For the complete documentation index, see llms.txt. This page is also available as Markdown.

Listing channels

GET /api/public/v1/channels

Returns your channels, newest first, with pagination. Filter by reference to find the channel assigned to one end user.

Headers

Name
Value

Content-Type

application/vnd.api+json

Authorization

Bearer <api_key>

URL Parameters

Name
Type
Description

order

string

Order in which the list of channels should be returned. Can be created_at.

order_type

string

Order type. Can be either asc or desc.

page

number

Page for which you want to return channels.

per_page

number

Number of channels per page to return.

reference

number

Channel reference.

cURL

curl -G "https://api.sandbox.txn.io/api/public/v1/channels" \
     -H 'Content-Type: application/vnd.api+json' \
     -H 'Authorization: Bearer <api_key>' \
     --data-urlencode 'order=created_at' \
     --data-urlencode 'order_type=desc' \
     --data-urlencode 'per_page=50'

Response

Response Body

Name
Type
Description

data[].id

string

Channel ID.

data[].type

string

Always channels.

data[].attributes.targetCurrency

string

Specifies the merchant’s currency account on the txn platform to which the deposit will be credited. Must be a tradable fiat or cryptocurrency listed on the Supported currencies page — display fiat currencies are not accepted.

data[].attributes.localCurrency

string

Currency to display to end users, e.g. their local currency in which they hold a balance on the merchant’s platform. This field is optional and can be different from the targetCurrency value.

data[].attributes.payCurrency

string

Crypto currency that customer must pay in. Refer to supported currencies.

data[].attributes.address

string

Channel address.

data[].attributes.networkCode

string

Payment network code. Refer to supported networks.

data[].attributes.network

string

Alias for networkCode. Refer to supported networks.

data[].attributes.networkName

string

Network name.

data[].attributes.hostedPageUrl

string

Channel redirect URL hosted by Txn.

data[].attributes.reference

string

The custom reference ID to tie the channel and its deposits to end-user who pays.

data[].attributes.status

string

Channel status. Can be either enabled or disabled. If enabled, deposits get processed and credited to the merchant's account as normal. If disabled, deposits do not get credited to the merchant's account.

data[].attributes.createdAt

string

Timestamp when a channel was created.

data[].attributes.updatedAt

string

Timestamp when a channel was last updated.

meta.page

number

Current page number.

meta.per_page

number

Page size used for the response.

meta.total

number

Total number of channels matching the query.

data[].relationships.targetAccount

object

The account channel deposits are credited to. data.type is accounts and data.id is the account ID; the entity is returned in included[].

included[].type(accounts)

object

The target account (data[].relationships.targetAccount). Same fields as Reading account; the ones most relevant here are listed below.

included[].type(accounts).attributes.currencyCode

string

Account currency. Equals data[].attributes.targetCurrency.

included[].type(accounts).attributes.label

string

Account label.

included[].type(accounts).attributes.master

boolean

true for the master account, false for a subaccount.

included[].type(accounts).attributes.balance

string

Account balance at the time of the request.

included[].type(accounts).attributes.currencyType

string

fiat or crypto.

included[].type(accounts).relationships

object

company, networks and txnBankCredentials: not expanded (meta.included is false).

Last updated