Send All Assets

Creates a send-all withdrawal order that sends the customer's entire available balance of a given asset to an external wallet address.

Creates a send-all withdrawal order that sends the customer's entire available balance of a given asset to an external wallet address.

📘

Send-all orders have no amount field

The entire available balance of the specified assetId is sent. To send a specific amount instead, see Sending Specified Amount.

Endpoint

EnvironmentURL
ProductionPOST https://caas.coinme.com/services/send-all
StagingPOST https://caas-staging.coinme.com/services/send-all

Headers

HeaderRequiredDescription
AuthorizationYesBearer token issued to the Partner. The Partner identifier is derived from this JWT.
Content-TypeYesapplication/json

Request Body

FieldTypeRequiredDescription
customerIdstringYesCoinme customer ID of the sender.
destinationWalletAddressstringYesDestination blockchain wallet address.
assetIdstringYesAsset + chain whose full balance will be sent (e.g. usdc_eth, btc).
partnerTransactionIdstringNoIdempotency key / Partner reference. Auto-generated by the system if omitted.
blockchainTagstringNoDestination tag/memo for chains that require it (e.g. XRP, XLM).
notestringNoFree-text note attached to the order.
📘

Use partnerTransactionId for idempotency and reconciliation

Supplying your own partnerTransactionId lets you safely retry requests and match the order back to your records. If omitted, the system generates one and returns it in the response.

Sample API Request

curl -X POST 'https://caas-staging.coinme.com/services/send-all' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
    "customerId": "cust_12345",
    "destinationWalletAddress": "0xAbC1234...eF90",
    "assetId": "usdc_eth",
    "partnerTransactionId": "partner-ref-001",
    "blockchainTag": null,
    "note": "monthly sweep"
  }'

Sample API Response

The response uses the standard CaaS envelope: on success, data is populated and errorResponse is null; on failure, data is null and errorResponse is populated.

{
  "data": {
    "partnerTransactionId": "partner-ref-001"
  },
  "errorResponse": null
}
{
  "data": null,
  "errorResponse": {
    "timestamp": "2026-06-29T12:34:56Z",
    "httpStatus": 400,
    "path": "/services/send-all",
    "errorData": [
      {
        "errorCode": "FIELD_NULL",
        "message": "Field assetId cannot be null or empty"
      }
    ]
  }
}

Response Fields

FieldTypeDescription
data.partnerTransactionIdstringPartner transaction ID assigned to the created send-all order. Matches the value supplied in the request, or a system-generated value if one was not provided.
errorResponseobject | nullError envelope (CaasErrorResponse). null on success.

Error Response Fields

FieldTypeDescription
errorResponse.timestampstringUTC timestamp of the error.
errorResponse.httpStatusintegerHTTP status code of the failure.
errorResponse.pathstringRequest path that produced the error.
errorResponse.errorDataarrayOne or more error entries.
errorResponse.errorData[].errorCodestringMachine-readable error code (e.g. FIELD_NULL).
errorResponse.errorData[].messagestringHuman-readable description of the error.

Tracking the Send Result

Creating the order returns immediately with the partnerTransactionId; the send itself completes asynchronously. A webhook notification of type SEND is delivered when the order completes, indicating whether it succeeded or failed. See Webhook Notifications for the notification payload and delivery details.


Did this page help you?