Transactions

Use these methods to obtain information about transactions (such as deposits, withdrawals, exchanges and transfers) made on accounts owned by a user that is currently signed in to the B2Core UI.

GET[host]/api/v2/my/transactions

Get a list of transactions

GET[host]/api/v2/my/transactions/{transactionId}

Get transaction details

Get a list of client transactions

Use this method to obtain a list of transactions made on accounts owned by a user that is currently signed in to the B2Core UI.

To obtain detailed information about a specific transaction, use a separate method to get transaction details.

When a request doesn’t include a filter parameter indicating the transaction type, a response includes transactions of all types.

The available filter and sorting parameters are listed in the Request section below.

Note

A response includes transactions with any status, except for those marked as new.

Request

Header parameters:

  • Authorization: Bearer <access_token>

Query parameters:

The following filter parameters are available for this method:

accountId

The identifier of a client account.

status

The current transaction status. Possible values:

  • cancelled

  • done

  • failed

  • hold

  • holdFailed

  • inProgress

  • new

  • partial

  • pending

  • rejected

  • refund

  • refundFailed

  • trade

Transactions with the new status are not returned.

type

The transaction type. Possible values:

  • deposit

  • exchange

  • external

  • partner

  • transfer

  • withdrawal

The following sorting parameters are available for this method:

createTime

The date and time when a transaction was made.

creditAmount

Applicable only for deposit-type transactions.

The amount deposited to an account.

debitAmount

Applicable only for withdrawal-type transactions.

The amount withdrawn from an account.

Refer to the Query parameters section in the API Overview for details on applying filter and sorting parameters.

GET[host]/api/v2/my/transactions

curl --location -g --request GET 'https://host.name/api/v2/my/transactions?limit=10&offset=0&sort_order=desc&sort_by=createTime&filter[accountId]=1&filter[status]=done&filter[type]=deposit' \
--header 'Authorization: Bearer <token>'

Response

A response contains an array of Transaction objects providing information about the transactions matching the request parameters.

Get transaction details

Use this method to obtain detailed information about a specified transaction.

To obtain a list of transactions made on a client account, use a separate method to get a list of transactions.

Request

Path parameters:

transactionId required

The transaction identifier.

GET[host]/api/v2/transactions{transactionId}

curl --location --request GET 'https://host.name/api/v2/my/transactions/1' \
--header 'Authorization: Bearer <token>'

Response

A response contains a Transaction object providing details about the specified transaction.