openapi: 3.2.0 info: title: Assembly Callbacks API description: Assembly (formely PromisePay) is a powerful payments engine custom-built for platforms and marketplaces. version: '2.3' contact: email: support@assemblypayments.com url: http://docs.assemblypayments.com/ servers: - 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 - description: SwaggerHub API Auto Mocking url: https://virtserver.swaggerhub.com/AssemblyPlatforms/assembly-api/2.3 security: - oAuth2ClientCredentials: [] tags: - name: Callbacks paths: /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 reference_id: null 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 reference_id: null 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 components: schemas: single_callback_response: properties: call_responses: $ref: '#/components/schemas/callback_response' list_callback_responses: properties: callback_responses: type: array items: $ref: '#/components/schemas/callback_response' meta: type: object properties: limit: type: integer offset: type: integer total: type: integer links: type: object properties: self: type: string callbacks: type: string callback_deletion: properties: callbacks: type: string example: Successfully redacted callback_requestBody: type: object required: - description - url - object_type - enabled properties: url: description: URL to which the callbacks will notify type: string default: https://httpbin.org example: https://httpbin.org object_type: description: Object or entity to which the callbacks refer. Please refer to [Callbacks](https://developer.assemblypayments.com/docs/callbacks) for a list of object types. type: string default: users example: users enabled: description: Toggle whether callback is active or inactive. type: string default: 'true' example: 'true' callbacks: properties: callbacks: type: array items: $ref: '#/components/schemas/callback' callback: type: object properties: id: type: string example: f92d4ca1-4ee5-43f3-9e34-ca5f759c5e76 description: type: string example: Users Callback url: type: string example: https://httpbin.org/post object_type: type: string enum: - Transactions - Items - Users - Batch Transactions - Disbursements - Accounts example: users enabled: type: boolean example: true authorization_token: type: string created_at: type: string format: date-time updated_at: type: string format: date-time marketplace_id: type: string format: uuid links: type: object properties: self: type: string responses: type: string callback_response: type: object properties: id: type: string example: 4476b384-fa48-4473-98ec-8fcdda4a1e84 url: type: string example: https://httpbin.org/post created_at: type: string format: date-time payload: type: object properties: message: type: string example: Assembly callback test response: type: object properties: error: type: string example: OK response_code: type: integer example: 200 single_callback: properties: callbacks: $ref: '#/components/schemas/callback' parameters: offsetParam: name: offset in: query description: Number of records to offset. Required for pagination. required: false schema: type: integer minimum: 0 default: 0 limitParam: name: limit in: query description: Number of records to retrieve. Up to 200. required: false schema: type: integer minimum: 1 maximum: 200 default: 10 securitySchemes: oAuth2ClientCredentials: type: oauth2 description: Please refer to Authentication section within https://developer.assemblypayments.com/reference#authentication flows: clientCredentials: tokenUrl: https://au-0000.sandbox.auth.assemblypay.com/tokens scopes: {} x-explorer-enabled: false x-samples-languages: - curl - ruby - php - javascript - csharp - go x-proxy-enabled: true x-samples-enabled: true