Dynamic Fields

Return only the fields you need with fields, or drop fields with omit.

Every response from the Platform API can be trimmed to just the fields you care about. This keeps payloads small — valuable when you're polling a large fleet of cold-chain trackers.

Two query parameters control this:

ParameterEffect
fieldsComma-separated list of fields to include
omitComma-separated list of fields to exclude
🚧

Which fields can I select?

Any field of the object inside the results array — i.e. any attribute of the entity.

Select only what you need

curl -X GET 'https://api.surfact.com/api/v2.0/variables/?fields=label,type' \
  -H 'X-Auth-Token: your_token_here'
{
  "count": 3,
  "next": null,
  "previous": null,
  "results": [
    { "label": "temperature", "type": "raw" },
    { "label": "humidity", "type": "raw" },
    { "label": "average_temperature", "type": "synthetic" }
  ]
}

Omit fields you don't want

curl -X GET 'https://api.surfact.com/api/v2.0/variables/?omit=createdAt,description,properties,tags,unit,url,valuesUrl,id,name' \
  -H 'X-Auth-Token: your_token_here'

The response contains every variable but only the fields that weren't omitted.

👍

Pairs well with everything

Combine fields/omit with Field Filters, Sorting, and Pagination to fetch exactly the data your dashboard or ERP integration needs — and nothing more.


Did this page help you?