Parameters

Default parameters

ParameterSupportExampleDescription
MaxAgeFunction, SnapshotMaxAge=2h30mThe MaxAge parameter allows you to limit the age of data retrieved from the endpoint cache. Out-of-cache functions will be executed to retrieve fresh data. Out-of-cache snapshots will return a 501 response.
CultureSnapshot, CSVCulture=en-USThe Culture parameter allows you to request CSV data from the REST API in a localized format.

Function parameters

Function endpoints may require additional parameters. It is mandatory to supply valid values for all parameters.

Function parameters for OData API can be set as arguments:
<Service URL>/api/odata/Function(Arg1=’ABC’)

or as query parameters:
<Service URL>/api/odata/Function?Arg1=ABC

Function parameters for Data API can only be set as query parameters:
<Service URL>/api/data/Function.csv?Arg1=ABC

Multiple parameters can be provided as function arguments:
<Service URL>/api/odata/Function(Arg1=’ABC’,Arg2=123)

or as query parameters:
<Service URL>/api/rest/Function.csv?Arg1=ABC&Arg2=123

Dates should be set in the format YYYY-MM-DD and decimal values should use period as decimal separator. String function parameters must be quoted, and query parameters should not be quoted.

Quoting string query parameters would result in a value including the quotes. A full request could for example look like:
<Service URL>/api/odata/Function(Arg1=’ABC’,Arg2=123,Arg3=2001-01-31,Arg4=123.34)
<Service URL>/api/odata/Function?Arg1=ABC&Arg2=123&Arg3=2001-01-31&Arg4=123.34)

Import parameters

Import parameters are provided in the request body, encoded in Json or XML format. As import endpoints are batch operations, the body consists of an array of parameters sets. In the following examples Json format is used.

Considering the somewhat unlikely case where no input parameters are accepted, an array with a single empty parameter set is provided to execute the endpoint once:

[
  {}
]

In a more realistic scenario a set of parameters are required. To execute a batch import, provide an array of parameters sets. Formats for various data types follow the Json standard. A quick way to get started is to copy and modify a request body sample from the documentation page:

[
  {
    "FXBaseAmount": 1000000.0,
    "Portfolio": "TRAD-FX",
    "Counterparty": " MY-CPTY",
    "Sign": "Buy",
    "CCY1": "EUR",
    "CCY2": "USD",
    "OpeningDate": "2019-09-11T16:30:13.4961062+02:00"
  },
  {
    "FXBaseAmount": 50000.0,
    "Portfolio": "TRAD-FX",
    "Counterparty": "MY-CPTY",
    "Sign": "Sell",
    "CCY1": "EUR",
    "CCY2": "GBP",
    "OpeningDate": "2019-09-11T16:30:13.4961062+02:00"
  }
]