Every API here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for apis
7 MCP tools reach this
find_apisBrowse and filter every API in the catalog.
get_api_artifactsOne API's artifacts, grouped by type.
get_openapiThe primary OpenAPI for this API.
find_similar_apisAPIs that look like this one.
apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
resolveTurn a domain, URL or GitHub org into the provider it belongs to.
find_cohortsEvery scored population of providers in the catalog.
All 92 tools →
Call it yourself
curl for this page
This API
curl "https://apis.io/api/v1/apis/recurly:recurly-transactions-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. See our Privacy Policy and
Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Recurly Transactions API
version: '1.0'
description: 'Operations tagged transactions across 2 of this provider''s published API definitions: recurly-v2-api.yaml, recurly-v2-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://{subdomain}.recurly.com/v2
variables:
subdomain:
description: Subdomain of your Recurly site.
default: my-super-successful-company
security:
- api_key: []
tags:
- name: Transactions
x-displayName: Transactions
paths:
/transactions:
get:
summary: List Transactions
description: '
'
tags:
- Transactions
operationId: listTransactions
parameters:
- in: query
name: state
schema:
type: string
default: ''
required: false
description: 'The state of transactions to return: "successful", "failed", or "voided".'
- in: query
name: type
schema:
type: string
default: ''
required: false
description: 'The type of transactions to return: "authorization", "refund", or "purchase".'
- in: query
name: cursor
schema:
type: string
default: ''
required: false
description: Splits records across pages. Leave blank to return the first page. Follow the URI in the first page's Link header to fetch the next page.
- in: query
name: per_page
schema:
type: string
default: '50'
required: false
description: Number of records to return per page, up to a maximum of 200.
responses:
'200':
description: ''
content:
application/xml:
example: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<transactions type=\"array\">\n <transaction href=\"https://your-subdomain.recurly.com/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" type=\"credit_card\">\n <account href=\"https://your-subdomain.recurly.com/v2/accounts/1\"/>\n <invoice href=\"https://your-subdomain.recurly.com/v2/invoices/1108\"/>\n <subscription href=\"https://your-subdomain.recurly.com/v2/subscriptions/17caaca1716f33572edc8146e0aaefde\"/>\n <uuid>a13acd8fe4294916b79aec87b7ea441f</uuid>\n <action>purchase</action>\n <amount_in_cents type=\"integer\">1000</amount_in_cents>\n <tax_in_cents type=\"integer\">0</tax_in_cents>\n <currency>USD</currency>\n <status>success</status>\n <payment_method>credit_card</payment_method>\n <reference nil=\"nil\"></reference>\n <source>subscription</source>\n <recurring type=\"boolean\">true</recurring>\n <test type=\"boolean\">true</test>\n <voidable type=\"boolean\">true</voidable>\n <refundable type=\"boolean\">true</refundable>\n <ip_address>127.0.0.1</ip_address>\n <cvv_result code=\"\" nil=\"nil\"></cvv_result>\n <avs_result code=\"\" nil=\"nil\"></avs_result>\n <avs_result_street nil=\"nil\"></avs_result_street>\n <avs_result_postal nil=\"nil\"></avs_result_postal>\n <created_at type=\"datetime\">2011-06-27T12:34:56Z</created_at>\n <details>\n <account>\n <account_code>verena100</account_code>\n <first_name>Verena</first_name>\n <last_name>Example</last_name>\n <company nil=\"nil\"></company>\n <email>verena@test.com</email>\n <billing_info type=\"credit_card\">\n <first_name nil=\"nil\"></first_name>\n <last_name nil=\"nil\"></last_name>\n <address1 nil=\"nil\"></address1>\n <address2 nil=\"nil\"></address2>\n <city nil=\"nil\"></city>\n <state nil=\"nil\"></state>\n <zip nil=\"nil\"></zip>\n <country nil=\"nil\"></country>\n <phone nil=\"nil\"></phone>\n <vat_number nil=\"nil\"></vat_number>\n <card_type>Visa</card_type>\n <year type=\"integer\">2015</year>\n <month type=\"integer\">11</month>\n <first_six>411111</first_six>\n <last_four>1111</last_four>\n </billing_info>\n </account>\n </details>\n <a name=\"refund\" href=\"http://api.test.host/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" method=\"delete\"/>\n </transaction>\n <!-- Continued... -->\n</transactions>"
'400':
description: ''
content:
application/json:
example: '{}'
x-codeSamples:
- lang: PHP
source: "$transactions = Recurly_TransactionList::get();\nforeach ($transactions as $transaction) {\n print \"Transaction: $transaction\\n\";\n}"
- lang: Ruby
source: "Recurly::Transaction.find_each do |transaction|\n puts \"Transaction: #{transaction.inspect}\"\nend"
- lang: Python
source: "# client version 2.1.6+\nfor transaction in Transaction.all():\n print 'Transaction: %s' % transaction\n\n# client version <= 2.1.5\ntransactions = Transaction.all()\nwhile transactions:\n for transaction in transactions:\n print 'Transaction: %s' % transaction\n try:\n transactions = transactions.next_page()\n except PageError:\n transactions = ()"
- lang: Dotnet
source: "using System.Linq;\n\nvar transactions = Transactions.List();\nwhile (transactions.Any())\n{\n\tforeach (var transaction in transactions)\n\t\tConsole.WriteLine(\"Transaction: \" + transaction);\n\ttransactions = transactions.Next;\n}\n\n// Filter successful Transactions\nvar transactions = Transactions.List(TransactionList.TransactionState.Success);\n\n// Filter failed purchases\nvar transactions = Transactions.List(TransactionList.TransactionState.Success,\n TransactionList.TransactionType.Failed);"
post:
summary: Create Transaction
description: 'The Recurly API provides a shortcut for creating an invoice, charge, and optionally account, and processing the payment immediately. When creating an account all of the required account attributes must be supplied. When charging an existing account only the account_code must be supplied.
##### Using stored billing info
You may create a transaction without specifying billing information if an account already has stored billing information.
xml
PHP
Ruby
Python
text
```xml
100
USD
1
```
```php
$transaction = new Recurly_Transaction();
$transaction->amount_in_cents = 100; // $1.00
$transaction->currency = ''USD'';
$transaction->account = new Recurly_Account();
$transaction->account->account_code = ''1'';
$transaction->create();
```
```ruby
transaction = account.transactions.create(
:amount_in_cents => 1_00,
:currency => ''USD'',
:account => { :account_code => ''1'' }
)
```
```python
transaction = Transaction(
amount_in_cents=100,
currency=''USD'',
account=Account(account_code=''1'')
)
transaction.save()
```
```text
var transaction = new Transaction("1", 100, "USD"); // account code, unit amount in cents, currency
transaction.Create();
```'
tags:
- Transactions
operationId: createTransaction
parameters: []
requestBody:
required: true
content:
application/xml:
schema:
type: object
properties:
amount_in_cents:
type: integer
default: ''
description: Amount of the transaction in cents. Max 10000000.
currency:
type: string
default: ''
description: 3-letter currency for the transaction
description:
type: string
default: ''
description: A description for the transaction. Description is added to the invoiced charge, and not the transaction object
account:
type: object
default: ''
description: nested attributes (see below)
account_code:
type: string
default: ''
description: 'A unique identifier used by your application to identify the account. This code may only contain the following characters: [a-z A-Z 0-9 @ - _ .]. Max of 50 characters.'
username:
type: string
default: ''
description: Username, ignore if you do not use usernames
email:
type: string
default: ''
description: Email address
first_name:
type: string
default: ''
description: First Name. Max 50 characters.
last_name:
type: string
default: ''
description: Last Name. Max 50 characters.
company_name:
type: string
default: ''
description: Company name. Max of 50 characters.
accept_language:
type: string
default: ''
description: An ISO 639-1 language code from the user's browser, indicating their preferred language and locale.
billing_info:
type: object
default: ''
description: account->billing_info nested attributes (see below)
company:
type: string
default: ''
description: Company name. Max of 50 characters.
address1:
type: string
default: ''
description: Address line 1, recommended for address validation. Max 50 characters.
address2:
type: string
default: ''
description: Address line 2. Max 50 characters.
city:
type: string
default: ''
description: City. Max 50 characters.
state:
type: string
default: ''
description: State or Province, 2-letters preferred
country:
type: string
default: ''
description: Country, 2-letter ISO code. Strongly Recommended
zip:
type: string
default: ''
description: Zip or postal code, recommended for address validation. Strongly Recommended
phone:
type: string
default: ''
description: Phone number
vat_number:
type: string
default: ''
description: Customer's VAT Number
ip_address:
type: string
default: ''
description: Customer's IP address when updating their billing information. Strongly Recommended.
number:
type: string
default: ''
description: Credit card number, spaces and dashes are accepted.
month:
type: string
default: ''
description: Expiration Month
year:
type: string
default: ''
description: Expiration Year
verification_value:
type: string
default: ''
description: Security code or CVV, 3-4 digits. Strongly Recommended.
responses:
'200':
description: ''
content:
application/xml:
example: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<transaction href=\"https://your-subdomain.recurly.com/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" type=\"credit_card\">\n <account href=\"https://your-subdomain.recurly.com/v2/accounts/1\"/>\n <invoice href=\"https://your-subdomain.recurly.com/v2/invoices/1108\"/>\n <uuid>a13acd8fe4294916b79aec87b7ea441f</uuid>\n <action>purchase</action>\n <amount_in_cents type=\"integer\">1000</amount_in_cents>\n <tax_in_cents type=\"integer\">0</tax_in_cents>\n <currency>USD</currency>\n <status>success</status>\n <reference nil=\"nil\"></reference>\n <test type=\"boolean\">true</test>\n <voidable type=\"boolean\">true</voidable>\n <refundable type=\"boolean\">true</refundable>\n <ip_address>127.0.0.1</ip_address>\n <cvv_result code=\"\" nil=\"nil\"></cvv_result>\n <avs_result code=\"\" nil=\"nil\"></avs_result>\n <avs_result_street nil=\"nil\"></avs_result_street>\n <avs_result_postal nil=\"nil\"></avs_result_postal>\n <created_at type=\"datetime\">2011-06-27T12:34:56Z</created_at>\n <details>\n <account>\n <account_code>verena100</account_code>\n <first_name>Verena</first_name>\n <last_name>Example</last_name>\n <company nil=\"nil\"></company>\n <email>verena@test.com</email>\n <billing_info type=\"credit_card\">\n <first_name nil=\"nil\"></first_name>\n <last_name nil=\"nil\"></last_name>\n <address1 nil=\"nil\"></address1>\n <address2 nil=\"nil\"></address2>\n <city nil=\"nil\"></city>\n <state nil=\"nil\"></state>\n <zip nil=\"nil\"></zip>\n <country nil=\"nil\"></country>\n <phone nil=\"nil\"></phone>\n <vat_number nil=\"nil\"></vat_number>\n <card_type>Visa</card_type>\n <year type=\"integer\">2015</year>\n <month type=\"integer\">11</month>\n <first_six>411111</first_six>\n <last_four>1111</last_four>\n </billing_info>\n </account>\n </details>\n <a name=\"refund\" href=\"http://api.test.host/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" method=\"delete\"/>\n</transaction>"
x-codeSamples:
- lang: PHP
source: '$transaction = new Recurly_Transaction();
$transaction->amount_in_cents = 1000; // $10.00.
$transaction->currency = ''USD'';
$account = new Recurly_Account();
$account->account_code = ''1'';
$billing_info = new Recurly_BillingInfo();
$billing_info->first_name = ''Verena'';
$billing_info->last_name = ''Example'';
$billing_info->number = ''4111-1111-1111-1111'';
$billing_info->verification_value = ''123'';
$billing_info->month = 11;
$billing_info->year = 2015;
$account->billing_info = $billing_info;
$transaction->account = $account;
$transaction->create();'
- lang: Ruby
source: "transaction = Recurly::Transaction.create(\n :amount_in_cents => 10_00,\n :currency => 'USD',\n :account => {\n :account_code => '1',\n :billing_info => {\n :first_name => 'Verena',\n :last_name => 'Example',\n :number => '4111-1111-1111-1111',\n :verification_value => '123',\n :month => 11,\n :year => 2015\n }\n }\n)"
- lang: Python
source: "transaction = Transaction(\n amount_in_cents=1000,\n currency='USD',\n account=Account(\n account_code=account_code,\n billing_info=BillingInfo(\n first_name='Verena',\n last_name='Example',\n number='4111-1111-1111-1111',\n verification_value='123',\n year=2015',\n month=11\n )\n )\n)\ntransaction.save()"
- lang: Dotnet
source: "var account = Accounts.Get(\"1\");\naccount.BillingInfo = new BillingInfo(account.AccountCode)\n{\n\tFirstName = \"Verana\",\n\tLastName = \"Example\",\n\tCreditCardNumber = \"4111-1111-1111-1111\",\n\tVerificationValue = \"123\",\n\tExpirationYear = 2015,\n\tExpirationMonth = 11\n};\nvar transaction = new Transaction(account, 100, \"USD\");\ntransaction.Create();"
servers:
- url: https://{subdomain}.recurly.com/v2
variables:
subdomain:
description: Subdomain of your Recurly site.
default: my-super-successful-company
/accounts/{account_code}/transactions:
get:
summary: List Account's Transactions
description: '
'
tags:
- Transactions
operationId: listAccountsTransactions
parameters:
- in: query
name: state
schema:
type: string
default: ''
required: false
description: 'The state of transactions to return: "successful", "failed", or "voided".'
- in: query
name: type
schema:
type: string
default: ''
required: false
description: 'The type of transactions to return: "authorization", "refund", or "purchase".'
- in: query
name: cursor
schema:
type: string
default: ''
required: false
description: Splits records across pages. Leave blank to return the first page. Follow the URI in the first page's Link header to fetch the next page.
- in: query
name: per_page
schema:
type: string
default: '50'
required: false
description: Number of records to return per page, up to a maximum of 200.
- in: path
name: account_code
schema:
type: string
required: true
description: Account Code.
responses:
'200':
description: ''
content:
application/xml:
example: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<transactions type=\"array\">\n <transaction href=\"https://your-subdomain.recurly.com/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" type=\"credit_card\">\n <account href=\"https://your-subdomain.recurly.com/v2/accounts/b6f5783\"/>\n <invoice href=\"https://your-subdomain.recurly.com/v2/invoices/1108\"/>\n <subscription href=\"https://your-subdomain.recurly.com/v2/subscriptions/17caaca1716f33572edc8146e0aaefde\"/>\n <uuid>a13acd8fe4294916b79aec87b7ea441f</uuid>\n <action>purchase</action>\n <amount_in_cents type=\"integer\">1000</amount_in_cents>\n <tax_in_cents type=\"integer\">0</tax_in_cents>\n <currency>USD</currency>\n <status>success</status>\n <payment_method>credit_card</payment_method>\n <reference nil=\"nil\"></reference>\n <source>subscription</source>\n <recurring type=\"boolean\">false</recurring>\n <test type=\"boolean\">true</test>\n <voidable type=\"boolean\">true</voidable>\n <refundable type=\"boolean\">true</refundable>\n <ip_address>127.0.0.1</ip_address>\n <cvv_result code=\"\" nil=\"nil\"></cvv_result>\n <avs_result code=\"\" nil=\"nil\"></avs_result>\n <avs_result_street nil=\"nil\"></avs_result_street>\n <avs_result_postal nil=\"nil\"></avs_result_postal>\n <created_at type=\"datetime\">2011-06-27T12:34:56Z</created_at>\n <details>\n <account>\n <account_code>verena100</account_code>\n <first_name>Verena</first_name>\n <last_name>Example</last_name>\n <company nil=\"nil\"></company>\n <email>verena@test.com</email>\n <billing_info type=\"credit_card\">\n <first_name nil=\"nil\"></first_name>\n <last_name nil=\"nil\"></last_name>\n <address1 nil=\"nil\"></address1>\n <address2 nil=\"nil\"></address2>\n <city nil=\"nil\"></city>\n <state nil=\"nil\"></state>\n <zip nil=\"nil\"></zip>\n <country nil=\"nil\"></country>\n <phone nil=\"nil\"></phone>\n <vat_number nil=\"nil\"></vat_number>\n <card_type>Visa</card_type>\n <year type=\"integer\">2015</year>\n <month type=\"integer\">11</month>\n <first_six>411111</first_six>\n <last_four>1111</last_four>\n </billing_info>\n </account>\n </details>\n <a name=\"refund\" href=\"http://api.test.host/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" method=\"delete\"/>\n </transaction>\n <!-- Continued... -->\n</transactions>"
'400':
description: ''
content:
application/json:
example: '{}'
x-codeSamples:
- lang: PHP
source: "try {\n $transactions = Recurly_TransactionList::getForAccount('b6f5783');\n foreach ($transactions as $transaction) {\n print \"Transaction: $transaction\\n\";\n }\n} catch (Recurly_NotFoundError $e) {\n print \"Account Not Found: $e\";\n}"
- lang: Ruby
source: "account = Recurly::Account.find('1')\naccount.transactions.find_each do |transaction|\n puts \"Transaction: #{transaction.inspect}\"\nend"
- lang: Python
source: "# client version 2.1.6+\naccount = Account.get('1')\nfor transaction in account.transactions():\n print 'Transaction: %s' % transaction\n\n# client version <= 2.1.5\naccount = Account.get('1')\ntransactions = account.transactions()\nwhile transactions:\n for transaction in transactions:\n print 'Transaction: %s' % transaction\n try:\n transactions = transactions.next_page()\n except PageError:\n transactions = ()"
- lang: Dotnet
source: "using System.Linq;\n\nvar account = Accounts.Get(\"1\");\nvar transactions = account.GetTransactions();\nwhile (transactions.Any())\n{\n\tforeach (var transaction in transactions)\n\t\tConsole.WriteLine(\"Transaction: \" + transaction);\n\ttransactions = transactions.Next;\n}"
servers:
- url: https://{subdomain}.recurly.com/v2
variables:
subdomain:
description: Subdomain of your Recurly site.
default: my-super-successful-company
/transactions/{id}:
get:
summary: Lookup Transaction
description: 'The details section contains the account and billing information at the time the transaction was submitted. It may not reflect the latest account information. A transaction_error section may be included if the transaction failed. Please see transaction error codes for more details.
**Transaction Attributes**
| Attributes | Description |
| --- | --- |
| uuid | Unique transaction id |
| action | "purchase", "authorization" or "refund" |
| amount_in_cents | Total transaction amount in cents |
| tax_in_cents | Amount of tax or VAT within the transaction, in cents |
| currency | 3-letter currency for the transaction |
| status | "success", "failed", or "void" |
| payment_method | "credit_card", "paypal", "check", "wire_transfer", "money_order" |
| reference | Transaction reference from your payment gateway |
| source | Source of the transaction. Possible values: `transaction` for one-time transactions, `subscription` for subscriptions, `billing_info` for updating billing info. |
| recurring | True if transaction is recurring |
| test | True if test transaction |
| voidable | True if the transaction may be voidable, accuracy depends on your gateway |
| refundable | True if the transaction may be refunded |
| ip_address | Customer''s IP address on the transaction, if applicable |
| cvv_result | CVV result, if applicable |
| avs_result | AVS result, if applicable |
| avs_result_street | AVS result for the street address, line 1 |
| avs_result_postal | AVS result for the postal code |
| created_at | Date the transaction took place |
| details | Nested account and billing information submitted at the time of the transaction. When writing a client library, do not map these directly to Account or Billing Info objects. |'
tags:
- Transactions
operationId: lookupTransaction
parameters:
- in: path
name: id
schema:
type: string
required: true
description: Id.
responses:
'200':
description: ''
content:
application/xml:
example: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<transaction href=\"https://your-subdomain.recurly.com/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" type=\"credit_card\">\n <account href=\"https://your-subdomain.recurly.com/v2/accounts/1\"/>\n <invoice href=\"https://your-subdomain.recurly.com/v2/invoices/1108\"/>\n <subscription href=\"https://your-subdomain.recurly.com/v2/subscriptions/17caaca1716f33572edc8146e0aaefde\"/>\n <uuid>a13acd8fe4294916b79aec87b7ea441f</uuid>\n <action>purchase</action>\n <amount_in_cents type=\"integer\">1000</amount_in_cents>\n <tax_in_cents type=\"integer\">0</tax_in_cents>\n <currency>USD</currency>\n <status>success</status>\n <payment_method>credit_card</payment_method>\n <reference nil=\"nil\"></reference>\n <source>subscription</source>\n <recurring type=\"boolean\">true</recurring>\n <test type=\"boolean\">true</test>\n <voidable type=\"boolean\">true</voidable>\n <refundable type=\"boolean\">true</refundable>\n <ip_address>127.0.0.1</ip_address>\n <cvv_result code=\"\" nil=\"nil\"></cvv_result>\n <avs_result code=\"\" nil=\"nil\"></avs_result>\n <avs_result_street nil=\"nil\"></avs_result_street>\n <avs_result_postal nil=\"nil\"></avs_result_postal>\n <created_at type=\"datetime\">2011-06-27T12:34:56Z</created_at>\n <details>\n <account>\n <account_code>verena100</account_code>\n <first_name>Verena</first_name>\n <last_name>Example</last_name>\n <company nil=\"nil\"></company>\n <email>verena@test.com</email>\n <billing_info type=\"credit_card\">\n <first_name nil=\"nil\"></first_name>\n <last_name nil=\"nil\"></last_name>\n <address1 nil=\"nil\"></address1>\n <address2 nil=\"nil\"></address2>\n <city nil=\"nil\"></city>\n <state nil=\"nil\"></state>\n <zip nil=\"nil\"></zip>\n <country nil=\"nil\"></country>\n <phone nil=\"nil\"></phone>\n <vat_number nil=\"nil\"></vat_number>\n <card_type>Visa</card_type>\n <year type=\"integer\">2015</year>\n <month type=\"integer\">11</month>\n <first_six>411111</first_six>\n <last_four>1111</last_four>\n </billing_info>\n </account>\n </details>\n <a name=\"refund\" href=\"http://api.test.host/v2/transactions/a13acd8fe4294916b79aec87b7ea441f\" method=\"delete\"/>\n</transaction>"
x-codeSamples:
- lang: PHP
source: "try {\n $transaction = Recurly_Transaction::get('a13acd8fe4294916b79aec87b7ea441f');\n\n print \"Transaction: $transaction\";\n} catch (Recurly_NotFoundError $e) {\n print \"Transaction not found: $e\";\n}"
- lang: Ruby
source: transaction = Recurly::Transaction.find('a13acd8fe4294916b79aec87b7ea441f')
- lang: Python
source: transaction = Transaction.get('a13acd8fe4294916b79aec87b7ea441f')
- lang: Dotnet
source: var transaction = Transactions.Get("a13acd8fe4294916b79aec87b7ea441f");
servers:
- url: https://{subdomain}.recurly.com/v2
variables:
subdomain:
description: Subdomain of your Recurly site.
default: my-super-successful-company
components:
securitySchemes:
api_key:
type: http
description: Enter the API key as the username and set the password to an empty string. You can locate and manage your API keys from the [API Credentials](https://app.recurly.com/go/developer/api_keys) page.
scheme: basic
x-refined-from:
- recurly-v2-api.yaml
- recurly-v2-openapi.yml
x-readme:
explorer-enabled: false