### Get All Projects (Curl) Source: https://api.freshservice.com/#delete_a_project Example using curl to fetch all projects from the Freshservice API. ```curl curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/projects' ``` -------------------------------- ### List All Departments (Response Example) Source: https://api.freshservice.com/#filter_departments Example JSON response when listing all departments. ```json { "departments": [ { "id": 1, "name": "Department of Magical Law Enforcement", "description": "Improper Use of Magic Office, Auror Headquarters, and Wizengamot Administration Services.", "head_user_id": 1, "prime_user_id": 2, "domains": [ "law.ministryofmagic.gov" ], "custom_fields": { "location": "Level 2" }, "workspace_id": 1, "created_at": "2019-04-04T04:45:15.983Z", "updated_at": "2019-04-04T04:45:15.983Z" }, { "id": 2, "name": "Department of Magical Accidents and Catastrophes", "description": "Accidental Magic Reversal Squad, Obliviator Headquarters, and Muggle-Worthy Excuses Committee.", "head_user_id": 3, "prime_user_id": 4, "domains": [ "accidents.ministryofmagic.gov" ], "custom_fields": { "location": "Level 3" }, "workspace_id": 1, "created_at": "2019-04-04T04:45:15.983Z", "updated_at": "2019-04-04T04:45:15.983Z" } ] } ``` -------------------------------- ### Add a Software Installation Source: https://api.freshservice.com/#create_an_installations Use this endpoint to add a new device to a Software installation. Ensure you have the correct application ID and provide the required installation details. ```curl curl -v -u api_key:X -H "Content-Type: application/json" -X POST -d '{"installation_machine_id": 12, "installation_path": "/Applications/Atom.app", "version": "1.41.0", "installation_date": "2019-02-05T10:23:28Z"}' 'https://domain.freshservice.com/api/v2/applications/99/installations' ``` -------------------------------- ### List All Announcements (Detailed Response Example) Source: https://api.freshservice.com/#edit_an_announcement A more detailed example of the announcement response, including announcement IDs and additional configuration options. ```json { "announcements": [ { "id": 29000008468, "created_at": "2025-01-29T12:00:13Z", "updated_at": "2025-01-29T12:00:13Z", "title": "7", "grouped_visibility_options": null, "visible_in_portal": true, "additional_config": { "email_all_audience": true, }, "workspace_id": 1, "created_by": 29001640480, "visible_from": "2025-01-29T11:59:56Z", "visible_till": null, "body": " 7 ", "body_html": "\u003Cp\u003E7\u003C/p\u003E", "visibility": "requesters_only", "state": "active", "groups": [], "agent_groups": [], "is_read": true, "send_email": false, "additional_emails": [] }, { "id": 29000008469, "created_at": "2025-01-29T12:00:13Z", "updated_at": "2025-01-29T12:00:13Z", "title": "7", "grouped_visibility_options": null, "visible_in_portal": true, "additional_config": { "email_all_audience": true, }, "workspace_id": 1, "created_by": 29001640480, "visible_from": "2025-01-29T11:59:56Z", "visible_till": null, "body": " 7 ", "body_html": "\u003Cp\u003E7\u003C/p\u003E", "visibility": "requesters_only", "state": "active", "groups": [], "agent_groups": [], "is_read": true, "send_email": false, "additional_emails": [] } ] } ``` -------------------------------- ### Project Fields Response Example Source: https://api.freshservice.com/#restore_a_project_newgen Example JSON response when fetching project fields, showing default fields like 'Name' and 'Description'. ```json { "project_fields": [ { "label": "Name", "name": "name", "type": "default_name", "default": true, "choices": [], "mandatory": true, "created_at": "2022-07-12 16:55:52", "updated_at": "2022-07-12 16:55:52" }, { "label": "Description", "name": "description", "type": "default_description", "default": true, "choices": [], "mandatory": false, "created_at": "2022-07-12 16:55:52", "updated_at": "2022-07-12 16:55:52" } ] } ``` -------------------------------- ### List All Announcements (Response Example) Source: https://api.freshservice.com/#edit_an_announcement This is an example JSON response when retrieving announcements. It includes details like title, body, visibility, and state. ```json { "announcements": [{ "title": "Email Service Outage", "body": "Email Service is down Service will be up and running in 2 hours", "body_html": "
Service will be up and running in 2 hours
", "visible_from": "2020-02-26T11:19:45.994Z", "visible_till": "2020-02-27T11:19:45.994Z", "visibility": "grouped_visibility", "departments": [19456, 23432], "groups": [34231], "state": "scheduled", "is_read": false, "send_email": false, "additional_emails": ["abc@xyz.com"], "created_at": "2020-02-20T11:16:45.994Z", "updated_at": "2020-02-20T11:16:45.994Z", "created_by": 1000000678, "workspace_id": 2 }] } ``` -------------------------------- ### List all installations of a Software Source: https://api.freshservice.com/#bulk_delete_installations This operation allows you to view the list of all the devices where the Software is installed in. ```APIDOC ## GET /api/v2/applications/[id]/installations ### Description This operation allows you to view the list of all the devices where the Software is installed in. ### Method GET ### Endpoint /api/v2/applications/[id]/installations ### Parameters #### Path Parameters - **id** (number) - Required - The ID of the application. ### Request Example ```bash curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/applications/99/installations' ``` ### Response #### Success Response (200) - **installations** (array) - A list of installation objects. - **id** (number) - The ID of the installation. - **created_at** (string) - The timestamp when the installation was created. - **updated_at** (string) - The timestamp when the installation was last updated. - **installation_path** (string) - The path where the software is installed. - **version** (string) - The version of the installed software. - **installation_machine_id** (number) - The ID of the machine where the software is installed. - **user_id** (number) - The ID of the user associated with the installation. - **department_id** (number) - The ID of the department associated with the installation. - **installation_date** (string) - The date when the software was installed. #### Response Example ```json { "installations": [ { "id": 100, "created_at": "2010-02-05T09:23:28Z", "updated_at": "2011-02-05T09:23:28Z", "installation_path": "Applications/Google Chrome.app", "version": "78.0.3904.108", "installation_machine_id": 11, "user_id": 79040, "department_id": 1705, "installation_date": "2020-10-10T00:00:00Z" } ] } ``` ``` -------------------------------- ### Sample Response for Listing Articles Source: https://api.freshservice.com/#delete_solution_article Example JSON response when retrieving a list of solution articles. ```JSON { "articles":[ { "description":"Steps: Fill in the mandatory fields ...
", "id":1, "created_at":"2020-03-29T16:38:29Z", "updated_at":"2020-03-29T16:38:29Z", "title":"Create a article", "status":1, "approval_status":null, "position":1, "folder_id":2, "category_id":2, "thumbs_up":0, "thumbs_down":0, "modified_by":null, "modified_at":"2020-03-29T16:38:29Z", "inserted_into_tickets":0, "url":null, "article_type":1, "agent_id":1, "views":0, "description_text":" Steps: Fill in the mandatory fields ... ", "keywords":[], "review_date":null, "workspace_id": 2, "deleted": false }, { "description":"Steps: Fill in the mandatory fields ...
", "id":2, "created_at":"2020-03-29T16:38:44Z", "updated_at":"2020-03-29T16:38:44Z", "title":"Create a article", "status":1, "approval_status":null, "position":2, "folder_id":2, "category_id":2, "thumbs_up":0, "thumbs_down":0, "modified_by":null, "modified_at":"2020-03-29T16:38:44Z", "inserted_into_tickets":0, "url":null, "article_type":1, "agent_id":1, "views":0, "description_text":" Steps: Fill in the mandatory fields ... ", "keywords":[], "review_date":null, "workspace_id": 2, "deleted": false } ] } ``` -------------------------------- ### Paginate Ticket List Source: https://api.freshservice.com/#update_a_ticket Get the second page (tickets from 11-20) of a list of all tickets. This example assumes 10 tickets per page. ```APIDOC ## GET /api/v2/tickets?per_page=10&page=2 ### Description Retrieves a specific page of tickets with a defined number of tickets per page. ### Method GET ### Endpoint /api/v2/tickets ### Query Parameters - **per_page** (integer) - Optional - The number of tickets to display per page. Defaults to 30. - **page** (integer) - Optional - The page number to retrieve. ``` -------------------------------- ### Onboarding Request Response Example Source: https://api.freshservice.com/#view_onboarding_request This is a sample JSON response when successfully retrieving an onboarding request. It includes details about the request, actors, fields, and lookup values. ```json { "onboarding_request": { "id": 253, "created_at": "2020-07-10T11:50:55Z", "updated_at": "2020-07-10T11:50:55Z", "status": 1, "subject": "Employee Onboarding Request for Andrea", "ticket_id": 20, "actors": { "HR Manager": { "email": "sample@freshservice.com", "name": "Support", "response_status": "Completed" } }, "fields": { "cf_employee_name": "Andrea", "cf_job_title": "HR", "cf_date_of_joining": "20-08-2020", "cf_all_users": 2, "cf_agents": null, "cf_requesters": null, "cf_department": 5, "cf_assets": 1, "cf_location": 5, "cf_hierarchy": "L3", "cf_online_portfolio": null, "cf_additional_info": null, "cf_experience": null, "cf_verified": true, "cf_category": null, "cf_subcategory": "", "msf_area_of_expertise": [ "Ruby", "Java" ] }, "lookup_values": { "cf_all_users": { "id": 2, "first_name": "Andrea", "last_name": "Paul", "email": "andrea@freshservice.com", "mobile": 12345XXXXX, "phone": 12XXXXX }, "cf_department": { "id": 5, "name": "HR", "description": "HR Team" }, "cf_assets": { "id": 1, "name": "Andrea's Laptop", "display_id": 527 }, "cf_location": { "id": 5, "name": "Canada" }, "msf_preferred_locations": [ { "id": 53, "name": "India" }, { "id": 57, "name": "America" } ] } } } ``` -------------------------------- ### Filter Tickets by Priority Source: https://api.freshservice.com/#filter_tickets This example demonstrates how to filter tickets by priority using a GET request. You can specify multiple priorities using the OR operator. ```APIDOC ## GET /api/v2/tickets/filter ### Description Retrieves a list of tickets that match the specified filter criteria. ### Method GET ### Endpoint `/api/v2/tickets/filter` ### Query Parameters - **workspace_id** (integer) - Required - The ID of the workspace to filter tickets from. - **query** (string) - Required - The filter query string. Supports operators like OR, AND, and field-specific filters (e.g., `priority:3`). ### Request Example ```bash curl -v -u api_key:X -X GET "https://domain.freshservice.com/api/v2/tickets/filter?workspace_id=0&query=\"priority%3A4%20OR%20priority%3A3\"" ``` ### Response #### Success Response (200) Returns a JSON object containing a list of tickets that match the query. The exact structure of the ticket object is not detailed in the source. #### Response Example (Response structure not provided in source) ``` -------------------------------- ### Create a Group Source: https://api.freshservice.com/#view_a_group This example demonstrates how to create a basic group with a name, description, and assign members and observers. ```APIDOC ## POST /api/v2/groups ### Description Creates a new group in Freshservice. ### Method POST ### Endpoint /api/v2/groups ### Request Body - **name** (string) - Required - The name of the group. - **description** (string) - Optional - A description for the group. - **restricted** (boolean) - Optional - Whether the group is restricted. - **members** (array of integers) - Optional - List of agent IDs to be added as members. - **observers** (array of integers) - Optional - List of agent IDs to be added as observers. - **leaders** (array of integers) - Optional - List of agent IDs to be added as leaders. - **approval_required** (boolean) - Optional - Whether approval is required for this group. - **workspace_id** (integer) - Optional - The ID of the workspace to create the group in. ### Request Example ```json { "name": "HR Group", "description": "To handle all HR related sensitive tickets", "restricted": true, "members": [15], "leaders": [15] } ``` ### Response #### Success Response (201 Created) - **group** (object) - Details of the created group. - **id** (integer) - The unique identifier for the group. - **name** (string) - The name of the group. - **description** (string) - The description of the group. - **created_at** (string) - The timestamp when the group was created. - **updated_at** (string) - The timestamp when the group was last updated. - **auto_ticket_assign** (boolean) - Indicates if auto ticket assignment is enabled. - **restricted** (boolean) - Indicates if the group is restricted. - **approval_required** (boolean) - Indicates if approval is required for the group. - **workspace_id** (integer) - The ID of the workspace the group belongs to. - **members** (array of integers) - List of agent IDs in the group. - **observers** (array of integers) - List of agent IDs observing the group. - **leaders** (array of integers) - List of agent IDs who are leaders of the group. ### Response Example ```json { "group": { "id": 5, "name": "Linux Support itsm", "description": "Support team for Linux VMs, workstations, and servers", "business_hours_id": null, "escalate_to": 1155, "unassigned_for": "30m", "restricted": false, "workspace_id": 2, "members": [1], "observers": [16], "leaders": [], "members_pending_approval": [], "leaders_pending_approval": [], "observers_pending_approval": [], "auto_ticket_assign": true, "created_at": "2020-01-08T07:53:41+05:30", "updated_at": "2020-01-08T07:53:41+05:30" } } ``` ``` -------------------------------- ### List Vendors with Pagination Source: https://api.freshservice.com/#update_a_vendor Retrieves a paginated list of vendors, useful for handling large numbers of vendors. This example gets the second page with 30 vendors per page. ```curl curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/vendors?per_page=30&page=2' ``` -------------------------------- ### Create a Solution Folder (Curl) Source: https://api.freshservice.com/#create_solution_folder_with_approval Use this cURL command to create a new solution folder with specified visibility and department IDs. Ensure you replace 'api_key:X' and 'domain.freshservice.com' with your actual credentials and domain. ```curl curl -u api_key:X -H "Content-Type: application/json" -X POST -d '{ "name":"Folder API", "visibility":4, "description":"Folder CRUD Operations", "department_ids": [4,5], "category_id": 2 }' https://domain.freshservice.com/api/v2/solutions/folders ``` -------------------------------- ### Response for Solution Folder Creation Source: https://api.freshservice.com/#create_solution_folder_with_approval This is an example JSON response when a solution folder is successfully created using the API. ```json { "folder": { "description": "Folder CRUD Operations", "id": 2, "created_at": "2020-03-29T14:43:28Z", "updated_at": "2020-03-29T14:43:28Z", "name": "Folder API", "category_id": 2, "position": 1, "visibility": 4, "approval_settings": null, "default_folder": false, "department_ids": [4, 5], "manage_by_group_ids": [], "workspace_id": 2, "deleted": false } } ``` -------------------------------- ### Get Agent or Contact by External ID Source: https://api.freshservice.com/#list_all_requester_fields Retrieve an agent or contact using their unique `external_id`. Note that this example queries the `/agents` endpoint, but the concept applies to requesters as well. ```curl curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/agents?query="external_id:'aa1234"' ``` -------------------------------- ### View Paginated List of Changes Source: https://api.freshservice.com/#view_all_changes Retrieves a specific page of changes, with 10 items per page. This example shows how to get the second page of results. Requires API key for authentication. ```curl curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/changes?per_page=10&page=2' ``` -------------------------------- ### Create a Solution Folder with Approval Settings (Curl) Source: https://api.freshservice.com/#create_solution_folder_with_approval This cURL command demonstrates how to create a solution folder and configure specific approval settings, including the approval type and a list of approver IDs. Replace placeholders with your actual values. ```curl curl -u api_key:X -H "Content-Type: application/json" -X POST -d '{ "name":"Folder API", "visibility":4, "description":"Folder CRUD Operations", "department_ids": [4,5], "category_id": 2, "approval_settings": {"approval_type": 1, "approver_ids": [1]} }' https://domain.freshservice.com/api/v2/solutions/folders ``` -------------------------------- ### Get Agent or Requester by External ID Source: https://api.freshservice.com/#filter_requesters Retrieve a specific agent or requester using their unique external ID. Note: This example uses the `/agents` endpoint, adjust if targeting requesters specifically. ```bash curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/agents?query="external_id:'aa1234'"' ``` -------------------------------- ### Create Onboarding Request using cURL Source: https://api.freshservice.com/#create_onboarding_request This cURL command demonstrates how to send a POST request to create an onboarding request. Ensure you replace 'api_key:X' and 'domain.freshservice.com' with your actual credentials and domain. ```curl curl -u api_key:X -H "Content-Type: application/json" -X POST -d '{ "fields": { "cf_employee_name": "Andrea","cf_job_title": "HR", "cf_date_of_joining": "2020-08-20","cf_all_users": "andrea@freshservice.com","cf_department": "HR","cf_assets": 1,"cf_location": 5,"cf_hierarchy": "L3","cf_verified": true}}' https://domain.freshservice.com/api/v2/onboarding_requests ``` -------------------------------- ### Get Journey Requests for a Specific Journey ID Source: https://api.freshservice.com/#view_all_journey_requests This example shows how to retrieve all journey requests associated with a particular journey ID. The 'value' field in the 'filter' attribute should contain the desired journey ID. ```json { "data": { "query": { "filter": [ { "attributes": [ { "field": "journey_id", "operator": "is_in", "value": [ 1 ] } ] } ] } } } ``` -------------------------------- ### Get Older Ticket Activities using Start Token Source: https://api.freshservice.com/#get_ticket_activities Demonstrates how to retrieve older ticket activities by using the `start_token` provided in the `next_page_url` from a previous request. This is useful for fetching more than the default 20 activities. ```APIDOC ## Get Older Ticket Activities ### Description To retrieve older activities, use the `start_token` obtained from the `next_page_url` in a previous API response. This allows you to paginate through ticket activities. ### Method GET ### Endpoint /api/v2/tickets/[id]/activities ### Query Parameters - **start_token** (string) - Required - The token obtained from `next_page_url` to fetch the subsequent set of activities. ### Request Example ```bash curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/tickets/[id]/activities?start_token=token_id' ``` ### Response #### Success Response (200) - **activities** (array) - A list of ticket activity objects. - **next_page_url** (string) - A URL to fetch the next page of activities if available. #### Response Example ```json { "activities": [ { "actor": {"id": 4223, "name": "Filius Flitwick"}, "content": "created ticket for Email210609233300, set Status as Open, set Urgency as Low, set Priority as Medium, set Source as Portal, set Type as Incident and set Impact as Low", "sub_contents": [ "System executed Default SLA Policy (SLA)" ], "created_at": "2021-06-09T18:03:01Z" } ], "next_page_url": "https://domain.freshservice.com/api/v2/tickets/152/activities?start_token=another_token_id" } ``` ``` -------------------------------- ### View All Solution Folders (Curl) Source: https://api.freshservice.com/#delete_solution_folder Use this command to retrieve a list of all solution folders. Ensure you replace 'api_key:X' and 'domain.freshservice.com' with your actual credentials and domain. ```curl curl -u api_key:X -H "Content-Type: application/json" -X GET https://domain.freshservice.com/api/v2/solutions/folders ``` -------------------------------- ### Get Shift Events Source: https://api.freshservice.com/#view_calendar_events_shift This endpoint retrieves on-call calendar events for a specific shift within a given time frame. You need to provide the start and end times, along with the shift ID and schedule ID. ```APIDOC ## GET /api/v2/oncall/shift-events ### Description Retrieves on-call calendar events for a specific shift within a given time frame. ### Method GET ### Endpoint /api/v2/oncall/shift-events ### Parameters #### Query Parameters - **start_time** (datetime) - Required - Indicates the start date and time from when the events need to be fetched. - **end_time** (datetime) - Required - Indicates the end date and time till when the events need to be fetched. - **shift_id** (number) - Required - The ID of the shift within the on-call schedule for which calendar events need to be fetched. - **schedule_id** (number) - Required - The ID of the on-call schedule for which calendar events should be fetched. ### Request Example ```bash curl -v -u api_key:X -X GET "https://domain.freshservice.com/api/v2/oncall/shift-events?start_time=2024-04-18T05:00:00Z&end_time=2024-04-19T05:00:00Z&shift_id=201&schedule_id=25988" ``` ### Response #### Success Response (200) - **shift_events** (array) - A list of on-call shift events. - **id** (number) - The unique identifier of the event. - **user** (object) - Information about the user assigned to the event. - **id** (number) - The user's ID. - **name** (string) - The user's name. - **email** (string) - The user's email address. - **second_email** (string) - The user's secondary email address. - **product_user_id** (string) - The Freshservice product user ID. - **phone** (string) - The user's phone number. - **mobile** (string) - The user's mobile number. - **agent** (boolean) - Indicates if the user is an agent. - **group_ids** (string) - Comma-separated list of group IDs the user belongs to. - **event_start_date_time** (datetime) - The start date and time of the event. - **event_end_date_time** (datetime) - The end date and time of the event. - **overridden** (boolean) - Indicates if the event was overridden. - **roster_type** (string) - The type of roster (e.g., PRIMARY, SECONDARY). - **shift** (object) - Information about the shift. - **id** (number) - The shift's ID. - **name** (string) - The shift's name. - **shift_timezone** (string) - The timezone of the shift. - **timezone_offset** (number) - The timezone offset in seconds. - **schedule** (object) - Information about the schedule. - **id** (number) - The schedule's ID. - **name** (string) - The schedule's name. - **agent_group_id** (number) - The ID of the agent group associated with the schedule. - **workspace_id** (number) - The ID of the workspace. #### Response Example ```json { "shift_events": [ { "id": 373282400, "user": { "id": 47, "name": "John Doe", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "1000814658", "phone": "+13232323232", "mobile": null, "agent": true, "group_ids": "1000186851,1000186855,1000206400,1000206869,1000207617,1000207620,1000207696,1000208087" }, "event_start_date_time": "2024-04-18T05:00:00Z", "event_end_date_time": "2024-04-19T05:00:00Z", "overridden": false, "roster_type": "PRIMARY", "shift": { "id": 11413, "name": "OCS shift", "shift_timezone": "America/New_York", "timezone_offset": -18000 }, "schedule": { "id": 8569, "name": "OCS schedule", "agent_group_id": 1000207617, "workspace_id": 5 } } ] } ``` ``` -------------------------------- ### List Project Tasks with Filter and Pagination Source: https://api.freshservice.com/#filter_all_project_tasks_newgen Example demonstrating how to filter project tasks by status and specify the number of results per page. ```bash /api/v2/pm/projects/1/tasks?filter=all ``` ```bash api/v2/pm/projects/1/tasks?page=1 ``` ```bash api/v2/pm/projects/1/tasks?per_page=20 ``` -------------------------------- ### Get Shift Events Source: https://api.freshservice.com/#view_calendar_events_shift_user This operation retrieves on-call events for a user within a specified shift and schedule. It requires the start and end times for the event window, the shift ID, schedule ID, and the user ID. ```APIDOC ## GET /api/v2/oncall/shift-events ### Description Retrieves on-call calendar events for a user within a specific shift. ### Method GET ### Endpoint /api/v2/oncall/shift-events ### Query Parameters - **start_time** (datetime) - Required - Indicates the start date and time from which to fetch events. - **end_time** (datetime) - Required - Indicates the end date and time until which to fetch events. - **shift_id** (number) - Required - The ID of the shift within the on-call schedule. - **schedule_id** (number) - Required - The ID of the on-call schedule. - **user_id** (number) - Required - The ID of the user for whom to fetch events. ### Request Example ``` curl -v -u api_key:X -X GET "https://domain.freshservice.com/api/v2/oncall/shift-events?start_time=2024-04-19T18:30:00Z&end_time=2024-04-20T18:30:00Z&shift_id=201&schedule_id=8569&user_id=25988" ``` ### Response #### Success Response (200) - **shift_events** (array) - A list of on-call shift events. - **id** (number) - The unique identifier for the shift event. - **user** (object) - Information about the user associated with the event. - **id** (number) - The user's ID. - **name** (string) - The user's name. - **email** (string) - The user's email address. - **second_email** (string) - The user's secondary email address (nullable). - **product_user_id** (string) - The user's product-specific ID. - **phone** (string) - The user's phone number (nullable). - **mobile** (string) - The user's mobile number (nullable). - **agent** (boolean) - Indicates if the user is an agent. - **group_ids** (string) - Comma-separated list of group IDs the user belongs to. - **event_start_date_time** (datetime) - The start date and time of the on-call event. - **event_end_date_time** (datetime) - The end date and time of the on-call event. - **overridden** (boolean) - Indicates if the event was overridden. - **roster_type** (string) - The type of roster for the event (e.g., TERTIARY). - **shift** (object) - Information about the shift. - **id** (number) - The shift's ID. - **name** (string) - The shift's name. - **shift_timezone** (string) - The timezone of the shift. - **timezone_offset** (number) - The timezone offset in minutes. - **schedule** (object) - Information about the schedule. - **id** (number) - The schedule's ID. - **name** (string) - The schedule's name. - **agent_group_id** (number) - The ID of the agent group associated with the schedule. - **workspace_id** (number) - The ID of the workspace. #### Response Example ```json { "shift_events": [ { "id": 885518224, "user": { "id": 25988, "name": "John Doe", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "102829", "phone": null, "mobile": null, "agent": true, "group_ids": "108868,110234,110934" }, "event_start_date_time": "2024-04-19T18:30:00Z", "event_end_date_time": "2024-04-20T18:30:00Z", "overridden": false, "roster_type": "TERTIARY", "shift": { "id": 47022, "name": "Check Workflow group", "shift_timezone": "Asia/Kolkata", "timezone_offset": 19800 }, "schedule": { "id": 62400, "name": "AA OCS", "agent_group_id": 108868, "workspace_id": 2 } } ] } ``` ``` -------------------------------- ### Filter and Search Assets by Serial Number and Workspace Source: https://api.freshservice.com/#filter_assets Combine search and filter parameters to find assets. This example retrieves assets with a serial number starting with 'HSN' and belonging to a specific workspace, while also filtering for assets that are 'IN STOCK'. ```bash curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/assets?search="serial_number%3A%27HSN%27"&filter="asset_state%3A%27IN%20STOCK%27%20AND%20workspace_id%3A%202"' ``` -------------------------------- ### Create a Group with specific settings Source: https://api.freshservice.com/#create_a_group Example of creating a group with specific settings like auto-ticket assignment and workspace ID. Useful for detailed group configurations. ```json { "group": { "id": 29000574206, "name": "Incident Team", "description": "Incident Management Team", "escalate_to": null, "unassigned_for": null, "business_hours_id": null, "created_at": "2025-02-06T15:00:48Z", "updated_at": "2025-02-06T15:00:48Z", "auto_ticket_assign": false, "restricted": false, "approval_required": false, "ocs_schedule_id": null, "workspace_id": 1, "members": [], "observers": [], "leaders": [], "members_pending_approval": [], "leaders_pending_approval": [], "observers_pending_approval": [] } } ``` -------------------------------- ### Example On-Call Calendar Events Data Source: https://api.freshservice.com/#view_calendar_events_schedule This JSON structure represents a list of on-call calendar events for a schedule. Each event includes agent details, start and end times, override status, roster type, and associated shift and schedule information. ```json { "agent_group_id": 1000207617, "workspace_id": 5 }, { "id": 0, "user": { "id": 16146, "name": "Staging Test Agent", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "1001447031", "phone": null, "mobile": null, "agent": true, "group_ids": "1000207613,1000207614,1000207615,1000207616,1000207617,1000207620" }, "event_start_date_time": "2024-04-20T05:00:00Z", "event_end_date_time": "2024-04-21T05:00:00Z", "overridden": false, "roster_type": "SECONDARY", "shift": { "id": 11413, "name": "OCS shift", "shift_timezone": "America/New_York", "timezone_offset": -18000 }, "schedule": { "id": 8569, "name": "OCS schedule", "agent_group_id": 1000207617, "workspace_id": 5 } }, { "id": 373282548, "user": { "id": 47, "name": "John Doe", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "1000814658", "phone": "+13232323232", "mobile": null, "agent": true, "group_ids": "1000186851,1000186855,1000206400,1000206869,1000207617,1000207620,1000207696,1000208087" }, "event_start_date_time": "2024-04-18T05:00:00Z", "event_end_date_time": "2024-04-19T05:00:00Z", "overridden": false, "roster_type": "TERTIARY", "shift": { "id": 11413, "name": "OCS shift", "shift_timezone": "America/New_York", "timezone_offset": -18000 }, "schedule": { "id": 8569, "name": "OCS schedule", "agent_group_id": 1000207617, "workspace_id": 5 } }, { "id": 0, "user": { "id": 47, "name": "John Doe", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "1000814658", "phone": "+13232323232", "mobile": null, "agent": true, "group_ids": "1000186851,1000186855,1000206400,1000206869,1000207617,1000207620,1000207696,1000208087" }, "event_start_date_time": "2024-04-19T05:00:00Z", "event_end_date_time": "2024-04-20T05:00:00Z", "overridden": false, "roster_type": "TERTIARY", "shift": { "id": 11413, "name": "OCS shift", "shift_timezone": "America/New_York", "timezone_offset": -18000 }, "schedule": { "id": 8569, "name": "OCS schedule", "agent_group_id": 1000207617, "workspace_id": 5 } }, { "id": 0, "user": { "id": 47, "name": "John Doe", "email": "john.doe@gmail.com", "second_email": null, "product_user_id": "1000814658", "phone": "+13232323232", "mobile": null, "agent": true, "group_ids": "1000186851,1000186855,1000206400,1000206869,1000207617,1000207620,1000207696,1000208087" }, "event_start_date_time": "2024-04-20T05:00:00Z", "event_end_date_time": "2024-04-21T05:00:00Z", "overridden": false, "roster_type": "TERTIARY", "shift": { "id": 11413, "name": "OCS shift", "shift_timezone": "America/New_York", "timezone_offset": -18000 }, "schedule": { "id": 8569, "name": "OCS schedule", "agent_group_id": 1000207617, "workspace_id": 5 } } ] ``` -------------------------------- ### Create Solution Article Response (Freshservice) Source: https://api.freshservice.com/#create_secondary_language_article This is a sample response when a solution article is successfully created in Freshservice. It includes details of the created article. ```json { "article": { "description":"Steps: Fill in the mandatory fields ...
", "id":527, "created_at":"2020-03-29T16:44:26Z", "updated_at":"2020-03-29T16:44:26Z", "title":"Create a article", "status":1, "approval_status":null, "position":1, "folder_id":2, "category_id":2, "thumbs_up":0, "thumbs_down":0, "modified_by":null, "modified_at":"2020-03-29T16:44:26Z", "inserted_into_tickets":0, "url":null, "article_type":1, "user_id":1, "views":0, "description_text":" Steps: Fill in the mandatory fields ... ", "keywords":[], "review_date":null, "tags":[ "tag1" ], "attachments":[], "approvals":[], "cloud_files":[], "workspace_id": 2, "deleted": false } } ``` -------------------------------- ### Response for Viewing Solution Folders Source: https://api.freshservice.com/#delete_solution_folder This is a sample JSON response when retrieving solution folders. It includes details such as folder name, description, ID, and creation/update timestamps. ```json { "folders": [ { "name": "Folder API", "description": "Folder API related Operations", "id": 1, "created_at": "2020-03-29T14:43:28Z", "updated_at": "2020-03-29T15:30:34Z", "category_id": 2, "position": 1, "visibility": 1, "approval_settings": null, "default_folder": false, "manage_by_group_ids": [], "workspace_id": 2, "deleted": false }, { "name": "Folder CRUD", "description": "Folder CRUD Operations", "id": 2, "created_at": "2020-03-29T14:14:30Z", "updated_at": "2020-03-29T14:25:46Z", "category_id": 2, "position": 2, "visibility": 4, "approval_settings": null, "default_folder": false, "department_ids": [5], "manage_by_group_ids": [], "workspace_id": 2, "deleted": false } ] } ``` -------------------------------- ### Associated Assets Response Example Source: https://api.freshservice.com/#reject_contract Example JSON response when listing associated assets of a contract. ```json { "associated_assets": [ { "id": 10, "display_id": 66, "name": "Macbook Pro", "description": null, "asset_type_id": 3, "impact": "low", "usage_type": "permanent", "asset_tag": "ASSET-66", "user_id": null, "department_id": null, "location_id": null, "agent_id": null, "group_id": null, "assigned_on": null, "created_at": "2021-11-10T07:50:32Z", "updated_at": "2021-11-10T07:50:32Z" }, { "id": 11, "display_id": 73, "name": "iPad Air", "description": null, "asset_type_id": 761355, "impact": "low", "usage_type": "permanent", "asset_tag": "ASSET-73", "user_id": null, "department_id": null, "location_id": null, "agent_id": null, "group_id": null, "assigned_on": null, "created_at": "2021-11-25T11:54:03Z", "updated_at": "2021-11-25T12:05:01Z" } ] } ``` -------------------------------- ### List all Software Installations Source: https://api.freshservice.com/#bulk_delete_installations Retrieve a list of all devices where a specific software is installed. Requires the software's ID. ```curl curl -v -u api_key:X -X GET 'https://domain.freshservice.com/api/v2/applications/99/installations' ```