curl --request GET \
--url https://api.tetrafi.io/api/v1/orders \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tetrafi.io/api/v1/orders"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.tetrafi.io/api/v1/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tetrafi.io/api/v1/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tetrafi.io/api/v1/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tetrafi.io/api/v1/orders")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tetrafi.io/api/v1/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"deliverTo": {
"accountKind": "venueAccount",
"displayName": "<string>",
"financialAccountId": "<string>",
"isDefault": true,
"kind": "financialAccount",
"network": "eip155:8453"
},
"fundingAccount": {
"financialAccountId": "<string>",
"kind": "venueAccount",
"linkId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"fundingModel": "prefunded",
"settlement": {
"method": "venueLedger",
"timing": "immediate",
"window": {
"cadence": {
"dayBasis": "calendarDays",
"kind": "intraday",
"everyHours": 1,
"localTimes": [
"<string>"
]
},
"scheduleId": "<string>",
"scheduleLabel": "<string>",
"scheduleVersion": 123,
"snapshotAt": "2023-11-07T05:31:56Z",
"windowId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"assumedBoundary": {
"lpName": "<string>",
"source": "<string>",
"timeZone": "<string>"
},
"cutoffAt": "2023-11-07T05:31:56Z",
"paymentDeadlineAt": "2023-11-07T05:31:56Z",
"settlementBasis": "clock",
"settlesBy": "2023-11-07T05:31:56Z",
"statementIssuer": "<string>"
}
},
"tradingSource": {
"financialAccountId": "<string>",
"kind": "venueAccount",
"venueEnablementId": "<string>"
},
"fees": [
{
"amount": "<string>",
"asset": "<string>",
"includedInPrice": true,
"kind": "trading",
"chain": "<string>"
}
],
"fills": [
{
"amount": "<string>",
"at": "2023-11-07T05:31:56Z",
"price": {
"amount": "<string>",
"base": "<string>",
"quote": "<string>"
},
"sellAmount": "<string>",
"venue": {
"id": "<string>",
"name": "<string>"
},
"network": "<string>",
"txHash": "<string>"
}
],
"quotedBuyAmount": "<string>",
"settledBuyAmount": "<string>",
"settlesBy": "2023-11-07T05:31:56Z",
"unrecordedFees": [
"trading"
],
"order": {
"createdAt": "2023-11-07T05:31:56Z",
"orderId": "<string>",
"orderType": "<string>",
"settlement": {
"data": "<unknown>",
"type": "escrow"
},
"status": "created",
"terminal": true,
"updatedAt": "2023-11-07T05:31:56Z",
"bondReservation": {
"amount": "<string>",
"status": "pending",
"assetSymbol": "<string>",
"chainId": 1,
"decimals": 1,
"paidAmount": "<string>",
"reason": "crossVmCarrier",
"txHash": "<string>"
},
"compliance": {
"checks": [
{
"enforced": true,
"group": "applied",
"groupReason": "<string>",
"id": "<string>",
"label": "<string>",
"layer": "onChain",
"runMode": "enforce",
"source": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"verdict": "pass",
"chainId": 1,
"contractAddress": "<string>",
"details": "<string>",
"evidence": "<unknown>",
"latencyMs": 123,
"missingInput": "<string>",
"reasonCode": "<string>",
"runModeReason": "<string>",
"txHash": "<string>"
}
],
"travelRule": {
"required": true,
"status": "<string>",
"transmitted": true
},
"verdict": "pass",
"attestation": {
"onChainAttested": true,
"expiresAt": "2023-11-07T05:31:56Z",
"jurisdiction": "<string>",
"onChainTxHash": "<string>",
"tier": 123,
"vendorHash": "<string>"
},
"corridor": "<string>",
"denial": {
"code": "<string>",
"remedy": "verifyIdentity",
"withheld": true,
"fields": [
"<string>"
]
},
"denialReason": "<string>",
"evaluatedAt": "2023-11-07T05:31:56Z",
"notionalUsd": 123,
"onChainPolicy": {
"openRuns": 1,
"runs": [
{
"chainId": 1,
"enforced": true,
"engineAddress": "<string>",
"gate": {
"gate": "enforced",
"policies": 1
},
"selector": "<string>",
"targetAddress": "<string>",
"transactionHash": "<string>",
"blockNumber": 1,
"blockTime": "2023-11-07T05:31:56Z"
}
],
"state": "policyRun",
"unknownRuns": 1
},
"scope": "full",
"walletIdentity": {
"address": "<string>",
"method": "<string>",
"chainFamily": "<string>",
"linkedAt": "2023-11-07T05:31:56Z"
}
},
"continuationPlan": {
"legs": [
{
"legIndex": 1,
"mode": "atomic",
"slippageBps": 1,
"delegation": {
"grantId": "<string>",
"status": "preparing",
"refusal": "GRANT_NOT_FOUND"
},
"etaSeconds": 1,
"minimumOutput": "<string>",
"onFailure": {
"funds": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"holder": "yourWallet",
"address": "<string>"
},
"referenceOutput": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
}
]
},
"custodySigningError": "<string>",
"custodySigningStatus": "<string>",
"custodyVaultAddress": "<string>",
"deliveredBuy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"deliveredBuyProvenance": "<string>",
"directUserId": "<string>",
"executionDeadlineAt": "2023-11-07T05:31:56Z",
"executionDeadlineKind": "<string>",
"failure": {
"code": "<string>",
"message": "<string>",
"phase": "prepare",
"recoveryStopped": true
},
"feeOutputs": [
{
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
],
"feeUsd": 123,
"fillTransaction": "<unknown>",
"filledAt": "2023-11-07T05:31:56Z",
"legAttempts": {},
"legs": [
{
"buy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"index": 1,
"kind": "<string>",
"label": "<string>",
"sell": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"status": "<string>",
"counterparty": {
"counterpartyType": "<string>",
"jurisdiction": "<string>",
"kybStatus": "<string>",
"licences": [
{
"jurisdiction": "<string>",
"licenceType": "<string>",
"status": "<string>",
"expiresAt": "2023-11-07T05:31:56Z"
}
],
"provenance": "kybVerified"
},
"destChainId": 1,
"etaSeconds": 1,
"externalRefs": [
{
"kind": "<string>",
"value": "<string>",
"url": "<string>"
}
],
"feeUsd": 123,
"measuredBuy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"measuredBuySource": "<string>",
"product": "<string>",
"provider": "<string>",
"sourceChainId": 1,
"tradeLeg": {
"direction": "pay_in",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"settlementRail": "bank",
"state": "planned",
"boundLapsesAt": "2023-11-07T05:31:56Z",
"confirmAgainReason": "priceBeyondBound",
"consentedPayoutFee": "<string>",
"creditedAmount": "<string>",
"currentPayoutFee": "<string>",
"declaredPayoutFee": "<string>",
"destination": {
"kind": "wallet",
"ref": "<string>",
"approvalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"expectedArrivalAt": "2023-11-07T05:31:56Z",
"expectedArrivalSource": "<string>",
"finality": "final",
"fundingDeadlineAt": "2023-11-07T05:31:56Z",
"fundingModel": "prefunded",
"fundsReceivedAt": "2023-11-07T05:31:56Z",
"holidaysApplied": true,
"outcomeCode": "<string>",
"overdueAt": "2023-11-07T05:31:56Z",
"overdueSince": "2023-11-07T05:31:56Z",
"ownBankVerification": {
"source": "revolutBusiness",
"state": "verified",
"credit": {
"amount": "<string>",
"creditedAt": "2023-11-07T05:31:56Z",
"currency": "<string>",
"referenceMasked": "<string>"
},
"lastGoodReadAt": "2023-11-07T05:31:56Z",
"matchedBy": "referenceAndAmount",
"reason": "<string>",
"reviewItemId": "<string>"
},
"payoutApproval": {
"approvalsRequired": 1,
"approverNames": [
"<string>"
],
"approvalRequestId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"approverGroup": "<string>",
"approverGroupName": "<string>",
"runId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"payoutBreakdown": {
"basis": "consent",
"fee": "<string>",
"receivedMax": "<string>",
"receivedMin": "<string>",
"withdrawn": "<string>",
"charging": "deducted"
},
"payoutBreakdownUnavailableReason": "<string>",
"payoutHeldReason": "<string>",
"quotedExpectedArrivalAt": "2023-11-07T05:31:56Z",
"rail": "<string>",
"railOption": "standard",
"railReference": {
"state": "not_reported_yet"
},
"recipientConfirmation": {
"confirmationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirmedAt": "2023-11-07T05:31:56Z",
"confirmedBy": "<string>",
"confirmedByName": "<string>",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"returnWindowEndsAt": "2023-11-07T05:31:56Z",
"returnedAfterSettlement": {
"detectedAt": "2023-11-07T05:31:56Z",
"reviewItemId": "<string>"
},
"returnedTo": "lpAccount",
"reviewAt": "2023-11-07T05:31:56Z",
"reviewEnteredAt": "2023-11-07T05:31:56Z",
"reviewItemId": "<string>",
"reviewReason": "uncertain_send",
"submittedAt": "2023-11-07T05:31:56Z",
"transactionHash": "<string>",
"venueReportedCredited": true,
"venueWithdrawalId": "<string>"
},
"transactions": [
{
"actor": "user",
"chainId": 1,
"chainRole": "origin",
"hash": "<string>",
"stage": "prepare",
"status": "pending",
"explorerUrl": "<string>",
"label": "<string>",
"legIndex": 1,
"timestamp": 1
}
],
"venueRouteId": "<string>"
}
],
"lifecycleStatus": {
"bucket": "inProgress",
"flowKind": "<string>",
"isTerminal": true,
"primary": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"rank": 1,
"rawStatus": "<string>",
"execution": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"rawDeferredStatus": "<string>",
"settlement": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"withdrawal": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
}
},
"linkedWalletId": "<string>",
"nextAction": {
"kind": "payoutFeeRose",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"nextActions": [
{
"purpose": "tokenApproval",
"type": "authorizeWallet",
"actor": "userWallet",
"after": [
"waitForTransactionMined"
],
"chain": {
"namespace": "eip155",
"reference": "<string>"
},
"chainId": 1,
"details": "<unknown>",
"frequency": "perTrade",
"sourceAuthorizationMessage": {
"deadline": 1,
"encoding": "base64",
"message": "<string>",
"nonce": "<string>",
"scheme": "svmSourcePermit",
"signer": "<string>"
},
"submitTo": "<string>",
"transaction": {
"data": "<string>",
"kind": "evm",
"to": "<string>",
"value": "<string>"
},
"tx": {
"data": "<string>",
"to": "<string>",
"value": "<string>"
},
"typedData": "<unknown>",
"walletAuthorization": {
"authorizationKind": "turnkeyOwnerProof",
"authorizationPayload": "<unknown>",
"expiresAt": "2023-11-07T05:31:56Z",
"provider": "privy",
"signingDigest": "<string>",
"walletId": "<string>",
"authorizationId": "<string>",
"providerBody": "<string>",
"requestExpiryMs": 123
}
}
],
"nextActor": "taker",
"orderKind": "<string>",
"pairQuoteId": "<string>",
"quoteId": "<string>",
"realizedSlippageBps": 123,
"recipientAddress": "<string>",
"reporting": {
"legs": [
{
"counterparty": {
"name": "<string>",
"status": "connected",
"workspaceId": "<string>"
},
"legId": "<string>",
"provider": "<string>",
"limitation": "<string>",
"reportingInstitution": {
"name": "<string>",
"status": "connected",
"workspaceId": "<string>"
}
}
],
"transfers": [
{
"createdAt": "2023-11-07T05:31:56Z",
"dataStatus": "<string>",
"id": "<string>",
"orderId": "<string>",
"state": "<string>",
"transmissionStatus": "<string>",
"viewerRole": "<string>",
"escalatedAt": "2023-11-07T05:31:56Z",
"lastError": "<string>",
"nextRetryAt": "2023-11-07T05:31:56Z",
"piiSubmittedAt": "2023-11-07T05:31:56Z",
"providerCheckedAt": "2023-11-07T05:31:56Z",
"providerStatus": "<string>",
"providerTransferId": "<string>",
"receivingVaspDid": "<string>",
"reportingWorkspaceId": "<string>",
"sendingVaspDid": "<string>"
}
]
},
"route": {
"buy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"sell": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
},
"senderAddress": "<string>",
"settledAt": "2023-11-07T05:31:56Z",
"settlementSpeedMs": 123,
"slippageToleranceBps": 123,
"stuckSince": "2023-11-07T05:31:56Z",
"substatus": "<string>",
"substatusCode": "<string>",
"substatusMessage": "<string>",
"timing": {
"observedAt": "2023-11-07T05:31:56Z",
"revision": "<string>",
"stages": [
{
"clockState": "<string>",
"context": "<string>",
"estimateKind": "<string>",
"key": "<string>",
"operation": "<string>",
"elapsedSeconds": 123,
"endedAt": "2023-11-07T05:31:56Z",
"expectedSeconds": 1,
"legIndex": 1,
"startedAt": "2023-11-07T05:31:56Z",
"waitingSince": "2023-11-07T05:31:56Z"
}
]
},
"transactions": [
{
"actor": "user",
"chainId": 1,
"chainRole": "origin",
"hash": "<string>",
"stage": "prepare",
"status": "pending",
"explorerUrl": "<string>",
"label": "<string>",
"legIndex": 1,
"timestamp": 1
}
],
"venueRouteId": "<string>",
"viewer": {
"recordsScope": "full",
"submittedByYou": true
},
"workspaceId": "<string>"
},
"orderId": "<string>",
"status": "pending",
"statusUrl": "<string>",
"terminal": true,
"kind": "advancedTrade",
"creditCheck": {
"activeHolds": "<string>",
"available": "<string>",
"availableSigned": "<string>",
"checkedAt": "2023-11-07T05:31:56Z",
"creditPortion": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"decision": "<string>",
"effectiveLimit": "<string>",
"exposureDelta": "<string>",
"exposureReducing": true,
"localHeadroom": "<string>",
"lpAvailable": "<string>",
"maxAgeMs": 1,
"observationAgeMs": 1,
"observationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"projectedUsed": "<string>",
"source": "<string>",
"termsVersion": 123,
"used": "<string>",
"valuationMaxAgeMs": 1,
"venueAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"journalVersion": "<string>",
"overLimitBy": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"positionsBasis": "<string>",
"zeroAssets": [
"<string>"
]
},
"creditPortion": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"creditReservation": {
"debitAsset": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"exposureAmount": "<string>",
"exposureCurrency": "<string>",
"inputAmount": "<string>",
"positiveInputAmount": "<string>",
"reservationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"state": "<string>",
"operationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"payIn": {
"afterPayBy": {
"action": "returned",
"source": "<string>"
},
"payBy": {
"clock": "payment_started",
"seconds": 1
},
"settlementGrace": {
"kind": "no_grace"
}
},
"next": {
"kind": "order"
},
"quoteId": "<string>",
"requestId": "<string>"
}
],
"scanLimitReached": true,
"nextCursor": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}List the active workspace's Basic and Advanced orders in newest-first order.
Lists Basic and Advanced orders using the same envelope as GET /orders/. Requires orders_read on an API key, or ViewOrders/PlaceOrder on a session. Newest first by created time and id. A status filter is applied to stored order facts first and then to each order’s canonical public status; a filtered page keeps reading until it holds limit items or the orders end, within a bounded scan. A page shorter than limit carries a nextCursor only when that scan reached its limit, and then says so with scanLimitReached: follow nextCursor until null. A cursor is bound to the caller, workspace and exact filters; a malformed, foreign or deleted anchor is INVALID_CURSOR.
curl --request GET \
--url https://api.tetrafi.io/api/v1/orders \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.tetrafi.io/api/v1/orders"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.tetrafi.io/api/v1/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tetrafi.io/api/v1/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tetrafi.io/api/v1/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tetrafi.io/api/v1/orders")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tetrafi.io/api/v1/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"items": [
{
"deliverTo": {
"accountKind": "venueAccount",
"displayName": "<string>",
"financialAccountId": "<string>",
"isDefault": true,
"kind": "financialAccount",
"network": "eip155:8453"
},
"fundingAccount": {
"financialAccountId": "<string>",
"kind": "venueAccount",
"linkId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"fundingModel": "prefunded",
"settlement": {
"method": "venueLedger",
"timing": "immediate",
"window": {
"cadence": {
"dayBasis": "calendarDays",
"kind": "intraday",
"everyHours": 1,
"localTimes": [
"<string>"
]
},
"scheduleId": "<string>",
"scheduleLabel": "<string>",
"scheduleVersion": 123,
"snapshotAt": "2023-11-07T05:31:56Z",
"windowId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"assumedBoundary": {
"lpName": "<string>",
"source": "<string>",
"timeZone": "<string>"
},
"cutoffAt": "2023-11-07T05:31:56Z",
"paymentDeadlineAt": "2023-11-07T05:31:56Z",
"settlementBasis": "clock",
"settlesBy": "2023-11-07T05:31:56Z",
"statementIssuer": "<string>"
}
},
"tradingSource": {
"financialAccountId": "<string>",
"kind": "venueAccount",
"venueEnablementId": "<string>"
},
"fees": [
{
"amount": "<string>",
"asset": "<string>",
"includedInPrice": true,
"kind": "trading",
"chain": "<string>"
}
],
"fills": [
{
"amount": "<string>",
"at": "2023-11-07T05:31:56Z",
"price": {
"amount": "<string>",
"base": "<string>",
"quote": "<string>"
},
"sellAmount": "<string>",
"venue": {
"id": "<string>",
"name": "<string>"
},
"network": "<string>",
"txHash": "<string>"
}
],
"quotedBuyAmount": "<string>",
"settledBuyAmount": "<string>",
"settlesBy": "2023-11-07T05:31:56Z",
"unrecordedFees": [
"trading"
],
"order": {
"createdAt": "2023-11-07T05:31:56Z",
"orderId": "<string>",
"orderType": "<string>",
"settlement": {
"data": "<unknown>",
"type": "escrow"
},
"status": "created",
"terminal": true,
"updatedAt": "2023-11-07T05:31:56Z",
"bondReservation": {
"amount": "<string>",
"status": "pending",
"assetSymbol": "<string>",
"chainId": 1,
"decimals": 1,
"paidAmount": "<string>",
"reason": "crossVmCarrier",
"txHash": "<string>"
},
"compliance": {
"checks": [
{
"enforced": true,
"group": "applied",
"groupReason": "<string>",
"id": "<string>",
"label": "<string>",
"layer": "onChain",
"runMode": "enforce",
"source": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"verdict": "pass",
"chainId": 1,
"contractAddress": "<string>",
"details": "<string>",
"evidence": "<unknown>",
"latencyMs": 123,
"missingInput": "<string>",
"reasonCode": "<string>",
"runModeReason": "<string>",
"txHash": "<string>"
}
],
"travelRule": {
"required": true,
"status": "<string>",
"transmitted": true
},
"verdict": "pass",
"attestation": {
"onChainAttested": true,
"expiresAt": "2023-11-07T05:31:56Z",
"jurisdiction": "<string>",
"onChainTxHash": "<string>",
"tier": 123,
"vendorHash": "<string>"
},
"corridor": "<string>",
"denial": {
"code": "<string>",
"remedy": "verifyIdentity",
"withheld": true,
"fields": [
"<string>"
]
},
"denialReason": "<string>",
"evaluatedAt": "2023-11-07T05:31:56Z",
"notionalUsd": 123,
"onChainPolicy": {
"openRuns": 1,
"runs": [
{
"chainId": 1,
"enforced": true,
"engineAddress": "<string>",
"gate": {
"gate": "enforced",
"policies": 1
},
"selector": "<string>",
"targetAddress": "<string>",
"transactionHash": "<string>",
"blockNumber": 1,
"blockTime": "2023-11-07T05:31:56Z"
}
],
"state": "policyRun",
"unknownRuns": 1
},
"scope": "full",
"walletIdentity": {
"address": "<string>",
"method": "<string>",
"chainFamily": "<string>",
"linkedAt": "2023-11-07T05:31:56Z"
}
},
"continuationPlan": {
"legs": [
{
"legIndex": 1,
"mode": "atomic",
"slippageBps": 1,
"delegation": {
"grantId": "<string>",
"status": "preparing",
"refusal": "GRANT_NOT_FOUND"
},
"etaSeconds": 1,
"minimumOutput": "<string>",
"onFailure": {
"funds": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"holder": "yourWallet",
"address": "<string>"
},
"referenceOutput": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
}
]
},
"custodySigningError": "<string>",
"custodySigningStatus": "<string>",
"custodyVaultAddress": "<string>",
"deliveredBuy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"deliveredBuyProvenance": "<string>",
"directUserId": "<string>",
"executionDeadlineAt": "2023-11-07T05:31:56Z",
"executionDeadlineKind": "<string>",
"failure": {
"code": "<string>",
"message": "<string>",
"phase": "prepare",
"recoveryStopped": true
},
"feeOutputs": [
{
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
],
"feeUsd": 123,
"fillTransaction": "<unknown>",
"filledAt": "2023-11-07T05:31:56Z",
"legAttempts": {},
"legs": [
{
"buy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"index": 1,
"kind": "<string>",
"label": "<string>",
"sell": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"status": "<string>",
"counterparty": {
"counterpartyType": "<string>",
"jurisdiction": "<string>",
"kybStatus": "<string>",
"licences": [
{
"jurisdiction": "<string>",
"licenceType": "<string>",
"status": "<string>",
"expiresAt": "2023-11-07T05:31:56Z"
}
],
"provenance": "kybVerified"
},
"destChainId": 1,
"etaSeconds": 1,
"externalRefs": [
{
"kind": "<string>",
"value": "<string>",
"url": "<string>"
}
],
"feeUsd": 123,
"measuredBuy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"measuredBuySource": "<string>",
"product": "<string>",
"provider": "<string>",
"sourceChainId": 1,
"tradeLeg": {
"direction": "pay_in",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"settlementRail": "bank",
"state": "planned",
"boundLapsesAt": "2023-11-07T05:31:56Z",
"confirmAgainReason": "priceBeyondBound",
"consentedPayoutFee": "<string>",
"creditedAmount": "<string>",
"currentPayoutFee": "<string>",
"declaredPayoutFee": "<string>",
"destination": {
"kind": "wallet",
"ref": "<string>",
"approvalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"expectedArrivalAt": "2023-11-07T05:31:56Z",
"expectedArrivalSource": "<string>",
"finality": "final",
"fundingDeadlineAt": "2023-11-07T05:31:56Z",
"fundingModel": "prefunded",
"fundsReceivedAt": "2023-11-07T05:31:56Z",
"holidaysApplied": true,
"outcomeCode": "<string>",
"overdueAt": "2023-11-07T05:31:56Z",
"overdueSince": "2023-11-07T05:31:56Z",
"ownBankVerification": {
"source": "revolutBusiness",
"state": "verified",
"credit": {
"amount": "<string>",
"creditedAt": "2023-11-07T05:31:56Z",
"currency": "<string>",
"referenceMasked": "<string>"
},
"lastGoodReadAt": "2023-11-07T05:31:56Z",
"matchedBy": "referenceAndAmount",
"reason": "<string>",
"reviewItemId": "<string>"
},
"payoutApproval": {
"approvalsRequired": 1,
"approverNames": [
"<string>"
],
"approvalRequestId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"approverGroup": "<string>",
"approverGroupName": "<string>",
"runId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"payoutBreakdown": {
"basis": "consent",
"fee": "<string>",
"receivedMax": "<string>",
"receivedMin": "<string>",
"withdrawn": "<string>",
"charging": "deducted"
},
"payoutBreakdownUnavailableReason": "<string>",
"payoutHeldReason": "<string>",
"quotedExpectedArrivalAt": "2023-11-07T05:31:56Z",
"rail": "<string>",
"railOption": "standard",
"railReference": {
"state": "not_reported_yet"
},
"recipientConfirmation": {
"confirmationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"confirmedAt": "2023-11-07T05:31:56Z",
"confirmedBy": "<string>",
"confirmedByName": "<string>",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"returnWindowEndsAt": "2023-11-07T05:31:56Z",
"returnedAfterSettlement": {
"detectedAt": "2023-11-07T05:31:56Z",
"reviewItemId": "<string>"
},
"returnedTo": "lpAccount",
"reviewAt": "2023-11-07T05:31:56Z",
"reviewEnteredAt": "2023-11-07T05:31:56Z",
"reviewItemId": "<string>",
"reviewReason": "uncertain_send",
"submittedAt": "2023-11-07T05:31:56Z",
"transactionHash": "<string>",
"venueReportedCredited": true,
"venueWithdrawalId": "<string>"
},
"transactions": [
{
"actor": "user",
"chainId": 1,
"chainRole": "origin",
"hash": "<string>",
"stage": "prepare",
"status": "pending",
"explorerUrl": "<string>",
"label": "<string>",
"legIndex": 1,
"timestamp": 1
}
],
"venueRouteId": "<string>"
}
],
"lifecycleStatus": {
"bucket": "inProgress",
"flowKind": "<string>",
"isTerminal": true,
"primary": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"rank": 1,
"rawStatus": "<string>",
"execution": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"rawDeferredStatus": "<string>",
"settlement": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
},
"withdrawal": {
"key": "<string>",
"label": "<string>",
"tone": "<string>"
}
},
"linkedWalletId": "<string>",
"nextAction": {
"kind": "payoutFeeRose",
"legId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"nextActions": [
{
"purpose": "tokenApproval",
"type": "authorizeWallet",
"actor": "userWallet",
"after": [
"waitForTransactionMined"
],
"chain": {
"namespace": "eip155",
"reference": "<string>"
},
"chainId": 1,
"details": "<unknown>",
"frequency": "perTrade",
"sourceAuthorizationMessage": {
"deadline": 1,
"encoding": "base64",
"message": "<string>",
"nonce": "<string>",
"scheme": "svmSourcePermit",
"signer": "<string>"
},
"submitTo": "<string>",
"transaction": {
"data": "<string>",
"kind": "evm",
"to": "<string>",
"value": "<string>"
},
"tx": {
"data": "<string>",
"to": "<string>",
"value": "<string>"
},
"typedData": "<unknown>",
"walletAuthorization": {
"authorizationKind": "turnkeyOwnerProof",
"authorizationPayload": "<unknown>",
"expiresAt": "2023-11-07T05:31:56Z",
"provider": "privy",
"signingDigest": "<string>",
"walletId": "<string>",
"authorizationId": "<string>",
"providerBody": "<string>",
"requestExpiryMs": 123
}
}
],
"nextActor": "taker",
"orderKind": "<string>",
"pairQuoteId": "<string>",
"quoteId": "<string>",
"realizedSlippageBps": 123,
"recipientAddress": "<string>",
"reporting": {
"legs": [
{
"counterparty": {
"name": "<string>",
"status": "connected",
"workspaceId": "<string>"
},
"legId": "<string>",
"provider": "<string>",
"limitation": "<string>",
"reportingInstitution": {
"name": "<string>",
"status": "connected",
"workspaceId": "<string>"
}
}
],
"transfers": [
{
"createdAt": "2023-11-07T05:31:56Z",
"dataStatus": "<string>",
"id": "<string>",
"orderId": "<string>",
"state": "<string>",
"transmissionStatus": "<string>",
"viewerRole": "<string>",
"escalatedAt": "2023-11-07T05:31:56Z",
"lastError": "<string>",
"nextRetryAt": "2023-11-07T05:31:56Z",
"piiSubmittedAt": "2023-11-07T05:31:56Z",
"providerCheckedAt": "2023-11-07T05:31:56Z",
"providerStatus": "<string>",
"providerTransferId": "<string>",
"receivingVaspDid": "<string>",
"reportingWorkspaceId": "<string>",
"sendingVaspDid": "<string>"
}
]
},
"route": {
"buy": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
},
"sell": {
"asset": {
"assetId": "<string>",
"resolutionStatus": "resolved",
"symbol": "<string>",
"address": "<string>",
"chainId": 1,
"chainRef": "<string>",
"decimals": 1,
"name": "<string>"
},
"decimalAmount": "<string>",
"rawAmount": "<string>",
"unresolved": "assetNotInRegistry"
}
},
"senderAddress": "<string>",
"settledAt": "2023-11-07T05:31:56Z",
"settlementSpeedMs": 123,
"slippageToleranceBps": 123,
"stuckSince": "2023-11-07T05:31:56Z",
"substatus": "<string>",
"substatusCode": "<string>",
"substatusMessage": "<string>",
"timing": {
"observedAt": "2023-11-07T05:31:56Z",
"revision": "<string>",
"stages": [
{
"clockState": "<string>",
"context": "<string>",
"estimateKind": "<string>",
"key": "<string>",
"operation": "<string>",
"elapsedSeconds": 123,
"endedAt": "2023-11-07T05:31:56Z",
"expectedSeconds": 1,
"legIndex": 1,
"startedAt": "2023-11-07T05:31:56Z",
"waitingSince": "2023-11-07T05:31:56Z"
}
]
},
"transactions": [
{
"actor": "user",
"chainId": 1,
"chainRole": "origin",
"hash": "<string>",
"stage": "prepare",
"status": "pending",
"explorerUrl": "<string>",
"label": "<string>",
"legIndex": 1,
"timestamp": 1
}
],
"venueRouteId": "<string>",
"viewer": {
"recordsScope": "full",
"submittedByYou": true
},
"workspaceId": "<string>"
},
"orderId": "<string>",
"status": "pending",
"statusUrl": "<string>",
"terminal": true,
"kind": "advancedTrade",
"creditCheck": {
"activeHolds": "<string>",
"available": "<string>",
"availableSigned": "<string>",
"checkedAt": "2023-11-07T05:31:56Z",
"creditPortion": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"decision": "<string>",
"effectiveLimit": "<string>",
"exposureDelta": "<string>",
"exposureReducing": true,
"localHeadroom": "<string>",
"lpAvailable": "<string>",
"maxAgeMs": 1,
"observationAgeMs": 1,
"observationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"projectedUsed": "<string>",
"source": "<string>",
"termsVersion": 123,
"used": "<string>",
"valuationMaxAgeMs": 1,
"venueAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"journalVersion": "<string>",
"overLimitBy": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"positionsBasis": "<string>",
"zeroAssets": [
"<string>"
]
},
"creditPortion": {
"amount": "<string>",
"currency": "<string>",
"lineValue": "<string>"
},
"creditReservation": {
"debitAsset": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"exposureAmount": "<string>",
"exposureCurrency": "<string>",
"inputAmount": "<string>",
"positiveInputAmount": "<string>",
"reservationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"state": "<string>",
"operationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"payIn": {
"afterPayBy": {
"action": "returned",
"source": "<string>"
},
"payBy": {
"clock": "payment_started",
"seconds": 1
},
"settlementGrace": {
"kind": "no_grace"
}
},
"next": {
"kind": "order"
},
"quoteId": "<string>",
"requestId": "<string>"
}
],
"scanLimitReached": true,
"nextCursor": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}{
"docUrl": "<string>",
"error": "<string>",
"message": "<string>",
"retryable": true,
"timestamp": 123,
"details": {
"capabilityBlockers": [
{
"code": "WORKSPACE_NOT_FOUND",
"estimate": "minutes",
"message": "<string>",
"unlockStep": "finish_onboarding",
"currentlyDue": [
"<string>"
]
}
],
"conflicts": [
"<string>"
],
"field": "<string>",
"reason": "<string>",
"remediation": "<string>",
"retryAfter": "PT120S",
"value": "<string>"
},
"next": {
"kind": "order"
},
"requestId": "<string>"
}Authorizations
Send the API key in X-API-Key.
Request signing. A key with signing enabled (POST /api/v1/workspaces/{workspaceId}/users/me/api-keys/{keyId}/signing, which returns the signing secret once) must also sign every request:
X-Timestamp: the current Unix time in seconds, within 300 seconds of the server clock.X-Signature: lower-case hex HMAC-SHA256 of the canonical string, keyed with the signing secret's 32 bytes (the secret is 64 hex characters; decode it first).
The canonical string is four lines joined by \n, with no trailing newline: the X-Timestamp value, the upper-case method, the path with its query exactly as sent (/api/v1/orders?limit=1), and the lower-case hex SHA-256 of the exact body bytes (the SHA-256 of an empty body when there is none).
A write's signature (POST, PUT, PATCH, DELETE) is accepted once: sending the same signed write again is refused, so a retry signs again. A read (GET, HEAD) changes nothing, so an identical signed read inside the window is admitted again and polling needs no nonce.
A signing refusal is a 401 AUTH_REQUIRED whose details.reason names the cause: SIGNATURE_REQUIRED (a header is missing), SIGNATURE_INVALID (a malformed header or a wrong signature), TIMESTAMP_OUT_OF_RANGE or SIGNATURE_REPLAYED.
Headers
The workspace the request acts in. An API key bound to a workspace implies it: omit the header, or send that same id (another id answers 403 WORKSPACE_SCOPE_MISMATCH). A member session must send it (400 MISSING_WORKSPACE without it).
Query Parameters
Number of matching items requested, 1–20; default 20.
x >= 0Opaque nextCursor from this caller, workspace and the identical filter set.
Public lifecycle status, shared by Basic and Advanced orders.
Open public lifecycle vocabulary shared by both order kinds. States may be
skipped; act on terminal, not on a particular sequence.
New values may be added; treat unknown values as other.
pending, working, filled, settled, unfilled, cancelled, failed, refunded, reviewRequired, outcomeUnknown, refused Which native owner holds an order.
basicTrade, advancedTrade Created at or after this RFC 3339 instant, inclusive.
Created at or before this RFC 3339 instant, inclusive.
Response
A page of the workspace's orders, newest first. A status filter keeps reading until the page
has limit items or the orders end, within a bounded scan: a page shorter than limit with a
nextCursor means that scan reached its limit (scanLimitReached), never that the orders ended.
What POST /orders {quoteId} created, read from the owner that saves it: a
protocol order in orders, or a workspace venue trade (fiat included) in the venue
trade operations. Nothing is recorded twice.
New values may be added; treat unknown values as other.
- Option 1
- Option 2
- Option 3
- Option 4
Show child attributes
Show child attributes
True when a status-filtered page stopped at its scan limit before filling limit:
more orders remain to examine, so follow nextCursor. False on every other page.