Get Jobs API
This API is used to get the list of jobs
Request URL:
https://people.zoho.com/people/api/timetracker/getjobs?assignedTo=<assignedTo>&assignedBy=<assignedBy>&jobStatus=<jobStatus>&dateFormat=<dateFormat>&projectId=<projectId>&clientId=<clientId>&isAssigneeCount=<isAssigneeCount>&fetchLoggedHrs=<fetchLoggedHrs>&sIndex=<sIndex>&limit=<limit>
Header:
Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxx9be93.9b8xxxxxxf
Scope:
ZOHOPEOPLE.timetracker.ALL
OR
ZOHOPEOPLE.timetracker.READ
Possible Operation Types:
ALL - Complete access to data
READ - Only to read data
Request parameter:
Parameter | Values Allowed | Default Value | Description |
*assignedTo | all | <Email Id> | <Employee Id> | <Erec No> | <Mandatory> | Specify the user whose jobs have to be fetched |
assignedBy | all | <Email Id> | <Employee Id> | <Erec No> | all | Specify the user by whom the jobs are assigned |
jobStatus | all | in-progress | completed | all | Specify the job status |
projectId | all | <project Id> | all | Specify the project Id which the jobs are associated with |
clientId | all | <client Id> | all | Specify the client Id |
dateFormat | <date format> | <Company date format> | Specify the format in which the dates should be provided |
isAssigneeCount | true | false | false | Fetches the number of users mapped to the job |
fetchLoggedHrs | true | false | false | Fetches the total hours logged for the job |
sIndex | <sIndex> | 0 | Specify from which record the response should be fetched |
limit | <limit> | 200 | Specify the number of records to be fetched. Maximum value is 200 |
Error Codes and Messages :
Error Code | Error Message |
9000 | Permission denied |
9002 | No <parameter name> parameter specified |
9003 | Wrong value given for <parameter name> parameter |
9005 | Time tracker tab is disabled |
Success Response Format
{
"response": {
"result": [
{
"jobId": <Job Id>,
"jobName": <Job name>,
"projectId": <Project Id>,
"projectName": <Project name>,
"clientId": <Client Id>,
"clientName": <Client name>,
"fromDate": <Start date>,
"toDate": <End date>,
"description": <Description>,
"jobBillableStatus": <Billable | Non-Billable>,
"ratePerHour": <Rate per hour>,
"jobStatus": <In-Progress | Completed>
"hours": <Estimated hours in HH:mm>,
"totalhours": <Total hours logged for the job in HH:mm>, (NOTE: this key will be available only if "fetchLoggedHrs" parameter is set as true in the request)
"owner": <Owner Id>,
"assignedBy": <Owner name>,
"assigneeCount": <No of assignees>, (NOTE: this key will be available only if "isAssigneeCount" parameter is set as true in the request)
"isDeleteAllowed": <true | false>
},....
],
"message": "Data fetched successfully",
"uri": "/api/timetracker/getjobs",
"isNextAvailable": true, (NOTE: this key will not be available if there is no more data)
"status": 0
}
}
Error Response Format
{
"response": {
"message": "Error in fetching data",
"uri": "/api/timetracker/getjobs",
"errors": [
{
"code": <Error Code>,
"message": <Error Message>
}
],
"status": 1
}
}
Threshold Limit: 20 requests | Lock period: 5 minutes
Threshold Limit - Number of API calls allowed within a minute.
Lock Period - Wait time before consecutive API requests.
Sample Request
Copiedhttps://people.zoho.com/people/api/timetracker/getjobs?assignedTo=eliza.madison@gmail.com&assignedBy=eliza.madison@gmail.com&jobStatus=in-progress&dateFormat=dd/MM/yyyy&projectId=469505000000267333&clientId=469505000000133417&isAssigneeCount=true&fetchLoggedHrs=true&sIndex=0&limit=1
Header
CopiedAuthorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxx9be93.9b8xxxxxxf
Sample Response
Copied{
"response": {
"result": [
{
"jobName": "System Performance Analysis",
"owner": "469505000000133005",
"jobStatus": "In-Progress",
"hours": "57:00",
"assignedBy": "Eliza Madison",
"clientId": "469505000000133417",
"clientName": "Adamo Meyrick",
"toDate": "12/04/2019",
"description": "To analyse the system performance",
"jobBillableStatus": "Non-Billable",
"assigneeCount": 26,
"isDeleteAllowed": true,
"fromDate": "05/04/2019",
"jobId": "469505000000268001",
"ratePerHour": 0,
"totalhours": "52:00",
"projectName": "Analysis",
"projectId": "469505000000267333"
}
],
"message": "Data fetched successfully",
"uri": "/api/timetracker/getjobs",
"isNextAvailable": true,
"status": 0
}
}
Copied<?xml version="1.0" encoding="UTF-8"?>
<response uri="/api/timetracker/getjobs">
<status>0</status>
<message>Data fetched successfully</message>
<isNextAvailable>true</isNextAvailable>
<result>
<job>
<jobName>System Performance Analysis</jobName>
<owner>469505000000133005</owner>
<jobStatus>In-Progress</jobStatus>
<hours>57:00</hours>
<assignedBy>Eliza Madison</assignedBy>
<clientId>469505000000133417</clientId>
<clientName>Adamo Meyrick</clientName>
<toDate>12/04/2019</toDate>
<description>To analyse the system performance</description>
<jobBillableStatus>Non-Billable</jobBillableStatus>
<assigneeCount>26</assigneeCount>
<isDeleteAllowed>true</isDeleteAllowed>
<fromDate>05/04/2019</fromDate>
<jobId>469505000000268001</jobId>
<ratePerHour>0.0</ratePerHour>
<totalhours>52:00</totalhours>
<projectName>Analysis</projectName>
<projectId>469505000000267333</projectId>
</job>
</result>
</response>