Endpoint Parameters

  • Request parameters

    Name Type Origin Description
    AssetType AssetType Query-String Assettype of the instrument.
    Count Int Query-String Specifies maximum number of samples to return. Maximum is 1200. If not specified a default of 1200 samples are returned.
    FieldGroups ChartFieldGroupSpec [] Query-String Use FieldGroups to add additional information to the samples like display/formatting details or information about the price source. If FieldGroups are not specified in the request then the response defaults to only hold the bare OHLC samples and nothing else.
    Horizon Int Query-String The time period that each sample covers. Values are interpreted in minutes: 1, 5, 10, 15, 30, 60, 120, 240, 360, 480, 1440, 10080, 43200.
    Mode ChartRequestMode Query-String If Time is supplied, mode specifies if the endpoint should returns samples "UpTo" (and including) or "From" (and including) the specified time.
    Time UtcDateTime Query-String Specifies the time of a sample, which must either be the first (If Mode=="From") or the last (if Mode=="UpTo") in the returned data.
    Uic Int Query-String UIC (Universal Instrument Code) of the instrument.
  • Response Parameters

    View Response Codes
    Name Type Description
    ChartInfo ChartInfo Object holding information about the OHLC samples such as the exchange id of the price source, when the first sample begins, the horizon in minutes and how long the samples are delayed by.
    Data ChartSample [] Array holding the individual OHLC samples. For Forex Instruments both Bid and Ask values are returned. For other instruments the values are the last traded values.
    DataVersion Int This field holds a version number of the data.
    DisplayAndFormat DisplayAndFormat Object holding information relevant to displaying the instrument and formatting the samples for charting it. Currently holds the symbol of the instrument, how many decimals samples have, a description of the instrument and what currency it is traded in.
  • Request Example

    Request URL
    GET chart/v1/charts/?AssetType=WarrantDoubleKnockOut&Count=2&FieldGroups=DisplayAndFormat&Horizon=1&Mode=From&Time=9999-12-31T23:59:59.999999Z&Uic=21
  • Response Example

    Response body
    {
      "ChartInfo": {
        "DelayedByMinutes": 15,
        "ExchangeId": "SBFX",
        "FirstSampleTime": "2015-02-02T01:02:03Z",
        "Horizon": 1
      },
      "Data": [
        {
          "CloseAsk": 1.3475,
          "CloseBid": 1.3473,
          "HighAsk": 1.4003,
          "HighBid": 1.4001,
          "LowAsk": 1.2804,
          "LowBid": 1.2802,
          "OpenAsk": 1.3478,
          "OpenBid": 1.3476,
          "Time": "2015-02-01T11:45:00Z"
        },
        {
          "CloseAsk": 1.3475,
          "CloseBid": 1.3473,
          "HighAsk": 1.4003,
          "HighBid": 1.4001,
          "LowAsk": 1.2804,
          "LowBid": 1.2802,
          "OpenAsk": 1.3478,
          "OpenBid": 1.3476,
          "Time": "2015-02-01T11:46:00Z"
        }
      ],
      "DataVersion": 1892739,
      "DisplayAndFormat": {
        "Currency": "USD",
        "Decimals": 4,
        "Description": "Euro/US Dollar",
        "Format": "AllowDecimalPips",
        "Symbol": "EURUSD"
      }
    }