Create a time entry
Headers
-
Content-Type string
-
Accept string
Body Required
-
The type of the model that is being tracked.. Valid types are: client, board_task, case, circle, firm, task
-
The UUID of the model that is being tracked
-
The name of the time entry.
-
description string
The description of the time entry.
-
start_date date
The start time of the time entry.
-
end_date date
The end time of the time entry.
-
total_time_in_minutes integer
The length of the time entry, can be used instead of dates.
POST
/api/v1/time-entry
curl \
-X POST https://api.plannrcrm.com/api/v1/time-entry \
-H "Authorization: Bearer {OAUTH_ACCESS_TOKEN or PERSONAL_ACCESS_TOKEN}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"trackable_type":"Client","trackable_uuid":"8a0ff630-8c17-4bce-aa6c-99d2154ee4ad","name":"Research","description":"Research for the new project.","start_date":"2025-01-17T10:33:30+00:00","end_date":"2025-01-17T11:18:30+00:00","total_time_in_minutes":200}'
Request examples
# Headers
Authorization: Bearer {OAUTH_ACCESS_TOKEN or PERSONAL_ACCESS_TOKEN}
Content-Type: application/json
Accept: application/json
# Payload
{
"trackable_type": "Client",
"trackable_uuid": "8a0ff630-8c17-4bce-aa6c-99d2154ee4ad",
"name": "Research",
"description": "Research for the new project.",
"start_date": "2025-01-17T10:33:30+00:00",
"end_date": "2025-01-17T11:18:30+00:00",
"total_time_in_minutes": 200
}
Response examples (200)
{
"name": "Research",
"uuid": "f806216e-46df-49d3-a05d-f99e3daa5343",
"account": {
"name": "Gareth Thompson",
"role": "client",
"type": "client",
"uuid": "c9c34275-f3fc-4f6a-945d-a74971be3901",
"email": "gareth@codepotato.co.uk",
"last_name": "Thompson",
"photo_url": "https://eu.ui-avatars.com/api/?name=Gareth+Thompson",
"created_at": "2025-01-17T11:18:30+00:00",
"first_name": "Gareth",
"updated_at": "2025-01-17T11:18:30+00:00",
"external_references": "App\\Http\\Resources\\ExternalReferenceResource"
},
"end_date": "2025-01-17T10:56:30+00:00",
"is_active": true,
"trackable": {
"name": "Gareth Thompson",
"role": "client",
"type": "client",
"uuid": "55d94c9c-b211-49ad-bf22-ba5900a65344",
"email": "gareth@codepotato.co.uk",
"last_name": "Thompson",
"photo_url": "https://eu.ui-avatars.com/api/?name=Gareth+Thompson",
"created_at": "2025-01-17T11:18:30+00:00",
"first_name": "Gareth",
"updated_at": "2025-01-17T11:18:30+00:00",
"external_references": "App\\Http\\Resources\\ExternalReferenceResource"
},
"created_at": "2025-01-17T11:18:30+00:00",
"start_date": "2025-01-17T10:28:30+00:00",
"updated_at": "2025-01-17T11:18:30+00:00",
"description": "This is a description.",
"trackable_type": "Client",
"total_time_in_minutes": 28,
"computed_time_elapsed_in_seconds": 1680
}