assembly-payments
Version:
Assembly Payments API Typescript/Javascript Bindings
1,251 lines (1,250 loc) • 329 kB
YAML
openapi: 3.0.0
info:
title: Assembly API
description: Assembly (formely PromisePay) is a powerful payments engine custom-built for platforms and marketplaces.
version: '2.0'
contact:
email: support@assemblypayments.com
url: 'http://docs.assemblypayments.com/'
servers:
# Added by API Auto Mocking Plugin
- description: SwaggerHub API Auto Mocking
url: https://virtserver.swaggerhub.com/AssemblyPlatforms/assembly-api/2.0
- url: 'https://test.api.promisepay.com'
description: Pre-live environment
- url: 'https://secure.api.promisepay.com'
description: Production environment
- url: 'https://au-0000.sandbox.auth.assemblypay.com'
description: Pre-Live (Sandbox) Auth issuing server and API
- url : 'https://au-0000.auth.assemblypay.com'
description: Production Auth issuing server and API
x-explorer-enabled: false
x-samples-languages:
- curl
- ruby
- php
- javascript
- csharp
- go
paths:
'/tokens':
post:
tags:
- Authentication
summary: Token
description: Exchange client application credentials for a bearer token. Please ensure to call the auth issuing server as described at https://developer.assemblypayments.com/reference#authentication
operationId: token
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/tokens_request_body'
responses:
'200':
description: >-
Response body contains an access token with lifetime in seconds and usage information.
content:
application/json:
schema:
$ref: '#/components/schemas/tokens_response'
examples:
response:
value:
access_token: ey...J9.ey...n0.Iu...7g
expires_in: 3600
token_type: Bearer
'400':
description: Request not parseable, grant type invalid or properties missing
content:
application/json:
schema:
$ref: '#/components/schemas/error'
examples:
response:
value:
error: bad request
'401':
description: We can't resolve the supplied credentials
content:
application/json:
schema:
$ref: '#/components/schemas/error'
examples:
response:
value:
error: invalid credentials
'422':
description: One or more property values are unprocessable
content:
application/json:
schema:
$ref: '#/components/schemas/error'
examples:
response:
value:
error: invalid client details
'500':
description: We have a problem, which we have logged. Please try again later and if it still doesn't work, contact us.
content:
application/json:
schema:
$ref: '#/components/schemas/error'
examples:
response:
value:
error: something went wrong
'/addresses/{id}':
get:
tags:
- Addresses
summary: Show Address
description: 'Show details of a specific Address using a given address `:id`.'
operationId: showAddress
parameters:
- name: id
in: path
description: Address ID
required: true
style: simple
explode: false
schema:
type: string
default: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
example: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/address'
examples:
response:
value:
addresses:
addressline1: 100 Main Street
addressline2: office building no 3
postcode: 2000
city: Sydney
state: NSW
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
country: Australia
links:
self: /addresses/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
'/bank_accounts/{id}':
get:
tags:
- Bank Accounts
summary: Show Bank Account
description: 'Show details of a specific **Bank Account** using a given `:id`.'
operationId: showBankAccount
parameters:
- name: id
in: path
description: Bank account ID
required: true
style: simple
explode: false
schema:
type: string
default: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
example: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/bank_account'
examples:
response:
value:
bank_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
created_at: '2020-04-27T20:28:22.378Z'
updated_at: '2020-04-27T20:28:22.378Z'
verification_status: not_verified
currency: AUD
bank:
bank_name: Bank of Australia
country: AUS
account_name: Samuel Seller
routing_number: XXXXX3
account_number: XXX234
holder_type: personal
account_type: checking
direct_debit_authority_status: approved
links:
self: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
users: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users
direct_debit_authorities: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/direct_debit_authorities
delete:
tags:
- Bank Accounts
summary: Redact Bank Account
description: |
Redact a **Bank Account** using a given `:id`. Redacted **Bank Accounts** can no longer be used as a funding source or a Disbursement destination.
operationId: redactBankAccount
parameters:
- name: id
in: path
description: Bank account ID
required: true
style: simple
explode: false
schema:
type: string
default: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
example: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/bank_account_deletion'
examples:
response:
value:
bank_account: Successfully redacted
'/bank_accounts/{id}/penny_send':
patch:
tags:
- Bank Accounts
summary: Send Penny Amount
description: |
When penny verification is enabled, this API call sends two penny transactions to the specified bank account for verification. **Note**: This API call is not required when your platform has automatic penny verification enabled, as this is instead done by the system. Penny credit verification is only supported for US platforms.
operationId: sendPennyAmount
parameters:
- name: id
in: path
description: Bank account ID
required: true
style: simple
explode: false
schema:
type: string
default: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
example: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/bank_account'
examples:
response:
value:
bank_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
created_at: '2020-04-27T20:28:22.378Z'
updated_at: '2020-04-27T20:28:22.378Z'
verification_status: verifying
currency: AUD
bank:
bank_name: Bank of Australia
country: AUS
account_name: Samuel Seller
routing_number: XXXXX3
account_number: XXX234
holder_type: personal
account_type: checking
direct_debit_authority_status: approved
links:
self: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
users: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users
direct_debit_authorities: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/direct_debit_authorities
/bank_accounts:
post:
tags:
- Bank Accounts
summary: Create Bank Account
description: |
Create a **Bank Account** to be used as either a funding source or a Disbursement destination. Store the returned `:id` and use it for a `make_payment` **Item Action** call. The `:id` is also referred to as a `token` when involving **Bank Accounts**.
operationId: createBankAccount
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/bank_account_requestBody'
responses:
'201':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/bank_account'
examples:
response:
value:
bank_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
verification_status: not_verified
currency: AUD
bank:
bank_name: Bank of Australia
country: AUS
account_name: Samuel Seller
routing_number: XXXXX3
account_number: XXX234
holder_type: personal
account_type: checking
direct_debit_authority_status: approved
links:
self: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
users: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users
direct_debit_authorities: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/direct_debit_authorities
'/bank_accounts/{id}/penny_verify':
patch:
tags:
- Bank Accounts
summary: Verify Penny Amount
description: |
When penny verification is enabled, this API call verifies the two penny transactions that were sent to a specified bank account using **Send Penny Amount**. **Note**: This API call requires you to provide a front-end interface to your end-users into which they can input the penny amounts required for a successful verification. Your front-end interface should then pass the information into this API call. Penny credit verification is only supported for US platforms.
operationId: verifyPennyAmount
parameters:
- name: id
in: path
description: Bank account ID
required: true
style: simple
explode: false
schema:
type: string
default: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/penny_verify_requestBody'
responses:
'200':
description: OK
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/bank_account'
examples:
response:
value:
bank_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
verification_status: verified
currency: AUD
bank:
bank_name: Bank of Australia
country: AUS
account_name: Samuel Seller
routing_number: XXXXX3
account_number: XXX234
holder_type: personal
account_type: checking
direct_debit_authority_status: approved
links:
self: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
users: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users
direct_debit_authorities: /bank_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/direct_debit_authorities
'/bank_accounts/{id}/users':
get:
tags:
- Bank Accounts
summary: Show Bank Account User
description: 'Show the **User** the **Bank Account** is associated with using a given `:id`.'
operationId: showBankAccountUser
parameters:
- name: id
in: path
description: Bank account ID
required: true
style: simple
explode: false
schema:
type: string
default: 901d8cd0-6af3-0138-967d-0a58a9feac04
example: '901d8cd0-6af3-0138-967d-0a58a9feac04'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_user'
examples:
response:
value:
users:
created_at: '2020-04-03T07:59:00.379Z'
updated_at: '2020-04-03T07:59:00.379Z'
id: Seller_1234
full_name: Samuel Seller
email: sam@example.com
mobile: 69543131
phone: null
logo_url: null
color_1: null
color_2: null
first_name: Samuel
last_name: Seller
custom_descriptor: Sam Garden Jobs
location: AUS
verification_state: pending
held_state: false
roles:
- customer
dob: encrypted
government_number: encrypted
drivers_license: null
flags: {}
related:
addresses: '11111111-2222-3333-4444-55555555555,'
links:
self: /bank_accounts/901d8cd0-6af3-0138-967d-0a58a9feac04/users
items: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/items
card_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/card_accounts
paypal_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/paypal_accounts
payid_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/payid_accounts
bank_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/bank_accounts
wallet_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/wallet_accounts
/tools/routing_number:
get:
tags:
- Bank Accounts
summary: Validate Routing Number
description: 'Validate a US bank routing number before creating an account. This can be used to provide on-demand verification, and further information of the bank information a User is providing.'
operationId: validateRoutingNumber
parameters:
- name: routing_number
in: query
description: Bank account routing number
required: true
style: form
explode: true
schema:
type: string
default: '122235821'
example: '122235821'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_routing_number'
examples:
response:
value:
routing_number:
routing_number: '122235821'
customer_name: US BANK NA
address: EP-MN-WN1A
city: ST. PAUL
state_code: MN
zip: '55107'
zip_extension: '1419'
phone_area_code: '800'
phone_prefix: '937'
phone_suffix: '631'
"/bpay_accounts/{id}":
get:
tags:
- BPay Accounts
summary: Show BPay Account
description: "Show details of a specific **BPay Account** using a given `:id`."
operationId: showBPayAccount
parameters:
- name: id
in: path
description: BPay account ID
required: true
style: simple
explode: false
schema:
type: string
default: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
example: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
responses:
"200":
description: OK
content:
application/json:
schema:
$ref: "#/components/schemas/bpay_account"
examples:
response:
value:
bpay_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
created_at: "2020-04-03T07:59:00.379Z"
updated_at: "2020-04-03T07:59:00.379Z"
verification_status: not_verified
currency: AUD
bpay_details:
account_name: My Water Bill Company
biller_code: 123456
biller_name: "ABC Water"
crn: 987654321
links:
self: "/bpay_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
users: "/bpay_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users"
delete:
tags:
- BPay Accounts
summary: Redact BPay Account (Future Feature)
description: >
Redact a **BPay Account** using a given `:id`. Redacted **BPay
Accounts** can no longer be used as a Disbursement
destination.
operationId: redactBPayAccount
parameters:
- name: id
in: path
description: BPay account ID
required: true
style: simple
explode: false
schema:
type: string
default: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
example: "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
responses:
"200":
description: OK
content:
application/json:
schema:
$ref: "#/components/schemas/bpay_account_deletion"
examples:
response:
value:
bpay_account: Successfully redacted
/bpay_accounts:
post:
tags:
- BPay Accounts
summary: Create BPay Account
description: >
Create a **BPay Account** to be used as a Disbursement destination.
operationId: createBPayAccount
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/bpay_account_requestBody'
responses:
"201":
description: OK
content:
application/json:
schema:
$ref: "#/components/schemas/bpay_account"
examples:
response:
value:
bpay_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
created_at: "2020-04-03T07:59:00.379Z"
updated_at: "2020-04-03T07:59:00.379Z"
active: true
verification_status: not_verified
currency: AUD
bpay_details:
account_name: My Water Bill Company
biller_code: 123456
biller_name: "ABC Water"
crn: 987654321
links:
self: "/bpay_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"
users: "/bpay_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users"
"/bpay_accounts/{id}/users":
get:
tags:
- BPay Accounts
summary: Show BPay Account User
description: >-
Show the **User** the **BPay Account** is associated with using a given
`:id`.
operationId: showBPayAccountUser
parameters:
- name: id
in: path
description: BPay account ID
required: true
style: simple
explode: false
schema:
type: string
default: "901d8cd0-6af3-0138-967d-0a58a9feac04"
example: "901d8cd0-6af3-0138-967d-0a58a9feac04"
responses:
"200":
description: OK
content:
application/json:
schema:
$ref: "#/components/schemas/single_user"
examples:
response:
value:
users:
created_at: "2020-04-03T07:59:00.379Z"
updated_at: "2020-04-03T07:59:00.379Z"
id: Seller_1234
full_name: Samuel Seller
email: sam@example.com
mobile: 69543131
phone: null
logo_url: null
color_1: null
color_2: null
first_name: Samuel
last_name: Seller
custom_descriptor: Sam Garden Jobs
location: AUS
verification_state: pending
held_state: false
roles:
- customer
dob: encrypted
government_number: encrypted
drivers_license: null
flags: {}
related:
addresses: "11111111-2222-3333-4444-55555555555,"
links:
self: /bpay_accounts/901d8cd0-6af3-0138-967d-0a58a9feac04/users
items: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/items
card_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/card_accounts
paypal_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/paypal_accounts
payid_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/payid_accounts
bpay_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/bpay_accounts
wallet_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/wallet_accounts
"/wallet_accounts/{id}/bill_payment":
post:
tags:
- Wallet Accounts
summary: Pay a Bill
description: Pay a bill by withdrawing funds from a **Wallet Account** to a specified bpay account.
operationId: billPayment
parameters:
- name: id
in: path
description: Account ID
required: true
schema:
type: string
default: "901d8cd0-6af3-0138-967d-0a58a9feac04"
example: '8a31ebfa-421b-4cbb-9241-632f71b3778a'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/bill_payment_requestBody'
responses:
'201':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_disbursement'
examples:
response:
value:
disbursements:
id: 8a31ebfa-421b-4cbb-9241-632f71b3778a
amount: 173
currency: AUD
batch_id: null
cuscal_payment_transaction_id: null
created_at: '2020-05-09T07:09:03.383Z'
updated_at: '2020-05-09T07:09:04.585Z'
state: pending
to: BPay Account
account_name: My Water Company
biller_name: ABC Water
biller_code: 123456
crn: 0987654321
links:
transactions: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/transactions
wallet_accounts: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/wallet_accounts
bank_accounts: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/bank_accounts
bpay_accounts: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/bpay_accounts
paypal_accounts: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/paypal_accounts
items: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/items
users: /disbursements/8a31ebfa-421b-4cbb-9241-632f71b3778a/users
'/users/{id}/bpay_accounts':
get:
tags:
- Users
summary: List User's BPay Accounts
description: >-
List the **BPay Accounts** the **User** is associated with using a given
`:id`.
operationId: listUserBPayAccounts
parameters:
- name: id
in: path
description: User ID
required: true
style: simple
explode: false
schema:
type: string
default: '901d8cd0-6af3-0138-967d-0a58a9feac04'
example: '901d8cd0-6af3-0138-967d-0a58a9feac04'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/list_bpay_accounts'
examples:
response:
value:
bpay_accounts:
- id: b0980390-ac5b-0138-8b2e-0a58a9feac03
active: true
created_at: 2020-07-20T02:07:33.583Z
updated_at: 2020-07-20T02:07:33.583Z
bpay_details:
biller_name: APIBCD AV4
account_name: Test Biller
biller_code: "93815"
crn: "613295205"
currency: AUD
verification_status: verified
links:
self: /bpay_accounts/b0980390-ac5b-0138-8b2e-0a58a9feac03
users: /bpay_accounts/b0980390-ac5b-0138-8b2e-0a58a9feac03/users
meta:
limit: 10
offset: 0
total: 1
links:
self: /users/901d8cd0-6af3-0138-967d-0a58a9feac04/bpay_accounts
'/callbacks/{id}':
get:
tags:
- Callbacks
summary: Show Callback
description: 'Show details of a specific **Callback** using a given `:id`.'
operationId: showCallback
parameters:
- name: id
in: path
description: Callback ID
required: true
style: simple
explode: false
schema:
type: string
default: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_callback'
examples:
response:
value:
callbacks:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
description": Users Callback
url: 'https://httpbin.org/post'
object_type: users
enabled: true
authorization_token: null
created_at: '2019-03-29T06:12:57.686Z'
updated_at: '2019-03-29T06:12:57.686Z'
marketplace_id: 8a840e7b-20e2-4a05-86b9-60b62bc6c21c
links:
self: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970
responses: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970/responses
delete:
tags:
- Callbacks
summary: Delete Callback
description: 'Delete an existing Callback using a given `:id`.'
operationId: deleteCallback
parameters:
- name: id
in: path
description: Callback ID
required: true
style: simple
explode: false
schema:
type: string
default: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/callback_deletion'
examples:
response:
value:
callbacks: Successfully redacted
patch:
tags:
- Callbacks
summary: Update Callback
description: |
Update an existing **Callback** using a given `:id`. You can change the `URL`, the `object_type` and whether the **Callback** is `enabled` or `disabled`.
operationId: updateCallback
parameters:
- name: id
in: path
description: Callback ID
required: true
style: simple
explode: false
schema:
type: string
default: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/callback_requestBody'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_callback'
examples:
response:
value:
callbacks:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
description": Users Callback
url: 'https://httpbin.org/post'
object_type: users
enabled: true
authorization_token: null
created_at: '2019-03-29T06:12:57.686Z'
updated_at: '2019-03-29T06:12:57.686Z'
links:
self: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970
responses: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970/responses
'/callbacks/{id}/responses':
get:
tags:
- Callbacks
summary: List Callback Responses
description: 'Retrieve an ordered and paginated list of the responses garnered from a callback using a given `:id`.'
operationId: listCallbackResponse
parameters:
- $ref: '#/components/parameters/limitParam'
- $ref: '#/components/parameters/offsetParam'
- name: id
in: path
description: Callback ID
required: true
style: simple
explode: false
schema:
type: string
default: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/list_callback_responses'
examples:
response:
value:
callback_responses:
- id: f96ca75b-4a37-4e37-a7e9-c121a0fd1142
created_at: '2019-04-01T01:55:30.345Z'
url: 'https://httpbin.org/post'
payload:
disbursements:
id: 42f2ca8f-deca-4d41-9982-26376a2d60ce
amount: 841698
currency: AUD
batch_id: 111
cuscal_payment_transaction_id: null
created_at: '2019-03-29T06:14:43.991Z'
updated_at: '2019-04-01T01:54:58.752Z'
state: batched
to: Bank Account
bank_name: Test Bank Assembly
bank_account_name: Assembly seller36550573
bank_account_number: XXX229
bank_routing_number: XXXXX9
npp_payout_state: trying
links:
transactions: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/transactions
wallet_accounts: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/wallet_accounts
bank_accounts: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/bank_accounts
paypal_accounts: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/paypal_accounts
items: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/items
users: /disbursements/42f2ca8f-deca-4d41-9982-26376a2d60ce/users
response:
error: OK
response_code: 200
- id: 0c9cbb28-0b98-4560-9c81-7a4ea6cde95b
created_at: '2019-04-01T01:55:25.276Z'
url: 'https://httpbin.org/post'
payload:
disbursements:
id: d98133ca-9a2e-4322-9610-62b2faf78476
amount: 577954
currency: AUD
batch_id: 111
cuscal_payment_transaction_id: null
created_at: '2019-03-29T06:14:07.045Z'
updated_at: '2019-04-01T01:54:58.448Z'
state: batched
to: Bank Account
bank_name: Test Bank Assembly
bank_account_name: Assembly seller36550536
bank_account_number: XXX229
bank_routing_number: XXXXX3
npp_payout_state: trying
links:
transactions: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/transactions
wallet_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/wallet_accounts
bank_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/bank_accounts
paypal_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/paypal_accounts
items: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/items
users: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/users
response:
error: OK
response_code: 200
meta:
limit: 2
offset: 0
total: 10
links:
self: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970/responses?limit=2
callbacks: /callbacks
'/callbacks/{callback_id}/responses/{id}':
get:
tags:
- Callbacks
summary: Show Callback Response
description: 'Show details of a specific **Callback** response using a given `:id`.'
operationId: showCallbackResponse
parameters:
- name: callback_id
in: path
description: Callback ID
required: true
style: simple
explode: false
schema:
type: string
default: '088e4cf1-2508-4bd4-97ab-a78e4e869970'
example: '088e4cf1-2508-4bd4-97ab-a78e4e869970'
- name: id
in: path
description: Callback response ID
required: true
style: simple
explode: false
schema:
type: string
default: '0c9cbb28-0b98-4560-9c81-7a4ea6cde95b'
example: '0c9cbb28-0b98-4560-9c81-7a4ea6cde95b'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_callback_response'
examples:
response:
value:
callback_responses:
id: 0c9cbb28-0b98-4560-9c81-7a4ea6cde95b
created_at: '2019-04-01T01:55:25.276Z'
url: 'https://httpbin.org/post'
payload:
disbursements:
id: d98133ca-9a2e-4322-9610-62b2faf78476
amount: 577954
currency: AUD
batch_id: 111
cuscal_payment_transaction_id: null
created_at: '2019-03-29T06:14:07.045Z'
updated_at: '2019-04-01T01:54:58.448Z'
state: batched
to: Bank Account
bank_name: Test Bank Assembly
bank_account_name: Assembly seller36550536
bank_account_number: XXX229
bank_routing_number: XXXXX3
npp_payout_state: trying
links:
transactions: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/transactions
wallet_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/wallet_accounts
bank_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/bank_accounts
paypal_accounts: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/paypal_accounts
items: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/items
users: /disbursements/d98133ca-9a2e-4322-9610-62b2faf78476/users
response:
error: OK
response_code: 200
links:
self: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970/responses/0c9cbb28-0b98-4560-9c81-7a4ea6cde95b
responses: /callbacks/088e4cf1-2508-4bd4-97ab-a78e4e869970/responses
/callbacks:
get:
tags:
- Callbacks
summary: List Callbacks
description: Retrieve an ordered and paginated list of all created **Callbacks**.
operationId: listCallbacks
parameters:
- $ref: '#/components/parameters/limitParam'
- $ref: '#/components/parameters/offsetParam'
- name: filter
in: query
description: Narrow down records to relevant character string
style: form
explode: true
schema:
type: string
example: ''
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/callbacks'
examples:
response:
value:
callbacks:
- id: a31a9b45-d5b3-401e-b7ce-0c23edd48b06
created_at: '2020-04-16T02:34:45.879Z'
updated_at: '2020-04-16T02:34:45.879Z'
description: Callbacks for items
url: 'https://httpbin.org/post'
object_type: disbursements
enabled: true
meta:
limit: 10
offset: 0
total: 1
links:
self: /callbacks
post:
tags:
- Callbacks
summary: Create Callback
description: Create a **Callback** to notify you at the `URL` when the `object_type` changes
operationId: createCallback
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/callback_requestBody'
responses:
'201':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_callback'
examples:
response:
value:
callbacks:
id: 30403493-7249-433a-83ce-555388f75c01
description: testy
url: 'https://httpbin.org'
object_type: batch_transactions
enabled: true
authorization_token: null
created_at: '2020-04-29T13:02:22.981Z'
updated_at: '2020-04-29T13:02:22.981Z'
links:
self: '/callbacks?description=testy&url=https://httpbin.org&object_type=batch_transactions&enabled=true'
responses: /callbacks/30403493-7249-433a-83ce-555388f75c01/responses
/card_accounts:
post:
tags:
- Card Accounts
summary: Create Card Account
description: |
Create a Credit **Card Account** to be used as a funding source. Store the returned `:id` and use it for a `make_payment` **Item Action** call. The `:id` is also referred to as a **token** when involving Credit Cards.
operationId: createCardAccount
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/card_account_requestBody'
responses:
'201':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/card_account'
examples:
response:
value:
card_accounts:
active: true
created_at: '2020-04-29T23:00:01.369Z'
updated_at: '2020-04-29T23:00:01.369Z'
id: 14160da0-6c9b-0138-e2ca-0a58a9feac03
cvv_verified: true
currency: AUD
links:
self: /card_accounts/14160da0-6c9b-0138-e2ca-0a58a9feac03
users: /card_accounts/14160da0-6c9b-0138-e2ca-0a58a9feac03/users
'/card_accounts/{id}/users':
get:
tags:
- Card Accounts
summary: Show Card Account User
description: 'Show the **User** the Credit **Card Account** is associated with using a given `:id`.'
operationId: showCardAccountUser
parameters:
- name: id
in: path
description: Card account ID
required: true
style: simple
explode: false
schema:
type: string
default: '901d8cd0-6af3-0138-967d-0a58a9feac04'
example: '901d8cd0-6af3-0138-967d-0a58a9feac04'
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/single_user'
examples:
response:
value:
users:
created_at: '2020-04-03T07:59:00.379Z'
updated_at: '2020-04-03T07:59:00.379Z'
id: Seller_1234
full_name: Samuel Seller
email: sam@example.com
mobile: 69543131
phone: null
logo_url: null
color_1: null
color_2: null
first_name: Samuel
last_name: Seller
custom_descriptor: Sam Garden Jobs
location: AUS
verification_state: pending
held_state: false
roles:
- customer
dob: encrypted
government_number: encrypted
drivers_license: null
flags: {}
related:
addresses: '11111111-2222-3333-4444-55555555555,'
links:
self: /card_accounts/901d8cd0-6af3-0138-967d-0a58a9feac04/users
items: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/items
card_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/card_accounts
paypal_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/paypal_accounts
payid_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/payid_accounts
bank_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/bank_accounts
wallet_accounts: /users/e6bc0480-57ae-0138-c46e-0a58a9feac03/wallet_accounts
'/card_accounts/{id}/verify':
patch:
tags:
- Card Accounts
summary: Verify Card
description: 'Where pre-authorization is enabled on a platform, verifies a **Card Account** when a **Card Account** is successfully verified, its verification status is `verified`.'
operationId: verifyCard
parameters:
- name: id
in: path
description: Card account ID
required: true
style: simple
explode: false
schema:
type: string
default: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
example: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
requestBody:
content:
application/json:
schema:
"$ref": "#/components/schemas/card_account_verify_requestBody"
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/card_account'
examples:
response:
value:
card_accounts:
id: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
active: true
verification_status: verified
currency: AUD
cvv_verified: true
created_at: '2019-04-08T01:40:15.038Z'
updated_at: '2019-04-08T01:40:15.038Z'
card:
type: visa
full_name: Jane Doe
number: XXXX-XXXX-XXXX-1111
expiry_month: '10'
expiry_year: '2020'
links:
self: /card_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee
users: /card_accounts/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/users
'/card_accounts/{id}':
get:
tags:
- Card Accounts
summary: Show Card Account
description: |
Show details of a specific Credit **Card Account** using a given `:id`. You can toggle the card account number display to show the first 6 digits in addition to the last 4 digits. Contact Assembly if you want to toggle the card account display.
operationId: showCardAccount
parameters:
- name: id