Skip to main content

GetUnitsResponseDto

nextCursorstring

Cursor for fetching the next page of results

Example: eyJsYXN0SWQiOiIxMjNlNDU2NyIsImxhc3RWYWx1ZSI6IjIwMjQtMDYtMTAifQ
previousCursorstring

Cursor for fetching the previous page of results

Example: eyJmaXJzdElkIjoiOTg3ZmVkY2IiLCJmaXJzdFZhbHVlIjoiMjAyNC0wNS0xNSJ9
totalnumberrequired

Total amount of results

results object[]required

List of units matching the query criteria

  • Array [
  • idnumberrequired

    Unique identifier for the unit

    Example: 1
    unitLanguages object[]required

    Translations of the unit in different languages, should reflect the languages available in the workspace

  • Array [
  • languagestringrequired

    Language code

    Possible values: [nl, en, de]

    singularstringrequired

    Singular form of the unit in this language

    Example: hour
    pluralstringrequired

    Plural form of the unit in this language

    Example: hours
  • ]
  • globalbooleanrequired

    Whether the unit is global

    Example: false
  • ]
  • GetUnitsResponseDto
    {
    "nextCursor": "eyJsYXN0SWQiOiIxMjNlNDU2NyIsImxhc3RWYWx1ZSI6IjIwMjQtMDYtMTAifQ",
    "previousCursor": "eyJmaXJzdElkIjoiOTg3ZmVkY2IiLCJmaXJzdFZhbHVlIjoiMjAyNC0wNS0xNSJ9",
    "total": 0,
    "results": [
    {
    "id": 1,
    "unitLanguages": [
    {
    "language": "nl",
    "singular": "Stuk",
    "plural": "Stuks"
    },
    {
    "language": "en",
    "singular": "Unit",
    "plural": "Units"
    },
    {
    "language": "de",
    "singular": "Einheit",
    "plural": "Einheiten"
    }
    ],
    "global": false
    }
    ]
    }