Get Time Profiles list
Returns Time Profiles list
Query Parameters
- limit integer
Possible values: [
10
,20
,30
,50
]Number of items. Value by default is 10
- page_number integer
Possible values:
>= 1
Page number
- sort_field string
Field name (JSON Key in item entity)
- sort_type string
Possible values: [
asc
,desc
]Default value:
asc
Sort type (asc/desc)
- filter object
Filtering options for Time Frofile
- 200
- 400
- 401
- 403
OK
- application/json
- Schema
- Example (from schema)
- Equal ` Work week`
- Since Monday, October 29, 2018 1:21:11 P M (1540819271 timestamp)
- Until Monday, October 29, 2018 1:21:13 P M (1540819273 timestamp)
Schema
- list_items object[]
list_option object
This object provides filter, pagination and sort options for time profiles table
pagination object
Available pagination options for tables
total_items integerThe total number of items found and reflected across all pages
items_limit integerPossible values: [
10
,25
,50
]Limiting the display of the amount of data for one page
total_pages integerPossible values:
>= 1
The number of pages that hold the requested data
current_page integerPossible values:
>= 1
Current page number
filter object
Available filter sets for time profiles
oneOf- MOD1
- MOD2
- MOD3
filter_field stringField available for filtering
filter_type stringPossible values: [
equal
]Available filtering type, only equal here
filter_format stringData format, only string here
filter_value stringTime profile name
filter_field stringField available for filtering
filter_type stringPossible values: [
equal
,less
,more
]Available filtering type
filter_format stringData format, only string here
filter_value int64Time profile date_from param
filter_field stringField available for filtering
filter_type stringPossible values: [
equal
,less
,more
]Available filtering type
filter_format stringData format, only string here
filter_value int64Time profile date_to param
sort object
Available sorting options for the time profile table
field stringSorting field name
asc booleanDirection of sorting
available_fields undefined[]Possible values: [
name
,date_from
,date_to
]Available for sorting fields names
{
"list_items": [
{
"time_profile_uid": 1,
"name": "Worker 1",
"time_options": {
"is_all_day": true,
"date_from": 1540819272,
"date_to": 1540819272
},
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_type": "day",
"repeat_end": {
"format": "date",
"date": 1540819272
},
"repeat_custom": {
"repeat_point_type": "week",
"repeat_looper": 5,
"repeat_options": [
"MON",
"TUE",
"WED",
"THU",
"FRI"
]
}
}
},
"identifiers": {
"count": 4,
"uid_items": [
11,
13,
23,
42
]
}
},
{
"time_profile_uid": 2,
"name": "Worker 2",
"time_options": {
"is_all_day": true,
"date_from": 1540819272,
"date_to": 1540819272
},
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_type": "day",
"repeat_end": {
"format": "date",
"date": 1540819272
},
"repeat_custom": {
"repeat_point_type": "week",
"repeat_looper": 5,
"repeat_options": [
"MON",
"TUE",
"WED",
"THU",
"FRI"
]
}
}
},
"identifiers": {
"count": 4,
"uid_items": [
11,
13,
23,
42
]
}
},
{
"time_profile_uid": 3,
"name": "Worker 3",
"time_options": {
"is_all_day": true,
"date_from": 1540819272,
"date_to": 1540819272
},
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_type": "day",
"repeat_end": {
"format": "date",
"date": 1540819272
},
"repeat_custom": {
"repeat_point_type": "week",
"repeat_looper": 5,
"repeat_options": [
"MON",
"TUE",
"WED",
"THU",
"FRI"
]
}
}
},
"identifiers": {
"count": 4,
"uid_items": [
11,
13,
23,
42
]
}
}
],
"list_option": {
"pagination": {
"total_items": 18,
"items_limit": 10,
"total_pages": 2,
"current_page": 1
},
"filter": {
"filter_field": "name",
"filter_type": "equal",
"filter_format": "string",
"filter_value": "Work week"
},
"sort": {
"field": "name",
"asc": true,
"available_fields": [
null
]
}
}
}
{
"list_items": [
{
"time_profile_uid": 1,
"name": "Work week",
"time_options": {
"is_all_day": true,
"date_from": 1540819272,
"date_to": 1540819272
},
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_type": "day",
"repeat_end": {
"format": "date",
"date": 1540819272
},
"repeat_custom": {
"repeat_point_type": "week",
"repeat_looper": 5,
"repeat_options": [
"MON",
"TUE",
"WED",
"THU",
"FRI"
]
}
}
},
"identifiers": {
"count": 4,
"uid_items": [
11,
13,
23,
42
]
}
}
],
"list_option": {
"pagination": {
"total_items": 18,
"items_limit": 10,
"total_pages": 2,
"current_page": 1
},
"filter": {
"filter_field": "name",
"filter_type": "equal",
"filter_format": "string",
"filter_value": "Work week",
"available_filtering": true,
"available_fields": [
"name",
"date_from",
"date_to"
],
"is_filtered": true
},
"sort": {
"asc": true,
"field": "name",
"available_fields": [
"date_to",
"date_from",
"name"
]
}
}
}
{
"list_option": {
"pagination": {
"total_pages": 1,
"items_limit": 10,
"total_items": 1,
"current_page": 1
},
"filter": {
"is_filtered": true,
"available_filtering": true,
"filter_format": "number",
"filter_type": "more",
"available_fields": [
"date_to",
"date_from",
"name"
],
"filter_field": "date_from",
"filter_value": 1540819271
},
"sort": {
"asc": true,
"field": "name",
"available_fields": "[date_to, date_from, name]"
}
},
"list_items": [
{
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_end": {
"date": 1540819272,
"format": "date"
},
"repeat_type": "day"
}
},
"identifiers": {
"count": 1,
"uid_items": [
1
]
},
"time_profile_uid": 1,
"time_options": {
"is_all_day": true,
"date_to": 1540819272,
"date_from": 1540819272
},
"name": "Work week"
}
]
}
{
"list_option": {
"pagination": {
"total_pages": 1,
"items_limit": 10,
"total_items": 1,
"current_page": 1
},
"filter": {
"is_filtered": true,
"available_filtering": true,
"filter_format": "number",
"filter_type": "less",
"available_fields": [
"date_to",
"date_from",
"name"
],
"filter_field": "date_to",
"filter_value": 1540819273
},
"sort": {
"asc": true,
"field": "name",
"available_fields": "[date_to, date_from, name]"
}
},
"list_items": [
{
"repeat_options": {
"repeat_enable": true,
"repeat_format": {
"repeat_end": {
"date": 1540819272,
"format": "date"
},
"repeat_type": "day"
}
},
"identifiers": {
"count": 1,
"uid_items": [
1
]
},
"time_profile_uid": 1,
"time_options": {
"is_all_day": true,
"date_to": 1540819272,
"date_from": 1540819272
},
"name": "Work week"
}
]
}
- Pagination: wrong limit
- Pagination: wrong page
- Wrong time format
- Wrong time range: 'to' must be greater then 'from'
- Filter: wrong filter_type
- Filter: wrong filter_field
- Filter: wrong filter_value
- Sort: wrong sort_type
- Wrong number format
- application/json
- Schema
- Example (from schema)
- Pagination Limit
- Pagination Page Number
- Sort
- Filter type
- Filter field
- Filter value
- Time format
- Time range
Schema
- error string
{
"error": "Administrator rights required"
}
{
"error": "Pagination: wrong limit"
}
{
"error": "Pagination: wrong page_number"
}
{
"error": "Sort: wrong sort_type"
}
{
"error": "Filter: wrong filter_type"
}
{
"error": "Filter: wrong filter_field"
}
{
"error": "Filter: wrong filter_value"
}
{
"error": "Wrong time format"
}
{
"error": "Wrong time range: 'to' must be greater then 'from'"
}
Unauthorized request. Log In
- application/json
- Schema
- Example (from schema)
- Log In
Schema
- error string
{
"error": "Log In"
}
{
"error": "Log In"
}
Administrator rights required. You are currently logged in with different user account. Log In with administrator rights
- application/json
- Schema
- Example (from schema)
- Admin Rights Required
Schema
- error string
{
"error": "Administrator rights required"
}
{
"error": "Administrator rights required"
}