API Documentation
Time Tracking Policies ¶
Time Tracking Policies ¶
Overview
Resource that defines time tracking rules and constraints for a time tracker. Multiple policies can exist per organization.
Policy Hierarchy
Policies are evaluated in the following order of precedence:
- Person-level policy
- Subsidiary-level policy
- Organization-level policy
Note: The strongest policy will be applied.
Resource Configuration
Policies can be configured at three levels:
-
Organization settings (global)
-
Subsidiary settings (division-specific)
-
Person profile (individual)
Key Attributes
-
working_day_limit
: Maximum allowed hours on working days -
non_working_day_limit
: Maximum allowed hours on non-working days -
holiday_limit
: Maximum allowed hours on holidays -
full_day_absence_limit
: Maximum allowed hours during full-day absences -
half_day_absence_limit
: Maximum allowed hours during half-day absences
Supported filter params
-
id
-
name
Supported sort params
- name
GET /api/v2/time_tracking_policies
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": [
{
"id": "3",
"type": "time_tracking_policies",
"attributes": {
"name": "Time Tracking Policy 3",
"description": null,
"disabled_tracking_message": null,
"limited_tracking_message": null,
"full_day_absence_limit": null,
"half_day_absence_limit": null,
"holiday_limit": null,
"non_working_day_limit": null,
"note_mandatory": false,
"restrict_future_tracking": false,
"restrict_tracking_over_budget": false,
"task_mandatory": false,
"time_range_mandatory": false,
"working_day_limit": null,
"created_at": "2025-08-01T06:24:21.918+02:00",
"updated_at": "2025-08-01T06:24:21.918+02:00"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "2290"
}
},
"last_actor": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
}
}
}
],
"links": {
"first": "http://api-test.productive.io/api/v2/time_tracking_policies?page%5Bnumber%5D=1&page%5Bsize%5D=30",
"last": "http://api-test.productive.io/api/v2/time_tracking_policies?page%5Bnumber%5D=1&page%5Bsize%5D=30"
},
"meta": {
"current_page": 1,
"total_pages": 1,
"total_count": 1,
"page_size": 30,
"max_page_size": 200
}
}
Get time tracking policiesGET/api/v2/time_tracking_policies
GET /api/v2/time_tracking_policies/4
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "4",
"type": "time_tracking_policies",
"attributes": {
"name": "Time Tracking Policy 4",
"description": null,
"disabled_tracking_message": null,
"limited_tracking_message": null,
"full_day_absence_limit": null,
"half_day_absence_limit": null,
"holiday_limit": null,
"non_working_day_limit": null,
"note_mandatory": false,
"restrict_future_tracking": false,
"restrict_tracking_over_budget": false,
"task_mandatory": false,
"time_range_mandatory": false,
"working_day_limit": null,
"created_at": "2025-08-01T06:24:22.019+02:00",
"updated_at": "2025-08-01T06:24:22.019+02:00"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "2291"
}
},
"last_actor": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
Gets a time tracking policyGET/api/v2/time_tracking_policies/{id}
- id
number
(required) Example: 1time tracking policy id
POST /api/v2/time_tracking_policies
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "time_tracking_policies",
"attributes": {
"name": "Default Policy"
}
}
}
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "5",
"type": "time_tracking_policies",
"attributes": {
"name": "Default Policy",
"description": null,
"disabled_tracking_message": null,
"limited_tracking_message": null,
"full_day_absence_limit": null,
"half_day_absence_limit": null,
"holiday_limit": null,
"non_working_day_limit": null,
"note_mandatory": false,
"restrict_future_tracking": false,
"restrict_tracking_over_budget": false,
"task_mandatory": false,
"time_range_mandatory": false,
"working_day_limit": null,
"created_at": "2025-08-01T06:24:22.075+02:00",
"updated_at": "2025-08-01T06:24:22.075+02:00"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "2292"
}
},
"last_actor": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
POST /api/v2/time_tracking_policies
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "time_tracking_policies",
"attributes": {
"name": null
}
}
}
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/name"
}
}
]
}
Create a time tracking policyPOST/api/v2/time_tracking_policies
- name
string
(required) Example: Default+Policypolicy name
PATCH /api/v2/time_tracking_policies/6
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "time_tracking_policies",
"id": "6",
"attributes": {
"name": "Updated Policy"
}
}
}
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "6",
"type": "time_tracking_policies",
"attributes": {
"name": "Updated Policy",
"description": null,
"disabled_tracking_message": null,
"limited_tracking_message": null,
"full_day_absence_limit": null,
"half_day_absence_limit": null,
"holiday_limit": null,
"non_working_day_limit": null,
"note_mandatory": false,
"restrict_future_tracking": false,
"restrict_tracking_over_budget": false,
"task_mandatory": false,
"time_range_mandatory": false,
"working_day_limit": null,
"created_at": "2025-08-01T06:24:22.163+02:00",
"updated_at": "2025-08-01T06:24:22.182+02:00"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "2294"
}
},
"last_actor": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}
Update a time tracking policyPATCH/api/v2/time_tracking_policies/{id}
- id
number
(required) Example: 1time tracking policy id
- name
string
(required) Example: Default+Policypolicy name
DELETE /api/v2/time_tracking_policies/7
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Deletes a time tracking policyDELETE/api/v2/time_tracking_policies/{id}
- id
number
(required) Example: 1time tracking policy id
Generated by aglio on 01 Aug 2025