Connect Exchange
POST
/api/v1/exchange-accounts
const url = 'https://api.qeychain.xyz/api/v1/exchange-accounts';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"provider":"example","api_key":"example","api_secret":"example","is_cdp":false,"nickname":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.qeychain.xyz/api/v1/exchange-accounts \ --header 'Content-Type: application/json' \ --data '{ "provider": "example", "api_key": "example", "api_secret": "example", "is_cdp": false, "nickname": "example" }'Connect a centralized exchange account.
Validates API credentials against the exchange, then stores them encrypted (Azure Key Vault or Fernet fallback).
Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”request
Request
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
ConnectExchangeRequest
Request body for connecting an exchange account.
object
provider
required
Provider
Exchange provider: coinbase, gemini, kraken, robinhood
string
api_key
required
Api Key
Exchange API key
string
api_secret
required
Api Secret
Exchange API secret (or Ed25519 private key for Robinhood)
string
is_cdp
Is Cdp
True if using Coinbase CDP API key format (Ed25519/JWT)
boolean
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
Examplegenerated
exampleValidation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example" } ]}