Skip to content

DeFi Service API (v2026_01_14)

API for the DeFi Service

Download OpenAPI description
Languages
Servers
Mock server

https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/

Local server

http://localhost:7072/

Request

Returns balances for all wallets associated with the authenticated user

Security
bearerAuth
Query
evmboolean

Include EVM chain balances

Default false
curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/balances?evm=false' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

A list of balances

Bodyapplication/json
balancesArray of objects(Balance)
Response
application/json
{ "balances": [ { … } ] }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
chainstringrequired
base_assetstringrequired
quote_assetstringrequired
order_sidestringrequired
Enum"buy""sell"
qtystringrequired
curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/quote \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "chain": "string",
    "base_asset": "string",
    "quote_asset": "string",
    "order_side": "buy",
    "qty": "string"
  }'

Responses

A quote response

Bodyapplication/json
quote_idstring
base_assetstring
quote_assetstring
order_sidestring
amountstring
feestring
payloadsArray of objects(UnsignedPayload)
issuesArray of strings
Response
application/json
{ "quote_id": "string", "base_asset": "string", "quote_asset": "string", "order_side": "string", "amount": "string", "fee": "string", "payloads": [ { … } ], "issues": [ "string" ] }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
signed_payloadsArray of objects(StampedAction)non-emptyrequired
signed_payloads[].​payloadstringrequired

The unsigned payload to execute

signed_payloads[].​signaturestringrequired

The cryptographic signature for the payload

signed_payloads[].​auth_typestringrequired

The authentication type used for signing

Enum"web_authn""api_key"
curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/trade \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "signed_payloads": [
      {
        "payload": "string",
        "signature": "string",
        "auth_type": "web_authn"
      }
    ]
  }'

Responses

The trade response

Bodyapplication/json
order_idstring(uuid)
Response
application/json
{ "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe" }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
chainstringrequired

Blockchain chain (e.g., solana, base)

assetstringrequired

Asset contract address

tostringrequired

Recipient address

qtystringrequired

Transfer quantity

qty_unitstringrequired

Unit of quantity (base for token amount, quote for USD)

Enum"base""quote"
curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/transfer/prepare \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "chain": "string",
    "asset": "string",
    "to": "string",
    "qty": "string",
    "qty_unit": "base"
  }'

Responses

The transfer prepare response

Bodyapplication/json
transfer_idstring(uuid)
payloadsArray of objects(UnsignedPayload)
Response
application/json
{ "transfer_id": "d4a2d8dd-7def-4545-a062-761683b9aa05", "payloads": [ { … } ] }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
transfer_idstring(uuid)required
signaturesArray of stringsrequired
auth_typestringrequired

The authentication type used for signing

Enum"web_authn""api_key"
curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/transfer/execute \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "transfer_id": "d4a2d8dd-7def-4545-a062-761683b9aa05",
    "signatures": [
      "string"
    ],
    "auth_type": "web_authn"
  }'

Responses

The transfer execute response

Bodyapplication/json
tx_hashstring
chainstring
assetstring
fromstring
tostring
sentstring
feestring
receivedstring
Response
application/json
{ "tx_hash": "string", "chain": "string", "asset": "string", "from": "string", "to": "string", "sent": "string", "fee": "string", "received": "string" }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
passkeyobject

Passkey authentication data (for passkey wallets)

api_keyobject

API key data (for API key wallets)

curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/create-wallet \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "passkey": {
      "challenge": "string",
      "credential_id": "string",
      "client_data": "string",
      "attestation": "string"
    },
    "api_key": {
      "public_key": "string"
    }
  }'

Responses

Wallet created successfully

Bodyapplication/json
walletsArray of objects

Detailed wallet information

Response
application/json
{ "wallets": [ { … } ] }

Request

Security
bearerAuth
Bodyapplication/jsonrequired
addressstringrequired

Wallet address to export

target_public_keystringrequired

Client-side public key that will receive the encrypted bundle

curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/wallet/export/prepare \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "address": "string",
    "target_public_key": "string"
  }'

Responses

Export payload created successfully

Bodyapplication/json
payloadstring

Turnkey payload clients must sign to authorize export

Response
application/json
{ "payload": "string" }

Execute a wallet private key export

Request

Security
bearerAuth
Bodyapplication/jsonrequired
addressstringrequired

Wallet address to export

target_public_keystringrequired

Client-side public key that will receive the encrypted bundle

payloadstringrequired

Signed Turnkey activity payload authorizing the export

curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/wallet/export/execute \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "address": "string",
    "target_public_key": "string",
    "payload": "string"
  }'

Responses

Export bundle created successfully

Bodyapplication/json
export_bundlestring

Encrypted export bundle

Response
application/json
{ "export_bundle": "string" }

Get the authenticated user profile

Request

Security
bearerAuth
curl -i -X GET \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/profile/me \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

