Skip to main content
POST
/
v1
/
swap
/
create
Place a new order
curl --request POST \
  --url https://api.openxswitch.com/v1/swap/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "fromCurrency": "BTC",
  "toCurrency": "ETH",
  "amount": "<string>",
  "fromAddress": "0x1234abcd...",
  "userId": "<string>",
  "payload": "<string>",
  "fromNetwork": "<string>",
  "toNetwork": "<string>",
  "toTag": "<string>",
  "amountType": "<string>",
  "vpm": "<string>",
  "refundAddress": "<string>",
  "refundTag": "<string>"
}
'
{
  "statusCode": 404,
  "path": "/v1/...",
  "timestamp": "2025-03-13T12:34:56.789Z",
  "message": "Cannot GET /v1/..."
}

Documentation Index

Fetch the complete documentation index at: https://docs.openxswitch.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
fromCurrency
string
required

Currency being sent

Example:

"BTC"

toCurrency
string
required

Currency to receive

Example:

"ETH"

amount
string
required

Amount to send or receive

fromAddress
string
required

Address to receive funds

Example:

"0x1234abcd..."

userId
string
required

User ID

payload
string

Optional payload

fromNetwork
string

Blockchain network for sending

toNetwork
string

Blockchain network for receiving

toTag
string

Tag associated with the receiving address

amountType
string

Specifies if amount is fixed or variable

vpm
string

Virtual Payment Machine (VPM) information

refundAddress
string

Address for refunds

refundTag
string

Tag associated with the refund address

Response

Order placed successfully.