api.nisa.digital
2025-08-28

Comprehensive guide to our Pohoda/Pamica endpoints

/v1/orders/list/:uid

List orders with server-side filtering and pagination.
Params
:uid - accounting unit identifier
Request
GET
POSTtext/json
{
  from?: number,  // default 0
  size?: number,  // default 30
  ids?: number[], // optional restrict to IDs
  asc?: string,   // optional sort asc
  desc?: string,  // optional sort desc
  on?: string[]   // optional filters: tokens "Field;search;from;to"
}
Response
200text/json
{
  total: number,
  filtered: number,
  fields: DField[],
  data: any[],
  summary: { [key: string]: number },
  query: DQuery
}

DField = {
  name: string,
  text?: string,
  sort?: 'asc'|'desc'|'',
  // simple values (one of these may be present)
  string?: string|null,
  number?: number|null,
  numbers?: number[],
  date?: string|null,          // ISO YYYY-MM-DD
  checkbox?: boolean|null,
  select?: { // select-like inputs
    type: 'number'|'date'|'string',
    value?: any|null,
    options: { value: any, text: string }[]
  },
  checkbuttons?: { // select-like inputs
    type: 'number'|'string',
    value?: any|null,
    options: { value: any, text: string }[]
  },
  checkboxes?: { // select-like inputs
    type: 'number'|'date'|'string'|'number[]'|'string[]',
    values?: any[],
    options: { value: any, text: string }[],
    classInput?: string
  },
  range?: { // ranges and validity
    type: 'number'|'date',
    nullable?: boolean,
    from?: number|string|Date|null,
    to?: number|string|Date|null
  },
  valid_until?: {
    type: 'date',
    nullable?: boolean,
    value?: string|Date|null
  }
}

DQuery = {
  from: number,
  size: number,
  init?: number,
  fields: DField[]
}
Error Codes
400 Bad Request
Your request doesn't meet the required input format
401 Not Authorized
Your request doesn't meet authorization requirements
404 Not Found
The entity you're looking for is missing
460 Request Error
Requested operation wasn't performed, or XML import failed
500 Internal Error
We encountered an internal server error
503 Not Available
Requested entity is offline and cannot be reached, try again later

/v1/commissions/list/:uid

List commissions with server-side filtering and pagination.
Params
:uid - accounting unit identifier
Request
GET
POSTtext/json
{
  from?: number,  // default 0
  size?: number,  // default 30
  ids?: number[], // optional restrict to IDs
  asc?: string,   // optional sort asc
  desc?: string,  // optional sort desc
  on?: string[]   // optional filters: tokens "Field;search;from;to"
}
Response
200text/json
{
  total: number,
  filtered: number,
  fields: DField[],
  data: any[],
  summary: { [key: string]: number },
  query: DQuery
}

DField = {
  name: string,
  text?: string,
  sort?: 'asc'|'desc'|'',
  // simple values (one of these may be present)
  string?: string|null,
  number?: number|null,
  numbers?: number[],
  date?: string|null,          // ISO YYYY-MM-DD
  checkbox?: boolean|null,
  select?: { // select-like inputs
    type: 'number'|'date'|'string',
    value?: any|null,
    options: { value: any, text: string }[]
  },
  checkbuttons?: { // select-like inputs
    type: 'number'|'string',
    value?: any|null,
    options: { value: any, text: string }[]
  },
  checkboxes?: { // select-like inputs
    type: 'number'|'date'|'string'|'number[]'|'string[]',
    values?: any[],
    options: { value: any, text: string }[],
    classInput?: string
  },
  range?: { // ranges and validity
    type: 'number'|'date',
    nullable?: boolean,
    from?: number|string|Date|null,
    to?: number|string|Date|null
  },
  valid_until?: {
    type: 'date',
    nullable?: boolean,
    value?: string|Date|null
  }
}

DQuery = {
  from: number,
  size: number,
  init?: number,
  fields: DField[]
}
Error Codes
400 Bad Request
Your request doesn't meet the required input format
401 Not Authorized
Your request doesn't meet authorization requirements
404 Not Found
The entity you're looking for is missing
460 Request Error
Requested operation wasn't performed, or XML import failed
500 Internal Error
We encountered an internal server error
503 Not Available
Requested entity is offline and cannot be reached, try again later