The authenticated user profile

Bodyapplication/json
idstring
emailstring(email)
walletsArray of objects(Wallet)
Response
application/json
{ "id": "string", "email": "user@example.com", "wallets": [ { … } ] }

Request

Query
evmboolean

Include EVM chain assets

Default false
curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/assets?evm=false'

Responses

A list of active assets

Bodyapplication/jsonArray [
idstring(uuid)
chainstring
addressstring
symbolstring
namestring
slugstring
decimalsinteger
descriptionstring
websitestring
iconstring or null
is_activeboolean
tradeableboolean
stableboolean
imageobject(AssetImage)
market_dataobject(AssetMarketData)
socialsobject(AssetSocials)
]
Response
application/json
[ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "chain": "string", "address": "string", "symbol": "string", "name": "string", "slug": "string", "decimals": 0, "description": "string", "website": "string", "icon": "string", "is_active": true, "tradeable": true, "stable": true, "image": { … }, "market_data": { … }, "socials": { … } } ]

Request

Path
chainstringrequired

Blockchain chain

addressstringrequired

Asset contract address

curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/asset/{chain}/{address}'

Responses

Asset details

Bodyapplication/json
idstring(uuid)
chainstring
addressstring
symbolstring
namestring
slugstring
decimalsinteger
descriptionstring
websitestring
iconstring or null
is_activeboolean
tradeableboolean
stableboolean
imageobject(AssetImage)
market_dataobject(AssetMarketData)
socialsobject(AssetSocials)
Response
application/json
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "chain": "string", "address": "string", "symbol": "string", "name": "string", "slug": "string", "decimals": 0, "description": "string", "website": "string", "icon": "string", "is_active": true, "tradeable": true, "stable": true, "image": { "thumb": "string", "small": "string", "large": "string" }, "market_data": { "circulating_supply": 0, "total_supply": 0, "max_supply": 0 }, "socials": { "x_username": "string", "facebook_username": "string", "subreddit_url": "string", "official_forum_url": "string" } }

Request

Returns all global/public watchlists.

curl -i -X GET \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/watchlists

Responses

A list of watchlists

Bodyapplication/jsonArray [
idstring(uuid)

Unique identifier for the watchlist

user_idstring or null(uuid)

User ID if this is a user-specific watchlist, null for global watchlists

titlestring

Watchlist title

descriptionstring or null

Watchlist description

]
Response
application/json
[ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5", "title": "string", "description": "string" } ]

Request

Returns a specific global/public watchlist with all its assets.

Path
idstring(uuid)required

Watchlist UUID

curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/watchlists/{id}'

Responses

Watchlist with assets

Bodyapplication/json
idstring(uuid)

Unique identifier for the watchlist

user_idstring or null(uuid)

User ID if this is a user-specific watchlist, null for global watchlists

titlestring

Watchlist title

descriptionstring or null

Watchlist description

assetsArray of objects(WatchlistAsset)

List of assets in this watchlist

Response
application/json
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5", "title": "string", "description": "string", "assets": [ { … } ] }

Request

Returns a unified view of all user transactions including trades, transfers, and onramps

Security
bearerAuth
Query
limitinteger[ 1 .. 100 ]

Maximum number of transactions to return

Default 50
cursorstring(date-time)

RFC3339 timestamp cursor for pagination

curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/history?limit=50&cursor=2019-08-24T14%3A15%3A22Z' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Transaction history retrieved successfully

Bodyapplication/json
itemsArray of objects(HistoryEntry)
next_cursorstring or null(date-time)

RFC3339 timestamp cursor for pagination

Response
application/json
{ "items": [ { … } ], "next_cursor": "2019-08-24T14:15:22Z" }

Request

Initiates a Coinbase onramp flow for purchasing crypto with fiat

Security
bearerAuth
Bodyapplication/jsonrequired
chainstringrequired

The blockchain to onramp to (e.g., "solana", "base")

Enum"solana""base"
amountstringrequired

The amount to purchase in USD

payment_methodstringrequired

The payment method to use

curl -i -X POST \
  https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/onramp \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "chain": "solana",
    "amount": "string",
    "payment_method": "string"
  }'

Responses

Onramp transaction created successfully

Bodyapplication/json
urlstring

The Coinbase onramp URL to redirect the user to

tx_idstring

The transaction ID for tracking

Response
application/json
{ "url": "string", "tx_id": "string" }

Request

Returns the status of a specific onramp transaction

Security
bearerAuth
Path
idstringrequired

Transaction ID

curl -i -X GET \
  'https://docs.truemarkets.co/_mock/apis/defi/v2026_01_14/v1/defi/core/onramp/transactions/{id}/status' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Transaction status

Bodyapplication/json
tx_statusstring

The current status of the onramp transaction

Response
application/json
{ "tx_status": "string" }