{
  "opencollection": "1.0.0",
  "info": {
    "name": "Ajaib Coin Exchange Spot Trading API",
    "version": "v1"
  },
  "request": {
    "auth": {
      "type": "apikey",
      "key": "X-API-KEY",
      "value": "{{X-API-KEY}}",
      "placement": "header"
    }
  },
  "items": [
    {
      "info": {
        "name": "Spot Trading",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Retrieve all trades under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.ajaib.co.id/coin/internal/v1/trades",
            "params": [
              {
                "name": "symbol",
                "value": "",
                "type": "query",
                "description": "Symbol of trading pair."
              },
              {
                "name": "from_trade_id",
                "value": "",
                "type": "query",
                "description": "trade_id to fetch from (exclusive). Returns the most recent trades by default."
              },
              {
                "name": "limit",
                "value": "",
                "type": "query",
                "description": "Default 100, max 1000."
              }
            ]
          },
          "docs": "Retrieves all trades belonging to the exchange client's trading account. Sub-accounts are not supported."
        },
        {
          "info": {
            "name": "Retrieve an order under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order",
            "params": [
              {
                "name": "order_id",
                "value": "",
                "type": "query",
                "description": "The order id."
              },
              {
                "name": "symbol",
                "value": "",
                "type": "query",
                "description": "Symbol of trading pair."
              }
            ]
          },
          "docs": "Retrieves a single order, based on the input search parameters, belonging to the exchange client's trading account."
        },
        {
          "info": {
            "name": "Create a new order under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order",
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Creates a new spot trading order belonging to the exchange client's trading account. A successful response means the exchange has received the order instructions to act upon; it is no guarantee that all instructions have been processed successfully."
        },
        {
          "info": {
            "name": "Cancel an order under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order",
            "params": [
              {
                "name": "order_id",
                "value": "",
                "type": "query",
                "description": "Unique identifier generated by Ajaib exchange for the order."
              },
              {
                "name": "symbol",
                "value": "",
                "type": "query",
                "description": "Symbol of trading pair."
              }
            ]
          },
          "docs": "Cancels or withdraws an open order belonging to the exchange client's trading account. The instruction is valid only for orders with status NEW, OPEN or PARTIALLY_FILLED; otherwise it is rejected automatically."
        },
        {
          "info": {
            "name": "Retrieve all open orders under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order/open",
            "params": [
              {
                "name": "symbol",
                "value": "",
                "type": "query",
                "description": "Symbol of trading pair."
              },
              {
                "name": "from_order_id",
                "value": "",
                "type": "query",
                "description": "order_id to fetch from (inclusive of the starting id). Returns the most recent orders by default in descending order."
              },
              {
                "name": "limit",
                "value": "",
                "type": "query",
                "description": "Default 100."
              }
            ]
          },
          "docs": "Retrieves all open orders belonging to the exchange client's trading account. Open orders can only have the statuses NEW, OPEN or PARTIAL_FILLED."
        },
        {
          "info": {
            "name": "Cancel all open orders under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order/open",
            "params": [
              {
                "name": "symbol",
                "value": "",
                "type": "query",
                "description": "Symbol of trading pair."
              }
            ]
          },
          "docs": "Cancels or withdraws all open orders belonging to the exchange client's trading account for a trading pair."
        },
        {
          "info": {
            "name": "Create a new self-trading order",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order/self-trading",
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Creates a new \"self-trading\" order. Only available for use via an internal market maker exchange client."
        },
        {
          "info": {
            "name": "Create multiple new orders from a single request",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order/batch",
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Creates a list of new orders belonging to the exchange client's trading account, allowing a batch of order instructions to be submitted at one go. A successful response means the exchange has received the instructions; it is no guarantee all have been processed successfully."
        },
        {
          "info": {
            "name": "Cancel multiple orders under the exchange client",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.ajaib.co.id/coin/internal/v1/order/batch",
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Cancels or withdraws a list of orders belonging to the exchange client's trading account in a single request."
        }
      ]
    }
  ],
  "bundled": true
}