Choose where you’d like to start

Update Associated Logs in Zoho Projects

Description

The zoho.projects.updateAssociateLogs task updates the time log associated with the specified record in Zoho Projects.

Note: For security reasons, if you execute Zoho Projects integration tasks for more than 100 times under 2 minutes, you will be restricted to execute any Zoho Projects integration task for the next 30 mins.

Syntax

<response> = zoho.projects.updateAssociateLogs(<portal>, <project_id>, <log_record_id>, <module>, <record_id>, <values>, [<connection>]);

where:

ParamsData typeDescription

<response> 

KEY-VALUE

The details of the time logs that will be updated and the status of the executed task.

<portal> 

TEXT/ NUMBER

The name or ID of the portal.

Note: You can get the name or ID of the portal using the get portals task. Click here to learn more about it.

<project_id> 

NUMBER

The ID of the project.

Note: You can get project_id using the get project details task. Click here to learn more about it.

<log_record_id> 

NUMBER

The record ID of the time log that needs to be updated.

Note: You can get the ID of the record using the get records task. Click here to learn more about it.

<module> 

TEXT

The name of the module in which the time log will be updated.

Allowed values:

  • tasks
  • bugs

<record_id> 

NUMBER

The ID of the record to which the time log is associated.

Note: You can get the ID of the record using the get records task. Click here to learn more about it.

<values>

KEY-VALUE

The values of the new time log that needs to be created. The keys to this parameter are provided as specified in the Zoho Projects API. The API documents for all the allowed modules are listed below:

<connection>

(optional)

TEXT

The link name of the connection.

Note: This parameter is applicable to all Zoho services that have connections support, except Zoho Creator.

Example

The following example creates a time log with the specified values and associates it with the task of ID - 548XXXXXXXXXXX885:

 new_value = Map();
 new_value.put("date", "07-11-2019");
 new_value.put("bill_status", "Non Billable");
 new_value.put("hours", "01:15");
 response = zoho.projects.updateAssociateLogs("zylker", 548XXXXXXXXXXX771, 548XXXXXXXXXXX001, "tasks", 548XXXXXXXXXXX885, new_value);

where:

response
The KEY-VALUE response returned by Zoho Projects.  It represents the details of the time log that will be updated.
"zylker"
The TEXT that represents the name of the portal.
548XXXXXXXXXXX771
The NUMBER that represents the project ID.
548XXXXXXXXXXX001
The NUMBER that represents the record ID of the time log that needs to be updated.
"tasks"
The TEXT that represents the name of the module in which the time log will be updated.
548XXXXXXXXXXX885
The NUMBER that represents the ID of the record to which the time log is associated.
new_value
The KEY-VALUE variable that holds the new values of the time log.

Response Format

Success Response

  • The success response will be returned in the following format:

      {
      "timelogs": {
      "tasklogs": [
      {
      "created_time_long": 1566220176747,
      "hours": 1,
      "notes": "",
      "owner_name": "Shawn",
      "created_time_format": "08-19-2019 06:39:36 PM",
      "minutes": 15,
      "total_minutes": 75,
      "owner_id": "58131170",
      "approval_status": "Approved",
      "link": {
      "self": {
      "url": "https://projects.zoho.com/restapi/portal/test24/projects/548XXXXXXXXXXX771/tasks/548XXXXXXXXXXX885/logs/548XXXXXXXXXXX001/"
      }
      },
      "last_modified_date": "08-20-2019",
      "log_date_long": 1562869799000,
      "bill_status": "Non Billable",
      "last_modified_time_long": 1566286952823,
      "last_modified_time_format": "08-20-2019 01:12:32 PM",
      "task": {
      "name": "task 1",
      "id_string": "548XXXXXXXXXXX885",
      "id": 548XXXXXXXXXXX885
      },
      "log_date": "07-11-2019",
      "id_string": "548XXXXXXXXXXX001",
      "id": 548XXXXXXXXXXX001,
      "created_date": "08-19-2019",
      "log_date_format": "07-11-2019 11:59:59 PM",
      "hours_display": "01:15"
      }
      ]
      }
      }

Failure Response

  • The failure response for invalid Project ID or log record ID will be returned in the following format:

      {
      "error": {
      "code": 6404,
      "message": "Resource Not Found"
      }
      }
  • The failure response for invalid portal name will be returned in the following format:

      {
      "error": {
      "code": 6504,
      "message": "Domain Not Available"
      }
      }
  • The failure response for invalid portal ID will be returned in the following format:

      {
      "error": {
      "code": 6500,
      "message": "General Error"
      }
      }
  •  

Related Links

Get Started Now

Execute