Get Projects API
This API is used to get the list of projects.
Request URL:
https://people.zoho.com/people/api/timetracker/getprojects?clientId=<clientId>&assignedTo=<assignedTo>
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:
Parameters | Values Allowed | Default Value | Description |
assignedTo | < all | ERECNO | Email-ID | Employee-ID > | <current user> | Specify the user whose projects should be listed. |
clientId | < clientId > | all | Specify the client Id to get the projects associated with it. |
projectStatus | all | inprogress | completed | all | Specify the project status |
projectManager | < all | ERECNO | Email-ID | Employee-ID > | all | Specify the project manager |
searchProjectKey | all | equal | notEqual | startsWith | endsWith | contains | notContains | all | Specify the condition to get the projects whose names match the value given in 'searchProjectKey' |
searchProjectName | <Project name search text> | - | Only the projects whose names match this value based on the condition given in 'searchProjectName' will be listed |
isUserCount | true | false | false | Fetches the number of users assigned to the project |
isJobCount | true | false | false | Fetches the number of jobs mapped to the project |
sIndex | < sIndex > | 0 | Specify from which record the response should be fetched |
limit | < limit > | 200 | Specify the number of records to be fetched. The maximum value is 200 |
Error Codes & Messages:
Error Code | Error Message |
9000 | Permission denied |
9003 | Wrong value for <parameter_name> parameter |
9005 | Time tracker tab is disabled |
Success Response Format:
{
"response": {
"result": [
{
"projectName": <Project name>,
"projectId": <Project ID>,
"projectCost": <Project cost>,
"clientId": <Client ID>,
"clientName": <Client name>,
"projectStatus": <Project status>,
"ownerId": <Owner ID>,
"ownerName": < Owner name >,
"isDeleteAllowed": < true | false >,
"jobCount": < Job count >, (NOTE: This key will be available only if 'isJobCount' param is true)
"projectUsersCount": <User count>, (NOTE: This key will be available only if 'isUserCount' param is true)
"projectHead": {
"empId": <Employee ID>,
"erecno": <Erecno>,
"rate": <Rate per hour>,
"name": <Name>
},
"projectManagers": [
{
"empId": <Employee ID>,
"erecno": <Erecno>,
"rate": <Rate per hour>,
"name": <Name>
},...
]
}
],
"isNextAvailable": < true | false >, (NOTE: This key will be available only if there is more data)
"message": "Data Fetched Successfully",
"uri": "/api/timetracker/getprojects",
"status": 0
}
}
Error Response Format:
{
"response":
"message": "Error in fetching data",
"uri": "/api/timetracker/getprojects",
"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/api/timetracker/getprojects?clientId=2239000000332107& assignedTo=all&projectStatus=all&projectManager=all
Header
CopiedAuthorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxx9be93.9b8xxxxxxf
Sample Response
Copied{
"response": {
"result": [
{
"projectName": "Web Designing",
"projectId": "617735000000229087",
"projectCost": 34590,
"clientId": "617735000000245001",
"clientName": "Nicole Kidman",
"projectStatus": "In-Progress",
"ownerId": "617735000000189005",
"ownerName": "Joshua Butler",
"isDeleteAllowed": true,
"jobCount": 2,
"projectUsersCount": 5,
"projectHead": {
"empId": "1",
"erecno": "617735000000189005",
"rate": 300,
"name": "Joshua Butler"
},
"projectManagers": [
{
"empId": "2",
"erecno": "617735000000189976",
"rate": 200,
"name": "Lucy Feroda"
},
{
"empId": "3",
"erecno": "617735000000189986",
"rate": 200,
"name": "Mark Tedson"
}
],
"projectUsers": [
{
"empId": "5",
"erecno": "617735000000193006",
"rate": 100,
"name": "James Taylor"
},
{
"empId": "4",
"erecno": "617735000000189996",
"rate": 100,
"name": Denise Hathway"
}
]
}
],
"message": "Data fetched successfully",
"uri": "/api/timetracker/getprojects",
"status": 0
}
}
Copied<?xml version="1.0" encoding="UTF-8"?>
<response uri="/api/timetracker/getprojects">
<status>0</status>
<message>Data fetched successfully</message>
<result>
<project>
<projectName>Web Designing</projectName>
<projectId>617735000000229087</projectId>
<projectCost>34590.0</projectCost>
<clientId>617735000000245001</clientId>
<clientName>Nicole Kidman</clientName>
<projectStatus>In-Progress</projectStatus>
<ownerId>617735000000189005</ownerId>
<ownerName>Joshua Butler</ownerName>
<isDeleteAllowed>true</isDeleteAllowed>
<jobCount>2</jobCount>
<projectUsersCount>5</projectUsersCount>
<projectHead>{"empId":"1","erecno":"617735000000189005","rate":300,"name":"Joshua Butler"}</projectHead>
<projectManagers>[{"empId":"2","erecno":"617735000000189976","rate":200,"name":"Lucy Feroda"},{"empId":"3","erecno":"617735000000189986","rate":200,"name":"Mark Tedson"}]</projectManagers>
<projectUsers>[{"empId":"5","erecno":"617735000000193006","rate":100,"name":"James Taylor"},{"empId":"4","erecno":"617735000000189996","rate":100,"name":"Denise Hathway"}]</projectUsers>
</project>
</result>
</response>