For the complete documentation index, see llms.txt. This page is also available as Markdown.

modify

modify

post
Body

Request envelope for the /exchange endpoint.

All exchange requests must include:

  • action: The action to perform
  • signature: EIP-712 signature authorizing the action
  • nonce: Unix timestamp in milliseconds (must be within validity window)
expiresAfterinteger · nullableOptional

Optional expiry for L1-signed actions.

nonceinteger · int64Required

Request nonce (Unix timestamp in milliseconds)

vaultAddressstring · nullableOptional

Optional vault address for vault operations

Responses
200

Request successful. Response format depends on the requested action.

application/json
anyOptional
post/exchange
POST /exchange HTTP/1.1
Host: api.hyperlink.xyz
Content-Type: application/json
Accept: */*
Content-Length: 231

{
  "action": {
    "a": null,
    "oid": 1,
    "order": {
      "a": 1,
      "b": true,
      "c": null,
      "p": "text",
      "r": true,
      "s": "text",
      "t": {
        "limit": {
          "tif": "text"
        }
      }
    },
    "type": "modify"
  },
  "expiresAfter": null,
  "nonce": 1,
  "signature": {
    "r": "text",
    "s": "text",
    "v": 1
  },
  "vaultAddress": null
}
[
  {
    "coin": "BTC",
    "side": "A",
    "limitPx": "29792.0",
    "sz": "5.0",
    "oid": 91490942,
    "timestamp": 1681247412573,
    "origSz": "5.0",
    "cloid": "0x1234567890abcdef1234567890abcdef"
  }
]

Last updated