### API Response: Get Project Information Success Example Source: https://worksection.com/en/faq/api-start.html/api-projects An example JSON structure returned upon a successful 'get_project' API call, illustrating the data format for project details including nested user objects, options, and tags. ```JSON { "status": "ok", "data": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/", "status": "active", "company": "FOLDER_NAME", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "text": "PROJECT_TEXT", "date_added": "YYYY-MM-DD HH:II", "date_start": "YYYY-MM-DD", "date_end": "YYYY-MM-DD", "date_closed": "YYYY-MM-DD HH:II", "options": { "allow_close": 0, "allow_give": 0, "allow_term": 0, "allow_limit": 0, "require_term": 0, "require_tag": 0, "require_limit": 0, "require_hidden": 0, "deny_comments_edit": 0, "deny_task_edit": 0, "deny_task_delete": 0, "time_require": 0, "time_today": 0, "timer_only": 0 }, "max_time": 100, "max_money": 500, "tags": { "TAG_ID": "TAG_NAME_1", "TAG_ID": "TAG_NAME_2" }, "users": [ { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_1" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_2" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_3" } ] } } ``` -------------------------------- ### Connecting Worksection to HubSpot CRM Step-by-Step Source: https://worksection.com/en/faq/api-start.html/hubspot Detailed guide on how to establish the connection between Worksection and HubSpot CRM, including account settings, activation, authorization, and automation setup. It outlines the fields to configure for new automations and how dynamic parameters can be used. ```APIDOC Connection Steps: Step 1: Go to Worksection account settings. Step 2: Activate the required CRM system. Step 3: Be logged in to HubSpot, or log in via the automatic window. Step 4: Allow Worksection access to your HubSpot account by clicking "Connect app". Step 5: Create a new automation by clicking "+ automation": Fields to fill: - Select HubSpot Funnel and Stage: For which you want to create a task. - Select Worksection Project: Where the task will be created. - Task Details: - Title: String (e.g., "Deal {dealname}") - Duration: Optional - Priority: Optional - Responsible Person: Optional - Import Information from CRM: - Contacts: Multiple contacts can be imported. - Matching Logic: Checked by "Name + Email", then "Name + Phone". New contact created if no match. - Note: Phone number changes in CRM won't update in Worksection if "Name + Email" matches. - CRM Transaction Impact: Specify how the transaction in CRM will be affected when the task is closed in Worksection. - Dynamic Fields in Task Title: To add a new parameter, enclose it in curly brackets (e.g., {dealname}). The list of parameters is displayed in the "Fields" field. Step 6: Add other automations if necessary. ``` -------------------------------- ### Worksection Admin API Example Query Parameters Source: https://worksection.com/en/faq/api-start.html/api-start An example of query parameters for the 'get_tasks' method when using an admin token. ```APIDOC ?action=get_tasks&id_project=26 ``` -------------------------------- ### Sample JSON Response for Get Project Tasks Source: https://worksection.com/en/faq/api-start.html/api-task An example JSON object demonstrating the successful response structure for the `get_tasks` API endpoint, showing typical values for various task attributes, including nested objects for users, project, files, subscribers, and relations. ```JSON { "status": "ok", "data": [ { "id": "TASK_ID", "name": "TASK_NAME_1", "page": "/project/PROJECT_ID/TASK_ID/", "status": "done", "priority": "0..10", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "project": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/" }, "text": "TASK_TEXT", "date_added": "YYYY—MM—DD HH:II", "date_start": "YYYY—MM—DD", "date_end": "YYYY—MM—DD", "date_closed": "YYYY—MM—DD HH:II", "time_end": "HH:II", "max_time": "50", "max_money": "100", "tags": { "TAG_ID": "TAG_NAME_1", "TAG_ID": "TAG_NAME_2" }, "files": [ { "id": "FILE_ID", "size": "FILE_SIZE", "name": "Example.docx", "page": "/download/FILE_ID" } ], "subscribers": [ { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_1" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_2" } ], "relations": { "to": [ { "type": "finish-to-start", "task": { "id": "SUBTASK_ID", "name": "SUBTASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/", "status": "active", "priority": "0..10" } } ], "from": [ { "type": "start-to-start", "task": { "id": "SUBTASK_ID", "name": "SUBTASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/" } } ] } } ] } ``` -------------------------------- ### Example Response for Get Webhooks API Source: https://worksection.com/en/faq/api-start.html/webhooks Provides a sample JSON response returned by the `get_webhooks` API method. It details the structure and typical data for multiple webhooks, including their ID, URL, subscribed events, status, and associated projects. ```JSON { "status": "ok", "data": [ { "id": "14", "url": "https://eoaerzysr8s23hq.m.pipedream.net", "events": "post_task,delete_task,reopen_task", "status": "active", "projects": "333" }, { "id": "16", "url": "https://eolb4pffb2s43u.m.pipedream.net", "events": "post_task,post_comment,post_project", "status": "paused" } ] } ``` -------------------------------- ### Obtain OAuth 2.0 Access Token Source: https://worksection.com/en/faq/api-start.html/oauth Explains how to make a POST request to the token URL to exchange the authorization code for an access token and refresh token. Includes required parameters, a CURL example, and an example JSON response. ```APIDOC Token URL: https://worksection.com/oauth2/token Method: POST Parameters: - client_id: string Description: client_id, received when creating the application. - client_secret: string Description: client_secret, received when creating the application. - grant_type: string Description: Always specify 'authorization_code'. - code: string Description: The authorization code you received in the previous step. - redirect_uri: string Description: URI where the response will be redirected. The URI must meet the requirements of the OAuth2 standard and use the HTTPS protocol. ``` ```curl curl -X POST -d "client_id=&client_secret=&grant_type=authorization_code&code=&redirect_uri=" https://worksection.com/oauth2/token ``` ```json { "token_type": "bearer", "expires_in": 86400, "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJh...", "refresh_token": "def502005534a202e9e8effa05cdbad564015604f34...", "account_url": "https://authorizeduseraccount.worksection.com" } ``` -------------------------------- ### Worksection OAuth2 API Example Query Parameters Source: https://worksection.com/en/faq/api-start.html/api-start An example of query parameters for the 'get_tasks' method when using an OAuth2 user token. ```APIDOC ?action=get_tasks&id_project=26 ``` -------------------------------- ### Worksection Admin API Final Request Example Source: https://worksection.com/en/faq/api-start.html/api-start An example of a complete Worksection API request using an admin token, including the generated MD5 hash as a parameter. ```APIDOC https://youraccount.worksection.com/api/admin/v2/?action=get_tasks&id_project=26& hash=ec3ab2c28f21b4a07424f8ed688d6644 ``` -------------------------------- ### API Response Example: Get All Account Tasks Source: https://worksection.com/en/faq/api-start.html/api-task A sample JSON structure returned by the `get_all_tasks` API method upon successful execution, illustrating the data format for tasks, users, projects, files, and relations. ```JSON { "status": "ok", "data": [ { "id": "TASK_ID", "name": "TASK_NAME_1", "page": "/project/PROJECT_ID/TASK_ID/", "status": "done", "priority": "0..10", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "project": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/" }, "text": "TASK_TEXT", "date_added": "YYYY—MM—DD HH:II", "date_start": "YYYY—MM—DD", "date_end": "YYYY—MM—DD", "date_closed": "YYYY—MM—DD HH:II", "time_end": "HH:II", "max_time": "50", "max_money": "100", "tags": { "TAG_ID": "TAG_NAME_1", "TAG_ID": "TAG_NAME_2" }, "files": [ { "id": "FILE_ID", "size": "FILE_SIZE", "name": "Example.docx", "page": "/download/FILE_ID" } ], "relations": { "to": [ { "type": "finish-to-start", "task": { "id": "SUBTASK_ID", "name": "SUBTASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/", "status": "active", "priority": "0..10" } } ], "from": [ { "type": "start-to-start", "task": { "id": "SUBTASK_ID", "name": "SUBTASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/", "status": "done", "priority": "0..10" } } ] }, "child": [ { "id": "SUBTASK_ID", "name": "SUBTASK_NAME_1", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/", "... ... ...", "child": [ { "id": "SUBTASK_ID" } ] } ] } ] } ``` -------------------------------- ### Sample get_projects API Request Source: https://worksection.com/en/faq/api-start.html/api-projects Illustrates the basic query parameter for initiating a request to retrieve a list of projects from the Worksection API. This is the minimal request to get all project information. ```HTTP ?action=get_projects ``` -------------------------------- ### Initiate OAuth 2.0 Authorization Code Flow Source: https://worksection.com/en/faq/api-start.html/oauth Details the initial authorization URL and required parameters for starting the OAuth 2.0 authorization code flow, including client ID, response type, redirect URI, state, and scopes. ```APIDOC Authorization URL: https://worksection.com/oauth2/authorize Parameters: - client_id: string Description: client_id, received when creating the application. - response_type: string Description: Customize the response, return the authorization code. Always specify 'code'. - redirect_uri: string Description: URI where the response will be redirected. The URI must meet the requirements of the OAuth2 standard and use the HTTPS protocol. - state: string Description: A random text string that will be included in the response to your application at the end of the OAuth stream. The main purpose is to prevent CSRF requests from being spoofed. - scope: string Description: OAuth permissions help you fine-tune which data in the Worksection your application will have access to. This parameter is transferred in the form of strings separated by a space or comma. Available Scopes: projects_read, projects_write, tasks_read, tasks_write, costs_read, costs_write, tags_read, tags_write, comments_read, comments_write, files_read, files_write, users_read, users_write, contacts_read, contacts_write, administrative ``` -------------------------------- ### Make Authenticated API Request with OAuth2 using cURL Source: https://worksection.com/en/faq/api-start.html/oauth This snippet demonstrates how to make an authenticated GET request to the Worksection API using cURL. It shows how to pass the access token in the Authorization header and provides an example of fetching tasks for a specific project. The response format is also illustrated. ```curl curl -X GET -H "Authorization: Bearer " https://youraccount.worksection.com/api/oauth2?action=get_tasks&id_project=193 ``` ```json { "status": "ok", "data": [ { "name": "T0", "page": "/project/193/13036/", "status": null, "priority": "1", "user_from": "Marcus Wright", "user_to": "Marcus Wright", "from_me": 0, "to_me": 0, "date_added": "2023-03-10 16:41", "date_start": "2023-03-15", "date_end": "2023-03-23", "child": [ { "name": "T0.1", "page": "/project/193/13036/13037/", "status": null, "priority": "1", "user_from": "Marcus Wright", "user_to": "Marcus Wright", "from_me": 0, "to_me": 0, "date_added": "2023-03-10 16:41" } ] } ] } ``` -------------------------------- ### Example Webhook Payload for Project Creation Source: https://worksection.com/en/faq/api-start.html/webhooks Illustrates the JSON structure of a webhook event payload sent to the specified URL when a new project is created in Worksection. This example shows the typical data included in such a notification. ```JSON { "action": "post_project", "project_id": "12345", "project_name": "New Project Name", "user_id": "67890", "user_name": "John Doe", "timestamp": "2023-10-27T10:00:00Z" } ``` -------------------------------- ### JSON Response: Sample for Worksection get_task API Source: https://worksection.com/en/faq/api-start.html/api-task Provides an example of the successful JSON response from the `get_task` API call, showcasing the data format for a task, including nested details like user info, project, files, subscribers, and task relations. ```JSON { "status": "ok", "data": { "id": "TASK_ID", "name": "TASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/", "status": "active", "priority": "0..10", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "project": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/" }, "text": "TASK_TEXT", "date_added": "YYYY-MM-DD HH:II", "date_start": "YYYY-MM-DD", "date_end": "YYYY-MM-DD", "date_closed": "YYYY-MM-DD HH:II", "time_end": "HH:II", "max_time": "25", "max_money": "50", "tags": { "TAG_ID": "TAG_NAME_1", "TAG_ID": "TAG_NAME_2" }, "files": [ { "id": "FILE_ID", "size": "FILE_SIZE", "name": "Example.docx", "page": "/download/FILE_ID" } ], "subscribers": [ { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_1" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME_2" } ], "relations": { "to": [ { "type": "finish-to-start", "task": { "id": "TASK_ID", "name": "TASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/", "status": "active", "priority": "0..10" } } ], "from": [ { "type": "start-to-start", "task": { "id": "TASK_ID", "name": "TASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/", "status": "done", "priority": "0..10" } } ] }, "child": [ {} ] } } ``` -------------------------------- ### Worksection API: Get Files Sample JSON Response Source: https://worksection.com/en/faq/api-start.html/api-files Example JSON structure returned by the 'get_files' API method upon a successful request, showing the status and an array of file objects with their detailed metadata. ```JSON { "status": "ok", "data": [ { "id": "FILE_ID", "page": "/download/FILE_ID", "name": "Example.docx", "size": "FILE_SIZE", "date_added": "YYYY—MM—DD HH:II", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" } }, { "id": "FILE_ID", "page": "/download/FILE_ID", "... ... ..." } ] } ``` -------------------------------- ### Sample JSON Response for get_projects API Call Source: https://worksection.com/en/faq/api-start.html/api-projects An example of a successful JSON response from the 'get_projects' API, demonstrating the 'ok' status and the full data structure for multiple projects, including nested fields and arrays. ```JSON { "status": "ok", "data": [ { "id": "PROJECT_ID_1", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/", "status": "active", "company": "FOLDER_NAME", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "text": "PROJECT_TEXT", "date_added": "YYYY—MM—DD HH:II", "date_start": "YYYY—MM—DD", "date_end": "YYYY—MM—DD", "date_closed": "YYYY—MM—DD HH:II", "options": { "allow_close": 0, "allow_give": 0, "allow_term": 0, "allow_limit": 0, "require_term": 0, "require_tag": 0, "require_limit": 0, "require_hidden": 0, "deny_comments_edit": 0, "deny_task_edit": 0, "deny_task_delete": 0, "time_require": 0, "time_today": 0, "timer_only": 0 }, "max_time": 100, "max_money": 500, "users": [ { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" } ] }, { "id": "PROJECT_ID_2", "name": "PROJECT_NAME", "... ... ..." } ] } ``` -------------------------------- ### API Request: Get All Account Tasks Source: https://worksection.com/en/faq/api-start.html/api-task Demonstrates the basic URL query parameter for requesting all tasks from an account via the Worksection API. ```APIDOC ?action=get_all_tasks ``` -------------------------------- ### Planfix: Generating API Key and Token for Worksection Import Source: https://worksection.com/en/faq/api-start.html/migration This guide explains how to obtain the necessary API key and token from Planfix for successful data import into Worksection. It includes steps for enabling API access, copying the API key, and creating and retrieving a new token. ```APIDOC API Key and Token Generation Process: 1. Navigate to: https://youraccount/?action=api&type=1 2. Log in to Planfix if prompted. 3. Click "Enable and get API keys". To Copy API Key: - Click the name of the field containing the API key. To Create and Copy Token: 1. Click "Create new token". 2. Enter an arbitrary token name (e.g., "Worksection Import"). 3. Save the token. 4. Click on the row of the newly created token to copy it. Management (Post-Import): - Reset API Key: Click the "pencil" icon next to the API key. - Delete Token: Hover over the token row and click the "basket" icon. ``` -------------------------------- ### API Request: Get Project Information Source: https://worksection.com/en/faq/api-start.html/api-projects Demonstrates the URL query parameters for requesting project details using the 'get_project' API method. Replace 'PROJECT_ID' with the actual project identifier. ```HTTP ?action=get_project&id_project=PROJECT_ID ``` -------------------------------- ### Worksection API: Example Project Tasks and Subtasks Response Source: https://worksection.com/en/faq/api-start.html/api-task This JSON snippet illustrates the typical structure of a Worksection API response when querying for project details, specifically focusing on how tasks and their associated subtasks are represented. Each task and subtask includes an 'id', 'name', and 'page' URL. The '...' indicates omitted fields for brevity. ```JSON "name": "SUBTASK_NAME_2", "page": "/project/PROJECT_ID/TASK_ID/SUBTASK_ID/", ... ... ... } ] } ] }, { "id": "TASK_ID", "name": "TASK_NAME_2", "page": "/project/PROJECT_ID/TASK_ID/", ... ... ... } ] } ``` -------------------------------- ### HTTP Request: Get Worksection Project Task Source: https://worksection.com/en/faq/api-start.html/api-task Illustrates the URL query parameters required to call the `get_task` API method, specifying the task ID. ```HTTP ?action=get_task&id_task=TASK_ID ``` -------------------------------- ### Worksection OAuth 2.0 Token Response Example Source: https://worksection.com/en/faq/api-start.html/api-start Illustrates the JSON structure of a successful response from the Worksection OAuth 2.0 token endpoint, containing the access token, refresh token, token type, expiration, and account URL. ```json { "token_type": "bearer", "expires_in": 86400, "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJh...", "refresh_token": "def502005534a202e9e8effa05cdbad564015604f34...", "account_url": "https://authorizeduseraccount.worksection.com" } ``` -------------------------------- ### Retrieve Webhooks via OAuth 2.0 Token: get_webhooks Source: https://worksection.com/en/faq/api-start.html/webhooks Shows how to retrieve webhooks using an OAuth 2.0 token with administrative scope. This cURL example demonstrates the HTTP GET request required for the `get_webhooks` method. ```cURL curl -X GET -H "Authorization: Bearer " https://youraccount.worksection.com/api/oauth2?action=get_webhooks ``` -------------------------------- ### Worksection OAuth2 API Request with access_token Parameter Source: https://worksection.com/en/faq/api-start.html/api-start Example Worksection API request using an OAuth2 user token passed directly as an 'access_token' query parameter. ```APIDOC https://youraccount.worksection.com/api/oauth2?action=get_tasks&id_project=26& access_token= ``` -------------------------------- ### Worksection Zapier Actions Reference Source: https://worksection.com/en/faq/api-start.html/zapier Actions in Zapier transfer new data to Worksection by calling its API. This section outlines the available Worksection actions that can be performed by your Zaps. ```APIDOC Worksection Actions: - Close Task: Description: Closes the task in the selected project. - Create Comment in Task: Description: Creates a comment in the task. - Create Project: Description: Creates a new project in your Worksection account. - Create Task in Project: Description: Creates a task in the project. ``` -------------------------------- ### API: Start Authorized User's Timer (start_my_timer) Source: https://worksection.com/en/faq/api-start.html/api-timers Starts a timer for the authorized user (OAuth2) within a specified task. This method requires an access token and the ID of the task where the timer should be started. ```HTTP Request ?action=start_my_timer&id_task=TASK_ID ``` ```APIDOC Parameters: id_task: string (Required) - The ID of the task to start the timer in. ``` ```JSON { "status": "ok" } ``` -------------------------------- ### Retrieve OAuth2 User Information Source: https://worksection.com/en/faq/api-start.html/oauth This snippet explains how to retrieve user information using an OAuth2 access token. It specifies the POST request to the `/oauth2/resource` endpoint and lists the necessary parameters: `client_id`, `client_secret`, and `access_token`. A cURL example and a sample JSON response are included. ```APIDOC Endpoint: POST https://worksection.com/oauth2/resource Parameters: client_id: string - client_id, received when creating the application. client_secret: string - client_secret, received when creating the application. access_token: string - The access token that was obtained in the /oauth2/token method. ``` ```curl curl -X POST -d "client_id=&client_secret=access_token=" https://worksection.com/oauth2/resource ``` ```json { "id": "11", "first_name": "John", "last_name": "Smith", "email": "[email protected]", "account_url": "https://authorizeduseraccount.worksection.com" } ``` -------------------------------- ### Obtain Worksection OAuth 2.0 Access Token with cURL Source: https://worksection.com/en/faq/api-start.html/api-start Example cURL command to make a POST request to the Worksection OAuth 2.0 token endpoint, exchanging an authorization code for an access token. ```bash curl -X POST -d "client_id=&client_secret=& grant_type=authorization_code&code=&redirect_uri=" https://worksection.com/oauth2/token ``` -------------------------------- ### Viber Bot Commands for Worksection Integration Source: https://worksection.com/en/faq/api-start.html/viber This section outlines the available commands for interacting with Worksection projects and tasks directly through the Viber bot. Commands are categorized into general commands and project-specific commands, detailing their purpose and usage. ```APIDOC General Commands: Help: Shows a list of all commands with their description. Projects: Shows a table of 42 projects. Use 'More' command to show the rest. Clicking one of the project names will display additional command buttons for working with the selected project. Project Commands (available after using the 'Projects' command and selecting a project): Tasks: Shows a table of 42 tasks. Use 'More' command to show the rest. Clicking one of the task names will display a message with brief information about the task with the possibility of further posting a comment or reaction. Team: Shows a list of all project members. Add: Creates a task in the selected project. You can specify a title, priority, executive, deadline and description. Adding tags, files and estimated costs is not available. ``` -------------------------------- ### API: Get List of Active Timers (get_timers) Source: https://worksection.com/en/faq/api-start.html/api-timers Retrieves a list of all currently running timers, including their ID, start time, current value, and the user who initiated them. This method provides comprehensive details about each active timer and its associated task. ```HTTP Request ?action=get_timers ``` ```APIDOC Returned Data Fields: - id: string (Timer ID) - time: string (Timer value at request time, format HH:II:SS) - date_started: string (Timer start date and time, format YYYY—MM—DD HH:II) - user_from: object (Info on who started the timer) - id: string (User ID) - email: string (User email) - name: string (User name) - task: object (Dataset on project and task where timer is running) - id: string (Task ID) - name: string (Task name) - page: string (URL to task page, e.g., /project/PROJECT_ID/TASK_ID/) - status: string (Task status, e.g., "active") - priority: string (Task priority, e.g., "1") - user_from: object (User who assigned the task) - email: string (User email) - name: string (User name) - user_to: object (User assigned to the task) - email: string (User email) - name: string (User name) - project: object - id: string (Project ID) - name: string (Project name) - page: string (URL to project page, e.g., /project/PROJECT_ID/) - text: string (Task description) - date_added: string (Task creation date, format YYYY—MM—DD HH:II) - date_start: string (Task start date, format YYYY—MM—DD) - date_end: string (Task end date, format YYYY—MM—DD) - time_end: string (Task end time, format HH:II) - max_time: number (Maximum time for task) - max_money: number (Maximum money for task) - tags: object (Key-value pairs of tag ID and name) ``` ```JSON { "status": "ok", "data": [ { "id": "TIMER_ID", "time": "HH:II:SS", "date_started": "YYYY—MM—DD HH:II", "user_from": { "id": "USER_ID", "email": "USER_EMAIL", "name": "USER_NAME" }, "task": { "id": "TASK_ID", "name": "TASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/", "status": "active", "priority": "1", "user_from": { "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "email": "USER_EMAIL", "name": "USER_NAME" }, "project": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/" }, "text": "TASK_TEXT", "date_added": "YYYY—MM—DD HH:II", "date_start": "YYYY—MM—DD", "date_end": "YYYY—MM—DD", "time_end": "HH:II", "max_time": 20, "max_money": 500, "tags": { "TAG_ID": "TAG_NAME_1", "TAG_ID": "TAG_NAME_2" } } }, { "id": "TIMER_ID", "time": "HH:II:SS", "... ... ..." } ] } ``` -------------------------------- ### API Documentation: get_all_tasks Method Details Source: https://worksection.com/en/faq/api-start.html/api-task Detailed documentation for the `get_all_tasks` API method, including its optional request parameters and the comprehensive structure of the returned data fields, such as task details, user info, project data, files, and relations. ```APIDOC Method: get_all_tasks Description: Returns all incomplete and completed tasks of all projects (except tasks with delayed publication). Note: Subtasks can be returned with extra=subtasks parameter. Optional Parameters: - extra: additional task info (can be specified with commas, e.g., extra=text,files) - text or html: description in text or html format - files: attached files info (in task description) - comments: five last comments - relations: dependencies with other tasks - subtasks: list of subtasks (in child dataset) - archive: tasks of archived projects - filter: - active: incomplete tasks (completed tasks filtering is not available) Returned Data Fields: - id: task ID - name: task name - page: task link - status: state (active/done — incomplete/completed) - priority: priority (value range: 0..10) - user_from: task author - id: USER_ID - email: USER_EMAIL - name: USER_NAME - user_to: task executive - id: USER_ID - email: USER_EMAIL - name: USER_NAME - project: project info - id: PROJECT_ID - name: PROJECT_NAME - page: /project/PROJECT_ID/ - text: task description in text or html format (if request contains corresponding extra parameter) - date_added: creation date and time - date_start: start date (if specified) - date_end: due date (if specified) - date_closed: closing date and time - time_end: due time (if specified) - max_time: time estimate (if specified) - max_money: financial estimate (if specified) - tags: array in id: name format for task tags (if specified) - files: attached files info (if request contains extra=files parameter) - id: file ID (can be used for downloading through download method) - size: file size (in bytes) - name: file name with its extension - page: part of the link for direct download (for the full path put the address of your account in front, for example https://youraccount.worksection.com/download/123456) - relations: dependencies with other tasks (if request contains extra=relations parameter) - from: inbound dependencies - type: dependency type finish-to-start/start-to-start - task: linked task - to: outbound dependencies (similar to from) - child: subtasks data (if request contains extra=subtasks parameter) ``` -------------------------------- ### Worksection OAuth2 API Request with Bearer Token (cURL) Source: https://worksection.com/en/faq/api-start.html/api-start Example cURL command for making a Worksection API request using an OAuth2 user token passed in the Authorization header as a Bearer token. ```Shell curl -X GET -H "Authorization: Bearer " https://youraccount.worksection.com/api/oauth2?action=get_tasks&id_project=26 ``` -------------------------------- ### API Request: Get Project Tasks (`get_tasks`) Source: https://worksection.com/en/faq/api-start.html/api-task Describes the URL parameters for requesting project tasks from the Worksection API. It supports filtering and including additional task details. Note that tasks with delayed publication are excluded. ```APIDOC get_tasks API Endpoint: Method: GET Path: ?action=get_tasks Description: Returns all incomplete and completed tasks of selected project (except tasks with delayed publication). Subtasks can be returned with extra=subtasks parameter. Required Parameters: id_project: string - project ID Optional Parameters: extra: string - additional task info (can be specified with commas, e.g., extra=text,files) text or html: description in text or html format files: attached files info (in task description) comments: five last comments relations: dependencies with other tasks subtasks: subtasks list (in child dataset) subscribers: subscribers list filter: string - incomplete tasks (e.g., filter=active). Completed tasks filtering is not available. Sample Request: ?action=get_tasks&id_project=PROJECT_ID ``` -------------------------------- ### Worksection API: get_task Method Reference Source: https://worksection.com/en/faq/api-start.html/api-task Detailed specification for the `get_task` API method, outlining its purpose, required and optional input parameters, and the comprehensive structure of the data returned, including nested objects for files, subscribers, and relations. ```APIDOC Method: get_task Description: Returns selected incomplete or completed (sub)task. Notes: - Except (sub)tasks with delayed publication. - Task along with its subtasks can be returned with extra=subtasks parameter. Parameters: Required: - id_task: task ID Optional: - extra: additional task info (can be specified with commas, e.g., extra=text,files) - text or html: description in text or html format - files: attached files info (in task description) - id: file ID (can be used for downloading through download method) - size: file size (in bytes) - name: file name with its extension - page: part of the link for direct download - comments: five last comments - relations: dependencies with other tasks - subtasks: subtasks list (in child dataset) - subscribers: subscribers list - filter: only incomplete subtasks (when using extra=subtasks parameter) - filter=active: only incomplete subtasks (Completed subtasks filtering is not available) Returned Data: - id: task ID - name: task name - page: task link - status: state (active/done - incomplete/completed) - priority: priority (value range: 0..10) - user_from: task author - id: USER_ID - email: USER_EMAIL - name: USER_NAME - user_to: task executive - id: USER_ID - email: USER_EMAIL - name: USER_NAME - project: project info - id: PROJECT_ID - name: PROJECT_NAME - page: /project/PROJECT_ID/ - parent: parent task (if request contains subtask ID) - text: task description in text or html format (if request contains corresponding extra parameter) - date_added: creation date and time - date_start: start date (if specified) - date_end: due date (if specified) - date_closed: closing date and time - time_end: due time (if specified) - max_time: time estimate (if specified) - max_money: financial estimate (if specified) - tags: array in id: name format for task tags (if specified) - files: attached files info (if request contains extra=files parameter) - id: file ID (can be used for downloading through download method) - size: file size (in bytes) - name: file name with its extension - page: part of the link for direct download - subscribers: subscribers list (if request contains extra=subscribers parameter) - id: USER_ID - email: USER_EMAIL - name: USER_NAME - relations: dependencies with other tasks (if request contains extra=relations parameter) - from: inbound dependencies - type: dependency type finish-to-start/start-to-start - task: linked task - id: TASK_ID - name: TASK_NAME - page: /project/PROJECT_ID/TASK_ID/ - status: active/done - priority: 0..10 - to: outbound dependencies (similar to from) - type: dependency type finish-to-start/start-to-start - task: linked task - id: TASK_ID - name: TASK_NAME - page: /project/PROJECT_ID/TASK_ID/ - status: active/done - priority: 0..10 - child: subtasks data (only if task ID is specified and request contains extra=subtasks parameter) ``` -------------------------------- ### Worksection API: Get Files Request Sample Source: https://worksection.com/en/faq/api-start.html/api-files Sample URL query for the 'get_files' API method to retrieve a list of files for a specified project or task. It requires either a project ID or a task ID. ```HTTP ?action=get_files&id_project=PROJECT_ID ``` -------------------------------- ### Worksection Zapier Triggers Reference Source: https://worksection.com/en/faq/api-start.html/zapier A trigger in Zapier initiates a Zap's execution based on an event in Worksection. This section lists the available Worksection events that can serve as triggers for your Zaps. ```APIDOC Worksection Triggers: - New Comment in Task: Description: Triggered when a new comment appears in the selected Worksection task. - New Project: Description: Triggered when a new project is created in Worksection. - New Task in Project: Description: Triggered when a new task appears in the selected Worksection project. - Task Completed: Description: Triggered when a task in Worksection is marked as completed. Does not work on subtasks. ``` -------------------------------- ### API Response: Get Project Tasks Data Structure Source: https://worksection.com/en/faq/api-start.html/api-task Details the structure of the JSON response for the `get_tasks` API call, outlining all possible fields for tasks and subtasks, including nested objects for users, projects, files, subscribers, and relations. ```APIDOC get_tasks Response Data: status: string - "ok" on success data: array - list of task objects id: string - task ID name: string - task name page: string - task link status: string - state (active/done — incomplete/completed) priority: string - priority (value range: 0..10) user_from: object - task author id: string - user ID email: string - user email name: string - user name user_to: object - task executive id: string - user ID email: string - user email name: string - user name project: object - project info id: string - project ID name: string - project name page: string - project link text: string - task description in text or html format (if extra=text or extra=html) date_added: string - creation date and time (YYYY—MM—DD HH:II) date_start: string - start date (if specified) (YYYY—MM—DD) date_end: string - due date (if specified) (YYYY—MM—DD) date_closed: string - closing date and time (YYYY—MM—DD HH:II) time_end: string - due time (if specified) (HH:II) max_time: string - time estimate (if specified) max_money: string - financial estimate (if specified) tags: object - array in id: name format for task tags (if specified) files: array - attached files info (if extra=files) id: string - file ID (can be used for downloading through download method) size: string - file size (in bytes) name: string - file name with its extension page: string - part of the link for direct download subscribers: array - subscribers list (if extra=subscribers) id: string - user ID email: string - user email name: string - user name relations: object - dependencies with other tasks (if extra=relations) from: array - inbound dependencies type: string - dependency type (finish-to-start/start-to-start) task: object - linked task id: string - subtask ID name: string - subtask name page: string - subtask link status: string - active/done priority: string - 0..10 to: array - outbound dependencies (similar to 'from') child: array - subtasks data (if extra=subtasks) ``` -------------------------------- ### Get Task Tags through API: get_task_tags Source: https://worksection.com/en/faq/api-start.html/api-tags Retrieves a list of task tags, optionally filtered by group, type, or access. Returns tag ID, title, and group dataset. ```HTTP Request ?action=get_task_tags ``` ```APIDOC Optional parameters: * group — tags of a particular group You can specify group name or group ID (can be obtained through the same method from the returned group dataset or through get_task_tag_groups method) * type — groups only of particular type, possible values: status, label * access — groups only with a particular visibility, possible values: public — available to all teams (including external client teams) statuses are always visible and have public value private — available only for your company teams Returned data: * id — tag ID * title — tag name * group — tag group dataset ``` ```JSON { "status": "ok", "data": [ { "title": "LABEL_NAME", "id": "LABEL_ID", "group": { "title": "GROUP_NAME", "id": GROUP_ID, "type": "label", "access": "public" } }, { "title": "STATUS_NAME", "id": "STATUS_ID", "group": { "title": "GROUP_NAME", "id": GROUP_ID, "type": "status", "access": "public" } } ] } ``` -------------------------------- ### Complete Task API Method: complete_task Source: https://worksection.com/en/faq/api-start.html/api-task Completes a selected (sub)task via API. Specifies the required parameter and provides a sample request URL and a simple JSON response. ```URL ?action=complete_task&id_task=TASK_ID ``` ```APIDOC complete_task: Description: Completes selected (sub)task. Required Parameters: id_task: task ID ``` ```JSON { "status": "ok" } ``` -------------------------------- ### Get List of Project Tag Groups through API: get_project_tag_groups Source: https://worksection.com/en/faq/api-start.html/api-tags Returns a list of project tag groups. Optional parameters allow filtering by group 'type' (status, label) and 'access' visibility (public, private). The response includes group ID, title, type, and access. ```HTTP ?action=get_project_tag_groups ``` ```JSON { "status": "ok", "data": [ { "title": "GROUP_NAME_1", "id": GROUP_ID, "type": "status", "access": "public" }, { "title": "GROUP_NAME_2", "id": GROUP_ID, "type": "label", "access": "public" }, { "title": "GROUP_NAME_3", "id": GROUP_ID, "type": "label", "access": "private" } ] } ``` -------------------------------- ### Worksection API: Add Files to Task using PHP cURL Source: https://worksection.com/en/faq/api-start.html/api-files PHP cURL example demonstrating how to add multiple files to a task using the 'post_task' API method. It shows how to set up a POST request with 'cURLFile' for file attachments. ```PHP $curl = curl_init(); curl_setopt($curl, CURLOPT_URL,'https://youraccount.worksection.com/api/admin/ v2/?action=post_task&id_project=PROJECT_ID&title=TASK_NAME&hash=HASH'); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_POST, true); curl_setopt($curl, CURLOPT_POSTFIELDS, [ 'attach[0]' = new cURLFile('path_to_file/local_file1.pdf', 'application/pdf','nice_name1.pdf'), 'attach[1]' = new cURLFile('path_to_file/local_file2.pdf', 'application/pdf','nice_name2.pdf'), ]); $response = json_decode(curl_exec($curl), true); curl_close($curl); ``` -------------------------------- ### Editing and Deleting Worksection HubSpot Automations Source: https://worksection.com/en/faq/api-start.html/hubspot Instructions on how to modify existing automations and how to remove them within the Worksection integration settings. Important notes are provided regarding tasks in archived projects and synchronization delays. ```APIDOC Automation Management: Edit Automation: 1. Go to integration settings. 2. Click on the desired automation (1). 3. Make changes. Delete Automation: 1. Move cursor over the desired automation. 2. The delete icon (2) will appear. 3. A warning message will appear, after which you can delete. Important Notes: - Tasks will not be created in an archived project. - If a project is archived/deleted, an explanation will be marked in the integration block. - When connecting, first tasks created in 5 minutes. - Synchronization is performed every 5 minutes, so there may be some delay. ``` -------------------------------- ### Reopen Task API Method: reopen_task Source: https://worksection.com/en/faq/api-start.html/api-task Reopens a selected completed (sub)task via API. Specifies the required parameter and provides a sample request URL and a simple JSON response. ```URL ?action=reopen_task&id_task=TASK_ID ``` ```APIDOC reopen_task: Description: Reopens selected completed (sub)task. Required Parameters: id_task: task ID ``` ```JSON { "status": "ok" } ``` -------------------------------- ### Add Webhook to Worksection API Source: https://worksection.com/en/faq/api-start.html/webhooks This section details how to add a new webhook to Worksection using an OAuth 2.0 token. It includes the `curl` command for the API call, a table describing all required and optional parameters, and examples of both successful and unsuccessful JSON responses. ```curl curl -X GET -H "Authorization: Bearer " https://youraccount.worksection.com/api/oauth2?action=add_webhook& url=&events=&http_user=&http_pass= ``` ```APIDOC Parameters for add_webhook: url: (Required) Webhook URL events: (Required) Events separated by commas, possible values: post_task, post_comment, post_project, update_task, update_comment, update_project, delete_task, delete_comment, close_task. Selected events will send notifications to Webhook URL projects: (Optional) Project IDs separated by commas. If you want to limit the sending of events only for particular projects http_user: (Optional) Username (if using basic access authentication) http_pass: (Optional) Password (if using basic access authentication) ``` ```json { "status": "ok", "id": 16 } ``` ```json { "status": "error", "status_code": 11, "message": "Url should respond 200 HTTP_CODE and JSON {status:OK}", "message_details": "https://google.com" } ``` -------------------------------- ### Get Project Tags API: get_project_tags Source: https://worksection.com/en/faq/api-start.html/api-tags This API method retrieves project tags, either all or filtered by a specific group. Optional parameters allow for filtering by group, type, and access visibility. The returned data includes tag ID, title, and associated group details. ```APIDOC Method: get_project_tags Description: Returns project tags of all or selected group. Request: ?action=get_project_tags Optional Parameters: group: tags of a particular group (name or ID, can be obtained through get_project_tag_groups method) type: groups only of particular type, possible values: status, label access: groups only with a particular visibility, possible values: public (available to all teams), private (available only for your company teams) Returned Data: id: project tag ID title: project tag name group: project tag group dataset (contains title, id, type, access) Sample JSON Response: { "status": "ok", "data": [ { "title": "PROJECT_STATUS_NAME_1", "id": "PROJECT_STATUS_ID", "group": { "title": "PROJECT_GROUP_NAME", "id": "PROJECT_GROUP_ID", "type": "status", "access": "public" } }, { "title": "_PROJECT_LABEL_NAME_2", "id": "PROJECT_LABEL_ID", "group": { "title": "PROJECT_GROUP_NAME", "id": "PROJECT_GROUP_ID", "type": "label", "access": "public" } } ] } ``` -------------------------------- ### Get Project Folders API: get_project_groups Source: https://worksection.com/en/faq/api-start.html/api-projects This API endpoint retrieves information about all project folders. It returns folder ID, title, type (user or team folder), and client type for team folders. A successful request returns an 'ok' status and a list of folder data. ```APIDOC API Endpoint: get_project_groups Description: Returns all project folders info. Parameters: None Response Data Fields: id: folder ID (string) title: folder name (string) type: folder type (string, "folder" or "company") client: team folder type (integer, 0 for your company, 1 for external client) Response: status: "ok" (string) data: array of folder objects ``` ```HTTP ?action=get_project_groups ``` ```JSON { "status": "ok", "data": [ { "id": "GROUP_ID", "title": "GROUP_NAME_1", "type": "folder" }, { "id": "GROUP_ID", "title": "GROUP_NAME_2", "type": "company", "client": 0 }, { "id": "GROUP_ID", "title": "GROUP_NAME_3", "type": "company", "client": 1 } ] } ``` -------------------------------- ### API Request: Create Project (post_project) Source: https://worksection.com/en/faq/api-start.html/api-projects Demonstrates the URL query string structure for invoking the `post_project` API method to create a new project. It requires the `action` and `title` parameters. ```HTTP ?action=post_project&title=PROJECT_NAME ```