diff --git a/ballerina/client.bal b/ballerina/client.bal index 6f95b13..518ff90 100644 --- a/ballerina/client.bal +++ b/ballerina/client.bal @@ -17,6 +17,7 @@ // specific language governing permissions and limitations // under the License. +import ballerina/data.jsondata; import ballerina/http; # Zendesk Support API endpoints @@ -24,5076 +25,4990 @@ public isolated client class Client { final http:Client clientEp; # Gets invoked to initialize the `connector`. # - # + config - The configurations to be used when initializing the `connector` - # + serviceUrl - URL of the target service - # + return - An error if connector initialization failed - public isolated function init(ConnectionConfig config, string serviceUrl) returns error? { - http:ClientConfiguration httpClientConfig = {auth: config.auth, httpVersion: config.httpVersion, timeout: config.timeout, forwarded: config.forwarded, poolConfig: config.poolConfig, compression: config.compression, circuitBreaker: config.circuitBreaker, retryConfig: config.retryConfig, validation: config.validation}; - do { - if config.http1Settings is ClientHttp1Settings { - ClientHttp1Settings settings = check config.http1Settings.ensureType(ClientHttp1Settings); - httpClientConfig.http1Settings = {...settings}; - } - if config.http2Settings is http:ClientHttp2Settings { - httpClientConfig.http2Settings = check config.http2Settings.ensureType(http:ClientHttp2Settings); - } - if config.cache is http:CacheConfig { - httpClientConfig.cache = check config.cache.ensureType(http:CacheConfig); - } - if config.responseLimits is http:ResponseLimitConfigs { - httpClientConfig.responseLimits = check config.responseLimits.ensureType(http:ResponseLimitConfigs); - } - if config.secureSocket is http:ClientSecureSocket { - httpClientConfig.secureSocket = check config.secureSocket.ensureType(http:ClientSecureSocket); - } - if config.proxy is http:ProxyConfig { - httpClientConfig.proxy = check config.proxy.ensureType(http:ProxyConfig); - } - } - http:Client httpEp = check new (serviceUrl, httpClientConfig); - self.clientEp = httpEp; - return; + # + config - The configurations to be used when initializing the `connector` + # + serviceUrl - URL of the target service + # + return - An error if connector initialization failed + public isolated function init(ConnectionConfig config, string serviceUrl = "//api") returns error? { + http:ClientConfiguration httpClientConfig = {auth: config.auth, httpVersion: config.httpVersion, http1Settings: config.http1Settings, http2Settings: config.http2Settings, timeout: config.timeout, forwarded: config.forwarded, followRedirects: config.followRedirects, poolConfig: config.poolConfig, cache: config.cache, compression: config.compression, circuitBreaker: config.circuitBreaker, retryConfig: config.retryConfig, cookieConfig: config.cookieConfig, responseLimits: config.responseLimits, secureSocket: config.secureSocket, proxy: config.proxy, socketConfig: config.socketConfig, validation: config.validation, laxDataBinding: config.laxDataBinding}; + self.clientEp = check new (serviceUrl, httpClientConfig); } + # List assignable groups and agents based on query matched against name # - # + name - Query string used to search assignable groups & agents in the AssigneeField - # + return - Success response - resource isolated function get api/lotus/assignables/autocomplete\.json(string name, string accept = "application/json") returns AssigneeFieldAssignableGroupsAndAgentsSearchResponse|error { - string resourcePath = string `/api/lotus/assignables/autocomplete.json`; - map queryParam = {"name": name}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AssigneeFieldAssignableGroupsAndAgentsSearchResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get lotus/assignables/autocomplete\.json(ListAssigneeFieldAssignableGroupsAndAgentsSearchHeaders headers = {}, *ListAssigneeFieldAssignableGroupsAndAgentsSearchQueries queries) returns AssigneeFieldAssignableGroupsAndAgentsSearchResponse|error { + string resourcePath = string `/lotus/assignables/autocomplete.json`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List assignable groups on the AssigneeField # - # + return - Success response - resource isolated function get api/lotus/assignables/groups\.json() returns AssigneeFieldAssignableGroupsResponse|error { - string resourcePath = string `/api/lotus/assignables/groups.json`; - AssigneeFieldAssignableGroupsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get lotus/assignables/groups\.json(map headers = {}) returns AssigneeFieldAssignableGroupsResponse|error { + string resourcePath = string `/lotus/assignables/groups.json`; + return self.clientEp->get(resourcePath, headers); } + # List assignable agents from a group on the AssigneeField # - # + group_id - The ID of the group - # + return - Success response - resource isolated function get api/lotus/assignables/groups/[int group_id]/agents\.json(string accept = "application/json") returns AssigneeFieldAssignableGroupAgentsResponse|error { - string resourcePath = string `/api/lotus/assignables/groups/${getEncodedUri(group_id)}/agents.json`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AssigneeFieldAssignableGroupAgentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + groupId - The ID of the group + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get lotus/assignables/groups/[int groupId]/agents\.json(ListAssigneeFieldAssignableGroupAgentsHeaders headers = {}) returns AssigneeFieldAssignableGroupAgentsResponse|error { + string resourcePath = string `/lotus/assignables/groups/${getEncodedUri(groupId)}/agents.json`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Get sources by target # - # + target_type - The type of object the relationship field is targeting. + # + targetType - The type of object the relationship field is targeting. # The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - # + target_id - The id of the object the relationship field is targeting - # + field_id - The id of the lookup relationship field - # + source_type - The type of object the relationship field belongs to (example. ticket field belongs to a ticket object). + # + targetId - The id of the object the relationship field is targeting + # + fieldId - The id of the lookup relationship field + # + sourceType - The type of object the relationship field belongs to (example. ticket field belongs to a ticket object). # The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - # + return - Success response - resource isolated function get api/v2/[string target_type]/[int target_id]/relationship_fields/[int field_id]/[string source_type](string accept = "application/json") returns ReverseLookupResponse|error { - string resourcePath = string `/api/v2/${getEncodedUri(target_type)}/${getEncodedUri(target_id)}/relationship_fields/${getEncodedUri(field_id)}/${getEncodedUri(source_type)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ReverseLookupResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/[string targetType]/[int targetId]/relationship_fields/[int fieldId]/[string sourceType](GetSourcesByTargetHeaders headers = {}) returns ReverseLookupResponse|error { + string resourcePath = string `/v2/${getEncodedUri(targetType)}/${getEncodedUri(targetId)}/relationship_fields/${getEncodedUri(fieldId)}/${getEncodedUri(sourceType)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Settings # - # + return - Success response - resource isolated function get api/v2/account/settings() returns AccountSettingsResponse|error { - string resourcePath = string `/api/v2/account/settings`; - AccountSettingsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/account/settings(map headers = {}) returns AccountSettingsResponse|error { + string resourcePath = string `/v2/account/settings`; + return self.clientEp->get(resourcePath, headers); } + # Update Account Settings # - # + return - Success response - resource isolated function put api/v2/account/settings() returns AccountSettingsResponse|error { - string resourcePath = string `/api/v2/account/settings`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/account/settings(map headers = {}) returns AccountSettingsResponse|error { + string resourcePath = string `/v2/account/settings`; http:Request request = new; - AccountSettingsResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # Create Trial Account # - # + return - Created response - resource isolated function post api/v2/accounts() returns TrialAccountResponse|error { - string resourcePath = string `/api/v2/accounts`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/accounts(map headers = {}) returns TrialAccountResponse|error { + string resourcePath = string `/v2/accounts`; http:Request request = new; - TrialAccountResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Verify Subdomain Availability # - # + subdomain - Specify the name of the subdomain you want to verify. The name can't contain underscores, hyphens, or spaces. - # + return - Success response - resource isolated function get api/v2/accounts/available(string subdomain, string accept = "application/json") returns Inline_response_200|error { - string resourcePath = string `/api/v2/accounts/available`; - map queryParam = {"subdomain": subdomain}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - Inline_response_200 response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/accounts/available(VerifySubdomainAvailabilityHeaders headers = {}, *VerifySubdomainAvailabilityQueries queries) returns InlineResponse200|error { + string resourcePath = string `/v2/accounts/available`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Activities # - # + since - A UTC time in ISO 8601 format to return ticket activities since said date. - # + return - Success response - resource isolated function get api/v2/activities(string accept = "application/json", string? since = ()) returns ActivitiesResponse|error { - string resourcePath = string `/api/v2/activities`; - map queryParam = {"since": since}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ActivitiesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/activities(ListActivitiesHeaders headers = {}, *ListActivitiesQueries queries) returns ActivitiesResponse|error { + string resourcePath = string `/v2/activities`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Activity # - # + activity_id - The activity ID - # + return - Success response - resource isolated function get api/v2/activities/[int activity_id](string accept = "application/json") returns ActivityResponse|error { - string resourcePath = string `/api/v2/activities/${getEncodedUri(activity_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ActivityResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + activityId - The activity ID + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/activities/[int activityId](ShowActivityHeaders headers = {}) returns ActivityResponse|error { + string resourcePath = string `/v2/activities/${getEncodedUri(activityId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Count Activities # - # + return - Count of ticket activities - resource isolated function get api/v2/activities/count() returns ActivitiesCountResponse|error { - string resourcePath = string `/api/v2/activities/count`; - ActivitiesCountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Count of ticket activities + resource isolated function get v2/activities/count(map headers = {}) returns ActivitiesCountResponse|error { + string resourcePath = string `/v2/activities/count`; + return self.clientEp->get(resourcePath, headers); } + # Report Channelback Error to Zendesk # - # + return - Success response - resource isolated function post api/v2/any_channel/channelback/report_error() returns string|error { - string resourcePath = string `/api/v2/any_channel/channelback/report_error`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/any_channel/channelback/report_error(map headers = {}) returns string|error { + string resourcePath = string `/v2/any_channel/channelback/report_error`; http:Request request = new; - string response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Push Content to Support # - # + return - Success response - resource isolated function post api/v2/any_channel/push() returns ChannelFrameworkPushResultsResponse|error { - string resourcePath = string `/api/v2/any_channel/push`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/any_channel/push(map headers = {}) returns ChannelFrameworkPushResultsResponse|error { + string resourcePath = string `/v2/any_channel/push`; http:Request request = new; - ChannelFrameworkPushResultsResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Validate Token # - # + return - Success response - resource isolated function post api/v2/any_channel/validate_token() returns string|error { - string resourcePath = string `/api/v2/any_channel/validate_token`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/any_channel/validate_token(map headers = {}) returns string|error { + string resourcePath = string `/v2/any_channel/validate_token`; http:Request request = new; - string response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Attachment # - # + attachment_id - The ID of the attachment - # + return - Success Response - resource isolated function get api/v2/attachments/[int attachment_id](string accept = "application/json") returns AttachmentResponse|error { - string resourcePath = string `/api/v2/attachments/${getEncodedUri(attachment_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AttachmentResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + attachmentId - The ID of the attachment + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/attachments/[int attachmentId](ShowAttachmentHeaders headers = {}) returns AttachmentResponse|error { + string resourcePath = string `/v2/attachments/${getEncodedUri(attachmentId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Attachment for Malware # - # + attachment_id - The ID of the attachment - # + return - Success response - resource isolated function put api/v2/attachments/[int attachment_id](AttachmentUpdateRequest payload, string accept = "application/json") returns AttachmentResponse|error { - string resourcePath = string `/api/v2/attachments/${getEncodedUri(attachment_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attachmentId - The ID of the attachment + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/attachments/[int attachmentId](AttachmentUpdateRequest payload, UpdateAttachmentHeaders headers = {}) returns AttachmentResponse|error { + string resourcePath = string `/v2/attachments/${getEncodedUri(attachmentId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - AttachmentResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Audit Logs # - # + filterSource_type - Filter audit logs by the source type. For example, user or rule - # + filterSource_id - Filter audit logs by the source id. Requires `filter[source_type]` to also be set - # + filterActor_id - Filter audit logs by the actor id - # + filterIp_address - Filter audit logs by the ip address - # + filterCreated_at - Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time - # + filterAction - Filter audit logs by the action - # + sort_by - Offset pagination only. Sort audit logs. Default is `sort_by=created_at` - # + sort_order - Offset pagination only. Sort audit logs. Default is `sort_order=desc` - # + sort - Cursor pagination only. Sort audit logs. Default is `sort=-created_at` - # + return - Success response - resource isolated function get api/v2/audit_logs(string accept = "application/json", string? filterSource_type = (), int? filterSource_id = (), int? filterActor_id = (), string? filterIp_address = (), string? filterCreated_at = (), string? filterAction = (), string? sort_by = (), string? sort_order = (), string? sort = ()) returns AuditLogsResponse|error { - string resourcePath = string `/api/v2/audit_logs`; - map queryParam = {"filter[source_type]": filterSource_type, "filter[source_id]": filterSource_id, "filter[actor_id]": filterActor_id, "filter[ip_address]": filterIp_address, "filter[created_at]": filterCreated_at, "filter[action]": filterAction, "sort_by": sort_by, "sort_order": sort_order, "sort": sort}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AuditLogsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/audit_logs(ListAuditLogsHeaders headers = {}, *ListAuditLogsQueries queries) returns AuditLogsResponse|error { + string resourcePath = string `/v2/audit_logs`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Audit Log # - # + audit_log_id - The ID of the audit log - # + return - Success response - resource isolated function get api/v2/audit_logs/[int audit_log_id](string accept = "application/json") returns AuditLogResponse|error { - string resourcePath = string `/api/v2/audit_logs/${getEncodedUri(audit_log_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AuditLogResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + auditLogId - The ID of the audit log + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/audit_logs/[int auditLogId](ShowAuditLogHeaders headers = {}) returns AuditLogResponse|error { + string resourcePath = string `/v2/audit_logs/${getEncodedUri(auditLogId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Export Audit Logs # - # + filterSource_type - Filter audit logs by the source type. For example, user or rule - # + filterSource_id - Filter audit logs by the source id. Requires `filter[source_type]` to also be set. - # + filterActor_id - Filter audit logs by the actor id - # + filterIp_address - Filter audit logs by the ip address - # + filterCreated_at - Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time - # + filterAction - Filter audit logs by the action - # + return - Accepted description - resource isolated function post api/v2/audit_logs/export(string accept = "application/json", string? filterSource_type = (), int? filterSource_id = (), int? filterActor_id = (), string? filterIp_address = (), string? filterCreated_at = (), string? filterAction = ()) returns string|error { - string resourcePath = string `/api/v2/audit_logs/export`; - map queryParam = {"filter[source_type]": filterSource_type, "filter[source_id]": filterSource_id, "filter[actor_id]": filterActor_id, "filter[ip_address]": filterIp_address, "filter[created_at]": filterCreated_at, "filter[action]": filterAction}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - http:Request request = new; - string response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Accepted description + resource isolated function post v2/audit_logs/export(ExportAuditLogsHeaders headers = {}, *ExportAuditLogsQueries queries) returns string|error { + string resourcePath = string `/v2/audit_logs/export`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + http:Request request = new; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Search Tags # - # + name - A substring of a tag to search for - # + return - Success response - resource isolated function get api/v2/autocomplete/tags(string accept = "application/json", string? name = ()) returns TagsByObjectIdResponse|error { - string resourcePath = string `/api/v2/autocomplete/tags`; - map queryParam = {"name": name}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TagsByObjectIdResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/autocomplete/tags(AutocompleteTagsHeaders headers = {}, *AutocompleteTagsQueries queries) returns TagsByObjectIdResponse|error { + string resourcePath = string `/v2/autocomplete/tags`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Automations # - # + return - Success response - resource isolated function get api/v2/automations() returns AutomationsResponse|error { - string resourcePath = string `/api/v2/automations`; - AutomationsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/automations(map headers = {}) returns AutomationsResponse|error { + string resourcePath = string `/v2/automations`; + return self.clientEp->get(resourcePath, headers); } + # Create Automation # - # + return - Created response - resource isolated function post api/v2/automations() returns AutomationResponse|error { - string resourcePath = string `/api/v2/automations`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/automations(map headers = {}) returns AutomationResponse|error { + string resourcePath = string `/v2/automations`; http:Request request = new; - AutomationResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Automation # - # + automation_id - The ID of the automation - # + return - Success response - resource isolated function get api/v2/automations/[int automation_id](string accept = "application/json") returns AutomationResponse|error { - string resourcePath = string `/api/v2/automations/${getEncodedUri(automation_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AutomationResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + automationId - The ID of the automation + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/automations/[int automationId](ShowAutomationHeaders headers = {}) returns AutomationResponse|error { + string resourcePath = string `/v2/automations/${getEncodedUri(automationId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Automation # - # + automation_id - The ID of the automation - # + return - Success response - resource isolated function put api/v2/automations/[int automation_id](string accept = "application/json") returns AutomationResponse|error { - string resourcePath = string `/api/v2/automations/${getEncodedUri(automation_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + automationId - The ID of the automation + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/automations/[int automationId](UpdateAutomationHeaders headers = {}) returns AutomationResponse|error { + string resourcePath = string `/v2/automations/${getEncodedUri(automationId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - AutomationResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Automation # - # + automation_id - The ID of the automation - # + return - No Content response - resource isolated function delete api/v2/automations/[int automation_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/automations/${getEncodedUri(automation_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + automationId - The ID of the automation + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/automations/[int automationId](DeleteAutomationHeaders headers = {}) returns error? { + string resourcePath = string `/v2/automations/${getEncodedUri(automationId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Active Automations # - # + return - Success response - resource isolated function get api/v2/automations/active() returns AutomationsResponse|error { - string resourcePath = string `/api/v2/automations/active`; - AutomationsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/automations/active(map headers = {}) returns AutomationsResponse|error { + string resourcePath = string `/v2/automations/active`; + return self.clientEp->get(resourcePath, headers); } + # Bulk Delete Automations # - # + ids - The IDs of the automations to delete - # + return - No Content response - resource isolated function delete api/v2/automations/destroy_many(string accept = "application/json", int[]? ids = ()) returns error? { - string resourcePath = string `/api/v2/automations/destroy_many`; - map queryParam = {"ids": ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No Content response + resource isolated function delete v2/automations/destroy_many(BulkDeleteAutomationsHeaders headers = {}, *BulkDeleteAutomationsQueries queries) returns error? { + string resourcePath = string `/v2/automations/destroy_many`; map queryParamEncoding = {"ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Search Automations # - # + query - Query string used to find all automations with matching title - # + active - Filter by active automations if true or inactive automations if false - # + sort_by - Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the automations are sorted by relevance - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + include - A sideload to include in the response. See [Sideloads](#sideloads-2) - # + return - Success response - resource isolated function get api/v2/automations/search(string query, string accept = "application/json", boolean? active = (), string? sort_by = (), string? sort_order = (), string? include = ()) returns AutomationsResponse|error { - string resourcePath = string `/api/v2/automations/search`; - map queryParam = {"query": query, "active": active, "sort_by": sort_by, "sort_order": sort_order, "include": include}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - AutomationsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/automations/search(SearchAutomationsHeaders headers = {}, *SearchAutomationsQueries queries) returns AutomationsResponse|error { + string resourcePath = string `/v2/automations/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Automations # - # + return - Success response - resource isolated function put api/v2/automations/update_many() returns AutomationsResponse|error { - string resourcePath = string `/api/v2/automations/update_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/automations/update_many(map headers = {}) returns AutomationsResponse|error { + string resourcePath = string `/v2/automations/update_many`; http:Request request = new; - AutomationsResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # List Bookmarks # - # + return - Successful response - resource isolated function get api/v2/bookmarks() returns BookmarksResponse|error { - string resourcePath = string `/api/v2/bookmarks`; - BookmarksResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/bookmarks(map headers = {}) returns BookmarksResponse|error { + string resourcePath = string `/v2/bookmarks`; + return self.clientEp->get(resourcePath, headers); } + # Create Bookmark # - # + return - Successfully created - resource isolated function post api/v2/bookmarks(BookmarkCreateRequest payload) returns BookmarkResponse|error { - string resourcePath = string `/api/v2/bookmarks`; + # + headers - Headers to be sent with the request + # + return - Successfully created + resource isolated function post v2/bookmarks(BookmarkCreateRequest payload, map headers = {}) returns BookmarkResponse|error { + string resourcePath = string `/v2/bookmarks`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - BookmarkResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Delete Bookmark # - # + bookmark_id - The ID of the bookmark - # + return - No content - resource isolated function delete api/v2/bookmarks/[int bookmark_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/bookmarks/${getEncodedUri(bookmark_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + bookmarkId - The ID of the bookmark + # + headers - Headers to be sent with the request + # + return - No content + resource isolated function delete v2/bookmarks/[int bookmarkId](DeleteBookmarkHeaders headers = {}) returns error? { + string resourcePath = string `/v2/bookmarks/${getEncodedUri(bookmarkId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Brands # - # + return - Successful response - resource isolated function get api/v2/brands() returns BrandsResponse|error { - string resourcePath = string `/api/v2/brands`; - BrandsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/brands(map headers = {}) returns BrandsResponse|error { + string resourcePath = string `/v2/brands`; + return self.clientEp->get(resourcePath, headers); } + # Create Brand # - # + return - Successful response - resource isolated function post api/v2/brands(BrandCreateRequest payload) returns BrandResponse|error { - string resourcePath = string `/api/v2/brands`; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/brands(BrandCreateRequest payload, map headers = {}) returns BrandResponse|error { + string resourcePath = string `/v2/brands`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - BrandResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show a Brand # - # + brand_id - The ID of the brand - # + return - Successful response - resource isolated function get api/v2/brands/[int brand_id](string accept = "application/json") returns BrandResponse|error { - string resourcePath = string `/api/v2/brands/${getEncodedUri(brand_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - BrandResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + brandId - The ID of the brand + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/brands/[int brandId](ShowBrandHeaders headers = {}) returns BrandResponse|error { + string resourcePath = string `/v2/brands/${getEncodedUri(brandId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update a Brand # - # + brand_id - The ID of the brand - # + return - Successful response - resource isolated function put api/v2/brands/[int brand_id](BrandUpdateRequest payload, string accept = "application/json") returns BrandResponse|error { - string resourcePath = string `/api/v2/brands/${getEncodedUri(brand_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + brandId - The ID of the brand + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function put v2/brands/[int brandId](BrandUpdateRequest payload, UpdateBrandHeaders headers = {}) returns BrandResponse|error { + string resourcePath = string `/v2/brands/${getEncodedUri(brandId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - BrandResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete a Brand # - # + brand_id - The ID of the brand - # + return - No Content response - resource isolated function delete api/v2/brands/[int brand_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/brands/${getEncodedUri(brand_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + brandId - The ID of the brand + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/brands/[int brandId](DeleteBrandHeaders headers = {}) returns error? { + string resourcePath = string `/v2/brands/${getEncodedUri(brandId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Check Host Mapping Validity for an Existing Brand # - # + brand_id - The ID of the brand - # + return - Successful response - resource isolated function get api/v2/brands/[int brand_id]/check_host_mapping(string accept = "application/json") returns HostMappingObject|error { - string resourcePath = string `/api/v2/brands/${getEncodedUri(brand_id)}/check_host_mapping`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - HostMappingObject response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + brandId - The ID of the brand + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/brands/[int brandId]/check_host_mapping(CheckHostMappingValidityForExistingBrandHeaders headers = {}) returns HostMappingObject|error { + string resourcePath = string `/v2/brands/${getEncodedUri(brandId)}/check_host_mapping`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Check Host Mapping Validity # - # + host_mapping - The hostmapping to a brand, if any (only admins view this key) - # + subdomain - Subdomain for a given Zendesk account address - # + return - Successful response - resource isolated function get api/v2/brands/check_host_mapping(string host_mapping, string subdomain, string accept = "application/json") returns HostMappingObject|error { - string resourcePath = string `/api/v2/brands/check_host_mapping`; - map queryParam = {"host_mapping": host_mapping, "subdomain": subdomain}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - HostMappingObject response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function get v2/brands/check_host_mapping(CheckHostMappingValidityHeaders headers = {}, *CheckHostMappingValidityQueries queries) returns HostMappingObject|error { + string resourcePath = string `/v2/brands/check_host_mapping`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Monitored Twitter Handles # - # + return - Success response - resource isolated function get api/v2/channels/twitter/monitored_twitter_handles() returns TwitterChannelsResponse|error { - string resourcePath = string `/api/v2/channels/twitter/monitored_twitter_handles`; - TwitterChannelsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/channels/twitter/monitored_twitter_handles(map headers = {}) returns TwitterChannelsResponse|error { + string resourcePath = string `/v2/channels/twitter/monitored_twitter_handles`; + return self.clientEp->get(resourcePath, headers); } + # Show Monitored Twitter Handle # - # + monitored_twitter_handle_id - The ID of the custom agent role - # + return - Success response - resource isolated function get api/v2/channels/twitter/monitored_twitter_handles/[int monitored_twitter_handle_id](string accept = "application/json") returns TwitterChannelResponse|error { - string resourcePath = string `/api/v2/channels/twitter/monitored_twitter_handles/${getEncodedUri(monitored_twitter_handle_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TwitterChannelResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + monitoredTwitterHandleId - The ID of the custom agent role + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/channels/twitter/monitored_twitter_handles/[int monitoredTwitterHandleId](ShowMonitoredTwitterHandleHeaders headers = {}) returns TwitterChannelResponse|error { + string resourcePath = string `/v2/channels/twitter/monitored_twitter_handles/${getEncodedUri(monitoredTwitterHandleId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Ticket from Tweet # - # + return - description - resource isolated function post api/v2/channels/twitter/tickets() returns string|error { - string resourcePath = string `/api/v2/channels/twitter/tickets`; + # + headers - Headers to be sent with the request + # + return - description + resource isolated function post v2/channels/twitter/tickets(map headers = {}) returns string|error { + string resourcePath = string `/v2/channels/twitter/tickets`; http:Request request = new; - string response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # List Twicket statuses # - # + comment_id - The ID of the comment - # + ids - Optional comment ids to retrieve tweet information for only particular comments - # + return - Success response - resource isolated function get api/v2/channels/twitter/tickets/[int comment_id]/statuses(string accept = "application/json", string? ids = ()) returns TwitterChannelTwicketStatusResponse|error { - string resourcePath = string `/api/v2/channels/twitter/tickets/${getEncodedUri(comment_id)}/statuses`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TwitterChannelTwicketStatusResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + commentId - The ID of the comment + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/channels/twitter/tickets/[int commentId]/statuses(GettingTwicketStatusHeaders headers = {}, *GettingTwicketStatusQueries queries) returns TwitterChannelTwicketStatusResponse|error { + string resourcePath = string `/v2/channels/twitter/tickets/${getEncodedUri(commentId)}/statuses`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Open Ticket in Agent's Browser # - # + agent_id - ID of an agent - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function post api/v2/channels/voice/agents/[int agent_id]/tickets/[int ticket_id]/display(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/channels/voice/agents/${getEncodedUri(agent_id)}/tickets/${getEncodedUri(ticket_id)}/display`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + agentId - ID of an agent + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/channels/voice/agents/[int agentId]/tickets/[int ticketId]/display(OpenTicketInAgentBrowserHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/channels/voice/agents/${getEncodedUri(agentId)}/tickets/${getEncodedUri(ticketId)}/display`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Open a User's Profile in an Agent's Browser # - # + agent_id - ID of an agent - # + user_id - The id of the user - # + return - Successful response - resource isolated function post api/v2/channels/voice/agents/[int agent_id]/users/[int user_id]/display(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/channels/voice/agents/${getEncodedUri(agent_id)}/users/${getEncodedUri(user_id)}/display`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + agentId - ID of an agent + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/channels/voice/agents/[int agentId]/users/[int userId]/display(OpenUsersProfileInAgentBrowserHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/channels/voice/agents/${getEncodedUri(agentId)}/users/${getEncodedUri(userId)}/display`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Create Ticket or Voicemail Ticket # - # + agent_id - ID of an agent - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function post api/v2/channels/voice/tickets(TicketCreateVoicemailTicketRequest payload, string accept = "application/json") returns TicketResponse|error { - string resourcePath = string `/api/v2/channels/voice/tickets`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + agentId - ID of an agent + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/channels/voice/tickets(TicketCreateVoicemailTicketRequest payload, CreateTicketOrVoicemailTicketHeaders headers = {}) returns TicketResponse|error { + string resourcePath = string `/v2/channels/voice/tickets`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TicketResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Redact Chat Comment Attachment # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function put api/v2/chat_file_redactions/[int ticket_id](string accept = "application/json") returns TicketChatCommentRedactionResponse|error { - string resourcePath = string `/api/v2/chat_file_redactions/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/chat_file_redactions/[int ticketId](RedactChatCommentAttachmentHeaders headers = {}) returns TicketChatCommentRedactionResponse|error { + string resourcePath = string `/v2/chat_file_redactions/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketChatCommentRedactionResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Redact Chat Comment # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function put api/v2/chat_redactions/[int ticket_id](string accept = "application/json") returns TicketChatCommentRedactionResponse|error { - string resourcePath = string `/api/v2/chat_redactions/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/chat_redactions/[int ticketId](RedactChatCommentHeaders headers = {}) returns TicketChatCommentRedactionResponse|error { + string resourcePath = string `/v2/chat_redactions/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketChatCommentRedactionResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Redact Ticket Comment In Agent Workspace # - # + ticket_comment_id - The ID of the ticket comment - # + return - Success response - resource isolated function put api/v2/comment_redactions/[int ticket_comment_id](string accept = "application/json") returns TicketCommentResponse|error { - string resourcePath = string `/api/v2/comment_redactions/${getEncodedUri(ticket_comment_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketCommentId - The ID of the ticket comment + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/comment_redactions/[int ticketCommentId](RedactTicketCommentInAgentWorkspaceHeaders headers = {}) returns TicketCommentResponse|error { + string resourcePath = string `/v2/comment_redactions/${getEncodedUri(ticketCommentId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketCommentResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Custom Objects # - # + return - Success response - resource isolated function get api/v2/custom_objects() returns CustomObjectsResponse|error { - string resourcePath = string `/api/v2/custom_objects`; - CustomObjectsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects(map headers = {}) returns CustomObjectsResponse|error { + string resourcePath = string `/v2/custom_objects`; + return self.clientEp->get(resourcePath, headers); } + # Create Custom Object # - # + return - Created - resource isolated function post api/v2/custom_objects(CustomObjectsCreateRequest payload) returns CustomObjectResponse|error { - string resourcePath = string `/api/v2/custom_objects`; + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/custom_objects(CustomObjectsCreateRequest payload, map headers = {}) returns CustomObjectResponse|error { + string resourcePath = string `/v2/custom_objects`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomObjectResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Custom Object # - # + custom_object_key - The key of a custom object - # + return - Custom Object - resource isolated function get api/v2/custom_objects/[string custom_object_key](string accept = "application/json") returns CustomObjectResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Custom Object + resource isolated function get v2/custom_objects/[string customObjectKey](ShowCustomObjectHeaders headers = {}) returns CustomObjectResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Custom Object # - # + custom_object_key - The key of a custom object - # + return - No content response - resource isolated function delete api/v2/custom_objects/[string custom_object_key](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/custom_objects/[string customObjectKey](DeleteCustomObjectHeaders headers = {}) returns error? { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Update Custom Object # - # + custom_object_key - The key of a custom object - # + return - Success response - resource isolated function patch api/v2/custom_objects/[string custom_object_key](string accept = "application/json") returns CustomObjectResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function patch v2/custom_objects/[string customObjectKey](UpdateCustomObjectHeaders headers = {}) returns CustomObjectResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomObjectResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # List Custom Object Fields # - # + custom_object_key - The key of a custom object - # + include_standard_fields - Include standard fields if true. Exclude them if false - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/fields(string accept = "application/json", boolean? include_standard_fields = ()) returns CustomObjectFieldsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields`; - map queryParam = {"include_standard_fields": include_standard_fields}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectFieldsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/fields(ListCustomObjectFieldsHeaders headers = {}, *ListCustomObjectFieldsQueries queries) returns CustomObjectFieldsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Custom Object Field # - # + custom_object_key - The key of a custom object - # + return - Created - resource isolated function post api/v2/custom_objects/[string custom_object_key]/fields(CustomObjectFieldsCreateRequest payload, string accept = "application/json") returns CustomObjectFieldResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/custom_objects/[string customObjectKey]/fields(CustomObjectFieldsCreateRequest payload, CreateCustomObjectFieldHeaders headers = {}) returns CustomObjectFieldResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomObjectFieldResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Custom Object Field # - # + custom_object_key - The key of a custom object - # + custom_object_field_key_or_id - The key or id of a custom object field - # + return - Custom Object Field - resource isolated function get api/v2/custom_objects/[string custom_object_key]/fields/[string custom_object_field_key_or_id](string accept = "application/json") returns CustomObjectFieldResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields/${getEncodedUri(custom_object_field_key_or_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectFieldResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + customObjectFieldKeyOrId - The key or id of a custom object field + # + headers - Headers to be sent with the request + # + return - Custom Object Field + resource isolated function get v2/custom_objects/[string customObjectKey]/fields/[string customObjectFieldKeyOrId](ShowCustomObjectFieldHeaders headers = {}) returns CustomObjectFieldResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields/${getEncodedUri(customObjectFieldKeyOrId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Custom Object Field # - # + custom_object_key - The key of a custom object - # + custom_object_field_key_or_id - The key or id of a custom object field - # + return - No content response - resource isolated function delete api/v2/custom_objects/[string custom_object_key]/fields/[string custom_object_field_key_or_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields/${getEncodedUri(custom_object_field_key_or_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + customObjectFieldKeyOrId - The key or id of a custom object field + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/custom_objects/[string customObjectKey]/fields/[string customObjectFieldKeyOrId](DeleteCustomObjectFieldHeaders headers = {}) returns error? { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields/${getEncodedUri(customObjectFieldKeyOrId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Update Custom Object Field # - # + custom_object_key - The key of a custom object - # + custom_object_field_key_or_id - The key or id of a custom object field - # + return - Success response - resource isolated function patch api/v2/custom_objects/[string custom_object_key]/fields/[string custom_object_field_key_or_id](string accept = "application/json") returns CustomObjectFieldResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields/${getEncodedUri(custom_object_field_key_or_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + customObjectFieldKeyOrId - The key or id of a custom object field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function patch v2/custom_objects/[string customObjectKey]/fields/[string customObjectFieldKeyOrId](UpdateCustomObjectFieldHeaders headers = {}) returns CustomObjectFieldResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields/${getEncodedUri(customObjectFieldKeyOrId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomObjectFieldResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # Reorder Custom Fields of an Object # - # + custom_object_key - The key of a custom object - # + return - Reordered - resource isolated function put api/v2/custom_objects/[string custom_object_key]/fields/reorder(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/fields/reorder`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Reordered + resource isolated function put v2/custom_objects/[string customObjectKey]/fields/reorder(ReorderCustomObjectFieldsHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/fields/reorder`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Custom Object Record Bulk Jobs # - # + custom_object_key - The key of a custom object - # + return - Created - resource isolated function post api/v2/custom_objects/[string custom_object_key]/jobs(CustomObjectRecordsBulkCreateRequest payload, string accept = "application/json") returns CustomObjectRecordsJobsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/jobs`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/custom_objects/[string customObjectKey]/jobs(CustomObjectRecordsBulkCreateRequest payload, CustomObjectRecordBulkJobsHeaders headers = {}) returns CustomObjectRecordsJobsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/jobs`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomObjectRecordsJobsResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Custom Object Fields Limit # - # + custom_object_key - The key of a custom object - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/limits/field_limit(string accept = "application/json") returns CustomObjectLimitsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/limits/field_limit`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectLimitsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/limits/field_limit(CustomObjectFieldsLimitHeaders headers = {}) returns CustomObjectLimitsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/limits/field_limit`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Custom Object Records # - # + custom_object_key - The key of a custom object - # + filterIds - Optional comma-separated list of ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive. - # + filterExternal_ids - Optional comma-separated list of external ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive. - # + sort - One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending. - # + pageBefore - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageAfter - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageSize - Specifies how many records should be returned in the response. You can specify up to 100 records per page. - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/records(string accept = "application/json", string? filterIds = (), string? filterExternal_ids = (), string? sort = (), string? pageBefore = (), string? pageAfter = (), int? pageSize = ()) returns CustomObjectRecordsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records`; - map queryParam = {"filter[ids]": filterIds, "filter[external_ids]": filterExternal_ids, "sort": sort, "page[before]": pageBefore, "page[after]": pageAfter, "page[size]": pageSize}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectRecordsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/records(ListCustomObjectRecordsHeaders headers = {}, *ListCustomObjectRecordsQueries queries) returns CustomObjectRecordsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Custom Object Record # - # + custom_object_key - The key of a custom object - # + return - Created - resource isolated function post api/v2/custom_objects/[string custom_object_key]/records(CustomObjectRecordsCreateRequest payload, string accept = "application/json") returns CustomObjectRecordResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/custom_objects/[string customObjectKey]/records(CustomObjectRecordsCreateRequest payload, CreateCustomObjectRecordHeaders headers = {}) returns CustomObjectRecordResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomObjectRecordResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Delete Custom Object Record by External Id # - # + custom_object_key - The key of a custom object - # + external_id - The external id of a custom object record - # + return - No content response - resource isolated function delete api/v2/custom_objects/[string custom_object_key]/records(string external_id, string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records`; - map queryParam = {"external_id": external_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No content response + resource isolated function delete v2/custom_objects/[string customObjectKey]/records(DeleteCustomObjectRecordByExternalIdHeaders headers = {}, *DeleteCustomObjectRecordByExternalIdQueries queries) returns error? { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Set Custom Object Record by External Id # - # + custom_object_key - The key of a custom object - # + external_id - The external id of a custom object record - # + return - Success - resource isolated function patch api/v2/custom_objects/[string custom_object_key]/records(string external_id, CustomObjectRecordsUpsertRequest payload, string accept = "application/json") returns CustomObjectRecordResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records`; - map queryParam = {"external_id": external_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - http:Request request = new; - json jsonBody = payload.toJson(); + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success + resource isolated function patch v2/custom_objects/[string customObjectKey]/records(CustomObjectRecordsUpsertRequest payload, UpsertCustomObjectRecordHeaders headers = {}, *UpsertCustomObjectRecordQueries queries) returns CustomObjectRecordResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + http:Request request = new; + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomObjectRecordResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # Show Custom Object Record # - # + custom_object_key - The key of a custom object - # + custom_object_record_id - The id of a custom object record - # + return - Custom Object Record - resource isolated function get api/v2/custom_objects/[string custom_object_key]/records/[string custom_object_record_id](string accept = "application/json") returns CustomObjectRecordResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/${getEncodedUri(custom_object_record_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectRecordResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + customObjectRecordId - The id of a custom object record + # + headers - Headers to be sent with the request + # + return - Custom Object Record + resource isolated function get v2/custom_objects/[string customObjectKey]/records/[string customObjectRecordId](ShowCustomObjectRecordHeaders headers = {}) returns CustomObjectRecordResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/${getEncodedUri(customObjectRecordId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Custom Object Record # - # + custom_object_key - The key of a custom object - # + custom_object_record_id - The id of a custom object record - # + return - No content response - resource isolated function delete api/v2/custom_objects/[string custom_object_key]/records/[string custom_object_record_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/${getEncodedUri(custom_object_record_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + customObjectRecordId - The id of a custom object record + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/custom_objects/[string customObjectKey]/records/[string customObjectRecordId](DeleteCustomObjectRecordHeaders headers = {}) returns error? { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/${getEncodedUri(customObjectRecordId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Update Custom Object Record # - # + custom_object_key - The key of a custom object - # + custom_object_record_id - The id of a custom object record - # + return - Success response - resource isolated function patch api/v2/custom_objects/[string custom_object_key]/records/[string custom_object_record_id](string accept = "application/json") returns CustomObjectRecordResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/${getEncodedUri(custom_object_record_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customObjectKey - The key of a custom object + # + customObjectRecordId - The id of a custom object record + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function patch v2/custom_objects/[string customObjectKey]/records/[string customObjectRecordId](UpdateCustomObjectRecordHeaders headers = {}) returns CustomObjectRecordResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/${getEncodedUri(customObjectRecordId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomObjectRecordResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # Autocomplete Custom Object Record Search # - # + custom_object_key - The key of a custom object - # + name - Part of a name of the record you are searching for - # + pageBefore - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageAfter - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageSize - The number of records to return in the response. You can specify up to 100 records per page. - # + field_id - The id of the lookup field. If the field has a relationship filter, the filter is applied to the results. Must be used with `source` param. - # + 'source - One of "zen:user", "zen:ticket", "zen:organization", or "zen:custom_object:CUSTOM_OBJECT_KEY". Represents the object `field_id` belongs to. Must be used with field_id param. - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/records/autocomplete(string accept = "application/json", string? name = (), string? pageBefore = (), string? pageAfter = (), int? pageSize = (), string? field_id = (), string? 'source = ()) returns CustomObjectRecordsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/autocomplete`; - map queryParam = {"name": name, "page[before]": pageBefore, "page[after]": pageAfter, "page[size]": pageSize, "field_id": field_id, "source": 'source}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectRecordsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/records/autocomplete(AutocompleteCustomObjectRecordSearchHeaders headers = {}, *AutocompleteCustomObjectRecordSearchQueries queries) returns CustomObjectRecordsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/autocomplete`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Count Custom Object Records # - # + custom_object_key - The key of a custom object - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/records/count(string accept = "application/json") returns Inline_response_200_1|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/count`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - Inline_response_200_1 response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/records/count(CountCustomObjectRecordsHeaders headers = {}) returns InlineResponse2001|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/count`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Search Custom Object Records # - # + custom_object_key - The key of a custom object - # + query - The query parameter is used to search text-based fields for records that match specific query terms. - # The query can be multiple words or numbers. Every record that matches the beginning of any word or number in the query string is returned.

- # For example, you might want to search for records related to Tesla vehicles: `query=Tesla`. In this example the API would return every record for the given custom object where any of the text fields contain the word 'Tesla'.

- # If needed, you could include multiple words or numbers in your search. For example: `query=Tesla Honda 2020`. This would be URL encoded as `query=Tesla%20Honda%202020`. In this example, the API would return every record for the custom object for which any of the text fields contained 'Tesla', 'Honda', or '2020'. - # + sort - One of `name`, `created_at`, `updated_at`, `-name`, `-created_at`, or `-updated_at`. The `-` denotes the sort will be descending. Defaults to sorting by relevance. - # + pageBefore - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageAfter - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - # + pageSize - Specifies how many records should be returned in the response. You can specify up to 100 records per page. - # + return - Success response - resource isolated function get api/v2/custom_objects/[string custom_object_key]/records/search(string accept = "application/json", string? query = (), string? sort = (), string? pageBefore = (), string? pageAfter = (), int? pageSize = ()) returns CustomObjectRecordsResponse|error { - string resourcePath = string `/api/v2/custom_objects/${getEncodedUri(custom_object_key)}/records/search`; - map queryParam = {"query": query, "sort": sort, "page[before]": pageBefore, "page[after]": pageAfter, "page[size]": pageSize}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomObjectRecordsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customObjectKey - The key of a custom object + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/[string customObjectKey]/records/search(SearchCustomObjectRecordsHeaders headers = {}, *SearchCustomObjectRecordsQueries queries) returns CustomObjectRecordsResponse|error { + string resourcePath = string `/v2/custom_objects/${getEncodedUri(customObjectKey)}/records/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Custom Objects Limit # - # + return - Success response - resource isolated function get api/v2/custom_objects/limits/object_limit() returns CustomObjectLimitsResponse|error { - string resourcePath = string `/api/v2/custom_objects/limits/object_limit`; - CustomObjectLimitsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/limits/object_limit(map headers = {}) returns CustomObjectLimitsResponse|error { + string resourcePath = string `/v2/custom_objects/limits/object_limit`; + return self.clientEp->get(resourcePath, headers); } + # Custom Object Records Limit # - # + return - Success response - resource isolated function get api/v2/custom_objects/limits/record_limit() returns CustomObjectLimitsResponse|error { - string resourcePath = string `/api/v2/custom_objects/limits/record_limit`; - CustomObjectLimitsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_objects/limits/record_limit(map headers = {}) returns CustomObjectLimitsResponse|error { + string resourcePath = string `/v2/custom_objects/limits/record_limit`; + return self.clientEp->get(resourcePath, headers); } + # List Custom Roles # - # + return - Success response - resource isolated function get api/v2/custom_roles() returns CustomRolesResponse|error { - string resourcePath = string `/api/v2/custom_roles`; - CustomRolesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_roles(map headers = {}) returns CustomRolesResponse|error { + string resourcePath = string `/v2/custom_roles`; + return self.clientEp->get(resourcePath, headers); } + # Create Custom Role # - # + return - Created response - resource isolated function post api/v2/custom_roles() returns CustomRoleResponse|error { - string resourcePath = string `/api/v2/custom_roles`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/custom_roles(map headers = {}) returns CustomRoleResponse|error { + string resourcePath = string `/v2/custom_roles`; http:Request request = new; - CustomRoleResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Custom Role # - # + custom_role_id - The ID of the custom agent role - # + return - Success response - resource isolated function get api/v2/custom_roles/[int custom_role_id](string accept = "application/json") returns CustomRoleResponse|error { - string resourcePath = string `/api/v2/custom_roles/${getEncodedUri(custom_role_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomRoleResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customRoleId - The ID of the custom agent role + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/custom_roles/[int customRoleId](ShowCustomRoleByIdHeaders headers = {}) returns CustomRoleResponse|error { + string resourcePath = string `/v2/custom_roles/${getEncodedUri(customRoleId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Custom Role # - # + custom_role_id - The ID of the custom agent role - # + return - Success response - resource isolated function put api/v2/custom_roles/[int custom_role_id](string accept = "application/json") returns CustomRoleResponse|error { - string resourcePath = string `/api/v2/custom_roles/${getEncodedUri(custom_role_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customRoleId - The ID of the custom agent role + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/custom_roles/[int customRoleId](UpdateCustomRoleByIdHeaders headers = {}) returns CustomRoleResponse|error { + string resourcePath = string `/v2/custom_roles/${getEncodedUri(customRoleId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomRoleResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Custom Role # - # + custom_role_id - The ID of the custom agent role - # + return - No Contetnt response - resource isolated function delete api/v2/custom_roles/[int custom_role_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/custom_roles/${getEncodedUri(custom_role_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customRoleId - The ID of the custom agent role + # + headers - Headers to be sent with the request + # + return - No Contetnt response + resource isolated function delete v2/custom_roles/[int customRoleId](DeleteCustomRoleByIdHeaders headers = {}) returns error? { + string resourcePath = string `/v2/custom_roles/${getEncodedUri(customRoleId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Bulk Update Default Custom Ticket Status # - # + return - Updated - resource isolated function put api/v2/custom_status/default(BulkUpdateDefaultCustomStatusRequest payload) returns BulkUpdateDefaultCustomStatusResponse|error { - string resourcePath = string `/api/v2/custom_status/default`; + # + headers - Headers to be sent with the request + # + return - Updated + resource isolated function put v2/custom_status/default(BulkUpdateDefaultCustomStatusRequest payload, map headers = {}) returns BulkUpdateDefaultCustomStatusResponse|error { + string resourcePath = string `/v2/custom_status/default`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - BulkUpdateDefaultCustomStatusResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # List Custom Ticket Statuses # - # + status_categories - Filter the list of custom ticket statuses by a comma-separated list of status categories - # + active - If true, show only active custom ticket statuses. If false, show only inactive custom ticket statuses. If the filter is not used, show all custom ticket statuses - # + default - If true, show only default custom ticket statuses. If false, show only non-default custom ticket statuses. If the filter is not used, show all custom ticket statuses - # + return - List custom ticket statuses - resource isolated function get api/v2/custom_statuses(string accept = "application/json", string? status_categories = (), boolean? active = (), boolean? default = ()) returns CustomStatusesResponse|error { - string resourcePath = string `/api/v2/custom_statuses`; - map queryParam = {"status_categories": status_categories, "active": active, "default": default}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomStatusesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - List custom ticket statuses + resource isolated function get v2/custom_statuses(ListCustomStatusesHeaders headers = {}, *ListCustomStatusesQueries queries) returns CustomStatusesResponse|error { + string resourcePath = string `/v2/custom_statuses`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Custom Ticket Status # - # + return - Created - resource isolated function post api/v2/custom_statuses(CustomStatusCreateRequest payload) returns CustomStatusResponse|error { - string resourcePath = string `/api/v2/custom_statuses`; + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/custom_statuses(CustomStatusCreateRequest payload, map headers = {}) returns CustomStatusResponse|error { + string resourcePath = string `/v2/custom_statuses`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Custom Ticket Status # - # + custom_status_id - The id of the custom status - # + return - Custom Status - resource isolated function get api/v2/custom_statuses/[int custom_status_id](string accept = "application/json") returns CustomStatusResponse|error { - string resourcePath = string `/api/v2/custom_statuses/${getEncodedUri(custom_status_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomStatusResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + customStatusId - The id of the custom status + # + headers - Headers to be sent with the request + # + return - Custom Status + resource isolated function get v2/custom_statuses/[int customStatusId](ShowCustomStatusHeaders headers = {}) returns CustomStatusResponse|error { + string resourcePath = string `/v2/custom_statuses/${getEncodedUri(customStatusId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Custom Ticket Status # - # + custom_status_id - The id of the custom status - # + return - Updated - resource isolated function put api/v2/custom_statuses/[int custom_status_id](CustomStatusUpdateRequest payload, string accept = "application/json") returns CustomStatusResponse|error { - string resourcePath = string `/api/v2/custom_statuses/${getEncodedUri(custom_status_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + customStatusId - The id of the custom status + # + headers - Headers to be sent with the request + # + return - Updated + resource isolated function put v2/custom_statuses/[int customStatusId](CustomStatusUpdateRequest payload, UpdateCustomStatusHeaders headers = {}) returns CustomStatusResponse|error { + string resourcePath = string `/v2/custom_statuses/${getEncodedUri(customStatusId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - CustomStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Deleted Tickets # - # + sort_by - Sort by - # + sort_order - Sort order. Defaults to "asc" - # + return - Successful response - resource isolated function get api/v2/deleted_tickets(string accept = "application/json", "id"|"subject"|"deleted_at"? sort_by = (), "asc"|"desc"? sort_order = ()) returns ListDeletedTicketsResponse|error { - string resourcePath = string `/api/v2/deleted_tickets`; - map queryParam = {"sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ListDeletedTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function get v2/deleted_tickets(ListDeletedTicketsHeaders headers = {}, *ListDeletedTicketsQueries queries) returns ListDeletedTicketsResponse|error { + string resourcePath = string `/v2/deleted_tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Ticket Permanently # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function delete api/v2/deleted_tickets/[int ticket_id](string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/deleted_tickets/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function delete v2/deleted_tickets/[int ticketId](DeleteTicketPermanentlyHeaders headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/deleted_tickets/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Restore a Previously Deleted Ticket # - # + ticket_id - The ID of the ticket - # + return - Empty response - resource isolated function put api/v2/deleted_tickets/[int ticket_id]/restore(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/deleted_tickets/${getEncodedUri(ticket_id)}/restore`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Empty response + resource isolated function put v2/deleted_tickets/[int ticketId]/restore(RestoreDeletedTicketHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/deleted_tickets/${getEncodedUri(ticketId)}/restore`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Multiple Tickets Permanently # - # + ids - Comma-separated list of ticket ids - # + return - Successful response - resource isolated function delete api/v2/deleted_tickets/destroy_many(string ids, string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/deleted_tickets/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function delete v2/deleted_tickets/destroy_many(BulkPermanentlyDeleteTicketsHeaders headers = {}, *BulkPermanentlyDeleteTicketsQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/deleted_tickets/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Restore Previously Deleted Tickets in Bulk # - # + ids - Comma-separated list of ticket ids - # + return - Empty response - resource isolated function put api/v2/deleted_tickets/restore_many(string ids, string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/deleted_tickets/restore_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Empty response + resource isolated function put v2/deleted_tickets/restore_many(BulkRestoreDeletedTicketsHeaders headers = {}, *BulkRestoreDeletedTicketsQueries queries) returns string|error { + string resourcePath = string `/v2/deleted_tickets/restore_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Deleted Users # - # + return - Success response - resource isolated function get api/v2/deleted_users() returns DeletedUsersResponse|error { - string resourcePath = string `/api/v2/deleted_users`; - DeletedUsersResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/deleted_users(map headers = {}) returns DeletedUsersResponse|error { + string resourcePath = string `/v2/deleted_users`; + return self.clientEp->get(resourcePath, headers); } + # Show Deleted User # - # + deleted_user_id - The ID of the deleted user - # + return - Success response - resource isolated function get api/v2/deleted_users/[int deleted_user_id](string accept = "application/json") returns DeletedUserResponse|error { - string resourcePath = string `/api/v2/deleted_users/${getEncodedUri(deleted_user_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DeletedUserResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + deletedUserId - The ID of the deleted user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/deleted_users/[int deletedUserId](ShowDeletedUserHeaders headers = {}) returns DeletedUserResponse|error { + string resourcePath = string `/v2/deleted_users/${getEncodedUri(deletedUserId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Permanently Delete User # - # + deleted_user_id - The ID of the deleted user - # + return - Success response - resource isolated function delete api/v2/deleted_users/[int deleted_user_id](string accept = "application/json") returns DeletedUserResponse|error { - string resourcePath = string `/api/v2/deleted_users/${getEncodedUri(deleted_user_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DeletedUserResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + deletedUserId - The ID of the deleted user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function delete v2/deleted_users/[int deletedUserId](PermanentlyDeleteUserHeaders headers = {}) returns DeletedUserResponse|error { + string resourcePath = string `/v2/deleted_users/${getEncodedUri(deletedUserId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Count Deleted Users # - # + return - Success response - resource isolated function get api/v2/deleted_users/count() returns CountResponse|error { - string resourcePath = string `/api/v2/deleted_users/count`; - CountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/deleted_users/count(map headers = {}) returns CountResponse|error { + string resourcePath = string `/v2/deleted_users/count`; + return self.clientEp->get(resourcePath, headers); } + # List Items # - # + return - Success response - resource isolated function get api/v2/dynamic_content/items() returns DynamicContentsResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items`; - DynamicContentsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/dynamic_content/items(map headers = {}) returns DynamicContentsResponse|error { + string resourcePath = string `/v2/dynamic_content/items`; + return self.clientEp->get(resourcePath, headers); } + # Create Item # - # + return - Created response - resource isolated function post api/v2/dynamic_content/items() returns DynamicContentResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/dynamic_content/items(map headers = {}) returns DynamicContentResponse|error { + string resourcePath = string `/v2/dynamic_content/items`; http:Request request = new; - DynamicContentResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Item # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Success response - resource isolated function get api/v2/dynamic_content/items/[int dynamic_content_item_id](string accept = "application/json") returns DynamicContentResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DynamicContentResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/dynamic_content/items/[int dynamicContentItemId](ShowDynamicContentItemHeaders headers = {}) returns DynamicContentResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Item # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Success response - resource isolated function put api/v2/dynamic_content/items/[int dynamic_content_item_id](string accept = "application/json") returns DynamicContentResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/dynamic_content/items/[int dynamicContentItemId](UpdateDynamicContentItemHeaders headers = {}) returns DynamicContentResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - DynamicContentResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Item # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - No Content response - resource isolated function delete api/v2/dynamic_content/items/[int dynamic_content_item_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/dynamic_content/items/[int dynamicContentItemId](DeleteDynamicContentItemHeaders headers = {}) returns error? { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Variants # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Success response - resource isolated function get api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants(string accept = "application/json") returns DynamicContentVariantsResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DynamicContentVariantsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/dynamic_content/items/[int dynamicContentItemId]/variants(DynamicContentListVariantsHeaders headers = {}) returns DynamicContentVariantsResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Variant # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Created response - resource isolated function post api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants(string accept = "application/json") returns DynamicContentVariantResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/dynamic_content/items/[int dynamicContentItemId]/variants(CreateDynamicContentVariantHeaders headers = {}) returns DynamicContentVariantResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - DynamicContentVariantResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Variant # - # + dynamic_content_item_id - The ID of the dynamic content item - # + dynammic_content_variant_id - The ID of the variant - # + return - Success response - resource isolated function get api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants/[int dynammic_content_variant_id](string accept = "application/json") returns DynamicContentVariantResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants/${getEncodedUri(dynammic_content_variant_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DynamicContentVariantResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + dynamicContentItemId - The ID of the dynamic content item + # + dynammicContentVariantId - The ID of the variant + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/dynamic_content/items/[int dynamicContentItemId]/variants/[int dynammicContentVariantId](ShowDynamicContentVariantHeaders headers = {}) returns DynamicContentVariantResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants/${getEncodedUri(dynammicContentVariantId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Variant # - # + dynamic_content_item_id - The ID of the dynamic content item - # + dynammic_content_variant_id - The ID of the variant - # + return - Success response - resource isolated function put api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants/[int dynammic_content_variant_id](string accept = "application/json") returns DynamicContentVariantResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants/${getEncodedUri(dynammic_content_variant_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + dynammicContentVariantId - The ID of the variant + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/dynamic_content/items/[int dynamicContentItemId]/variants/[int dynammicContentVariantId](UpdateDynamicContentVariantHeaders headers = {}) returns DynamicContentVariantResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants/${getEncodedUri(dynammicContentVariantId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - DynamicContentVariantResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Variant # - # + dynamic_content_item_id - The ID of the dynamic content item - # + dynammic_content_variant_id - The ID of the variant - # + return - No Content response - resource isolated function delete api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants/[int dynammic_content_variant_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants/${getEncodedUri(dynammic_content_variant_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + dynammicContentVariantId - The ID of the variant + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/dynamic_content/items/[int dynamicContentItemId]/variants/[int dynammicContentVariantId](DeleteDynamicContentVariantHeaders headers = {}) returns error? { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants/${getEncodedUri(dynammicContentVariantId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Create Many Variants # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Created response - resource isolated function post api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants/create_many(string accept = "application/json") returns DynamicContentVariantsResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants/create_many`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/dynamic_content/items/[int dynamicContentItemId]/variants/create_many(CreateManyDynamicContentVariantsHeaders headers = {}) returns DynamicContentVariantsResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants/create_many`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - DynamicContentVariantsResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Update Many Variants # - # + dynamic_content_item_id - The ID of the dynamic content item - # + return - Success response - resource isolated function put api/v2/dynamic_content/items/[int dynamic_content_item_id]/variants/update_many(string accept = "application/json") returns DynamicContentVariantsResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/${getEncodedUri(dynamic_content_item_id)}/variants/update_many`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + dynamicContentItemId - The ID of the dynamic content item + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/dynamic_content/items/[int dynamicContentItemId]/variants/update_many(UpdateManyDynamicContentVariantsHeaders headers = {}) returns DynamicContentVariantsResponse|error { + string resourcePath = string `/v2/dynamic_content/items/${getEncodedUri(dynamicContentItemId)}/variants/update_many`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - DynamicContentVariantsResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Show Many Items # - # + identifiers - Identifiers for the dynamic contents - # + return - Success response - resource isolated function get api/v2/dynamic_content/items/show_many(string accept = "application/json", string? identifiers = ()) returns DynamicContentsResponse|error { - string resourcePath = string `/api/v2/dynamic_content/items/show_many`; - map queryParam = {"identifiers": identifiers}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - DynamicContentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/dynamic_content/items/show_many(ShowManyDynamicContentsHeaders headers = {}, *ShowManyDynamicContentsQueries queries) returns DynamicContentsResponse|error { + string resourcePath = string `/v2/dynamic_content/items/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Memberships # - # + return - Success response - resource isolated function get api/v2/group_memberships() returns GroupMembershipsResponse|error { - string resourcePath = string `/api/v2/group_memberships`; - GroupMembershipsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_memberships(map headers = {}) returns GroupMembershipsResponse|error { + string resourcePath = string `/v2/group_memberships`; + return self.clientEp->get(resourcePath, headers); } + # Create Membership # - # + return - Created response - resource isolated function post api/v2/group_memberships() returns GroupMembershipResponse|error { - string resourcePath = string `/api/v2/group_memberships`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/group_memberships(map headers = {}) returns GroupMembershipResponse|error { + string resourcePath = string `/v2/group_memberships`; http:Request request = new; - GroupMembershipResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Membership # - # + group_membership_id - The ID of the group membership - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/group_memberships/[int group_membership_id](string accept = "application/json") returns GroupMembershipResponse|error { - string resourcePath = string `/api/v2/group_memberships/${getEncodedUri(group_membership_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupMembershipResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + groupMembershipId - The ID of the group membership + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_memberships/[int groupMembershipId](ShowGroupMembershipByIdHeaders headers = {}) returns GroupMembershipResponse|error { + string resourcePath = string `/v2/group_memberships/${getEncodedUri(groupMembershipId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Membership # - # + group_membership_id - The ID of the group membership - # + user_id - The id of the user - # + return - No content response - resource isolated function delete api/v2/group_memberships/[int group_membership_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/group_memberships/${getEncodedUri(group_membership_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + groupMembershipId - The ID of the group membership + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/group_memberships/[int groupMembershipId](DeleteGroupMembershipHeaders headers = {}) returns error? { + string resourcePath = string `/v2/group_memberships/${getEncodedUri(groupMembershipId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Assignable Memberships # - # + return - Success response - resource isolated function get api/v2/group_memberships/assignable() returns GroupMembershipsResponse|error { - string resourcePath = string `/api/v2/group_memberships/assignable`; - GroupMembershipsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_memberships/assignable(map headers = {}) returns GroupMembershipsResponse|error { + string resourcePath = string `/v2/group_memberships/assignable`; + return self.clientEp->get(resourcePath, headers); } + # Bulk Create Memberships # - # + return - Success response - resource isolated function post api/v2/group_memberships/create_many() returns JobStatusResponse|error { - string resourcePath = string `/api/v2/group_memberships/create_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/group_memberships/create_many(map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/group_memberships/create_many`; http:Request request = new; - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Bulk Delete Memberships # - # + ids - Id of the group memberships to delete. Comma separated - # + return - Success response - resource isolated function delete api/v2/group_memberships/destroy_many(string accept = "application/json", string? ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/group_memberships/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function delete v2/group_memberships/destroy_many(GroupMembershipBulkDeleteHeaders headers = {}, *GroupMembershipBulkDeleteQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/group_memberships/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Group SLA Policies # - # + return - Success response - resource isolated function get api/v2/group_slas/policies() returns GroupSLAPoliciesResponse|error { - string resourcePath = string `/api/v2/group_slas/policies`; - GroupSLAPoliciesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_slas/policies(map headers = {}) returns GroupSLAPoliciesResponse|error { + string resourcePath = string `/v2/group_slas/policies`; + return self.clientEp->get(resourcePath, headers); } + # Create Group SLA Policy # - # + return - Created response - resource isolated function post api/v2/group_slas/policies() returns GroupSLAPolicyResponse|error { - string resourcePath = string `/api/v2/group_slas/policies`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/group_slas/policies(map headers = {}) returns GroupSLAPolicyResponse|error { + string resourcePath = string `/v2/group_slas/policies`; http:Request request = new; - GroupSLAPolicyResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Group SLA Policy # - # + group_sla_policy_id - The id of the Group SLA policy - # + return - Success response - resource isolated function get api/v2/group_slas/policies/[int group_sla_policy_id](string accept = "application/json") returns GroupSLAPolicyResponse|error { - string resourcePath = string `/api/v2/group_slas/policies/${getEncodedUri(group_sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupSLAPolicyResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + groupSlaPolicyId - The id of the Group SLA policy + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_slas/policies/[int groupSlaPolicyId](ShowGroupSLAPolicyHeaders headers = {}) returns GroupSLAPolicyResponse|error { + string resourcePath = string `/v2/group_slas/policies/${getEncodedUri(groupSlaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Group SLA Policy # - # + group_sla_policy_id - The id of the Group SLA policy - # + return - Success response - resource isolated function put api/v2/group_slas/policies/[int group_sla_policy_id](string accept = "application/json") returns GroupSLAPolicyResponse|error { - string resourcePath = string `/api/v2/group_slas/policies/${getEncodedUri(group_sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + groupSlaPolicyId - The id of the Group SLA policy + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/group_slas/policies/[int groupSlaPolicyId](UpdateGroupSLAPolicyHeaders headers = {}) returns GroupSLAPolicyResponse|error { + string resourcePath = string `/v2/group_slas/policies/${getEncodedUri(groupSlaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - GroupSLAPolicyResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Group SLA Policy # - # + group_sla_policy_id - The id of the Group SLA policy - # + return - No Content response - resource isolated function delete api/v2/group_slas/policies/[int group_sla_policy_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/group_slas/policies/${getEncodedUri(group_sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + groupSlaPolicyId - The id of the Group SLA policy + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/group_slas/policies/[int groupSlaPolicyId](DeleteGroupSLAPolicyHeaders headers = {}) returns error? { + string resourcePath = string `/v2/group_slas/policies/${getEncodedUri(groupSlaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Retrieve Supported Filter Definition Items # - # + return - Success response - resource isolated function get api/v2/group_slas/policies/definitions() returns GroupSLAPolicyFilterDefinitionResponse|error { - string resourcePath = string `/api/v2/group_slas/policies/definitions`; - GroupSLAPolicyFilterDefinitionResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/group_slas/policies/definitions(map headers = {}) returns GroupSLAPolicyFilterDefinitionResponse|error { + string resourcePath = string `/v2/group_slas/policies/definitions`; + return self.clientEp->get(resourcePath, headers); } + # Reorder Group SLA Policies # - # + group_sla_policy_ids - The ids of the Group SLA policies to reorder - # + return - Success response - resource isolated function put api/v2/group_slas/policies/reorder(string accept = "application/json", string[]? group_sla_policy_ids = ()) returns string|error { - string resourcePath = string `/api/v2/group_slas/policies/reorder`; - map queryParam = {"group_sla_policy_ids": group_sla_policy_ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function put v2/group_slas/policies/reorder(ReorderGroupSLAPoliciesHeaders headers = {}, *ReorderGroupSLAPoliciesQueries queries) returns string|error { + string resourcePath = string `/v2/group_slas/policies/reorder`; map queryParamEncoding = {"group_sla_policy_ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Groups # - # + user_id - The id of the user - # + exclude_deleted - Whether to exclude deleted entities - # + return - Success response - resource isolated function get api/v2/groups(string accept = "application/json", boolean? exclude_deleted = ()) returns GroupsResponse|error { - string resourcePath = string `/api/v2/groups`; - map queryParam = {"exclude_deleted": exclude_deleted}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/groups(ListGroupsHeaders headers = {}, *ListGroupsQueries queries) returns GroupsResponse|error { + string resourcePath = string `/v2/groups`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Group # - # + return - Created response - resource isolated function post api/v2/groups() returns GroupResponse|error { - string resourcePath = string `/api/v2/groups`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/groups(map headers = {}) returns GroupResponse|error { + string resourcePath = string `/v2/groups`; http:Request request = new; - GroupResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Group # - # + group_id - The ID of the group - # + return - Success response - resource isolated function get api/v2/groups/[int group_id](string accept = "application/json") returns GroupResponse|error { - string resourcePath = string `/api/v2/groups/${getEncodedUri(group_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + groupId - The ID of the group + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/groups/[int groupId](ShowGroupByIdHeaders headers = {}) returns GroupResponse|error { + string resourcePath = string `/v2/groups/${getEncodedUri(groupId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Group # - # + group_id - The ID of the group - # + return - Success response - resource isolated function put api/v2/groups/[int group_id](string accept = "application/json") returns GroupResponse|error { - string resourcePath = string `/api/v2/groups/${getEncodedUri(group_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + groupId - The ID of the group + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/groups/[int groupId](UpdateGroupHeaders headers = {}) returns GroupResponse|error { + string resourcePath = string `/v2/groups/${getEncodedUri(groupId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - GroupResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Group # - # + group_id - The ID of the group - # + return - No content response - resource isolated function delete api/v2/groups/[int group_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/groups/${getEncodedUri(group_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + groupId - The ID of the group + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/groups/[int groupId](DeleteGroupHeaders headers = {}) returns error? { + string resourcePath = string `/v2/groups/${getEncodedUri(groupId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Memberships # - # + group_id - The ID of the group - # + return - Success response - resource isolated function get api/v2/groups/[int group_id]/memberships(string accept = "application/json") returns GroupMembershipsResponse|error { - string resourcePath = string `/api/v2/groups/${getEncodedUri(group_id)}/memberships`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupMembershipsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + groupId - The ID of the group + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/groups/[int groupId]/memberships(ListGroupMembershipsByGroupIdHeaders headers = {}) returns GroupMembershipsResponse|error { + string resourcePath = string `/v2/groups/${getEncodedUri(groupId)}/memberships`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Assignable Groups # - # + return - Success response - resource isolated function get api/v2/groups/assignable() returns GroupsResponse|error { - string resourcePath = string `/api/v2/groups/assignable`; - GroupsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/groups/assignable(map headers = {}) returns GroupsResponse|error { + string resourcePath = string `/v2/groups/assignable`; + return self.clientEp->get(resourcePath, headers); } + # Count Groups # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/groups/count(string accept = "application/json") returns GroupsCountObject|error { - string resourcePath = string `/api/v2/groups/count`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupsCountObject response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/groups/count(CountGroupsHeaders headers = {}) returns GroupsCountObject|error { + string resourcePath = string `/v2/groups/count`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Ticket Import # - # + archive_immediately - If `true`, any ticket created with a `closed` status bypasses the normal ticket lifecycle and will be created directly in your ticket archive - # + return - Successfully created - resource isolated function post api/v2/imports/tickets(TicketImportRequest payload, string accept = "application/json", boolean? archive_immediately = ()) returns TicketResponse|error { - string resourcePath = string `/api/v2/imports/tickets`; - map queryParam = {"archive_immediately": archive_immediately}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successfully created + resource isolated function post v2/imports/tickets(TicketImportRequest payload, TicketImportHeaders headers = {}, *TicketImportQueries queries) returns TicketResponse|error { + string resourcePath = string `/v2/imports/tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TicketResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Ticket Bulk Import # - # + archive_immediately - If `true`, any ticket created with a `closed` status bypasses the normal ticket lifecycle and will be created directly in your ticket archive - # + return - Successful response - resource isolated function post api/v2/imports/tickets/create_many(TicketBulkImportRequest payload, string accept = "application/json", boolean? archive_immediately = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/imports/tickets/create_many`; - map queryParam = {"archive_immediately": archive_immediately}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function post v2/imports/tickets/create_many(TicketBulkImportRequest payload, TicketBulkImportHeaders headers = {}, *TicketBulkImportQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/imports/tickets/create_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Incremental Sample Export # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + incremental_resource - The resource requested for incremental sample export - # + return - Success response - resource isolated function get api/v2/incremental/[string incremental_resource]/sample(int start_time, string accept = "application/json") returns TimeBasedExportIncrementalTicketsResponse|error { - string resourcePath = string `/api/v2/incremental/${getEncodedUri(incremental_resource)}/sample`; - map queryParam = {"start_time": start_time}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TimeBasedExportIncrementalTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + incrementalResource - The resource requested for incremental sample export + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/[string incrementalResource]/sample(IncrementalSampleExportHeaders headers = {}, *IncrementalSampleExportQueries queries) returns TimeBasedExportIncrementalTicketsResponse|error { + string resourcePath = string `/v2/incremental/${getEncodedUri(incrementalResource)}/sample`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental Organization Export # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + return - Success response - resource isolated function get api/v2/incremental/organizations(int start_time, string accept = "application/json") returns ExportIncrementalOrganizationsResponse|error { - string resourcePath = string `/api/v2/incremental/organizations`; - map queryParam = {"start_time": start_time}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ExportIncrementalOrganizationsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/organizations(IncrementalOrganizationExportHeaders headers = {}, *IncrementalOrganizationExportQueries queries) returns ExportIncrementalOrganizationsResponse|error { + string resourcePath = string `/v2/incremental/organizations`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental Attributes Values Export # - # + return - Success response - resource isolated function get api/v2/incremental/routing/attribute_values() returns IncrementalSkillBasedRouting|error { - string resourcePath = string `/api/v2/incremental/routing/attribute_values`; - IncrementalSkillBasedRouting response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/routing/attribute_values(map headers = {}) returns IncrementalSkillBasedRouting|error { + string resourcePath = string `/v2/incremental/routing/attribute_values`; + return self.clientEp->get(resourcePath, headers); } + # Incremental Attributes Export # - # + return - Success response - resource isolated function get api/v2/incremental/routing/attributes() returns IncrementalSkillBasedRouting|error { - string resourcePath = string `/api/v2/incremental/routing/attributes`; - IncrementalSkillBasedRouting response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/routing/attributes(map headers = {}) returns IncrementalSkillBasedRouting|error { + string resourcePath = string `/v2/incremental/routing/attributes`; + return self.clientEp->get(resourcePath, headers); } + # Incremental Instance Values Export # - # + return - Success response - resource isolated function get api/v2/incremental/routing/instance_values() returns IncrementalSkillBasedRouting|error { - string resourcePath = string `/api/v2/incremental/routing/instance_values`; - IncrementalSkillBasedRouting response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/routing/instance_values(map headers = {}) returns IncrementalSkillBasedRouting|error { + string resourcePath = string `/v2/incremental/routing/instance_values`; + return self.clientEp->get(resourcePath, headers); } + # Incremental Ticket Event Export # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + return - Success response - resource isolated function get api/v2/incremental/ticket_events(int start_time, string accept = "application/json") returns ExportIncrementalTicketEventsResponse|error { - string resourcePath = string `/api/v2/incremental/ticket_events`; - map queryParam = {"start_time": start_time}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ExportIncrementalTicketEventsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/ticket_events(IncrementalTicketEventsHeaders headers = {}, *IncrementalTicketEventsQueries queries) returns ExportIncrementalTicketEventsResponse|error { + string resourcePath = string `/v2/incremental/ticket_events`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Ticket Metric Events # - # + start_time - The Unix UTC epoch time of the oldest event you're interested in. Example: 1332034771. - # + return - Successful response - resource isolated function get api/v2/incremental/ticket_metric_events(int start_time, string accept = "application/json") returns TicketMetricEventsResponse|error { - string resourcePath = string `/api/v2/incremental/ticket_metric_events`; - map queryParam = {"start_time": start_time}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketMetricEventsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function get v2/incremental/ticket_metric_events(ListTicketMetricEventsHeaders headers = {}, *ListTicketMetricEventsQueries queries) returns TicketMetricEventsResponse|error { + string resourcePath = string `/v2/incremental/ticket_metric_events`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental Ticket Export, Time Based # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + return - Success response - resource isolated function get api/v2/incremental/tickets(int start_time, string accept = "application/json") returns TimeBasedExportIncrementalTicketsResponse|error { - string resourcePath = string `/api/v2/incremental/tickets`; - map queryParam = {"start_time": start_time}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TimeBasedExportIncrementalTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/tickets(IncrementalTicketExportTimeHeaders headers = {}, *IncrementalTicketExportTimeQueries queries) returns TimeBasedExportIncrementalTicketsResponse|error { + string resourcePath = string `/v2/incremental/tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental Ticket Export, Cursor Based # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + cursor - The cursor pointer to work with for all subsequent exports after the initial request - # + return - Success response - resource isolated function get api/v2/incremental/tickets/cursor(int start_time, string accept = "application/json", string? cursor = ()) returns CursorBasedExportIncrementalTicketsResponse|error { - string resourcePath = string `/api/v2/incremental/tickets/cursor`; - map queryParam = {"start_time": start_time, "cursor": cursor}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CursorBasedExportIncrementalTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/tickets/cursor(IncrementalTicketExportCursorHeaders headers = {}, *IncrementalTicketExportCursorQueries queries) returns CursorBasedExportIncrementalTicketsResponse|error { + string resourcePath = string `/v2/incremental/tickets/cursor`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental User Export, Time Based # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + per_page - The number of records to return per page - # + return - Success response - resource isolated function get api/v2/incremental/users(int start_time, string accept = "application/json", int? per_page = ()) returns TimeBasedExportIncrementalUsersResponse|error { - string resourcePath = string `/api/v2/incremental/users`; - map queryParam = {"start_time": start_time, "per_page": per_page}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TimeBasedExportIncrementalUsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/users(IncrementalUserExportTimeHeaders headers = {}, *IncrementalUserExportTimeQueries queries) returns TimeBasedExportIncrementalUsersResponse|error { + string resourcePath = string `/v2/incremental/users`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Incremental User Export, Cursor Based # - # + start_time - The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute - # + cursor - The cursor pointer to work with for all subsequent exports after the initial request - # + per_page - The number of records to return per page - # + return - Success response - resource isolated function get api/v2/incremental/users/cursor(int start_time, string accept = "application/json", string? cursor = (), int? per_page = ()) returns CursorBasedExportIncrementalUsersResponse|error { - string resourcePath = string `/api/v2/incremental/users/cursor`; - map queryParam = {"start_time": start_time, "cursor": cursor, "per_page": per_page}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CursorBasedExportIncrementalUsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/incremental/users/cursor(IncrementalUserExportCursorHeaders headers = {}, *IncrementalUserExportCursorQueries queries) returns CursorBasedExportIncrementalUsersResponse|error { + string resourcePath = string `/v2/incremental/users/cursor`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Job Statuses # - # + return - Success Response - resource isolated function get api/v2/job_statuses() returns JobStatusesResponse|error { - string resourcePath = string `/api/v2/job_statuses`; - JobStatusesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/job_statuses(map headers = {}) returns JobStatusesResponse|error { + string resourcePath = string `/v2/job_statuses`; + return self.clientEp->get(resourcePath, headers); } + # Show Job Status # - # + job_status_id - the Id of the Job status - # + return - Success Response - resource isolated function get api/v2/job_statuses/[string job_status_id](string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/job_statuses/${getEncodedUri(job_status_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + jobStatusId - the Id of the Job status + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/job_statuses/[string jobStatusId](ShowJobStatusHeaders headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/job_statuses/${getEncodedUri(jobStatusId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Many Job Statuses # - # + ids - Comma-separated list of job status ids. - # + return - Success Response - resource isolated function get api/v2/job_statuses/show_many(string ids, string accept = "application/json") returns JobStatusesResponse|error { - string resourcePath = string `/api/v2/job_statuses/show_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success Response + resource isolated function get v2/job_statuses/show_many(ShowManyJobStatusesHeaders headers = {}, *ShowManyJobStatusesQueries queries) returns JobStatusesResponse|error { + string resourcePath = string `/v2/job_statuses/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Locales # - # + return - Success response - resource isolated function get api/v2/locales() returns LocalesResponse|error { - string resourcePath = string `/api/v2/locales`; - LocalesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/locales(map headers = {}) returns LocalesResponse|error { + string resourcePath = string `/v2/locales`; + return self.clientEp->get(resourcePath, headers); } + # Show Locale # - # + locale_id - The ID or the [BCP-47 code](https://en.wikipedia.org/wiki/IETF_language_tag) of the locale. Examples: es-419, en-us, pr-br - # + return - Success Response - resource isolated function get api/v2/locales/[string locale_id](string accept = "application/json") returns LocaleResponse|error { - string resourcePath = string `/api/v2/locales/${getEncodedUri(locale_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - LocaleResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + localeId - The ID or the [BCP-47 code](https://en.wikipedia.org/wiki/IETF_language_tag) of the locale. Examples: es-419, en-us, pr-br + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/locales/[string localeId](ShowLocaleByIdHeaders headers = {}) returns LocaleResponse|error { + string resourcePath = string `/v2/locales/${getEncodedUri(localeId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Locales for Agent # - # + return - Success response - resource isolated function get api/v2/locales/agent() returns LocalesResponse|error { - string resourcePath = string `/api/v2/locales/agent`; - LocalesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/locales/agent(map headers = {}) returns LocalesResponse|error { + string resourcePath = string `/v2/locales/agent`; + return self.clientEp->get(resourcePath, headers); } + # Show Current Locale # - # + return - Success response - resource isolated function get api/v2/locales/current() returns LocaleResponse|error { - string resourcePath = string `/api/v2/locales/current`; - LocaleResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/locales/current(map headers = {}) returns LocaleResponse|error { + string resourcePath = string `/v2/locales/current`; + return self.clientEp->get(resourcePath, headers); } + # Detect Best Language for User # - # + return - Success response - resource isolated function get api/v2/locales/detect_best_locale() returns LocaleResponse|error { - string resourcePath = string `/api/v2/locales/detect_best_locale`; - LocaleResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/locales/detect_best_locale(map headers = {}) returns LocaleResponse|error { + string resourcePath = string `/v2/locales/detect_best_locale`; + return self.clientEp->get(resourcePath, headers); } + # List Available Public Locales # - # + return - Success response - resource isolated function get api/v2/locales/'public() returns LocalesResponse|error { - string resourcePath = string `/api/v2/locales/public`; - LocalesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/locales/'public(map headers = {}) returns LocalesResponse|error { + string resourcePath = string `/v2/locales/public`; + return self.clientEp->get(resourcePath, headers); } + # List Macros # - # + include - A sideload to include in the response. See [Sideloads](#sideloads-2) - # + access - Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins. - # + active - Filter by active macros if true or inactive macros if false - # + category - Filter macros by category - # + group_id - Filter macros by group - # + only_viewable - If true, returns only macros that can be applied to tickets. If false, returns all macros the current user can manage. Default is false - # + sort_by - Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + return - Success Response - resource isolated function get api/v2/macros(string accept = "application/json", string? include = (), string? access = (), boolean? active = (), int? category = (), int? group_id = (), boolean? only_viewable = (), string? sort_by = (), string? sort_order = ()) returns MacrosResponse|error { - string resourcePath = string `/api/v2/macros`; - map queryParam = {"include": include, "access": access, "active": active, "category": category, "group_id": group_id, "only_viewable": only_viewable, "sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacrosResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success Response + resource isolated function get v2/macros(ListMacrosHeaders headers = {}, *ListMacrosQueries queries) returns MacrosResponse|error { + string resourcePath = string `/v2/macros`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Macro # - # + return - OK - resource isolated function post api/v2/macros(V2_macros_body payload) returns Inline_response_200_2|error { - string resourcePath = string `/api/v2/macros`; + # + headers - Headers to be sent with the request + # + return - OK + resource isolated function post v2/macros(V2MacrosBody payload, map headers = {}) returns InlineResponse2002|error { + string resourcePath = string `/v2/macros`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - Inline_response_200_2 response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Macro # - # + macro_id - The ID of the macro - # + return - Success Response - resource isolated function get api/v2/macros/[int macro_id](string accept = "application/json") returns MacroResponse|error { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/[int macroId](ShowMacroHeaders headers = {}) returns MacroResponse|error { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Macro # - # + macro_id - The ID of the macro - # + return - OK - resource isolated function put api/v2/macros/[int macro_id](Macros_macro_id_body payload, string accept = "application/json") returns Inline_response_200_2|error { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - OK + resource isolated function put v2/macros/[int macroId](V2MacrosBody payload, UpdateMacroHeaders headers = {}) returns InlineResponse2002|error { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - Inline_response_200_2 response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Macro # - # + macro_id - The ID of the macro - # + return - No Content - resource isolated function delete api/v2/macros/[int macro_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - No Content + resource isolated function delete v2/macros/[int macroId](DeleteMacroHeaders headers = {}) returns error? { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Show Changes to Ticket # - # + macro_id - The ID of the macro - # + return - Success Response - resource isolated function get api/v2/macros/[int macro_id]/apply(string accept = "application/json") returns MacroApplyTicketResponse|error { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}/apply`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroApplyTicketResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/[int macroId]/apply(ShowChangesToTicketHeaders headers = {}) returns MacroApplyTicketResponse|error { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}/apply`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Macro Attachments # - # + macro_id - The ID of the macro - # + return - Success Response - resource isolated function get api/v2/macros/[int macro_id]/attachments(string accept = "application/json") returns MacroAttachmentsResponse|error { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}/attachments`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroAttachmentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/[int macroId]/attachments(ListMacroAttachmentsHeaders headers = {}) returns MacroAttachmentsResponse|error { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}/attachments`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Macro Attachment # - # + macro_id - The ID of the macro - # + return - Success Response - resource isolated function post api/v2/macros/[int macro_id]/attachments(string accept = "application/json") returns MacroAttachmentResponse|error { - string resourcePath = string `/api/v2/macros/${getEncodedUri(macro_id)}/attachments`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + macroId - The ID of the macro + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function post v2/macros/[int macroId]/attachments(CreateAssociatedMacroAttachmentHeaders headers = {}) returns MacroAttachmentResponse|error { + string resourcePath = string `/v2/macros/${getEncodedUri(macroId)}/attachments`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - MacroAttachmentResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # List Supported Actions for Macros # - # + return - Success Response - resource isolated function get api/v2/macros/actions() returns Inline_response_200_3|error { - string resourcePath = string `/api/v2/macros/actions`; - Inline_response_200_3 response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/actions(map headers = {}) returns InlineResponse2003|error { + string resourcePath = string `/v2/macros/actions`; + return self.clientEp->get(resourcePath, headers); } + # List Active Macros # - # + include - A sideload to include in the response. See [Sideloads](#sideloads-2) - # + access - Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins. - # + category - Filter macros by category - # + group_id - Filter macros by group - # + sort_by - Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + return - Success Response - resource isolated function get api/v2/macros/active(string accept = "application/json", string? include = (), string? access = (), int? category = (), int? group_id = (), string? sort_by = (), string? sort_order = ()) returns MacrosResponse|error { - string resourcePath = string `/api/v2/macros/active`; - map queryParam = {"include": include, "access": access, "category": category, "group_id": group_id, "sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacrosResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/active(ListActiveMacrosHeaders headers = {}, *ListActiveMacrosQueries queries) returns MacrosResponse|error { + string resourcePath = string `/v2/macros/active`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Unassociated Macro Attachment # - # + return - Created Response - resource isolated function post api/v2/macros/attachments() returns MacroAttachmentResponse|error { - string resourcePath = string `/api/v2/macros/attachments`; + # + headers - Headers to be sent with the request + # + return - Created Response + resource isolated function post v2/macros/attachments(map headers = {}) returns MacroAttachmentResponse|error { + string resourcePath = string `/v2/macros/attachments`; http:Request request = new; - MacroAttachmentResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Macro Attachment # - # + attachment_id - The ID of the attachment - # + return - Success Response - resource isolated function get api/v2/macros/attachments/[int attachment_id](string accept = "application/json") returns MacroAttachmentResponse|error { - string resourcePath = string `/api/v2/macros/attachments/${getEncodedUri(attachment_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroAttachmentResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + attachmentId - The ID of the attachment + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/attachments/[int attachmentId](ShowMacroAttachmentHeaders headers = {}) returns MacroAttachmentResponse|error { + string resourcePath = string `/v2/macros/attachments/${getEncodedUri(attachmentId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Macro Categories # - # + return - Success Response - resource isolated function get api/v2/macros/categories() returns MacroCategoriesResponse|error { - string resourcePath = string `/api/v2/macros/categories`; - MacroCategoriesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/categories(map headers = {}) returns MacroCategoriesResponse|error { + string resourcePath = string `/v2/macros/categories`; + return self.clientEp->get(resourcePath, headers); } + # List Macro Action Definitions # - # + return - Success Response - resource isolated function get api/v2/macros/definitions() returns Inline_response_200_4|error { - string resourcePath = string `/api/v2/macros/definitions`; - Inline_response_200_4 response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/definitions(map headers = {}) returns InlineResponse2004|error { + string resourcePath = string `/v2/macros/definitions`; + return self.clientEp->get(resourcePath, headers); } + # Bulk Delete Macros # - # + ids - The IDs of the macros to delete - # + return - No Content - resource isolated function delete api/v2/macros/destroy_many(int[] ids, string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/macros/destroy_many`; - map queryParam = {"ids": ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No Content + resource isolated function delete v2/macros/destroy_many(DeleteManyMacrosHeaders headers = {}, *DeleteManyMacrosQueries queries) returns error? { + string resourcePath = string `/v2/macros/destroy_many`; map queryParamEncoding = {"ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Show Macro Replica # - # + macro_id - The ID of the macro to replicate - # + ticket_id - The ID of the ticket from which to build a macro replica - # + return - Success Response - resource isolated function get api/v2/macros/'new(int macro_id, int ticket_id, string accept = "application/json") returns MacroResponse|error { - string resourcePath = string `/api/v2/macros/new`; - map queryParam = {"macro_id": macro_id, "ticket_id": ticket_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/'new(ShowDerivedMacroHeaders headers = {}, *ShowDerivedMacroQueries queries) returns MacroResponse|error { + string resourcePath = string `/v2/macros/new`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Search Macros # - # + include - A sideload to include in the response. See [Sideloads](#sideloads-2) - # + access - Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins. - # + active - Filter by active macros if true or inactive macros if false - # + category - Filter macros by category - # + group_id - Filter macros by group - # + only_viewable - If true, returns only macros that can be applied to tickets. If false, returns all macros the current user can manage. Default is false - # + sort_by - Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + query - Query string used to find macros with matching titles - # + return - Success Response - resource isolated function get api/v2/macros/search(string query, string accept = "application/json", string? include = (), string? access = (), boolean? active = (), int? category = (), int? group_id = (), boolean? only_viewable = (), string? sort_by = (), string? sort_order = ()) returns MacrosResponse|error { - string resourcePath = string `/api/v2/macros/search`; - map queryParam = {"include": include, "access": access, "active": active, "category": category, "group_id": group_id, "only_viewable": only_viewable, "sort_by": sort_by, "sort_order": sort_order, "query": query}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacrosResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success Response + resource isolated function get v2/macros/search(SearchMacroHeaders headers = {}, *SearchMacroQueries queries) returns MacrosResponse|error { + string resourcePath = string `/v2/macros/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Macros # - # + return - Success Response - resource isolated function put api/v2/macros/update_many(MacroUpdateManyInput payload) returns MacrosResponse|error { - string resourcePath = string `/api/v2/macros/update_many`; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function put v2/macros/update_many(MacroUpdateManyInput payload, map headers = {}) returns MacrosResponse|error { + string resourcePath = string `/v2/macros/update_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - MacrosResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # Show Essentials Card # - # + object_type - Essentials card type. Example: `zen:user` refers user type - # + return - Success response - resource isolated function get api/v2/object_layouts/[string object_type]/essentials_card(string accept = "application/json") returns EssentialsCardResponse|error { - string resourcePath = string `/api/v2/object_layouts/${getEncodedUri(object_type)}/essentials_card`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - EssentialsCardResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + objectType - Essentials card type. Example: `zen:user` refers user type + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/object_layouts/[string objectType]/essentials_card(ShowEssentialsCardHeaders headers = {}) returns EssentialsCardResponse|error { + string resourcePath = string `/v2/object_layouts/${getEncodedUri(objectType)}/essentials_card`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Essentials Card # - # + object_type - Essentials card type. Example: `zen:user` refers user type - # + return - Success response - resource isolated function put api/v2/object_layouts/[string object_type]/essentials_card(string accept = "application/json") returns EssentialsCardResponse|error { - string resourcePath = string `/api/v2/object_layouts/${getEncodedUri(object_type)}/essentials_card`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + objectType - Essentials card type. Example: `zen:user` refers user type + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/object_layouts/[string objectType]/essentials_card(UpdateEssentialsCardHeaders headers = {}) returns EssentialsCardResponse|error { + string resourcePath = string `/v2/object_layouts/${getEncodedUri(objectType)}/essentials_card`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - EssentialsCardResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Essentials Card # - # + object_type - Essentials card type. Example: `zen:user` refers user type - # + return - Success response - resource isolated function delete api/v2/object_layouts/[string object_type]/essentials_card(string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/object_layouts/${getEncodedUri(object_type)}/essentials_card`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + objectType - Essentials card type. Example: `zen:user` refers user type + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function delete v2/object_layouts/[string objectType]/essentials_card(DeleteEssentialsCardHeaders headers = {}) returns error? { + string resourcePath = string `/v2/object_layouts/${getEncodedUri(objectType)}/essentials_card`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List of Essentials Cards # - # + return - Success response - resource isolated function get api/v2/object_layouts/essentials_cards() returns EssentialsCardsResponse|error { - string resourcePath = string `/api/v2/object_layouts/essentials_cards`; - EssentialsCardsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/object_layouts/essentials_cards(map headers = {}) returns EssentialsCardsResponse|error { + string resourcePath = string `/v2/object_layouts/essentials_cards`; + return self.clientEp->get(resourcePath, headers); } + # List Organization Fields # - # + return - Success response - resource isolated function get api/v2/organization_fields() returns OrganizationFieldsResponse|error { - string resourcePath = string `/api/v2/organization_fields`; - OrganizationFieldsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organization_fields(map headers = {}) returns OrganizationFieldsResponse|error { + string resourcePath = string `/v2/organization_fields`; + return self.clientEp->get(resourcePath, headers); } + # Create Organization Field # - # + return - Created response - resource isolated function post api/v2/organization_fields() returns OrganizationFieldResponse|error { - string resourcePath = string `/api/v2/organization_fields`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/organization_fields(map headers = {}) returns OrganizationFieldResponse|error { + string resourcePath = string `/v2/organization_fields`; http:Request request = new; - OrganizationFieldResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Organization Field # - # + organization_field_id - The ID or key of the organization field - # + return - Success response - resource isolated function get api/v2/organization_fields/[Organization_field_id organization_field_id](string accept = "application/json") returns OrganizationFieldResponse|error { - string resourcePath = string `/api/v2/organization_fields/${getEncodedUri(organization_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationFieldResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + organizationFieldId - The ID or key of the organization field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organization_fields/[organizationFieldId organizationFieldId](ShowOrganizationFieldHeaders headers = {}) returns OrganizationFieldResponse|error { + string resourcePath = string `/v2/organization_fields/${getEncodedUri(organizationFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Organization Field # - # + organization_field_id - The ID or key of the organization field - # + return - Success response - resource isolated function put api/v2/organization_fields/[Organization_field_id organization_field_id](string accept = "application/json") returns OrganizationFieldResponse|error { - string resourcePath = string `/api/v2/organization_fields/${getEncodedUri(organization_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationFieldId - The ID or key of the organization field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/organization_fields/[organizationFieldId organizationFieldId](UpdateOrganizationFieldHeaders headers = {}) returns OrganizationFieldResponse|error { + string resourcePath = string `/v2/organization_fields/${getEncodedUri(organizationFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - OrganizationFieldResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Organization Field # - # + organization_field_id - The ID or key of the organization field - # + return - No Content response - resource isolated function delete api/v2/organization_fields/[Organization_field_id organization_field_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/organization_fields/${getEncodedUri(organization_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationFieldId - The ID or key of the organization field + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/organization_fields/[organizationFieldId organizationFieldId](DeleteOrganizationFieldHeaders headers = {}) returns error? { + string resourcePath = string `/v2/organization_fields/${getEncodedUri(organizationFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Reorder Organization Field # - # + return - Success response - resource isolated function put api/v2/organization_fields/reorder() returns string|error { - string resourcePath = string `/api/v2/organization_fields/reorder`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/organization_fields/reorder(map headers = {}) returns string|error { + string resourcePath = string `/v2/organization_fields/reorder`; http:Request request = new; - string response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # List Memberships # - # + return - Success response - resource isolated function get api/v2/organization_memberships() returns OrganizationMembershipsResponse|error { - string resourcePath = string `/api/v2/organization_memberships`; - OrganizationMembershipsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organization_memberships(map headers = {}) returns OrganizationMembershipsResponse|error { + string resourcePath = string `/v2/organization_memberships`; + return self.clientEp->get(resourcePath, headers); } + # Create Membership # - # + return - Created response - resource isolated function post api/v2/organization_memberships() returns OrganizationMembershipResponse|error { - string resourcePath = string `/api/v2/organization_memberships`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/organization_memberships(map headers = {}) returns OrganizationMembershipResponse|error { + string resourcePath = string `/v2/organization_memberships`; http:Request request = new; - OrganizationMembershipResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Membership # - # + organization_membership_id - The ID of the organization membership - # + return - Success response - resource isolated function get api/v2/organization_memberships/[int organization_membership_id](string accept = "application/json") returns OrganizationMembershipResponse|error { - string resourcePath = string `/api/v2/organization_memberships/${getEncodedUri(organization_membership_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationMembershipResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + organizationMembershipId - The ID of the organization membership + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organization_memberships/[int organizationMembershipId](ShowOrganizationMembershipByIdHeaders headers = {}) returns OrganizationMembershipResponse|error { + string resourcePath = string `/v2/organization_memberships/${getEncodedUri(organizationMembershipId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Membership # - # + organization_membership_id - The ID of the organization membership - # + return - No Content response - resource isolated function delete api/v2/organization_memberships/[int organization_membership_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/organization_memberships/${getEncodedUri(organization_membership_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationMembershipId - The ID of the organization membership + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/organization_memberships/[int organizationMembershipId](DeleteOrganizationMembershipHeaders headers = {}) returns error? { + string resourcePath = string `/v2/organization_memberships/${getEncodedUri(organizationMembershipId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Create Many Memberships # - # + return - Success response - resource isolated function post api/v2/organization_memberships/create_many() returns JobStatusResponse|error { - string resourcePath = string `/api/v2/organization_memberships/create_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/organization_memberships/create_many(map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/organization_memberships/create_many`; http:Request request = new; - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Bulk Delete Memberships # - # + ids - The IDs of the organization memberships to delete - # + return - Success response - resource isolated function delete api/v2/organization_memberships/destroy_many(string accept = "application/json", int[]? ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/organization_memberships/destroy_many`; - map queryParam = {"ids": ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function delete v2/organization_memberships/destroy_many(DeleteManyOrganizationMembershipsHeaders headers = {}, *DeleteManyOrganizationMembershipsQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/organization_memberships/destroy_many`; map queryParamEncoding = {"ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Organization Subscriptions # - # + return - Successful response - resource isolated function get api/v2/organization_subscriptions() returns OrganizationSubscriptionsResponse|error { - string resourcePath = string `/api/v2/organization_subscriptions`; - OrganizationSubscriptionsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/organization_subscriptions(map headers = {}) returns OrganizationSubscriptionsResponse|error { + string resourcePath = string `/v2/organization_subscriptions`; + return self.clientEp->get(resourcePath, headers); } + # Create Organization Subscription # - # + return - Successful response - resource isolated function post api/v2/organization_subscriptions(OrganizationSubscriptionCreateRequest payload) returns OrganizationSubscriptionResponse|error { - string resourcePath = string `/api/v2/organization_subscriptions`; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/organization_subscriptions(OrganizationSubscriptionCreateRequest payload, map headers = {}) returns OrganizationSubscriptionResponse|error { + string resourcePath = string `/v2/organization_subscriptions`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - OrganizationSubscriptionResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Organization Subscription # - # + organization_subscription_id - The ID of the organization subscription - # + return - Successful response - resource isolated function get api/v2/organization_subscriptions/[int organization_subscription_id](string accept = "application/json") returns OrganizationSubscriptionResponse|error { - string resourcePath = string `/api/v2/organization_subscriptions/${getEncodedUri(organization_subscription_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationSubscriptionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + organizationSubscriptionId - The ID of the organization subscription + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/organization_subscriptions/[int organizationSubscriptionId](ShowOrganizationSubscriptionHeaders headers = {}) returns OrganizationSubscriptionResponse|error { + string resourcePath = string `/v2/organization_subscriptions/${getEncodedUri(organizationSubscriptionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Organization Subscription # - # + organization_subscription_id - The ID of the organization subscription - # + return - No content - resource isolated function delete api/v2/organization_subscriptions/[int organization_subscription_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/organization_subscriptions/${getEncodedUri(organization_subscription_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationSubscriptionId - The ID of the organization subscription + # + headers - Headers to be sent with the request + # + return - No content + resource isolated function delete v2/organization_subscriptions/[int organizationSubscriptionId](DeleteOrganizationSubscriptionHeaders headers = {}) returns error? { + string resourcePath = string `/v2/organization_subscriptions/${getEncodedUri(organizationSubscriptionId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Organizations # - # + return - Success response - resource isolated function get api/v2/organizations() returns OrganizationsResponse|error { - string resourcePath = string `/api/v2/organizations`; - OrganizationsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organizations(map headers = {}) returns OrganizationsResponse|error { + string resourcePath = string `/v2/organizations`; + return self.clientEp->get(resourcePath, headers); } + # Create Organization # - # + return - Created - resource isolated function post api/v2/organizations() returns OrganizationResponse|error { - string resourcePath = string `/api/v2/organizations`; + # + headers - Headers to be sent with the request + # + return - Created + resource isolated function post v2/organizations(map headers = {}) returns OrganizationResponse|error { + string resourcePath = string `/v2/organizations`; http:Request request = new; - OrganizationResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Organization # - # + organization_id - The ID of an organization - # + return - Success response - resource isolated function get api/v2/organizations/[int organization_id](string accept = "application/json") returns OrganizationResponse|error { - string resourcePath = string `/api/v2/organizations/${getEncodedUri(organization_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + organizationId - The ID of an organization + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/[int organizationId](ShowOrganizationHeaders headers = {}) returns OrganizationResponse|error { + string resourcePath = string `/v2/organizations/${getEncodedUri(organizationId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Organization # - # + organization_id - The ID of an organization - # + return - Success response - resource isolated function put api/v2/organizations/[int organization_id](string accept = "application/json") returns OrganizationResponse|error { - string resourcePath = string `/api/v2/organizations/${getEncodedUri(organization_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationId - The ID of an organization + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/organizations/[int organizationId](UpdateOrganizationHeaders headers = {}) returns OrganizationResponse|error { + string resourcePath = string `/v2/organizations/${getEncodedUri(organizationId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - OrganizationResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Organization # - # + organization_id - The ID of an organization - # + return - No Content Response - resource isolated function delete api/v2/organizations/[int organization_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/organizations/${getEncodedUri(organization_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationId - The ID of an organization + # + headers - Headers to be sent with the request + # + return - No Content Response + resource isolated function delete v2/organizations/[int organizationId](DeleteOrganizationHeaders headers = {}) returns error? { + string resourcePath = string `/v2/organizations/${getEncodedUri(organizationId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Show Organization's Related Information # - # + organization_id - The ID of an organization - # + return - Success response - resource isolated function get api/v2/organizations/[int organization_id]/related(string accept = "application/json") returns OrganizationsRelatedResponse|error { - string resourcePath = string `/api/v2/organizations/${getEncodedUri(organization_id)}/related`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationsRelatedResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + organizationId - The ID of an organization + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/[int organizationId]/related(OrganizationRelatedHeaders headers = {}) returns OrganizationsRelatedResponse|error { + string resourcePath = string `/v2/organizations/${getEncodedUri(organizationId)}/related`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Autocomplete Organizations # - # + name - A substring of an organization to search for - # + field_id - The id of a lookup relationship field. The type of field is determined - # by the `source` param - # + 'source - If a `field_id` is provided, this specifies the type of the field. - # For example, if the field is on a "zen:user", it references a field on a user - # + return - Success response - resource isolated function get api/v2/organizations/autocomplete(string name, string accept = "application/json", string? field_id = (), string? 'source = ()) returns OrganizationsResponse|error { - string resourcePath = string `/api/v2/organizations/autocomplete`; - map queryParam = {"name": name, "field_id": field_id, "source": 'source}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/autocomplete(AutocompleteOrganizationsHeaders headers = {}, *AutocompleteOrganizationsQueries queries) returns OrganizationsResponse|error { + string resourcePath = string `/v2/organizations/autocomplete`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Count Organizations # - # + return - Success response - resource isolated function get api/v2/organizations/count() returns CountOrganizationResponse|error { - string resourcePath = string `/api/v2/organizations/count`; - CountOrganizationResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/count(map headers = {}) returns CountOrganizationResponse|error { + string resourcePath = string `/v2/organizations/count`; + return self.clientEp->get(resourcePath, headers); } + # Create Many Organizations # - # + return - Success response - resource isolated function post api/v2/organizations/create_many() returns JobStatusResponse|error { - string resourcePath = string `/api/v2/organizations/create_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/organizations/create_many(map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/organizations/create_many`; http:Request request = new; - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Create Or Update Organization # - # + return - Success response - resource isolated function post api/v2/organizations/create_or_update() returns OrganizationResponse|error { - string resourcePath = string `/api/v2/organizations/create_or_update`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/organizations/create_or_update(map headers = {}) returns OrganizationResponse|error { + string resourcePath = string `/v2/organizations/create_or_update`; http:Request request = new; - OrganizationResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Bulk Delete Organizations # - # + ids - A list of organization ids - # + external_ids - A list of external ids - # + return - Success response - resource isolated function delete api/v2/organizations/destroy_many(string accept = "application/json", string? ids = (), string? external_ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/organizations/destroy_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function delete v2/organizations/destroy_many(DeleteManyOrganizationsHeaders headers = {}, *DeleteManyOrganizationsQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/organizations/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Search Organizations # - # + external_id - The external id of an organization - # + name - The name of an organization - # + return - Success response - resource isolated function get api/v2/organizations/search(string accept = "application/json", int? external_id = (), string? name = ()) returns OrganizationsResponse|error { - string resourcePath = string `/api/v2/organizations/search`; - map queryParam = {"external_id": external_id, "name": name}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/search(SearchOrganizationsHeaders headers = {}, *SearchOrganizationsQueries queries) returns OrganizationsResponse|error { + string resourcePath = string `/v2/organizations/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Many Organizations # - # + ids - A list of organization ids - # + external_ids - A list of external ids - # + return - Success response - resource isolated function get api/v2/organizations/show_many(string accept = "application/json", string? ids = (), string? external_ids = ()) returns OrganizationsResponse|error { - string resourcePath = string `/api/v2/organizations/show_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - OrganizationsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/organizations/show_many(ShowManyOrganizationsHeaders headers = {}, *ShowManyOrganizationsQueries queries) returns OrganizationsResponse|error { + string resourcePath = string `/v2/organizations/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Organizations # - # + ids - A list of organization ids - # + external_ids - A list of external ids - # + return - Success response - resource isolated function put api/v2/organizations/update_many(string accept = "application/json", string? ids = (), string? external_ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/organizations/update_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function put v2/organizations/update_many(UpdateManyOrganizationsHeaders headers = {}, *UpdateManyOrganizationsQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/organizations/update_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - JobStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Ticket Problems # - # + return - Successful response - resource isolated function get api/v2/problems() returns ListTicketProblemsResponse|error { - string resourcePath = string `/api/v2/problems`; - ListTicketProblemsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/problems(map headers = {}) returns ListTicketProblemsResponse|error { + string resourcePath = string `/v2/problems`; + return self.clientEp->get(resourcePath, headers); } + # Autocomplete Problems # - # + text - The text to search for - # + return - Successful response - resource isolated function post api/v2/problems/autocomplete(Problems_autocomplete_body payload, string accept = "application/json", string? text = ()) returns ListTicketProblemsResponse|error { - string resourcePath = string `/api/v2/problems/autocomplete`; - map queryParam = {"text": text}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function post v2/problems/autocomplete(ProblemsAutocompleteBody payload, AutocompleteProblemsHeaders headers = {}, *AutocompleteProblemsQueries queries) returns ListTicketProblemsResponse|error { + string resourcePath = string `/v2/problems/autocomplete`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - ListTicketProblemsResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Bulk Unregister Push Notification Devices # - # + return - Successful response - resource isolated function post api/v2/push_notification_devices/destroy_many(PushNotificationDevicesRequest payload) returns string|error { - string resourcePath = string `/api/v2/push_notification_devices/destroy_many`; + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/push_notification_devices/destroy_many(PushNotificationDevicesRequest payload, map headers = {}) returns string|error { + string resourcePath = string `/v2/push_notification_devices/destroy_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - string response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # List queues # - # + return - Success response - resource isolated function get api/v2/queues() returns QueuesResponse|error { - string resourcePath = string `/api/v2/queues`; - QueuesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/queues(map headers = {}) returns QueuesResponse|error { + string resourcePath = string `/v2/queues`; + return self.clientEp->get(resourcePath, headers); } + # Create queue # - # + return - Created response - resource isolated function post api/v2/queues() returns QueueResponse|error { - string resourcePath = string `/api/v2/queues`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/queues(map headers = {}) returns QueueResponse|error { + string resourcePath = string `/v2/queues`; http:Request request = new; - QueueResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Queue # - # + queue_id - The id of the omnichannel routing queue - # + return - Success response - resource isolated function get api/v2/queues/[string queue_id](string accept = "application/json") returns QueueResponse|error { - string resourcePath = string `/api/v2/queues/${getEncodedUri(queue_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - QueueResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + queueId - The id of the omnichannel routing queue + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/queues/[string queueId](ShowQueueByIdHeaders headers = {}) returns QueueResponse|error { + string resourcePath = string `/v2/queues/${getEncodedUri(queueId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update queue # - # + queue_id - The id of the omnichannel routing queue - # + return - Success response - resource isolated function put api/v2/queues/[string queue_id](string accept = "application/json") returns QueueResponse|error { - string resourcePath = string `/api/v2/queues/${getEncodedUri(queue_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + queueId - The id of the omnichannel routing queue + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/queues/[string queueId](UpdateQueueHeaders headers = {}) returns QueueResponse|error { + string resourcePath = string `/v2/queues/${getEncodedUri(queueId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - QueueResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete queue # - # + queue_id - The id of the omnichannel routing queue - # + return - No content response - resource isolated function delete api/v2/queues/[string queue_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/queues/${getEncodedUri(queue_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + queueId - The id of the omnichannel routing queue + # + headers - Headers to be sent with the request + # + return - No content response + resource isolated function delete v2/queues/[string queueId](DeleteQueueHeaders headers = {}) returns error? { + string resourcePath = string `/v2/queues/${getEncodedUri(queueId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List queue definitions # - # + return - Success response - resource isolated function get api/v2/queues/definitions() returns DefinitionsResponse|error { - string resourcePath = string `/api/v2/queues/definitions`; - DefinitionsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/queues/definitions(map headers = {}) returns DefinitionsResponse|error { + string resourcePath = string `/v2/queues/definitions`; + return self.clientEp->get(resourcePath, headers); } + # List Support Addresses # - # + return - Success response - resource isolated function get api/v2/recipient_addresses() returns SupportAddressesResponse|error { - string resourcePath = string `/api/v2/recipient_addresses`; - SupportAddressesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/recipient_addresses(map headers = {}) returns SupportAddressesResponse|error { + string resourcePath = string `/v2/recipient_addresses`; + return self.clientEp->get(resourcePath, headers); } + # Create Support Address # - # + return - Created response - resource isolated function post api/v2/recipient_addresses() returns SupportAddressResponse|error { - string resourcePath = string `/api/v2/recipient_addresses`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/recipient_addresses(map headers = {}) returns SupportAddressResponse|error { + string resourcePath = string `/v2/recipient_addresses`; http:Request request = new; - SupportAddressResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Support Address # - # + support_address_id - The ID of the support address - # + return - Success response - resource isolated function get api/v2/recipient_addresses/[int support_address_id](string accept = "application/json") returns SupportAddressResponse|error { - string resourcePath = string `/api/v2/recipient_addresses/${getEncodedUri(support_address_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SupportAddressResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + supportAddressId - The ID of the support address + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/recipient_addresses/[int supportAddressId](ShowSupportAddressHeaders headers = {}) returns SupportAddressResponse|error { + string resourcePath = string `/v2/recipient_addresses/${getEncodedUri(supportAddressId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Support Address # - # + support_address_id - The ID of the support address - # + return - Success response - resource isolated function put api/v2/recipient_addresses/[int support_address_id](string accept = "application/json") returns SupportAddressResponse|error { - string resourcePath = string `/api/v2/recipient_addresses/${getEncodedUri(support_address_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + supportAddressId - The ID of the support address + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/recipient_addresses/[int supportAddressId](UpdateSupportAddressHeaders headers = {}) returns SupportAddressResponse|error { + string resourcePath = string `/v2/recipient_addresses/${getEncodedUri(supportAddressId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SupportAddressResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Support Address # - # + support_address_id - The ID of the support address - # + return - No Content response - resource isolated function delete api/v2/recipient_addresses/[int support_address_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/recipient_addresses/${getEncodedUri(support_address_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + supportAddressId - The ID of the support address + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/recipient_addresses/[int supportAddressId](DeleteRecipientAddressHeaders headers = {}) returns error? { + string resourcePath = string `/v2/recipient_addresses/${getEncodedUri(supportAddressId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Verify Support Address Forwarding # - # + support_address_id - The ID of the support address - # + return - Success response - resource isolated function put api/v2/recipient_addresses/[int support_address_id]/verify(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/recipient_addresses/${getEncodedUri(support_address_id)}/verify`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + supportAddressId - The ID of the support address + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/recipient_addresses/[int supportAddressId]/verify(VerifySupportAddressForwardingHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/recipient_addresses/${getEncodedUri(supportAddressId)}/verify`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Filter Definitions # - # + target_type - The target type for which you would like to see filter definitions. + # + targetType - The target type for which you would like to see filter definitions. # The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - # + source_type - The source type for which you would like to see filter definitions. - # The options are "zen:user", "zen:ticket", and "zen:organization" - # + return - Success response - resource isolated function get api/v2/relationships/definitions/[string target_type](string accept = "application/json", string? source_type = ()) returns RelationshipFilterDefinitionResponse|error { - string resourcePath = string `/api/v2/relationships/definitions/${getEncodedUri(target_type)}`; - map queryParam = {"source_type": source_type}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - RelationshipFilterDefinitionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/relationships/definitions/[string targetType](GetRelationshipFilterDefinitionsHeaders headers = {}, *GetRelationshipFilterDefinitionsQueries queries) returns RelationshipFilterDefinitionResponse|error { + string resourcePath = string `/v2/relationships/definitions/${getEncodedUri(targetType)}`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Requests # - # + sort_by - Possible values are "updated_at", "created_at" - # + sort_order - One of "asc", "desc". Defaults to "asc" - # + return - Success response - resource isolated function get api/v2/requests(string accept = "application/json", string? sort_by = (), string? sort_order = ()) returns RequestsResponse|error { - string resourcePath = string `/api/v2/requests`; - map queryParam = {"sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - RequestsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/requests(ListRequestsHeaders headers = {}, *ListRequestsQueries queries) returns RequestsResponse|error { + string resourcePath = string `/v2/requests`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Request # - # + return - Created response - resource isolated function post api/v2/requests() returns RequestResponse|error { - string resourcePath = string `/api/v2/requests`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/requests(map headers = {}) returns RequestResponse|error { + string resourcePath = string `/v2/requests`; http:Request request = new; - RequestResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Request # - # + request_id - The ID of the request - # + return - Success response - resource isolated function get api/v2/requests/[int request_id](string accept = "application/json") returns RequestResponse|error { - string resourcePath = string `/api/v2/requests/${getEncodedUri(request_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - RequestResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + requestId - The ID of the request + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/requests/[int requestId](ShowRequestHeaders headers = {}) returns RequestResponse|error { + string resourcePath = string `/v2/requests/${getEncodedUri(requestId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Request # - # + request_id - The ID of the request - # + return - Success response - resource isolated function put api/v2/requests/[int request_id](string accept = "application/json") returns RequestResponse|error { - string resourcePath = string `/api/v2/requests/${getEncodedUri(request_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + requestId - The ID of the request + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/requests/[int requestId](UpdateRequestHeaders headers = {}) returns RequestResponse|error { + string resourcePath = string `/v2/requests/${getEncodedUri(requestId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - RequestResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Listing Comments # - # + request_id - The ID of the request - # + since - Filters the comments from the given datetime - # + role - One of "agent", "end_user". If not specified it does not filter - # + return - Success response - resource isolated function get api/v2/requests/[int request_id]/comments(string accept = "application/json", string? since = (), string? role = ()) returns TicketCommentsResponse|error { - string resourcePath = string `/api/v2/requests/${getEncodedUri(request_id)}/comments`; - map queryParam = {"since": since, "role": role}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketCommentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + requestId - The ID of the request + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/requests/[int requestId]/comments(ListCommentsHeaders headers = {}, *ListCommentsQueries queries) returns TicketCommentsResponse|error { + string resourcePath = string `/v2/requests/${getEncodedUri(requestId)}/comments`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Getting Comments # - # + request_id - The ID of the request - # + ticket_comment_id - The ID of the ticket comment - # + return - Success response - resource isolated function get api/v2/requests/[int request_id]/comments/[int ticket_comment_id](string accept = "application/json") returns TicketCommentResponse|error { - string resourcePath = string `/api/v2/requests/${getEncodedUri(request_id)}/comments/${getEncodedUri(ticket_comment_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketCommentResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + requestId - The ID of the request + # + ticketCommentId - The ID of the ticket comment + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/requests/[int requestId]/comments/[int ticketCommentId](ShowCommentHeaders headers = {}) returns TicketCommentResponse|error { + string resourcePath = string `/v2/requests/${getEncodedUri(requestId)}/comments/${getEncodedUri(ticketCommentId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Search Requests # - # + query - The syntax and matching logic for the string is detailed in the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226). See also [Query basics](/api-reference/ticketing/ticket-management/search/#query-basics) in the Tickets API doc. - # + return - Success response - resource isolated function get api/v2/requests/search(string accept = "application/json", string? query = ()) returns RequestsResponse|error { - string resourcePath = string `/api/v2/requests/search`; - map queryParam = {"query": query}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - RequestsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/requests/search(SearchRequestsHeaders headers = {}, *SearchRequestsQueries queries) returns RequestsResponse|error { + string resourcePath = string `/v2/requests/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Resource Collections # - # + return - Success response - resource isolated function get api/v2/resource_collections() returns ResourceCollectionsResponse|error { - string resourcePath = string `/api/v2/resource_collections`; - ResourceCollectionsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/resource_collections(map headers = {}) returns ResourceCollectionsResponse|error { + string resourcePath = string `/v2/resource_collections`; + return self.clientEp->get(resourcePath, headers); } + # Create Resource Collection # - # + return - Success response - resource isolated function post api/v2/resource_collections() returns JobStatusResponse|error { - string resourcePath = string `/api/v2/resource_collections`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/resource_collections(map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/resource_collections`; http:Request request = new; - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Resource Collection # - # + resource_collection_id - The id of the resource collection - # + return - Success response - resource isolated function get api/v2/resource_collections/[int resource_collection_id](string accept = "application/json") returns ResourceCollectionResponse|error { - string resourcePath = string `/api/v2/resource_collections/${getEncodedUri(resource_collection_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ResourceCollectionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + resourceCollectionId - The id of the resource collection + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/resource_collections/[int resourceCollectionId](RetrieveResourceCollectionHeaders headers = {}) returns ResourceCollectionResponse|error { + string resourcePath = string `/v2/resource_collections/${getEncodedUri(resourceCollectionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Resource Collection # - # + resource_collection_id - The id of the resource collection - # + return - Success response - resource isolated function put api/v2/resource_collections/[int resource_collection_id](string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/resource_collections/${getEncodedUri(resource_collection_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + resourceCollectionId - The id of the resource collection + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/resource_collections/[int resourceCollectionId](UpdateResourceCollectionHeaders headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/resource_collections/${getEncodedUri(resourceCollectionId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - JobStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Resource Collection # - # + resource_collection_id - The id of the resource collection - # + return - Success response - resource isolated function delete api/v2/resource_collections/[int resource_collection_id](string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/resource_collections/${getEncodedUri(resource_collection_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + resourceCollectionId - The id of the resource collection + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function delete v2/resource_collections/[int resourceCollectionId](DeleteResourceCollectionHeaders headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/resource_collections/${getEncodedUri(resourceCollectionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Agent Attribute Values # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/routing/agents/[int user_id]/instance_values(string accept = "application/json") returns SkillBasedRoutingAttributeValuesResponse|error { - string resourcePath = string `/api/v2/routing/agents/${getEncodedUri(user_id)}/instance_values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingAttributeValuesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/agents/[int userId]/instance_values(ListAGentAttributeValuesHeaders headers = {}) returns SkillBasedRoutingAttributeValuesResponse|error { + string resourcePath = string `/v2/routing/agents/${getEncodedUri(userId)}/instance_values`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Set Agent Attribute Values # - # + user_id - The id of the user - # + return - Success response - resource isolated function post api/v2/routing/agents/[int user_id]/instance_values(string accept = "application/json") returns SkillBasedRoutingAttributeValuesResponse|error { - string resourcePath = string `/api/v2/routing/agents/${getEncodedUri(user_id)}/instance_values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/routing/agents/[int userId]/instance_values(SetAgentAttributeValuesHeaders headers = {}) returns SkillBasedRoutingAttributeValuesResponse|error { + string resourcePath = string `/v2/routing/agents/${getEncodedUri(userId)}/instance_values`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SkillBasedRoutingAttributeValuesResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # List Account Attributes # - # + return - Success response - resource isolated function get api/v2/routing/attributes() returns SkillBasedRoutingAttributesResponse|error { - string resourcePath = string `/api/v2/routing/attributes`; - SkillBasedRoutingAttributesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/attributes(map headers = {}) returns SkillBasedRoutingAttributesResponse|error { + string resourcePath = string `/v2/routing/attributes`; + return self.clientEp->get(resourcePath, headers); } + # Create Attribute # - # + return - Created response - resource isolated function post api/v2/routing/attributes() returns SkillBasedRoutingAttributeResponse|error { - string resourcePath = string `/api/v2/routing/attributes`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/routing/attributes(map headers = {}) returns SkillBasedRoutingAttributeResponse|error { + string resourcePath = string `/v2/routing/attributes`; http:Request request = new; - SkillBasedRoutingAttributeResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Attribute # - # + attribute_id - The ID of the skill-based routing attribute - # + return - Success response - resource isolated function get api/v2/routing/attributes/[string attribute_id](string accept = "application/json") returns SkillBasedRoutingAttributeResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingAttributeResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + attributeId - The ID of the skill-based routing attribute + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/attributes/[string attributeId](ShowAttributeHeaders headers = {}) returns SkillBasedRoutingAttributeResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Attribute # - # + attribute_id - The ID of the skill-based routing attribute - # + return - Success response - resource isolated function put api/v2/routing/attributes/[string attribute_id](string accept = "application/json") returns SkillBasedRoutingAttributeResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attributeId - The ID of the skill-based routing attribute + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/routing/attributes/[string attributeId](UpdateAttributeHeaders headers = {}) returns SkillBasedRoutingAttributeResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SkillBasedRoutingAttributeResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Attribute # - # + attribute_id - The ID of the skill-based routing attribute - # + return - No Content response - resource isolated function delete api/v2/routing/attributes/[string attribute_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attributeId - The ID of the skill-based routing attribute + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/routing/attributes/[string attributeId](DeleteAttributeHeaders headers = {}) returns error? { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Attribute Values for an Attribute # - # + attribute_id - The ID of the skill-based routing attribute - # + return - Success response - resource isolated function get api/v2/routing/attributes/[string attribute_id]/values(string accept = "application/json") returns SkillBasedRoutingAttributeValuesResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}/values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingAttributeValuesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + attributeId - The ID of the skill-based routing attribute + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/attributes/[string attributeId]/values(ListAttributeValuesHeaders headers = {}) returns SkillBasedRoutingAttributeValuesResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}/values`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Attribute Value # - # + attribute_id - The ID of the skill-based routing attribute - # + return - Created response - resource isolated function post api/v2/routing/attributes/[string attribute_id]/values(string accept = "application/json") returns SkillBasedRoutingAttributeValueResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}/values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attributeId - The ID of the skill-based routing attribute + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/routing/attributes/[string attributeId]/values(CreateAttributeValueHeaders headers = {}) returns SkillBasedRoutingAttributeValueResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}/values`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SkillBasedRoutingAttributeValueResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Attribute Value # - # + attribute_id - The ID of the skill-based routing attribute - # + attribute_value_id - The ID of the skill-based routing attribute value - # + return - Success response - resource isolated function get api/v2/routing/attributes/[string attribute_id]/values/[string attribute_value_id](string accept = "application/json") returns SkillBasedRoutingAttributeValueResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}/values/${getEncodedUri(attribute_value_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingAttributeValueResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + attributeId - The ID of the skill-based routing attribute + # + attributeValueId - The ID of the skill-based routing attribute value + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/attributes/[string attributeId]/values/[string attributeValueId](ShowAttributeValueHeaders headers = {}) returns SkillBasedRoutingAttributeValueResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}/values/${getEncodedUri(attributeValueId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Attribute Value # - # + attribute_id - The ID of the skill-based routing attribute - # + attribute_value_id - The ID of the skill-based routing attribute value - # + return - No Content response - resource isolated function delete api/v2/routing/attributes/[string attribute_id]/values/[string attribute_value_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}/values/${getEncodedUri(attribute_value_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attributeId - The ID of the skill-based routing attribute + # + attributeValueId - The ID of the skill-based routing attribute value + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/routing/attributes/[string attributeId]/values/[string attributeValueId](DeleteAttributeValueHeaders headers = {}) returns error? { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}/values/${getEncodedUri(attributeValueId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Update Attribute Value # - # + attribute_id - The ID of the skill-based routing attribute - # + attribute_value_id - The ID of the skill-based routing attribute value - # + return - Success response - resource isolated function patch api/v2/routing/attributes/[string attribute_id]/values/[string attribute_value_id](string accept = "application/json") returns SkillBasedRoutingAttributeValueResponse|error { - string resourcePath = string `/api/v2/routing/attributes/${getEncodedUri(attribute_id)}/values/${getEncodedUri(attribute_value_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + attributeId - The ID of the skill-based routing attribute + # + attributeValueId - The ID of the skill-based routing attribute value + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function patch v2/routing/attributes/[string attributeId]/values/[string attributeValueId](UpdateAttributeValueHeaders headers = {}) returns SkillBasedRoutingAttributeValueResponse|error { + string resourcePath = string `/v2/routing/attributes/${getEncodedUri(attributeId)}/values/${getEncodedUri(attributeValueId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SkillBasedRoutingAttributeValueResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # List Routing Attribute Definitions # - # + return - Success response - resource isolated function get api/v2/routing/attributes/definitions() returns SkillBasedRoutingAttributeDefinitions|error { - string resourcePath = string `/api/v2/routing/attributes/definitions`; - SkillBasedRoutingAttributeDefinitions response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/attributes/definitions(map headers = {}) returns SkillBasedRoutingAttributeDefinitions|error { + string resourcePath = string `/v2/routing/attributes/definitions`; + return self.clientEp->get(resourcePath, headers); } + # List Tickets Fulfilled by a User # - # + ticket_ids - The IDs of the relevant tickets to check for matching attributes - # + return - Success response - resource isolated function get api/v2/routing/requirements/fulfilled(int ticket_ids, string accept = "application/json") returns SkillBasedRoutingTicketFulfilledResponse|error { - string resourcePath = string `/api/v2/routing/requirements/fulfilled`; - map queryParam = {"ticket_ids": ticket_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingTicketFulfilledResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/routing/requirements/fulfilled(ListTicketsFullfilledByUserHeaders headers = {}, *ListTicketsFullfilledByUserQueries queries) returns SkillBasedRoutingTicketFulfilledResponse|error { + string resourcePath = string `/v2/routing/requirements/fulfilled`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Ticket Attribute Values # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function get api/v2/routing/tickets/[int ticket_id]/instance_values(string accept = "application/json") returns SkillBasedRoutingAttributeValuesResponse|error { - string resourcePath = string `/api/v2/routing/tickets/${getEncodedUri(ticket_id)}/instance_values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SkillBasedRoutingAttributeValuesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/routing/tickets/[int ticketId]/instance_values(ListTicketAttributeValuesHeaders headers = {}) returns SkillBasedRoutingAttributeValuesResponse|error { + string resourcePath = string `/v2/routing/tickets/${getEncodedUri(ticketId)}/instance_values`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Set Ticket Attribute Values # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function post api/v2/routing/tickets/[int ticket_id]/instance_values(string accept = "application/json") returns SkillBasedRoutingAttributeValuesResponse|error { - string resourcePath = string `/api/v2/routing/tickets/${getEncodedUri(ticket_id)}/instance_values`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/routing/tickets/[int ticketId]/instance_values(SetTicketAttributeValuesHeaders headers = {}) returns SkillBasedRoutingAttributeValuesResponse|error { + string resourcePath = string `/v2/routing/tickets/${getEncodedUri(ticketId)}/instance_values`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SkillBasedRoutingAttributeValuesResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # List Satisfaction Ratings # - # + return - Success response - resource isolated function get api/v2/satisfaction_ratings(string accept = "application/json") returns SatisfactionRatingsResponse|error { - string resourcePath = string `/api/v2/satisfaction_ratings`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SatisfactionRatingsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/satisfaction_ratings(ListSatisfactionRatingsHeaders headers = {}) returns SatisfactionRatingsResponse|error { + string resourcePath = string `/v2/satisfaction_ratings`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Satisfaction Rating # - # + satisfaction_rating_id - The id of the satisfaction rating to retrieve - # + return - Success response - resource isolated function get api/v2/satisfaction_ratings/[int satisfaction_rating_id](string accept = "application/json") returns SatisfactionRatingResponse|error { - string resourcePath = string `/api/v2/satisfaction_ratings/${getEncodedUri(satisfaction_rating_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SatisfactionRatingResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + satisfactionRatingId - The id of the satisfaction rating to retrieve + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/satisfaction_ratings/[int satisfactionRatingId](ShowSatisfactionRatingHeaders headers = {}) returns SatisfactionRatingResponse|error { + string resourcePath = string `/v2/satisfaction_ratings/${getEncodedUri(satisfactionRatingId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Count Satisfaction Ratings # - # + return - Count of satisfaction ratings - resource isolated function get api/v2/satisfaction_ratings/count() returns SatisfactionRatingsCountResponse|error { - string resourcePath = string `/api/v2/satisfaction_ratings/count`; - SatisfactionRatingsCountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Count of satisfaction ratings + resource isolated function get v2/satisfaction_ratings/count(map headers = {}) returns SatisfactionRatingsCountResponse|error { + string resourcePath = string `/v2/satisfaction_ratings/count`; + return self.clientEp->get(resourcePath, headers); } + # List Reasons for Satisfaction Rating # - # + return - Success response - resource isolated function get api/v2/satisfaction_reasons() returns SatisfactionReasonsResponse|error { - string resourcePath = string `/api/v2/satisfaction_reasons`; - SatisfactionReasonsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/satisfaction_reasons(map headers = {}) returns SatisfactionReasonsResponse|error { + string resourcePath = string `/v2/satisfaction_reasons`; + return self.clientEp->get(resourcePath, headers); } + # Show Reason for Satisfaction Rating # - # + satisfaction_reason_id - The id of the satisfaction rating reason - # + return - Success response - resource isolated function get api/v2/satisfaction_reasons/[int satisfaction_reason_id](string accept = "application/json") returns SatisfactionReasonResponse|error { - string resourcePath = string `/api/v2/satisfaction_reasons/${getEncodedUri(satisfaction_reason_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SatisfactionReasonResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + satisfactionReasonId - The id of the satisfaction rating reason + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/satisfaction_reasons/[int satisfactionReasonId](ShowSatisfactionRatingsHeaders headers = {}) returns SatisfactionReasonResponse|error { + string resourcePath = string `/v2/satisfaction_reasons/${getEncodedUri(satisfactionReasonId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Search Results # - # + query - The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) - # + sort_by - One of `updated_at`, `created_at`, `priority`, `status`, or `ticket_type`. Defaults to sorting by relevance - # + sort_order - One of `asc` or `desc`. Defaults to `desc` - # + return - Success response - resource isolated function get api/v2/search(string query, string accept = "application/json", string? sort_by = (), string? sort_order = ()) returns SearchResponse|error { - string resourcePath = string `/api/v2/search`; - map queryParam = {"query": query, "sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SearchResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/search(ListSearchResultsHeaders headers = {}, *ListSearchResultsQueries queries) returns SearchResponse|error { + string resourcePath = string `/v2/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Results Count # - # + query - The search query - # + return - Success response - resource isolated function get api/v2/search/count(string query, string accept = "application/json") returns SearchCountResponse|error { - string resourcePath = string `/api/v2/search/count`; - map queryParam = {"query": query}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SearchCountResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/search/count(CountSearchResultsHeaders headers = {}, *CountSearchResultsQueries queries) returns SearchCountResponse|error { + string resourcePath = string `/v2/search/count`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Export Search Results # - # + query - The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) - # + pageSize - The number of results shown in a page. - # + filterType - The object type returned by the export query. Can be `ticket`, `organization`, `user`, or `group`. - # + return - Success response - resource isolated function get api/v2/search/export(string query, string accept = "application/json", int? pageSize = (), string? filterType = ()) returns SearchExportResponse|error { - string resourcePath = string `/api/v2/search/export`; - map queryParam = {"query": query, "page[size]": pageSize, "filter[type]": filterType}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SearchExportResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/search/export(ExportSearchResultsHeaders headers = {}, *ExportSearchResultsQueries queries) returns SearchExportResponse|error { + string resourcePath = string `/v2/search/export`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Sessions # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/sessions(string accept = "application/json") returns SessionsResponse|error { - string resourcePath = string `/api/v2/sessions`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SessionsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/sessions(ListSessionsHeaders headers = {}) returns SessionsResponse|error { + string resourcePath = string `/v2/sessions`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Sharing Agreements # - # + return - Success response - resource isolated function get api/v2/sharing_agreements() returns SharingAgreementsResponse|error { - string resourcePath = string `/api/v2/sharing_agreements`; - SharingAgreementsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/sharing_agreements(map headers = {}) returns SharingAgreementsResponse|error { + string resourcePath = string `/v2/sharing_agreements`; + return self.clientEp->get(resourcePath, headers); } + # Create Sharing Agreement # - # + return - Created response - resource isolated function post api/v2/sharing_agreements() returns SharingAgreementResponse|error { - string resourcePath = string `/api/v2/sharing_agreements`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/sharing_agreements(map headers = {}) returns SharingAgreementResponse|error { + string resourcePath = string `/v2/sharing_agreements`; http:Request request = new; - SharingAgreementResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show a Sharing Agreement # - # + sharing_agreement_id - The ID of the sharing agreement - # + return - Success response - resource isolated function get api/v2/sharing_agreements/[int sharing_agreement_id](string accept = "application/json") returns SharingAgreementResponse|error { - string resourcePath = string `/api/v2/sharing_agreements/${getEncodedUri(sharing_agreement_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SharingAgreementResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + sharingAgreementId - The ID of the sharing agreement + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/sharing_agreements/[int sharingAgreementId](ShowSharingAgreementHeaders headers = {}) returns SharingAgreementResponse|error { + string resourcePath = string `/v2/sharing_agreements/${getEncodedUri(sharingAgreementId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update a Sharing Agreement # - # + sharing_agreement_id - The ID of the sharing agreement - # + return - Success response - resource isolated function put api/v2/sharing_agreements/[int sharing_agreement_id](string accept = "application/json") returns SharingAgreementResponse|error { - string resourcePath = string `/api/v2/sharing_agreements/${getEncodedUri(sharing_agreement_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + sharingAgreementId - The ID of the sharing agreement + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/sharing_agreements/[int sharingAgreementId](UpdateSharingAgreementHeaders headers = {}) returns SharingAgreementResponse|error { + string resourcePath = string `/v2/sharing_agreements/${getEncodedUri(sharingAgreementId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SharingAgreementResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete a Sharing Agreement # - # + sharing_agreement_id - The ID of the sharing agreement - # + return - No Content response - resource isolated function delete api/v2/sharing_agreements/[int sharing_agreement_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/sharing_agreements/${getEncodedUri(sharing_agreement_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + sharingAgreementId - The ID of the sharing agreement + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/sharing_agreements/[int sharingAgreementId](DeleteSharingAgreementHeaders headers = {}) returns error? { + string resourcePath = string `/v2/sharing_agreements/${getEncodedUri(sharingAgreementId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Record a New Skip for the Current User # - # + return - Success response - resource isolated function post api/v2/skips() returns TicketSkipCreation|error { - string resourcePath = string `/api/v2/skips`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/skips(map headers = {}) returns TicketSkipCreation|error { + string resourcePath = string `/v2/skips`; http:Request request = new; - TicketSkipCreation response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # List SLA Policies # - # + return - Success response - resource isolated function get api/v2/slas/policies() returns SLAPoliciesResponse|error { - string resourcePath = string `/api/v2/slas/policies`; - SLAPoliciesResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/slas/policies(map headers = {}) returns SLAPoliciesResponse|error { + string resourcePath = string `/v2/slas/policies`; + return self.clientEp->get(resourcePath, headers); } + # Create SLA Policy # - # + return - Created response - resource isolated function post api/v2/slas/policies() returns SLAPolicyResponse|error { - string resourcePath = string `/api/v2/slas/policies`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/slas/policies(map headers = {}) returns SLAPolicyResponse|error { + string resourcePath = string `/v2/slas/policies`; http:Request request = new; - SLAPolicyResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show SLA Policy # - # + sla_policy_id - The ID of the SLA Policy - # + return - Success response - resource isolated function get api/v2/slas/policies/[int sla_policy_id](string accept = "application/json") returns SLAPolicyResponse|error { - string resourcePath = string `/api/v2/slas/policies/${getEncodedUri(sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SLAPolicyResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + slaPolicyId - The ID of the SLA Policy + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/slas/policies/[int slaPolicyId](ShowSLAPolicyHeaders headers = {}) returns SLAPolicyResponse|error { + string resourcePath = string `/v2/slas/policies/${getEncodedUri(slaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update SLA Policy # - # + sla_policy_id - The ID of the SLA Policy - # + return - Success response - resource isolated function put api/v2/slas/policies/[int sla_policy_id](string accept = "application/json") returns SLAPolicyResponse|error { - string resourcePath = string `/api/v2/slas/policies/${getEncodedUri(sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + slaPolicyId - The ID of the SLA Policy + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/slas/policies/[int slaPolicyId](UpdateSLAPolicyHeaders headers = {}) returns SLAPolicyResponse|error { + string resourcePath = string `/v2/slas/policies/${getEncodedUri(slaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SLAPolicyResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete SLA Policy # - # + sla_policy_id - The ID of the SLA Policy - # + return - No Content response - resource isolated function delete api/v2/slas/policies/[int sla_policy_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/slas/policies/${getEncodedUri(sla_policy_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + slaPolicyId - The ID of the SLA Policy + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/slas/policies/[int slaPolicyId](DeleteSLAPolicyHeaders headers = {}) returns error? { + string resourcePath = string `/v2/slas/policies/${getEncodedUri(slaPolicyId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Retrieve Supported Filter Definition Items # - # + return - Success response - resource isolated function get api/v2/slas/policies/definitions() returns SLAPolicyFilterDefinitionResponse|error { - string resourcePath = string `/api/v2/slas/policies/definitions`; - SLAPolicyFilterDefinitionResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/slas/policies/definitions(map headers = {}) returns SLAPolicyFilterDefinitionResponse|error { + string resourcePath = string `/v2/slas/policies/definitions`; + return self.clientEp->get(resourcePath, headers); } + # Reorder SLA Policies # - # + sla_policy_ids - The IDs of the SLA Policies to reorder - # + return - Success response - resource isolated function put api/v2/slas/policies/reorder(string accept = "application/json", int[]? sla_policy_ids = ()) returns string|error { - string resourcePath = string `/api/v2/slas/policies/reorder`; - map queryParam = {"sla_policy_ids": sla_policy_ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function put v2/slas/policies/reorder(ReorderSLAPoliciesHeaders headers = {}, *ReorderSLAPoliciesQueries queries) returns string|error { + string resourcePath = string `/v2/slas/policies/reorder`; map queryParamEncoding = {"sla_policy_ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Suspended Tickets # - # + sort_by - The field to sort the ticket by, being one of `author_email`, `cause`, `created_at`, or `subject`. - # + sort_order - The order in which to sort the suspended tickets. This can take value `asc` or `desc`. - # + return - Success response - resource isolated function get api/v2/suspended_tickets(string accept = "application/json", string? sort_by = (), string? sort_order = ()) returns SuspendedTicketsResponse|error { - string resourcePath = string `/api/v2/suspended_tickets`; - map queryParam = {"sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SuspendedTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/suspended_tickets(ListSuspendedTicketsHeaders headers = {}, *ListSuspendedTicketsQueries queries) returns SuspendedTicketsResponse|error { + string resourcePath = string `/v2/suspended_tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Suspended Ticket # # + id - id of the suspended ticket - # + return - Success response - resource isolated function get api/v2/suspended_tickets/[decimal id](string accept = "application/json") returns SuspendedTicketsResponse|error { - string resourcePath = string `/api/v2/suspended_tickets/${getEncodedUri(id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SuspendedTicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/suspended_tickets/[decimal id](ShowSuspendedTicketsHeaders headers = {}) returns SuspendedTicketsResponse|error { + string resourcePath = string `/v2/suspended_tickets/${getEncodedUri(id)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Suspended Ticket # # + id - id of the suspended ticket - # + return - No Content response - resource isolated function delete api/v2/suspended_tickets/[decimal id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/suspended_tickets/${getEncodedUri(id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/suspended_tickets/[decimal id](DeleteSuspendedTicketHeaders headers = {}) returns error? { + string resourcePath = string `/v2/suspended_tickets/${getEncodedUri(id)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Recover Suspended Ticket # # + id - id of the suspended ticket - # + return - Success response - resource isolated function put api/v2/suspended_tickets/[decimal id]/recover(string accept = "application/json") returns RecoverSuspendedTicketResponse|error { - string resourcePath = string `/api/v2/suspended_tickets/${getEncodedUri(id)}/recover`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/suspended_tickets/[decimal id]/recover(RecoverSuspendedTicketHeaders headers = {}) returns RecoverSuspendedTicketResponse|error { + string resourcePath = string `/v2/suspended_tickets/${getEncodedUri(id)}/recover`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - RecoverSuspendedTicketResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Suspended Ticket Attachments # # + id - id of the suspended ticket - # + return - Success response - resource isolated function post api/v2/suspended_tickets/attachments(string accept = "application/json") returns SuspendedTicketsAttachmentsResponse|error { - string resourcePath = string `/api/v2/suspended_tickets/attachments`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/suspended_tickets/attachments(SuspendedTicketsAttachmentsHeaders headers = {}) returns SuspendedTicketsAttachmentsResponse|error { + string resourcePath = string `/v2/suspended_tickets/attachments`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SuspendedTicketsAttachmentsResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Delete Multiple Suspended Tickets # - # + ids - A comma separated list of ids of suspended tickets to delete. - # + return - No Content response - resource isolated function delete api/v2/suspended_tickets/destroy_many(string ids, string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/suspended_tickets/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No Content response + resource isolated function delete v2/suspended_tickets/destroy_many(DeleteSuspendedTicketsHeaders headers = {}, *DeleteSuspendedTicketsQueries queries) returns error? { + string resourcePath = string `/v2/suspended_tickets/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Export Suspended Tickets # - # + return - Ok - resource isolated function post api/v2/suspended_tickets/export() returns SuspendedTicketsExportResponse|error { - string resourcePath = string `/api/v2/suspended_tickets/export`; + # + headers - Headers to be sent with the request + # + return - Ok + resource isolated function post v2/suspended_tickets/export(map headers = {}) returns SuspendedTicketsExportResponse|error { + string resourcePath = string `/v2/suspended_tickets/export`; http:Request request = new; - SuspendedTicketsExportResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Recover Multiple Suspended Tickets # - # + ids - A comma separated list of ids of suspended tickets to recover. - # + return - Success response - resource isolated function put api/v2/suspended_tickets/recover_many(string ids, string accept = "application/json") returns RecoverSuspendedTicketsResponse|error { - string resourcePath = string `/api/v2/suspended_tickets/recover_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function put v2/suspended_tickets/recover_many(RecoverSuspendedTicketsHeaders headers = {}, *RecoverSuspendedTicketsQueries queries) returns RecoverSuspendedTicketsResponse|error { + string resourcePath = string `/v2/suspended_tickets/recover_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - RecoverSuspendedTicketsResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Tags # - # + return - Success response - resource isolated function get api/v2/tags() returns TagsResponse|error { - string resourcePath = string `/api/v2/tags`; - TagsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/tags(map headers = {}) returns TagsResponse|error { + string resourcePath = string `/v2/tags`; + return self.clientEp->get(resourcePath, headers); } + # Count Tags # - # + return - Success response - resource isolated function get api/v2/tags/count() returns TagCountResponse|error { - string resourcePath = string `/api/v2/tags/count`; - TagCountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/tags/count(map headers = {}) returns TagCountResponse|error { + string resourcePath = string `/v2/tags/count`; + return self.clientEp->get(resourcePath, headers); } + # List Target Failures # - # + return - Success response - resource isolated function get api/v2/target_failures() returns TargetFailuresResponse|error { - string resourcePath = string `/api/v2/target_failures`; - TargetFailuresResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/target_failures(map headers = {}) returns TargetFailuresResponse|error { + string resourcePath = string `/v2/target_failures`; + return self.clientEp->get(resourcePath, headers); } + # Show Target Failure # - # + target_failure_id - The ID of the target failure - # + return - Success response - resource isolated function get api/v2/target_failures/[int target_failure_id](string accept = "application/json") returns TargetFailureResponse|error { - string resourcePath = string `/api/v2/target_failures/${getEncodedUri(target_failure_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TargetFailureResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + targetFailureId - The ID of the target failure + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/target_failures/[int targetFailureId](ShowTargetFailureHeaders headers = {}) returns TargetFailureResponse|error { + string resourcePath = string `/v2/target_failures/${getEncodedUri(targetFailureId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Targets # - # + return - Success response - resource isolated function get api/v2/targets() returns TargetsResponse|error { - string resourcePath = string `/api/v2/targets`; - TargetsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/targets(map headers = {}) returns TargetsResponse|error { + string resourcePath = string `/v2/targets`; + return self.clientEp->get(resourcePath, headers); } + # Create Target # - # + return - Created response - resource isolated function post api/v2/targets() returns TargetResponse|error { - string resourcePath = string `/api/v2/targets`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/targets(map headers = {}) returns TargetResponse|error { + string resourcePath = string `/v2/targets`; http:Request request = new; - TargetResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Target # - # + target_id - The ID of the target - # + return - Success response - resource isolated function get api/v2/targets/[int target_id](string accept = "application/json") returns TargetResponse|error { - string resourcePath = string `/api/v2/targets/${getEncodedUri(target_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TargetResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + targetId - The ID of the target + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/targets/[int targetId](ShowTargetHeaders headers = {}) returns TargetResponse|error { + string resourcePath = string `/v2/targets/${getEncodedUri(targetId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Target # - # + target_id - The ID of the target - # + return - Success response - resource isolated function put api/v2/targets/[int target_id](string accept = "application/json") returns TargetResponse|error { - string resourcePath = string `/api/v2/targets/${getEncodedUri(target_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + targetId - The ID of the target + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/targets/[int targetId](UpdateTargetHeaders headers = {}) returns TargetResponse|error { + string resourcePath = string `/v2/targets/${getEncodedUri(targetId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TargetResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Target # - # + target_id - The ID of the target - # + return - No Content response - resource isolated function delete api/v2/targets/[int target_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/targets/${getEncodedUri(target_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + targetId - The ID of the target + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/targets/[int targetId](DeleteTargetHeaders headers = {}) returns error? { + string resourcePath = string `/v2/targets/${getEncodedUri(targetId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List All Ticket Audits # - # + 'limit - Maximum number of results returned - # + return - Success response - resource isolated function get api/v2/ticket_audits(string accept = "application/json", int? 'limit = ()) returns TicketAuditsResponse|error { - string resourcePath = string `/api/v2/ticket_audits`; - map queryParam = {"limit": 'limit}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketAuditsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_audits(ListTicketAuditsHeaders headers = {}, *ListTicketAuditsQueries queries) returns TicketAuditsResponse|error { + string resourcePath = string `/v2/ticket_audits`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Ticket Fields # - # + locale - Forces the `title_in_portal` property to return a dynamic content variant for the specified locale. - # Only accepts [active locale ids](/api-reference/ticketing/account-configuration/locales/#list-locales). - # Example: `locale="de"`. - # + creator - Displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created - # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field - # is not created by an app, `creator_app_name` is null - # + return - Success response - resource isolated function get api/v2/ticket_fields(string accept = "application/json", string? locale = (), boolean? creator = ()) returns TicketFieldsResponse|error { - string resourcePath = string `/api/v2/ticket_fields`; - map queryParam = {"locale": locale, "creator": creator}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketFieldsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_fields(ListTicketFieldsHeaders headers = {}, *ListTicketFieldsQueries queries) returns TicketFieldsResponse|error { + string resourcePath = string `/v2/ticket_fields`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Ticket Field # - # + return - Created response - resource isolated function post api/v2/ticket_fields() returns TicketFieldResponse|error { - string resourcePath = string `/api/v2/ticket_fields`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/ticket_fields(map headers = {}) returns TicketFieldResponse|error { + string resourcePath = string `/v2/ticket_fields`; http:Request request = new; - TicketFieldResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Ticket Field # - # + ticket_field_id - The ID of the ticket field - # + creator - If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created - # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field - # is not created by an app, then `creator_app_name` is null - # + return - Success response - resource isolated function get api/v2/ticket_fields/[int ticket_field_id](string accept = "application/json", boolean? creator = ()) returns TicketFieldResponse|error { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}`; - map queryParam = {"creator": creator}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketFieldResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketFieldId - The ID of the ticket field + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_fields/[int ticketFieldId](ShowTicketfieldHeaders headers = {}, *ShowTicketfieldQueries queries) returns TicketFieldResponse|error { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Ticket Field # - # + ticket_field_id - The ID of the ticket field - # + creator - If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created - # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field - # is not created by an app, then `creator_app_name` is null - # + return - Success response - resource isolated function put api/v2/ticket_fields/[int ticket_field_id](string accept = "application/json", boolean? creator = ()) returns TicketFieldResponse|error { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}`; - map queryParam = {"creator": creator}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - http:Request request = new; - TicketFieldResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + # + ticketFieldId - The ID of the ticket field + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function put v2/ticket_fields/[int ticketFieldId](UpdateTicketFieldHeaders headers = {}, *UpdateTicketFieldQueries queries) returns TicketFieldResponse|error { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + http:Request request = new; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Ticket Field # - # + ticket_field_id - The ID of the ticket field - # + creator - If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created - # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field - # is not created by an app, then `creator_app_name` is null - # + return - No Content response - resource isolated function delete api/v2/ticket_fields/[int ticket_field_id](string accept = "application/json", boolean? creator = ()) returns error? { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}`; - map queryParam = {"creator": creator}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFieldId - The ID of the ticket field + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No Content response + resource isolated function delete v2/ticket_fields/[int ticketFieldId](DeleteTicketFieldHeaders headers = {}, *DeleteTicketFieldQueries queries) returns error? { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Ticket Field Options # - # + ticket_field_id - The ID of the ticket field - # + return - Success response - resource isolated function get api/v2/ticket_fields/[int ticket_field_id]/options(string accept = "application/json") returns CustomFieldOptionsResponse|error { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}/options`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomFieldOptionsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketFieldId - The ID of the ticket field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_fields/[int ticketFieldId]/options(ListTicketFieldOptionsHeaders headers = {}) returns CustomFieldOptionsResponse|error { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}/options`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create or Update Ticket Field Option # - # + ticket_field_id - The ID of the ticket field - # + return - Success response - resource isolated function post api/v2/ticket_fields/[int ticket_field_id]/options(string accept = "application/json") returns CustomFieldOptionResponse|error { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}/options`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFieldId - The ID of the ticket field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/ticket_fields/[int ticketFieldId]/options(CreateOrUpdateTicketFieldOptionHeaders headers = {}) returns CustomFieldOptionResponse|error { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}/options`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomFieldOptionResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Ticket Field Option # - # + ticket_field_id - The ID of the ticket field - # + ticket_field_option_id - The ID of the ticket field option - # + return - Success response - resource isolated function get api/v2/ticket_fields/[int ticket_field_id]/options/[int ticket_field_option_id](string accept = "application/json") returns CustomFieldOptionResponse|error { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}/options/${getEncodedUri(ticket_field_option_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomFieldOptionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketFieldId - The ID of the ticket field + # + ticketFieldOptionId - The ID of the ticket field option + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_fields/[int ticketFieldId]/options/[int ticketFieldOptionId](ShowTicketFieldOptionHeaders headers = {}) returns CustomFieldOptionResponse|error { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}/options/${getEncodedUri(ticketFieldOptionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Ticket Field Option # - # + ticket_field_id - The ID of the ticket field - # + ticket_field_option_id - The ID of the ticket field option - # + return - No Content response - resource isolated function delete api/v2/ticket_fields/[int ticket_field_id]/options/[int ticket_field_option_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/ticket_fields/${getEncodedUri(ticket_field_id)}/options/${getEncodedUri(ticket_field_option_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFieldId - The ID of the ticket field + # + ticketFieldOptionId - The ID of the ticket field option + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/ticket_fields/[int ticketFieldId]/options/[int ticketFieldOptionId](DeleteTicketFieldOptionHeaders headers = {}) returns error? { + string resourcePath = string `/v2/ticket_fields/${getEncodedUri(ticketFieldId)}/options/${getEncodedUri(ticketFieldOptionId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Count Ticket Fields # - # + return - Count of ticket fields - resource isolated function get api/v2/ticket_fields/count() returns TicketFieldCountResponse|error { - string resourcePath = string `/api/v2/ticket_fields/count`; - TicketFieldCountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Count of ticket fields + resource isolated function get v2/ticket_fields/count(map headers = {}) returns TicketFieldCountResponse|error { + string resourcePath = string `/v2/ticket_fields/count`; + return self.clientEp->get(resourcePath, headers); } + # List Ticket Forms # - # + active - true returns active ticket forms; false returns inactive ticket forms. If not present, returns both - # + end_user_visible - true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both - # + fallback_to_default - true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms - # + associated_to_brand - true returns the ticket forms of the brand specified by the url's subdomain - # + return - Success response - resource isolated function get api/v2/ticket_forms(string accept = "application/json", boolean? active = (), boolean? end_user_visible = (), boolean? fallback_to_default = (), boolean? associated_to_brand = ()) returns TicketFormsResponse|error { - string resourcePath = string `/api/v2/ticket_forms`; - map queryParam = {"active": active, "end_user_visible": end_user_visible, "fallback_to_default": fallback_to_default, "associated_to_brand": associated_to_brand}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketFormsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_forms(ListTicketFormsHeaders headers = {}, *ListTicketFormsQueries queries) returns TicketFormsResponse|error { + string resourcePath = string `/v2/ticket_forms`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Ticket Form # - # + return - Created response - resource isolated function post api/v2/ticket_forms() returns TicketFormResponse|error { - string resourcePath = string `/api/v2/ticket_forms`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/ticket_forms(map headers = {}) returns TicketFormResponse|error { + string resourcePath = string `/v2/ticket_forms`; http:Request request = new; - TicketFormResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Ticket Form # - # + ticket_form_id - The ID of the ticket form - # + return - Success response - resource isolated function get api/v2/ticket_forms/[int ticket_form_id](string accept = "application/json") returns TicketFormResponse|error { - string resourcePath = string `/api/v2/ticket_forms/${getEncodedUri(ticket_form_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketFormResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketFormId - The ID of the ticket form + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_forms/[int ticketFormId](ShowTicketFormHeaders headers = {}) returns TicketFormResponse|error { + string resourcePath = string `/v2/ticket_forms/${getEncodedUri(ticketFormId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Ticket Form # - # + ticket_form_id - The ID of the ticket form - # + return - Success response - resource isolated function put api/v2/ticket_forms/[int ticket_form_id](string accept = "application/json") returns TicketFormResponse|error { - string resourcePath = string `/api/v2/ticket_forms/${getEncodedUri(ticket_form_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFormId - The ID of the ticket form + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/ticket_forms/[int ticketFormId](UpdateTicketFormHeaders headers = {}) returns TicketFormResponse|error { + string resourcePath = string `/v2/ticket_forms/${getEncodedUri(ticketFormId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketFormResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Ticket Form # - # + ticket_form_id - The ID of the ticket form - # + return - No Content response - resource isolated function delete api/v2/ticket_forms/[int ticket_form_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/ticket_forms/${getEncodedUri(ticket_form_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFormId - The ID of the ticket form + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/ticket_forms/[int ticketFormId](DeleteTicketFormHeaders headers = {}) returns error? { + string resourcePath = string `/v2/ticket_forms/${getEncodedUri(ticketFormId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Clone an Already Existing Ticket Form # - # + ticket_form_id - The ID of the ticket form - # + return - Success response - resource isolated function post api/v2/ticket_forms/[int ticket_form_id]/clone(string accept = "application/json") returns TicketFormResponse|error { - string resourcePath = string `/api/v2/ticket_forms/${getEncodedUri(ticket_form_id)}/clone`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketFormId - The ID of the ticket form + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/ticket_forms/[int ticketFormId]/clone(CloneTicketFormHeaders headers = {}) returns TicketFormResponse|error { + string resourcePath = string `/v2/ticket_forms/${getEncodedUri(ticketFormId)}/clone`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketFormResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Reorder Ticket Forms # - # + return - Success response - resource isolated function put api/v2/ticket_forms/reorder() returns TicketFormsResponse|error { - string resourcePath = string `/api/v2/ticket_forms/reorder`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/ticket_forms/reorder(map headers = {}) returns TicketFormsResponse|error { + string resourcePath = string `/v2/ticket_forms/reorder`; http:Request request = new; - TicketFormsResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # Show Many Ticket Forms # - # + ids - IDs of the ticket forms to be shown - # + active - true returns active ticket forms; false returns inactive ticket forms. If not present, returns both - # + end_user_visible - true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both - # + fallback_to_default - true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms - # + associated_to_brand - true returns the ticket forms of the brand specified by the url's subdomain - # + return - Success response - resource isolated function get api/v2/ticket_forms/show_many(string ids, string accept = "application/json", boolean? active = (), boolean? end_user_visible = (), boolean? fallback_to_default = (), boolean? associated_to_brand = ()) returns TicketFormsResponse|error { - string resourcePath = string `/api/v2/ticket_forms/show_many`; - map queryParam = {"ids": ids, "active": active, "end_user_visible": end_user_visible, "fallback_to_default": fallback_to_default, "associated_to_brand": associated_to_brand}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketFormsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_forms/show_many(ShowManyTicketFormsHeaders headers = {}, *ShowManyTicketFormsQueries queries) returns TicketFormsResponse|error { + string resourcePath = string `/v2/ticket_forms/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Ticket Metrics # - # + return - Success response - resource isolated function get api/v2/ticket_metrics() returns TicketMetricsResponse|error { - string resourcePath = string `/api/v2/ticket_metrics`; - TicketMetricsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_metrics(map headers = {}) returns TicketMetricsResponse|error { + string resourcePath = string `/v2/ticket_metrics`; + return self.clientEp->get(resourcePath, headers); } + # Show Ticket Metrics # - # + ticket_metric_id - The id of the ticket metric to retrieve - # + return - Success response - resource isolated function get api/v2/ticket_metrics/[string ticket_metric_id](string accept = "application/json") returns TicketMetricsByTicketMetricIdResponse|error { - string resourcePath = string `/api/v2/ticket_metrics/${getEncodedUri(ticket_metric_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketMetricsByTicketMetricIdResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketMetricId - The id of the ticket metric to retrieve + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/ticket_metrics/[string ticketMetricId](ShowTicketMetricsHeaders headers = {}) returns TicketMetricsByTicketMetricIdResponse|error { + string resourcePath = string `/v2/ticket_metrics/${getEncodedUri(ticketMetricId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Tickets # - # + external_id - Lists tickets by external id. External ids don't have to be unique for each ticket. As a result, the request may return multiple tickets with the same external id. - # + return - List tickets - resource isolated function get api/v2/tickets(string accept = "application/json", string? external_id = ()) returns TicketsResponse|error { - string resourcePath = string `/api/v2/tickets`; - map queryParam = {"external_id": external_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - List tickets + resource isolated function get v2/tickets(ListTicketsHeaders headers = {}, *ListTicketsQueries queries) returns TicketsResponse|error { + string resourcePath = string `/v2/tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Ticket # - # + return - Create ticket - resource isolated function post api/v2/tickets(TicketCreateRequest payload) returns TicketResponse|error { - string resourcePath = string `/api/v2/tickets`; + # + headers - Headers to be sent with the request + # + return - Create ticket + resource isolated function post v2/tickets(TicketCreateRequest payload, map headers = {}) returns TicketResponse|error { + string resourcePath = string `/v2/tickets`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TicketResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Ticket # - # + ticket_id - The ID of the ticket - # + return - Ticket - resource isolated function get api/v2/tickets/[int ticket_id](string accept = "application/json") returns TicketResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Ticket + resource isolated function get v2/tickets/[int ticketId](ShowTicketHeaders headers = {}) returns TicketResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Ticket # - # + ticket_id - The ID of the ticket - # + return - Successful request - resource isolated function put api/v2/tickets/[int ticket_id](TicketUpdateRequest payload, string accept = "application/json") returns TicketUpdateResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful request + resource isolated function put v2/tickets/[int ticketId](TicketUpdateRequest payload, UpdateTicketHeaders headers = {}) returns TicketUpdateResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TicketUpdateResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Ticket # - # + ticket_id - The ID of the ticket - # + return - No content - resource isolated function delete api/v2/tickets/[int ticket_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - No content + resource isolated function delete v2/tickets/[int ticketId](DeleteTicketHeaders headers = {}) returns error? { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Audits for a Ticket # - # + ticket_id - The ID of the ticket - # + return - OK response - resource isolated function get api/v2/tickets/[int ticket_id]/audits(string accept = "application/json") returns TicketAuditsResponseNoneCursor|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/audits`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketAuditsResponseNoneCursor response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - OK response + resource isolated function get v2/tickets/[int ticketId]/audits(ListAuditsForTicketHeaders headers = {}) returns TicketAuditsResponseNoneCursor|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/audits`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Audit # - # + ticket_id - The ID of the ticket - # + ticket_audit_id - The ID of the ticket audit - # + return - OK response - resource isolated function get api/v2/tickets/[int ticket_id]/audits/[int ticket_audit_id](string accept = "application/json") returns TicketAuditResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/audits/${getEncodedUri(ticket_audit_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketAuditResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + ticketAuditId - The ID of the ticket audit + # + headers - Headers to be sent with the request + # + return - OK response + resource isolated function get v2/tickets/[int ticketId]/audits/[int ticketAuditId](ShowTicketAuditHeaders headers = {}) returns TicketAuditResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/audits/${getEncodedUri(ticketAuditId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Change a Comment From Public To Private # - # + ticket_id - The ID of the ticket - # + ticket_audit_id - The ID of the ticket audit - # + return - description - resource isolated function put api/v2/tickets/[int ticket_id]/audits/[int ticket_audit_id]/make_private(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/audits/${getEncodedUri(ticket_audit_id)}/make_private`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + ticketAuditId - The ID of the ticket audit + # + headers - Headers to be sent with the request + # + return - description + resource isolated function put v2/tickets/[int ticketId]/audits/[int ticketAuditId]/make_private(MakeTicketCommentPrivateFromAuditsHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/audits/${getEncodedUri(ticketAuditId)}/make_private`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Count Audits for a Ticket # - # + ticket_id - The ID of the ticket - # + return - Count of audits on a ticket - resource isolated function get api/v2/tickets/[int ticket_id]/audits/count(string accept = "application/json") returns TicketAuditsCountResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/audits/count`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketAuditsCountResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Count of audits on a ticket + resource isolated function get v2/tickets/[int ticketId]/audits/count(CountAuditsForTicketHeaders headers = {}) returns TicketAuditsCountResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/audits/count`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Collaborators for a Ticket # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function get api/v2/tickets/[int ticket_id]/collaborators(string accept = "application/json") returns ListTicketCollaboratorsResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/collaborators`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ListTicketCollaboratorsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/tickets/[int ticketId]/collaborators(ListTicketCollaboratorsHeaders headers = {}) returns ListTicketCollaboratorsResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/collaborators`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Comments # - # + ticket_id - The ID of the ticket - # + include_inline_images - Default is false. When true, inline images are also listed as attachments in the response - # + include - Accepts "users". Use this parameter to list email CCs by side-loading users. Example: `?include=users`. **Note**: If the comment source is email, a deleted user will be represented as the CCd email address. If the comment source is anything else, a deleted user will be represented as the user name. - # + return - Success response - resource isolated function get api/v2/tickets/[int ticket_id]/comments(string accept = "application/json", boolean? include_inline_images = (), string? include = ()) returns TicketCommentsResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/comments`; - map queryParam = {"include_inline_images": include_inline_images, "include": include}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketCommentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/tickets/[int ticketId]/comments(ListTicketCommentsHeaders headers = {}, *ListTicketCommentsQueries queries) returns TicketCommentsResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/comments`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Redact Comment Attachment # - # + ticket_id - The ID of the ticket - # + comment_id - The ID of the comment - # + attachment_id - The ID of the attachment - # + return - OK response - resource isolated function put api/v2/tickets/[int ticket_id]/comments/[int comment_id]/attachments/[int attachment_id]/redact(string accept = "application/json") returns AttachmentResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/comments/${getEncodedUri(comment_id)}/attachments/${getEncodedUri(attachment_id)}/redact`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + commentId - The ID of the comment + # + attachmentId - The ID of the attachment + # + headers - Headers to be sent with the request + # + return - OK response + resource isolated function put v2/tickets/[int ticketId]/comments/[int commentId]/attachments/[int attachmentId]/redact(RedactCommentAttachmentHeaders headers = {}) returns AttachmentResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/comments/${getEncodedUri(commentId)}/attachments/${getEncodedUri(attachmentId)}/redact`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - AttachmentResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Make Comment Private # - # + ticket_id - The ID of the ticket - # + ticket_comment_id - The ID of the ticket comment - # + return - description - resource isolated function put api/v2/tickets/[int ticket_id]/comments/[int ticket_comment_id]/make_private(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/comments/${getEncodedUri(ticket_comment_id)}/make_private`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + ticketCommentId - The ID of the ticket comment + # + headers - Headers to be sent with the request + # + return - description + resource isolated function put v2/tickets/[int ticketId]/comments/[int ticketCommentId]/make_private(MakeTicketCommentPrivateHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/comments/${getEncodedUri(ticketCommentId)}/make_private`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Redact String in Comment # - # + ticket_id - The ID of the ticket - # + ticket_comment_id - The ID of the ticket comment - # + return - Success response - resource isolated function put api/v2/tickets/[int ticket_id]/comments/[int ticket_comment_id]/redact(string accept = "application/json") returns TicketCommentResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/comments/${getEncodedUri(ticket_comment_id)}/redact`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + ticketCommentId - The ID of the ticket comment + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/tickets/[int ticketId]/comments/[int ticketCommentId]/redact(RedactStringInCommentHeaders headers = {}) returns TicketCommentResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/comments/${getEncodedUri(ticketCommentId)}/redact`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TicketCommentResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Count Ticket Comments # - # + ticket_id - The ID of the ticket - # + return - Count of ticket comments - resource isolated function get api/v2/tickets/[int ticket_id]/comments/count(string accept = "application/json") returns TicketCommentsCountResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/comments/count`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketCommentsCountResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Count of ticket comments + resource isolated function get v2/tickets/[int ticketId]/comments/count(CountTicketCommentsHeaders headers = {}) returns TicketCommentsCountResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/comments/count`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Email CCs for a Ticket # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function get api/v2/tickets/[int ticket_id]/email_ccs(string accept = "application/json") returns ListTicketEmailCCsResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/email_ccs`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ListTicketEmailCCsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/tickets/[int ticketId]/email_ccs(ListTicketEmailCCsHeaders headers = {}) returns ListTicketEmailCCsResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/email_ccs`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Followers for a Ticket # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function get api/v2/tickets/[int ticket_id]/followers(string accept = "application/json") returns ListTicketFollowersResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/followers`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ListTicketFollowersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/tickets/[int ticketId]/followers(ListTicketFollowersHeaders headers = {}) returns ListTicketFollowersResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/followers`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Ticket Incidents # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function get api/v2/tickets/[int ticket_id]/incidents(string accept = "application/json") returns ListTicketIncidentsResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/incidents`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ListTicketIncidentsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/tickets/[int ticketId]/incidents(ListTicketIncidentsHeaders headers = {}) returns ListTicketIncidentsResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/incidents`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Ticket After Changes # - # + macro_id - The ID of the macro - # + ticket_id - The ID of the ticket - # + return - Success Response - resource isolated function get api/v2/tickets/[int ticket_id]/macros/[int macro_id]/apply(string accept = "application/json") returns MacroApplyTicketResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/macros/${getEncodedUri(macro_id)}/apply`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - MacroApplyTicketResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + macroId - The ID of the macro + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/tickets/[int ticketId]/macros/[int macroId]/apply(ShowTicketAfterChangesHeaders headers = {}) returns MacroApplyTicketResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/macros/${getEncodedUri(macroId)}/apply`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Mark Ticket as Spam and Suspend Requester # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function put api/v2/tickets/[int ticket_id]/mark_as_spam(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/mark_as_spam`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function put v2/tickets/[int ticketId]/mark_as_spam(MarkTicketAsSpamAndSuspendRequesterHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/mark_as_spam`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Merge Tickets into Target Ticket # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function post api/v2/tickets/[int ticket_id]/merge(TicketMergeInput payload, string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/merge`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function post v2/tickets/[int ticketId]/merge(TicketMergeInput payload, MergeTicketsIntoTargetTicketHeaders headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/merge`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Ticket Related Information # - # + ticket_id - The ID of the ticket - # + return - Successful response - resource isolated function get api/v2/tickets/[int ticket_id]/related(string accept = "application/json") returns TicketRelatedInformation|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/related`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketRelatedInformation response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/tickets/[int ticketId]/related(TicketRelatedInformationHeaders headers = {}) returns TicketRelatedInformation|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/related`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create a Satisfaction Rating # - # + ticket_id - The id of the ticket - # + return - Success response - resource isolated function post api/v2/tickets/[int ticket_id]/satisfaction_rating(string accept = "application/json") returns SatisfactionRatingResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/satisfaction_rating`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The id of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/tickets/[int ticketId]/satisfaction_rating(CreateTicketSatisfactionRatingHeaders headers = {}) returns SatisfactionRatingResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/satisfaction_rating`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - SatisfactionRatingResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # List Resource Tags # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function get api/v2/tickets/[int ticket_id]/tags(string accept = "application/json") returns TagsByObjectIdResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/tags`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TagsByObjectIdResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/tickets/[int ticketId]/tags(ListResourceTagsHeaders headers = {}) returns TagsByObjectIdResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/tags`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Add Tags # - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function put api/v2/tickets/[int ticket_id]/tags(string accept = "application/json") returns TagsByObjectIdResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/tags`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/tickets/[int ticketId]/tags(PutTagsTicketHeaders headers = {}) returns TagsByObjectIdResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/tags`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TagsByObjectIdResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Set Tags # - # + ticket_id - The ID of the ticket - # + return - Created response - resource isolated function post api/v2/tickets/[int ticket_id]/tags(string accept = "application/json") returns TagsByObjectIdResponse|error { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/tags`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/tickets/[int ticketId]/tags(SetTagsTicketHeaders headers = {}) returns TagsByObjectIdResponse|error { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/tags`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - TagsByObjectIdResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Remove Tags # - # + ticket_id - The ID of the ticket - # + return - No Content response - resource isolated function delete api/v2/tickets/[int ticket_id]/tags(string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/tickets/${getEncodedUri(ticket_id)}/tags`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/tickets/[int ticketId]/tags(DeleteTagsTicketHeaders headers = {}) returns error? { + string resourcePath = string `/v2/tickets/${getEncodedUri(ticketId)}/tags`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Count Tickets # - # + return - Count of tickets - resource isolated function get api/v2/tickets/count() returns Inline_response_200_5|error { - string resourcePath = string `/api/v2/tickets/count`; - Inline_response_200_5 response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Count of tickets + resource isolated function get v2/tickets/count(map headers = {}) returns InlineResponse2005|error { + string resourcePath = string `/v2/tickets/count`; + return self.clientEp->get(resourcePath, headers); } + # Create Many Tickets # - # + return - Create many tickets - resource isolated function post api/v2/tickets/create_many(TicketsCreateRequest payload) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/tickets/create_many`; + # + headers - Headers to be sent with the request + # + return - Create many tickets + resource isolated function post v2/tickets/create_many(TicketsCreateRequest payload, map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/tickets/create_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Bulk Delete Tickets # - # + ids - Comma-separated list of ticket ids - # + return - Successful response - resource isolated function delete api/v2/tickets/destroy_many(string ids, string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/tickets/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function delete v2/tickets/destroy_many(BulkDeleteTicketsHeaders headers = {}, *BulkDeleteTicketsQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/tickets/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Bulk Mark Tickets as Spam # - # + ids - Comma-separated list of ticket ids - # + return - Successful response - resource isolated function put api/v2/tickets/mark_many_as_spam(string ids, string accept = "application/json") returns JobStatusResponse|error { - string resourcePath = string `/api/v2/tickets/mark_many_as_spam`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function put v2/tickets/mark_many_as_spam(MarkManyTicketsAsSpamHeaders headers = {}, *MarkManyTicketsAsSpamQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/tickets/mark_many_as_spam`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - JobStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Show Multiple Tickets # - # + ids - Comma-separated list of ticket ids - # + return - List tickets - resource isolated function get api/v2/tickets/show_many(string ids, string accept = "application/json") returns TicketsResponse|error { - string resourcePath = string `/api/v2/tickets/show_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - List tickets + resource isolated function get v2/tickets/show_many(TicketsShowManyHeaders headers = {}, *TicketsShowManyQueries queries) returns TicketsResponse|error { + string resourcePath = string `/v2/tickets/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Tickets # - # + ids - Comma-separated list of ticket ids - # + return - Successful response - resource isolated function put api/v2/tickets/update_many(string accept = "application/json", string? ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/tickets/update_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function put v2/tickets/update_many(TicketsUpdateManyHeaders headers = {}, *TicketsUpdateManyQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/tickets/update_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - JobStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Trigger Categories # - # + page - Pagination parameters - # + sort - Sort parameters - # + include - Allowed sideloads - # + return - A paged array of trigger categories - resource isolated function get api/v2/trigger_categories(string accept = "application/json", Page? page = (), "position"|"-position"|"name"|"-name"|"created_at"|"-created_at"|"updated_at"|"-updated_at"? sort = (), "rule_counts"? include = ()) returns Inline_response_200_6|error { - string resourcePath = string `/api/v2/trigger_categories`; - map queryParam = {"page": page, "sort": sort, "include": include}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - A paged array of trigger categories + resource isolated function get v2/trigger_categories(ListTriggerCategoriesHeaders headers = {}, *ListTriggerCategoriesQueries queries) returns InlineResponse2006|error { + string resourcePath = string `/v2/trigger_categories`; map queryParamEncoding = {"page": {style: DEEPOBJECT, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - Inline_response_200_6 response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Trigger Category # - # + return - The created trigger category - resource isolated function post api/v2/trigger_categories(V2_trigger_categories_body payload) returns TriggerCategoryResponse|error { - string resourcePath = string `/api/v2/trigger_categories`; + # + headers - Headers to be sent with the request + # + return - The created trigger category + resource isolated function post v2/trigger_categories(V2TriggerCategoriesBody payload, map headers = {}) returns TriggerCategoryResponse|error { + string resourcePath = string `/v2/trigger_categories`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TriggerCategoryResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Trigger Category # - # + trigger_category_id - The id of the trigger category to retrieve - # + return - The requested trigger category - resource isolated function get api/v2/trigger_categories/[string trigger_category_id](string accept = "application/json") returns TriggerCategoryResponse|error { - string resourcePath = string `/api/v2/trigger_categories/${getEncodedUri(trigger_category_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggerCategoryResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + triggerCategoryId - The id of the trigger category to retrieve + # + headers - Headers to be sent with the request + # + return - The requested trigger category + resource isolated function get v2/trigger_categories/[string triggerCategoryId](ShowTriggerCategoryByIdHeaders headers = {}) returns TriggerCategoryResponse|error { + string resourcePath = string `/v2/trigger_categories/${getEncodedUri(triggerCategoryId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Trigger Category # - # + trigger_category_id - The id of the trigger category to delete - # + return - No content - resource isolated function delete api/v2/trigger_categories/[string trigger_category_id](string accept = "application/json") returns http:Response|error { - string resourcePath = string `/api/v2/trigger_categories/${getEncodedUri(trigger_category_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - http:Response response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + triggerCategoryId - The id of the trigger category to delete + # + headers - Headers to be sent with the request + # + return - No content + resource isolated function delete v2/trigger_categories/[string triggerCategoryId](DeleteTriggerCategoryHeaders headers = {}) returns error? { + string resourcePath = string `/v2/trigger_categories/${getEncodedUri(triggerCategoryId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Update Trigger Category # - # + trigger_category_id - The id of the trigger category to update - # + return - The updated trigger category - resource isolated function patch api/v2/trigger_categories/[string trigger_category_id](Trigger_categories_trigger_category_id_body payload, string accept = "application/json") returns TriggerCategoryResponse|error { - string resourcePath = string `/api/v2/trigger_categories/${getEncodedUri(trigger_category_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + triggerCategoryId - The id of the trigger category to update + # + headers - Headers to be sent with the request + # + return - The updated trigger category + resource isolated function patch v2/trigger_categories/[string triggerCategoryId](TriggerCategoriestriggerCategoryIdBody payload, UpdateTriggerCategoryHeaders headers = {}) returns TriggerCategoryResponse|error { + string resourcePath = string `/v2/trigger_categories/${getEncodedUri(triggerCategoryId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TriggerCategoryResponse response = check self.clientEp->patch(resourcePath, request, httpHeaders); - return response; + return self.clientEp->patch(resourcePath, request, httpHeaders); } + # Create Batch Job for Trigger Categories # - # + return - The response to the batch job - resource isolated function post api/v2/trigger_categories/jobs(BatchJobRequest payload) returns BatchJobResponse|error { - string resourcePath = string `/api/v2/trigger_categories/jobs`; + # + headers - Headers to be sent with the request + # + return - The response to the batch job + resource isolated function post v2/trigger_categories/jobs(BatchJobRequest payload, map headers = {}) returns BatchJobResponse|error { + string resourcePath = string `/v2/trigger_categories/jobs`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - BatchJobResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # List Triggers # - # + active - Filter by active triggers if true or inactive triggers if false - # + sort - Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position". - # + sort_by - Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + category_id - Filter triggers by category ID - # + return - Success response - resource isolated function get api/v2/triggers(string accept = "application/json", boolean? active = (), string? sort = (), string? sort_by = (), string? sort_order = (), string? category_id = ()) returns TriggersResponse|error { - string resourcePath = string `/api/v2/triggers`; - map queryParam = {"active": active, "sort": sort, "sort_by": sort_by, "sort_order": sort_order, "category_id": category_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/triggers(ListTriggersHeaders headers = {}, *ListTriggersQueries queries) returns TriggersResponse|error { + string resourcePath = string `/v2/triggers`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Trigger # - # + return - Created response - resource isolated function post api/v2/triggers(TriggerWithCategoryRequest payload) returns TriggerResponse|error { - string resourcePath = string `/api/v2/triggers`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/triggers(TriggerWithCategoryRequest payload, map headers = {}) returns TriggerResponse|error { + string resourcePath = string `/v2/triggers`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TriggerResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Trigger # - # + trigger_id - The ID of the trigger - # + return - Success response - resource isolated function get api/v2/triggers/[int trigger_id](string accept = "application/json") returns TriggerResponse|error { - string resourcePath = string `/api/v2/triggers/${getEncodedUri(trigger_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggerResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + triggerId - The ID of the trigger + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/[int triggerId](GetTriggerHeaders headers = {}) returns TriggerResponse|error { + string resourcePath = string `/v2/triggers/${getEncodedUri(triggerId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Trigger # - # + trigger_id - The ID of the trigger - # + return - Success response - resource isolated function put api/v2/triggers/[int trigger_id](TriggerWithCategoryRequest payload, string accept = "application/json") returns TriggerResponse|error { - string resourcePath = string `/api/v2/triggers/${getEncodedUri(trigger_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + triggerId - The ID of the trigger + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/triggers/[int triggerId](TriggerWithCategoryRequest payload, UpdateTriggerHeaders headers = {}) returns TriggerResponse|error { + string resourcePath = string `/v2/triggers/${getEncodedUri(triggerId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TriggerResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Trigger # - # + trigger_id - The ID of the trigger - # + return - No Content response - resource isolated function delete api/v2/triggers/[int trigger_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/triggers/${getEncodedUri(trigger_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + triggerId - The ID of the trigger + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/triggers/[int triggerId](DeleteTriggerHeaders headers = {}) returns error? { + string resourcePath = string `/v2/triggers/${getEncodedUri(triggerId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Trigger Revisions # - # + trigger_id - The ID of the trigger - # + return - Success response - resource isolated function get api/v2/triggers/[int trigger_id]/revisions(string accept = "application/json") returns TriggerRevisionsResponse|error { - string resourcePath = string `/api/v2/triggers/${getEncodedUri(trigger_id)}/revisions`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggerRevisionsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + triggerId - The ID of the trigger + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/[int triggerId]/revisions(ListTriggerRevisionsHeaders headers = {}) returns TriggerRevisionsResponse|error { + string resourcePath = string `/v2/triggers/${getEncodedUri(triggerId)}/revisions`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Trigger Revision # - # + trigger_id - The ID of the trigger - # + trigger_revision_id - The ID of the revision for a particular trigger - # + return - Success response - resource isolated function get api/v2/triggers/[int trigger_id]/revisions/[int trigger_revision_id](string accept = "application/json") returns TriggerRevisionResponse|error { - string resourcePath = string `/api/v2/triggers/${getEncodedUri(trigger_id)}/revisions/${getEncodedUri(trigger_revision_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggerRevisionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + triggerId - The ID of the trigger + # + triggerRevisionId - The ID of the revision for a particular trigger + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/[int triggerId]/revisions/[int triggerRevisionId](TriggerRevisionHeaders headers = {}) returns TriggerRevisionResponse|error { + string resourcePath = string `/v2/triggers/${getEncodedUri(triggerId)}/revisions/${getEncodedUri(triggerRevisionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Active Triggers # - # + sort - Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position". - # + sort_by - Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + category_id - Filter triggers by category ID - # + return - Success response - resource isolated function get api/v2/triggers/active(string accept = "application/json", string? sort = (), string? sort_by = (), string? sort_order = (), string? category_id = ()) returns TriggersResponse|error { - string resourcePath = string `/api/v2/triggers/active`; - map queryParam = {"sort": sort, "sort_by": sort_by, "sort_order": sort_order, "category_id": category_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/active(ListActiveTriggersHeaders headers = {}, *ListActiveTriggersQueries queries) returns TriggersResponse|error { + string resourcePath = string `/v2/triggers/active`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Trigger Action and Condition Definitions # - # + return - Success response - resource isolated function get api/v2/triggers/definitions() returns TriggerDefinitionResponse|error { - string resourcePath = string `/api/v2/triggers/definitions`; - TriggerDefinitionResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/definitions(map headers = {}) returns TriggerDefinitionResponse|error { + string resourcePath = string `/v2/triggers/definitions`; + return self.clientEp->get(resourcePath, headers); } + # Bulk Delete Triggers # - # + ids - A comma separated list of trigger IDs - # + return - No content response - resource isolated function delete api/v2/triggers/destroy_many(string ids, string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/triggers/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No content response + resource isolated function delete v2/triggers/destroy_many(DeleteManyTriggersHeaders headers = {}, *DeleteManyTriggersQueries queries) returns error? { + string resourcePath = string `/v2/triggers/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Reorder Triggers # - # + return - Success response - resource isolated function put api/v2/triggers/reorder() returns TriggerResponse|error { - string resourcePath = string `/api/v2/triggers/reorder`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/triggers/reorder(map headers = {}) returns TriggerResponse|error { + string resourcePath = string `/v2/triggers/reorder`; http:Request request = new; - TriggerResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # Search Triggers # - # + query - Query string used to find all triggers with matching title - # + filter - Trigger attribute filters for the search. See [Filter](#filter) - # + active - Filter by active triggers if true or inactive triggers if false - # + sort - Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position". - # + sort_by - Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + include - A sideload to include in the response. See [Sideloads](#sideloads-2) - # + return - Success response - resource isolated function get api/v2/triggers/search(string query, string accept = "application/json", Filter? filter = (), boolean? active = (), string? sort = (), string? sort_by = (), string? sort_order = (), string? include = ()) returns TriggersResponse|error { - string resourcePath = string `/api/v2/triggers/search`; - map queryParam = {"query": query, "filter": filter, "active": active, "sort": sort, "sort_by": sort_by, "sort_order": sort_order, "include": include}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/triggers/search(SearchTriggersHeaders headers = {}, *SearchTriggersQueries queries) returns TriggersResponse|error { + string resourcePath = string `/v2/triggers/search`; map queryParamEncoding = {"filter": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TriggersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Triggers # - # + return - Success response - resource isolated function put api/v2/triggers/update_many(TriggerBulkUpdateRequest payload) returns TriggersResponse|error { - string resourcePath = string `/api/v2/triggers/update_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/triggers/update_many(TriggerBulkUpdateRequest payload, map headers = {}) returns TriggersResponse|error { + string resourcePath = string `/v2/triggers/update_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - TriggersResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # Upload Files # - # + return - Created response - resource isolated function post api/v2/uploads() returns AttachmentUploadResponse|error { - string resourcePath = string `/api/v2/uploads`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/uploads(map headers = {}) returns AttachmentUploadResponse|error { + string resourcePath = string `/v2/uploads`; http:Request request = new; - AttachmentUploadResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Delete Upload # # + token - The token of the uploaded attachment - # + return - No Content response - resource isolated function delete api/v2/uploads/[string token](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/uploads/${getEncodedUri(token)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/uploads/[string token](DeleteUploadHeaders headers = {}) returns error? { + string resourcePath = string `/v2/uploads/${getEncodedUri(token)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List User Fields # - # + return - Success response - resource isolated function get api/v2/user_fields() returns UserFieldsResponse|error { - string resourcePath = string `/api/v2/user_fields`; - UserFieldsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/user_fields(map headers = {}) returns UserFieldsResponse|error { + string resourcePath = string `/v2/user_fields`; + return self.clientEp->get(resourcePath, headers); } + # Create User Field # - # + return - Created response - resource isolated function post api/v2/user_fields() returns UserFieldResponse|error { - string resourcePath = string `/api/v2/user_fields`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/user_fields(map headers = {}) returns UserFieldResponse|error { + string resourcePath = string `/v2/user_fields`; http:Request request = new; - UserFieldResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show User Field # - # + user_field_id - The ID or key of the user field - # + return - Success response - resource isolated function get api/v2/user_fields/[User_field_id user_field_id](string accept = "application/json") returns UserFieldResponse|error { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserFieldResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userFieldId - The ID or key of the user field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/user_fields/[userFieldId userFieldId](ShowUserFieldHeaders headers = {}) returns UserFieldResponse|error { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update User Field # - # + user_field_id - The ID or key of the user field - # + return - Success response - resource isolated function put api/v2/user_fields/[User_field_id user_field_id](string accept = "application/json") returns UserFieldResponse|error { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userFieldId - The ID or key of the user field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/user_fields/[userFieldId userFieldId](UpdateUserFieldHeaders headers = {}) returns UserFieldResponse|error { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - UserFieldResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete User Field # - # + user_field_id - The ID or key of the user field - # + return - No Content response - resource isolated function delete api/v2/user_fields/[User_field_id user_field_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userFieldId - The ID or key of the user field + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/user_fields/[userFieldId userFieldId](DeleteUserFieldHeaders headers = {}) returns error? { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List User Field Options # - # + user_field_id - The ID or key of the user field - # + return - Success response - resource isolated function get api/v2/user_fields/[User_field_id user_field_id]/options(string accept = "application/json") returns CustomFieldOptionsResponse|error { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}/options`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomFieldOptionsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userFieldId - The ID or key of the user field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/user_fields/[userFieldId userFieldId]/options(ListUserFieldOptionsHeaders headers = {}) returns CustomFieldOptionsResponse|error { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}/options`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create or Update a User Field Option # - # + user_field_id - The ID or key of the user field - # + return - Success response - resource isolated function post api/v2/user_fields/[User_field_id user_field_id]/options(string accept = "application/json") returns CustomFieldOptionResponse|error { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}/options`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userFieldId - The ID or key of the user field + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/user_fields/[userFieldId userFieldId]/options(CreateOrUpdateUserFieldOptionHeaders headers = {}) returns CustomFieldOptionResponse|error { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}/options`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - CustomFieldOptionResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show a User Field Option # - # + user_field_id - The ID or key of the user field - # + user_field_option_id - The ID of the user field option - # + return - Success response - resource isolated function get api/v2/user_fields/[User_field_id user_field_id]/options/[int user_field_option_id](string accept = "application/json") returns CustomFieldOptionResponse|error { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}/options/${getEncodedUri(user_field_option_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CustomFieldOptionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userFieldId - The ID or key of the user field + # + userFieldOptionId - The ID of the user field option + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/user_fields/[userFieldId userFieldId]/options/[int userFieldOptionId](ShowUserFieldOptionHeaders headers = {}) returns CustomFieldOptionResponse|error { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}/options/${getEncodedUri(userFieldOptionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete User Field Option # - # + user_field_id - The ID or key of the user field - # + user_field_option_id - The ID of the user field option - # + return - No Content response - resource isolated function delete api/v2/user_fields/[User_field_id user_field_id]/options/[int user_field_option_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/user_fields/${getEncodedUri(user_field_id)}/options/${getEncodedUri(user_field_option_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userFieldId - The ID or key of the user field + # + userFieldOptionId - The ID of the user field option + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/user_fields/[userFieldId userFieldId]/options/[int userFieldOptionId](DeleteUserFieldOptionHeaders headers = {}) returns error? { + string resourcePath = string `/v2/user_fields/${getEncodedUri(userFieldId)}/options/${getEncodedUri(userFieldOptionId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Reorder User Field # - # + return - Success response - resource isolated function put api/v2/user_fields/reorder() returns string|error { - string resourcePath = string `/api/v2/user_fields/reorder`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/user_fields/reorder(map headers = {}) returns string|error { + string resourcePath = string `/v2/user_fields/reorder`; http:Request request = new; - string response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # List Users # - # + role - Filters the results by role. Possible values are "end-user", "agent", or "admin" - # + roles - Filters the results by more than one role using the format `role[]={role}&role[]={role}` - # + permission_set - For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request - # + external_id - List users by external id. External id has to be unique for each user under the same account. - # + return - Success response - resource isolated function get api/v2/users(string accept = "application/json", "end-user"|"agent"|"admin"? role = (), string? roles = (), int? permission_set = (), string? external_id = ()) returns UsersResponse|error { - string resourcePath = string `/api/v2/users`; - map queryParam = {"role": role, "roles": roles, "permission_set": permission_set, "external_id": external_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users(ListUsersHeaders headers = {}, *ListUsersQueries queries) returns UsersResponse|error { + string resourcePath = string `/v2/users`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create User # - # + return - Created response - resource isolated function post api/v2/users(UserRequest payload) returns UserResponse|error { - string resourcePath = string `/api/v2/users`; + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/users(UserRequest payload, map headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - UserResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show User # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id](string accept = "application/json") returns UserResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId](ShowUserHeaders headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update User # - # + user_id - The id of the user - # + return - Success response - resource isolated function put api/v2/users/[int user_id](UserRequest payload, string accept = "application/json") returns UserResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId](UserRequest payload, UpdateUserHeaders headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - UserResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete User # - # + user_id - The id of the user - # + return - Success response - resource isolated function delete api/v2/users/[int user_id](string accept = "application/json") returns UserResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function delete v2/users/[int userId](DeleteUserHeaders headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Show Compliance Deletion Statuses # - # + user_id - The id of the user - # + application - Area of compliance - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/compliance_deletion_statuses(string accept = "application/json", string? application = ()) returns ComplianceDeletionStatusesResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/compliance_deletion_statuses`; - map queryParam = {"application": application}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ComplianceDeletionStatusesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/compliance_deletion_statuses(ShowUserComplianceDeletionStatusesHeaders headers = {}, *ShowUserComplianceDeletionStatusesQueries queries) returns ComplianceDeletionStatusesResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/compliance_deletion_statuses`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Memberships # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/group_memberships(string accept = "application/json") returns GroupMembershipsResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/group_memberships`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - GroupMembershipsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/group_memberships(ListGroupMembershipsByUserIdHeaders headers = {}) returns GroupMembershipsResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/group_memberships`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Set Membership as Default # - # + user_id - The id of the user - # + group_membership_id - The ID of the group membership - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/group_memberships/[int group_membership_id]/make_default(string accept = "application/json") returns GroupMembershipsResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/group_memberships/${getEncodedUri(group_membership_id)}/make_default`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + groupMembershipId - The ID of the group membership + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/group_memberships/[int groupMembershipId]/make_default(GroupMembershipSetDefaultHeaders headers = {}) returns GroupMembershipsResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/group_memberships/${getEncodedUri(groupMembershipId)}/make_default`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - GroupMembershipsResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Identities # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/identities(string accept = "application/json") returns UserIdentitiesResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserIdentitiesResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/identities(ListUserIdentitiesHeaders headers = {}) returns UserIdentitiesResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Identity # - # + user_id - The id of the user - # + return - Created response - resource isolated function post api/v2/users/[int user_id]/identities(string accept = "application/json") returns UserIdentityResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Created response + resource isolated function post v2/users/[int userId]/identities(CreateUserIdentityHeaders headers = {}) returns UserIdentityResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - UserIdentityResponse response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Identity # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/identities/[int user_identity_id](string accept = "application/json") returns UserIdentityResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserIdentityResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/identities/[int userIdentityId](ShowUserIdentityHeaders headers = {}) returns UserIdentityResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Identity # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/identities/[int user_identity_id](string accept = "application/json") returns UserIdentityResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/identities/[int userIdentityId](UpdateUserIdentityHeaders headers = {}) returns UserIdentityResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - UserIdentityResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Identity # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - No Content response - resource isolated function delete api/v2/users/[int user_id]/identities/[int user_identity_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/users/[int userId]/identities/[int userIdentityId](DeleteUserIdentityHeaders headers = {}) returns error? { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Make Identity Primary # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/identities/[int user_identity_id]/make_primary(string accept = "application/json") returns UserIdentitiesResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}/make_primary`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/identities/[int userIdentityId]/make_primary(MakeUserIdentityPrimaryHeaders headers = {}) returns UserIdentitiesResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}/make_primary`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - UserIdentitiesResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Request User Verification # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - Success description - resource isolated function put api/v2/users/[int user_id]/identities/[int user_identity_id]/request_verification(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}/request_verification`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - Success description + resource isolated function put v2/users/[int userId]/identities/[int userIdentityId]/request_verification(RequestUserVerficationHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}/request_verification`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Verify Identity # - # + user_id - The id of the user - # + user_identity_id - The ID of the user identity - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/identities/[int user_identity_id]/verify(string accept = "application/json") returns UserIdentityResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/identities/${getEncodedUri(user_identity_id)}/verify`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + userIdentityId - The ID of the user identity + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/identities/[int userIdentityId]/verify(VerifyUserIdentityHeaders headers = {}) returns UserIdentityResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/identities/${getEncodedUri(userIdentityId)}/verify`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - UserIdentityResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Merge End Users # - # + user_id - The id of the user - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/merge(UserRequest payload, string accept = "application/json") returns UserResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/merge`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/merge(UserRequest payload, MergeEndUsersHeaders headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/merge`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - UserResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Set Membership as Default # - # + user_id - The id of the user - # + organization_membership_id - The ID of the organization membership - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/organization_memberships/[int organization_membership_id]/make_default(string accept = "application/json") returns OrganizationMembershipsResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/organization_memberships/${getEncodedUri(organization_membership_id)}/make_default`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + organizationMembershipId - The ID of the organization membership + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/organization_memberships/[int organizationMembershipId]/make_default(SetOrganizationMembershipAsDefaultHeaders headers = {}) returns OrganizationMembershipsResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/organization_memberships/${getEncodedUri(organizationMembershipId)}/make_default`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - OrganizationMembershipsResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Unassign Organization # - # + organization_id - The ID of an organization - # + user_id - The id of the user - # + return - No Content response - resource isolated function delete api/v2/users/[int user_id]/organizations/[int organization_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/organizations/${getEncodedUri(organization_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + organizationId - The ID of an organization + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/users/[int userId]/organizations/[int organizationId](UnassignOrganizationHeaders headers = {}) returns error? { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/organizations/${getEncodedUri(organizationId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Set Organization as Default # - # + user_id - The id of the user - # + organization_id - The ID of an organization - # + return - Success response - resource isolated function put api/v2/users/[int user_id]/organizations/[int organization_id]/make_default(string accept = "application/json") returns OrganizationMembershipResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/organizations/${getEncodedUri(organization_id)}/make_default`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + organizationId - The ID of an organization + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/users/[int userId]/organizations/[int organizationId]/make_default(SetOrganizationAsDefaultHeaders headers = {}) returns OrganizationMembershipResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/organizations/${getEncodedUri(organizationId)}/make_default`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - OrganizationMembershipResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Change Your Password # - # + user_id - The id of the user - # + return - Success description - resource isolated function put api/v2/users/[int user_id]/password(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/password`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success description + resource isolated function put v2/users/[int userId]/password(ChangeOwnPasswordHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/password`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Set a User's Password # - # + user_id - The id of the user - # + return - Success description - resource isolated function post api/v2/users/[int user_id]/password(string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/password`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success description + resource isolated function post v2/users/[int userId]/password(SetUserPasswordHeaders headers = {}) returns string|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/password`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # List password requirements # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/password/requirements(string accept = "application/json") returns UserPasswordRequirementsResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/password/requirements`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserPasswordRequirementsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/password/requirements(GetUserPasswordRequirementsHeaders headers = {}) returns UserPasswordRequirementsResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/password/requirements`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show User Related Information # - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/related(string accept = "application/json") returns UserRelatedResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/related`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UserRelatedResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/related(ShowUserRelatedHeaders headers = {}) returns UserRelatedResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/related`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Bulk Delete Sessions # - # + user_id - The id of the user - # + return - No Content - resource isolated function delete api/v2/users/[int user_id]/sessions(string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/sessions`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - No Content + resource isolated function delete v2/users/[int userId]/sessions(BulkDeleteSessionsByUserIdHeaders headers = {}) returns error? { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/sessions`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Show Session # - # + session_id - The ID of the session - # + user_id - The id of the user - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/sessions/[int session_id](string accept = "application/json") returns SessionResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/sessions/${getEncodedUri(session_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - SessionResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + sessionId - The ID of the session + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/sessions/[int sessionId](ShowSessionHeaders headers = {}) returns SessionResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/sessions/${getEncodedUri(sessionId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Delete Session # - # + session_id - The ID of the session - # + user_id - The id of the user - # + return - No Content - resource isolated function delete api/v2/users/[int user_id]/sessions/[int session_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/sessions/${getEncodedUri(session_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + sessionId - The ID of the session + # + userId - The id of the user + # + headers - Headers to be sent with the request + # + return - No Content + resource isolated function delete v2/users/[int userId]/sessions/[int sessionId](DeleteSessionHeaders headers = {}) returns error? { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/sessions/${getEncodedUri(sessionId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # List Ticket Skips # - # + user_id - User ID of an agent - # + sort_order - Sort order. Defaults to "asc" - # + ticket_id - The ID of the ticket - # + return - Success response - resource isolated function get api/v2/users/[int user_id]/skips(string accept = "application/json", "asc"|"desc"? sort_order = ()) returns TicketSkipsResponse|error { - string resourcePath = string `/api/v2/users/${getEncodedUri(user_id)}/skips`; - map queryParam = {"sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketSkipsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + userId - User ID of an agent + # + ticketId - The ID of the ticket + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/[int userId]/skips(ListTicketSkipsHeaders headers = {}, *ListTicketSkipsQueries queries) returns TicketSkipsResponse|error { + string resourcePath = string `/v2/users/${getEncodedUri(userId)}/skips`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Autocomplete Users # - # + name - The name to search for the user. - # + field_id - The id of a lookup relationship field. The type of field is determined - # by the `source` param - # + 'source - If a `field_id` is provided, this specifies the type of the field. - # For example, if the field is on a "zen:user", it references a field on a user - # + return - Success response - resource isolated function get api/v2/users/autocomplete(string name, string accept = "application/json", string? field_id = (), string? 'source = ()) returns UsersResponse|error { - string resourcePath = string `/api/v2/users/autocomplete`; - map queryParam = {"name": name, "field_id": field_id, "source": 'source}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/autocomplete(AutocompleteUsersHeaders headers = {}, *AutocompleteUsersQueries queries) returns UsersResponse|error { + string resourcePath = string `/v2/users/autocomplete`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Count Users # - # + role - Filters the results by role. Possible values are "end-user", "agent", or "admin" - # + roles - Filters the results by more than one role using the format `role[]={role}&role[]={role}` - # + permission_set - For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request - # + return - Success response - resource isolated function get api/v2/users/count(string accept = "application/json", "end-user"|"agent"|"admin"? role = (), string? roles = (), int? permission_set = ()) returns CountResponse|error { - string resourcePath = string `/api/v2/users/count`; - map queryParam = {"role": role, "roles": roles, "permission_set": permission_set}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - CountResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/count(CountUsersHeaders headers = {}, *CountUsersQueries queries) returns CountResponse|error { + string resourcePath = string `/v2/users/count`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create Many Users # - # + return - Success response - resource isolated function post api/v2/users/create_many(UsersRequest payload) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/users/create_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/users/create_many(UsersRequest payload, map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/users/create_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Create Or Update User # - # + return - Successful response, when user exits - resource isolated function post api/v2/users/create_or_update(UserRequest payload) returns UserResponse|error { - string resourcePath = string `/api/v2/users/create_or_update`; + # + headers - Headers to be sent with the request + # + return - Successful response, when user exits + resource isolated function post v2/users/create_or_update(UserRequest payload, map headers = {}) returns UserResponse|error { + string resourcePath = string `/v2/users/create_or_update`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - UserResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Create Or Update Many Users # - # + return - Success response - resource isolated function post api/v2/users/create_or_update_many(UsersRequest payload) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/users/create_or_update_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/users/create_or_update_many(UsersRequest payload, map headers = {}) returns JobStatusResponse|error { + string resourcePath = string `/v2/users/create_or_update_many`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Bulk Delete Users # - # + ids - Id of the users to delete. Comma separated - # + external_ids - External Id of the users to delete. Comma separated - # + return - Success response - resource isolated function delete api/v2/users/destroy_many(string accept = "application/json", string? ids = (), string? external_ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/users/destroy_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - JobStatusResponse response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function delete v2/users/destroy_many(DestroyManyUsersHeaders headers = {}, *DestroyManyUsersQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/users/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Logout many users # - # + ids - Accepts a comma-separated list of up to 100 user ids. - # + return - Accepted response - resource isolated function post api/v2/users/logout_many(string accept = "application/json", string? ids = ()) returns string|error { - string resourcePath = string `/api/v2/users/logout_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Accepted response + resource isolated function post v2/users/logout_many(LogoutManyUsersHeaders headers = {}, *LogoutManyUsersQueries queries) returns string|error { + string resourcePath = string `/v2/users/logout_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - string response = check self.clientEp->post(resourcePath, request, httpHeaders); - return response; + return self.clientEp->post(resourcePath, request, httpHeaders); } + # Show Self # - # + return - Success response - resource isolated function get api/v2/users/me() returns CurrentUserResponse|error { - string resourcePath = string `/api/v2/users/me`; - CurrentUserResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/me(map headers = {}) returns CurrentUserResponse|error { + string resourcePath = string `/v2/users/me`; + return self.clientEp->get(resourcePath, headers); } + # Delete the Authenticated Session # - # + return - No Content - resource isolated function delete api/v2/users/me/logout() returns error? { - string resourcePath = string `/api/v2/users/me/logout`; - return self.clientEp->delete(resourcePath); + # + headers - Headers to be sent with the request + # + return - No Content + resource isolated function delete v2/users/me/logout(map headers = {}) returns error? { + string resourcePath = string `/v2/users/me/logout`; + return self.clientEp->delete(resourcePath, headers = headers); } + # Show the Currently Authenticated Session # - # + return - Success response - resource isolated function get api/v2/users/me/session() returns SessionResponse|error { - string resourcePath = string `/api/v2/users/me/session`; - SessionResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/me/session(map headers = {}) returns SessionResponse|error { + string resourcePath = string `/v2/users/me/session`; + return self.clientEp->get(resourcePath, headers); } + # Renew the current session # - # + return - Success response - resource isolated function get api/v2/users/me/session/renew() returns RenewSessionResponse|error { - string resourcePath = string `/api/v2/users/me/session/renew`; - RenewSessionResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/users/me/session/renew(map headers = {}) returns RenewSessionResponse|error { + string resourcePath = string `/v2/users/me/session/renew`; + return self.clientEp->get(resourcePath, headers); } + # Request User Create # - # + return - description - resource isolated function post api/v2/users/request_create(UserRequest payload) returns string|error { - string resourcePath = string `/api/v2/users/request_create`; + # + headers - Headers to be sent with the request + # + return - description + resource isolated function post v2/users/request_create(UserRequest payload, map headers = {}) returns string|error { + string resourcePath = string `/v2/users/request_create`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - string response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Search Users # - # + query - The `query` parameter supports the Zendesk search syntax for more advanced - # user searches. It can specify a partial or full value of any - # user property, including name, email address, notes, or phone. Example: - # `query="jdoe"`. - # See the [Search API](/api-reference/ticketing/ticket-management/search/). - # + external_id - The `external_id` parameter does not support the search syntax. It only accepts ids. - # + return - Success response - resource isolated function get api/v2/users/search(string accept = "application/json", string? query = (), string? external_id = ()) returns UsersResponse|error { - string resourcePath = string `/api/v2/users/search`; - map queryParam = {"query": query, "external_id": external_id}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/search(SearchUsersHeaders headers = {}, *SearchUsersQueries queries) returns UsersResponse|error { + string resourcePath = string `/v2/users/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Show Many Users # - # + ids - Accepts a comma-separated list of up to 100 user ids. - # + external_ids - Accepts a comma-separated list of up to 100 external ids. - # + return - Success response - resource isolated function get api/v2/users/show_many(string accept = "application/json", string? ids = (), string? external_ids = ()) returns UsersResponse|error { - string resourcePath = string `/api/v2/users/show_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - UsersResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/users/show_many(ShowManyUsersHeaders headers = {}, *ShowManyUsersQueries queries) returns UsersResponse|error { + string resourcePath = string `/v2/users/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Users # - # + ids - Id of the users to update. Comma separated - # + external_ids - External Id of the users to update. Comma separated - # + return - Successful response - resource isolated function put api/v2/users/update_many(Users_update_many_body payload, string accept = "application/json", string? ids = (), string? external_ids = ()) returns JobStatusResponse|error { - string resourcePath = string `/api/v2/users/update_many`; - map queryParam = {"ids": ids, "external_ids": external_ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - http:Request request = new; - json jsonBody = payload.toJson(); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Successful response + resource isolated function put v2/users/update_many(UsersUpdateManyBody payload, UpdateManyUsersHeaders headers = {}, *UpdateManyUsersQueries queries) returns JobStatusResponse|error { + string resourcePath = string `/v2/users/update_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + http:Request request = new; + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - JobStatusResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # List Views # - # + access - Only views with given access. May be "personal", "shared", or "account" - # + active - Only active views if true, inactive views if false - # + group_id - Only views belonging to given group - # + sort_by - Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + return - Success response - resource isolated function get api/v2/views(string accept = "application/json", string? access = (), boolean? active = (), int? group_id = (), string? sort_by = (), string? sort_order = ()) returns ViewsResponse|error { - string resourcePath = string `/api/v2/views`; - map queryParam = {"access": access, "active": active, "group_id": group_id, "sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views(ListViewsHeaders headers = {}, *ListViewsQueries queries) returns ViewsResponse|error { + string resourcePath = string `/v2/views`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Create View # - # + return - Success response - resource isolated function post api/v2/views() returns ViewResponse|error { - string resourcePath = string `/api/v2/views`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/views(map headers = {}) returns ViewResponse|error { + string resourcePath = string `/v2/views`; http:Request request = new; - ViewResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show View # - # + view_id - The ID of the view - # + return - Success response - resource isolated function get api/v2/views/[int view_id](string accept = "application/json") returns ViewResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/views/[int viewId](ShowViewHeaders headers = {}) returns ViewResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update View # - # + view_id - The ID of the view - # + return - Success response - resource isolated function put api/v2/views/[int view_id](string accept = "application/json") returns ViewResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/views/[int viewId](UpdateViewHeaders headers = {}) returns ViewResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - ViewResponse response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete View # - # + view_id - The ID of the view - # + return - No Content response - resource isolated function delete api/v2/views/[int view_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + return - No Content response + resource isolated function delete v2/views/[int viewId](DeleteViewHeaders headers = {}) returns error? { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Count Tickets in View # - # + view_id - The ID of the view - # + return - Success response - resource isolated function get api/v2/views/[int view_id]/count(string accept = "application/json") returns ViewCountResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}/count`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewCountResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/views/[int viewId]/count(GetViewCountHeaders headers = {}) returns ViewCountResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}/count`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Execute View # - # + view_id - The ID of the view - # + sort_by - The ticket field used for sorting. This will either be a title or a custom field id. - # + sort_order - The direction the tickets are sorted. May be one of 'asc' or 'desc' - # + return - Success response - resource isolated function get api/v2/views/[int view_id]/execute(string accept = "application/json", string? sort_by = (), string? sort_order = ()) returns ViewResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}/execute`; - map queryParam = {"sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/[int viewId]/execute(ExecuteViewHeaders headers = {}, *ExecuteViewQueries queries) returns ViewResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}/execute`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Export View # - # + view_id - The ID of the view - # + return - Success response - resource isolated function get api/v2/views/[int view_id]/export(string accept = "application/json") returns ViewExportResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}/export`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewExportResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/views/[int viewId]/export(ExportViewHeaders headers = {}) returns ViewExportResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}/export`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Tickets From a View # - # + view_id - The ID of the view - # + sort_by - Sort or group the tickets by a column in the [View columns](#view-columns) table. The `subject` and `submitter` columns are not supported - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + return - Success response - resource isolated function get api/v2/views/[int view_id]/tickets(string accept = "application/json", string? sort_by = (), string? sort_order = ()) returns TicketsResponse|error { - string resourcePath = string `/api/v2/views/${getEncodedUri(view_id)}/tickets`; - map queryParam = {"sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - TicketsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + viewId - The ID of the view + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/[int viewId]/tickets(ListTicketsFromViewHeaders headers = {}, *ListTicketsFromViewQueries queries) returns TicketsResponse|error { + string resourcePath = string `/v2/views/${getEncodedUri(viewId)}/tickets`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Active Views # - # + access - Only views with given access. May be "personal", "shared", or "account" - # + group_id - Only views belonging to given group - # + sort_by - Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + return - Success response - resource isolated function get api/v2/views/active(string accept = "application/json", string? access = (), int? group_id = (), string? sort_by = (), string? sort_order = ()) returns ViewsResponse|error { - string resourcePath = string `/api/v2/views/active`; - map queryParam = {"access": access, "group_id": group_id, "sort_by": sort_by, "sort_order": sort_order}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/active(ListActiveViewsHeaders headers = {}, *ListActiveViewsQueries queries) returns ViewsResponse|error { + string resourcePath = string `/v2/views/active`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Views - Compact # - # + return - Success response - resource isolated function get api/v2/views/compact() returns ViewsResponse|error { - string resourcePath = string `/api/v2/views/compact`; - ViewsResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function get v2/views/compact(map headers = {}) returns ViewsResponse|error { + string resourcePath = string `/v2/views/compact`; + return self.clientEp->get(resourcePath, headers); } + # Count Views # - # + return - Count of views - resource isolated function get api/v2/views/count() returns ViewsCountResponse|error { - string resourcePath = string `/api/v2/views/count`; - ViewsCountResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Count of views + resource isolated function get v2/views/count(map headers = {}) returns ViewsCountResponse|error { + string resourcePath = string `/v2/views/count`; + return self.clientEp->get(resourcePath, headers); } + # Count Tickets in Views # - # + ids - List of view's ids separated by commas. - # + return - Success response - resource isolated function get api/v2/views/count_many(string ids, string accept = "application/json") returns ViewCountsResponse|error { - string resourcePath = string `/api/v2/views/count_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewCountsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/count_many(GetViewCountsHeaders headers = {}, *GetViewCountsQueries queries) returns ViewCountsResponse|error { + string resourcePath = string `/v2/views/count_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Bulk Delete Views # - # + ids - The IDs of the views to delete - # + return - No Content response - resource isolated function delete api/v2/views/destroy_many(string ids, string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/views/destroy_many`; - map queryParam = {"ids": ids}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - No Content response + resource isolated function delete v2/views/destroy_many(BulkDeleteViewsHeaders headers = {}, *BulkDeleteViewsQueries queries) returns error? { + string resourcePath = string `/v2/views/destroy_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Preview Views # - # + return - Success response - resource isolated function post api/v2/views/preview() returns ViewResponse|error { - string resourcePath = string `/api/v2/views/preview`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/views/preview(map headers = {}) returns ViewResponse|error { + string resourcePath = string `/v2/views/preview`; http:Request request = new; - ViewResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Preview Ticket Count # - # + return - Success response - resource isolated function post api/v2/views/preview/count() returns ViewCountResponse|error { - string resourcePath = string `/api/v2/views/preview/count`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function post v2/views/preview/count(map headers = {}) returns ViewCountResponse|error { + string resourcePath = string `/v2/views/preview/count`; http:Request request = new; - ViewCountResponse response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Search Views # - # + query - Query string used to find all views with matching title - # + access - Filter views by access. May be "personal", "shared", or "account" - # + active - Filter by active views if true or inactive views if false - # + group_id - Filter views by group - # + sort_by - Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the views are sorted by relevance - # + sort_order - One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - # + include - A sideload to include in the response. See [Sideloads](#sideloads-3) - # + return - Success response - resource isolated function get api/v2/views/search(string query, string accept = "application/json", string? access = (), boolean? active = (), int? group_id = (), string? sort_by = (), string? sort_order = (), string? include = ()) returns ViewsResponse|error { - string resourcePath = string `/api/v2/views/search`; - map queryParam = {"query": query, "access": access, "active": active, "group_id": group_id, "sort_by": sort_by, "sort_order": sort_order, "include": include}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/search(SearchViewsHeaders headers = {}, *SearchViewsQueries queries) returns ViewsResponse|error { + string resourcePath = string `/v2/views/search`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # List Views By ID # - # + ids - List of view's ids separated by commas. - # + active - Only active views if true, inactive views if false - # + return - Success response - resource isolated function get api/v2/views/show_many(string ids, string accept = "application/json", boolean? active = ()) returns ViewsResponse|error { - string resourcePath = string `/api/v2/views/show_many`; - map queryParam = {"ids": ids, "active": active}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - ViewsResponse response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Success response + resource isolated function get v2/views/show_many(ListViewsByIdHeaders headers = {}, *ListViewsByIdQueries queries) returns ViewsResponse|error { + string resourcePath = string `/v2/views/show_many`; + resourcePath = resourcePath + check getPathForQueryParam(queries); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Many Views # - # + return - Success response - resource isolated function put api/v2/views/update_many() returns ViewsResponse|error { - string resourcePath = string `/api/v2/views/update_many`; + # + headers - Headers to be sent with the request + # + return - Success response + resource isolated function put v2/views/update_many(map headers = {}) returns ViewsResponse|error { + string resourcePath = string `/v2/views/update_many`; http:Request request = new; - ViewsResponse response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } + # List Workspaces # - # + return - Success Response - resource isolated function get api/v2/workspaces() returns WorkspaceResponse|error { - string resourcePath = string `/api/v2/workspaces`; - WorkspaceResponse response = check self.clientEp->get(resourcePath); - return response; + # + headers - Headers to be sent with the request + # + return - Success Response + resource isolated function get v2/workspaces(map headers = {}) returns WorkspaceResponse|error { + string resourcePath = string `/v2/workspaces`; + return self.clientEp->get(resourcePath, headers); } + # Create Workspace # - # + return - Created workspace - resource isolated function post api/v2/workspaces(V2_workspaces_body payload) returns Inline_response_201|error { - string resourcePath = string `/api/v2/workspaces`; + # + headers - Headers to be sent with the request + # + return - Created workspace + resource isolated function post v2/workspaces(V2WorkspacesBody payload, map headers = {}) returns InlineResponse201|error { + string resourcePath = string `/v2/workspaces`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - Inline_response_201 response = check self.clientEp->post(resourcePath, request); - return response; + return self.clientEp->post(resourcePath, request, headers); } + # Show Workspace # - # + workspace_id - The id of the workspace - # + return - Successful response - resource isolated function get api/v2/workspaces/[int workspace_id](string accept = "application/json") returns Inline_response_201|error { - string resourcePath = string `/api/v2/workspaces/${getEncodedUri(workspace_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - Inline_response_201 response = check self.clientEp->get(resourcePath, httpHeaders); - return response; + # + workspaceId - The id of the workspace + # + headers - Headers to be sent with the request + # + return - Successful response + resource isolated function get v2/workspaces/[int workspaceId](ShowWorkspaceHeaders headers = {}) returns InlineResponse201|error { + string resourcePath = string `/v2/workspaces/${getEncodedUri(workspaceId)}`; + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->get(resourcePath, httpHeaders); } + # Update Workspace # - # + workspace_id - The id of the workspace - # + return - OK - resource isolated function put api/v2/workspaces/[int workspace_id](Workspaces_workspace_id_body payload, string accept = "application/json") returns Inline_response_201|error { - string resourcePath = string `/api/v2/workspaces/${getEncodedUri(workspace_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + workspaceId - The id of the workspace + # + headers - Headers to be sent with the request + # + return - OK + resource isolated function put v2/workspaces/[int workspaceId](V2WorkspacesBody payload, UpdateWorkspaceHeaders headers = {}) returns InlineResponse201|error { + string resourcePath = string `/v2/workspaces/${getEncodedUri(workspaceId)}`; + map httpHeaders = http:getHeaderMap(headers); http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - Inline_response_201 response = check self.clientEp->put(resourcePath, request, httpHeaders); - return response; + return self.clientEp->put(resourcePath, request, httpHeaders); } + # Delete Workspace # - # + workspace_id - The id of the workspace - # + return - No Content - resource isolated function delete api/v2/workspaces/[int workspace_id](string accept = "application/json") returns error? { - string resourcePath = string `/api/v2/workspaces/${getEncodedUri(workspace_id)}`; - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); + # + workspaceId - The id of the workspace + # + headers - Headers to be sent with the request + # + return - No Content + resource isolated function delete v2/workspaces/[int workspaceId](DeleteWorkspaceHeaders headers = {}) returns error? { + string resourcePath = string `/v2/workspaces/${getEncodedUri(workspaceId)}`; + map httpHeaders = http:getHeaderMap(headers); return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Bulk Delete Workspaces # - # + ids - The ids of the workspaces to delete - # + return - Succesful response - resource isolated function delete api/v2/workspaces/destroy_many(int[] ids, string accept = "application/json") returns string|error { - string resourcePath = string `/api/v2/workspaces/destroy_many`; - map queryParam = {"ids": ids}; + # + headers - Headers to be sent with the request + # + queries - Queries to be sent with the request + # + return - Succesful response + resource isolated function delete v2/workspaces/destroy_many(DestroyManyWorkspacesHeaders headers = {}, *DestroyManyWorkspacesQueries queries) returns string|error { + string resourcePath = string `/v2/workspaces/destroy_many`; map queryParamEncoding = {"ids": {style: FORM, explode: true}}; - resourcePath = resourcePath + check getPathForQueryParam(queryParam, queryParamEncoding); - map headerValues = {"Accept": accept}; - map httpHeaders = getMapForHeaders(headerValues); - string response = check self.clientEp->delete(resourcePath, headers = httpHeaders); - return response; + resourcePath = resourcePath + check getPathForQueryParam(queries, queryParamEncoding); + map httpHeaders = http:getHeaderMap(headers); + return self.clientEp->delete(resourcePath, headers = httpHeaders); } + # Reorder Workspaces # - # + return - Succesful response - resource isolated function put api/v2/workspaces/reorder(Workspaces_reorder_body payload) returns string|error { - string resourcePath = string `/api/v2/workspaces/reorder`; + # + headers - Headers to be sent with the request + # + return - Succesful response + resource isolated function put v2/workspaces/reorder(WorkspacesReorderBody payload, map headers = {}) returns string|error { + string resourcePath = string `/v2/workspaces/reorder`; http:Request request = new; - json jsonBody = payload.toJson(); + json jsonBody = jsondata:toJson(payload); request.setPayload(jsonBody, "application/json"); - string response = check self.clientEp->put(resourcePath, request); - return response; + return self.clientEp->put(resourcePath, request, headers); } } diff --git a/ballerina/types.bal b/ballerina/types.bal index d5b81ea..72aaceb 100644 --- a/ballerina/types.bal +++ b/ballerina/types.bal @@ -17,862 +17,608 @@ // specific language governing permissions and limitations // under the License. +import ballerina/data.jsondata; import ballerina/http; -# Provides a set of configurations for controlling the behaviours when communicating with a remote HTTP endpoint. -@display {label: "Connection Config"} -public type ConnectionConfig record {| - # Configurations related to client authentication - http:CredentialsConfig auth; - # The HTTP version understood by the client - http:HttpVersion httpVersion = http:HTTP_2_0; - # Configurations related to HTTP/1.x protocol - ClientHttp1Settings http1Settings?; - # Configurations related to HTTP/2 protocol - http:ClientHttp2Settings http2Settings?; - # The maximum time to wait (in seconds) for a response before closing the connection - decimal timeout = 60; - # The choice of setting `forwarded`/`x-forwarded` header - string forwarded = "disable"; - # Configurations associated with request pooling - http:PoolConfiguration poolConfig?; - # HTTP caching related configurations - http:CacheConfig cache?; - # Specifies the way of handling compression (`accept-encoding`) header - http:Compression compression = http:COMPRESSION_AUTO; - # Configurations associated with the behaviour of the Circuit Breaker - http:CircuitBreakerConfig circuitBreaker?; - # Configurations associated with retrying - http:RetryConfig retryConfig?; - # Configurations associated with inbound response size limits - http:ResponseLimitConfigs responseLimits?; - # SSL/TLS-related options - http:ClientSecureSocket secureSocket?; - # Proxy server related options - http:ProxyConfig proxy?; - # Enables the inbound payload validation functionality which provided by the constraint package. Enabled by default - boolean validation = true; -|}; - -# Provides settings related to HTTP/1.x protocol. -public type ClientHttp1Settings record {| - # Specifies whether to reuse a connection for multiple requests - http:KeepAlive keepAlive = http:KEEPALIVE_AUTO; - # The chunking behaviour of the request - http:Chunking chunking = http:CHUNKING_AUTO; - # Proxy server related options - ProxyConfig proxy?; -|}; - -# Proxy server configurations to be used with the HTTP client endpoint. -public type ProxyConfig record {| - # Host name of the proxy server - string host = ""; - # Proxy server port - int port = 0; - # Proxy server username - string userName = ""; - # Proxy server password - @display {label: "", kind: "password"} - string password = ""; -|}; +# Represents the Headers record for the operation: ShowMonitoredTwitterHandle +public type ShowMonitoredTwitterHandleHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; -public type TicketMetricEventBreachObject record { - *TicketMetricEventBaseObject; - # Available if `type` is `breach`. In general, you can ignore any breach event when `deleted` is true. See [deleted](#deleted) - boolean? deleted?; +# Represents the Headers record for the operation: TicketsUpdateMany +public type TicketsUpdateManyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketRelatedInformation record { - string[]? followup_source_ids?; - # Is true if the current ticket is archived - boolean? from_archive?; + # X (formerly Twitter) information associated with the ticket + record {} twitter?; + @jsondata:Name {value: "followup_source_ids"} + string[] followupSourceIds?; # A count of related incident occurrences - int? incidents?; + int incidents?; # Related topic in the Web portal (deprecated feature) - string? topic_id?; - # X (formerly Twitter) information associated with the ticket - record {}? twitter?; + @jsondata:Name {value: "topic_id"} + string? topicId?; + # Is true if the current ticket is archived + @jsondata:Name {value: "from_archive"} + boolean fromArchive?; }; -# Google Apps configuration. See [G Suite](#g-suite) -public type AccountSettingsGoogleAppsObject record { - boolean? has_google_apps?; - boolean? has_google_apps_admin?; +# Represents the Headers record for the operation: ReorderGroupSLAPolicies +public type ReorderGroupSLAPoliciesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TargetCampfire record { - boolean? preserve_format?; - string? room; - boolean? ssl?; - string? subdomain; - string? token; +# Represents the Headers record for the operation: CreateCustomObjectField +public type CreateCustomObjectFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerCategoryRuleCounts record { - int? active_count?; - int? inactive_count?; +# Represents the Headers record for the operation: ShowGroupSLAPolicy +public type ShowGroupSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SLAPolicyFilterDefinitionResponse_definitions record { - SLAPolicyFilterDefinitionResponse_definitions_all[]? all?; - SLAPolicyFilterDefinitionResponse_definitions_all[]? 'any?; +# Represents the Headers record for the operation: ShowUserComplianceDeletionStatuses +public type ShowUserComplianceDeletionStatusesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type UserIdentityObject record { - # The time the identity was created - string? created_at?; - # Email identity type only. Indicates if Zendesk sends notifications to the email address. See [Deliverable state](#deliverable-state) - string? deliverable_state?; - # Automatically assigned on creation - int? id?; - # If the identity is the primary identity. *Writable only when creating, not when updating. Use the [Make Identity Primary](#make-identity-primary) endpoint instead - boolean? primary?; - # The type of this identity - "email"|"twitter"|"facebook"|"google"|"phone_number"|"agent_forwarding"|"any_channel"|"foreign"|"sdk" 'type; - # The number of times a soft-bounce response was received at that address - int? undeliverable_count?; - # The time the identity was updated - string? updated_at?; - # The API url of this identity - string? url?; - # The id of the user - int? user_id; - # The identifier for this identity, such as an email address - string? value; - # If the identity has been verified - boolean? verified?; +public type CustomRolesResponse record { + @jsondata:Name {value: "custom_roles"} + CustomRoleObject[] customRoles?; }; -public type TargetResponse record { - TargetObject? target?; +# Represents the Headers record for the operation: DeleteSuspendedTicket +public type DeleteSuspendedTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomRolesResponse record { - CustomRoleObject[]? custom_roles?; +# Represents the Queries record for the operation: DeleteCustomObjectRecordByExternalId +public type DeleteCustomObjectRecordByExternalIdQueries record { + # The external id of a custom object record + @http:Query {name: "external_id"} + string externalId; }; -public type CustomFieldObject record { - # If true, this field is available for use - boolean? active?; - # The time of the last update of the ticket field - string? created_at?; - # Required and presented for a custom field of type "dropdown". Each option is represented by an object with a `name` and `value` property - CustomFieldOptionObject[]? custom_field_options?; - # User-defined description of this field's purpose - string? description?; - # Automatically assigned upon creation - int? id?; - # A unique key that identifies this custom field. This is used for updating the field and referencing in placeholders. The key must consist of only letters, numbers, and underscores. It can't be only numbers and can't be reused if deleted. - string? 'key; - # Ordering of the field relative to other fields - int? position?; - # The dynamic content placeholder, if present, or the `description` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_description?; - # The dynamic content placeholder, if present, or the `title` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_title?; - # Regular expression field only. The validation pattern for a field value to be deemed valid - string? regexp_for_validation?; - # A filter definition that allows your autocomplete to filter down results - record {}? relationship_filter?; - # A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", and "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment". - string? relationship_target_type?; - # If true, only active and position values of this field can be changed - boolean? system?; - # Optional for custom field of type "checkbox"; not presented otherwise. - string? tag?; - # The title of the custom field - string? title; - # The custom field type: "checkbox", "date", "decimal", "dropdown", "integer", ["lookup"](/api-reference/ticketing/lookup_relationships/lookup_relationships/), "regexp", "text", or "textarea" - string? 'type; - # The time of the last update of the ticket field - string? updated_at?; - # The URL for this resource - string? url?; +# Represents the Headers record for the operation: UpdateRequest +public type UpdateRequestHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type RecoverSuspendedTicketResponse record { - SuspendedTicketObject[]? ticket?; + SuspendedTicketObject[] ticket?; }; -public type TicketCommentResponse record { - TicketCommentObject? comment?; +# Represents the Headers record for the operation: BulkDeleteTickets +public type BulkDeleteTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type DeletedUserResponse record { - DeletedUserObject? deleted_user?; +public type TicketCommentResponse record { + TicketCommentObject comment?; }; -# Metadata for the export query response. -public type SearchExportResponse_meta record { - # The cursor id for the next object. - string? after_cursor?; - # The cursor id for the previous object. - string? before_cursor?; - # Whether there are more items yet to be returned by the cursor. - boolean? has_more?; +# Represents the Headers record for the operation: ShowAttributeValue +public type ShowAttributeValueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TagCountResponse record { - TagCountObject? count?; +# Represents the Headers record for the operation: UpdateTriggerCategory +public type UpdateTriggerCategoryHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type OrganizationsResponse record { - int? count?; - string? next_page?; - OrganizationObject[]? organizations?; - string? previous_page?; +# Represents the Headers record for the operation: OpenTicketInAgentBrowser +public type OpenTicketInAgentBrowserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TriggerCategoryResponse record { - TriggerCategory? trigger_category?; -}; - -public type TicketObject record { - # Permission for agents to add add attachments to a comment. Defaults to true - boolean? allow_attachments?; - # Is false if channelback is disabled, true otherwise. Only applicable for channels framework ticket - boolean? allow_channelback?; - # Write only. The email address of the agent to assign the ticket to - string? assignee_email?; - # The agent currently assigned to the ticket - int? assignee_id?; - # Write only. An array of the IDs of attribute values to be associated with the ticket - int[]? attribute_value_ids?; - # The id of the brand this ticket is associated with. See [Setting up multiple brands](https://support.zendesk.com/hc/en-us/articles/4408829476378) - int? brand_id?; - # The ids of users currently CC'ed on the ticket - int[]? collaborator_ids?; - # POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) - CollaboratorObject[]? collaborators?; - # Write only. An object that adds a comment to the ticket. See [Ticket comments](/api-reference/ticketing/tickets/ticket_comments/). To include an attachment with the comment, see [Attaching files](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#attaching-files) - record {}? comment?; - # When this record was created - string? created_at?; - # Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) - TicketObject_custom_fields[]? custom_fields?; - # The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) - int? custom_status_id?; - # Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) - string? description?; - # If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format. - string? due_at?; - # The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center - int[]? email_cc_ids?; - # Write only. An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-email-ccs) - record {}? email_ccs?; - # An id you can use to link Zendesk Support tickets to local records - string? external_id?; - # The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) - int[]? follower_ids?; - # Write only. An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-followers) - record {}? followers?; - # The ids of the followups created from this ticket. Ids are only visible once the ticket is closed - int[]? followup_ids?; - # The topic in the Zendesk Web portal this ticket originated from, if any. The Web portal is deprecated - int? forum_topic_id?; - # If true, the ticket's [via type](/documentation/ticketing/reference-guides/via-object-reference/) is a messaging channel. - boolean? from_messaging_channel?; - # The group this ticket is assigned to - int? group_id?; - # Is true if a ticket is a problem type and has one or more incidents linked to it. Otherwise, the value is false. - boolean? has_incidents?; - # Automatically assigned when the ticket is created - int? id?; - # Is true if any comments are public, false otherwise - boolean? is_public?; - # Write only. A macro ID to be recorded in the ticket audit - int? macro_id?; - # POST requests only. List of macro IDs to be recorded in the ticket audit - int[]? macro_ids?; - # Write only. Metadata for the audit. In the `audit` object, the data is specified in the `custom` property of the `metadata` object. See [Setting Metadata](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-metadata) - record {}? metadata?; - # The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) - int? organization_id?; - # The urgency with which the ticket should be addressed - "urgent"|"high"|"normal"|"low" priority?; - # For tickets of type "incident", the ID of the problem the incident is linked to - int? problem_id?; - # The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_subject?; - # The original recipient e-mail address of the ticket. Notification emails for the ticket are sent from this address - string? recipient?; - # Write only. See [Creating a ticket with a new requester](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#creating-a-ticket-with-a-new-requester) - record {}? requester?; - # The user who requested this ticket - int? requester_id; - # Write only. Optional boolean. When true and an `update_stamp` date is included, protects against ticket update collisions and returns a message to let you know if one occurs. See [Protecting against ticket update collisions](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#protecting-against-ticket-update-collisions). A value of false has the same effect as true. Omit the property to force the updates to not be safe - boolean? safe_update?; - # The satisfaction rating of the ticket, if it exists, or the state of satisfaction, "offered" or "unoffered". The value is null for plan types that don't support CSAT - record {}? satisfaction_rating?; - # The ids of the sharing agreements used for this ticket - int[]? sharing_agreement_ids?; - # The state of the ticket. - # - # If your account has activated custom ticket statuses, this is the ticket's - # status category. See [custom ticket statuses](#custom-ticket-statuses) - "new"|"open"|"pending"|"hold"|"solved"|"closed" status?; - # The value of the subject field for this ticket. See [Subject](/api-reference/ticketing/tickets/tickets/#subject) - string? subject?; - # The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket - int? submitter_id?; - # The array of tags applied to this ticket - string[]? tags?; - # Enterprise only. The id of the ticket form to render for the ticket - int? ticket_form_id?; - # The type of this ticket - "problem"|"incident"|"question"|"task" 'type?; - # When this record last got updated. It is updated only if the update generates a [ticket event](#incremental-ticket-event-export) - string? updated_at?; - # Write only. Datetime of last update received from API. See the `safe_update` property - string? updated_stamp?; - # The API url of this ticket - string? url?; - # For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - TicketObject_via? via?; - # POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) - int? via_followup_source_id?; - # Write only. For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference/) - int? via_id?; - # Write only. See [Creating voicemail ticket](/api-reference/voice/talk-partner-edition-api/reference/#creating-voicemail-tickets) - record {}? voice_comment?; + @jsondata:Name {value: "trigger_category"} + TriggerCategory triggerCategory?; }; -public type TrialAccountResponse record { - TrialAccountObject? account?; +# Represents the Headers record for the operation: UpdateCustomObjectField +public type UpdateCustomObjectFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketFieldsResponse record { - TicketFieldObject[]? ticket_fields?; + @jsondata:Name {value: "ticket_fields"} + TicketFieldObject[] ticketFields?; }; public type TicketAuditsResponseNoneCursor record { - TicketAuditObject[]? audits?; - int? count?; - string? next_page?; - string? previous_page?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + TicketAuditObject[] audits?; }; public type CursorBasedExportIncrementalUsersResponse record { - string? after_cursor?; - string? after_url?; - string? before_cursor?; - string? before_url?; - boolean? end_of_stream?; - UserObject[]? users?; + @jsondata:Name {value: "before_url"} + string? beforeUrl?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + @jsondata:Name {value: "after_cursor"} + string? afterCursor?; + @jsondata:Name {value: "after_url"} + string? afterUrl?; + @jsondata:Name {value: "before_cursor"} + string? beforeCursor?; + UserObject[] users?; }; public type RequestsResponse record { - RequestObject[]? requests?; + RequestObject[] requests?; }; -public type ReverseLookupResponse UsersResponse?; - public type WorkspaceResponse record { - WorkspaceObject[]? workspaces?; + *WorkspaceResponseAllOf1; *OffsetPaginationObject; }; -public type AssigneeFieldAssignableAgentObject record { - # URL of Agent's avatar - string? avatar_url?; - # Agent Support ID - int? id?; - # Name of the agent - string? name?; +# Represents the Headers record for the operation: SetTagsTicket +public type SetTagsTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomFieldOptionsResponse record { - # Total count of records retrieved - int? count?; - CustomFieldOptionObject[]? custom_field_options?; # URL of the next page - string? next_page?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "custom_field_options"} + CustomFieldOptionObject[] customFieldOptions?; + # Total count of records retrieved + int count?; # URL of the previous page - string? previous_page?; -}; - -public type TicketMetricEventGroupSLAObject record { - *TicketMetricEventBaseObject; - # Available if `type` is "apply_group_sla". The Group SLA policy and target being enforced on the ticket and metric in question, if any. See [group_sla](#group_sla) - record {}? group_sla?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; }; public type MacroAttachmentsResponse record { - MacroAttachmentObject[]? macro_attachments?; -}; - -public type CountResponse_count record { - string? refreshed_at?; - int? value?; + @jsondata:Name {value: "macro_attachments"} + MacroAttachmentObject[] macroAttachments?; }; -public type SkillBasedRoutingAttributesResponse record { - SkillBasedRoutingAttributeObject[]? attributes?; - int? count?; - string? next_page?; - string? previous_page?; +# Represents the Queries record for the operation: TicketsUpdateMany +public type TicketsUpdateManyQueries record { + # Comma-separated list of ticket ids + string ids?; }; public type TargetFailureResponse record { - TargetFailureObject? target_failure?; + @jsondata:Name {value: "target_failure"} + TargetFailureObject targetFailure?; }; public type ListTicketProblemsResponse record { }; -public type Inline_response_200_1_count record { - # The time the last count was performed - string? refreshed_at?; - # Number of records at the time of the latest count operation - int? value?; -}; - -public type TriggerCategoriesResponse record { - TriggerCategory[]? trigger_categories?; +# Represents the Queries record for the operation: BulkDeleteTickets +public type BulkDeleteTicketsQueries record { + # Comma-separated list of ticket ids + string ids; }; public type TicketCommentObject record { + # System information (web client, IP address, etc.) and comment flags, if any. See [Comment flags](#comment-flags) + record {} metadata?; # Attachments, if any. See [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) - AttachmentObject[]? attachments?; - # The id of the ticket audit record. See [Show Audit](/api-reference/ticketing/tickets/ticket_audits/#show-audit) - int? audit_id?; - # The id of the comment author. See [Author id](#author-id) - int? author_id?; - # The comment string. See [Bodies](#bodies) - string? body?; - # The time the comment was created - string? created_at?; + AttachmentObject[] attachments?; # The comment formatted as HTML. See [Bodies](#bodies) - string? html_body?; - # Automatically assigned when the comment is created - int? id?; - # System information (web client, IP address, etc.) and comment flags, if any. See [Comment flags](#comment-flags) - record {}? metadata?; + @jsondata:Name {value: "html_body"} + string htmlBody?; + # The time the comment was created + @jsondata:Name {value: "created_at"} + string createdAt?; # The comment presented as plain text. See [Bodies](#bodies) - string? plain_body?; - # true if a public comment; false if an internal note. The initial value set on ticket creation persists for any additional comment unless you change it - boolean? 'public?; + @jsondata:Name {value: "plain_body"} + string plainBody?; + # The comment string. See [Bodies](#bodies) + string body?; # `Comment` or `VoiceComment`. The JSON object for adding voice comments to tickets is different. See [Adding voice comments to tickets](/documentation/ticketing/managing-tickets/adding-voice-comments-to-tickets) - string? 'type?; + string 'type?; # List of tokens received from [uploading files](/api-reference/ticketing/tickets/ticket-attachments/#upload-files) for comment attachments. The files are attached by creating or updating tickets with the tokens. See [Attaching files](/api-reference/ticketing/tickets/tickets/#attaching-files) in Tickets - string[]? uploads?; - # Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - TicketAuditViaObject? via?; + string[] uploads?; + TicketAuditViaObject via?; + # The id of the ticket audit record. See [Show Audit](/api-reference/ticketing/tickets/ticket_audits/#show-audit) + @jsondata:Name {value: "audit_id"} + int auditId?; + # true if a public comment; false if an internal note. The initial value set on ticket creation persists for any additional comment unless you change it + boolean 'public?; + # Automatically assigned when the comment is created + int id?; + # The id of the comment author. See [Author id](#author-id) + @jsondata:Name {value: "author_id"} + int authorId?; }; -public type TicketImportInput record { - # The agent currently assigned to the ticket - int? assignee_id?; - # The conversation between requesters, collaborators, and agents - record {}? comments?; - # Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) - string? description?; - # The user who requested this ticket - int? requester_id?; - # The value of the subject field for this ticket - string? subject?; - # The array of tags applied to this ticket - string[]? tags?; +# Represents the Headers record for the operation: ShowUserIdentity +public type ShowUserIdentityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TwitterChannelTwicketStatusResponse record { - TwitterChannelTwicketStatusResponse_statuses[]? statuses?; +# Represents the Headers record for the operation: DeleteTicket +public type DeleteTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# The active features for an account. See [Active Features](#active-features) -public type AccountSettingsActiveFeaturesObject record { - boolean? advanced_analytics?; - boolean? agent_forwarding?; - boolean? allow_ccs?; - boolean? allow_email_template_customization?; - boolean? automatic_answers?; - boolean? bcc_archiving?; - boolean? benchmark_opt_out?; - boolean? business_hours?; - boolean? chat?; - boolean? chat_about_my_ticket?; - boolean? csat_reason_code?; - boolean? custom_dkim_domain?; - boolean? customer_context_as_default?; - boolean? customer_satisfaction?; - boolean? dynamic_contents?; - boolean? explore?; - boolean? explore_on_support_ent_plan?; - boolean? explore_on_support_pro_plan?; - boolean? facebook?; - boolean? facebook_login?; - boolean? fallback_composer?; - boolean? forum_analytics?; - boolean? good_data_and_explore?; - boolean? google_login?; - boolean? insights?; - boolean? is_abusive?; - boolean? light_agents?; - boolean? markdown?; - boolean? on_hold_status?; - boolean? organization_access_enabled?; - boolean? rich_content_in_emails?; - boolean? sandbox?; - boolean? satisfaction_prediction?; - boolean? suspended_ticket_notification?; - boolean? ticket_forms?; - boolean? ticket_tagging?; - boolean? topic_suggestion?; - boolean? twitter?; - boolean? twitter_login?; - boolean? user_org_fields?; - boolean? user_tagging?; - boolean? voice?; +public type TwitterChannelTwicketStatusResponse record { + TwitterChannelTwicketStatusResponseStatuses[] statuses?; }; public type BookmarkInput record { - # The id of the ticket the bookmark is for. - int? ticket_id?; -}; - -public type BookmarkResponse record { - BookmarkObject? bookmark?; + # The id of the ticket the bookmark is for + @jsondata:Name {value: "ticket_id"} + int ticketId?; }; -public type CountOrganizationObject record { - string? refreshed_at?; - int? value?; +# Represents the Queries record for the operation: ExecuteView +public type ExecuteViewQueries record { + # The ticket field used for sorting. This will either be a title or a custom field id + @http:Query {name: "sort_by"} + string sortBy?; + # The direction the tickets are sorted. May be one of 'asc' or 'desc' + @http:Query {name: "sort_order"} + string sortOrder?; }; public type IncrementalSkillBasedRoutingInstanceValue record { - # Id of the associated attribute value - string? attribute_value_id?; - # Automatically assigned when an instance value is created - string? id?; # Id of the associated agent or ticket - string? instance_id?; + @jsondata:Name {value: "instance_id"} + string instanceId?; + # Automatically assigned when an instance value is created + string id?; # The time the instance value was created or deleted - string? time?; + string time?; + # Id of the associated attribute value + @jsondata:Name {value: "attribute_value_id"} + string attributeValueId?; # One of "associate_agent", "unassociate_agent", "associate_ticket", or "unassociate_ticket" - string? 'type?; + string 'type?; }; -# For some channels a source object gives more information about how or why the ticket or event was created -public type ViaObject_source record { - ViaObject_source_from? 'from?; - string? rel?; - ViaObject_source_to? to?; +# Represents the Headers record for the operation: DeleteAttributeValue +public type DeleteAttributeValueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ChannelFrameworkPushResultsResponse record { - # An array of [result objects](#result-object) - ChannelFrameworkResultObject[]? results?; +# Represents the Headers record for the operation: ListDeletedTickets +public type ListDeletedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AutomationObject record { - # An object describing what the automation will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) - ActionObject[]? actions?; - # Whether the automation is active - boolean? active?; - # An object that describes the conditions under which the automation will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - ConditionsObject? conditions?; - # The time the automation was created - string? created_at?; - # If true, the automation is a default automation - boolean? default?; - # Automatically assigned when created - int? id?; - # The position of the automation which specifies the order it will be executed - int? position?; - # The raw title of the automation - string? raw_title?; - # The title of the automation - string? title?; - # The time of the last update of the automation - string? updated_at?; +# Represents the Headers record for the operation: SearchAutomations +public type SearchAutomationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SearchExportResponse record { - # The facets corresponding to the search query - string? facets?; - # The links to the previous and next entries via the cursor ids in the metadata. - SearchExportResponse_links? links?; - # Metadata for the export query response. - SearchExportResponse_meta? meta?; - # May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object - SearchResultObject[]? results?; -}; +public type TriggerCategoriesResponseTriggerCategories TriggerCategory; -public type ComplianceDeletionStatusObject record { - string? account_subdomain; - string? action; - string? application; - string? created_at; - int? executer_id; - int? user_id; +public type TicketObjectCustomFields record { + # The id of the custom field + int id?; + # The value of the custom field + string value?; }; public type UserRelatedResponse record { - UserRelatedObject? user_related?; + @jsondata:Name {value: "user_related"} + UserRelatedObject userRelated?; }; public type TriggerConditionObject record { - string? 'field?; - string? operator?; - string|int|(string|int?)[]? value?; + string 'field?; + string|int|(string|int)[] value?; + string operator?; }; # Zendesk Talk settings. See [Voice](#voice) public type AccountSettingsVoiceObject record { - boolean? agent_confirmation_when_forwarding?; - boolean? agent_wrap_up_after_calls?; - boolean? enabled?; - boolean? logging?; - int? maximum_queue_size?; - int? maximum_queue_wait_time?; - boolean? only_during_business_hours?; - boolean? outbound_enabled?; - boolean? recordings_public?; - boolean? uk_mobile_forwarding?; + @jsondata:Name {value: "agent_wrap_up_after_calls"} + boolean agentWrapUpAfterCalls?; + @jsondata:Name {value: "outbound_enabled"} + boolean outboundEnabled?; + @jsondata:Name {value: "only_during_business_hours"} + boolean onlyDuringBusinessHours?; + @jsondata:Name {value: "maximum_queue_wait_time"} + int maximumQueueWaitTime?; + boolean logging?; + @jsondata:Name {value: "maximum_queue_size"} + int maximumQueueSize?; + @jsondata:Name {value: "recordings_public"} + boolean recordingsPublic?; + @jsondata:Name {value: "uk_mobile_forwarding"} + boolean ukMobileForwarding?; + @jsondata:Name {value: "agent_confirmation_when_forwarding"} + boolean agentConfirmationWhenForwarding?; + boolean enabled?; }; public type SupportAddressObject record { - # The ID of the [brand](/api-reference/ticketing/account-configuration/brands/) - int? brand_id?; # Whether all of the required CNAME records are set. Possible values: "unknown", "verified", "failed" - "unknown"|"verified"|"failed" cname_status?; - # When the address was created - string? created_at?; - # Whether the address is the account's default support address - boolean? default?; - # Verification statuses for the domain and CNAME records. Possible types: "verified", "failed" - "verified"|"failed" dns_results?; - # Verification string to be added as a TXT record to the domain. Possible types: string or null. - string? domain_verification_code?; - # Whether the domain verification record is valid. Possible values: "unknown", "verified", "failed" - "unknown"|"verified"|"failed" domain_verification_status?; - # The email address. You can't change the email address of an existing support address. - string? email; + @jsondata:Name {value: "cname_status"} + "unknown"|"verified"|"failed" cnameStatus?; # Status of email forwarding. Possible values: "unknown", "waiting", "verified", or "failed" - "unknown"|"waiting"|"verified"|"failed" forwarding_status?; - # Automatically assigned when created - int? id?; - # The name for the address - string? name?; + @jsondata:Name {value: "forwarding_status"} + "unknown"|"waiting"|"verified"|"failed" forwardingStatus?; + # When the address was created + @jsondata:Name {value: "created_at"} + string createdAt?; # Whether the SPF record is set up correctly. Possible values: "unknown", "verified", "failed" - "unknown"|"verified"|"failed" spf_status?; + @jsondata:Name {value: "spf_status"} + "unknown"|"verified"|"failed" spfStatus?; + # The ID of the [brand](/api-reference/ticketing/account-configuration/brands/) + @jsondata:Name {value: "brand_id"} + int brandId?; + # Whether the address is the account's default support address + boolean default?; # When the address was updated - string? updated_at?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The name for the address + string name?; + # Automatically assigned when created + int id?; + # Whether the domain verification record is valid. Possible values: "unknown", "verified", "failed" + @jsondata:Name {value: "domain_verification_status"} + "unknown"|"verified"|"failed" domainVerificationStatus?; + # Verification statuses for the domain and CNAME records. Possible types: "verified", "failed" + @jsondata:Name {value: "dns_results"} + "verified"|"failed" dnsResults?; + # Verification string to be added as a TXT record to the domain. Possible types: string or null + @jsondata:Name {value: "domain_verification_code"} + string domainVerificationCode?; + # The email address. You can't change the email address of an existing support address + string email; }; -public type ViaObject_source_to record { - string? address?; - string? name?; +# Represents the Queries record for the operation: GetRelationshipFilterDefinitions +public type GetRelationshipFilterDefinitionsQueries record { + # The source type for which you would like to see filter definitions. + # The options are "zen:user", "zen:ticket", and "zen:organization" + @http:Query {name: "source_type"} + string sourceType?; }; -public type TicketUpdateRequest record { - TicketUpdateInput? ticket?; +# Represents the Headers record for the operation: ListTicketFieldOptions +public type ListTicketFieldOptionsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ActionsObject record { - ActionObject[]? actions?; +# Represents the Headers record for the operation: SetOrganizationAsDefault +public type SetOrganizationAsDefaultHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketBulkImportRequest record { - TicketImportInput[]? tickets?; + TicketImportInput[] tickets?; }; -public type ViaObject_source_from record { - string? address?; - int? id?; - string? name?; - string? title?; -}; - -# Brand settings. See [Brands](#brands) -public type AccountSettingsBrandsObject record { - int? default_brand_id?; - boolean? require_brand_on_new_tickets?; +# For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) +public type TicketObjectVia record { + # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" + string channel?; + # For some channels a source object gives more information about how or why the ticket or event was created + record {} 'source?; }; public type TicketAuditObject record { - # The user who created the audit - int? author_id?; + # Metadata for the audit, custom and system data + record {} metadata?; # The time the audit was created - string? created_at?; - # An array of the events that happened in this audit. See the [Ticket Audit events reference](/documentation/ticketing/reference-guides/ticket-audit-events-reference) - record {}[]? events?; + @jsondata:Name {value: "created_at"} + string createdAt?; # Automatically assigned when creating audits - int? id?; - # Metadata for the audit, custom and system data - record {}? metadata?; + int id?; + # The user who created the audit + @jsondata:Name {value: "author_id"} + int authorId?; # The ID of the associated ticket - int? ticket_id?; - # Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - TicketAuditViaObject? via?; -}; - -public type OrganizationMembershipObject record { - # When this record was created - string? created_at?; - # Denotes whether this is the default organization membership for the user. If false, returns `null` - boolean? default; - # Automatically assigned when the membership is created - int? id?; - # The ID of the organization associated with this user, in this membership - int? organization_id; - # The name of the organization associated with this user, in this membership - string? organization_name?; - # When this record last got updated - string? updated_at?; - # The API url of this membership - string? url?; - # The ID of the user for whom this memberships belongs - int? user_id; - # Denotes whether the user can or cannot have access to all organization's tickets. - boolean? view_tickets?; + @jsondata:Name {value: "ticket_id"} + int ticketId?; + # An array of the events that happened in this audit. See the [Ticket Audit events reference](/documentation/ticketing/reference-guides/ticket-audit-events-reference) + record {}[] events?; + TicketAuditViaObject via?; }; -public type TicketMetricEventBaseObject record { - # Automatically assigned when the record is created - int? id?; - # The instance of the metric associated with the event. See [instance_id](#instance_id) - int? instance_id?; - # The metric being tracked - "agent_work_time"|"pausable_update_time"|"periodic_update_time"|"reply_time"|"requester_wait_time"|"resolution_time" metric?; - # Id of the associated ticket - int? ticket_id?; - # The time the event occurred - string? time?; - # The type of the metric event. See [Ticket metric event types reference](/documentation/ticketing/reference-guides/ticket-metric-event-types-reference) - "activate"|"pause"|"fulfill"|"apply_sla"|"breach"|"update_status"|"measure" 'type?; +# Represents the Headers record for the operation: ShowUserRelated +public type ShowUserRelatedHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type UserMergeByIdInput record { - int? id?; +# Represents the Headers record for the operation: ShowCustomObject +public type ShowCustomObjectHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AssigneeFieldAssignableGroupsAndAgentsSearchResponse record { - AssigneeFieldAssignableSearchAgentObject[]? agents?; - # Number of agents + groups listed from search result. - int? count?; - AssigneeFieldAssignableSearchGroupObject[]? groups?; +# Represents the Headers record for the operation: ListActiveViews +public type ListActiveViewsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example. +# See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example public type TimeBasedExportIncrementalTicketsResponse record { - int? count?; - boolean? end_of_stream?; - int? end_time?; - string? next_page?; - TicketObject[]? tickets?; -}; - -public type TargetYammer record { - string? group_id?; - string? token?; -}; - -public type AuditObject record { - int? author_id?; - string? created_at?; - AuditObject_events[]? events?; - int? id?; - record {}? metadata?; - int? ticket_id?; - # An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - ViaObject? via?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + TicketObject[] tickets?; + int count?; + @jsondata:Name {value: "end_time"} + int endTime?; +}; + +# Represents the Queries record for the operation: IncrementalUserExportTime +public type IncrementalUserExportTimeQueries record { + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; + # The number of records to return per page + @http:Query {name: "per_page"} + int perPage?; +}; + +public type EmailCCObjectAllOf2 record { + @jsondata:Name {value: "user_email"} + string userEmail?; + @jsondata:Name {value: "user_id"} + string userId?; + @jsondata:Name {value: "user_name"} + string userName?; + "put"|"delete" action?; }; public type TriggerCategoryBatchRequest record { - string? id; - int? position; + string id; + int position; }; -public type TicketObject_custom_fields record { - # The id of the custom field - int? id?; - # The value of the custom field - string? value?; +# Represents the Headers record for the operation: ShowWorkspace +public type ShowWorkspaceHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type OrganizationResponse record { - OrganizationObject? organization?; +public type TicketsCreateRequest record { + TicketCreateInput[] tickets?; }; -public type TargetCommonFields record { - # Whether or not the target is activated - boolean? active?; - # The time the target was created - string? created_at?; - # Automatically assigned when created - int? id?; - # A name for the target - string? title; - # A pre-defined target, such as "basecamp_target". See the additional attributes for the type that follow - string? 'type; +# Represents the Headers record for the operation: DeleteUserIdentity +public type DeleteUserIdentityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketsCreateRequest record { - TicketCreateInput[]? tickets?; +public type TriggersResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + TriggerObject[] triggers?; }; -public type Macros_macro_id_body record { - MacroInput? macro?; +# Represents the Headers record for the operation: GetRelationshipFilterDefinitions +public type GetRelationshipFilterDefinitionsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggersResponse record { - int? count?; - string? next_page?; - string? previous_page?; - TriggerObject[]? triggers?; +# Represents the Headers record for the operation: UpdateOrganization +public type UpdateOrganizationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TriggerCategoryRequestRequired record { }; +# Represents the Queries record for the operation: SearchMacro +public type SearchMacroQueries record { + # A sideload to include in the response. See [Sideloads](#sideloads-2) + string include?; + # Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins + string access?; + # Filter macros by group + @http:Query {name: "group_id"} + int groupId?; + # Query string used to find macros with matching titles + string query; + # Filter by active macros if true or inactive macros if false + boolean active?; + # If true, returns only macros that can be applied to tickets. If false, returns all macros the current user can manage. Default is false + @http:Query {name: "only_viewable"} + boolean onlyViewable?; + # Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical + @http:Query {name: "sort_by"} + string sortBy?; + # Filter macros by category + int category?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +# Represents the Headers record for the operation: SetOrganizationMembershipAsDefault +public type SetOrganizationMembershipAsDefaultHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + public type UserForAdmin record { - # false if the user has been deleted - boolean? active?; - # An alias displayed to end users - string? alias?; - # Whether or not the user is a chat-only agent - boolean? chat_only?; - # The time the user was created - string? created_at?; - # A custom role if the user is an agent on the Enterprise plan or above - int? custom_role_id?; - # The id of the user's default group - int? default_group_id?; - # Any details you want to store about the user, such as an address - string? details?; - # The user's primary email address. *Writeable on create only. On update, a secondary email is added. See [Email Address](#email-address) - string? email?; - # A unique identifier from another system. The API treats the id as case insensitive. Example: "ian1" and "IAN1" are the same value. - string? external_id?; - # The time zone for the user - string? iana_time_zone?; - # Automatically assigned when the user is created - int? id?; + # If the user is shared from a different Zendesk Support instance. Ticket sharing accounts only + boolean shared?; # Last time the user signed in to Zendesk Support or made an API request # using an API token or basic authentication - string? last_login_at?; - # The user's locale. A BCP-47 compliant tag for the locale. If both "locale" and "locale_id" are present on create or update, "locale_id" is ignored and only "locale" is used. - string? locale?; - # The user's language identifier - int? locale_id?; - # Designates whether the user has forum moderation capabilities - boolean? moderator?; - # The user's name - string? name; + @jsondata:Name {value: "last_login_at"} + string lastLoginAt?; # Any notes you want to store about the user - string? notes?; - # true if the user can only create private comments - boolean? only_private_comments?; - # The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](#organization-id) - int? organization_id?; - # The user's primary phone number. See [Phone Number](#phone-number) below - string? phone?; - # The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - record {}? photo?; - # A URL pointing to the user's profile picture. - string? remote_photo_url?; + string notes?; + # The user's role. Possible values are "end-user", "agent", or "admin" + string role?; + # The user's signature. Only agents and admins can have signatures + string signature?; + # A custom role if the user is an agent on the Enterprise plan or above + @jsondata:Name {value: "custom_role_id"} + int? customRoleId?; + # Designates whether the user has forum moderation capabilities + boolean moderator?; + # If the user is a shared agent from a different Zendesk Support instance. Ticket sharing accounts only + @jsondata:Name {value: "shared_agent"} + boolean sharedAgent?; + # The time the user was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # A unique identifier from another system. The API treats the id as case insensitive. Example: "ian1" and "IAN1" are the same value + @jsondata:Name {value: "external_id"} + string? externalId?; + # The user's locale. A BCP-47 compliant tag for the locale. If both "locale" and "locale_id" are present on create or update, "locale_id" is ignored and only "locale" is used + string locale?; + # The id of the user's default group + @jsondata:Name {value: "default_group_id"} + int defaultGroupId?; + # The user's language identifier + @jsondata:Name {value: "locale_id"} + int localeId?; + # A URL pointing to the user's profile picture + @jsondata:Name {value: "remote_photo_url"} + string remotePhotoUrl?; + # Values of custom fields in the user's profile. See [User Fields](#user-fields) + @jsondata:Name {value: "user_fields"} + record {} userFields?; + # The time the user was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; # This parameter is inert and has no effect. It may be deprecated in the # future. # @@ -880,802 +626,4707 @@ public type UserForAdmin record { # report in a legacy Guide dashboard. This dashboard has been removed. See # [Announcing Guide legacy reporting upgrade to # Explore](https://support.zendesk.com/hc/en-us/articles/4762263171610-Announcing-Guide-legacy-reporting-upgrade-to-Explore-) - boolean? report_csv?; + @jsondata:Name {value: "report_csv"} + boolean reportCsv?; + # An alias displayed to end users + string alias?; + # Any details you want to store about the user, such as an address + string details?; + # Automatically assigned when the user is created + int id?; + # The user's primary email address. *Writeable on create only. On update, a secondary email is added. See [Email Address](#email-address) + string email?; # If the agent has any restrictions; false for admins and unrestricted agents, true for other agents - boolean? restricted_agent?; - # The user's role. Possible values are "end-user", "agent", or "admin" - string? role?; + @jsondata:Name {value: "restricted_agent"} + boolean restrictedAgent?; + # If two factor authentication is enabled + @jsondata:Name {value: "two_factor_auth_enabled"} + boolean? twoFactorAuthEnabled?; # The user's role id. 0 for a custom agent, 1 for a light agent, 2 for a chat agent, 3 for a chat agent added to the Support account as a contributor ([Chat Phase 4](https://support.zendesk.com/hc/en-us/articles/360022365373#topic_djh_1zk_4fb)), 4 for an admin, and 5 for a billing admin - int? role_type?; - # If the user is shared from a different Zendesk Support instance. Ticket sharing accounts only - boolean? shared?; - # If the user is a shared agent from a different Zendesk Support instance. Ticket sharing accounts only - boolean? shared_agent?; + @jsondata:Name {value: "role_type"} + int? roleType?; + # true if the user can only create private comments + @jsondata:Name {value: "only_private_comments"} + boolean onlyPrivateComments?; + # The time zone for the user + @jsondata:Name {value: "iana_time_zone"} + string ianaTimeZone?; # Whether the `phone` number is shared or not. See [Phone Number](#phone-number) below - boolean? shared_phone_number?; - # The user's signature. Only agents and admins can have signatures - string? signature?; + @jsondata:Name {value: "shared_phone_number"} + boolean? sharedPhoneNumber?; + # Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) + boolean verified?; + # false if the user has been deleted + boolean active?; + # The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object + record {}? photo?; + # The user's time zone. See [Time Zone](#time-zone) + @jsondata:Name {value: "time_zone"} + string timeZone?; # If the agent is suspended. Tickets from suspended users are also suspended, and these users cannot sign in to the end user portal - boolean? suspended?; + boolean suspended?; + # The user's API url + string url?; # The user's tags. Only present if your account has user tagging enabled - string[]? tags?; + string[] tags?; + # The user's primary phone number. See [Phone Number](#phone-number) below + string? phone?; + # The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](#organization-id) + @jsondata:Name {value: "organization_id"} + int? organizationId?; + # The user's name + string name; + # Whether or not the user is a chat-only agent + @jsondata:Name {value: "chat_only"} + boolean chatOnly?; # Specifies which tickets the user has access to. Possible values are: "organization", "groups", "assigned", "requested", null. "groups" and "assigned" are valid only for agents. If you pass an invalid value to an end user (for example, "groups"), they will be assigned to "requested", regardless of their previous access - string? ticket_restriction?; - # The user's time zone. See [Time Zone](#time-zone) - string? time_zone?; - # If two factor authentication is enabled - boolean? two_factor_auth_enabled?; - # The time the user was last updated - string? updated_at?; - # The user's API url - string? url?; - # Values of custom fields in the user's profile. See [User Fields](#user-fields) - record {}? user_fields?; - # Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) - boolean? verified?; -}; - -public type BulkUpdateDefaultCustomStatusResponse record { + @jsondata:Name {value: "ticket_restriction"} + string? ticketRestriction?; }; public type TwitterChannelsResponse record { - TwitterChannelObject[]? monitored_twitter_handles?; + @jsondata:Name {value: "monitored_twitter_handles"} + TwitterChannelObject[] monitoredTwitterHandles?; }; public type UserRelatedObject record { - # Count of assigned tickets - int? assigned_tickets?; - # Count of collaborated tickets - int? ccd_tickets?; # Count of organization subscriptions - int? organization_subscriptions?; + @jsondata:Name {value: "organization_subscriptions"} + int organizationSubscriptions?; # Count of requested tickets - int? requested_tickets?; + @jsondata:Name {value: "requested_tickets"} + int requestedTickets?; + # Count of assigned tickets + @jsondata:Name {value: "assigned_tickets"} + int assignedTickets?; + # Count of collaborated tickets + @jsondata:Name {value: "ccd_tickets"} + int ccdTickets?; }; -# For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) -public type TicketObject_via record { - # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" - string? channel?; - # For some channels a source object gives more information about how or why the ticket or event was created - record {}? 'source?; +# Represents the Headers record for the operation: DeleteCustomObjectRecordByExternalId +public type DeleteCustomObjectRecordByExternalIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerBulkUpdateItem record { - # The active status of the trigger (true or false) - boolean? active?; - # The ID of the new category the trigger is to be moved to - string? category_id?; - # The ID of the trigger to update - int? id; - # The new position of the trigger - int? position?; +public type SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll record { + string subject?; + string title?; +}; + +# Represents the Headers record for the operation: RedactChatComment +public type RedactChatCommentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketFormResponse record { - TicketFormObject? ticket_form?; + @jsondata:Name {value: "ticket_form"} + TicketFormObject ticketForm?; }; -public type SuspendedTicketsExportResponse record { - SuspendedTicketsExportResponse_export? export?; +# Represents the Headers record for the operation: CreateTicketOrVoicemailTicket +public type CreateTicketOrVoicemailTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateCustomObjectRecord +public type UpdateCustomObjectRecordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketMetricObject record { - # Number of minutes the agent spent waiting during calendar and business hours - TicketMetricTimeObject?? agent_wait_time_in_minutes?; - # When the ticket was assigned - string? assigned_at?; + # Number of groups the ticket passed through + @jsondata:Name {value: "group_stations"} + int groupStations?; + # Number of minutes on hold + @jsondata:Name {value: "on_hold_time_in_minutes"} + TicketMetricTimeObject onHoldTimeInMinutes?; + # Total number of times the ticket was reopened + int reopens?; + # When the requester last updated the ticket + @jsondata:Name {value: "requester_updated_at"} + string requesterUpdatedAt?; + # Number of minutes to the first reply during calendar and business hours + @jsondata:Name {value: "reply_time_in_minutes"} + TicketMetricTimeObject replyTimeInMinutes?; # Number of assignees the ticket had - int? assignee_stations?; - # When the assignee last updated the ticket - string? assignee_updated_at?; + @jsondata:Name {value: "assignee_stations"} + int assigneeStations?; # When the record was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # The date and time the ticket's custom status was last updated - string? custom_status_updated_at?; - # Number of minutes to the first resolution time during calendar and business hours - TicketMetricTimeObject?? first_resolution_time_in_minutes?; - # Number of minutes to the full resolution during calendar and business hours - TicketMetricTimeObject?? full_resolution_time_in_minutes?; - # Number of groups the ticket passed through - int? group_stations?; - # Automatically assigned when the client is created - int? id?; + @jsondata:Name {value: "custom_status_updated_at"} + string customStatusUpdatedAt?; + # Id of the associated ticket + @jsondata:Name {value: "ticket_id"} + int ticketId?; + # The API url of the ticket metric + string url?; # When the ticket was initially assigned - string? initially_assigned_at?; + @jsondata:Name {value: "initially_assigned_at"} + string initiallyAssignedAt?; # When the latest comment was added - string? latest_comment_added_at?; - # Number of minutes on hold - TicketMetricTimeObject?? on_hold_time_in_minutes?; - # Total number of times the ticket was reopened - int? reopens?; + @jsondata:Name {value: "latest_comment_added_at"} + string latestCommentAddedAt?; # The number of public replies added to a ticket by an agent - int? replies?; - # Number of minutes to the first reply during calendar and business hours - TicketMetricTimeObject?? reply_time_in_minutes?; + int replies?; + # When the record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # When the ticket was solved + @jsondata:Name {value: "solved_at"} + string solvedAt?; + # When the ticket was assigned + @jsondata:Name {value: "assigned_at"} + string assignedAt?; + # Automatically assigned when the client is created + int id?; + # Number of minutes the agent spent waiting during calendar and business hours + @jsondata:Name {value: "agent_wait_time_in_minutes"} + TicketMetricTimeObject agentWaitTimeInMinutes?; + # Number of minutes to the full resolution during calendar and business hours + @jsondata:Name {value: "full_resolution_time_in_minutes"} + TicketMetricTimeObject fullResolutionTimeInMinutes?; # Number of seconds to the first reply during calendar hours, only available for Messaging tickets - TicketMetricTimeObject?? reply_time_in_seconds?; - # When the requester last updated the ticket - string? requester_updated_at?; + @jsondata:Name {value: "reply_time_in_seconds"} + TicketMetricTimeObject replyTimeInSeconds?; # Number of minutes the requester spent waiting during calendar and business hours - TicketMetricTimeObject?? requester_wait_time_in_minutes?; - # When the ticket was solved - string? solved_at?; + @jsondata:Name {value: "requester_wait_time_in_minutes"} + TicketMetricTimeObject requesterWaitTimeInMinutes?; + # Number of minutes to the first resolution time during calendar and business hours + @jsondata:Name {value: "first_resolution_time_in_minutes"} + TicketMetricTimeObject firstResolutionTimeInMinutes?; + # When the assignee last updated the ticket + @jsondata:Name {value: "assignee_updated_at"} + string assigneeUpdatedAt?; # When the status of the ticket was last updated - string? status_updated_at?; - # Id of the associated ticket - int? ticket_id?; - # When the record was last updated - string? updated_at?; - # The API url of the ticket metric - string? url?; + @jsondata:Name {value: "status_updated_at"} + string statusUpdatedAt?; }; public type CountOrganizationResponse record { - CountOrganizationObject? count?; + CountOrganizationObject count?; }; -public type Problems_autocomplete_body record { - # The text to search for - string? text?; +# Represents the Headers record for the operation: DeleteSuspendedTickets +public type DeleteSuspendedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Inline_response_200_5 record { - ActivitiesCountResponse_count? count?; +# Represents the Headers record for the operation: ListTicketFollowers +public type ListTicketFollowersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Inline_response_200_6 record { - *TriggerCategoriesResponse; - *Pagination; +# Represents the Headers record for the operation: ExecuteView +public type ExecuteViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; +public type GroupSLAPolicyFilterConditionObjectValue ValueOneOf1|ValueValueOneOf12; + public type TicketSkipCreation record { - TicketSkipObject? skip?; + TicketSkipObject skip?; +}; + +public type UserInput UserCreateInput|UserMergePropertiesInput|UserMergeByIdInput; + +# Represents the Headers record for the operation: UpdateMacro +public type UpdateMacroHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteUserFieldOption +public type DeleteUserFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListDeletedTickets +public type ListDeletedTicketsQueries record { + # Sort by + @http:Query {name: "sort_by"} + "id"|"subject"|"deleted_at" sortBy?; + # Sort order. Defaults to "asc" + @http:Query {name: "sort_order"} + "asc"|"desc" sortOrder?; }; -public type UserInput UserCreateInput|UserMergePropertiesInput|UserMergeByIdInput?; +# Represents the Queries record for the operation: SearchAutomations +public type SearchAutomationsQueries record { + # A sideload to include in the response. See [Sideloads](#sideloads-2) + string include?; + # Query string used to find all automations with matching title + string query; + # Filter by active automations if true or inactive automations if false + boolean active?; + # Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the automations are sorted by relevance + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; public type TicketAuditsCountResponse record { - ActivitiesCountResponse_count? count?; + ActivitiesCountResponseCount count?; }; # Ticket sharing partners settings. See [Ticket Sharing Partners](#ticket-sharing-partners) public type AccountSettingsTicketSharingPartnersObject record { - string[]? support_addresses?; + @jsondata:Name {value: "support_addresses"} + string[] supportAddresses?; +}; + +# Represents the Headers record for the operation: DeleteGroupSLAPolicy +public type DeleteGroupSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type ExportIncrementalOrganizationsResponse record { - int? count?; - boolean? end_of_stream?; - int? end_time?; - string? next_page?; - OrganizationObject[]? organizations?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + int count?; + @jsondata:Name {value: "end_time"} + int endTime?; + OrganizationObject[] organizations?; }; public type OffsetPaginationObject record { - # the total record count - int? count?; # the URL of the next page - string? next_page?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + # the total record count + int count?; # the URL of the previous page - string? previous_page?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +# Represents the Headers record for the operation: RestoreDeletedTicket +public type RestoreDeletedTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type OrganizationFieldResponse record { - OrganizationFieldObject? organization_field?; + @jsondata:Name {value: "organization_field"} + OrganizationFieldObject organizationField?; }; # Account statistics settings. See [Statistics](#statistics) public type AccountSettingsStatisticsObject record { - boolean? forum?; - boolean? rule_usage?; - boolean? search?; -}; - -# Account limits configuration. See [Limits](#limits) -public type AccountSettingsLimitsObject record { - int? attachment_size?; -}; - -public type Inline_response_200_3 record { - record {}[]? actions?; + boolean forum?; + boolean search?; + @jsondata:Name {value: "rule_usage"} + boolean ruleUsage?; }; -public type Inline_response_200_4 record { - Inline_response_200_3? definitions?; -}; - -public type Inline_response_200_1 record { - record {|Inline_response_200_1_count?...;|}? count?; +# Represents the Queries record for the operation: UpsertCustomObjectRecord +public type UpsertCustomObjectRecordQueries record { + # The external id of a custom object record + @http:Query {name: "external_id"} + string externalId; }; public type TriggerActionObject record { - string? 'field?; - string|int|(string|int?)[]? value?; -}; - -public type Inline_response_200_2 record { - MacroObject? macro?; + string 'field?; + string|int|(string|int)[] value?; }; public type SharingAgreementObject record { - # The time the record was created - string? created_at?; - # Automatically assigned upon creation - int? id?; - # Name of this sharing agreement - string? name?; # Can be one of the following: "jira", null - string? partner_name?; + @jsondata:Name {value: "partner_name"} + string? partnerName?; # Subdomain of the remote account or null if not associated with an account - string? remote_subdomain?; - # Can be one of the following: "accepted", "declined", "pending", "inactive", "failed", "ssl_error", "configuration_error" - string? status?; + @jsondata:Name {value: "remote_subdomain"} + string remoteSubdomain?; + # Name of this sharing agreement + string name?; + # The time the record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned upon creation + int id?; # Can be one of the following: "inbound", "outbound" - string? 'type?; + string 'type?; # URL of the sharing agreement record - string? url?; + string url?; + # Can be one of the following: "accepted", "declined", "pending", "inactive", "failed", "ssl_error", "configuration_error" + string status?; +}; + +public type ListDeletedTicketsResponseActor record { + string name?; + int id?; +}; + +# Represents the Headers record for the operation: ListAGentAttributeValues +public type ListAGentAttributeValuesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type MacroCommonObject record { - # Each action describes what the macro will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) - ActionObject[]? actions; + # If true, the macro is a default macro + boolean default?; + # The time of the last update of the macro + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Access to this macro. A null value allows unrestricted access for all users in the account + record {}? restriction?; # Useful for determining if the macro should be displayed - boolean? active?; + boolean active?; # The time the macro was created - string? created_at?; - # If true, the macro is a default macro - boolean? default?; + @jsondata:Name {value: "created_at"} + string createdAt?; # The description of the macro string? description?; # The ID automatically assigned when a macro is created - int? id?; + int id?; # The position of the macro - int? position?; - # Access to this macro. A null value allows unrestricted access for all users in the account - record {}? restriction?; + int position?; # The title of the macro - string? title; - # The time of the last update of the macro - string? updated_at?; + string title; + # Each action describes what the macro will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) + ActionObject[] actions; # A URL to access the macro's details - string? url?; + string url?; +}; + +public type OrganizationFieldObject CustomFieldObject; + +# Represents the Headers record for the operation: DeleteAttribute +public type DeleteAttributeHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type OrganizationFieldObject CustomFieldObject?; +# Represents the Headers record for the operation: DeleteDynamicContentItem +public type DeleteDynamicContentItemHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; public type TriggerActionDefinitionObject record { - string? group?; - boolean? nullable?; - boolean? repeatable?; - string? subject?; - string? title?; - string? 'type?; - DefinitionsResponse_definitions_values[]? values?; + boolean nullable?; + boolean repeatable?; + string subject?; + DefinitionsResponseDefinitionsValues[] values?; + string title?; + string 'type?; + string group?; }; -public type SLAPolicyFilterDefinitionResponse_definitions_values record { - SLAPolicyFilterDefinitionResponse_definitions_values_list[]? list?; - string? 'type?; +# Represents the Headers record for the operation: PermanentlyDeleteUser +public type PermanentlyDeleteUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type EmailCCObject record { - *FollowerObject; - "put"|"delete" action?; - string? user_email?; - string? user_id?; - string? user_name?; +# Represents the Queries record for the operation: ListGroups +public type ListGroupsQueries record { + # Whether to exclude deleted entities + @http:Query {name: "exclude_deleted"} + boolean excludeDeleted?; }; -# Who may access this macro. Will be null when everyone in the account can access it -public type MacroInput_restriction record { - # The numeric ID of the group or user - int? id?; - # The numeric IDs of the groups - int[]? ids?; - # Allowed values are Group or User - string? 'type?; +public type EmailCCObject record { + *FollowerObject; + *EmailCCObjectAllOf2; }; -public type GroupMembershipsResponse record { - GroupMembershipObject[]? group_memberships?; +# Represents the Headers record for the operation: ListTicketAttributeValues +public type ListTicketAttributeValuesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerBulkUpdateRequest record { - TriggerBulkUpdateItem[]? triggers?; +public type GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators record { + string title?; + string value?; }; -public type ViewExportResponse_export record { - string? status?; - int? view_id?; +# Represents the Headers record for the operation: DeleteQueue +public type DeleteQueueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SLAPolicyFilterConditionObject record { - # The name of a ticket field - string? 'field?; - # A comparison operator - string? operator?; - # The value of a ticket field - string|(string|int?)[]? value?; +# Represents the Headers record for the operation: ShowView +public type ShowViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type ChannelFrameworkResultObject record { # The external ID of the resource, as passed in - string? external_resource_id?; - # The status of the import for the indicated resource - ChannelFrameworkResultStatusObject? status?; + @jsondata:Name {value: "external_resource_id"} + string externalResourceId?; + ChannelFrameworkResultStatusObject status?; }; -# Billing configuration options. See [Billing](#billing) -public type AccountSettingsBillingObject record { - string? backend?; +# Represents the Headers record for the operation: UpdateOrganizationField +public type UpdateOrganizationFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AccountSettingsCdnObject_hosts record { - string? name?; - string? url?; +public type V2TriggerCategoriesBody record { + @jsondata:Name {value: "trigger_category"} + record {*TriggerCategoryRequest; *TriggerCategoryRequestRequired;} triggerCategory?; }; -public type CustomObjectField CustomFieldObject?; +public type TicketMetricEventsResponseAllOf1 record { + @jsondata:Name {value: "ticket_metric_events"} + TicketMetricEventBaseObject[] ticketMetricEvents?; +}; -public type CustomStatusCreateInput record { - *CustomStatusUpdateInput; - # The status category the custom ticket status belongs to - "new"|"open"|"pending"|"hold"|"solved" status_category?; +# Represents the Headers record for the operation: ShowOrganizationMembershipById +public type ShowOrganizationMembershipByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomObjectField CustomFieldObject; + +# Represents the Headers record for the operation: ShowAttribute +public type ShowAttributeHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomObjectRecord record { - # The time the object was created - string? created_at?; - # Id of a user who created the object - string? created_by_user_id?; - record {}? custom_object_fields?; + # The time of the last update of the object + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Id of the last user who updated the object + @jsondata:Name {value: "updated_by_user_id"} + string updatedByUserId?; # A user-defined unique identifier - string? custom_object_key?; + @jsondata:Name {value: "custom_object_key"} + string customObjectKey?; + # User-defined display name for the object + string name; + # The time the object was created + @jsondata:Name {value: "created_at"} + string createdAt?; # An id you can use to link custom object records to external data - string? external_id?; + @jsondata:Name {value: "external_id"} + string? externalId?; + @jsondata:Name {value: "custom_object_fields"} + record {} customObjectFields?; # Automatically assigned upon creation - string? id?; - # User-defined display name for the object - string? name; - # The time of the last update of the object - string? updated_at?; - # Id of the last user who updated the object - string? updated_by_user_id?; + string id?; + # Id of a user who created the object + @jsondata:Name {value: "created_by_user_id"} + string createdByUserId?; # Direct link to the specific custom object - string? url?; + string url?; }; -public type TriggerCategoryRequest record { - string? name?; - int? position?; +# Represents the Queries record for the operation: AutocompleteTags +public type AutocompleteTagsQueries record { + # A substring of a tag to search for + string name?; }; -# An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) -public type ViaObject record { - # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" - string? channel?; - # For some channels a source object gives more information about how or why the ticket or event was created - ViaObject_source? 'source?; +# Represents the Headers record for the operation: RetrieveResourceCollection +public type RetrieveResourceCollectionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomStatusResponse record { - CustomStatusObject? custom_status?; +# Represents the Headers record for the operation: UpdateResourceCollection +public type UpdateResourceCollectionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Trigger_categories_trigger_category_id_body record { - TriggerCategoryRequest? trigger_category?; +public type TriggerCategoryRequest record { + string name?; + int position?; }; -public type TicketCreateVoicemailTicketInput record { - TicketCommentObject? comment?; - # The urgency with which the ticket should be addressed. - "urgent"|"high"|"normal"|"low" priority?; - # Required for Create Ticket operation - 44|45|46 via_id?; - # Required if creating voicemail ticket - TicketCreateVoicemailTicketVoiceCommentInput?? voice_comment?; +public type CustomStatusResponse record { + @jsondata:Name {value: "custom_status"} + CustomStatusObject customStatus?; }; -public type TriggerConditionsDiffObject record { - TriggerConditionDiffObject[]? all?; - TriggerConditionDiffObject[]? 'any?; +public type BatchJobResponseResults record { + @jsondata:Name {value: "trigger_categories"} + TriggerCategory[] triggerCategories?; + TriggerObject[] triggers?; }; -public type UserFieldResponse record { - UserFieldObject? user_field?; +# Represents the Headers record for the operation: MakeUserIdentityPrimary +public type MakeUserIdentityPrimaryHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyObject record { - # The time the Group SLA policy was created - string? created_at?; - # The description of the Group SLA policy - string? description?; - # An object that describes the conditions a ticket must match for a Group SLA policy to be applied to the ticket. See [Filter](#filter). - GroupSLAPolicyFilterObject? filter; - # Automatically assigned when created - string? id?; - # Array of [policy metric](#policy-metric) objects - GroupSLAPolicyMetricObject[]? policy_metrics?; - # Position of the Group SLA policy. This position determines the order in which policies are matched to tickets. If not specified, the Group SLA policy is added at the last position - int? position?; - # The title of the Group SLA policy - string? title; - # The time of the last update of the Group SLA policy - string? updated_at?; - # URL of the Group SLA policy record - string? url?; +public type TicketCreateVoicemailTicketInput record { + # Required if creating voicemail ticket + @jsondata:Name {value: "voice_comment"} + TicketCreateVoicemailTicketVoiceCommentInput voiceComment?; + TicketCommentObject comment?; + # The urgency with which the ticket should be addressed + "urgent"|"high"|"normal"|"low" priority?; + # Required for Create Ticket operation + @jsondata:Name {value: "via_id"} + 44|45|46 viaId?; }; -public type TicketMetricTimeObject record { - # Time in business hours - int? business?; - # Time in calendar hours - int? calendar?; +public type UserFieldResponse record { + @jsondata:Name {value: "user_field"} + UserFieldObject userField?; }; public type TicketFieldObject record { - # Whether this field is available - boolean? active?; - # A description of the ticket field that only agents can see - string? agent_description?; - # If true, the field is shown to agents by default. If false, the field is hidden alongside infrequently used fields. Classic interface only - boolean? collapsed_for_agents?; - # The time the custom ticket field was created - string? created_at?; + # The dynamic content placeholder if present, or the `title` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_title"} + string rawTitle?; # Name of the app that created the ticket field, or a null value if no app created the ticket field - string? creator_app_name?; - # The id of the user that created the ticket field, or a value of "-1" if an app created the ticket field - int? creator_user_id?; + @jsondata:Name {value: "creator_app_name"} + string creatorAppName?; # Required and presented for a custom ticket field of type "multiselect" or "tagger" - CustomFieldOptionObject[]? custom_field_options?; - # List of customized ticket statuses. Only presented for a system ticket field of type "custom_status" - TicketFieldCustomStatusObject[]? custom_statuses?; + @jsondata:Name {value: "custom_field_options"} + CustomFieldOptionObject[] customFieldOptions?; + # Whether this field is visible to end users in Help Center + @jsondata:Name {value: "visible_in_portal"} + boolean visibleInPortal?; + # The time the custom ticket field was created + @jsondata:Name {value: "created_at"} + string createdAt?; # Describes the purpose of the ticket field to users - string? description?; + string description?; + # The title of the ticket field + string title; + # System or custom field type. Editable for custom field types and only on creation. See [Create Ticket Field](#create-ticket-field) + string 'type; + # If true, agents must enter a value in the field to change the ticket status to solved + boolean required?; # Whether this field is editable by end users in Help Center - boolean? editable_in_portal?; - # Automatically assigned when created - int? id?; - # The relative position of the ticket field on a ticket. Note that for accounts with ticket forms, positions are controlled by the different forms - int? position?; - # The dynamic content placeholder if present, or the `description` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_description?; - # The dynamic content placeholder if present, or the `title` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_title?; - # The dynamic content placeholder if present, or the "title_in_portal" value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_title_in_portal?; + @jsondata:Name {value: "editable_in_portal"} + boolean editableInPortal?; + # List of customized ticket statuses. Only presented for a system ticket field of type "custom_status" + @jsondata:Name {value: "custom_statuses"} + TicketFieldCustomStatusObject[] customStatuses?; + # The time the custom ticket field was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Presented for a system ticket field of type "tickettype", "priority" or "status" + @jsondata:Name {value: "system_field_options"} + SystemFieldOptionObject[] systemFieldOptions?; + # A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", or "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment" + @jsondata:Name {value: "relationship_target_type"} + string relationshipTargetType?; # For "regexp" fields only. The validation pattern for a field value to be deemed valid - string? regexp_for_validation?; + @jsondata:Name {value: "regexp_for_validation"} + string? regexpForValidation?; # A filter definition that allows your autocomplete to filter down results - record {}? relationship_filter?; - # A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", or "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment". - string? relationship_target_type?; - # If false, this field is a system field that must be present on all tickets - boolean? removable?; - # If true, agents must enter a value in the field to change the ticket status to solved - boolean? required?; - # If true, end users must enter a value in the field to create the request - boolean? required_in_portal?; - # For system ticket fields of type "priority" and "status". Defaults to 0. A "priority" sub type of 1 removes the "Low" and "Urgent" options. A "status" sub type of 1 adds the "On-Hold" option - int? sub_type_id?; - # Presented for a system ticket field of type "tickettype", "priority" or "status" - SystemFieldOptionObject[]? system_field_options?; + @jsondata:Name {value: "relationship_filter"} + record {} relationshipFilter?; + # Automatically assigned when created + int id?; # For "checkbox" fields only. A tag added to tickets when the checkbox field is selected string? tag?; - # The title of the ticket field - string? title; - # The title of the ticket field for end users in Help Center - string? title_in_portal?; - # System or custom field type. Editable for custom field types and only on creation. See [Create Ticket Field](#create-ticket-field) - string? 'type; - # The time the custom ticket field was last updated - string? updated_at?; + # The id of the user that created the ticket field, or a value of "-1" if an app created the ticket field + @jsondata:Name {value: "creator_user_id"} + int creatorUserId?; + # If true, the field is shown to agents by default. If false, the field is hidden alongside infrequently used fields. Classic interface only + @jsondata:Name {value: "collapsed_for_agents"} + boolean collapsedForAgents?; + # Whether this field is available + boolean active?; + # A description of the ticket field that only agents can see + @jsondata:Name {value: "agent_description"} + string agentDescription?; + # The dynamic content placeholder if present, or the "title_in_portal" value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_title_in_portal"} + string rawTitleInPortal?; + # The dynamic content placeholder if present, or the `description` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_description"} + string rawDescription?; # The URL for this resource - string? url?; - # Whether this field is visible to end users in Help Center - boolean? visible_in_portal?; + string url?; + # If true, end users must enter a value in the field to create the request + @jsondata:Name {value: "required_in_portal"} + boolean requiredInPortal?; + # If false, this field is a system field that must be present on all tickets + boolean removable?; + # For system ticket fields of type "priority" and "status". Defaults to 0. A "priority" sub type of 1 removes the "Low" and "Urgent" options. A "status" sub type of 1 adds the "On-Hold" option + @jsondata:Name {value: "sub_type_id"} + int subTypeId?; + # The relative position of the ticket field on a ticket. Note that for accounts with ticket forms, positions are controlled by the different forms + int position?; + # The title of the ticket field for end users in Help Center + @jsondata:Name {value: "title_in_portal"} + string titleInPortal?; +}; + +# Represents the Headers record for the operation: CountGroups +public type CountGroupsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteCustomObject +public type DeleteCustomObjectHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type RequestResponse record { + RequestObject request?; +}; + +# Represents the Headers record for the operation: UpdateTrigger +public type UpdateTriggerHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ComplianceDeletionStatusesResponse record { + @jsondata:Name {value: "compliance_deletion_statuses"} + ComplianceDeletionStatusObject[] complianceDeletionStatuses?; +}; + +public type TicketFieldCustomStatusObject record { + # If true, the custom status is set to default. If false, the custom status is set to non-default + boolean default?; + # The label displayed to end users + @jsondata:Name {value: "end_user_label"} + string endUserLabel?; + # The status category the custom ticket status belongs to + @jsondata:Name {value: "status_category"} + "new"|"open"|"pending"|"hold"|"solved" statusCategory?; + # The date and time at which the custom ticket status was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The description displayed to end users + @jsondata:Name {value: "end_user_description"} + string endUserDescription?; + # If true, if the custom status is set to active. If false, the custom status is set to inactive + boolean active?; + # The date and time at which the custom ticket status was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of when the user should select this custom ticket status + string description?; + # Automatically assigned when the custom ticket status is created + int id?; + # The label displayed to agents + @jsondata:Name {value: "agent_label"} + string agentLabel?; +}; + +public type AccountSettingsResponse record { + AccountSettingsObject settings?; +}; + +public type CustomObjectResponse record { + @jsondata:Name {value: "custom_object"} + CustomObject customObject?; +}; + +# X (formerly Twitter) settings. See [X](#x-formerly-twitter) +public type AccountSettingsTwitterObject record { + @jsondata:Name {value: "shorten_url"} + string shortenUrl?; +}; + +public type AssigneeFieldAssignableGroupAgentsResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + # Number of agents listed in `agents` property + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + AssigneeFieldAssignableAgentObject[] agents?; +}; + +public type SkillBasedRoutingAttributeDefinitions record { + SkillBasedRoutingAttributeDefinitionsDefinitions definitions?; +}; + +public type CustomRoleResponse record { + @jsondata:Name {value: "custom_role"} + CustomRoleObject customRole?; +}; + +public type UsersRequest record { + UserInput[] users; +}; + +public type ListTicketFollowersResponse record { +}; + +public type AttachmentUpdateRequest record { + AttachmentUpdateInput attachment?; +}; + +public type DynamicContentResponse record { + DynamicContentObject item?; +}; + +public type UserForEndUser record { + # The role of the user. Possible values: `"end-user"`, `"agent"`, `"admin"` + string role?; + # The time zone for the user + @jsondata:Name {value: "iana_time_zone"} + string ianaTimeZone?; + # Whether the `phone` number is shared or not. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API + @jsondata:Name {value: "shared_phone_number"} + boolean sharedPhoneNumber?; + # Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) + boolean verified?; + # The time the user was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object + record {} photo?; + # The locale for this user + string locale?; + # The time-zone of this user + @jsondata:Name {value: "time_zone"} + string timeZone?; + # The API url of this user + string url?; + # The language identifier for this user + @jsondata:Name {value: "locale_id"} + int localeId?; + # The time of the last update of the user + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The primary phone number of this user. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API + string phone?; + # The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](/api-reference/ticketing/users/users/#organization-id) + @jsondata:Name {value: "organization_id"} + int organizationId?; + # The name of the user + string name; + # Automatically assigned when creating users + int id?; + # The primary email address of this user. If the primary email address is not [verified](https://support.zendesk.com/hc/en-us/articles/4408886752410), the secondary email address is used + string email?; +}; + +public type BrandUpdateRequest record { + BrandObject brand?; +}; + +# Represents the Headers record for the operation: UpdateTicketField +public type UpdateTicketFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListUserFieldOptions +public type ListUserFieldOptionsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# An object that describes the conditions a ticket must match for a Group SLA policy to be applied to the ticket. See [Filter](#filter) +public type GroupSLAPolicyFilterObject record { + GroupSLAPolicyFilterConditionObject[] all?; +}; + +# Represents the Headers record for the operation: ShowSuspendedTickets +public type ShowSuspendedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TwitterChannelObject record { + # If replies are allowed for this handle + @jsondata:Name {value: "can_reply"} + boolean canReply?; + # The country's code + @jsondata:Name {value: "twitter_user_id"} + int twitterUserId; + # The profile image url of the handle + @jsondata:Name {value: "avatar_url"} + string avatarUrl?; + # The time of the last update of the handle + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The Twitter handle + @jsondata:Name {value: "screen_name"} + string screenName; + # If replies are allowed for this handle + @jsondata:Name {value: "allow_reply"} + boolean allowReply?; + # The profile name of the handle + string name?; + # The time the handle was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned upon creation + int id; + # What brand the handle is associated with + @jsondata:Name {value: "brand_id"} + int brandId?; +}; + +public type GroupSLAPolicyFilterConditionObject record { + # The name of a ticket field + string 'field?; + # The value of a ticket field + GroupSLAPolicyFilterConditionObjectValue[] value?; + # A comparison operator + string operator?; +}; + +# Conditions when queue could be applied +public type QueueObjectDefinition record { + QueueObjectDefinitionAll[] all?; + QueueObjectDefinitionAll[] 'any?; +}; + +public type SharingAgreementResponse record { + @jsondata:Name {value: "sharing_agreement"} + SharingAgreementObject sharingAgreement?; +}; + +# Represents the Queries record for the operation: DeleteSuspendedTickets +public type DeleteSuspendedTicketsQueries record { + # A comma separated list of ids of suspended tickets to delete + string ids; +}; + +# Represents the Headers record for the operation: BulkDeleteSessionsByUserId +public type BulkDeleteSessionsByUserIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomObjectRecordsResponseLinks record { + string? next; + string? prev; +}; + +public type QueueObject record { + # The time of the queue's last update + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Primary group ids linked to the queue + @jsondata:Name {value: "primary_groups"} + QueueObjectPrimaryGroups primaryGroups?; + # The name of the queue + string name?; + # The time the queue was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the queue + string description?; + # Conditions when queue could be applied + QueueObjectDefinition definition?; + # Automatically assigned when creating queue + string id?; + # The queue-applied priority + int priority?; + # The API URL of the queue + string url?; + # The queue-applied order + int 'order?; + # Secondary group ids linked to the queue + @jsondata:Name {value: "secondary_groups"} + QueueObjectSecondaryGroups secondaryGroups?; +}; + +public type TriggerWithCategoryRequest record { + TriggerObject trigger?; +}; + +public type MacroApplyTicketResponseResultTicket record { + @jsondata:Name {value: "group_id"} + int groupId?; + MacroApplyTicketResponseResultTicketComment comment?; + int id?; + MacroApplyTicketResponseResultTicketFields fields?; + string url?; + @jsondata:Name {value: "assignee_id"} + int assigneeId?; +}; + +# Represents the Queries record for the operation: IncrementalOrganizationExport +public type IncrementalOrganizationExportQueries record { + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; +}; + +# Represents the Headers record for the operation: ShowManyUsers +public type ShowManyUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomStatusUpdateRequest record { + @jsondata:Name {value: "custom_status"} + CustomStatusUpdateInput customStatus?; +}; + +# Represents the Headers record for the operation: UpdateDynamicContentItem +public type UpdateDynamicContentItemHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: DeleteManyTriggers +public type DeleteManyTriggersQueries record { + # A comma separated list of trigger IDs + string ids; +}; + +public type ViewObject record { + # Describes how the view should be executed. See [Execution](#execution) + record {} execution?; + # If true, the view is a default view + boolean default?; + # The time the view was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Who may access this account. Is null when everyone in the account can access it + record {} restriction?; + # Whether the view is active + boolean active?; + # The time the view was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the view + string description?; + # Automatically assigned when created + int id?; + # The position of the view + int position?; + # Describes how the view is constructed. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) + record {} conditions?; + # The title of the view + string title?; +}; + +# Represents the Headers record for the operation: ListActivities +public type ListActivitiesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: CreateManyDynamicContentVariants +public type CreateManyDynamicContentVariantsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: UpdateManyOrganizations +public type UpdateManyOrganizationsQueries record { + # A list of organization ids + string ids?; + # A list of external ids + @http:Query {name: "external_ids"} + string externalIds?; +}; + +public type OrganizationsRelatedResponse record { + @jsondata:Name {value: "organization_related"} + OrganizationMetadataObject organizationRelated?; +}; + +# Represents the Headers record for the operation: UpdateManyOrganizations +public type UpdateManyOrganizationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type GroupSLAPoliciesResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "group_sla_policies"} + GroupSLAPolicyObject[] groupSlaPolicies?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +# Represents the Headers record for the operation: ShowAttachment +public type ShowAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# API configuration options. See [API](#api) +public type AccountSettingsApiObject record { + @jsondata:Name {value: "api_token_access"} + string apiTokenAccess?; + @jsondata:Name {value: "accepted_api_agreement"} + boolean acceptedApiAgreement?; + @jsondata:Name {value: "api_password_access"} + string apiPasswordAccess?; +}; + +# Represents the Queries record for the operation: ShowDerivedMacro +public type ShowDerivedMacroQueries record { + # The ID of the macro to replicate + @http:Query {name: "macro_id"} + int macroId; + # The ID of the ticket from which to build a macro replica + @http:Query {name: "ticket_id"} + int ticketId; +}; + +# Represents the Headers record for the operation: ListAttributeValues +public type ListAttributeValuesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: IncrementalOrganizationExport +public type IncrementalOrganizationExportHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ShowUserComplianceDeletionStatuses +public type ShowUserComplianceDeletionStatusesQueries record { + # Area of compliance + string application?; +}; + +public type UsersResponse record { + UserObject[] users?; +}; + +public type OrganizationSubscriptionsResponseAllOf2 record { + # An array of organization subscriptions + @jsondata:Name {value: "organization_subscriptions"} + OrganizationSubscriptionObject[] organizationSubscriptions?; +}; + +# Represents the Queries record for the operation: ReorderGroupSLAPolicies +public type ReorderGroupSLAPoliciesQueries record { + # The ids of the Group SLA policies to reorder + @http:Query {name: "group_sla_policy_ids"} + string[] groupSlaPolicyIds?; +}; + +public type PushNotificationDevicesRequest record { + @jsondata:Name {value: "push_notification_devices"} + PushNotificationDevicesInput pushNotificationDevices?; +}; + +public type GroupSLAPolicyFilterDefinitionResponseDefinitionsAll record { + GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators[] operators?; + GroupSLAPolicyFilterDefinitionResponseDefinitionsValues values?; + string title?; + string value?; + string group?; +}; + +# Represents the Headers record for the operation: CreateOrUpdateUserFieldOption +public type CreateOrUpdateUserFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomStatusCreateRequest record { + @jsondata:Name {value: "custom_status"} + CustomStatusCreateInput customStatus?; +}; + +# An object that describes the conditions that a ticket must match in order for an SLA policy to be applied to that ticket. See [Filter](#filter) +public type SLAPolicyFilterObject record { + SLAPolicyFilterConditionObject[] all?; + SLAPolicyFilterConditionObject[] 'any?; +}; + +# Represents the Headers record for the operation: ShowActivity +public type ShowActivityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: VerifySupportAddressForwarding +public type VerifySupportAddressForwardingHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type AssigneeFieldAssignableSearchAgentObject record { + # Agent's Group ID + @jsondata:Name {value: "group_id"} + int groupId?; + # Name of the agent + string name?; + # Agent ID + int id?; + # URL of Avatar + @jsondata:Name {value: "photo_url"} + string? photoUrl?; + # Name of the agent's group + string group?; +}; + +# Represents the Headers record for the operation: ShowDynamicContentVariant +public type ShowDynamicContentVariantHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteManyTriggers +public type DeleteManyTriggersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Primary group ids linked to the queue +public type QueueObjectPrimaryGroups record { + int count?; + ListDeletedTicketsResponseActor[] groups?; +}; + +# Represents the Headers record for the operation: UpdateSupportAddress +public type UpdateSupportAddressHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: TicketBulkImport +public type TicketBulkImportQueries record { + # If `true`, any ticket created with a `closed` status bypasses the normal ticket lifecycle and will be created directly in your ticket archive + @http:Query {name: "archive_immediately"} + boolean archiveImmediately?; +}; + +# Represents the Headers record for the operation: DeleteTarget +public type DeleteTargetHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateTicket +public type UpdateTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type AuditLogResponse record { + @jsondata:Name {value: "audit_log"} + AuditLogObject auditLog?; +}; + +# Represents the Headers record for the operation: SearchOrganizations +public type SearchOrganizationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ResourceCollectionResponse record { + @jsondata:Name {value: "resource_collection"} + ResourceCollectionObject resourceCollection?; +}; + +public type SystemFieldOptionObject record { + # Name of the system field option + string name?; + # Value of the system field option + string value?; +}; + +public type AuditLogsResponse record { + @jsondata:Name {value: "audit_logs"} + AuditLogObject[] auditLogs?; +}; + +public type TagListTagObject record { + # The number of tags + int count?; + # A name for the tag + string name?; +}; + +public type CurrentUserResponse record { + UserObject user?; +}; + +public type ViewResponse record { + ViewObject view?; + record {}[] columns?; + record {}[] groups?; + record {}[] rows?; +}; + +public type UserIdentitiesResponse record { + UserIdentityObject[] identities?; +}; + +# Represents the Headers record for the operation: UpdateTicketForm +public type UpdateTicketFormHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerResponse record { + TriggerObject trigger?; +}; + +public type DynamicContentObject record { + # Indicates the item has outdated variants within it + boolean outdated?; + # When this record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The default locale for the item. Must be one of the [locales the account has active](/api-reference/ticketing/account-configuration/locales/#list-locales) + @jsondata:Name {value: "default_locale_id"} + int defaultLocaleId; + # The unique name of the item + string name; + # When this record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when creating items + int id?; + # Automatically generated placeholder for the item, derived from name + string placeholder?; + # All variants within this item. See [Dynamic Content Item Variants](/api-reference/ticketing/ticket-management/dynamic_content_item_variants/) + DynamicContentVariantObject[] variants; + # The API url of this item + string url?; +}; + +# Represents the Headers record for the operation: UpdateGroup +public type UpdateGroupHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type RequestObject record { + # The ids of users who are currently email CCs on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center + @jsondata:Name {value: "email_cc_ids"} + int[] emailCcIds?; + # The value of the subject field for this request if the subject field is visible to end users; a truncated version of the description otherwise + string subject; + # When this record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The custom ticket status id of the ticket + @jsondata:Name {value: "custom_status_id"} + int customStatusId?; + # Read-only first comment on the request. When [creating a request](#create-request), use `comment` to set the description + string description?; + # Whether or not request is solved (an end user can set this if "can_be_solved_by_me", above, is true for that user) + boolean solved?; + # The type of the request, "question", "incident", "problem", "task" + string 'type?; + TicketAuditViaObject via?; + # When this record last got updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # When the task is due (only applies if the request is of type "task") + @jsondata:Name {value: "due_at"} + string dueAt?; + # Automatically assigned when creating requests + int id?; + # The id of the assignee if the field is visible to end users + @jsondata:Name {value: "assignee_id"} + int assigneeId?; + # Custom fields for the request. See [Setting custom field values](/api-reference/ticketing/tickets/tickets/#setting-custom-field-values) in the Tickets doc + @jsondata:Name {value: "custom_fields"} + MacroApplyTicketResponseResultTicketFields[] customFields?; + # The ids of users currently CC'ed on the ticket + @jsondata:Name {value: "collaborator_ids"} + int[] collaboratorIds?; + # The priority of the request, "low", "normal", "high", "urgent" + string priority?; + # The API url of this request + string url?; + # The numeric id of the ticket form associated with this request if the form is visible to end users - only applicable for enterprise accounts + @jsondata:Name {value: "ticket_form_id"} + int ticketFormId?; + # The id of the original ticket if this request is a follow-up ticket. See [Create Request](#create-request) + @jsondata:Name {value: "followup_source_id"} + int followupSourceId?; + # The id of the assigned group if the field is visible to end users + @jsondata:Name {value: "group_id"} + int groupId?; + # If true, an end user can mark the request as solved. See [Update Request](/api-reference/ticketing/tickets/ticket-requests/#update-request) + @jsondata:Name {value: "can_be_solved_by_me"} + boolean canBeSolvedByMe?; + # The organization of the requester + @jsondata:Name {value: "organization_id"} + int organizationId?; + # Is true if any comments are public, false otherwise + @jsondata:Name {value: "is_public"} + boolean isPublic?; + # The original recipient e-mail address of the request + string recipient?; + # The id of the requester + @jsondata:Name {value: "requester_id"} + int requesterId?; + # The state of the request, "new", "open", "pending", "hold", "solved", "closed" + string status?; +}; + +public type TicketAuditsResponse record { + @jsondata:Name {value: "before_url"} + string beforeUrl?; + @jsondata:Name {value: "after_cursor"} + string afterCursor?; + @jsondata:Name {value: "after_url"} + string afterUrl?; + @jsondata:Name {value: "before_cursor"} + string beforeCursor?; + TicketAuditObject[] audits?; +}; + +# Represents the Headers record for the operation: AutocompleteProblems +public type AutocompleteProblemsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListTicketFields +public type ListTicketFieldsQueries record { + # Displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created + # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field + # is not created by an app, `creator_app_name` is null + boolean creator?; + # Forces the `title_in_portal` property to return a dynamic content variant for the specified locale. + # Only accepts [active locale ids](/api-reference/ticketing/account-configuration/locales/#list-locales). + # Example: `locale="de"` + string locale?; +}; + +public type OrganizationMembershipsResponse record { + @jsondata:Name {value: "organization_memberships"} + OrganizationMembershipObject[] organizationMemberships?; +}; + +# Represents the Headers record for the operation: GetTrigger +public type GetTriggerHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ShowManyTicketForms +public type ShowManyTicketFormsQueries record { + # true returns the ticket forms of the brand specified by the url's subdomain + @http:Query {name: "associated_to_brand"} + boolean associatedToBrand?; + # true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both + @http:Query {name: "end_user_visible"} + boolean endUserVisible?; + # IDs of the ticket forms to be shown + string ids; + # true returns active ticket forms; false returns inactive ticket forms. If not present, returns both + boolean active?; + # true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms + @http:Query {name: "fallback_to_default"} + boolean fallbackToDefault?; +}; + +# Represents the Headers record for the operation: ShowGroupById +public type ShowGroupByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TagCountObject record { + # The time that the count value was last refreshed + @jsondata:Name {value: "refreshed_at"} + string refreshedAt?; + # The count of tags created in the last 24 hours + int value?; +}; + +public type AttachmentThumbnails record { + # An array of attachment objects. Note that photo thumbnails do not have thumbnails + AttachmentBaseObject[] thumbnails?; +}; + +public type ResourceCollectionsResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "resource_collections"} + ResourceCollectionObject[] resourceCollections?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +# Represents the Queries record for the operation: ListTicketForms +public type ListTicketFormsQueries record { + # true returns the ticket forms of the brand specified by the url's subdomain + @http:Query {name: "associated_to_brand"} + boolean associatedToBrand?; + # true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both + @http:Query {name: "end_user_visible"} + boolean endUserVisible?; + # true returns active ticket forms; false returns inactive ticket forms. If not present, returns both + boolean active?; + # true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms + @http:Query {name: "fallback_to_default"} + boolean fallbackToDefault?; +}; + +public type JobStatusResponse record { + @jsondata:Name {value: "job_status"} + JobStatusObject jobStatus?; +}; + +public type ViewsResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + ViewObject[] views?; +}; + +# Represents the Queries record for the operation: ListRequests +public type ListRequestsQueries record { + # Possible values are "updated_at", "created_at" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc", "desc". Defaults to "asc" + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +public type SessionsResponse record { + SessionObject[] sessions?; +}; + +public type UserCreateInputIdentities record { + string 'type; + string value; +}; + +public type DynamicContentVariantResponse record { + DynamicContentVariantObject variant?; +}; + +# Represents the Headers record for the operation: DeleteOrganizationMembership +public type DeleteOrganizationMembershipHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListRequests +public type ListRequestsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BookmarksResponseAllOf2 record { + BookmarkObject[] bookmarks?; +}; + +public type ValueValueOneOf12 int; + +public type LocaleObject record { + # The ISO 8601 formatted date-time when the locale was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The name of the language + string name?; + # The ISO 8601 formatted date-time the locale was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The unique ID of the locale + int id?; + # The name of the locale + string locale?; + # The URL of the locale record + string url?; +}; + +public type AttachmentUploadResponse record { + AttachmentUploadResponseUpload upload?; +}; + +public type CreateResourceResult record { + # the index number of the resul + int index; + # the id of the new resource + int id; +}; + +public type V2WorkspacesBody record { + WorkspaceInput workspace?; +}; + +public type ActivityObject record { + # The full user record of the user responsible for the ticket activity. See [Users](/api-reference/ticketing/users/users/) + UserObject actor?; + # When the record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The id of the agent making the request + @jsondata:Name {value: "user_id"} + int userId?; + # The type of activity. Can be "tickets.assignment", "tickets.comment", or "tickets.priority_increase" + string verb?; + # When the record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The id of the user responsible for the ticket activity. An `actor_id` of "-1" is a Zendesk system user, such as an automations action + @jsondata:Name {value: "actor_id"} + int actorId?; + # Automatically assigned on creation + int id?; + # Description of the activity + string title?; + # The full user record of the agent making the request. See [Users](/api-reference/ticketing/users/users/) + UserObject user?; + # The API url of the activity + string url?; + # The content of the activity. Can be a ticket, comment, or change + record {} 'object?; + # The target of the activity, a ticket + record {} target?; +}; + +# Represents the Headers record for the operation: ListTicketFields +public type ListTicketFieldsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SLAPolicyFilterDefinitionResponseDefinitionsValues record { + SLAPolicyFilterDefinitionResponseDefinitionsValuesList[] list?; + string 'type?; +}; + +public type TwitterChannelResponse record { + @jsondata:Name {value: "monitored_twitter_handle"} + TwitterChannelObject monitoredTwitterHandle?; +}; + +# Represents the Headers record for the operation: ShowManyTicketForms +public type ShowManyTicketFormsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type IncrementalSkillBasedRoutingAttribute record { + # The name of the attribute + string name?; + # Automatically assigned when an attribute is created + string id?; + # The time the attribute was created, updated, or deleted + string time?; + # One of "create", "update", or "delete" + string 'type?; +}; + +public type ViewCountObject record { + # A pretty-printed text approximation of the view count + string pretty?; + # The id of the view + @jsondata:Name {value: "view_id"} + int viewId?; + # Only active views if true, inactive views if false, all views if null + boolean active?; + # false if the cached data is stale and the system is still loading and caching new data + boolean fresh?; + # The cached number of tickets in the view. Can also be null if the system is loading and caching new data. Not to be confused with 0 tickets + int? value?; + # The API url of the count + string url?; +}; + +# Represents the Headers record for the operation: MakeTicketCommentPrivateFromAudits +public type MakeTicketCommentPrivateFromAuditsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListTriggerCategories +public type ListTriggerCategoriesQueries record { + # Allowed sideloads + "rule_counts" include?; + # Pagination parameters + Page page?; + # Sort parameters + "position"|"-position"|"name"|"-name"|"created_at"|"-created_at"|"updated_at"|"-updated_at" sort?; +}; + +public type OrganizationObject record { + # End users in this organization are able to see each other's tickets + @jsondata:Name {value: "shared_tickets"} + boolean sharedTickets?; + # Any notes you have about the organization + string? notes?; + # The time the organization was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # A unique external id to associate organizations to an external record. The id is case-insensitive. For example, "company1" and "Company1" are considered the same + @jsondata:Name {value: "external_id"} + string? externalId?; + # The API url of this organization + string url?; + # An array of domain names associated with this organization + @jsondata:Name {value: "domain_names"} + string[] domainNames?; + # The tags of the organization + string[] tags?; + # Custom fields for this organization. See [Custom organization fields](/api-reference/ticketing/organizations/organizations/#custom-organization-fields) + @jsondata:Name {value: "organization_fields"} + record {}? organizationFields?; + # The time of the last update of the organization + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # New tickets from users in this organization are automatically put in this group + @jsondata:Name {value: "group_id"} + int? groupId?; + # A unique name for the organization + string name?; + # Any details obout the organization, such as the address + string? details?; + # Automatically assigned when the organization is created + int id?; + # End users in this organization are able to comment on each other's tickets + @jsondata:Name {value: "shared_comments"} + boolean sharedComments?; +}; + +public type LocaleResponse record { + LocaleObject locale?; +}; + +# Represents the Headers record for the operation: DeleteTicketForm +public type DeleteTicketFormHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type MacrosResponseAllOf1 record { + MacroObject[] macros?; +}; + +# Represents the Headers record for the operation: RecoverSuspendedTicket +public type RecoverSuspendedTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type WorkspaceResponseAllOf1 record { + WorkspaceObject[] workspaces?; +}; + +public type SupportAddressResponse record { + @jsondata:Name {value: "recipient_address"} + SupportAddressObject recipientAddress?; +}; + +public type SatisfactionRatingObject record { + # The reason for a bad rating given by the requester in a follow-up question. Satisfaction reasons must be [enabled](https://support.zendesk.com/hc/en-us/articles/223152967) + string reason?; + # The time the satisfaction rating got created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The id of ticket being rated + @jsondata:Name {value: "ticket_id"} + int ticketId; + # The API url of this rating + string url?; + # id for the reason the user gave a negative rating. Can only be set on ratings with a `score` of "bad". To get a descriptive value for the id, use the [Show Reason for Satisfaction Rating](/api-reference/ticketing/ticket-management/satisfaction_reasons/#show-reason-for-satisfaction-rating) endpoint + @jsondata:Name {value: "reason_id"} + int reasonId?; + # The default reasons the user can select from a list menu for giving a negative rating. See [Reason codes](/api-reference/ticketing/ticket-management/satisfaction_reasons/#reason-codes) in the Satisfaction Reasons API. Can only be set on ratings with a `score` of "bad". Responses don't include this property + @jsondata:Name {value: "reason_code"} + int reasonCode?; + # The rating "offered", "unoffered", "good" or "bad" + string score; + # The time the satisfaction rating got updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The id of group assigned to at the time of rating + @jsondata:Name {value: "group_id"} + int groupId; + # The comment received with this rating, if available + string comment?; + # Automatically assigned upon creation + int id?; + # The id of agent assigned to at the time of rating + @jsondata:Name {value: "assignee_id"} + int assigneeId; + # The id of ticket requester submitting the rating + @jsondata:Name {value: "requester_id"} + int requesterId; +}; + +public type UserMergePropertiesInput record { + string password?; + @jsondata:Name {value: "organization_id"} + int organizationId?; + string name?; + string email?; +}; + +# Branding settings. See [Branding](#branding) +public type AccountSettingsBrandingObject record { + @jsondata:Name {value: "tab_background_color"} + string tabBackgroundColor?; + @jsondata:Name {value: "favicon_url"} + string? faviconUrl?; + @jsondata:Name {value: "header_color"} + string headerColor?; + @jsondata:Name {value: "page_background_color"} + string pageBackgroundColor?; + @jsondata:Name {value: "text_color"} + string textColor?; + @jsondata:Name {value: "header_logo_url"} + string? headerLogoUrl?; +}; + +# Represents the Queries record for the operation: SearchOrganizations +public type SearchOrganizationsQueries record { + # The name of an organization + string name?; + # The external id of an organization + @http:Query {name: "external_id"} + int externalId?; +}; + +# Represents the Queries record for the operation: ListTicketAudits +public type ListTicketAuditsQueries record { + # Maximum number of results returned + int 'limit?; +}; + +# Represents the Headers record for the operation: GetViewCount +public type GetViewCountHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type MacroCategoriesResponse record { + string[] categories?; +}; + +public type TicketMetricEventsResponseTicketMetricEventsResponseAllOf12 record { + @jsondata:Name {value: "next_page"} + string nextPage?; + int count?; + @jsondata:Name {value: "end_time"} + int endTime?; +}; + +public type GroupResponse record { + GroupObject group?; +}; + +# Represents the Headers record for the operation: OrganizationRelated +public type OrganizationRelatedHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SkillBasedRoutingAttributeValueObject record { + # When this record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Id of the associated attribute + @jsondata:Name {value: "attribute_id"} + string attributeId?; + # The name of the attribute value + string name?; + # When this record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when an attribute value is created + string id?; + # URL of the attribute value + string url?; +}; + +public type CustomObjectsCreateRequest record { + @jsondata:Name {value: "custom_object"} + CustomObjectCreateInput customObject?; +}; + +public type SuspendedTicketObject record { + # The attachments, if any associated to this suspended ticket. See [Attachments](/api-reference/ticketing/tickets/ticket-attachments/) + AttachmentObject[]? attachments?; + # The author id (if available), name and email + AuthorObject author?; + # The value of the subject field for this ticket + string subject?; + # Why the ticket was suspended + string cause?; + # The ticket ID this suspended email is associated with, if available + @jsondata:Name {value: "created_at"} + string createdAt?; + # The ID of the cause + @jsondata:Name {value: "cause_id"} + int causeId?; + # The ID of the email, if available + @jsondata:Name {value: "message_id"} + string messageId?; + # The ticket ID this suspended email is associated with, if available + @jsondata:Name {value: "ticket_id"} + int ticketId?; + # The content that was flagged + string content?; + # The error messages if any associated to this suspended ticket + @jsondata:Name {value: "error_messages"} + record {}[]? errorMessages?; + # The API url of this ticket + string url?; + # The id of the brand this ticket is associated with. Only applicable for Enterprise accounts + @jsondata:Name {value: "brand_id"} + int brandId?; + ViaObject via?; + # When the ticket was assigned + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The original recipient e-mail address of the ticket + string recipient?; + # Automatically assigned + int id?; +}; + +# Represents the Headers record for the operation: ListAssigneeFieldAssignableGroupsAndAgentsSearch +public type ListAssigneeFieldAssignableGroupsAndAgentsSearchHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ResourceCollectionObject record { + # Last time the resource collection was updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # When the resource collection was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Array of resource metadata objects. See [Resource objects](#resource-objects) + ResourceCollectionObjectResources[] resources?; + # id for the resource collection. Automatically assigned upon creation + int id?; +}; + +# Represents the Queries record for the operation: RecoverSuspendedTickets +public type RecoverSuspendedTicketsQueries record { + # A comma separated list of ids of suspended tickets to recover + string ids; +}; + +public type ConditionObject record { + # The name of a ticket field + string 'field?; + # The value of a ticket field + string value?; + # A comparison operator + string operator?; +}; + +# Represents the Queries record for the operation: DeleteManyOrganizationMemberships +public type DeleteManyOrganizationMembershipsQueries record { + # The IDs of the organization memberships to delete + int[] ids?; +}; + +public type OrganizationMetadataObject record { + # The number of tickets for the organization + @jsondata:Name {value: "tickets_count"} + int ticketsCount?; + # The number of users for the organization + @jsondata:Name {value: "users_count"} + int usersCount?; +}; + +public type organizationFieldId int|string; + +# Represents the Queries record for the operation: ListActiveMacros +public type ListActiveMacrosQueries record { + # A sideload to include in the response. See [Sideloads](#sideloads-2) + string include?; + # Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins + string access?; + # Filter macros by group + @http:Query {name: "group_id"} + int groupId?; + # Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical + @http:Query {name: "sort_by"} + string sortBy?; + # Filter macros by category + int category?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +# Represents the Headers record for the operation: ShowTicket +public type ShowTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomObjectLimitsResponse record { + # The current numnber of the requested resource + int count?; + # The maximum allowed number for the requested resource + int 'limit?; +}; + +# Represents the Headers record for the operation: CreateCustomObjectRecord +public type CreateCustomObjectRecordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type EssentialsCardObject record { + # layout type + string layout?; + # Maximum number of fields allowed in the essentials card + @jsondata:Name {value: "max_count"} + int maxCount?; + # If true, the system has used the first twenty fields for the custom object type as the essentials card + boolean default?; + # Date and time the essentials card were last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Date and time the essentials card were created + @jsondata:Name {value: "created_at"} + string createdAt?; + # id of the essentials card + string? id?; + # Fields that are displayed in the essentials card details. The order is defined by the order of the fields in the array + record {}[] fields; + # Object type. Example: `zen:user` refers to `User` type + string 'key?; +}; + +# Represents the Headers record for the operation: UpdateAutomation +public type UpdateAutomationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ListTicketCollaboratorsResponse record { +}; + +# Represents the Queries record for the operation: GroupMembershipBulkDelete +public type GroupMembershipBulkDeleteQueries record { + # Id of the group memberships to delete. Comma separated + string ids?; +}; + +# Represents the Headers record for the operation: MakeTicketCommentPrivate +public type MakeTicketCommentPrivateHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: RedactChatCommentAttachment +public type RedactChatCommentAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) +public type TicketAuditViaObject record { + # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" + string channel?; + # For some channels a source object gives more information about how or why the ticket or event was created + record {} 'source?; +}; + +public type SkillBasedRoutingAttributeValueResponse record { + @jsondata:Name {value: "attribute_value"} + SkillBasedRoutingAttributeValueObject attributeValue?; +}; + +public type SLAPoliciesResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + @jsondata:Name {value: "sla_policies"} + SLAPolicyObject[] slaPolicies?; +}; + +# Represents the Queries record for the operation: ShowManyDynamicContents +public type ShowManyDynamicContentsQueries record { + # Identifiers for the dynamic contents + string identifiers?; +}; + +public type GroupObject record { + # If the group is the default one for the account + boolean default?; + # Deleted groups get marked as such + boolean deleted?; + # The time of the last update of the group + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # If true, the group is public. + # If false, the group is private. + # You can't change a private group to a public group + @jsondata:Name {value: "is_public"} + boolean isPublic?; + # The name of the group + string name; + # The time the group was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the group + string description?; + # Automatically assigned when creating groups + int id?; + # The API url of the group + string url?; +}; + +# Represents the Headers record for the operation: GroupMembershipBulkDelete +public type GroupMembershipBulkDeleteHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SearchResponse record { + # URL to the next page of results + @jsondata:Name {value: "next_page"} + string? nextPage?; + # The number of resources returned by the query corresponding to this page of results in the paginated response + int count?; + # URL to the previous page of results + @jsondata:Name {value: "previous_page"} + string? previousPage?; + # May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object + SearchResultObject[] results?; + # The facets corresponding to the search query + string? facets?; +}; + +public type ViewExportResponse record { + ViewExportResponseExport export?; +}; + +# Represents the Headers record for the operation: UpdateManyDynamicContentVariants +public type UpdateManyDynamicContentVariantsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type DefinitionsResponseDefinitionsValues record { + string title?; + string value?; + boolean enabled?; +}; + +# Represents the Headers record for the operation: ListMacroAttachments +public type ListMacroAttachmentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowSatisfactionRating +public type ShowSatisfactionRatingHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TicketCommentsCountResponse record { + ActivitiesCountResponseCount count?; +}; + +public type SatisfactionRatingsResponse record { + @jsondata:Name {value: "satisfaction_ratings"} + SatisfactionRatingObject[] satisfactionRatings?; +}; + +# Represents the Headers record for the operation: ExportView +public type ExportViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TicketCreateVoicemailTicketVoiceCommentInput record { + # Transcription of the call (optional) + @jsondata:Name {value: "transcription_text"} + string transcriptionText?; + # Incoming phone number + @jsondata:Name {value: "recording_url"} + string recordingUrl?; + # The agent who answered the call + @jsondata:Name {value: "answered_by_id"} + int answeredById?; + # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp of the call starting time + @jsondata:Name {value: "started_at"} + string startedAt?; + # Incoming phone number + string 'from?; + # Location of the caller (optional) + string location?; + # Dialed phone number + string to?; + # Duration in seconds of the call + @jsondata:Name {value: "call_duration"} + int callDuration?; +}; + +public type SupportAddressesResponse record { + @jsondata:Name {value: "recipient_addresses"} + SupportAddressObject[] recipientAddresses?; +}; + +public type SearchResultObject record { + # The type of the resource + @jsondata:Name {value: "result_type"} + string resultType?; + # Flag to indicate whether this is the default resource + boolean default?; + # Flag to indicate whether or not resource has been deleted + boolean deleted?; + # When the resource was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The name of the resource + string name?; + # When the resource was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the resource + string description?; + # The ID of the resource + int id?; + # The url of the resource + string url?; +}; + +public type CustomStatusCreateInputAllOf2 record { + # The status category the custom ticket status belongs to + @jsondata:Name {value: "status_category"} + "new"|"open"|"pending"|"hold"|"solved" statusCategory?; +}; + +# Represents the Headers record for the operation: ShowCustomStatus +public type ShowCustomStatusHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Ticket settings. See [Tickets](#tickets) +public type AccountSettingsTicketObject record { + @jsondata:Name {value: "auto_translation_enabled"} + boolean autoTranslationEnabled?; + @jsondata:Name {value: "agent_ticket_deletion"} + boolean agentTicketDeletion?; + boolean tagging?; + @jsondata:Name {value: "using_skill_based_routing"} + boolean usingSkillBasedRouting?; + @jsondata:Name {value: "has_color_text"} + boolean hasColorText?; + @jsondata:Name {value: "allow_group_reset"} + boolean allowGroupReset?; + @jsondata:Name {value: "rich_text_comments"} + boolean richTextComments?; + @jsondata:Name {value: "comments_public_by_default"} + boolean commentsPublicByDefault?; + @jsondata:Name {value: "follower_and_email_cc_collaborations"} + boolean followerAndEmailCcCollaborations?; + @jsondata:Name {value: "light_agent_email_ccs_allowed"} + boolean lightAgentEmailCcsAllowed?; + @jsondata:Name {value: "is_first_comment_private_enabled"} + boolean isFirstCommentPrivateEnabled?; + @jsondata:Name {value: "list_empty_views"} + boolean listEmptyViews?; + @jsondata:Name {value: "chat_sla_enablement"} + boolean chatSlaEnablement?; + @jsondata:Name {value: "agent_invitation_enabled"} + boolean agentInvitationEnabled?; + @jsondata:Name {value: "accepted_new_collaboration_tos"} + boolean acceptedNewCollaborationTos?; + @jsondata:Name {value: "assign_default_organization"} + boolean assignDefaultOrganization?; + @jsondata:Name {value: "emoji_autocompletion"} + boolean emojiAutocompletion?; + @jsondata:Name {value: "private_attachments"} + boolean privateAttachments?; + @jsondata:Name {value: "auto_updated_ccs_followers_rules"} + boolean autoUpdatedCcsFollowersRules?; + @jsondata:Name {value: "email_attachments"} + boolean emailAttachments?; + @jsondata:Name {value: "list_newest_comments_first"} + boolean listNewestCommentsFirst?; + @jsondata:Name {value: "status_hold"} + boolean statusHold?; + @jsondata:Name {value: "markdown_ticket_comments"} + boolean markdownTicketComments?; + @jsondata:Name {value: "agent_collision"} + boolean agentCollision?; + @jsondata:Name {value: "maximum_personal_views_to_list"} + int maximumPersonalViewsToList?; + @jsondata:Name {value: "assign_tickets_upon_solve"} + boolean assignTicketsUponSolve?; + boolean collaboration?; +}; + +# Represents the Headers record for the operation: ShowChangesToTicket +public type ShowChangesToTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TagsByObjectIdResponse record { + # An array of strings + string[] tags; +}; + +public type CountResponseCount record { + @jsondata:Name {value: "refreshed_at"} + string refreshedAt?; + int value?; +}; + +# Configuration for the agent workspace. See [Agents](#agents) +public type AccountSettingsAgentObject record { + @jsondata:Name {value: "agent_workspace"} + boolean agentWorkspace?; + @jsondata:Name {value: "aw_self_serve_migration_enabled"} + boolean awSelfServeMigrationEnabled?; + @jsondata:Name {value: "agent_home"} + boolean agentHome?; + @jsondata:Name {value: "idle_timeout_enabled"} + boolean idleTimeoutEnabled?; + @jsondata:Name {value: "unified_agent_statuses"} + boolean unifiedAgentStatuses?; + @jsondata:Name {value: "focus_mode"} + boolean focusMode?; +}; + +# Represents the Headers record for the operation: ShowRequest +public type ShowRequestHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListTicketAudits +public type ListTicketAuditsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ActionObject record { + # The name of a ticket field to modify + string 'field?; + # The new value of the field + string value?; +}; + +public type UserResponse record { + UserObject user?; +}; + +# Represents the Queries record for the operation: UpdateTicketField +public type UpdateTicketFieldQueries record { + # If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created + # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field + # is not created by an app, then `creator_app_name` is null + boolean creator?; +}; + +public type TriggerRevisionsResponseTriggerRevisions record { + @jsondata:Name {value: "created_at"} + string createdAt?; + TriggerRevisionsResponseDiff diff?; + int id?; + @jsondata:Name {value: "author_id"} + int authorId?; + TriggerSnapshotObject snapshot?; + string url?; +}; + +public type SLAPolicyFilterDefinitionResponseDefinitions record { + SLAPolicyFilterDefinitionResponseDefinitionsAll[] all?; + SLAPolicyFilterDefinitionResponseDefinitionsAll[] 'any?; +}; + +# Represents the Headers record for the operation: RecoverSuspendedTickets +public type RecoverSuspendedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type GroupsCountObjectCount record { + # Timestamp that indicates when the count was last updated + @jsondata:Name {value: "refreshed_at"} + string refreshedAt?; + # Approximate count of groups + int value?; +}; + +public type TriggerConditionDiffObject record { + # An array of [change](#change) objects + TriggerChangeObject[] 'field?; + # An array of [change](#change) objects + TriggerChangeObject[] value?; + # An array of [change](#change) objects + TriggerChangeObject[] operator?; +}; + +# Represents the Headers record for the operation: CountTicketComments +public type CountTicketCommentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: PutTagsTicket +public type PutTagsTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: TicketsShowMany +public type TicketsShowManyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type UserFieldsResponse record { + # URL of the next page + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "user_fields"} + UserFieldObject[] userFields?; + # Total count of records retrieved + int count?; + # URL of the previous page + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +public type ViewsCountResponse record { + ActivitiesCountResponseCount count?; +}; + +# Represents the Headers record for the operation: ListTicketsFullfilledByUser +public type ListTicketsFullfilledByUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomFieldOptionResponse record { + @jsondata:Name {value: "custom_field_option"} + CustomFieldOptionObject customFieldOption?; +}; + +# Represents the Queries record for the operation: ShowTicketfield +public type ShowTicketfieldQueries record { + # If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created + # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field + # is not created by an app, then `creator_app_name` is null + boolean creator?; +}; + +public type AssigneeFieldAssignableSearchGroupObject record { + # Name of the group + string name?; + # Group ID + int id?; +}; + +# Represents the Headers record for the operation: CustomObjectFieldsLimit +public type CustomObjectFieldsLimitHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BrandObject record { + # The hostmapping to this brand, if any. Only admins view this property + @jsondata:Name {value: "host_mapping"} + string hostMapping?; + # The ids of ticket forms that are available for use by a brand + @jsondata:Name {value: "ticket_form_ids"} + int[] ticketFormIds?; + # If the brand is set as active + boolean active?; + # The time the brand was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The state of the Help Center + @jsondata:Name {value: "help_center_state"} + "enabled"|"disabled"|"restricted" helpCenterState?; + # The API url of this brand + string url?; + # The url of the brand + @jsondata:Name {value: "brand_url"} + string brandUrl?; + # Is the brand the default brand for this account + boolean default?; + # If the brand has a Help Center + @jsondata:Name {value: "has_help_center"} + boolean hasHelpCenter?; + # If the brand object is deleted or not + @jsondata:Name {value: "is_deleted"} + boolean isDeleted?; + # The time of the last update of the brand + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The signature template for a brand + @jsondata:Name {value: "signature_template"} + string signatureTemplate?; + # The name of the brand + string name; + AttachmentObject logo?; + # The subdomain of the brand + string subdomain; + # The ID automatically assigned when the brand is created + int id?; +}; + +# Apps configuration options. See [Apps](#apps) +public type AccountSettingsAppsObject record { + @jsondata:Name {value: "create_public"} + boolean createPublic?; + @jsondata:Name {value: "create_private"} + boolean createPrivate?; + boolean use?; +}; + +# Represents the Headers record for the operation: CountCustomObjectRecords +public type CountCustomObjectRecordsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type IncrementalSkillBasedRoutingAttributeValue record { + # Id of the associated attribute + @jsondata:Name {value: "attribute_id"} + string attributeId?; + # The name of the attribute value + string name?; + # Automatically assigned when an attribute value is created + string id?; + # The time the attribute value was created, updated, or deleted + string time?; + # One of "create", "update", or "delete" + string 'type?; +}; + +public type TicketImportRequest record { + TicketImportInput ticket?; +}; + +public type TicketChatCommentRedactionResponse record { + # Chat event object + @jsondata:Name {value: "chat_event"} + TicketChatCommentRedactionResponseChatEvent chatEvent?; +}; + +public type MacroInput record { + # Who may access this macro. Will be null when everyone in the account can access it + MacroInputRestriction restriction?; + # Useful for determining if the macro should be displayed + boolean active?; + # The description of the macro + string? description?; + # The title of the macro + string title; + # Each action describes what the macro will do + ActionObject[] actions; +}; + +# For some channels a source object gives more information about how or why the ticket or event was created +public type ViaObjectSource record { + ViaObjectSourceFrom 'from?; + string? rel?; + ViaObjectSourceTo to?; +}; + +public type CustomObjectRecordResponse record { + @jsondata:Name {value: "custom_object_record"} + CustomObjectRecord customObjectRecord?; +}; + +# Represents the Queries record for the operation: SearchRequests +public type SearchRequestsQueries record { + # The syntax and matching logic for the string is detailed in the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226). See also [Query basics](/api-reference/ticketing/ticket-management/search/#query-basics) in the Tickets API doc + string query?; +}; + +# Represents the Headers record for the operation: DeleteOrganization +public type DeleteOrganizationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowBrand +public type ShowBrandHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerObject record { + # The raw format of the title of the trigger + @jsondata:Name {value: "raw_title"} + string rawTitle?; + # Whether the trigger is active + boolean active?; + # The time the trigger was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the trigger + string description?; + # The title of the trigger + string title; + # The url of the trigger + string url?; + # If true, the trigger is a default trigger + boolean default?; + # The ID of the category the trigger belongs to + @jsondata:Name {value: "category_id"} + string categoryId?; + # The time of the last update of the trigger + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Automatically assigned when created + int id?; + # Position of the trigger, determines the order they will execute in + int position?; + TriggerConditionsObject conditions; + # An array of actions describing what the trigger will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) + TriggerActionObject[] actions; +}; + +public type UserCreateInput record { + UserCreateInputIdentities[] identities?; + string role?; + @jsondata:Name {value: "custom_role_id"} + int customRoleId?; + UserCreateInputOrganization organization?; + @jsondata:Name {value: "organization_id"} + int organizationId?; + string name; + @jsondata:Name {value: "external_id"} + string externalId?; + string email; +}; + +# Represents the Queries record for the operation: CheckHostMappingValidity +public type CheckHostMappingValidityQueries record { + # The hostmapping to a brand, if any (only admins view this key) + @http:Query {name: "host_mapping"} + string hostMapping; + # Subdomain for a given Zendesk account address + string subdomain; +}; + +# Represents the Headers record for the operation: ListActiveMacros +public type ListActiveMacrosHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BrandsResponse record { + *OffsetPaginationObject; + *BrandsResponseAllOf2; +}; + +# Represents the Headers record for the operation: ShowSLAPolicy +public type ShowSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TagsResponse record { + # The url of the previous page + @jsondata:Name {value: "next_page"} + string? nextPage?; + # The number of pages + int count?; + # The url of the next page + @jsondata:Name {value: "previous_page"} + string? previousPage?; + TagListTagObject[] tags?; +}; + +public type EssentialsCardsResponse record { + @jsondata:Name {value: "object_layouts"} + EssentialsCardObject[] objectLayouts?; +}; + +# Secondary group ids linked to the queue +public type QueueObjectSecondaryGroups record { + int count?; + ListDeletedTicketsResponseActor[] groups?; +}; + +# Represents the Headers record for the operation: ShowTicketfield +public type ShowTicketfieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: AutocompleteOrganizations +public type AutocompleteOrganizationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: IncrementalSampleExport +public type IncrementalSampleExportHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BatchJobResponse record { + BatchJobResponseResults results?; + BatchErrorItem[] errors?; + "complete"|"failed" status?; +}; + +public type GroupSLAPolicyResponse record { + @jsondata:Name {value: "group_sla_policy"} + GroupSLAPolicyObject groupSlaPolicy?; +}; + +# Represents the Headers record for the operation: CustomObjectRecordBulkJobs +public type CustomObjectRecordBulkJobsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateEssentialsCard +public type UpdateEssentialsCardHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteCustomObjectField +public type DeleteCustomObjectFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerActionDiffObject record { + # An array of [change](#change) objects + TriggerChangeObject[] 'field?; + # An array of [change](#change) objects + TriggerChangeObject[] value?; +}; + +public type CustomFieldOptionObject record { + # Raw name of the dropdown option + @jsondata:Name {value: "raw_name"} + string rawName?; + # Name of the dropdown option + string name; + # Automatically assigned upon creation + int id?; + # Position of the dropdown option + int position?; + # Value of the dropdown option + string value; + # URL of the dropdown option + string url?; +}; + +# Represents the Headers record for the operation: ListSessions +public type ListSessionsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SuspendedTicketsExportResponseExport record { + @jsondata:Name {value: "view_id"} + string viewId?; + string status?; +}; + +public type SharingAgreementsResponse record { + @jsondata:Name {value: "sharing_agreements"} + SharingAgreementObject[] sharingAgreements?; +}; + +# Represents the Queries record for the operation: BulkPermanentlyDeleteTickets +public type BulkPermanentlyDeleteTicketsQueries record { + # Comma-separated list of ticket ids + string ids; +}; + +# Represents the Headers record for the operation: SearchRequests +public type SearchRequestsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SatisfactionReasonResponse record { + SatisfactionReasonObject[] reason?; +}; + +public type BookmarkObject record { + TicketObject ticket?; + # The time the bookmark was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when the bookmark is created + int id?; + # The API url of this bookmark + string url?; +}; + +public type CustomStatusObject record { + # The description displayed to end users + @jsondata:Name {value: "end_user_description"} + string endUserDescription?; + # If true, the custom status is set to active, If false, the custom status is set to inactive + boolean active?; + # The date and time the custom ticket status was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of when the user should select this custom ticket status + string description?; + # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "description" value. [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_description"} + string rawDescription?; + # If true, the custom status is set to default. If false, the custom status is set to non-default + boolean default?; + # The label displayed to end users. Maximum length is 48 characters + @jsondata:Name {value: "end_user_label"} + string endUserLabel?; + # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "agent_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_agent_label"} + string rawAgentLabel?; + # The status category the custom ticket status belongs to + @jsondata:Name {value: "status_category"} + "new"|"open"|"pending"|"hold"|"solved" statusCategory; + # The date and time the custom ticket status was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_description" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_end_user_description"} + string rawEndUserDescription?; + # Automatically assigned when the custom ticket status is created + int id?; + # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_end_user_label"} + string rawEndUserLabel?; + # The label displayed to agents. Maximum length is 48 characters + @jsondata:Name {value: "agent_label"} + string agentLabel; +}; + +public type SearchCountResponse record { + int count?; +}; + +public type JobStatusObject record { + # The type of the job + @jsondata:Name {value: "job_type"} + string jobType?; + # The total number of tasks this job is batching through + int? total?; + # Number of tasks that have already been completed + int? progress?; + # Automatically assigned when the job is queued + string id?; + # Message from the job worker, if any + string? message?; + # Result data from processed tasks. See [Results](#results) below + JobStatusResultObject[]|record {boolean success;}? results?; + # The URL to poll for status updates + string url?; + # The current status. One of the following: "queued", "working", "failed", "completed" + string status?; +}; + +# GoodData settings, used for insights. Legacy configuration prior to Zendesk Explore. See [GoodData Advanced Analytics](#gooddata-advanced-analytics) +public type AccountSettingsGooddataAdvancedAnalyticsObject record { + boolean enabled?; +}; + +public type AuthorObject record { + # The author name + string name?; + # The author id + int id?; + # The author email + string email?; +}; + +# Represents the Headers record for the operation: ShowManyDynamicContents +public type ShowManyDynamicContentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerDefinitionResponse record { + TriggerDefinitionObject definitions?; +}; + +# Represents the Headers record for the operation: CreateAttributeValue +public type CreateAttributeValueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: GetViewCounts +public type GetViewCountsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object +public type AttachmentObject record { + *AttachmentBaseObject; + *AttachmentThumbnails; +}; + +public type LocalesResponse record { + LocaleObject[] locales?; +}; + +# Represents the Queries record for the operation: ListSuspendedTickets +public type ListSuspendedTicketsQueries record { + # The field to sort the ticket by, being one of `author_email`, `cause`, `created_at`, or `subject` + @http:Query {name: "sort_by"} + string sortBy?; + # The order in which to sort the suspended tickets. This can take value `asc` or `desc` + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +# Represents the Headers record for the operation: ShowTargetFailure +public type ShowTargetFailureHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type AttachmentResponse record { + AttachmentObject attachment?; +}; + +public type MacroUpdateManyInput record { + MacroUpdateManyInputMacros[] macros?; +}; + +# Represents the Headers record for the operation: ChangeOwnPassword +public type ChangeOwnPasswordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type JobStatusResultObject CreateResourceResult|UpdateResourceResult; + +public type ActivitiesCountResponseCount record { + @jsondata:Name {value: "refreshed_at"} + string refreshedAt?; + int value?; +}; + +public type GroupMembershipResponse record { + @jsondata:Name {value: "group_membership"} + GroupMembershipObject groupMembership?; +}; + +public type ListTicketEmailCCsResponse record { +}; + +public type DeletedUserObject record { + string role; + @jsondata:Name {value: "shared_phone_number"} + string? sharedPhoneNumber; + boolean active; + @jsondata:Name {value: "created_at"} + string createdAt; + record {}? photo; + string locale; + @jsondata:Name {value: "time_zone"} + string timeZone; + string url; + @jsondata:Name {value: "locale_id"} + int localeId; + @jsondata:Name {value: "updated_at"} + string updatedAt; + string? phone; + @jsondata:Name {value: "organization_id"} + int organizationId; + string name; + int id; + string email; +}; + +# Represents the Queries record for the operation: ListTicketComments +public type ListTicketCommentsQueries record { + # Accepts "users". Use this parameter to list email CCs by side-loading users. Example: `?include=users`. **Note**: If the comment source is email, a deleted user will be represented as the CCd email address. If the comment source is anything else, a deleted user will be represented as the user name + string include?; + # Default is false. When true, inline images are also listed as attachments in the response + @http:Query {name: "include_inline_images"} + boolean includeInlineImages?; +}; + +public type BrandResponse record { + BrandObject brand?; +}; + +# Represents the Headers record for the operation: DeleteAutomation +public type DeleteAutomationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type DynamicContentVariantsResponse record { + DynamicContentVariantObject[] variants?; +}; + +public type RelationshipFilterDefinition record { + @jsondata:Name {value: "conditions_any"} + TriggerConditionDefinitionObjectAny[] conditionsAny?; + @jsondata:Name {value: "conditions_all"} + TriggerConditionDefinitionObjectAll[] conditionsAll?; +}; + +# Represents the Headers record for the operation: UpdateCustomStatus +public type UpdateCustomStatusHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerRevisionsResponse record { + @jsondata:Name {value: "trigger_revisions"} + TriggerRevisionsResponseTriggerRevisions[] triggerRevisions?; + @jsondata:Name {value: "before_url"} + string beforeUrl?; + @jsondata:Name {value: "after_cursor"} + string afterCursor?; + int count?; + @jsondata:Name {value: "after_url"} + string afterUrl?; + @jsondata:Name {value: "before_cursor"} + string beforeCursor?; +}; + +public type GroupSLAPolicyMetricObject record { + # Whether the metric targets are being measured in business hours or calendar hours + @jsondata:Name {value: "business_hours"} + boolean businessHours?; + # The definition of the time that is being measured + string metric?; + # Priority that a ticket must match + string priority?; + # The time within which the end-state for a metric should be met + int target?; +}; + +# The value of the chat event object +public type TicketChatCommentRedactionResponseChatEventValue record { + # Id assigned to the visitor + @jsondata:Name {value: "visitor_id"} + string visitorId?; + # Chat events within the chat session + record {}[] history?; + # Id of the chat session + @jsondata:Name {value: "chat_id"} + string chatId?; +}; + +public type GroupSLAPolicyFilterDefinitionResponseDefinitions record { + GroupSLAPolicyFilterDefinitionResponseDefinitionsAll[] all?; +}; + +public type TargetFailuresResponse record { + @jsondata:Name {value: "target_failures"} + TargetFailureObject[] targetFailures?; +}; + +# Represents the Headers record for the operation: DeleteMacro +public type DeleteMacroHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Rules settings for triggers, macros, views, and automations. See [Rules](#rules) +public type AccountSettingsRuleObject record { + @jsondata:Name {value: "using_skill_based_routing"} + boolean usingSkillBasedRouting?; + @jsondata:Name {value: "macro_order"} + string macroOrder?; + @jsondata:Name {value: "skill_based_filtered_views"} + record {}[] skillBasedFilteredViews?; + @jsondata:Name {value: "macro_most_used"} + boolean macroMostUsed?; +}; + +# Represents the Queries record for the operation: GetViewCounts +public type GetViewCountsQueries record { + # List of view's ids separated by commas + string ids; +}; + +# Represents the Headers record for the operation: DeleteDynamicContentVariant +public type DeleteDynamicContentVariantHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BatchJobRequestJob record { + "patch" action?; + BatchJobRequestJobItems items?; +}; + +# Represents the Headers record for the operation: ListTicketComments +public type ListTicketCommentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListTicketsFullfilledByUser +public type ListTicketsFullfilledByUserQueries record { + # The IDs of the relevant tickets to check for matching attributes + @http:Query {name: "ticket_ids"} + int ticketIds; +}; + +# Represents the Headers record for the operation: ListTicketForms +public type ListTicketFormsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListSuspendedTickets +public type ListSuspendedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type CustomObjectRecordsCreateRequest record { + @jsondata:Name {value: "custom_object_record"} + CustomObjectRecord customObjectRecord?; +}; + +# Metadata for the export query response +public type SearchExportResponseMeta record { + # The cursor id for the next object + @jsondata:Name {value: "after_cursor"} + string? afterCursor?; + # The cursor id for the previous object + @jsondata:Name {value: "before_cursor"} + string? beforeCursor?; + # Whether there are more items yet to be returned by the cursor + @jsondata:Name {value: "has_more"} + boolean hasMore?; +}; + +# Represents the Queries record for the operation: IncrementalSampleExport +public type IncrementalSampleExportQueries record { + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; +}; + +public type SuspendedTicketsResponse record { + @jsondata:Name {value: "suspended_tickets"} + SuspendedTicketObject[] suspendedTickets?; +}; + +public type TicketUpdateInput record { + # Optional boolean. Prevents updates with outdated ticket data (`updated_stamp` property required when true) + @jsondata:Name {value: "safe_update"} + boolean safeUpdate?; + # Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) + @jsondata:Name {value: "custom_fields"} + CustomFieldObject[] customFields?; + # The value of the subject field for this ticket + string subject?; + # The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) + @jsondata:Name {value: "custom_status_id"} + int customStatusId?; + # An id you can use to link Zendesk Support tickets to local records + @jsondata:Name {value: "external_id"} + string externalId?; + # An array of numeric IDs, emails, or objects containing name and email properties. See [Setting Collaborators](/api-reference/ticketing/tickets/tickets/#setting-collaborators). An email notification is sent to them when the ticket is updated + @jsondata:Name {value: "additional_collaborators"} + CollaboratorObject[] additionalCollaborators?; + # The ids of users currently CC'ed on the ticket + @jsondata:Name {value: "collaborator_ids"} + int[] collaboratorIds?; + # The urgency with which the ticket should be addressed + "urgent"|"high"|"normal"|"low" priority?; + # The type of this ticket + "problem"|"incident"|"question"|"task" 'type?; + # Datetime of last update received from API. See the safe_update property + @jsondata:Name {value: "updated_stamp"} + string updatedStamp?; + # The array of tags applied to this ticket + string[] tags?; + # The email address of the agent to assign the ticket to + @jsondata:Name {value: "assignee_email"} + string assigneeEmail?; + # An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-followers) + FollowerObject[] followers?; + # An array of the numeric IDs of sharing agreements. Note that this replaces any existing agreements + @jsondata:Name {value: "sharing_agreement_ids"} + int[] sharingAgreementIds?; + # The group this ticket is assigned to + @jsondata:Name {value: "group_id"} + int groupId?; + # For tickets of type "incident", the ID of the problem the incident is linked to + @jsondata:Name {value: "problem_id"} + int problemId?; + # An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-email-ccs) + @jsondata:Name {value: "email_ccs"} + EmailCCObject[] emailCcs?; + # The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) + @jsondata:Name {value: "organization_id"} + int organizationId?; + TicketCommentObject comment?; + # If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format + @jsondata:Name {value: "due_at"} + string? dueAt?; + # An array of the IDs of attribute values to be associated with the ticket + @jsondata:Name {value: "attribute_value_ids"} + int[] attributeValueIds?; + # The agent currently assigned to the ticket + @jsondata:Name {value: "assignee_id"} + int assigneeId?; + # The user who requested this ticket + @jsondata:Name {value: "requester_id"} + int requesterId?; + # The state of the ticket. + # + # If your account has activated custom ticket statuses, this is the ticket's + # status category. See [custom ticket statuses](#custom-ticket-statuses) + "new"|"open"|"pending"|"hold"|"solved"|"closed" status?; +}; + +# CDN settings +public type AccountSettingsCdnObject record { + @jsondata:Name {value: "cdn_provider"} + string cdnProvider?; + AccountSettingsCdnObjectHosts[] hosts?; + @jsondata:Name {value: "fallback_cdn_provider"} + string fallbackCdnProvider?; +}; + +public type RecoverSuspendedTicketsResponse record { + SuspendedTicketObject[] tickets?; +}; + +# Represents the Headers record for the operation: ShowTicketAfterChanges +public type ShowTicketAfterChangesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListUserIdentities +public type ListUserIdentitiesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowUserFieldOption +public type ShowUserFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListAssigneeFieldAssignableGroupsAndAgentsSearch +public type ListAssigneeFieldAssignableGroupsAndAgentsSearchQueries record { + # Query string used to search assignable groups & agents in the AssigneeField + string name; +}; + +public type CustomObjectRecordsJobsResponseJobStatus record { + int total?; + int? progress?; + string id?; + string? message?; + CustomObjectRecord[]? results?; + string url?; + string status?; +}; + +public type EssentialsCardResponse record { + @jsondata:Name {value: "object_layout"} + EssentialsCardObject objectLayout?; +}; + +# The status of the import for the indicated resource +public type ChannelFrameworkResultStatusObject record { + # A code indicating the status of the import of the resource, as described in [status codes](#status-codes) + string code?; + # In the case of an exception, a description of the exception. Otherwise, not present + string description?; +}; + +public type CustomObjectFieldsCreateRequest record { + @jsondata:Name {value: "custom_object_field"} + CustomObjectField customObjectField?; +}; + +public type BatchJobRequest record { + BatchJobRequestJob job?; +}; + +public type ViewExportResponseExport record { + @jsondata:Name {value: "view_id"} + int viewId?; + string status?; +}; + +public type CustomObjectRecordsBulkCreateRequest record { + CustomObjectRecordsBulkCreateRequestJob job?; +}; + +# Represents the Queries record for the operation: AutocompleteOrganizations +public type AutocompleteOrganizationsQueries record { + # The id of a lookup relationship field. The type of field is determined + # by the `source` param + @http:Query {name: "field_id"} + string fieldId?; + # A substring of an organization to search for + string name; + # If a `field_id` is provided, this specifies the type of the field. + # For example, if the field is on a "zen:user", it references a field on a user + string 'source?; +}; + +# Google Apps configuration. See [G Suite](#g-suite) +public type AccountSettingsGoogleAppsObject record { + @jsondata:Name {value: "has_google_apps_admin"} + boolean hasGoogleAppsAdmin?; + @jsondata:Name {value: "has_google_apps"} + boolean hasGoogleApps?; +}; + +# Represents the Headers record for the operation: DeleteSession +public type DeleteSessionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type UserIdentityObject record { + # The time the identity was updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Email identity type only. Indicates if Zendesk sends notifications to the email address. See [Deliverable state](#deliverable-state) + @jsondata:Name {value: "deliverable_state"} + string deliverableState?; + # The id of the user + @jsondata:Name {value: "user_id"} + int userId; + # The number of times a soft-bounce response was received at that address + @jsondata:Name {value: "undeliverable_count"} + int undeliverableCount?; + # If the identity has been verified + boolean verified?; + # The time the identity was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned on creation + int id?; + # The type of this identity + "email"|"twitter"|"facebook"|"google"|"phone_number"|"agent_forwarding"|"any_channel"|"foreign"|"sdk" 'type; + # The identifier for this identity, such as an email address + string value; + # The API url of this identity + string url?; + # If the identity is the primary identity. *Writable only when creating, not when updating. Use the [Make Identity Primary](#make-identity-primary) endpoint instead + boolean primary?; +}; + +public type TargetResponse record { + TargetObject target?; +}; + +# Represents the Queries record for the operation: ListViews +public type ListViewsQueries record { + # Only views with given access. May be "personal", "shared", or "account" + string access?; + # Only views belonging to given group + @http:Query {name: "group_id"} + int groupId?; + # Only active views if true, inactive views if false + boolean active?; + # Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +public type MacroApplyTicketResponseResultTicketComment record { + boolean 'public?; + @jsondata:Name {value: "scoped_body"} + string[][] scopedBody?; + string body?; +}; + +# Represents the Headers record for the operation: SetAgentAttributeValues +public type SetAgentAttributeValuesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: VerifyUserIdentity +public type VerifyUserIdentityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowTicketMetrics +public type ShowTicketMetricsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type PaginationMeta record { + @jsondata:Name {value: "after_cursor"} + string afterCursor?; + @jsondata:Name {value: "before_cursor"} + string beforeCursor?; + @jsondata:Name {value: "has_more"} + boolean hasMore?; +}; + +public type CustomFieldObject record { + # The dynamic content placeholder, if present, or the `title` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_title"} + string rawTitle?; + # Required and presented for a custom field of type "dropdown". Each option is represented by an object with a `name` and `value` property + @jsondata:Name {value: "custom_field_options"} + CustomFieldOptionObject[] customFieldOptions?; + # If true, this field is available for use + boolean active?; + # The time of the last update of the ticket field + @jsondata:Name {value: "created_at"} + string createdAt?; + # User-defined description of this field's purpose + string description?; + # The title of the custom field + string title; + # The custom field type: "checkbox", "date", "decimal", "dropdown", "integer", ["lookup"](/api-reference/ticketing/lookup_relationships/lookup_relationships/), "regexp", "text", or "textarea" + string 'type; + # The dynamic content placeholder, if present, or the `description` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_description"} + string rawDescription?; + # The URL for this resource + string url?; + # If true, only active and position values of this field can be changed + boolean system?; + # The time of the last update of the ticket field + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", and "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment" + @jsondata:Name {value: "relationship_target_type"} + string relationshipTargetType?; + # Regular expression field only. The validation pattern for a field value to be deemed valid + @jsondata:Name {value: "regexp_for_validation"} + string? regexpForValidation?; + # A filter definition that allows your autocomplete to filter down results + @jsondata:Name {value: "relationship_filter"} + record {} relationshipFilter?; + # Automatically assigned upon creation + int id?; + # Ordering of the field relative to other fields + int position?; + # Optional for custom field of type "checkbox"; not presented otherwise + string tag?; + # A unique key that identifies this custom field. This is used for updating the field and referencing in placeholders. The key must consist of only letters, numbers, and underscores. It can't be only numbers and can't be reused if deleted + string 'key; +}; + +# Represents the Headers record for the operation: DeleteTriggerCategory +public type DeleteTriggerCategoryHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type DeletedUserResponse record { + @jsondata:Name {value: "deleted_user"} + DeletedUserObject deletedUser?; +}; + +# Represents the Headers record for the operation: DeleteGroup +public type DeleteGroupHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: RedactStringInComment +public type RedactStringInCommentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: SuspendedTicketsAttachments +public type SuspendedTicketsAttachmentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TagCountResponse record { + TagCountObject count?; +}; + +# Represents the Headers record for the operation: ShowTicketAudit +public type ShowTicketAuditHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type OrganizationsResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + OrganizationObject[] organizations?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +public type TicketObject record { + # If true, the ticket's [via type](/documentation/ticketing/reference-guides/via-object-reference/) is a messaging channel + @jsondata:Name {value: "from_messaging_channel"} + boolean fromMessagingChannel?; + # Write only. Metadata for the audit. In the `audit` object, the data is specified in the `custom` property of the `metadata` object. See [Setting Metadata](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-metadata) + record {} metadata?; + # The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center + @jsondata:Name {value: "email_cc_ids"} + int[] emailCcIds?; + # The value of the subject field for this ticket. See [Subject](/api-reference/ticketing/tickets/tickets/#subject) + string subject?; + # Write only. See [Creating voicemail ticket](/api-reference/voice/talk-partner-edition-api/reference/#creating-voicemail-tickets) + @jsondata:Name {value: "voice_comment"} + record {} voiceComment?; + # POST requests only. List of macro IDs to be recorded in the ticket audit + @jsondata:Name {value: "macro_ids"} + int[] macroIds?; + # The type of this ticket + "problem"|"incident"|"question"|"task" 'type?; + # Write only. Datetime of last update received from API. See the `safe_update` property + @jsondata:Name {value: "updated_stamp"} + string updatedStamp?; + # For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) + TicketObjectVia via?; + # Write only. An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-email-ccs) + @jsondata:Name {value: "email_ccs"} + record {} emailCcs?; + # POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) + CollaboratorObject[] collaborators?; + # If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format + @jsondata:Name {value: "due_at"} + string? dueAt?; + # Automatically assigned when the ticket is created + int id?; + # The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_subject"} + string rawSubject?; + # Write only. See [Creating a ticket with a new requester](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#creating-a-ticket-with-a-new-requester) + record {} requester?; + # Write only. Optional boolean. When true and an `update_stamp` date is included, protects against ticket update collisions and returns a message to let you know if one occurs. See [Protecting against ticket update collisions](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#protecting-against-ticket-update-collisions). A value of false has the same effect as true. Omit the property to force the updates to not be safe + @jsondata:Name {value: "safe_update"} + boolean safeUpdate?; + # Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) + @jsondata:Name {value: "custom_fields"} + TicketObjectCustomFields[] customFields?; + # Is false if channelback is disabled, true otherwise. Only applicable for channels framework ticket + @jsondata:Name {value: "allow_channelback"} + boolean allowChannelback?; + # The satisfaction rating of the ticket, if it exists, or the state of satisfaction, "offered" or "unoffered". The value is null for plan types that don't support CSAT + @jsondata:Name {value: "satisfaction_rating"} + record {} satisfactionRating?; + # The urgency with which the ticket should be addressed + "urgent"|"high"|"normal"|"low" priority?; + # The id of the brand this ticket is associated with. See [Setting up multiple brands](https://support.zendesk.com/hc/en-us/articles/4408829476378) + @jsondata:Name {value: "brand_id"} + int brandId?; + # The array of tags applied to this ticket + string[] tags?; + # Write only. An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-followers) + record {} followers?; + # The ids of the sharing agreements used for this ticket + @jsondata:Name {value: "sharing_agreement_ids"} + int[] sharingAgreementIds?; + # The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) + @jsondata:Name {value: "organization_id"} + int organizationId?; + # POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) + @jsondata:Name {value: "via_followup_source_id"} + int viaFollowupSourceId?; + # Is true if a ticket is a problem type and has one or more incidents linked to it. Otherwise, the value is false + @jsondata:Name {value: "has_incidents"} + boolean hasIncidents?; + # Write only. An array of the IDs of attribute values to be associated with the ticket + @jsondata:Name {value: "attribute_value_ids"} + int[] attributeValueIds?; + # Write only. For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference/) + @jsondata:Name {value: "via_id"} + int viaId?; + # The user who requested this ticket + @jsondata:Name {value: "requester_id"} + int requesterId; + # The state of the ticket. + # + # If your account has activated custom ticket statuses, this is the ticket's + # status category. See [custom ticket statuses](#custom-ticket-statuses) + "new"|"open"|"pending"|"hold"|"solved"|"closed" status?; + # When this record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) + @jsondata:Name {value: "custom_status_id"} + int customStatusId?; + # Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) + string description?; + # An id you can use to link Zendesk Support tickets to local records + @jsondata:Name {value: "external_id"} + string externalId?; + # Permission for agents to add add attachments to a comment. Defaults to true + @jsondata:Name {value: "allow_attachments"} + boolean allowAttachments?; + # Write only. The email address of the agent to assign the ticket to + @jsondata:Name {value: "assignee_email"} + string assigneeEmail?; + # When this record last got updated. It is updated only if the update generates a [ticket event](#incremental-ticket-event-export) + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # For tickets of type "incident", the ID of the problem the incident is linked to + @jsondata:Name {value: "problem_id"} + int problemId?; + # The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) + @jsondata:Name {value: "follower_ids"} + int[] followerIds?; + # The agent currently assigned to the ticket + @jsondata:Name {value: "assignee_id"} + int assigneeId?; + # The topic in the Zendesk Web portal this ticket originated from, if any. The Web portal is deprecated + @jsondata:Name {value: "forum_topic_id"} + int forumTopicId?; + # Write only. A macro ID to be recorded in the ticket audit + @jsondata:Name {value: "macro_id"} + int macroId?; + # The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket + @jsondata:Name {value: "submitter_id"} + int submitterId?; + # The ids of users currently CC'ed on the ticket + @jsondata:Name {value: "collaborator_ids"} + int[] collaboratorIds?; + # The API url of this ticket + string url?; + # Enterprise only. The id of the ticket form to render for the ticket + @jsondata:Name {value: "ticket_form_id"} + int ticketFormId?; + # The group this ticket is assigned to + @jsondata:Name {value: "group_id"} + int groupId?; + # The ids of the followups created from this ticket. Ids are only visible once the ticket is closed + @jsondata:Name {value: "followup_ids"} + int[] followupIds?; + # Is true if any comments are public, false otherwise + @jsondata:Name {value: "is_public"} + boolean isPublic?; + # The original recipient e-mail address of the ticket. Notification emails for the ticket are sent from this address + string recipient?; + # Write only. An object that adds a comment to the ticket. See [Ticket comments](/api-reference/ticketing/tickets/ticket_comments/). To include an attachment with the comment, see [Attaching files](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#attaching-files) + record {} comment?; +}; + +# Represents the Headers record for the operation: RequestUserVerfication +public type RequestUserVerficationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BatchErrorItemAllOf2 record { + @jsondata:Name {value: "trigger_id"} + string triggerId?; +}; + +public type AttachmentUploadResponseUpload record { + AttachmentObject[] attachments?; + AttachmentObject attachment?; + # Token for subsequent request + string token?; +}; + +public type TrialAccountResponse record { + TrialAccountObject account?; +}; + +# Represents the Queries record for the operation: ListComments +public type ListCommentsQueries record { + # One of "agent", "end_user". If not specified it does not filter + string role?; + # Filters the comments from the given datetime + string since?; +}; + +# Represents the Headers record for the operation: UpdateQueue +public type UpdateQueueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListComments +public type ListCommentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ReverseLookupResponse UsersResponse; + +public type AssigneeFieldAssignableAgentObject record { + # URL of Agent's avatar + @jsondata:Name {value: "avatar_url"} + string? avatarUrl?; + # Name of the agent + string name?; + # Agent Support ID + int id?; +}; + +public type InlineResponse2001Count record { + # The time the last count was performed + string refreshed_at?; + # Number of records at the time of the latest count operation + int value?; +}; + +# Represents the Headers record for the operation: UpdateAttachment +public type UpdateAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SkillBasedRoutingAttributesResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + int count?; + SkillBasedRoutingAttributeObject[] attributes?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; +}; + +# Represents the Headers record for the operation: ListViews +public type ListViewsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: MarkManyTicketsAsSpam +public type MarkManyTicketsAsSpamQueries record { + # Comma-separated list of ticket ids + string ids; +}; + +# Represents the Headers record for the operation: MarkTicketAsSpamAndSuspendRequester +public type MarkTicketAsSpamAndSuspendRequesterHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: SetTicketAttributeValues +public type SetTicketAttributeValuesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowSession +public type ShowSessionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerCategoriesResponse record { + @jsondata:Name {value: "trigger_categories"} + TriggerCategoriesResponseTriggerCategories[] triggerCategories?; +}; + +public type TicketImportInput record { + # The conversation between requesters, collaborators, and agents + record {} comments?; + # The value of the subject field for this ticket + string subject?; + # Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) + string description?; + # The agent currently assigned to the ticket + @jsondata:Name {value: "assignee_id"} + int assigneeId?; + # The user who requested this ticket + @jsondata:Name {value: "requester_id"} + int requesterId?; + # The array of tags applied to this ticket + string[] tags?; +}; + +# Represents the Headers record for the operation: ShowOrganizationField +public type ShowOrganizationFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# The active features for an account. See [Active Features](#active-features) +public type AccountSettingsActiveFeaturesObject record { + @jsondata:Name {value: "business_hours"} + boolean businessHours?; + boolean voice?; + @jsondata:Name {value: "fallback_composer"} + boolean fallbackComposer?; + @jsondata:Name {value: "bcc_archiving"} + boolean bccArchiving?; + @jsondata:Name {value: "ticket_tagging"} + boolean ticketTagging?; + @jsondata:Name {value: "benchmark_opt_out"} + boolean benchmarkOptOut?; + @jsondata:Name {value: "allow_email_template_customization"} + boolean allowEmailTemplateCustomization?; + @jsondata:Name {value: "csat_reason_code"} + boolean csatReasonCode?; + boolean twitter?; + @jsondata:Name {value: "satisfaction_prediction"} + boolean satisfactionPrediction?; + @jsondata:Name {value: "customer_satisfaction"} + boolean customerSatisfaction?; + @jsondata:Name {value: "dynamic_contents"} + boolean dynamicContents?; + @jsondata:Name {value: "advanced_analytics"} + boolean advancedAnalytics?; + @jsondata:Name {value: "explore_on_support_pro_plan"} + boolean exploreOnSupportProPlan?; + @jsondata:Name {value: "customer_context_as_default"} + boolean customerContextAsDefault?; + boolean markdown?; + @jsondata:Name {value: "ticket_forms"} + boolean ticketForms?; + @jsondata:Name {value: "agent_forwarding"} + boolean agentForwarding?; + @jsondata:Name {value: "user_org_fields"} + boolean userOrgFields?; + @jsondata:Name {value: "automatic_answers"} + boolean automaticAnswers?; + @jsondata:Name {value: "good_data_and_explore"} + boolean goodDataAndExplore?; + @jsondata:Name {value: "chat_about_my_ticket"} + boolean chatAboutMyTicket?; + @jsondata:Name {value: "topic_suggestion"} + boolean topicSuggestion?; + boolean explore?; + @jsondata:Name {value: "on_hold_status"} + boolean onHoldStatus?; + boolean insights?; + @jsondata:Name {value: "light_agents"} + boolean lightAgents?; + @jsondata:Name {value: "user_tagging"} + boolean userTagging?; + boolean facebook?; + boolean sandbox?; + @jsondata:Name {value: "suspended_ticket_notification"} + boolean suspendedTicketNotification?; + @jsondata:Name {value: "facebook_login"} + boolean facebookLogin?; + @jsondata:Name {value: "rich_content_in_emails"} + boolean richContentInEmails?; + @jsondata:Name {value: "allow_ccs"} + boolean allowCcs?; + @jsondata:Name {value: "explore_on_support_ent_plan"} + boolean exploreOnSupportEntPlan?; + @jsondata:Name {value: "is_abusive"} + boolean isAbusive?; + @jsondata:Name {value: "organization_access_enabled"} + boolean organizationAccessEnabled?; + @jsondata:Name {value: "twitter_login"} + boolean twitterLogin?; + boolean chat?; + @jsondata:Name {value: "custom_dkim_domain"} + boolean customDkimDomain?; + @jsondata:Name {value: "google_login"} + boolean googleLogin?; + @jsondata:Name {value: "forum_analytics"} + boolean forumAnalytics?; +}; + +public type BookmarkResponse record { + BookmarkObject bookmark?; +}; + +public type CountOrganizationObject record { + @jsondata:Name {value: "refreshed_at"} + string refreshedAt?; + int value?; +}; + +# Represents the Headers record for the operation: DeleteResourceCollection +public type DeleteResourceCollectionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowAuditLog +public type ShowAuditLogHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: BulkDeleteAutomations +public type BulkDeleteAutomationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type ChannelFrameworkPushResultsResponse record { + # An array of [result objects](#result-object) + ChannelFrameworkResultObject[] results?; +}; + +public type AutomationObject record { + # The raw title of the automation + @jsondata:Name {value: "raw_title"} + string rawTitle?; + # If true, the automation is a default automation + boolean default?; + # The time of the last update of the automation + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Whether the automation is active + boolean active?; + # The time the automation was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when created + int id?; + # The position of the automation which specifies the order it will be executed + int position?; + ConditionsObject conditions?; + # The title of the automation + string title?; + # An object describing what the automation will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) + ActionObject[] actions?; +}; + +# Represents the Headers record for the operation: DeleteUser +public type DeleteUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type InlineResponse2001 record { + record {|InlineResponse2001Count...;|} count?; +}; + +public type SearchExportResponse record { + # Metadata for the export query response + SearchExportResponseMeta meta?; + # The links to the previous and next entries via the cursor ids in the metadata + SearchExportResponseLinks links?; + # May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object + SearchResultObject[] results?; + # The facets corresponding to the search query + string? facets?; +}; + +public type InlineResponse2003 record { + record {}[] actions?; +}; + +public type InlineResponse2002 record { + MacroObject macro?; +}; + +public type ComplianceDeletionStatusObject record { + @jsondata:Name {value: "account_subdomain"} + string accountSubdomain; + string application; + @jsondata:Name {value: "user_id"} + int userId; + @jsondata:Name {value: "executer_id"} + int? executerId; + string action; + @jsondata:Name {value: "created_at"} + string createdAt; +}; + +public type InlineResponse2005 record { + ActivitiesCountResponseCount count?; +}; + +public type InlineResponse2004 record { + InlineResponse2003 definitions?; +}; + +public type InlineResponse2006 record { + *TriggerCategoriesResponse; + *Pagination; +}; + +public type TicketUpdateRequest record { + TicketUpdateInput ticket?; +}; + +# Brand settings. See [Brands](#brands) +public type AccountSettingsBrandsObject record { + @jsondata:Name {value: "default_brand_id"} + int defaultBrandId?; + @jsondata:Name {value: "require_brand_on_new_tickets"} + boolean requireBrandOnNewTickets?; +}; + +public type PaginationLinks record { + string next?; + string prev?; +}; + +public type OrganizationMembershipObject record { + # Denotes whether the user can or cannot have access to all organization's tickets + @jsondata:Name {value: "view_tickets"} + boolean viewTickets?; + # Denotes whether this is the default organization membership for the user. If false, returns `null` + boolean? default; + # When this record last got updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The ID of the user for whom this memberships belongs + @jsondata:Name {value: "user_id"} + int userId; + # The ID of the organization associated with this user, in this membership + @jsondata:Name {value: "organization_id"} + int organizationId; + # When this record was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when the membership is created + int id?; + # The name of the organization associated with this user, in this membership + @jsondata:Name {value: "organization_name"} + string organizationName?; + # The API url of this membership + string url?; +}; + +public type QueueObjectDefinitionAll record { + string 'field?; + string value?; + string operator?; +}; + +public type TicketMetricEventBaseObject record { + # The instance of the metric associated with the event. See [instance_id](#instance_id) + @jsondata:Name {value: "instance_id"} + int instanceId?; + # The metric being tracked + "agent_work_time"|"pausable_update_time"|"periodic_update_time"|"reply_time"|"requester_wait_time"|"resolution_time" metric?; + # Automatically assigned when the record is created + int id?; + # The time the event occurred + string time?; + # Id of the associated ticket + @jsondata:Name {value: "ticket_id"} + int ticketId?; + # The type of the metric event. See [Ticket metric event types reference](/documentation/ticketing/reference-guides/ticket-metric-event-types-reference) + "activate"|"pause"|"fulfill"|"apply_sla"|"breach"|"update_status"|"measure" 'type?; +}; + +# Represents the Queries record for the operation: ShowManyJobStatuses +public type ShowManyJobStatusesQueries record { + # Comma-separated list of job status ids + string ids; +}; + +public type UserMergeByIdInput record { + int id?; +}; + +public type AssigneeFieldAssignableGroupsAndAgentsSearchResponse record { + # Number of agents + groups listed from search result + int count?; + AssigneeFieldAssignableSearchGroupObject[] groups?; + AssigneeFieldAssignableSearchAgentObject[] agents?; +}; + +# Represents the Queries record for the operation: ShowManyOrganizations +public type ShowManyOrganizationsQueries record { + # A list of organization ids + string ids?; + # A list of external ids + @http:Query {name: "external_ids"} + string externalIds?; +}; + +# Represents the Headers record for the operation: DeleteUserField +public type DeleteUserFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: AutocompleteUsers +public type AutocompleteUsersQueries record { + # The id of a lookup relationship field. The type of field is determined + # by the `source` param + @http:Query {name: "field_id"} + string fieldId?; + # The name to search for the user + string name; + # If a `field_id` is provided, this specifies the type of the field. + # For example, if the field is on a "zen:user", it references a field on a user + string 'source?; +}; + +# Represents the Headers record for the operation: ShowJobStatus +public type ShowJobStatusHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowCustomObjectRecord +public type ShowCustomObjectRecordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: VerifySubdomainAvailability +public type VerifySubdomainAvailabilityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type AuditObject record { + record {} metadata?; + @jsondata:Name {value: "created_at"} + string createdAt?; + int id?; + @jsondata:Name {value: "author_id"} + int authorId?; + @jsondata:Name {value: "ticket_id"} + int ticketId?; + AuditObjectEvents[] events?; + ViaObject via?; +}; + +# Represents the Headers record for the operation: TicketRelatedInformation +public type TicketRelatedInformationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateUser +public type UpdateUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: VerifySubdomainAvailability +public type VerifySubdomainAvailabilityQueries record { + # Specify the name of the subdomain you want to verify. The name can't contain underscores, hyphens, or spaces + string subdomain; +}; + +public type CustomObjectRecordsBulkCreateRequestJob record { + string action?; + # An array of record objects for job actions that create, update, or set. An array of strings for job actions that delete + CustomObjectRecord[] items?; +}; + +public type OrganizationResponse record { + OrganizationObject organization?; +}; + +public type TargetCommonFields record { + # Whether or not the target is activated + boolean active?; + # The time the target was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when created + int id?; + # A name for the target + string title; + # A pre-defined target, such as "basecamp_target". See the additional attributes for the type that follow + string 'type; +}; + +# Represents the Headers record for the operation: DeleteTrigger +public type DeleteTriggerHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateSLAPolicy +public type UpdateSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowCustomRoleById +public type ShowCustomRoleByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type MacroObjectAllOf2 record { + # The app installation that requires each macro, if present + @jsondata:Name {value: "app_installation"} + string? appInstallation?; + # The number of times each macro has been used in the past day + @jsondata:Name {value: "usage_24h"} + int usage24h?; + # The number of times each macro has been used in the past thirty days + @jsondata:Name {value: "usage_30d"} + int usage30d?; + # The number of times each macro has been used in the past hour + @jsondata:Name {value: "usage_1h"} + int usage1h?; + # Permissions for each macro + string? permissions?; + # The macro categories + string? categories?; + # The number of times each macro has been used in the past week + @jsondata:Name {value: "usage_7d"} + int usage7d?; +}; + +public type BulkUpdateDefaultCustomStatusResponse record { +}; + +public type GroupSLAPolicyFilterDefinitionResponseDefinitionsValuesList record { + string title?; + int? value?; +}; + +# Represents the Headers record for the operation: ShowOrganizationSubscription +public type ShowOrganizationSubscriptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: CheckHostMappingValidityForExistingBrand +public type CheckHostMappingValidityForExistingBrandHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: TicketsShowMany +public type TicketsShowManyQueries record { + # Comma-separated list of ticket ids + string ids; +}; + +# Represents the Headers record for the operation: ShowTriggerCategoryById +public type ShowTriggerCategoryByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerBulkUpdateItem record { + # The ID of the new category the trigger is to be moved to + @jsondata:Name {value: "category_id"} + string categoryId?; + # The active status of the trigger (true or false) + boolean active?; + # The ID of the trigger to update + int id; + # The new position of the trigger + int position?; +}; + +# Represents the Headers record for the operation: DynamicContentListVariants +public type DynamicContentListVariantsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowGroupMembershipById +public type ShowGroupMembershipByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SuspendedTicketsExportResponse record { + SuspendedTicketsExportResponseExport export?; +}; + +# Represents the Headers record for the operation: DeleteManyOrganizations +public type DeleteManyOrganizationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: GettingTwicketStatus +public type GettingTwicketStatusHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListSatisfactionRatings +public type ListSatisfactionRatingsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: CheckHostMappingValidity +public type CheckHostMappingValidityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListGroupMembershipsByUserId +public type ListGroupMembershipsByUserIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type V2MacrosBody record { + MacroInput macro?; +}; + +# Represents the Headers record for the operation: MergeEndUsers +public type MergeEndUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Account limits configuration. See [Limits](#limits) +public type AccountSettingsLimitsObject record { + @jsondata:Name {value: "attachment_size"} + int attachmentSize?; +}; + +# Represents the Headers record for the operation: TriggerRevision +public type TriggerRevisionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateUserIdentity +public type UpdateUserIdentityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: BulkPermanentlyDeleteTickets +public type BulkPermanentlyDeleteTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ShowEssentialsCard +public type ShowEssentialsCardHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListUsers +public type ListUsersQueries record { + # Filters the results by role. Possible values are "end-user", "agent", or "admin" + "end-user"|"agent"|"admin" role?; + # Filters the results by more than one role using the format `role[]={role}&role[]={role}` + string roles?; + # List users by external id. External id has to be unique for each user under the same account + @http:Query {name: "external_id"} + string externalId?; + # For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request + @http:Query {name: "permission_set"} + int permissionSet?; +}; + +public type AccountSettingsCdnObjectHosts record { + string name?; + string url?; +}; + +# Represents the Headers record for the operation: ListUsers +public type ListUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SkillBasedRoutingAttributeDefinitionsDefinitions record { + @jsondata:Name {value: "conditions_any"} + SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll[] conditionsAny?; + @jsondata:Name {value: "conditions_all"} + SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll[] conditionsAll?; +}; + +public type DefinitionsResponseDefinitionsConditionsAll record { + boolean nullable?; + DefinitionsResponseDefinitionsOperators[] operators?; + boolean repeatable?; + string subject?; + DefinitionsResponseDefinitionsValues[] values?; + string title?; + string 'type?; + string group?; +}; + +# Represents the Headers record for the operation: UpdateManyUsers +public type UpdateManyUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteTagsTicket +public type DeleteTagsTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type GroupMembershipsResponse record { + @jsondata:Name {value: "group_memberships"} + GroupMembershipObject[] groupMemberships?; +}; + +public type TriggerBulkUpdateRequest record { + TriggerBulkUpdateItem[] triggers?; +}; + +# Represents the Headers record for the operation: ShowCustomObjectField +public type ShowCustomObjectFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type SLAPolicyFilterConditionObject record { + # The name of a ticket field + string 'field?; + # The value of a ticket field + string|(string|int)[] value?; + # A comparison operator + string operator?; +}; + +# Represents the Queries record for the operation: ListTriggers +public type ListTriggersQueries record { + # Filter triggers by category ID + @http:Query {name: "category_id"} + string categoryId?; + # Filter by active triggers if true or inactive triggers if false + boolean active?; + # Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position" + string sort?; + # Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +# Represents the Headers record for the operation: DeleteCustomObjectRecord +public type DeleteCustomObjectRecordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteRecipientAddress +public type DeleteRecipientAddressHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: DeleteView +public type DeleteViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: UpdateWorkspace +public type UpdateWorkspaceHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Billing configuration options. See [Billing](#billing) +public type AccountSettingsBillingObject record { + string backend?; +}; + +public type CustomStatusCreateInput record { + *CustomStatusUpdateInput; + *CustomStatusCreateInputAllOf2; +}; + +public type MacroUpdateManyInputMacros record { + # The active status of the macro (true or false) + boolean active?; + # The ID of the macro to update + int id; + # The new position of the macro + int position?; +}; + +# An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) +public type ViaObject record { + # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" + string channel?; + # For some channels a source object gives more information about how or why the ticket or event was created + ViaObjectSource 'source?; }; -public type RequestResponse record { - RequestObject? request?; +# Represents the Headers record for the operation: DeleteCustomRoleById +public type DeleteCustomRoleByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ComplianceDeletionStatusesResponse record { - ComplianceDeletionStatusObject[]? compliance_deletion_statuses?; +# Represents the Headers record for the operation: CreateUserIdentity +public type CreateUserIdentityHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type V2_workspaces_body record { - WorkspaceInput? workspace?; +public type UserCreateInputOrganization record { + string name; }; -public type TicketFieldCustomStatusObject record { - # If true, if the custom status is set to active. If false, the custom status is set to inactive - boolean? active?; - # The label displayed to agents - string? agent_label?; - # The date and time at which the custom ticket status was created - string? created_at?; - # If true, the custom status is set to default. If false, the custom status is set to non-default - boolean? default?; - # The description of when the user should select this custom ticket status - string? description?; - # The description displayed to end users - string? end_user_description?; - # The label displayed to end users - string? end_user_label?; - # Automatically assigned when the custom ticket status is created - int? id?; - # The status category the custom ticket status belongs to - "new"|"open"|"pending"|"hold"|"solved" status_category?; - # The date and time at which the custom ticket status was last updated - string? updated_at?; +# Represents the Headers record for the operation: DeleteManyOrganizationMemberships +public type DeleteManyOrganizationMembershipsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AccountSettingsResponse record { - AccountSettingsObject? settings?; +# Represents the Headers record for the operation: ListTriggerRevisions +public type ListTriggerRevisionsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomObjectResponse record { - CustomObject? custom_object?; +public type GroupSLAPolicyObject record { + GroupSLAPolicyFilterObject filter; + # The time of the last update of the Group SLA policy + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Array of [policy metric](#policy-metric) objects + @jsondata:Name {value: "policy_metrics"} + GroupSLAPolicyMetricObject[] policyMetrics?; + # The time the Group SLA policy was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # The description of the Group SLA policy + string description?; + # Automatically assigned when created + string id?; + # Position of the Group SLA policy. This position determines the order in which policies are matched to tickets. If not specified, the Group SLA policy is added at the last position + int position?; + # The title of the Group SLA policy + string title; + # URL of the Group SLA policy record + string url?; }; -public type AttachmentUploadResponse_upload record { - # A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - AttachmentObject? attachment?; - AttachmentObject[]? attachments?; - # Token for subsequent request - string? token?; +public type TicketMetricTimeObject record { + # Time in calendar hours + int calendar?; + # Time in business hours + int business?; }; -# X (formerly Twitter) settings. See [X](#x-formerly-twitter) -public type AccountSettingsTwitterObject record { - string? shorten_url?; +# Represents the Queries record for the operation: UpdateManyUsers +public type UpdateManyUsersQueries record { + # Id of the users to update. Comma separated + string ids?; + # External Id of the users to update. Comma separated + @http:Query {name: "external_ids"} + string externalIds?; +}; + +# Represents the Headers record for the operation: UpdateCustomRoleById +public type UpdateCustomRoleByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomObjectRecordsJobsResponse record { - CustomObjectRecordsJobsResponse_job_status? job_status?; + @jsondata:Name {value: "job_status"} + CustomObjectRecordsJobsResponseJobStatus jobStatus?; }; public type IncrementalSkillBasedRouting record { + # The URL that should be called to get the next set of results + @jsondata:Name {value: "next_page"} + string nextPage?; + # Routing instance values + @jsondata:Name {value: "instance_values"} + IncrementalSkillBasedRoutingInstanceValue[] instanceValues?; # Routing attribute values - IncrementalSkillBasedRoutingAttributeValue[]? attribute_values?; - # Routing attributes - IncrementalSkillBasedRoutingAttribute[]? attributes?; + @jsondata:Name {value: "attribute_values"} + IncrementalSkillBasedRoutingAttributeValue[] attributeValues?; # The number of results returned for the current request - int? count?; + int count?; # The most recent resource creation time present in this result set in Unix epoch time - int? end_time?; - # Routing instance values - IncrementalSkillBasedRoutingInstanceValue[]? instance_values?; - # The URL that should be called to get the next set of results - string? next_page?; -}; - -public type ResourceCollectionObject_resources record { - boolean? deleted?; - string? identifier?; - int? resource_id?; - string? 'type?; -}; - -public type AssigneeFieldAssignableGroupAgentsResponse record { - AssigneeFieldAssignableAgentObject[]? agents?; - # Number of agents listed in `agents` property. - int? count?; - string? next_page?; - string? previous_page?; -}; - -public type SkillBasedRoutingAttributeDefinitions record { - SkillBasedRoutingAttributeDefinitions_definitions? definitions?; + @jsondata:Name {value: "end_time"} + int endTime?; + # Routing attributes + IncrementalSkillBasedRoutingAttribute[] attributes?; }; -public type CustomRoleResponse record { - CustomRoleObject? custom_role?; +# Represents the Queries record for the operation: GettingTwicketStatus +public type GettingTwicketStatusQueries record { + # Optional comment ids to retrieve tweet information for only particular comments + string ids?; }; -public type UsersRequest record { - UserInput[]? users; +# Represents the Headers record for the operation: CreateDynamicContentVariant +public type CreateDynamicContentVariantHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TriggerDefinitionObject record { - TriggerActionDefinitionObject[]? actions?; - TriggerConditionDefinitionObjectAll[]? conditions_all?; - TriggerConditionDefinitionObjectAny[]? conditions_any?; -}; - -public type ListTicketFollowersResponse record { -}; - -public type AttachmentUpdateRequest record { - AttachmentUpdateInput? attachment?; + @jsondata:Name {value: "conditions_any"} + TriggerConditionDefinitionObjectAny[] conditionsAny?; + @jsondata:Name {value: "conditions_all"} + TriggerConditionDefinitionObjectAll[] conditionsAll?; + TriggerActionDefinitionObject[] actions?; }; -public type DynamicContentResponse record { - DynamicContentObject? item?; +# Represents the Queries record for the operation: DeleteManyOrganizations +public type DeleteManyOrganizationsQueries record { + # A list of organization ids + string ids?; + # A list of external ids + @http:Query {name: "external_ids"} + string externalIds?; }; # Internationalization configuration settings. See [Localization](#localization) public type AccountSettingsLocalizationObject record { - int[]? locale_ids?; + @jsondata:Name {value: "locale_ids"} + int[] localeIds?; }; -public type UserForEndUser record { - # The time the user was created - string? created_at?; - # The primary email address of this user. If the primary email address is not [verified](https://support.zendesk.com/hc/en-us/articles/4408886752410), the secondary email address is used - string? email?; - # The time zone for the user - string? iana_time_zone?; - # Automatically assigned when creating users - int? id?; - # The locale for this user - string? locale?; - # The language identifier for this user - int? locale_id?; - # The name of the user - string? name; - # The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](/api-reference/ticketing/users/users/#organization-id) - int? organization_id?; - # The primary phone number of this user. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API - string? phone?; - # The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - record {}? photo?; - # The role of the user. Possible values: `"end-user"`, `"agent"`, `"admin"` - string? role?; - # Whether the `phone` number is shared or not. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API - boolean? shared_phone_number?; - # The time-zone of this user - string? time_zone?; - # The time of the last update of the user - string? updated_at?; - # The API url of this user - string? url?; - # Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) - boolean? verified?; +# Represents the Headers record for the operation: ShowTicketForm +public type ShowTicketFormHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type SkillBasedRoutingTicketFulfilledResponse record { - int[]? fulfilled_ticket_ids?; + @jsondata:Name {value: "fulfilled_ticket_ids"} + int[] fulfilledTicketIds?; }; -public type BrandUpdateRequest record { - BrandObject? brand?; +# Chat event object +public type TicketChatCommentRedactionResponseChatEvent record { + # Id assigned to the chat event object + int id?; + # Type of chat event + string 'type?; + # The value of the chat event object + TicketChatCommentRedactionResponseChatEventValue value?; }; public type OrganizationFieldsResponse record { - # Total count of records retrieved - int? count?; # URL of the next page - string? next_page?; - OrganizationFieldObject[]? organization_fields?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "organization_fields"} + OrganizationFieldObject[] organizationFields?; + # Total count of records retrieved + int count?; # URL of the previous page - string? previous_page?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; }; # Cross Sell settings public type AccountSettingsCrossSellObject record { - boolean? show_chat_tooltip?; - string? xsell_source?; + @jsondata:Name {value: "show_chat_tooltip"} + boolean showChatTooltip?; + @jsondata:Name {value: "xsell_source"} + string? xsellSource?; }; public type DeletedUsersResponse record { - DeletedUserObject[]? deleted_users?; + @jsondata:Name {value: "deleted_users"} + DeletedUserObject[] deletedUsers?; }; -# An object that describes the conditions a ticket must match for a Group SLA policy to be applied to the ticket. See [Filter](#filter). -public type GroupSLAPolicyFilterObject record { - GroupSLAPolicyFilterConditionObject[]? all?; +# Represents the Headers record for the operation: ShowMacro +public type ShowMacroHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type SuspendedTicketsAttachmentsResponse record { - SuspendedTicketsAttachmentsResponse_upload? upload?; + SuspendedTicketsAttachmentsResponseUpload upload?; }; -public type TwitterChannelObject record { - # If replies are allowed for this handle - boolean? allow_reply?; - # The profile image url of the handle - string? avatar_url?; - # What brand the handle is associated with - int? brand_id?; - # If replies are allowed for this handle - boolean? can_reply?; - # The time the handle was created - string? created_at?; - # Automatically assigned upon creation - int? id; - # The profile name of the handle - string? name?; - # The Twitter handle - string? screen_name; - # The country's code - int? twitter_user_id; - # The time of the last update of the handle - string? updated_at?; +public type TriggerRevisionResponseTriggerRevisionSnapshot record { + boolean active?; + string? description?; + TriggerConditionsObject conditions?; + string title?; + TriggerActionObject[] actions?; }; -public type GroupSLAPolicyFilterConditionObject record { - # The name of a ticket field - string? 'field?; - # A comparison operator - string? operator?; - # The value of a ticket field - (string|int?)[]? value?; +# Represents the Headers record for the operation: ShowDeletedUser +public type ShowDeletedUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SharingAgreementResponse record { - SharingAgreementObject? sharing_agreement?; +# Represents the Headers record for the operation: DestroyManyWorkspaces +public type DestroyManyWorkspacesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type QueueObject record { - # The time the queue was created - string? created_at?; - # Conditions when queue could be applied - QueueObject_definition? definition?; - # The description of the queue - string? description?; - # Automatically assigned when creating queue - string? id?; - # The name of the queue - string? name?; - # The queue-applied order - int? 'order?; - # Primary group ids linked to the queue - QueueObject_primary_groups? primary_groups?; - # The queue-applied priority - int? priority?; - # Secondary group ids linked to the queue - QueueObject_secondary_groups? secondary_groups?; - # The time of the queue's last update - string? updated_at?; - # The API URL of the queue - string? url?; +# Represents the Queries record for the operation: LogoutManyUsers +public type LogoutManyUsersQueries record { + # Accepts a comma-separated list of up to 100 user ids + string ids?; }; -public type TriggerWithCategoryRequest record { - TriggerObject?? trigger?; +public type SuspendedTicketsAttachmentsResponseUpload record { + AttachmentObject[] attachments?; + # Token for subsequent request + string token?; }; -public type GroupsResponse record { - GroupObject[]? groups?; +# Represents the Headers record for the operation: DeleteBookmark +public type DeleteBookmarkHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Inline_response_201 record { - WorkspaceObject? workspace?; +# Represents the Headers record for the operation: ListTickets +public type ListTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Inline_response_200 record { - boolean? success?; +# Represents the Queries record for the operation: CountSearchResults +public type CountSearchResultsQueries record { + # The search query + string query; }; -public type SkillBasedRoutingAttributeDefinitions_definitions_conditions_all record { - string? subject?; - string? title?; +public type GroupsResponse record { + GroupObject[] groups?; }; public type AuditLogObject record { - # Type of change made. Possible values are "create", "destroy", "exported", "login", and "update" - string? action?; - # Localized string of action field - string? action_label?; - # id of the user or system that initiated the change - int? actor_id?; - # Name of the user or system that initiated the change - string? actor_name?; # The description of the change that occurred - string? change_description?; - # The time the audit got created - string? created_at?; - # The id automatically assigned upon creation - int? id?; - # The IP address of the user doing the audit - string? ip_address?; - # The id of the item being audited - int? source_id?; + @jsondata:Name {value: "change_description"} + string changeDescription?; # The name of the item being audited - string? source_label?; + @jsondata:Name {value: "source_label"} + string sourceLabel?; + # Name of the user or system that initiated the change + @jsondata:Name {value: "actor_name"} + string actorName?; + # Type of change made. Possible values are "create", "destroy", "exported", "login", and "update" + string action?; + # The time the audit got created + @jsondata:Name {value: "created_at"} + string createdAt?; # Item type being audited. Typically describes the system where the change # was initiated. Possible values vary based on your account's Zendesk # products and activity. Common values include "apitoken", "rule", "ticket", @@ -1685,467 +5336,447 @@ public type AuditLogObject record { # [triggers](https://support.zendesk.com/hc/en-us/articles/4408822236058), # [views](https://support.zendesk.com/hc/en-us/articles/4408888828570), # and other automated business rules - string? source_type?; + @jsondata:Name {value: "source_type"} + string sourceType?; + # id of the user or system that initiated the change + @jsondata:Name {value: "actor_id"} + int actorId?; + # The id automatically assigned upon creation + int id?; + # The IP address of the user doing the audit + @jsondata:Name {value: "ip_address"} + string ipAddress?; + # The id of the item being audited + @jsondata:Name {value: "source_id"} + int sourceId?; + # Localized string of action field + @jsondata:Name {value: "action_label"} + string actionLabel?; # The URL to access the audit log - string? url?; -}; - -public type GroupSLAPolicyFilterDefinitionResponse_definitions_operators record { - string? title?; - string? value?; + string url?; }; public type ActivityResponse record { - ActivityObject? activity?; + ActivityObject activity?; }; public type CustomObjectRecordsUpsertRequest record { - CustomObjectRecord? custom_object_record?; + @jsondata:Name {value: "custom_object_record"} + CustomObjectRecord customObjectRecord?; +}; + +# Represents the Queries record for the operation: ListCustomObjectRecords +public type ListCustomObjectRecordsQueries record { + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[before]"} + string pageBefore?; + # One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending + string sort?; + # Optional comma-separated list of external ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive + @http:Query {name: "filter[external_ids]"} + string filterExternalIds?; + # Specifies how many records should be returned in the response. You can specify up to 100 records per page + @http:Query {name: "page[size]"} + int pageSize?; + # Optional comma-separated list of ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive + @http:Query {name: "filter[ids]"} + string filterIds?; + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[after]"} + string pageAfter?; +}; + +public type SLAPolicyFilterDefinitionResponseDefinitionsValuesList record { + string title?; + string? value?; }; -public type CustomStatusUpdateRequest record { - CustomStatusUpdateInput? custom_status?; +# Represents the Headers record for the operation: CloneTicketForm +public type CloneTicketFormHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Workspaces_reorder_body record { - decimal[]? ids?; +public type TicketsResponse record { + TicketObject[] tickets?; }; -public type Users_update_many_body UserRequest|UsersRequest?; - -public type TicketsResponse record { - TicketObject[]? tickets?; +# Represents the Headers record for the operation: AutocompleteUsers +public type AutocompleteUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ViewObject record { - # Whether the view is active - boolean? active?; - # Describes how the view is constructed. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - record {}? conditions?; - # The time the view was created - string? created_at?; - # If true, the view is a default view - boolean? default?; - # The description of the view - string? description?; - # Describes how the view should be executed. See [Execution](#execution) - record {}? execution?; - # Automatically assigned when created - int? id?; - # The position of the view - int? position?; - # Who may access this account. Is null when everyone in the account can access it - record {}? restriction?; - # The title of the view - string? title?; - # The time the view was last updated - string? updated_at?; +# Represents the Headers record for the operation: ShowManyOrganizations +public type ShowManyOrganizationsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SuspendedTicketResponse record { - SuspendedTicketObject[]? suspended_ticket?; +# Represents the Headers record for the operation: ShowOrganization +public type ShowOrganizationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; # An object that describes the conditions under which the automation will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) public type ConditionsObject record { # Logical AND. Tickets must fulfill all of the conditions to be considered matching - ConditionObject[]? all?; + ConditionObject[] all?; # Logical OR. Tickets may satisfy any of the conditions to be considered matching - ConditionObject[]? 'any?; -}; - -public type OrganizationsRelatedResponse record { - OrganizationMetadataObject? organization_related?; + ConditionObject[] 'any?; }; -public type TriggerRevisionResponse_trigger_revision record { - int? author_id?; - string? created_at?; - int? id?; - TriggerRevisionResponse_trigger_revision_snapshot? snapshot?; - string? url?; +# Represents the Headers record for the operation: UpdateAttribute +public type UpdateAttributeHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BatchJobRequest_job_items record { - TriggerCategoryBatchRequest[]? trigger_categories?; - TriggerBatchRequest[]? triggers?; +# The links to the previous and next entries via the cursor ids in the metadata +public type SearchExportResponseLinks record { + # The url to the next entry via the cursor + string? next?; + # The url to the previous entry via the cursor + string? prev?; }; # Side conversations settings public type AccountSettingsSideConversationsObject record { - boolean? email_channel?; - boolean? msteams_channel?; - boolean? show_in_context_panel?; - boolean? slack_channel?; - boolean? tickets_channel?; -}; - -public type GroupSLAPoliciesResponse record { - int? count?; - GroupSLAPolicyObject[]? group_sla_policies?; - string? next_page?; - string? previous_page?; -}; - -# API configuration options. See [API](#api) -public type AccountSettingsApiObject record { - boolean? accepted_api_agreement?; - string? api_password_access?; - string? api_token_access?; + @jsondata:Name {value: "tickets_channel"} + boolean ticketsChannel?; + @jsondata:Name {value: "slack_channel"} + boolean slackChannel?; + @jsondata:Name {value: "email_channel"} + boolean emailChannel?; + @jsondata:Name {value: "show_in_context_panel"} + boolean showInContextPanel?; + @jsondata:Name {value: "msteams_channel"} + boolean msteamsChannel?; +}; + +public type ProblemsAutocompleteBody record { + # The text to search for + string text?; }; public type OrganizationMembershipResponse record { - OrganizationMembershipObject? organization_membership?; -}; - -public type CustomObjectRecordsBulkCreateRequest_job record { - string? action?; - # An array of record objects for job actions that create, update, or set. An array of strings for job actions that delete. - CustomObjectRecord[]? items?; + @jsondata:Name {value: "organization_membership"} + OrganizationMembershipObject organizationMembership?; }; # User settings. See [Users](#users) public type AccountSettingsUserObject record { - boolean? agent_created_welcome_emails?; - boolean? end_user_phone_number_validation?; - boolean? have_gravatars_enabled?; - boolean? language_selection?; - boolean? multiple_organizations?; - boolean? tagging?; - boolean? time_zone_selection?; + boolean tagging?; + @jsondata:Name {value: "end_user_phone_number_validation"} + boolean endUserPhoneNumberValidation?; + @jsondata:Name {value: "agent_created_welcome_emails"} + boolean agentCreatedWelcomeEmails?; + @jsondata:Name {value: "language_selection"} + boolean languageSelection?; + @jsondata:Name {value: "multiple_organizations"} + boolean multipleOrganizations?; + @jsondata:Name {value: "time_zone_selection"} + boolean timeZoneSelection?; + @jsondata:Name {value: "have_gravatars_enabled"} + boolean haveGravatarsEnabled?; }; public type GroupsCountObject record { - GroupsCountObject_count? count?; + GroupsCountObjectCount count?; +}; + +public type ResourceCollectionObjectResources record { + string identifier?; + boolean deleted?; + @jsondata:Name {value: "resource_id"} + int resourceId?; + string 'type?; }; public type MacroAttachmentObject record { + # The name of the image file + string filename?; # The content type of the image. Example value: "image/png" - string? content_type?; - # A full URL where the attachment image file can be downloaded - string? content_url?; + @jsondata:Name {value: "content_type"} + string contentType?; + # The size of the image file in bytes + int size?; # The time when this attachment was created - string? created_at?; - # The name of the image file - string? filename?; + @jsondata:Name {value: "created_at"} + string createdAt?; + # A full URL where the attachment image file can be downloaded + @jsondata:Name {value: "content_url"} + string contentUrl?; # Automatically assigned when created - int? id?; - # The size of the image file in bytes - int? size?; + int id?; }; public type CustomObjectsResponse record { - CustomObject[]? custom_objects?; + @jsondata:Name {value: "custom_objects"} + CustomObject[] customObjects?; }; -public type UsersResponse record { - UserObject[]? users?; +public type CustomObjectRecordsResponseMeta record { + @jsondata:Name {value: "after_cursor"} + string? afterCursor; + @jsondata:Name {value: "before_cursor"} + string? beforeCursor; + @jsondata:Name {value: "has_more"} + boolean hasMore; }; -public type CustomObjectRecordsResponse_meta record { - string? after_cursor; - string? before_cursor; - boolean? has_more; +public type InlineResponse201 record { + WorkspaceObject workspace?; }; -public type GroupSLAPolicyFilterDefinitionResponse record { - GroupSLAPolicyFilterDefinitionResponse_definitions? definitions?; +public type InlineResponse200 record { + boolean success?; }; -public type DefinitionsResponse_definitions_operators record { - boolean? terminal?; - string? title?; - string? value?; +# Represents the Headers record for the operation: UpdateCustomObject +public type UpdateCustomObjectHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type PushNotificationDevicesRequest record { - PushNotificationDevicesInput? push_notification_devices?; +public type GroupSLAPolicyFilterDefinitionResponse record { + GroupSLAPolicyFilterDefinitionResponseDefinitions definitions?; }; -public type SLAPolicyFilterDefinitionResponse_definitions_values_list record { +public type ViaObjectSourceFrom record { + string? address?; + string? name?; + int? id?; string? title?; - string? value?; -}; - -public type CustomStatusCreateRequest record { - CustomStatusCreateInput? custom_status?; }; -# An object that describes the conditions that a ticket must match in order for an SLA policy to be applied to that ticket. See [Filter](#filter). -public type SLAPolicyFilterObject record { - SLAPolicyFilterConditionObject[]? all?; - SLAPolicyFilterConditionObject[]? 'any?; -}; - -public type AssigneeFieldAssignableSearchAgentObject record { - # Name of the agent's group - string? group?; - # Agent's Group ID - int? group_id?; - # Agent ID - int? id?; - # Name of the agent - string? name?; - # URL of Avatar - string? photo_url?; +# Represents the Headers record for the operation: UpdateView +public type UpdateViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TargetTwitter record { - # only writable - string? secret?; - string? token?; +# Represents the Queries record for the operation: ReorderSLAPolicies +public type ReorderSLAPoliciesQueries record { + # The IDs of the SLA Policies to reorder + @http:Query {name: "sla_policy_ids"} + int[] slaPolicyIds?; }; public type DynamicContentsResponse record { - DynamicContentObject[]? items?; -}; - -public type TriggerCategoryId string?; - -public type TargetEmail record { - string? email; - string? subject; + DynamicContentObject[] items?; }; -public type TwitterChannelTwicketStatusResponse_statuses record { - boolean? favorited?; - int? id?; - boolean? retweeted?; - boolean? user_followed?; +public type AuditObjectEvents record { + int id?; + string body?; + string 'type?; + string|int value?; + @jsondata:Name {value: "field_name"} + string fieldName?; }; public type JobStatusesResponse record { - JobStatusObject[]? job_statuses; -}; - -public type Error record { - string? code; - string? detail?; - string? id?; - record {}? links?; - record {}? 'source?; - string? status?; - string? title; + @jsondata:Name {value: "job_statuses"} + JobStatusObject[] jobStatuses; }; -public type TicketMetricEventUpdateStatusObject record { - *TicketMetricEventBaseObject; - # Available if `type` is `update_status`. Minutes since the metric has been open. See [status](#status) - record {}? status?; +# Represents the Queries record for the operation: ListSearchResults +public type ListSearchResultsQueries record { + # The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) + string query; + # One of `updated_at`, `created_at`, `priority`, `status`, or `ticket_type`. Defaults to sorting by relevance + @http:Query {name: "sort_by"} + string sortBy?; + # One of `asc` or `desc`. Defaults to `desc` + @http:Query {name: "sort_order"} + string sortOrder?; }; -public type AuditLogResponse record { - AuditLogObject? audit_log?; +# Represents the Headers record for the operation: ShowSharingAgreement +public type ShowSharingAgreementHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ResourceCollectionResponse record { - ResourceCollectionObject? resource_collection?; +public type Error record { + string code; + record {} links?; + string detail?; + string id?; + record {} 'source?; + string title; + string status?; }; -public type TargetObject TargetCommonFields?; - -public type SystemFieldOptionObject record { - # Name of the system field option - string? name?; - # Value of the system field option - string? value?; -}; +public type TargetObject TargetCommonFields; -public type QueuesResponse record { - QueueObject[]? queues?; +# Represents the Headers record for the operation: ListTriggerCategories +public type ListTriggerCategoriesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AuditLogsResponse record { - AuditLogObject[]? audit_logs?; +# Represents the Headers record for the operation: DeleteBrand +public type DeleteBrandHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TagListTagObject record { - # The number of tags - int? count?; - # A name for the tag - string? name?; +public type QueuesResponse record { + QueueObject[] queues?; }; -public type CurrentUserResponse record { - UserObject?? user?; +# Represents the Queries record for the operation: DestroyManyWorkspaces +public type DestroyManyWorkspacesQueries record { + # The ids of the workspaces to delete + int[] ids; }; -public type ViewResponse record { - record {}[]? columns?; - record {}[]? groups?; - record {}[]? rows?; - ViewObject? view?; +# Represents the Headers record for the operation: CreateOrUpdateTicketFieldOption +public type CreateOrUpdateTicketFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomObjectFieldsResponse record { - CustomObjectField[]? custom_object_fields?; -}; - -public type V2_trigger_categories_body record { - record {*TriggerCategoryRequest; *TriggerCategoryRequestRequired;}? trigger_category?; -}; - -public type UserIdentitiesResponse record { - UserIdentityObject[]? identities?; + @jsondata:Name {value: "custom_object_fields"} + CustomObjectField[] customObjectFields?; }; public type TriggerCategory record { - string? created_at?; - string? id?; - string? name?; - int? position?; - string? updated_at?; -}; - -public type TriggerResponse record { - TriggerObject? trigger?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; + string name?; + @jsondata:Name {value: "created_at"} + string createdAt?; + string id?; + int position?; }; -public type DefinitionsResponse_definitions record { - DefinitionsResponse_definitions_conditions_all[]? conditions_all?; - DefinitionsResponse_definitions_conditions_all[]? conditions_any?; +# Represents the Queries record for the operation: ListTickets +public type ListTicketsQueries record { + # Lists tickets by external id. External ids don't have to be unique for each ticket. As a result, the request may return multiple tickets with the same external id + @http:Query {name: "external_id"} + string externalId?; }; -public type DynamicContentObject record { - # When this record was created - string? created_at?; - # The default locale for the item. Must be one of the [locales the account has active](/api-reference/ticketing/account-configuration/locales/#list-locales). - int? default_locale_id; - # Automatically assigned when creating items - int? id?; - # The unique name of the item - string? name; - # Indicates the item has outdated variants within it - boolean? outdated?; - # Automatically generated placeholder for the item, derived from name - string? placeholder?; - # When this record was last updated - string? updated_at?; - # The API url of this item - string? url?; - # All variants within this item. See [Dynamic Content Item Variants](/api-reference/ticketing/ticket-management/dynamic_content_item_variants/) - DynamicContentVariantObject[]? variants; +# Represents the Headers record for the operation: DeleteOrganizationField +public type DeleteOrganizationFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type RequestObject record { - # The id of the assignee if the field is visible to end users - int? assignee_id?; - # If true, an end user can mark the request as solved. See [Update Request](/api-reference/ticketing/tickets/ticket-requests/#update-request) - boolean? can_be_solved_by_me?; - # The ids of users currently CC'ed on the ticket - int[]? collaborator_ids?; - # When this record was created - string? created_at?; - # Custom fields for the request. See [Setting custom field values](/api-reference/ticketing/tickets/tickets/#setting-custom-field-values) in the Tickets doc - MacroApplyTicketResponse_result_ticket_fields[]? custom_fields?; - # The custom ticket status id of the ticket - int? custom_status_id?; - # Read-only first comment on the request. When [creating a request](#create-request), use `comment` to set the description - string? description?; - # When the task is due (only applies if the request is of type "task") - string? due_at?; - # The ids of users who are currently email CCs on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center - int[]? email_cc_ids?; - # The id of the original ticket if this request is a follow-up ticket. See [Create Request](#create-request) - int? followup_source_id?; - # The id of the assigned group if the field is visible to end users - int? group_id?; - # Automatically assigned when creating requests - int? id?; - # Is true if any comments are public, false otherwise - boolean? is_public?; - # The organization of the requester - int? organization_id?; - # The priority of the request, "low", "normal", "high", "urgent" - string? priority?; - # The original recipient e-mail address of the request - string? recipient?; - # The id of the requester - int? requester_id?; - # Whether or not request is solved (an end user can set this if "can_be_solved_by_me", above, is true for that user) - boolean? solved?; - # The state of the request, "new", "open", "pending", "hold", "solved", "closed" - string? status?; - # The value of the subject field for this request if the subject field is visible to end users; a truncated version of the description otherwise - string? subject; - # The numeric id of the ticket form associated with this request if the form is visible to end users - only applicable for enterprise accounts - int? ticket_form_id?; - # The type of the request, "question", "incident", "problem", "task" - string? 'type?; - # When this record last got updated - string? updated_at?; - # The API url of this request - string? url?; - # Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - TicketAuditViaObject? via?; +# Represents the Headers record for the operation: LogoutManyUsers +public type LogoutManyUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketAuditsResponse record { - string? after_cursor?; - string? after_url?; - TicketAuditObject[]? audits?; - string? before_cursor?; - string? before_url?; +# Represents the Headers record for the operation: UpdateGroupSLAPolicy +public type UpdateGroupSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type OrganizationMembershipsResponse record { - OrganizationMembershipObject[]? organization_memberships?; +public type TriggerRevisionResponseTriggerRevision record { + @jsondata:Name {value: "created_at"} + string createdAt?; + int id?; + @jsondata:Name {value: "author_id"} + int authorId?; + TriggerRevisionResponseTriggerRevisionSnapshot snapshot?; + string url?; }; public type SessionObject record { + # The id of the user + @jsondata:Name {value: "user_id"} + int? userId?; # When the session was created - string? authenticated_at?; + @jsondata:Name {value: "authenticated_at"} + string? authenticatedAt?; # Automatically assigned when the session is created - int? id; - # The last approximate time this session was seen. This does not update on every request. - string? last_seen_at?; + int id; + # The last approximate time this session was seen. This does not update on every request + @jsondata:Name {value: "last_seen_at"} + string? lastSeenAt?; # The API URL of this session string? url?; - # The id of the user - int? user_id?; +}; + +# Represents the Headers record for the operation: UpdateTarget +public type UpdateTargetHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type RelationshipFilterDefinitionResponse record { - RelationshipFilterDefinition? definitions?; + RelationshipFilterDefinition definitions?; }; public type SatisfactionReasonObject record { - # The time the reason was created - string? created_at?; - # The time the reason was deleted - string? deleted_at?; - # Automatically assigned upon creation - int? id?; - # The dynamic content placeholder, if present, or the current "value", if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_value?; # An account-level code for referencing the reason. Custom reasons are assigned an auto-incrementing integer (non-system reason codes begin at 1000). See [Reason codes](#reason-codes) - int? reason_code?; + @jsondata:Name {value: "reason_code"} + int reasonCode?; + # The dynamic content placeholder, if present, or the current "value", if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_value"} + string rawValue?; # The time the reason was updated - string? updated_at?; - # API URL for the resource - string? url?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The time the reason was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned upon creation + int id?; + # The time the reason was deleted + @jsondata:Name {value: "deleted_at"} + string deletedAt?; # Translated value of the reason in the account locale - string? value; + string value; + # API URL for the resource + string url?; }; -public type Workspaces_workspace_id_body record { - WorkspaceInput? workspace?; +# Represents the Headers record for the operation: UpdateBrand +public type UpdateBrandHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TagCountObject record { - # The time that the count value was last refreshed - string? refreshed_at?; - # The count of tags created in the last 24 hours - int? value?; +# Represents the Queries record for the operation: ListTicketMetricEvents +public type ListTicketMetricEventsQueries record { + # The Unix UTC epoch time of the oldest event you're interested in. Example: 1332034771 + @http:Query {name: "start_time"} + int startTime; +}; + +# Represents the Headers record for the operation: DeleteSharingAgreement +public type DeleteSharingAgreementHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type ActivitiesResponse record { - ActivityObject[]? activities?; - record {}[]? actors?; - int? count?; - string? next_page?; - string? previous_page?; - record {}[]? users?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + record {}[] actors?; + ActivityObject[] activities?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; + record {}[] users?; +}; + +# Represents the Queries record for the operation: DestroyManyUsers +public type DestroyManyUsersQueries record { + # Id of the users to delete. Comma separated + string ids?; + # External Id of the users to delete. Comma separated + @http:Query {name: "external_ids"} + string externalIds?; }; public type ListTicketIncidentsResponse record { @@ -2153,996 +5784,913 @@ public type ListTicketIncidentsResponse record { # Support UI settings. See [Lotus](#lotus) public type AccountSettingsLotusObject record { - int? pod_id?; - boolean? prefer_lotus?; - boolean? reporting?; + @jsondata:Name {value: "pod_id"} + int podId?; + @jsondata:Name {value: "prefer_lotus"} + boolean preferLotus?; + boolean reporting?; +}; + +# Represents the Queries record for the operation: DeleteManyMacros +public type DeleteManyMacrosQueries record { + # The IDs of the macros to delete + int[] ids; }; public type DefinitionsResponse record { - DefinitionsResponse_definitions? definitions?; + DefinitionsResponseDefinitions definitions?; +}; + +public type TriggerConditionDefinitionObjectAny record { + boolean nullable?; + DefinitionsResponseDefinitionsOperators[] operators?; + boolean repeatable?; + string subject?; + string title?; + string 'type?; + string group?; }; public type TriggerChangeObject record { # One of `-`, `+`, `=` representing the type of change - string? change?; + string change?; # The value of the item it represents - boolean|string|int|(string|int|boolean?)[]? content?; + boolean|string|int|(string|int|boolean)[] content?; }; -public type TriggerConditionDefinitionObjectAny record { - string? group?; - boolean? nullable?; - DefinitionsResponse_definitions_operators[]? operators?; - boolean? repeatable?; - string? subject?; - string? title?; - string? 'type?; +# Represents the Queries record for the operation: TicketImport +public type TicketImportQueries record { + # If `true`, any ticket created with a `closed` status bypasses the normal ticket lifecycle and will be created directly in your ticket archive + @http:Query {name: "archive_immediately"} + boolean archiveImmediately?; }; public type MacroResponse record { - MacroObject? macro?; -}; - -public type AttachmentThumbnails record { - # An array of attachment objects. Note that photo thumbnails do not have thumbnails - AttachmentBaseObject[]? thumbnails?; + MacroObject macro?; }; public type TicketSkipsResponse record { - TicketSkipObject[]? skips?; -}; - -public type SuspendedTicketsExportResponse_export record { - string? status?; - string? view_id?; -}; - -public type ResourceCollectionsResponse record { - int? count?; - string? next_page?; - string? previous_page?; - ResourceCollectionObject[]? resource_collections?; -}; - -public type CustomObjectRecordsResponse_links record { - string? next; - string? prev; + TicketSkipObject[] skips?; }; -public type JobStatusResponse record { - JobStatusObject? job_status?; +# Represents the Headers record for the operation: ListTicketEmailCCs +public type ListTicketEmailCCsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ViewsResponse record { - int? count?; - string? next_page?; - string? previous_page?; - ViewObject[]? views?; -}; +# Provides a set of configurations for controlling the behaviours when communicating with a remote HTTP endpoint. +@display {label: "Connection Config"} +public type ConnectionConfig record {| + # Configurations related to client authentication + http:CredentialsConfig auth; + # The HTTP version understood by the client + http:HttpVersion httpVersion = http:HTTP_2_0; + # Configurations related to HTTP/1.x protocol + http:ClientHttp1Settings http1Settings = {}; + # Configurations related to HTTP/2 protocol + http:ClientHttp2Settings http2Settings = {}; + # The maximum time to wait (in seconds) for a response before closing the connection + decimal timeout = 30; + # The choice of setting `forwarded`/`x-forwarded` header + string forwarded = "disable"; + # Configurations associated with Redirection + http:FollowRedirects followRedirects?; + # Configurations associated with request pooling + http:PoolConfiguration poolConfig?; + # HTTP caching related configurations + http:CacheConfig cache = {}; + # Specifies the way of handling compression (`accept-encoding`) header + http:Compression compression = http:COMPRESSION_AUTO; + # Configurations associated with the behaviour of the Circuit Breaker + http:CircuitBreakerConfig circuitBreaker?; + # Configurations associated with retrying + http:RetryConfig retryConfig?; + # Configurations associated with cookies + http:CookieConfig cookieConfig?; + # Configurations associated with inbound response size limits + http:ResponseLimitConfigs responseLimits = {}; + # SSL/TLS-related options + http:ClientSecureSocket secureSocket?; + # Proxy server related options + http:ProxyConfig proxy?; + # Provides settings related to client socket configuration + http:ClientSocketConfig socketConfig = {}; + # Enables the inbound payload validation functionality which provided by the constraint package. Enabled by default + boolean validation = true; + # Enables relaxed data binding on the client side. When enabled, `nil` values are treated as optional, + # and absent fields are handled as `nilable` types. Enabled by default. + boolean laxDataBinding = true; +|}; -# Primary group ids linked to the queue -public type QueueObject_primary_groups record { - int? count?; - ListDeletedTicketsResponse_actor[]? groups?; +# Represents the Queries record for the operation: ListActiveTriggers +public type ListActiveTriggersQueries record { + # Filter triggers by category ID + @http:Query {name: "category_id"} + string categoryId?; + # Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position" + string sort?; + # Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; }; -public type SessionsResponse record { - SessionObject[]? sessions?; +# Represents the Headers record for the operation: ListCustomStatuses +public type ListCustomStatusesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SkillBasedRoutingAttributeDefinitions_definitions record { - SkillBasedRoutingAttributeDefinitions_definitions_conditions_all[]? conditions_all?; - SkillBasedRoutingAttributeDefinitions_definitions_conditions_all[]? conditions_any?; +# Represents the Headers record for the operation: ListActiveTriggers +public type ListActiveTriggersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type DynamicContentVariantResponse record { - DynamicContentVariantObject? variant?; +public type SatisfactionReasonsResponse record { + SatisfactionReasonObject[] reasons?; }; -public type AuditObject_events record { - string? body?; - string? field_name?; - int? id?; - string? 'type?; - string|int? value?; +# Zendesk Chat settings. See [Chat](#chat) +public type AccountSettingsChatObject record { + boolean available?; + @jsondata:Name {value: "welcome_message"} + string welcomeMessage?; + boolean enabled?; + @jsondata:Name {value: "maximum_request_count"} + int maximumRequestCount?; + boolean integrated?; }; -public type SatisfactionReasonsResponse record { - SatisfactionReasonObject[]? reasons?; +# Represents the Headers record for the operation: GetSourcesByTarget +public type GetSourcesByTargetHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# Zendesk Chat settings. See [Chat](#chat) -public type AccountSettingsChatObject record { - boolean? available?; - boolean? enabled?; - boolean? integrated?; - int? maximum_request_count?; - string? welcome_message?; +# Represents the Headers record for the operation: TicketImport +public type TicketImportHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type OrganizationSubscriptionsResponse record { *OffsetPaginationObject; - # An array of organization subscriptions - OrganizationSubscriptionObject[]? organization_subscriptions?; + *OrganizationSubscriptionsResponseAllOf2; }; -public type LocaleObject record { - # The ISO 8601 formatted date-time the locale was created - string? created_at?; - # The unique ID of the locale - int? id?; - # The name of the locale - string? locale?; - # The name of the language - string? name?; - # The ISO 8601 formatted date-time when the locale was last updated - string? updated_at?; - # The URL of the locale record - string? url?; +public type DefinitionsResponseDefinitionsOperators record { + boolean terminal?; + string title?; + string value?; }; -public type AttachmentUploadResponse record { - AttachmentUploadResponse_upload? upload?; +# Represents the Headers record for the operation: ShowDerivedMacro +public type ShowDerivedMacroHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CreateResourceResult record { - # the id of the new resource - int? id; - # the index number of the resul - int? index; +public type SatisfactionRatingResponse record { + @jsondata:Name {value: "satisfaction_rating"} + SatisfactionRatingObject[] satisfactionRating?; }; -public type SatisfactionRatingResponse record { - SatisfactionRatingObject[]? satisfaction_rating?; +# Represents the Queries record for the operation: IncrementalTicketEvents +public type IncrementalTicketEventsQueries record { + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; }; -public type TagUrlObject record { - # The url associated to the api request - string? url?; +# Represents the Headers record for the operation: UpdateAttributeValue +public type UpdateAttributeValueHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomStatusUpdateInput record { + # The dynamic content placeholder, if present, or the "end_user_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "end_user_label"} + string endUserLabel?; + # The dynamic content placeholder, if present, or the "end_user_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "end_user_description"} + string endUserDescription?; # True if the custom status is set as active; inactive if false - boolean? active?; - # The dynamic content placeholder, if present, or the "agent_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? agent_label?; + boolean active?; # The dynamic content placeholder, if present, or the "description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? description?; - # The dynamic content placeholder, if present, or the "end_user_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? end_user_description?; - # The dynamic content placeholder, if present, or the "end_user_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? end_user_label?; + string description?; + # The dynamic content placeholder, if present, or the "agent_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "agent_label"} + string agentLabel?; }; public type SessionResponse record { - SessionObject[]? session?; + SessionObject[] session?; }; -public type ActivityObject record { - # The full user record of the user responsible for the ticket activity. See [Users](/api-reference/ticketing/users/users/) - UserObject?? actor?; - # The id of the user responsible for the ticket activity. An `actor_id` of "-1" is a Zendesk system user, such as an automations action. - int? actor_id?; - # When the record was created - string? created_at?; - # Automatically assigned on creation - int? id?; - # The content of the activity. Can be a ticket, comment, or change. - record {}? 'object?; - # The target of the activity, a ticket. - record {}? target?; - # Description of the activity - string? title?; - # When the record was last updated - string? updated_at?; - # The API url of the activity - string? url?; - # The full user record of the agent making the request. See [Users](/api-reference/ticketing/users/users/) - UserObject?? user?; - # The id of the agent making the request - int? user_id?; - # The type of activity. Can be "tickets.assignment", "tickets.comment", or "tickets.priority_increase" - string? verb?; +# Represents the Headers record for the operation: SearchCustomObjectRecords +public type SearchCustomObjectRecordsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyFilterDefinitionResponse_definitions_values_list record { - string? title?; - int? value?; +# Represents the Queries record for the operation: AutocompleteProblems +public type AutocompleteProblemsQueries record { + # The text to search for + string text?; }; -public type TwitterChannelResponse record { - TwitterChannelObject? monitored_twitter_handle?; +# Represents the Headers record for the operation: ListTicketMetricEvents +public type ListTicketMetricEventsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type BatchJobRequestJobItems record { + @jsondata:Name {value: "trigger_categories"} + TriggerCategoryBatchRequest[] triggerCategories?; + TriggerBatchRequest[] triggers?; }; -public type UserCreateInput_organization record { - string? name; +# Represents the Headers record for the operation: DeleteWorkspace +public type DeleteWorkspaceHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type DynamicContentVariantObject record { - # If the variant is active and useable - boolean? active?; - # The content of the variant - string? content; - # When the variant was created - string? created_at?; - # If the variant is the default for the item it belongs to - boolean? default?; - # Automatically assigned when the variant is created - int? id?; # An active locale - int? locale_id; + @jsondata:Name {value: "locale_id"} + int localeId; + # If the variant is the default for the item it belongs to + boolean default?; # If the variant is outdated - boolean? outdated?; + boolean outdated?; # When the variant was last updated - string? updated_at?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # If the variant is active and useable + boolean active?; + # When the variant was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned when the variant is created + int id?; + # The content of the variant + string content; # The API url of the variant - string? url?; + string url?; }; -public type IncrementalSkillBasedRoutingAttribute record { - # Automatically assigned when an attribute is created - string? id?; - # The name of the attribute - string? name?; - # The time the attribute was created, updated, or deleted - string? time?; - # One of "create", "update", or "delete" - string? 'type?; +# Represents the Headers record for the operation: MergeTicketsIntoTargetTicket +public type MergeTicketsIntoTargetTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type SLAPolicyFilterDefinitionResponse record { - SLAPolicyFilterDefinitionResponse_definitions? definitions?; + SLAPolicyFilterDefinitionResponseDefinitions definitions?; }; -public type ViewCountObject record { - # Only active views if true, inactive views if false, all views if null. - boolean? active?; - # false if the cached data is stale and the system is still loading and caching new data - boolean? fresh?; - # A pretty-printed text approximation of the view count - string? pretty?; - # The API url of the count - string? url?; - # The cached number of tickets in the view. Can also be null if the system is loading and caching new data. Not to be confused with 0 tickets - int? value?; - # The id of the view - int? view_id?; +public type QueueResponse record { + QueueObject queue?; }; -public type QueueResponse record { - QueueObject? queue?; +public type TicketMetricsResponse record { + @jsondata:Name {value: "ticket_metrics"} + TicketMetricObject[] ticketMetrics?; }; public type FollowerObject record { + @jsondata:Name {value: "user_email"} + string userEmail?; + @jsondata:Name {value: "user_id"} + string userId?; "put"|"delete" action?; - string? user_email?; - string? user_id?; }; -public type TicketMetricsResponse record { - TicketMetricObject[]? ticket_metrics?; +# Represents the Queries record for the operation: ListActivities +public type ListActivitiesQueries record { + # A UTC time in ISO 8601 format to return ticket activities since said date + string since?; }; -public type LocaleResponse record { - LocaleObject? locale?; +# Represents the Headers record for the operation: ListCustomObjectRecords +public type ListCustomObjectRecordsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type OrganizationObject record { - # The time the organization was created - string? created_at?; - # Any details obout the organization, such as the address - string? details?; - # An array of domain names associated with this organization - string[]? domain_names?; - # A unique external id to associate organizations to an external record. The id is case-insensitive. For example, "company1" and "Company1" are considered the same - string? external_id?; - # New tickets from users in this organization are automatically put in this group - int? group_id?; - # Automatically assigned when the organization is created - int? id?; - # A unique name for the organization - string? name?; - # Any notes you have about the organization - string? notes?; - # Custom fields for this organization. See [Custom organization fields](/api-reference/ticketing/organizations/organizations/#custom-organization-fields) - record {}? organization_fields?; - # End users in this organization are able to comment on each other's tickets - boolean? shared_comments?; - # End users in this organization are able to see each other's tickets - boolean? shared_tickets?; - # The tags of the organization - string[]? tags?; - # The time of the last update of the organization - string? updated_at?; - # The API url of this organization - string? url?; +# Represents the Headers record for the operation: ListTicketCollaborators +public type ListTicketCollaboratorsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ActivitiesCountResponse_count record { - string? refreshed_at?; - int? value?; +# Represents the Headers record for the operation: ShowQueueById +public type ShowQueueByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyFilterDefinitionResponse_definitions_values record { - GroupSLAPolicyFilterDefinitionResponse_definitions_values_list[]? list?; - string? 'type?; +# Represents the Headers record for the operation: ShowUserField +public type ShowUserFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CollaboratorObject record { - string? email?; - string? name?; + string name?; + string email?; }; -public type SupportAddressResponse record { - SupportAddressObject? recipient_address?; +# Represents the Headers record for the operation: TicketBulkImport +public type TicketBulkImportHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; # Ticket form settings. See [Ticket Form](#ticket-form) public type AccountSettingsTicketFormObject record { - string? raw_ticket_forms_instructions?; - string? ticket_forms_instructions?; -}; - -public type SatisfactionRatingObject record { - # The id of agent assigned to at the time of rating - int? assignee_id; - # The comment received with this rating, if available - string? comment?; - # The time the satisfaction rating got created - string? created_at?; - # The id of group assigned to at the time of rating - int? group_id; - # Automatically assigned upon creation - int? id?; - # The reason for a bad rating given by the requester in a follow-up question. Satisfaction reasons must be [enabled](https://support.zendesk.com/hc/en-us/articles/223152967) - string? reason?; - # The default reasons the user can select from a list menu for giving a negative rating. See [Reason codes](/api-reference/ticketing/ticket-management/satisfaction_reasons/#reason-codes) in the Satisfaction Reasons API. Can only be set on ratings with a `score` of "bad". Responses don't include this property - int? reason_code?; - # id for the reason the user gave a negative rating. Can only be set on ratings with a `score` of "bad". To get a descriptive value for the id, use the [Show Reason for Satisfaction Rating](/api-reference/ticketing/ticket-management/satisfaction_reasons/#show-reason-for-satisfaction-rating) endpoint - int? reason_id?; - # The id of ticket requester submitting the rating - int? requester_id; - # The rating "offered", "unoffered", "good" or "bad" - string? score; - # The id of ticket being rated - int? ticket_id; - # The time the satisfaction rating got updated - string? updated_at?; - # The API url of this rating - string? url?; + @jsondata:Name {value: "ticket_forms_instructions"} + string ticketFormsInstructions?; + @jsondata:Name {value: "raw_ticket_forms_instructions"} + string rawTicketFormsInstructions?; }; -public type GroupSLAPolicyFilterDefinitionResponse_definitions_all record { - string? group?; - GroupSLAPolicyFilterDefinitionResponse_definitions_operators[]? operators?; - string? title?; - string? value?; - GroupSLAPolicyFilterDefinitionResponse_definitions_values? values?; +public type TicketCreateInputAllOf2 record { + # The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_subject"} + string rawSubject?; + # Enterprise only. The id of the ticket form to render for the ticket + @jsondata:Name {value: "ticket_form_id"} + int ticketFormId?; + # The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center + @jsondata:Name {value: "email_cc_ids"} + int[] emailCcIds?; + # The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) + @jsondata:Name {value: "follower_ids"} + int[] followerIds?; + # The original recipient e-mail address of the ticket + string recipient?; + # POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) + @jsondata:Name {value: "via_followup_source_id"} + int viaFollowupSourceId?; + # POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) + CollaboratorObject[] collaborators?; + # The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket + @jsondata:Name {value: "submitter_id"} + int submitterId?; + # POST requests only. List of macro IDs to be recorded in the ticket audit + @jsondata:Name {value: "macro_ids"} + int[] macroIds?; + # Enterprise only. The id of the brand this ticket is associated with + @jsondata:Name {value: "brand_id"} + int brandId?; + ViaObject via?; }; -public type ListDeletedTicketsResponse_actor record { - int? id?; - string? name?; +public type TwitterChannelTwicketStatusResponseStatuses record { + @jsondata:Name {value: "user_followed"} + boolean userFollowed?; + int id?; + boolean favorited?; + boolean retweeted?; }; public type SkillBasedRoutingAttributeObject record { + # When this record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # The name of the attribute + string name; # When this record was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # Automatically assigned when an attribute is created - string? id?; - # The name of the attribute - string? name; - # When this record was last updated - string? updated_at?; + string id?; # URL of the attribute - string? url?; + string url?; }; -public type UserMergePropertiesInput record { - string? email?; - string? name?; - int? organization_id?; - string? password?; -}; - -# Branding settings. See [Branding](#branding) -public type AccountSettingsBrandingObject record { - string? favicon_url?; - string? header_color?; - string? header_logo_url?; - string? page_background_color?; - string? tab_background_color?; - string? text_color?; +# Represents the Headers record for the operation: DeleteTicketFieldOption +public type DeleteTicketFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AttachmentUpdateInput record { - # If true, allows access to attachments with detected malware. - boolean? malware_access_override?; +# Represents the Headers record for the operation: DeleteManyMacros +public type DeleteManyMacrosHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type MacroCategoriesResponse record { - string[]? categories?; +# Represents the Headers record for the operation: ExportAuditLogs +public type ExportAuditLogsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BatchJobRequest_job record { - "patch" action?; - BatchJobRequest_job_items? items?; +public type AttachmentUpdateInput record { + # If true, allows access to attachments with detected malware + @jsondata:Name {value: "malware_access_override"} + boolean malwareAccessOverride?; }; public type TicketCreateRequest record { - TicketCreateInput? ticket?; -}; - -public type GroupResponse record { - GroupObject? group?; -}; - -public type SkillBasedRoutingAttributeValueObject record { - # Id of the associated attribute - string? attribute_id?; - # When this record was created - string? created_at?; - # Automatically assigned when an attribute value is created - string? id?; - # The name of the attribute value - string? name?; - # When this record was last updated - string? updated_at?; - # URL of the attribute value - string? url?; -}; - -public type CustomObjectsCreateRequest record { - CustomObjectCreateInput? custom_object?; + TicketCreateInput ticket?; }; -public type SuspendedTicketObject record { - # The attachments, if any associated to this suspended ticket. See [Attachments](/api-reference/ticketing/tickets/ticket-attachments/) - AttachmentObject[]? attachments?; - # The author id (if available), name and email - AuthorObject?? author?; - # The id of the brand this ticket is associated with. Only applicable for Enterprise accounts - int? brand_id?; - # Why the ticket was suspended - string? cause?; - # The ID of the cause - int? cause_id?; - # The content that was flagged - string? content?; - # The ticket ID this suspended email is associated with, if available - string? created_at?; - # The error messages if any associated to this suspended ticket - record {}[]? error_messages?; - # Automatically assigned - int? id?; - # The ID of the email, if available - string? message_id?; - # The original recipient e-mail address of the ticket - string? recipient?; - # The value of the subject field for this ticket - string? subject?; - # The ticket ID this suspended email is associated with, if available - int? ticket_id?; - # When the ticket was assigned - string? updated_at?; - # The API url of this ticket - string? url?; - # An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - ViaObject? via?; +# Represents the Headers record for the operation: CreateTicketSatisfactionRating +public type CreateTicketSatisfactionRatingHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type OrganizationSubscriptionResponse record { - OrganizationSubscriptionObject? organization_subscription?; + @jsondata:Name {value: "organization_subscription"} + OrganizationSubscriptionObject organizationSubscription?; }; -public type ResourceCollectionObject record { - # When the resource collection was created - string? created_at?; - # id for the resource collection. Automatically assigned upon creation - int? id?; - # Array of resource metadata objects. See [Resource objects](#resource-objects) - ResourceCollectionObject_resources[]? resources?; - # Last time the resource collection was updated - string? updated_at?; +# Represents the Headers record for the operation: ShowTarget +public type ShowTargetHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TargetHTTP record { - # "application/json", "application/xml", or "application/x-www-form-urlencoded" - string? content_type; - # "get", "patch", "put", "post", or "delete" - string? method; - # only writable - string? password?; - string? target_url; - string? username?; +public type TriggerRevisionsResponseDiff record { + # An array of [change](#change) objects + TriggerChangeObject[] active?; + # An array of [change](#change) objects + TriggerChangeObject[] description?; + # ID of the target revision + @jsondata:Name {value: "target_id"} + int targetId?; + # ID of the source revision + @jsondata:Name {value: "source_id"} + int sourceId?; + TriggerConditionDiffObject conditions?; + # An array of [change](#change) objects + TriggerChangeObject[] title?; + # An array that contain [action diff objects](#Action Diffs) + TriggerActionDiffObject[] actions?; }; public type TicketCreateInput record { *TicketUpdateInput; - # Enterprise only. The id of the brand this ticket is associated with - int? brand_id?; - # POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) - CollaboratorObject[]? collaborators?; - # The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center - int[]? email_cc_ids?; - # The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) - int[]? follower_ids?; - # POST requests only. List of macro IDs to be recorded in the ticket audit - int[]? macro_ids?; - # The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_subject?; - # The original recipient e-mail address of the ticket - string? recipient?; - # The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket - int? submitter_id?; - # Enterprise only. The id of the ticket form to render for the ticket - int? ticket_form_id?; - # An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - ViaObject? via?; - # POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) - int? via_followup_source_id?; + *TicketCreateInputAllOf2; +}; + +# Represents the Headers record for the operation: SearchViews +public type SearchViewsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TrialAccountObject record { # The name of the account - string? name?; + string name?; # The subdomain of the account - string? subdomain?; + string subdomain?; # The URL of the account - string? url?; + string url?; }; -public type SLAPolicyFilterDefinitionResponse_definitions_all record { - string? group?; - GroupSLAPolicyFilterDefinitionResponse_definitions_operators[]? operators?; - string? target?; - string? title?; - string? value?; - SLAPolicyFilterDefinitionResponse_definitions_values? values?; +# Represents the Queries record for the operation: IncrementalTicketExportTime +public type IncrementalTicketExportTimeQueries record { + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; +}; + +# Represents the Headers record for the operation: ListSearchResults +public type ListSearchResultsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type WorkspaceObject record { - # If true, this workspace is available for use - boolean? activated?; - # The apps associated to this workspace - record {}[]? apps?; - # An object that describes the conditions under which the automation will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - ConditionsObject? conditions?; + # The ids of the macros associated to this workspace + int[] macros?; # The time the workspace was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # User-defined description of this workspace's purpose - string? description?; - # Automatically assigned upon creation - int? id?; + string description?; # The ids of the macros associated to this workspace - int[]? macro_ids?; - # The ids of the macros associated to this workspace - int[]? macros?; - # Ordering of the workspace relative to other workspaces - int? position?; + @jsondata:Name {value: "macro_ids"} + int[] macroIds?; # If true, the order of apps within the workspace will be preserved - boolean? prefer_workspace_app_order?; - # An array of the macro objects that will be used in this workspace. See [Macros](/api-reference/ticketing/business-rules/macros/) - MacroObject[]? selected_macros?; - # The id of the ticket web form associated to this workspace - int? ticket_form_id?; + @jsondata:Name {value: "prefer_workspace_app_order"} + boolean preferWorkspaceAppOrder?; # The title of the workspace - string? title?; - # The time of the last update of the workspace - string? updated_at?; + string title?; # The URL for this resource - string? url?; + string url?; + # The id of the ticket web form associated to this workspace + @jsondata:Name {value: "ticket_form_id"} + int ticketFormId?; + # The time of the last update of the workspace + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # An array of the macro objects that will be used in this workspace. See [Macros](/api-reference/ticketing/business-rules/macros/) + @jsondata:Name {value: "selected_macros"} + MacroObject[] selectedMacros?; + # Automatically assigned upon creation + int id?; + # Ordering of the workspace relative to other workspaces + int position?; + ConditionsObject conditions?; + # If true, this workspace is available for use + boolean activated?; + # The apps associated to this workspace + record {}[] apps?; }; -public type ConditionObject record { - # The name of a ticket field - string? 'field?; - # A comparison operator - string? operator?; - # The value of a ticket field - string? value?; +# Represents the Queries record for the operation: ListTicketsFromView +public type ListTicketsFromViewQueries record { + # Sort or group the tickets by a column in the [View columns](#view-columns) table. The `subject` and `submitter` columns are not supported + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; }; public type SLAPolicyObject record { + SLAPolicyFilterObject filter; + # The time of the last update of the SLA policy + @jsondata:Name {value: "updated_at"} + string updatedAt?; + # Array of [Policy Metric](#policy-metric) objects + @jsondata:Name {value: "policy_metrics"} + SLAPolicyMetricObject[] policyMetrics?; # The time the SLA policy was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # The description of the SLA policy - string? description?; - # An object that describes the conditions that a ticket must match in order for an SLA policy to be applied to that ticket. See [Filter](#filter). - SLAPolicyFilterObject? filter; + string description?; # Automatically assigned when created - int? id?; - # Array of [Policy Metric](#policy-metric) objects - SLAPolicyMetricObject[]? policy_metrics?; + int id?; # Position of the SLA policy that determines the order they will be matched. If not specified, the SLA policy is added as the last position - int? position?; + int position?; # The title of the SLA policy - string? title; - # The time of the last update of the SLA policy - string? updated_at?; + string title; # URL of the SLA Policy reacord - string? url?; -}; - -public type ListDeletedTicketsResponse_deleted_tickets record { - ListDeletedTicketsResponse_actor? actor?; - string? deleted_at?; - int? id?; - string? previous_state?; - string? subject?; -}; - -public type OrganizationMetadataObject record { - # The number of tickets for the organization - int? tickets_count?; - # The number of users for the organization - int? users_count?; + string url?; }; -public type PushNotificationDevicesInput string[]?; - -public type TargetGetSatisfaction record { - string? account_name; - string? email; - # only writable - string? password; - string? target_url?; +# Represents the Headers record for the operation: UpdateUserField +public type UpdateUserFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type MacroApplyTicketResponse_result record { - MacroApplyTicketResponse_result_ticket? ticket?; +# Represents the Queries record for the operation: SearchCustomObjectRecords +public type SearchCustomObjectRecordsQueries record { + # The query parameter is used to search text-based fields for records that match specific query terms. + # The query can be multiple words or numbers. Every record that matches the beginning of any word or number in the query string is returned.

+ # + # For example, you might want to search for records related to Tesla vehicles: `query=Tesla`. In this example the API would return every record for the given custom object where any of the text fields contain the word 'Tesla'.

+ # + # If needed, you could include multiple words or numbers in your search. For example: `query=Tesla Honda 2020`. This would be URL encoded as `query=Tesla%20Honda%202020`. In this example, the API would return every record for the custom object for which any of the text fields contained 'Tesla', 'Honda', or '2020' + string query?; + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[before]"} + string pageBefore?; + # One of `name`, `created_at`, `updated_at`, `-name`, `-created_at`, or `-updated_at`. The `-` denotes the sort will be descending. Defaults to sorting by relevance + string sort?; + # Specifies how many records should be returned in the response. You can specify up to 100 records per page + @http:Query {name: "page[size]"} + int pageSize?; + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[after]"} + string pageAfter?; +}; + +# Represents the Headers record for the operation: ShowAutomation +public type ShowAutomationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: IncrementalTicketExportCursor +public type IncrementalTicketExportCursorQueries record { + # The cursor pointer to work with for all subsequent exports after the initial request + string cursor?; + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; +}; + +public type PushNotificationDevicesInput string[]; + +# Represents the Queries record for the operation: SearchTriggers +public type SearchTriggersQueries record { + # Trigger attribute filters for the search. See [Filter](#filter) + filter filter?; + # A sideload to include in the response. See [Sideloads](#sideloads-2) + string include?; + # Query string used to find all triggers with matching title + string query; + # Filter by active triggers if true or inactive triggers if false + boolean active?; + # Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position" + string sort?; + # Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +public type ListDeletedTicketsResponseDeletedTickets record { + ListDeletedTicketsResponseActor actor?; + @jsondata:Name {value: "previous_state"} + string previousState?; + string subject?; + int id?; + @jsondata:Name {value: "deleted_at"} + string deletedAt?; }; public type BrandCreateRequest record { - BrandObject? brand?; + BrandObject brand?; }; public type Page record { - string? after?; - string? before?; - int? size?; -}; - -public type CustomObjectLimitsResponse record { - # The current numnber of the requested resource - int? count?; - # The maximum allowed number for the requested resource - int? 'limit?; + int size?; + string before?; + string after?; }; public type CustomRoleObject record { - # Configuration settings for the role. See [Configuration](#configuration) - CustomRoleConfigurationObject? configuration?; + # The number of team members assigned to this role + @jsondata:Name {value: "team_member_count"} + int teamMemberCount?; + # The user's role. 0 stands for a custom agent, 1 for a light agent, 2 for a chat agent, 3 for a contributor, 4 for an admin and 5 for a billing admin. See [Understanding standard agent roles in Zendesk Support](https://support.zendesk.com/hc/en-us/articles/4409155971354-Understanding-standard-agent-roles-in-Zendesk-Support) in Zendesk help + @jsondata:Name {value: "role_type"} + int roleType; + # The time the record was last updated + @jsondata:Name {value: "updated_at"} + string updatedAt?; + CustomRoleConfigurationObject configuration?; + # Name of the custom role + string name; # The time the record was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # A description of the role - string? description?; + string description?; # Automatically assigned on creation - int? id?; - # Name of the custom role - string? name; - # The user's role. 0 stands for a custom agent, 1 for a light agent, 2 for a chat agent, 3 for a contributor, 4 for an admin and 5 for a billing admin. See [Understanding standard agent roles in Zendesk Support](https://support.zendesk.com/hc/en-us/articles/4409155971354-Understanding-standard-agent-roles-in-Zendesk-Support) in Zendesk help - int? role_type; - # The number of team members assigned to this role - int? team_member_count?; - # The time the record was last updated - string? updated_at?; -}; - -public type EssentialsCardObject record { - # Date and time the essentials card were created - string? created_at?; - # If true, the system has used the first twenty fields for the custom object type as the essentials card. - boolean? default?; - # Fields that are displayed in the essentials card details. The order is defined by the order of the fields in the array - record {}[]? fields; - # id of the essentials card - string? id?; - # Object type. Example: `zen:user` refers to `User` type - string? 'key?; - # layout type - string? layout?; - # Maximum number of fields allowed in the essentials card - int? max_count?; - # Date and time the essentials card were last updated - string? updated_at?; + int id?; }; public type CustomObjectRecordsResponse record { + CustomObjectRecordsResponseMeta meta?; # The number of results returned for the current request - int? count?; - CustomObjectRecord[]? custom_object_records?; - CustomObjectRecordsResponse_links? links?; - CustomObjectRecordsResponse_meta? meta?; -}; - -public type Organization_field_id int|string; - -public type MacroUpdateManyInput_macros record { - # The active status of the macro (true or false) - boolean? active?; - # The ID of the macro to update - int? id; - # The new position of the macro - int? position?; -}; - -public type ListTicketCollaboratorsResponse record { + int count?; + CustomObjectRecordsResponseLinks links?; + @jsondata:Name {value: "custom_object_records"} + CustomObjectRecord[] customObjectRecords?; }; -public type TriggerRevisionResponse_trigger_revision_snapshot record { - TriggerActionObject[]? actions?; - boolean? active?; - # An object that describes the conditions under which the trigger will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - TriggerConditionsObject? conditions?; - string? description?; - string? title?; +# Represents the Headers record for the operation: ReorderSLAPolicies +public type ReorderSLAPoliciesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) -public type TicketAuditViaObject record { - # This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" - string? channel?; - # For some channels a source object gives more information about how or why the ticket or event was created - record {}? 'source?; +public type UserRequest record { + UserInput user; }; -public type UserRequest record { - UserInput? user; +# Represents the Headers record for the operation: ShowSupportAddress +public type ShowSupportAddressHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type OrganizationSubscriptionObject record { + # The ID of the user + @jsondata:Name {value: "user_id"} + int userId?; + # The ID of the organization + @jsondata:Name {value: "organization_id"} + int organizationId?; # The date the organization subscription was created - string? created_at?; + @jsondata:Name {value: "created_at"} + string createdAt?; # The ID of the organization subscription - int? id?; - # The ID of the organization - int? organization_id?; - # The ID of the user - int? user_id?; + int id?; }; # Account metrics settings. See [Metrics](#metrics) public type AccountSettingsMetricsObject record { - string? account_size?; + @jsondata:Name {value: "account_size"} + string accountSize?; }; public type MacrosResponse record { - MacroObject[]? macros?; + *MacrosResponseAllOf1; *OffsetPaginationObject; }; -public type TicketMetricEventSLAObject record { - *TicketMetricEventBaseObject; - # Available if `type` is `apply_sla`. The SLA policy and target being enforced on the ticket and metric in question, if any. See [sla](#sla) - record {}? sla?; -}; - -public type SkillBasedRoutingAttributeValueResponse record { - SkillBasedRoutingAttributeValueObject? attribute_value?; -}; - -public type SLAPoliciesResponse record { - int? count?; - string? next_page?; - string? previous_page?; - SLAPolicyObject[]? sla_policies?; +# Represents the Headers record for the operation: ListTriggers +public type ListTriggersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CountResponse record { - CountResponse_count? count?; + CountResponseCount count?; }; -public type GroupObject record { - # The time the group was created - string? created_at?; - # If the group is the default one for the account - boolean? default?; - # Deleted groups get marked as such - boolean? deleted?; - # The description of the group - string? description?; - # Automatically assigned when creating groups - int? id?; - # If true, the group is public. - # If false, the group is private. - # You can't change a private group to a public group - boolean? is_public?; - # The name of the group - string? name; - # The time of the last update of the group - string? updated_at?; - # The API url of the group - string? url?; +# Represents the Queries record for the operation: ExportSearchResults +public type ExportSearchResultsQueries record { + # The object type returned by the export query. Can be `ticket`, `organization`, `user`, or `group` + @http:Query {name: "filter[type]"} + string filterType?; + # The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) + string query; + # The number of results shown in a page + @http:Query {name: "page[size]"} + int pageSize?; }; # Onboarding settings public type AccountSettingsOnboardingObject record { - int? checklist_onboarding_version?; - string? onboarding_segments?; - string? product_sign_up?; + @jsondata:Name {value: "product_sign_up"} + string? productSignUp?; + @jsondata:Name {value: "checklist_onboarding_version"} + int checklistOnboardingVersion?; + @jsondata:Name {value: "onboarding_segments"} + string? onboardingSegments?; }; -public type SearchResponse record { - # The number of resources returned by the query corresponding to this page of results in the paginated response - int? count?; - # The facets corresponding to the search query - string? facets?; - # URL to the next page of results - string? next_page?; - # URL to the previous page of results - string? previous_page?; - # May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object - SearchResultObject[]? results?; +# Represents the Headers record for the operation: ShowUser +public type ShowUserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type ViewExportResponse record { - ViewExportResponse_export? export?; +# Represents the Headers record for the operation: IncrementalTicketEvents +public type IncrementalTicketEventsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type UserCreateInput_identities record { - string? 'type; - string? value; +# Represents the Headers record for the operation: ListAssigneeFieldAssignableGroupAgents +public type ListAssigneeFieldAssignableGroupAgentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type AttachmentBaseObject record { - # The content type of the image. Example value: "image/png" - string? content_type?; - # A full URL where the attachment image file can be downloaded. The file may be hosted externally so take care not to inadvertently send Zendesk authentication credentials. See [Working with url properties](/documentation/ticketing/managing-tickets/working-with-url-properties) - string? content_url?; - # If true, the attachment has been deleted - boolean? deleted?; + # If true, you can download an attachment flagged as malware. If false, you can't download such an attachment + @jsondata:Name {value: "malware_access_override"} + boolean malwareAccessOverride?; + # The URL the attachment image file has been mapped to + @jsondata:Name {value: "mapped_content_url"} + string mappedContentUrl?; # The name of the image file - string? file_name?; - # The height of the image file in pixels. If height is unknown, returns null - string? height?; - # Automatically assigned when created - int? id?; + @jsondata:Name {value: "file_name"} + string fileName?; + # The result of the malware scan. There is a delay between the time the attachment is uploaded and when the malware scan is completed. Usually the scan is done within a few seconds, but high load conditions can delay the scan results. Possible values: "malware_found", "malware_not_found", "failed_to_scan", "not_scanned" + @jsondata:Name {value: "malware_scan_result"} + string malwareScanResult?; + # A URL to access the attachment details + string url?; + # If true, the attachment has been deleted + boolean deleted?; + # The content type of the image. Example value: "image/png" + @jsondata:Name {value: "content_type"} + string contentType?; # If true, the attachment is excluded from the attachment list and the attachment's URL # can be referenced within the comment of a ticket. Default is false - boolean? inline?; - # If true, you can download an attachment flagged as malware. If false, you can't download such an attachment. - boolean? malware_access_override?; - # The result of the malware scan. There is a delay between the time the attachment is uploaded and when the malware scan is completed. Usually the scan is done within a few seconds, but high load conditions can delay the scan results. Possible values: "malware_found", "malware_not_found", "failed_to_scan", "not_scanned" - string? malware_scan_result?; - # The URL the attachment image file has been mapped to - string? mapped_content_url?; + boolean inline?; # The size of the image file in bytes - int? size?; - # A URL to access the attachment details - string? url?; + int size?; # The width of the image file in pixels. If width is unknown, returns null - string? width?; + string width?; + # A full URL where the attachment image file can be downloaded. The file may be hosted externally so take care not to inadvertently send Zendesk authentication credentials. See [Working with url properties](/documentation/ticketing/managing-tickets/working-with-url-properties) + @jsondata:Name {value: "content_url"} + string contentUrl?; + # Automatically assigned when created + int id?; + # The height of the image file in pixels. If height is unknown, returns null + string height?; }; public type UpdateResourceResult record { + # whether the action was successful or not (`"success": true`) + boolean success; # the action the job attempted (`"action": "update"`) - string? action; + string action; # the id of the resource the job attempted to update - int? id; + int id; # the status (`"status": "Updated"`) - string? status; - # whether the action was successful or not (`"success": true`) - boolean? success; + string status; }; -public type QueueObject_definition_all record { - string? 'field?; - string? operator?; - string? value?; +# Represents the Headers record for the operation: CountSearchResults +public type CountSearchResultsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type UserPasswordRequirementsResponse record { - string[]? requirements?; -}; - -public type TicketCommentsCountResponse record { - ActivitiesCountResponse_count? count?; + string[] requirements?; }; -public type SuspendedTicketsAttachmentsResponse_upload record { - AttachmentObject[]? attachments?; - # Token for subsequent request - string? token?; +# Represents the Headers record for the operation: ListGroups +public type ListGroupsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SatisfactionRatingsResponse record { - SatisfactionRatingObject[]? satisfaction_ratings?; +# Represents the Headers record for the operation: DestroyManyUsers +public type DestroyManyUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketCreateVoicemailTicketVoiceCommentInput record { - # The agent who answered the call - int? answered_by_id?; - # Duration in seconds of the call - int? call_duration?; - # Incoming phone number - string? 'from?; - # Location of the caller (optional) - string? location?; - # Incoming phone number - string? recording_url?; - # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp of the call starting time - string? started_at?; - # Dialed phone number - string? to?; - # Transcription of the call (optional) - string? transcription_text?; +public type DefinitionsResponseDefinitions record { + @jsondata:Name {value: "conditions_any"} + DefinitionsResponseDefinitionsConditionsAll[] conditionsAny?; + @jsondata:Name {value: "conditions_all"} + DefinitionsResponseDefinitionsConditionsAll[] conditionsAll?; }; -public type SearchResultObject record { - # When the resource was created - string? created_at?; - # Flag to indicate whether this is the default resource - boolean? default?; - # Flag to indicate whether or not resource has been deleted - boolean? deleted?; - # The description of the resource - string? description?; - # The ID of the resource - int? id?; - # The name of the resource - string? name?; - # The type of the resource - string? result_type?; - # When the resource was last updated - string? updated_at?; - # The url of the resource - string? url?; +# Represents the Headers record for the operation: IncrementalTicketExportCursor +public type IncrementalTicketExportCursorHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SupportAddressesResponse record { - SupportAddressObject[]? recipient_addresses?; +public type MacroApplyTicketResponseResultTicketFields record { + int id?; + string value?; +}; + +# Represents the Queries record for the operation: ShowManyUsers +public type ShowManyUsersQueries record { + # Accepts a comma-separated list of up to 100 user ids + string ids?; + # Accepts a comma-separated list of up to 100 external ids + @http:Query {name: "external_ids"} + string externalIds?; +}; + +# Represents the Queries record for the operation: SearchUsers +public type SearchUsersQueries record { + # The `query` parameter supports the Zendesk search syntax for more advanced + # user searches. It can specify a partial or full value of any + # user property, including name, email address, notes, or phone. Example: + # `query="jdoe"`. + # See the [Search API](/api-reference/ticketing/ticket-management/search/) + string query?; + # The `external_id` parameter does not support the search syntax. It only accepts ids + @http:Query {name: "external_id"} + string externalId?; +}; + +# Represents the Headers record for the operation: IncrementalUserExportCursor +public type IncrementalUserExportCursorHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TriggerConditionDefinitionObjectAll record { - string? group?; - boolean? nullable?; - DefinitionsResponse_definitions_operators[]? operators?; - boolean? repeatable?; - string? subject?; - string? title?; - string? 'type?; - DefinitionsResponse_definitions_values[]? values?; + boolean nullable?; + DefinitionsResponseDefinitionsOperators[] operators?; + boolean repeatable?; + string subject?; + DefinitionsResponseDefinitionsValues[] values?; + string title?; + string 'type?; + string group?; }; -# Ticket settings. See [Tickets](#tickets) -public type AccountSettingsTicketObject record { - boolean? accepted_new_collaboration_tos?; - boolean? agent_collision?; - boolean? agent_invitation_enabled?; - boolean? agent_ticket_deletion?; - boolean? allow_group_reset?; - boolean? assign_default_organization?; - boolean? assign_tickets_upon_solve?; - boolean? auto_translation_enabled?; - boolean? auto_updated_ccs_followers_rules?; - boolean? chat_sla_enablement?; - boolean? collaboration?; - boolean? comments_public_by_default?; - boolean? email_attachments?; - boolean? emoji_autocompletion?; - boolean? follower_and_email_cc_collaborations?; - boolean? has_color_text?; - boolean? is_first_comment_private_enabled?; - boolean? light_agent_email_ccs_allowed?; - boolean? list_empty_views?; - boolean? list_newest_comments_first?; - boolean? markdown_ticket_comments?; - int? maximum_personal_views_to_list?; - boolean? private_attachments?; - boolean? rich_text_comments?; - boolean? status_hold?; - boolean? tagging?; - boolean? using_skill_based_routing?; +# Represents the Headers record for the operation: ShowComment +public type ShowCommentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TagsByObjectIdResponse record { - # An array of strings - string[]? tags; +# Represents the Headers record for the operation: RedactCommentAttachment +public type RedactCommentAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketResponse record { - TicketObject? ticket?; + TicketObject ticket?; }; # An object that describes the conditions under which the trigger will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) @@ -3151,1296 +6699,1199 @@ public type TriggerConditionsObject record { TriggerConditionObject[]? 'any?; }; -# Secondary group ids linked to the queue -public type QueueObject_secondary_groups record { - int? count?; - ListDeletedTicketsResponse_actor[]? groups?; -}; - -# Configuration for the agent workspace. See [Agents](#agents) -public type AccountSettingsAgentObject record { - boolean? agent_home?; - boolean? agent_workspace?; - boolean? aw_self_serve_migration_enabled?; - boolean? focus_mode?; - boolean? idle_timeout_enabled?; - boolean? unified_agent_statuses?; -}; - public type TicketMetricsByTicketMetricIdResponse record { - TicketMetricObject[]? ticket_metric?; + @jsondata:Name {value: "ticket_metric"} + TicketMetricObject[] ticketMetric?; }; public type TicketFormObject record { + # The dynamic content placeholder, if present, or the "name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_name"} + string rawName?; + # Is the form available for use in all brands on this account + @jsondata:Name {value: "in_all_brands"} + boolean inAllBrands?; + # ids of all ticket fields which are in this ticket form. The products use the order of the ids to show the field values in the tickets + @jsondata:Name {value: "ticket_field_ids"} + int[] ticketFieldIds?; # If the form is set as active - boolean? active?; + boolean active?; # Array of condition sets for agent workspaces - record {}[]? agent_conditions?; + @jsondata:Name {value: "agent_conditions"} + record {}[] agentConditions?; # The time the ticket form was created - string? created_at?; - # Is the form the default form for this account - boolean? default?; + @jsondata:Name {value: "created_at"} + string createdAt?; + # The dynamic content placeholder, if present, or the "display_name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_display_name"} + string rawDisplayName?; # The name of the form that is displayed to an end user - string? display_name?; + @jsondata:Name {value: "display_name"} + string displayName?; + # URL of the ticket form + string url?; + # Is the form the default form for this account + boolean default?; # Array of condition sets for end user products - record {}[]? end_user_conditions?; + @jsondata:Name {value: "end_user_conditions"} + record {}[] endUserConditions?; + # The time of the last update of the ticket form + @jsondata:Name {value: "updated_at"} + string updatedAt?; # Is the form visible to the end user - boolean? end_user_visible?; - # Automatically assigned when creating ticket form - int? id?; - # Is the form available for use in all brands on this account - boolean? in_all_brands?; + @jsondata:Name {value: "end_user_visible"} + boolean endUserVisible?; # The name of the form - string? name; + string name; + # Automatically assigned when creating ticket form + int id?; # The position of this form among other forms in the account, i.e. dropdown - int? position?; - # The dynamic content placeholder, if present, or the "display_name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_display_name?; - # The dynamic content placeholder, if present, or the "name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_name?; + int position?; # ids of all brands that this ticket form is restricted to - int[]? restricted_brand_ids?; - # ids of all ticket fields which are in this ticket form. The products use the order of the ids to show the field values in the tickets - int[]? ticket_field_ids?; - # The time of the last update of the ticket form - string? updated_at?; - # URL of the ticket form - string? url?; + @jsondata:Name {value: "restricted_brand_ids"} + int[] restrictedBrandIds?; }; -public type BatchJobResponse_results record { - TriggerCategory[]? trigger_categories?; - TriggerObject[]? triggers?; +# Represents the Headers record for the operation: ListTicketsFromView +public type ListTicketsFromViewHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type ListDeletedTicketsResponse record { - ListDeletedTicketsResponse_deleted_tickets[]? deleted_tickets?; + *ListDeletedTicketsResponseAllOf1; *OffsetPaginationObject; }; -public type MacroApplyTicketResponse_result_ticket record { - int? assignee_id?; - MacroApplyTicketResponse_result_ticket_comment? comment?; - MacroApplyTicketResponse_result_ticket_fields? fields?; - int? group_id?; - int? id?; - string? url?; -}; - public type TargetsResponse record { - TargetObject[]? targets?; + TargetObject[] targets?; }; -public type UserObject UserForAdmin|UserForEndUser?; +public type UserObject UserForAdmin|UserForEndUser; public type WorkspaceInput record { - # An object that describes the conditions under which the automation will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - ConditionsObject? conditions?; + decimal[] macros?; + @jsondata:Name {value: "ticket_form_id"} + decimal ticketFormId?; # User-defined description of this workspace's purpose - string? description?; - decimal[]? macros?; - decimal? ticket_form_id?; + string description?; + ConditionsObject conditions?; # The title of the workspace - string? title?; -}; - -public type ActionObject record { - # The name of a ticket field to modify - string? 'field?; - # The new value of the field - string? value?; -}; - -public type UserResponse record { - UserObject? user?; -}; - -public type Pagination_meta record { - string? after_cursor?; - string? before_cursor?; - boolean? has_more?; -}; - -public type Filter record { - TriggerObject? 'json?; -}; + string title?; +}; + +# Represents the Queries record for the operation: ExportAuditLogs +public type ExportAuditLogsQueries record { + # Filter audit logs by the source id. Requires `filter[source_type]` to also be set + @http:Query {name: "filter[source_id]"} + int filterSourceId?; + # Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time + @http:Query {name: "filter[created_at]"} + string filterCreatedAt?; + # Filter audit logs by the source type. For example, user or rule + @http:Query {name: "filter[source_type]"} + string filterSourceType?; + # Filter audit logs by the action + @http:Query {name: "filter[action]"} + string filterAction?; + # Filter audit logs by the actor id + @http:Query {name: "filter[actor_id]"} + int filterActorId?; + # Filter audit logs by the ip address + @http:Query {name: "filter[ip_address]"} + string filterIpAddress?; +}; + +public type ValueOneOf1 string; # Configuration settings for the role. See [Configuration](#configuration) public type CustomRoleConfigurationObject record { + @jsondata:Name {value: "moderate_forums"} + boolean moderateForums?; + # Whether or not the agent can contribute to side conversations + @jsondata:Name {value: "side_conversation_create"} + boolean sideConversationCreate?; + # Whether or not the agent can answer and place calls to end users + @jsondata:Name {value: "voice_access"} + boolean voiceAccess?; + # What the agent can do with customer lists. Allowed values: "full", "manage-group", "manage-personal", "none", "readonly" + @jsondata:Name {value: "user_view_access"} + string userViewAccess?; + # Whether or not the agent can merge tickets + @jsondata:Name {value: "ticket_merge"} + boolean ticketMerge?; + @jsondata:Name {value: "light_agent"} + boolean lightAgent?; + # What kind of tickets the agent can access. Allowed values: "all", "assigned-only", "within-groups", "within-groups-and-public-groups", "within-organization" + @jsondata:Name {value: "ticket_access"} + string ticketAccess?; + # Whether or not the agent can view details about calls on the Talk dashboard + @jsondata:Name {value: "voice_dashboard_access"} + boolean voiceDashboardAccess?; # Whether or not the agent can assign tickets to any group - boolean? assign_tickets_to_any_group?; - # Whether or not the agent has access to Chat - boolean? chat_access?; + @jsondata:Name {value: "assign_tickets_to_any_group"} + boolean assignTicketsToAnyGroup?; + # Allowed values: "edit", "full", "none", "readonly" + @jsondata:Name {value: "explore_access"} + string exploreAccess?; + # What the agent can do with macros. Allowed values: "full", "manage-group", "manage-personal", "readonly" + @jsondata:Name {value: "macro_access"} + string macroAccess?; + # Whether or not the agent can add or modify organization notes + @jsondata:Name {value: "organization_notes_editing"} + boolean organizationNotesEditing?; + # Whether or not the agent can view deleted tickets + @jsondata:Name {value: "view_deleted_tickets"} + boolean viewDeletedTickets?; # Whether or not the agent can view lists of user profiles. Allowed values: "full", "none" - string? end_user_list_access?; + @jsondata:Name {value: "end_user_list_access"} + string endUserListAccess?; # What the agent can do with end-user profiles. Allowed values: "edit", "edit-within-org", "full", "readonly" - string? end_user_profile_access?; - # Allowed values: "edit", "full", "none", "readonly" - string? explore_access?; + @jsondata:Name {value: "end_user_profile_access"} + string endUserProfileAccess?; + # Whether or not the agent can create and manage ticket fields + @jsondata:Name {value: "manage_ticket_fields"} + boolean manageTicketFields?; + # What the agent can do with reports. Allowed values: "full", "none", "readonly" + @jsondata:Name {value: "report_access"} + string reportAccess?; + # Whether or not the agent can access dynamic content + @jsondata:Name {value: "manage_dynamic_content"} + boolean manageDynamicContent?; # The kind of access the agent has to Guide. Allowed values: "edit-topics", "full", "readonly" - string? forum_access?; - boolean? forum_access_restricted_content?; + @jsondata:Name {value: "forum_access"} + string forumAccess?; + # What type of comments the agent can make. Allowed values: "public", "none" + @jsondata:Name {value: "ticket_comment_access"} + string ticketCommentAccess?; + @jsondata:Name {value: "twitter_search_access"} + boolean twitterSearchAccess?; + @jsondata:Name {value: "forum_access_restricted_content"} + boolean forumAccessRestrictedContent?; # Whether or not the agent can add or modify groups - boolean? group_access?; - boolean? light_agent?; - # What the agent can do with macros. Allowed values: "full", "manage-group", "manage-personal", "readonly" - string? macro_access?; + @jsondata:Name {value: "group_access"} + boolean groupAccess?; + # Whether or not the agent can edit ticket properties + @jsondata:Name {value: "ticket_editing"} + boolean ticketEditing?; + # Whether or not the agent can create and manage user fields + @jsondata:Name {value: "manage_user_fields"} + boolean manageUserFields?; # Whether or not the agent can manage business rules - boolean? manage_business_rules?; - # Whether or not the agent can view, add, and edit contextual workspaces - boolean? manage_contextual_workspaces?; - # Whether or not the agent can access dynamic content - boolean? manage_dynamic_content?; - # Whether or not the agent can manage channels and extensions - boolean? manage_extensions_and_channels?; - # Whether or not the agent can manage Facebook pages - boolean? manage_facebook?; + @jsondata:Name {value: "manage_business_rules"} + boolean manageBusinessRules?; # Whether or not the agent can create and manage organization fields - boolean? manage_organization_fields?; - # Whether or not the agent can create and manage ticket fields - boolean? manage_ticket_fields?; - # Whether or not the agent can create and manage ticket forms - boolean? manage_ticket_forms?; - # Whether or not the agent can create and manage user fields - boolean? manage_user_fields?; - boolean? moderate_forums?; - # Whether or not the agent can add or modify organizations - boolean? organization_editing?; - # Whether or not the agent can add or modify organization notes - boolean? organization_notes_editing?; - # What the agent can do with reports. Allowed values: "full", "none", "readonly" - string? report_access?; - # Whether or not the agent can contribute to side conversations - boolean? side_conversation_create?; - # What kind of tickets the agent can access. Allowed values: "all", "assigned-only", "within-groups", "within-groups-and-public-groups", "within-organization" - string? ticket_access?; - # What type of comments the agent can make. Allowed values: "public", "none" - string? ticket_comment_access?; + @jsondata:Name {value: "manage_organization_fields"} + boolean manageOrganizationFields?; # Whether or not the agent can delete tickets - boolean? ticket_deletion?; - # Whether or not the agent can edit ticket properties - boolean? ticket_editing?; - # Whether or not the agent can merge tickets - boolean? ticket_merge?; - # Whether or not the agent can edit ticket tags - boolean? ticket_tag_editing?; - boolean? twitter_search_access?; - # What the agent can do with customer lists. Allowed values: "full", "manage-group", "manage-personal", "none", "readonly" - string? user_view_access?; + @jsondata:Name {value: "ticket_deletion"} + boolean ticketDeletion?; # What the agent can do with views. Allowed values: "full", "manage-group", "manage-personal", "playonly", "readonly" - string? view_access?; - # Whether or not the agent can view deleted tickets - boolean? view_deleted_tickets?; - # Whether or not the agent can answer and place calls to end users - boolean? voice_access?; - # Whether or not the agent can view details about calls on the Talk dashboard - boolean? voice_dashboard_access?; + @jsondata:Name {value: "view_access"} + string viewAccess?; + # Whether or not the agent can edit ticket tags + @jsondata:Name {value: "ticket_tag_editing"} + boolean ticketTagEditing?; + # Whether or not the agent can manage Facebook pages + @jsondata:Name {value: "manage_facebook"} + boolean manageFacebook?; + # Whether or not the agent can view, add, and edit contextual workspaces + @jsondata:Name {value: "manage_contextual_workspaces"} + boolean manageContextualWorkspaces?; + # Whether or not the agent can create and manage ticket forms + @jsondata:Name {value: "manage_ticket_forms"} + boolean manageTicketForms?; + # Whether or not the agent can manage channels and extensions + @jsondata:Name {value: "manage_extensions_and_channels"} + boolean manageExtensionsAndChannels?; + # Whether or not the agent can add or modify organizations + @jsondata:Name {value: "organization_editing"} + boolean organizationEditing?; + # Whether or not the agent has access to Chat + @jsondata:Name {value: "chat_access"} + boolean chatAccess?; }; public type SLAPolicyResponse record { - SLAPolicyObject? sla_policy?; -}; - -public type TriggerConditionDiffObject record { - # An array of [change](#change) objects - TriggerChangeObject[]? 'field?; - # An array of [change](#change) objects - TriggerChangeObject[]? operator?; - # An array of [change](#change) objects - TriggerChangeObject[]? value?; -}; - -# The value of the chat event object -public type TicketChatCommentRedactionResponse_chat_event_value record { - # Id of the chat session - string? chat_id?; - # Chat events within the chat session - record {}[]? history?; - # Id assigned to the visitor - string? visitor_id?; -}; - -public type MacroApplyTicketResponse_result_ticket_comment record { - string? body?; - boolean? 'public?; - string[][]? scoped_body?; -}; - -public type UserFieldsResponse record { - # Total count of records retrieved - int? count?; - # URL of the next page - string? next_page?; - # URL of the previous page - string? previous_page?; - UserFieldObject[]? user_fields?; + @jsondata:Name {value: "sla_policy"} + SLAPolicyObject slaPolicy?; +}; + +# Represents the Headers record for the operation: RedactTicketCommentInAgentWorkspace +public type RedactTicketCommentInAgentWorkspaceHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: CountAuditsForTicket +public type CountAuditsForTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: AutocompleteCustomObjectRecordSearch +public type AutocompleteCustomObjectRecordSearchQueries record { + # The id of the lookup field. If the field has a relationship filter, the filter is applied to the results. Must be used with `source` param + @http:Query {name: "field_id"} + string fieldId?; + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[before]"} + string pageBefore?; + # Part of a name of the record you are searching for + string name?; + # One of "zen:user", "zen:ticket", "zen:organization", or "zen:custom_object:CUSTOM_OBJECT_KEY". Represents the object `field_id` belongs to. Must be used with field_id param + string 'source?; + # The number of records to return in the response. You can specify up to 100 records per page + @http:Query {name: "page[size]"} + int pageSize?; + # A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + @http:Query {name: "page[after]"} + string pageAfter?; }; -public type ViewsCountResponse record { - ActivitiesCountResponse_count? count?; +# Who may access this macro. Will be null when everyone in the account can access it +public type MacroInputRestriction record { + # The numeric ID of the group or user + int id?; + # The numeric IDs of the groups + int[] ids?; + # Allowed values are Group or User + string 'type?; }; public type TicketMergeInput record { - # Ids of tickets to merge into the target ticket - int[]? ids; - # Private comment to add to the source ticket - string? source_comment?; # Whether comment in source tickets are public or private - boolean? source_comment_is_public?; - # Private comment to add to the target ticket - string? target_comment?; + @jsondata:Name {value: "source_comment_is_public"} + boolean sourceCommentIsPublic?; # Whether comment in target ticket is public or private - boolean? target_comment_is_public?; + @jsondata:Name {value: "target_comment_is_public"} + boolean targetCommentIsPublic?; + # Private comment to add to the target ticket + @jsondata:Name {value: "target_comment"} + string targetComment?; + # Ids of tickets to merge into the target ticket + int[] ids; + # Private comment to add to the source ticket + @jsondata:Name {value: "source_comment"} + string sourceComment?; }; -public type User_field_id int|string; - public type AssigneeFieldAssignableGroupObject record { + # Name of the group + string name?; # Description of the group - string? description?; + string description?; # Group ID - int? id?; - # Name of the group - string? name?; -}; - -public type CustomFieldOptionResponse record { - CustomFieldOptionObject? custom_field_option?; + int id?; }; public type SLAPolicyMetricObject record { # Whether the metric targets are being measured in business hours or calendar hours - boolean? business_hours?; + @jsondata:Name {value: "business_hours"} + boolean businessHours?; # The definition of the time that is being measured - string? metric?; + string metric?; # Priority that a ticket must match - string? priority?; + string priority?; # The time within which the end-state for a metric should be met - int? target?; + int target?; }; public type HostMappingObject record { - # The canonical name record for a host mapping - string? cname?; + # Reason why a host mapping is valid or not + string reason?; # Array of expected CNAME records for host mapping(s) of a given brand - string[]? expected_cnames?; + @jsondata:Name {value: "expected_cnames"} + string[] expectedCnames?; # Whether a host mapping is valid or not for a given brand - boolean? is_valid?; - # Reason why a host mapping is valid or not - string? reason?; + @jsondata:Name {value: "is_valid"} + boolean isValid?; + # The canonical name record for a host mapping + string cname?; }; -public type AssigneeFieldAssignableSearchGroupObject record { - # Group ID - int? id?; - # Name of the group - string? name?; +# Represents the Headers record for the operation: DeleteTicketField +public type DeleteTicketFieldHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type CustomObject record { - # The time the object type was created - string? created_at?; - # Id of a user who created the object - string? created_by_user_id?; - # User-defined description of the object - string? description?; - # A user-defined unique identifier. Writable on create only. Cannot be reused if deleted. - string? 'key; - # The dynamic content placeholder, if present, or the "raw_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_description?; # The dynamic content placeholder, if present, or the "title" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_title?; - # The dynamic content placeholder, if present, or the "raw_title_pluralized" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_title_pluralized?; - # User-defined display name for the object - string? title; + @jsondata:Name {value: "raw_title"} + string rawTitle?; # User-defined pluralized version of the object's title - string? title_pluralized; + @jsondata:Name {value: "title_pluralized"} + string titlePluralized; # The time of the last update of the object - string? updated_at?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; # Id of the last user who updated the object - string? updated_by_user_id?; + @jsondata:Name {value: "updated_by_user_id"} + string updatedByUserId?; + # The dynamic content placeholder, if present, or the "raw_title_pluralized" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_title_pluralized"} + string rawTitlePluralized?; + # The time the object type was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # User-defined description of the object + string description?; + # User-defined display name for the object + string title; + # Id of a user who created the object + @jsondata:Name {value: "created_by_user_id"} + string createdByUserId?; + # The dynamic content placeholder, if present, or the "raw_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + @jsondata:Name {value: "raw_description"} + string rawDescription?; + # A user-defined unique identifier. Writable on create only. Cannot be reused if deleted + string 'key; # Direct link to the specific custom object - string? url?; + string url?; }; -public type Pagination_links record { - string? next?; - string? prev?; +# Represents the Headers record for the operation: ListTicketIncidents +public type ListTicketIncidentsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: DeleteTicketField +public type DeleteTicketFieldQueries record { + # If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created + # by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field + # is not created by an app, then `creator_app_name` is null + boolean creator?; }; public type TicketFieldResponse record { - TicketFieldObject? ticket_field?; + @jsondata:Name {value: "ticket_field"} + TicketFieldObject ticketField?; }; -public type DefinitionsResponse_definitions_values record { - boolean? enabled?; - string? title?; - string? value?; +public type ViaObjectSourceTo record { + string address?; + string name?; }; -public type BrandObject record { - # If the brand is set as active - boolean? active?; - # The url of the brand - string? brand_url?; - # The time the brand was created - string? created_at?; - # Is the brand the default brand for this account - boolean? default?; - # If the brand has a Help Center - boolean? has_help_center?; - # The state of the Help Center - "enabled"|"disabled"|"restricted" help_center_state?; - # The hostmapping to this brand, if any. Only admins view this property. - string? host_mapping?; - # The ID automatically assigned when the brand is created - int? id?; - # If the brand object is deleted or not - boolean? is_deleted?; - # A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - AttachmentObject? logo?; - # The name of the brand - string? name; - # The signature template for a brand - string? signature_template?; - # The subdomain of the brand - string? subdomain; - # The ids of ticket forms that are available for use by a brand - int[]? ticket_form_ids?; - # The time of the last update of the brand - string? updated_at?; - # The API url of this brand - string? url?; +# Represents the Headers record for the operation: AutocompleteTags +public type AutocompleteTagsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# Apps configuration options. See [Apps](#apps) -public type AccountSettingsAppsObject record { - boolean? create_private?; - boolean? create_public?; - boolean? use?; +# Represents the Headers record for the operation: ShowSatisfactionRatings +public type ShowSatisfactionRatingsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TargetURL record { - string? attribute; - # "get" - string? method?; - # only writable - string? password?; - string? target_url; - string? username?; +# Represents the Headers record for the operation: ExportSearchResults +public type ExportSearchResultsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type ViewCountResponse record { - ViewCountObject? view_count?; + @jsondata:Name {value: "view_count"} + ViewCountObject viewCount?; }; -# See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example. +# See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example public type CursorBasedExportIncrementalTicketsResponse record { - string? after_cursor?; - string? after_url?; - string? before_cursor?; - string? before_url?; - boolean? end_of_stream?; - TicketObject[]? tickets?; + @jsondata:Name {value: "before_url"} + string? beforeUrl?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + TicketObject[] tickets?; + @jsondata:Name {value: "after_cursor"} + string? afterCursor?; + @jsondata:Name {value: "after_url"} + string? afterUrl?; + @jsondata:Name {value: "before_cursor"} + string? beforeCursor?; }; public type OrganizationSubscriptionCreateRequest record { - OrganizationSubscriptionInput? organization_subscription?; -}; - -public type TargetJira record { - # only writable - string? password; - string? target_url; - string? username; -}; - -public type IncrementalSkillBasedRoutingAttributeValue record { - # Id of the associated attribute - string? attribute_id?; - # Automatically assigned when an attribute value is created - string? id?; - # The name of the attribute value - string? name?; - # The time the attribute value was created, updated, or deleted - string? time?; - # One of "create", "update", or "delete" - string? 'type?; + @jsondata:Name {value: "organization_subscription"} + OrganizationSubscriptionInput organizationSubscription?; }; public type ActivitiesCountResponse record { - ActivitiesCountResponse_count? count?; + ActivitiesCountResponseCount count?; }; public type TicketFieldCountResponse record { - ActivitiesCountResponse_count? count?; + ActivitiesCountResponseCount count?; }; -public type TicketImportRequest record { - TicketImportInput? ticket?; +# Represents the Headers record for the operation: UpdateDynamicContentVariant +public type UpdateDynamicContentVariantHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type BulkUpdateDefaultCustomStatusRequest record { # The comma-separated list of custom ticket status ids to be set as default for their status categories - string? ids?; + string ids?; }; -public type UserIdentityResponse record { - UserIdentityObject? identity?; -}; - -public type MacroInput record { - # Each action describes what the macro will do - ActionObject[]? actions; - # Useful for determining if the macro should be displayed - boolean? active?; - # The description of the macro - string? description?; - # Who may access this macro. Will be null when everyone in the account can access it - MacroInput_restriction? restriction?; - # The title of the macro - string? title; +# Represents the Headers record for the operation: DeleteUpload +public type DeleteUploadHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketChatCommentRedactionResponse record { - # Chat event object - TicketChatCommentRedactionResponse_chat_event? chat_event?; +public type UserIdentityResponse record { + UserIdentityObject identity?; }; public type TriggerBatchRequest record { - boolean? active?; - string? category_id?; - string? id; - int? position?; + @jsondata:Name {value: "category_id"} + string categoryId?; + boolean active?; + string id; + int position?; }; -public type CustomObjectRecordResponse record { - CustomObjectRecord? custom_object_record?; +# Represents the Queries record for the operation: BulkRestoreDeletedTickets +public type BulkRestoreDeletedTicketsQueries record { + # Comma-separated list of ticket ids + string ids; }; -public type MacroApplyTicketResponse_result_ticket_fields record { - int? id?; - string? value?; +# Represents the Headers record for the operation: CreateAssociatedMacroAttachment +public type CreateAssociatedMacroAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type OrganizationSubscriptionInput record { - # The ID of the organization - int? organization_id?; # The ID of the user - int? user_id?; -}; - -public type SkillBasedRoutingAttributeValuesResponse record { - SkillBasedRoutingAttributeValueObject[]? attribute_values?; -}; - -public type TargetClickatell record { - string? api_id; - # Read-only - string? attribute?; - string? 'from?; - # Read-only - string? method?; - # only writable - string? password; - # Read-only - string? target_url?; - string? to; - string? us_small_business_account?; - string? username; -}; - -public type TriggerObject record { - # An array of actions describing what the trigger will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) - TriggerActionObject[]? actions; - # Whether the trigger is active - boolean? active?; - # The ID of the category the trigger belongs to - string? category_id?; - # An object that describes the conditions under which the trigger will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - TriggerConditionsObject? conditions; - # The time the trigger was created - string? created_at?; - # If true, the trigger is a default trigger - boolean? default?; - # The description of the trigger - string? description?; - # Automatically assigned when created - int? id?; - # Position of the trigger, determines the order they will execute in - int? position?; - # The raw format of the title of the trigger - string? raw_title?; - # The title of the trigger - string? title; - # The time of the last update of the trigger - string? updated_at?; - # The url of the trigger - string? url?; -}; - -public type TicketUpdateResponse record { - AuditObject? audit?; - TicketObject? ticket?; -}; - -public type TriggerRevisionsResponse_diff record { - # An array that contain [action diff objects](#Action Diffs) - TriggerActionDiffObject[]? actions?; - # An array of [change](#change) objects - TriggerChangeObject[]? active?; - TriggerConditionDiffObject? conditions?; - # An array of [change](#change) objects - TriggerChangeObject[]? description?; - # ID of the source revision - int? source_id?; - # ID of the target revision - int? target_id?; - # An array of [change](#change) objects - TriggerChangeObject[]? title?; + @jsondata:Name {value: "user_id"} + int userId?; + # The ID of the organization + @jsondata:Name {value: "organization_id"} + int organizationId?; }; -public type UserCreateInput record { - int? custom_role_id?; - string? email; - string? external_id?; - UserCreateInput_identities[]? identities?; - string? name; - UserCreateInput_organization? organization?; - int? organization_id?; - string? role?; +# Represents the Headers record for the operation: SearchTriggers +public type SearchTriggersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TargetFlowdock record { - string? api_token; +# Represents the Headers record for the operation: AutocompleteCustomObjectRecordSearch +public type AutocompleteCustomObjectRecordSearchHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AccountSettingsObject record { - # The active features for an account. See [Active Features](#active-features) - AccountSettingsActiveFeaturesObject? active_features?; - # Configuration for the agent workspace. See [Agents](#agents) - AccountSettingsAgentObject? agents?; - # API configuration options. See [API](#api) - AccountSettingsApiObject? api?; - # Apps configuration options. See [Apps](#apps) - AccountSettingsAppsObject? apps?; - # Billing configuration options. See [Billing](#billing) - AccountSettingsBillingObject? billing?; - # Branding settings. See [Branding](#branding) - AccountSettingsBrandingObject? branding?; - # Brand settings. See [Brands](#brands) - AccountSettingsBrandsObject? brands?; - # CDN settings - AccountSettingsCdnObject? cdn?; - # Zendesk Chat settings. See [Chat](#chat) - AccountSettingsChatObject? chat?; - # Cross Sell settings - AccountSettingsCrossSellObject? cross_sell?; - # GoodData settings, used for insights. Legacy configuration prior to Zendesk Explore. See [GoodData Advanced Analytics](#gooddata-advanced-analytics) - AccountSettingsGooddataAdvancedAnalyticsObject? gooddata_advanced_analytics?; - # Google Apps configuration. See [G Suite](#g-suite) - AccountSettingsGoogleAppsObject? google_apps?; - # Group configuration - AccountSettingsGroupObject? groups?; - # Account limits configuration. See [Limits](#limits) - AccountSettingsLimitsObject? limits?; - # Internationalization configuration settings. See [Localization](#localization) - AccountSettingsLocalizationObject? localization?; - # Support UI settings. See [Lotus](#lotus) - AccountSettingsLotusObject? lotus?; - # Account metrics settings. See [Metrics](#metrics) - AccountSettingsMetricsObject? metrics?; - # Onboarding settings - AccountSettingsOnboardingObject? onboarding?; - # Configuration for routing. See [Routing](#routing) - AccountSettingsRoutingObject? routing?; - # Rules settings for triggers, macros, views, and automations. See [Rules](#rules) - AccountSettingsRuleObject? rule?; - # Side conversations settings - AccountSettingsSideConversationsObject? side_conversations?; - # Account statistics settings. See [Statistics](#statistics) - AccountSettingsStatisticsObject? statistics?; - # Ticket form settings. See [Ticket Form](#ticket-form) - AccountSettingsTicketFormObject? ticket_form?; - # Ticket sharing partners settings. See [Ticket Sharing Partners](#ticket-sharing-partners) - AccountSettingsTicketSharingPartnersObject? ticket_sharing_partners?; - # Ticket settings. See [Tickets](#tickets) - AccountSettingsTicketObject? tickets?; - # X (formerly Twitter) settings. See [X](#x-formerly-twitter) - AccountSettingsTwitterObject? twitter?; - # User settings. See [Users](#users) - AccountSettingsUserObject? user?; - # Zendesk Talk settings. See [Voice](#voice) - AccountSettingsVoiceObject? voice?; +public type SkillBasedRoutingAttributeValuesResponse record { + @jsondata:Name {value: "attribute_values"} + SkillBasedRoutingAttributeValueObject[] attributeValues?; }; -public type BrandsResponse record { - *OffsetPaginationObject; - # Array of brands - BrandObject[]? brands?; +# Represents the Headers record for the operation: ShowLocaleById +public type ShowLocaleByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TagsResponse record { - # The number of pages - int? count?; - # The url of the previous page - string? next_page?; - # The url of the next page - string? previous_page?; - TagListTagObject[]? tags?; +public type TicketUpdateResponse record { + TicketObject ticket?; + AuditObject audit?; }; -public type EssentialsCardsResponse record { - EssentialsCardObject[]? object_layouts?; +# Represents the Headers record for the operation: OpenUsersProfileInAgentBrowser +public type OpenUsersProfileInAgentBrowserHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomObjectFieldResponse record { - CustomObjectField? custom_object_field?; +# Represents the Headers record for the operation: ShowMacroAttachment +public type ShowMacroAttachmentHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyFilterDefinitionResponse_definitions record { - GroupSLAPolicyFilterDefinitionResponse_definitions_all[]? all?; +# Represents the Headers record for the operation: DeleteOrganizationSubscription +public type DeleteOrganizationSubscriptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerRevisionsResponse_trigger_revisions record { - int? author_id?; - string? created_at?; - TriggerRevisionsResponse_diff? diff?; - int? id?; - TriggerSnapshotObject? snapshot?; - string? url?; +# Represents the Headers record for the operation: GroupMembershipSetDefault +public type GroupMembershipSetDefaultHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketMetricEventsResponse record { - TicketMetricEventBaseObject[]? ticket_metric_events?; - int? count?; - int? end_time?; - string? next_page?; +# Represents the Headers record for the operation: DeleteEssentialsCard +public type DeleteEssentialsCardHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BatchJobResponse record { - BatchErrorItem[]? errors?; - BatchJobResponse_results? results?; - "complete"|"failed" status?; +public type AccountSettingsObject record { + AccountSettingsLocalizationObject localization?; + AccountSettingsVoiceObject voice?; + @jsondata:Name {value: "side_conversations"} + AccountSettingsSideConversationsObject sideConversations?; + AccountSettingsTicketObject tickets?; + AccountSettingsBrandingObject branding?; + AccountSettingsLotusObject lotus?; + AccountSettingsRuleObject rule?; + @jsondata:Name {value: "gooddata_advanced_analytics"} + AccountSettingsGooddataAdvancedAnalyticsObject gooddataAdvancedAnalytics?; + @jsondata:Name {value: "active_features"} + AccountSettingsActiveFeaturesObject activeFeatures?; + AccountSettingsBillingObject billing?; + @jsondata:Name {value: "ticket_form"} + AccountSettingsTicketFormObject ticketForm?; + AccountSettingsRoutingObject routing?; + AccountSettingsTwitterObject twitter?; + AccountSettingsOnboardingObject onboarding?; + AccountSettingsApiObject api?; + AccountSettingsLimitsObject limits?; + AccountSettingsAppsObject apps?; + AccountSettingsBrandsObject brands?; + AccountSettingsGroupObject groups?; + AccountSettingsCdnObject cdn?; + @jsondata:Name {value: "cross_sell"} + AccountSettingsCrossSellObject crossSell?; + AccountSettingsAgentObject agents?; + AccountSettingsChatObject chat?; + @jsondata:Name {value: "ticket_sharing_partners"} + AccountSettingsTicketSharingPartnersObject ticketSharingPartners?; + AccountSettingsMetricsObject metrics?; + @jsondata:Name {value: "google_apps"} + AccountSettingsGoogleAppsObject googleApps?; + AccountSettingsUserObject user?; + AccountSettingsStatisticsObject statistics?; +}; + +# Represents the Headers record for the operation: ListAuditsForTicket +public type ListAuditsForTicketHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyResponse record { - GroupSLAPolicyObject? group_sla_policy?; +public type CustomObjectFieldResponse record { + @jsondata:Name {value: "custom_object_field"} + CustomObjectField customObjectField?; }; -public type MacroApplyTicketResponse record { - MacroApplyTicketResponse_result? result?; +# Represents the Queries record for the operation: ListActiveViews +public type ListActiveViewsQueries record { + # Only views with given access. May be "personal", "shared", or "account" + string access?; + # Only views belonging to given group + @http:Query {name: "group_id"} + int groupId?; + # Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; }; -public type CustomObjectRecordsJobsResponse_job_status record { - string? id?; - string? message?; - int? progress?; - CustomObjectRecord[]? results?; - string? status?; - int? total?; - string? url?; +public type TicketMetricEventsResponse record { + *TicketMetricEventsResponseAllOf1; + *TicketMetricEventsResponseTicketMetricEventsResponseAllOf12; +}; + +# Represents the Queries record for the operation: ListMacros +public type ListMacrosQueries record { + # A sideload to include in the response. See [Sideloads](#sideloads-2) + string include?; + # Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins + string access?; + # Filter macros by group + @http:Query {name: "group_id"} + int groupId?; + # Filter by active macros if true or inactive macros if false + boolean active?; + # If true, returns only macros that can be applied to tickets. If false, returns all macros the current user can manage. Default is false + @http:Query {name: "only_viewable"} + boolean onlyViewable?; + # Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical + @http:Query {name: "sort_by"} + string sortBy?; + # Filter macros by category + int category?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; }; -public type GroupsCountObject_count record { - # Timestamp that indicates when the count was last updated - string? refreshed_at?; - # Approximate count of groups - int? value?; +public type MacroApplyTicketResponse record { + MacroApplyTicketResponseResult result?; }; -public type TargetBasecamp record { - # Can be filled if it is a "message" resource - string? message_id?; - # The 37Signals password for the Basecamp account (only writable) - string? password?; - # The ID of the project in Basecamp where updates should be pushed - string? project_id; - # "todo" or "message" - string? 'resource; - # The URL of your Basecamp account, including protocol and path - string? target_url; - # Can be filled if it is a "todo" resource - string? todo_list_id?; - # Get the API token from My info > Show your tokens > Token for feed readers or the Basecamp API in your Basecamp account - string? token; - # The 37Signals username of the account you use to log in to Basecamp - string? username?; +# Represents the Headers record for the operation: ReorderCustomObjectFields +public type ReorderCustomObjectFieldsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TimeBasedExportIncrementalUsersResponse record { - int? count?; - boolean? end_of_stream?; - int? end_time?; - string? next_page?; - UserObject[]? users?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + int count?; + @jsondata:Name {value: "end_time"} + int endTime?; + UserObject[] users?; }; public type ExportIncrementalTicketEventsResponse record { - int? count?; - boolean? end_of_stream?; - int? end_time?; - string? next_page?; - TicketMetricEventBaseObject[]? ticket_events?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + @jsondata:Name {value: "end_of_stream"} + boolean endOfStream?; + @jsondata:Name {value: "ticket_events"} + TicketMetricEventBaseObject[] ticketEvents?; + int count?; + @jsondata:Name {value: "end_time"} + int endTime?; }; public type TargetFailureObject record { - # Number of times the target failed consecutively - int? consecutive_failure_count?; - # Time of the failure - string? created_at?; - # The ID of the target failure - int? id?; # The raw message of the target request - string? raw_request?; - # The raw response of the failure - string? raw_response?; + @jsondata:Name {value: "raw_request"} + string rawRequest?; # HTTP status code of the target failure - int? status_code?; + @jsondata:Name {value: "status_code"} + int statusCode?; # Name of the target failure - string? target_name?; + @jsondata:Name {value: "target_name"} + string targetName?; + # Time of the failure + @jsondata:Name {value: "created_at"} + string createdAt?; + # Number of times the target failed consecutively + @jsondata:Name {value: "consecutive_failure_count"} + int consecutiveFailureCount?; + # The ID of the target failure + int id?; + # The raw response of the failure + @jsondata:Name {value: "raw_response"} + string rawResponse?; # The API url of the failure record - string? url?; + string url?; }; -public type TargetPivotal record { - string? owner_by?; - string? project_id; - string? requested_by?; - string? story_labels?; - string? story_title; - string? story_type; - string? token; +public type filter record { + TriggerObject 'json?; }; public type CustomObjectCreateInput record { - # Unique identifier. Writable on create only - string? 'key?; - # Display name for the object - string? title?; # Pluralized version of the object's title - string? title_pluralized?; + @jsondata:Name {value: "title_pluralized"} + string titlePluralized?; + # Display name for the object + string title?; + # Unique identifier. Writable on create only + string 'key?; }; -public type TriggerActionDiffObject record { - # An array of [change](#change) objects. - TriggerChangeObject[]? 'field?; - # An array of [change](#change) objects. - TriggerChangeObject[]? value?; +# Represents the Queries record for the operation: IncrementalUserExportCursor +public type IncrementalUserExportCursorQueries record { + # The cursor pointer to work with for all subsequent exports after the initial request + string cursor?; + # The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + @http:Query {name: "start_time"} + int startTime; + # The number of records to return per page + @http:Query {name: "per_page"} + int perPage?; }; -public type CustomFieldOptionObject record { - # Automatically assigned upon creation - int? id?; - # Name of the dropdown option - string? name; - # Position of the dropdown option - int? position?; - # Raw name of the dropdown option - string? raw_name?; - # URL of the dropdown option - string? url?; - # Value of the dropdown option - string? value; +# Represents the Headers record for the operation: CountUsers +public type CountUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BookmarkCreateRequest record { - BookmarkInput? bookmark?; +# Represents the Headers record for the operation: ListAuditLogs +public type ListAuditLogsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketFormsResponse record { - TicketFormObject[]? ticket_forms?; +public type BookmarkCreateRequest record { + BookmarkInput bookmark?; }; -public type SharingAgreementsResponse record { - SharingAgreementObject[]? sharing_agreements?; +public type TicketFormsResponse record { + @jsondata:Name {value: "ticket_forms"} + TicketFormObject[] ticketForms?; }; -public type SatisfactionReasonResponse record { - SatisfactionReasonObject[]? reason?; +# Represents the Headers record for the operation: GetUserPasswordRequirements +public type GetUserPasswordRequirementsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# The links to the previous and next entries via the cursor ids in the metadata. -public type SearchExportResponse_links record { - # The url to the next entry via the cursor. - string? next?; - # The url to the previous entry via the cursor. - string? prev?; +# Represents the Headers record for the operation: ListTicketSkips +public type ListTicketSkipsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BookmarkObject record { - # The time the bookmark was created - string? created_at?; - # Automatically assigned when the bookmark is created - int? id?; - TicketObject?? ticket?; - # The API url of this bookmark - string? url?; +# Represents the Headers record for the operation: SearchUsers +public type SearchUsersHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomStatusObject record { - # If true, the custom status is set to active, If false, the custom status is set to inactive - boolean? active?; - # The label displayed to agents. Maximum length is 48 characters - string? agent_label; - # The date and time the custom ticket status was created - string? created_at?; - # If true, the custom status is set to default. If false, the custom status is set to non-default - boolean? default?; - # The description of when the user should select this custom ticket status - string? description?; - # The description displayed to end users - string? end_user_description?; - # The label displayed to end users. Maximum length is 48 characters - string? end_user_label?; - # Automatically assigned when the custom ticket status is created - int? id?; - # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "agent_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_agent_label?; - # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "description" value. [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_description?; - # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_description" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_end_user_description?; - # The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - string? raw_end_user_label?; - # The status category the custom ticket status belongs to - "new"|"open"|"pending"|"hold"|"solved" status_category; - # The date and time the custom ticket status was last updated - string? updated_at?; +# Represents the Headers record for the operation: UpsertCustomObjectRecord +public type UpsertCustomObjectRecordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type AutomationResponse record { - AutomationObject? automation?; -}; - -public type SearchCountResponse record { - int? count?; + AutomationObject automation?; }; public type TicketAuditResponse record { - TicketAuditObject? audit?; + TicketAuditObject audit?; }; # Configuration for routing. See [Routing](#routing) public type AccountSettingsRoutingObject record { - string? autorouting_tag?; - boolean? enabled?; - int? max_email_capacity?; - int? max_messaging_capacity?; - boolean? reassignment_messaging_enabled?; - int? reassignment_messaging_timeout?; - int? reassignment_talk_timeout?; -}; - -public type JobStatusObject record { - # Automatically assigned when the job is queued - string? id?; - # The type of the job - string? job_type?; - # Message from the job worker, if any - string? message?; - # Number of tasks that have already been completed - int? progress?; - # Result data from processed tasks. See [Results](#results) below - JobStatusResultObject[]|record { - # Whether the action was successful or not - boolean? success; - }? results?; - # The current status. One of the following: "queued", "working", "failed", "completed" - string? status?; - # The total number of tasks this job is batching through - int? total?; - # The URL to poll for status updates - string? url?; + @jsondata:Name {value: "reassignment_messaging_enabled"} + boolean reassignmentMessagingEnabled?; + @jsondata:Name {value: "reassignment_messaging_timeout"} + int reassignmentMessagingTimeout?; + @jsondata:Name {value: "autorouting_tag"} + string autoroutingTag?; + @jsondata:Name {value: "max_email_capacity"} + int maxEmailCapacity?; + boolean enabled?; + @jsondata:Name {value: "max_messaging_capacity"} + int maxMessagingCapacity?; + @jsondata:Name {value: "reassignment_talk_timeout"} + int reassignmentTalkTimeout?; }; # Group configuration public type AccountSettingsGroupObject record { - boolean? check_group_name_uniqueness?; + @jsondata:Name {value: "check_group_name_uniqueness"} + boolean checkGroupNameUniqueness?; }; -# GoodData settings, used for insights. Legacy configuration prior to Zendesk Explore. See [GoodData Advanced Analytics](#gooddata-advanced-analytics) -public type AccountSettingsGooddataAdvancedAnalyticsObject record { - boolean? enabled?; +# Represents the Headers record for the operation: SearchMacro +public type SearchMacroHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type AuthorObject record { - # The author email - string? email?; - # The author id - int? id?; - # The author name - string? name?; +public type CustomStatusesResponse record { + @jsondata:Name {value: "custom_statuses"} + CustomStatusObject[] customStatuses?; }; -# Chat event object -public type TicketChatCommentRedactionResponse_chat_event record { - # Id assigned to the chat event object - int? id?; - # Type of chat event - string? 'type?; - # The value of the chat event object - TicketChatCommentRedactionResponse_chat_event_value? value?; +# Represents the Headers record for the operation: MarkManyTicketsAsSpam +public type MarkManyTicketsAsSpamHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type CustomStatusesResponse record { - CustomStatusObject[]? custom_statuses?; +public type MacroApplyTicketResponseResult record { + MacroApplyTicketResponseResultTicket ticket?; +}; + +# Represents the Headers record for the operation: ListViewsById +public type ListViewsByIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type Pagination record { - Pagination_links? links?; - Pagination_meta? meta?; + PaginationMeta meta?; + PaginationLinks links?; }; -public type RecoverSuspendedTicketUnprocessableContentResponse record { - SuspendedTicketObject[]? ticket?; +# Represents the Headers record for the operation: ShowDynamicContentItem +public type ShowDynamicContentItemHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerDefinitionResponse record { - TriggerDefinitionObject? definitions?; +public type MacroObject record { + *MacroCommonObject; + *MacroObjectAllOf2; }; -# A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object -public type AttachmentObject record { - *AttachmentBaseObject; - *AttachmentThumbnails; +public type SkillBasedRoutingAttributeResponse record { + SkillBasedRoutingAttributeObject attribute?; }; -public type LocalesResponse record { - LocaleObject[]? locales?; +# Represents the Queries record for the operation: ListCustomObjectFields +public type ListCustomObjectFieldsQueries record { + # Include standard fields if true. Exclude them if false + @http:Query {name: "include_standard_fields"} + boolean includeStandardFields?; }; -public type MacroObject record { - *MacroCommonObject; - # The app installation that requires each macro, if present - string? app_installation?; - # The macro categories - string? categories?; - # Permissions for each macro - string? permissions?; - # The number of times each macro has been used in the past hour - int? usage_1h?; - # The number of times each macro has been used in the past week - int? usage_7d?; - # The number of times each macro has been used in the past day - int? usage_24h?; - # The number of times each macro has been used in the past thirty days - int? usage_30d?; +# Represents the Headers record for the operation: DeleteGroupMembership +public type DeleteGroupMembershipHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SkillBasedRoutingAttributeResponse record { - SkillBasedRoutingAttributeObject? attribute?; +# Represents the Queries record for the operation: ListCustomStatuses +public type ListCustomStatusesQueries record { + # If true, show only default custom ticket statuses. If false, show only non-default custom ticket statuses. If the filter is not used, show all custom ticket statuses + boolean default?; + # Filter the list of custom ticket statuses by a comma-separated list of status categories + @http:Query {name: "status_categories"} + string statusCategories?; + # If true, show only active custom ticket statuses. If false, show only inactive custom ticket statuses. If the filter is not used, show all custom ticket statuses + boolean active?; }; -public type AttachmentResponse record { - # A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - AttachmentObject? attachment?; +public type SLAPolicyFilterDefinitionResponseDefinitionsAll record { + GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators[] operators?; + SLAPolicyFilterDefinitionResponseDefinitionsValues values?; + string title?; + string value?; + string group?; + string? target?; }; -public type MacroUpdateManyInput record { - MacroUpdateManyInput_macros[]? macros?; +# Represents the Headers record for the operation: IncrementalUserExportTime +public type IncrementalUserExportTimeHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type AutomationsResponse record { - AutomationObject[]? automations?; - int? count?; - string? next_page?; - string? previous_page?; + @jsondata:Name {value: "next_page"} + string? nextPage?; + AutomationObject[] automations?; + int count?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; }; public type GroupMembershipObject record { - # The time the group was created - string? created_at?; # If true, tickets assigned directly to the agent will assume this membership's group - boolean? default?; + boolean default?; + # The time of the last update of the group + @jsondata:Name {value: "updated_at"} + string updatedAt?; # The id of a group - int? group_id; + @jsondata:Name {value: "group_id"} + int groupId; + # The id of an agent + @jsondata:Name {value: "user_id"} + int userId; + # The time the group was created + @jsondata:Name {value: "created_at"} + string createdAt?; # Automatically assigned upon creation - int? id?; - # The time of the last update of the group - string? updated_at?; + int id?; # The API url of this record - string? url?; - # The id of an agent - int? user_id; + string url?; }; -public type JobStatusResultObject CreateResourceResult|UpdateResourceResult?; - -public type GroupMembershipResponse record { - GroupMembershipObject? group_membership?; +public type GroupSLAPolicyFilterDefinitionResponseDefinitionsValues record { + GroupSLAPolicyFilterDefinitionResponseDefinitionsValuesList[] list?; + string 'type?; }; -public type ListTicketEmailCCsResponse record { -}; +public type UserFieldObject CustomFieldObject; -public type DeletedUserObject record { - boolean? active; - string? created_at; - string? email; - int? id; - string? locale; - int? locale_id; - string? name; - int? organization_id; - string? phone; - record {}? photo; - string? role; - string? shared_phone_number; - string? time_zone; - string? updated_at; - string? url; +# Represents the Queries record for the operation: BulkDeleteViews +public type BulkDeleteViewsQueries record { + # The IDs of the views to delete + string ids; }; -public type UserFieldObject CustomFieldObject?; - -public type BrandResponse record { - BrandObject? brand?; +# Represents the Headers record for the operation: BulkDeleteViews +public type BulkDeleteViewsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type Errors record { - Error[]? errors?; +# Represents the Headers record for the operation: UnassignOrganization +public type UnassignOrganizationHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type RenewSessionResponse record { # A token of authenticity for the request - string? authenticity_token?; + @jsondata:Name {value: "authenticity_token"} + string authenticityToken?; }; -public type DynamicContentVariantsResponse record { - DynamicContentVariantObject[]? variants?; +public type MacroAttachmentResponse record { + @jsondata:Name {value: "macro_attachment"} + MacroAttachmentObject macroAttachment?; }; -public type RelationshipFilterDefinition record { - TriggerConditionDefinitionObjectAll[]? conditions_all?; - TriggerConditionDefinitionObjectAny[]? conditions_any?; +# Represents the Headers record for the operation: IncrementalTicketExportTime +public type IncrementalTicketExportTimeHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TriggerRevisionsResponse record { - string? after_cursor?; - string? after_url?; - string? before_cursor?; - string? before_url?; - int? count?; - TriggerRevisionsResponse_trigger_revisions[]? trigger_revisions?; +# Represents the Headers record for the operation: BulkRestoreDeletedTickets +public type BulkRestoreDeletedTicketsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type MacroAttachmentResponse record { - MacroAttachmentObject? macro_attachment?; +# Represents the Headers record for the operation: DeleteSLAPolicy +public type DeleteSLAPolicyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type GroupSLAPolicyMetricObject record { - # Whether the metric targets are being measured in business hours or calendar hours - boolean? business_hours?; - # The definition of the time that is being measured - string? metric?; - # Priority that a ticket must match - string? priority?; - # The time within which the end-state for a metric should be met - int? target?; -}; +public type userFieldId int|string; -public type TargetFailuresResponse record { - TargetFailureObject[]? target_failures?; +# Represents the Headers record for the operation: ShowManyJobStatuses +public type ShowManyJobStatusesHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; public type TicketCommentsResponse record { - TicketCommentObject[]? comments?; + TicketCommentObject[] comments?; }; -# Rules settings for triggers, macros, views, and automations. See [Rules](#rules) -public type AccountSettingsRuleObject record { - boolean? macro_most_used?; - string? macro_order?; - record {}[]? skill_based_filtered_views?; - boolean? using_skill_based_routing?; +# Represents the Queries record for the operation: ListViewsById +public type ListViewsByIdQueries record { + # List of view's ids separated by commas + string ids; + # Only active views if true, inactive views if false + boolean active?; }; -# Conditions when queue could be applied -public type QueueObject_definition record { - QueueObject_definition_all[]? all?; - QueueObject_definition_all[]? 'any?; +public type BrandsResponseAllOf2 record { + # Array of brands + BrandObject[] brands?; }; -public type AssigneeFieldAssignableGroupsResponse record { - # Number of groups listed in `groups` property. - int? count?; - AssigneeFieldAssignableGroupObject[]? groups?; - string? next_page?; - string? previous_page?; +public type ListDeletedTicketsResponseAllOf1 record { + @jsondata:Name {value: "deleted_tickets"} + ListDeletedTicketsResponseDeletedTickets[] deletedTickets?; }; -public type CustomObjectRecordsCreateRequest record { - CustomObjectRecord? custom_object_record?; +# Represents the Headers record for the operation: ShowTicketFieldOption +public type ShowTicketFieldOptionHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type SuspendedTicketsResponse record { - SuspendedTicketObject[]? suspended_tickets?; +# Represents the Headers record for the operation: ListGroupMembershipsByGroupId +public type ListGroupMembershipsByGroupIdHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type TicketUpdateInput record { - # An array of numeric IDs, emails, or objects containing name and email properties. See [Setting Collaborators](/api-reference/ticketing/tickets/tickets/#setting-collaborators). An email notification is sent to them when the ticket is updated - CollaboratorObject[]? additional_collaborators?; - # The email address of the agent to assign the ticket to - string? assignee_email?; - # The agent currently assigned to the ticket - int? assignee_id?; - # An array of the IDs of attribute values to be associated with the ticket - int[]? attribute_value_ids?; - # The ids of users currently CC'ed on the ticket - int[]? collaborator_ids?; - TicketCommentObject? comment?; - # Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) - CustomFieldObject[]? custom_fields?; - # The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) - int? custom_status_id?; - # If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format. - string? due_at?; - # An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-email-ccs) - EmailCCObject[]? email_ccs?; - # An id you can use to link Zendesk Support tickets to local records - string? external_id?; - # An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-followers) - FollowerObject[]? followers?; - # The group this ticket is assigned to - int? group_id?; - # The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) - int? organization_id?; - # The urgency with which the ticket should be addressed. - "urgent"|"high"|"normal"|"low" priority?; - # For tickets of type "incident", the ID of the problem the incident is linked to - int? problem_id?; - # The user who requested this ticket - int? requester_id?; - # Optional boolean. Prevents updates with outdated ticket data (`updated_stamp` property required when true) - boolean? safe_update?; - # An array of the numeric IDs of sharing agreements. Note that this replaces any existing agreements - int[]? sharing_agreement_ids?; - # The state of the ticket. - # - # If your account has activated custom ticket statuses, this is the ticket's - # status category. See [custom ticket statuses](#custom-ticket-statuses). - "new"|"open"|"pending"|"hold"|"solved"|"closed" status?; - # The value of the subject field for this ticket - string? subject?; - # The array of tags applied to this ticket - string[]? tags?; - # The type of this ticket. - "problem"|"incident"|"question"|"task" 'type?; - # Datetime of last update received from API. See the safe_update property - string? updated_stamp?; +public type AssigneeFieldAssignableGroupsResponse record { + @jsondata:Name {value: "next_page"} + string? nextPage?; + # Number of groups listed in `groups` property + int count?; + AssigneeFieldAssignableGroupObject[] groups?; + @jsondata:Name {value: "previous_page"} + string? previousPage?; }; -public type V2_macros_body record { - MacroInput? macro?; +public type WorkspacesReorderBody record { + decimal[] ids?; }; -public type TriggerRevisionResponse record { - TriggerRevisionResponse_trigger_revision? trigger_revision?; +# Represents the Headers record for the operation: ListCustomObjectFields +public type ListCustomObjectFieldsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -# CDN settings -public type AccountSettingsCdnObject record { - string? cdn_provider?; - string? fallback_cdn_provider?; - AccountSettingsCdnObject_hosts[]? hosts?; +# Represents the Headers record for the operation: ListMacros +public type ListMacrosHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type BatchErrorItem record { - *Error; - string? trigger_id?; +# Represents the Headers record for the operation: DeleteTicketPermanently +public type DeleteTicketPermanentlyHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Headers record for the operation: ListResourceTags +public type ListResourceTagsHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +public type TriggerRevisionResponse record { + @jsondata:Name {value: "trigger_revision"} + TriggerRevisionResponseTriggerRevision triggerRevision?; +}; + +# Represents the Headers record for the operation: SetUserPassword +public type SetUserPasswordHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; +}; + +# Represents the Queries record for the operation: ListAuditLogs +public type ListAuditLogsQueries record { + # Filter audit logs by the source id. Requires `filter[source_type]` to also be set + @http:Query {name: "filter[source_id]"} + int filterSourceId?; + # Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time + @http:Query {name: "filter[created_at]"} + string filterCreatedAt?; + # Filter audit logs by the source type. For example, user or rule + @http:Query {name: "filter[source_type]"} + string filterSourceType?; + # Filter audit logs by the action + @http:Query {name: "filter[action]"} + string filterAction?; + # Offset pagination only. Sort audit logs. Default is `sort_by=created_at` + @http:Query {name: "sort_by"} + string sortBy?; + # Cursor pagination only. Sort audit logs. Default is `sort=-created_at` + string sort?; + # Filter audit logs by the actor id + @http:Query {name: "filter[actor_id]"} + int filterActorId?; + # Offset pagination only. Sort audit logs. Default is `sort_order=desc` + @http:Query {name: "sort_order"} + string sortOrder?; + # Filter audit logs by the ip address + @http:Query {name: "filter[ip_address]"} + string filterIpAddress?; }; public type TicketSkipObject record { - # Time the skip was created - string? created_at?; - # Automatically assigned upon creation - int? id?; # Reason for skipping the ticket - string? reason?; + string reason?; # The skipped ticket. See the [Ticket object reference](/api-reference/ticketing/tickets/tickets/#json-format) - TicketObject?? ticket?; - # ID of the skipped ticket - int? ticket_id?; + TicketObject ticket?; # Time the skip was last updated - string? updated_at?; + @jsondata:Name {value: "updated_at"} + string updatedAt?; # ID of the skipping agent - int? user_id?; + @jsondata:Name {value: "user_id"} + int userId?; + # Time the skip was created + @jsondata:Name {value: "created_at"} + string createdAt?; + # Automatically assigned upon creation + int id?; + # ID of the skipped ticket + @jsondata:Name {value: "ticket_id"} + int ticketId?; }; -public type ViewCountsResponse record { - ViewCountObject[]? view_counts?; +public type BatchErrorItem record { + *Error; + *BatchErrorItemAllOf2; }; -public type UrlObject record { - string? url?; +public type ViewCountsResponse record { + @jsondata:Name {value: "view_counts"} + ViewCountObject[] viewCounts?; }; public type BookmarksResponse record { *OffsetPaginationObject; - BookmarkObject[]? bookmarks?; -}; - -public type RecoverSuspendedTicketsResponse record { - SuspendedTicketObject[]? tickets?; + *BookmarksResponseAllOf2; }; public type TriggerSnapshotObject record { - # An array of [Actions](#actions) describing what the trigger will do - TriggerActionObject[]? actions?; # Whether the trigger is active - boolean? active?; - # An object that describes the conditions under which the trigger will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - TriggerConditionsObject? conditions?; + boolean active?; # The description of the trigger string? description?; + TriggerConditionsObject conditions?; # The title of the trigger - string? title?; + string title?; + # An array of [Actions](#actions) describing what the trigger will do + TriggerActionObject[] actions?; }; -public type SatisfactionRatingsCountResponse record { - ActivitiesCountResponse_count? count?; +# Represents the Headers record for the operation: UpdateSharingAgreement +public type UpdateSharingAgreementHeaders record { + @http:Header {name: "Accept"} + string accept = "application/json"; }; -public type EssentialsCardResponse record { - EssentialsCardObject? object_layout?; +# Represents the Queries record for the operation: CountUsers +public type CountUsersQueries record { + # Filters the results by role. Possible values are "end-user", "agent", or "admin" + "end-user"|"agent"|"admin" role?; + # Filters the results by more than one role using the format `role[]={role}&role[]={role}` + string roles?; + # For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request + @http:Query {name: "permission_set"} + int permissionSet?; }; -# The status of the import for the indicated resource -public type ChannelFrameworkResultStatusObject record { - # A code indicating the status of the import of the resource, as described in [status codes](#status-codes) - string? code?; - # In the case of an exception, a description of the exception. Otherwise, not present. - string? description?; +public type SatisfactionRatingsCountResponse record { + ActivitiesCountResponseCount count?; }; -public type BatchJobRequest record { - BatchJobRequest_job? job?; +# Represents the Queries record for the operation: ListTicketSkips +public type ListTicketSkipsQueries record { + # Sort order. Defaults to "asc" + @http:Query {name: "sort_order"} + "asc"|"desc" sortOrder?; }; -public type CustomObjectFieldsCreateRequest record { - CustomObjectField? custom_object_field?; +public type UsersUpdateManyBody UserRequest|UsersRequest; + +# Represents the Queries record for the operation: BulkDeleteAutomations +public type BulkDeleteAutomationsQueries record { + # The IDs of the automations to delete + int[] ids?; }; public type TicketCreateVoicemailTicketRequest record { - # Optional value such as the ID of the agent that will see the newly created ticket. - int? display_to_agent?; # Ticket object that lists the values to set when the ticket is created - TicketCreateVoicemailTicketInput?? ticket?; -}; - -public type CustomObjectRecordsBulkCreateRequest record { - CustomObjectRecordsBulkCreateRequest_job? job?; -}; - -public type DefinitionsResponse_definitions_conditions_all record { - string? group?; - boolean? nullable?; - DefinitionsResponse_definitions_operators[]? operators?; - boolean? repeatable?; - string? subject?; - string? title?; - string? 'type?; - DefinitionsResponse_definitions_values[]? values?; + TicketCreateVoicemailTicketInput ticket?; + # Optional value such as the ID of the agent that will see the newly created ticket + @jsondata:Name {value: "display_to_agent"} + int displayToAgent?; +}; + +# Represents the Queries record for the operation: SearchViews +public type SearchViewsQueries record { + # A sideload to include in the response. See [Sideloads](#sideloads-3) + string include?; + # Filter views by access. May be "personal", "shared", or "account" + string access?; + # Filter views by group + @http:Query {name: "group_id"} + int groupId?; + # Query string used to find all views with matching title + string query; + # Filter by active views if true or inactive views if false + boolean active?; + # Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the views are sorted by relevance + @http:Query {name: "sort_by"} + string sortBy?; + # One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + @http:Query {name: "sort_order"} + string sortOrder?; +}; + +public type TriggerCategoriestriggerCategoryIdBody record { + @jsondata:Name {value: "trigger_category"} + TriggerCategoryRequest triggerCategory?; }; diff --git a/ballerina/utils.bal b/ballerina/utils.bal index 7e4fe4c..3cbf6df 100644 --- a/ballerina/utils.bal +++ b/ballerina/utils.bal @@ -17,6 +17,7 @@ // specific language governing permissions and limitations // under the License. +import ballerina/http; import ballerina/url; type SimpleBasicType string|boolean|int|float|decimal; @@ -74,11 +75,11 @@ isolated function getFormStyleRequest(string parent, record {} anyRecord, boolea string[] recordArray = []; if explode { foreach [string, anydata] [key, value] in anyRecord.entries() { - if (value is SimpleBasicType) { + if value is SimpleBasicType { recordArray.push(key, "=", getEncodedUri(value.toString())); - } else if (value is SimpleBasicType[]) { + } else if value is SimpleBasicType[] { recordArray.push(getSerializedArray(key, value, explode = explode)); - } else if (value is record {}) { + } else if value is record {} { recordArray.push(getFormStyleRequest(parent, value, explode)); } recordArray.push("&"); @@ -86,11 +87,11 @@ isolated function getFormStyleRequest(string parent, record {} anyRecord, boolea _ = recordArray.pop(); } else { foreach [string, anydata] [key, value] in anyRecord.entries() { - if (value is SimpleBasicType) { + if value is SimpleBasicType { recordArray.push(key, ",", getEncodedUri(value.toString())); - } else if (value is SimpleBasicType[]) { + } else if value is SimpleBasicType[] { recordArray.push(getSerializedArray(key, value, explode = false)); - } else if (value is record {}) { + } else if value is record {} { recordArray.push(getFormStyleRequest(parent, value, explode)); } recordArray.push(","); @@ -110,23 +111,23 @@ isolated function getFormStyleRequest(string parent, record {} anyRecord, boolea isolated function getSerializedArray(string arrayName, anydata[] anyArray, string style = "form", boolean explode = true) returns string { string key = arrayName; string[] arrayValues = []; - if (anyArray.length() > 0) { - if (style == FORM && !explode) { + if anyArray.length() > 0 { + if style == FORM && !explode { arrayValues.push(key, "="); foreach anydata i in anyArray { arrayValues.push(getEncodedUri(i.toString()), ","); } - } else if (style == SPACEDELIMITED && !explode) { + } else if style == SPACEDELIMITED && !explode { arrayValues.push(key, "="); foreach anydata i in anyArray { arrayValues.push(getEncodedUri(i.toString()), "%20"); } - } else if (style == PIPEDELIMITED && !explode) { + } else if style == PIPEDELIMITED && !explode { arrayValues.push(key, "="); foreach anydata i in anyArray { arrayValues.push(getEncodedUri(i.toString()), "|"); } - } else if (style == DEEPOBJECT) { + } else if style == DEEPOBJECT { foreach anydata i in anyArray { arrayValues.push(key, "[]", "=", getEncodedUri(i.toString()), "&"); } @@ -156,7 +157,7 @@ isolated function getSerializedRecordArray(string parent, record {}[] value, str arayIndex = arayIndex + 1; } } else { - if (!explode) { + if !explode { serializedArray.push(parent, "="); } foreach var recordItem in value { @@ -173,7 +174,7 @@ isolated function getSerializedRecordArray(string parent, record {}[] value, str # + return - Encoded string isolated function getEncodedUri(anydata value) returns string { string|error encoded = url:encode(value.toString(), "UTF8"); - if (encoded is string) { + if encoded is string { return encoded; } else { return value.toString(); @@ -186,21 +187,22 @@ isolated function getEncodedUri(anydata value) returns string { # + encodingMap - Details on serialization mechanism # + return - Returns generated Path or error at failure of client initialization isolated function getPathForQueryParam(map queryParam, map encodingMap = {}) returns string|error { + map queriesMap = http:getQueryMap(queryParam); string[] param = []; - if (queryParam.length() > 0) { + if queriesMap.length() > 0 { param.push("?"); - foreach var [key, value] in queryParam.entries() { + foreach var [key, value] in queriesMap.entries() { if value is () { - _ = queryParam.remove(key); + _ = queriesMap.remove(key); continue; } Encoding encodingData = encodingMap.hasKey(key) ? encodingMap.get(key) : defaultEncoding; - if (value is SimpleBasicType) { + if value is SimpleBasicType { param.push(key, "=", getEncodedUri(value.toString())); - } else if (value is SimpleBasicType[]) { + } else if value is SimpleBasicType[] { param.push(getSerializedArray(key, value, encodingData.style, encodingData.explode)); - } else if (value is record {}) { - if (encodingData.style == DEEPOBJECT) { + } else if value is record {} { + if encodingData.style == DEEPOBJECT { param.push(getDeepObjectStyleRequest(key, value)); } else { param.push(getFormStyleRequest(key, value, encodingData.explode)); @@ -215,25 +217,3 @@ isolated function getPathForQueryParam(map queryParam, map en string restOfPath = string:'join("", ...param); return restOfPath; } - -# Generate header map for given header values. -# -# + headerParam - Headers map -# + return - Returns generated map or error at failure of client initialization -isolated function getMapForHeaders(map headerParam) returns map { - map headerMap = {}; - foreach var [key, value] in headerParam.entries() { - if value is string || value is string[] { - headerMap[key] = value; - } else if value is int[] { - string[] stringArray = []; - foreach int intValue in value { - stringArray.push(intValue.toString()); - } - headerMap[key] = stringArray; - } else if value is SimpleBasicType { - headerMap[key] = value.toString(); - } - } - return headerMap; -} diff --git a/docs/spec/openapi.yaml b/docs/spec/openapi.yaml index 720d2a4..f7b378e 100644 --- a/docs/spec/openapi.yaml +++ b/docs/spec/openapi.yaml @@ -3,82 +3,84 @@ info: title: Support API description: Zendesk Support API endpoints version: 2.0.0 - # TODO: Add x-ballerina extensions +servers: +- url: //api +security: +- basicAuth: [] tags: - - name: Attachments - - name: Sessions - - name: Trigger Categories - - name: Tags - - name: Targets - - name: Target Failures - - name: Job Statuses - - name: Automations - - name: Tickets - - name: Lookup Relationships - - name: Dynamic Content - - name: Dynamic Content Item Variants - - name: Push Notification Devices - - name: Channel Framework - - name: Twitter Channel - - name: Organizations - - name: Triggers - - name: Custom Roles - - name: Incremental Export - - name: Account Settings - - name: Ticket Metrics - - name: Groups - - name: Group Memberships - - name: Incremental Skill Based Routing - - name: Organization Memberships - - name: Sharing Agreements - - name: Search - - name: Workspaces - - name: Skill Based Routing - - name: Resource Collections - - name: Macros - - name: Organization Subscriptions - - name: Support Addresses - - name: User Passwords - - name: User Identities - - name: Activity Stream - - name: Group SLA Policies - - name: SLA Policies - - name: Ticket Audits - - name: Ticket Metric Events - - name: Brands - - name: Users - - name: Satisfaction Reasons - - name: Ticket Forms - - name: Suspended Tickets - - name: Satisfaction Ratings - - name: Ticket Comments - - name: Requests - - name: Audit Logs - - name: Views - - name: Ticket Import - - name: Organization Fields - - name: User Fields - - name: Ticket Fields - - name: Ticket Skips - - name: Bookmarks - - name: Reseller - - name: Basics - - name: AssigneeFieldAssignableGroups - - name: AssigneeFieldAssignableAgents - - name: Custom Ticket Statuses - - name: Locales - - name: Custom Objects - - name: Custom Object Fields - - name: Custom Object Records - - name: Essentials Card - - name: Omnichannel Routing Queues +- name: Attachments +- name: Sessions +- name: Trigger Categories +- name: Tags +- name: Targets +- name: Target Failures +- name: Job Statuses +- name: Automations +- name: Tickets +- name: Lookup Relationships +- name: Dynamic Content +- name: Dynamic Content Item Variants +- name: Push Notification Devices +- name: Channel Framework +- name: Twitter Channel +- name: Organizations +- name: Triggers +- name: Custom Roles +- name: Incremental Export +- name: Account Settings +- name: Ticket Metrics +- name: Groups +- name: Group Memberships +- name: Incremental Skill Based Routing +- name: Organization Memberships +- name: Sharing Agreements +- name: Search +- name: Workspaces +- name: Skill Based Routing +- name: Resource Collections +- name: Macros +- name: Organization Subscriptions +- name: Support Addresses +- name: User Passwords +- name: User Identities +- name: Activity Stream +- name: Group SLA Policies +- name: SLA Policies +- name: Ticket Audits +- name: Ticket Metric Events +- name: Brands +- name: Users +- name: Satisfaction Reasons +- name: Ticket Forms +- name: Suspended Tickets +- name: Satisfaction Ratings +- name: Ticket Comments +- name: Requests +- name: Audit Logs +- name: Views +- name: Ticket Import +- name: Organization Fields +- name: User Fields +- name: Ticket Fields +- name: Ticket Skips +- name: Bookmarks +- name: Reseller +- name: Basics +- name: AssigneeFieldAssignableGroups +- name: AssigneeFieldAssignableAgents +- name: Custom Ticket Statuses +- name: Locales +- name: Custom Objects +- name: Custom Object Fields +- name: Custom Object Records +- name: Essentials Card +- name: Omnichannel Routing Queues paths: - /api/lotus/assignables/autocomplete.json: + /lotus/assignables/autocomplete.json: get: - operationId: ListAssigneeFieldAssignableGroupsAndAgentsSearch tags: - - AssigneeFieldAssignableGroups - - AssigneeFieldAssignableAgents + - AssigneeFieldAssignableGroups + - AssigneeFieldAssignableAgents summary: List assignable groups and agents based on query matched against name description: | List assignable groups and agents based on query matched against name @@ -86,9 +88,10 @@ paths: #### Allowed For * Agents + operationId: ListAssigneeFieldAssignableGroupsAndAgentsSearch parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AssigneeFieldSearchValue' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AssigneeFieldSearchValue' responses: "200": description: Success response @@ -99,11 +102,10 @@ paths: examples: default: $ref: '#/components/examples/AssigneeFieldAssignableGroupsAndAgentsSearchResponseExample' - /api/lotus/assignables/groups.json: + /lotus/assignables/groups.json: get: - operationId: ListAssigneeFieldAssignableGroups tags: - - AssigneeFieldAssignableAgents + - AssigneeFieldAssignableAgents summary: List assignable groups on the AssigneeField description: | List assignable groups on the AssigneeField @@ -111,6 +113,7 @@ paths: #### Allowed For * Agents + operationId: ListAssigneeFieldAssignableGroups responses: "200": description: Success response @@ -121,11 +124,10 @@ paths: examples: default: $ref: '#/components/examples/AssigneeFieldAssignableGroupsResponseExample' - /api/lotus/assignables/groups/{group_id}/agents.json: + /lotus/assignables/groups/{groupId}/agents.json: get: - operationId: ListAssigneeFieldAssignableGroupAgents tags: - - AssigneeFieldAssignableAgents + - AssigneeFieldAssignableAgents summary: List assignable agents from a group on the AssigneeField description: | List assignable agents from a group on the AssigneeField @@ -133,9 +135,10 @@ paths: #### Allowed For * Agents + operationId: ListAssigneeFieldAssignableGroupAgents parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/GroupId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/GroupId' responses: "200": description: Success response @@ -146,11 +149,10 @@ paths: examples: default: $ref: '#/components/examples/AssigneeFieldAssignableGroupAgentsResponseExample' - /api/v2/{target_type}/{target_id}/relationship_fields/{field_id}/{source_type}: + /v2/{targetType}/{targetId}/relationship_fields/{fieldId}/{sourceType}: get: - operationId: GetSourcesByTarget tags: - - Lookup Relationships + - Lookup Relationships summary: Get sources by target description: | Returns a list of source objects whose values are populated with the id of a related target object. For example, @@ -168,42 +170,51 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: GetSourcesByTarget parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: target_type - in: path - description: | - The type of object the relationship field is targeting. - The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - required: true - schema: - type: string - example: zen:custom_object:apartment - - name: target_id - in: path - description: | - The id of the object the relationship field is targeting - required: true - schema: - type: integer - example: 1234 - - name: field_id - in: path - description: | - The id of the lookup relationship field - required: true - schema: - type: integer - example: 1234 - - name: source_type - in: path - description: | - The type of object the relationship field belongs to (example. ticket field belongs to a ticket object). - The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - required: true - schema: - type: string - example: zen:custom_object:apartment + - $ref: '#/components/parameters/AcceptHeader' + - name: targetType + in: path + description: | + The type of object the relationship field is targeting. + The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" + required: true + style: simple + explode: false + schema: + type: string + example: zen:custom_object:apartment + - name: targetId + in: path + description: | + The id of the object the relationship field is targeting + required: true + style: simple + explode: false + schema: + type: integer + example: 1234 + - name: fieldId + in: path + description: | + The id of the lookup relationship field + required: true + style: simple + explode: false + schema: + type: integer + example: 1234 + - name: sourceType + in: path + description: | + The type of object the relationship field belongs to (example. ticket field belongs to a ticket object). + The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" + required: true + style: simple + explode: false + schema: + type: string + example: zen:custom_object:apartment responses: "200": description: Success response @@ -214,11 +225,10 @@ paths: examples: default: $ref: '#/components/examples/ReverseLookupUsersResponseExample' - /api/v2/account/settings: + /v2/account/settings: get: - operationId: ShowAccountSettings tags: - - Account Settings + - Account Settings summary: Show Settings description: | Shows the settings that are available for the account. @@ -226,6 +236,7 @@ paths: #### Allowed For * Agents + operationId: ShowAccountSettings responses: "200": description: Success response @@ -237,9 +248,8 @@ paths: default: $ref: '#/components/examples/AccountSettingsResponseExample' put: - operationId: UpdateAccountSettings tags: - - Account Settings + - Account Settings summary: Update Account Settings description: | Updates settings for the account. See [JSON Format](#json-format) above for the settings you can update. @@ -247,6 +257,7 @@ paths: #### Allowed For * Admins + operationId: UpdateAccountSettings responses: "200": description: Success response @@ -257,12 +268,12 @@ paths: examples: default: $ref: '#/components/examples/AccountSettingsResponseExample' - /api/v2/accounts: + /v2/accounts: post: - operationId: CreateTrialAccount tags: - - Reseller + - Reseller summary: Create Trial Account + operationId: CreateTrialAccount responses: "201": description: Created response @@ -273,46 +284,41 @@ paths: examples: default: $ref: '#/components/examples/TrialAccountResponseExample' - /api/v2/accounts/available: + /v2/accounts/available: get: - operationId: VerifySubdomainAvailability tags: - - Reseller + - Reseller summary: Verify Subdomain Availability description: | Zendesk Support credentials are not required to access this endpoint. You can use any Zendesk Support subdomain. Returns "true" if the subdomain is available. + operationId: VerifySubdomainAvailability parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: subdomain - in: query - description: | - Specify the name of the subdomain you want to verify. The name can't contain underscores, hyphens, or spaces. - required: true - schema: - type: string - example: z3ndesk + - $ref: '#/components/parameters/AcceptHeader' + - name: subdomain + in: query + description: | + Specify the name of the subdomain you want to verify. The name can't contain underscores, hyphens, or spaces + required: true + style: form + explode: true + schema: + type: string + example: z3ndesk responses: "200": description: Success response content: application/json: schema: - type: object - properties: - success: - type: boolean + $ref: '#/components/schemas/InlineResponse200' example: success: true - /api/v2/activities: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ActivitySince' + /v2/activities: get: - operationId: ListActivities tags: - - Activity Stream + - Activity Stream summary: List Activities description: | Lists ticket activities in the last 30 days affecting the agent making the request. @@ -333,6 +339,7 @@ paths: #### Allowed For * Agents + operationId: ListActivities responses: "200": description: Success response @@ -343,14 +350,13 @@ paths: examples: default: $ref: '#/components/examples/ActivitiesResponseExample' - /api/v2/activities/{activity_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ActivityId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ActivitySince' + /v2/activities/{activityId}: get: - operationId: ShowActivity tags: - - Activity Stream + - Activity Stream summary: Show Activity description: | Lists a specific activity. @@ -358,6 +364,7 @@ paths: #### Allowed For * Agents + operationId: ShowActivity responses: "200": description: Success response @@ -368,11 +375,13 @@ paths: examples: default: $ref: '#/components/examples/ActivityResponseExample' - /api/v2/activities/count: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ActivityId' + /v2/activities/count: get: - operationId: CountActivities tags: - - Activity Stream + - Activity Stream summary: Count Activities description: |- Returns an approximate count of ticket activities in the last 30 days affecting the agent making the request. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -384,6 +393,7 @@ paths: #### Allowed For * Agents + operationId: CountActivities responses: "200": description: Count of ticket activities @@ -394,11 +404,10 @@ paths: examples: default: $ref: '#/components/examples/ActivitiesCountResponseExample' - /api/v2/any_channel/channelback/report_error: + /v2/any_channel/channelback/report_error: post: - operationId: ReportChannelbackError tags: - - Channel Framework + - Channel Framework summary: Report Channelback Error to Zendesk description: | #### Allowed For @@ -421,6 +430,7 @@ paths: #### Response format The response does not include a response body + operationId: ReportChannelbackError responses: "200": description: Success response @@ -431,11 +441,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/any_channel/push: + /v2/any_channel/push: post: - operationId: PushContentToSupport tags: - - Channel Framework + - Channel Framework summary: Push Content to Support description: | Pushes Channel framework content to Zendesk. @@ -530,6 +539,7 @@ paths: | could_not_locate_parent_external_resource | The parent resource, as identified by parent_id in the [request](#request-parameters), could not be found. The unrecognized parent ID is returned in the description of the [status](#status-object) | processing_error | An internal exception occurred while processing the resource. See `description` in the [status object](#status-object) | halted | This resource was not processed because processing of previous resources failed + operationId: PushContentToSupport responses: "200": description: Success response @@ -540,11 +550,10 @@ paths: examples: default: $ref: '#/components/examples/ChannelFrameworkPushResultsResponseExample' - /api/v2/any_channel/validate_token: + /v2/any_channel/validate_token: post: - operationId: ValidateToken tags: - - Channel Framework + - Channel Framework summary: Validate Token description: | #### Allowed For @@ -563,6 +572,7 @@ paths: #### Response format The response body is empty. + operationId: ValidateToken responses: "200": description: Success response @@ -573,11 +583,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/attachments/{attachment_id}: + /v2/attachments/{attachmentId}: get: - operationId: ShowAttachment tags: - - Attachments + - Attachments summary: Show Attachment description: | Shows attachment details. You can get the value of the `attachment_id` parameter by listing the ticket's comments. @@ -588,9 +597,10 @@ paths: #### Allowed for * Agents + operationId: ShowAttachment parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AttachmentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AttachmentId' responses: "200": description: Success Response @@ -602,9 +612,8 @@ paths: default: $ref: '#/components/examples/AttachmentResponseExample' put: - operationId: UpdateAttachment tags: - - Attachments + - Attachments summary: Update Attachment for Malware description: | Toggles enabling or restricting agent access to attachments with detected malware. @@ -612,9 +621,10 @@ paths: #### Allowed For * Admins + operationId: UpdateAttachment parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AttachmentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AttachmentId' requestBody: content: application/json: @@ -633,11 +643,10 @@ paths: examples: default: $ref: '#/components/examples/AttachmentResponseExample' - /api/v2/audit_logs: + /v2/audit_logs: get: - operationId: ListAuditLogs tags: - - Audit Logs + - Audit Logs summary: List Audit Logs description: | #### Allowed For @@ -652,53 +661,92 @@ paths: See [Pagination](/api-reference/introduction/pagination/). Returns a maximum of 100 records per page. + operationId: ListAuditLogs parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: filter[source_type] - in: query - description: Filter audit logs by the source type. For example, user or rule - schema: - type: string - - name: filter[source_id] - in: query - description: Filter audit logs by the source id. Requires `filter[source_type]` to also be set - schema: - type: integer - - name: filter[actor_id] - in: query - description: Filter audit logs by the actor id - schema: - type: integer - - name: filter[ip_address] - in: query - description: Filter audit logs by the ip address - schema: - type: string - - name: filter[created_at] - in: query - description: Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time - schema: - type: string - - name: filter[action] - in: query - description: Filter audit logs by the action - schema: - type: string - - name: sort_by - in: query - description: Offset pagination only. Sort audit logs. Default is `sort_by=created_at` - schema: - type: string - - name: sort_order - in: query - description: Offset pagination only. Sort audit logs. Default is `sort_order=desc` - schema: - type: string - - name: sort - in: query - description: Cursor pagination only. Sort audit logs. Default is `sort=-created_at` - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: "filter[source_type]" + in: query + description: "Filter audit logs by the source type. For example, user or rule" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterSourceType + - name: "filter[source_id]" + in: query + description: "Filter audit logs by the source id. Requires `filter[source_type]`\ + \ to also be set" + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: filterSourceId + - name: "filter[actor_id]" + in: query + description: Filter audit logs by the actor id + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: filterActorId + - name: "filter[ip_address]" + in: query + description: Filter audit logs by the ip address + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterIpAddress + - name: "filter[created_at]" + in: query + description: "Filter audit logs by the time of creation. When used, you must\ + \ specify `filter[created_at]` twice in your request, first with the start\ + \ time and again with an end time" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterCreatedAt + - name: "filter[action]" + in: query + description: Filter audit logs by the action + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterAction + - name: sort_by + in: query + description: Offset pagination only. Sort audit logs. Default is `sort_by=created_at` + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: Offset pagination only. Sort audit logs. Default is `sort_order=desc` + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder + - name: sort + in: query + description: Cursor pagination only. Sort audit logs. Default is `sort=-created_at` + required: false + style: form + explode: true + schema: + type: string responses: "200": description: Success response @@ -709,19 +757,16 @@ paths: examples: default: $ref: '#/components/examples/AuditLogsResponseExample' - /api/v2/audit_logs/{audit_log_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AuditLogId' + /v2/audit_logs/{auditLogId}: get: - operationId: ShowAuditLog tags: - - Audit Logs + - Audit Logs summary: Show Audit Log description: | #### Allowed For * Admins on accounts that have audit-log access + operationId: ShowAuditLog responses: "200": description: Success response @@ -732,48 +777,78 @@ paths: examples: default: $ref: '#/components/examples/AuditLogResponseExample' - /api/v2/audit_logs/export: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AuditLogId' + /v2/audit_logs/export: post: - operationId: ExportAuditLogs tags: - - Audit Logs + - Audit Logs summary: Export Audit Logs description: | #### Allowed For * Admins on accounts that have audit log access + operationId: ExportAuditLogs parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: filter[source_type] - in: query - description: Filter audit logs by the source type. For example, user or rule - schema: - type: string - - name: filter[source_id] - in: query - description: Filter audit logs by the source id. Requires `filter[source_type]` to also be set. - schema: - type: integer - - name: filter[actor_id] - in: query - description: Filter audit logs by the actor id - schema: - type: integer - - name: filter[ip_address] - in: query - description: Filter audit logs by the ip address - schema: - type: string - - name: filter[created_at] - in: query - description: Filter audit logs by the time of creation. When used, you must specify `filter[created_at]` twice in your request, first with the start time and again with an end time - schema: - type: string - - name: filter[action] - in: query - description: Filter audit logs by the action - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: "filter[source_type]" + in: query + description: "Filter audit logs by the source type. For example, user or rule" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterSourceType + - name: "filter[source_id]" + in: query + description: "Filter audit logs by the source id. Requires `filter[source_type]`\ + \ to also be set" + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: filterSourceId + - name: "filter[actor_id]" + in: query + description: Filter audit logs by the actor id + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: filterActorId + - name: "filter[ip_address]" + in: query + description: Filter audit logs by the ip address + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterIpAddress + - name: "filter[created_at]" + in: query + description: "Filter audit logs by the time of creation. When used, you must\ + \ specify `filter[created_at]` twice in your request, first with the start\ + \ time and again with an end time" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterCreatedAt + - name: "filter[action]" + in: query + description: Filter audit logs by the action + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterAction responses: "202": description: Accepted description @@ -784,14 +859,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/autocomplete/tags: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TagNameFragment' + /v2/autocomplete/tags: get: - operationId: AutocompleteTags tags: - - Tags + - Tags summary: Search Tags description: | Returns an array of registered and recent tag names that start with the characters specified in the `name` query parameter. You must specify at least 2 characters. @@ -806,6 +877,7 @@ paths: #### Allowed For * Agents + operationId: AutocompleteTags responses: "200": description: Success response @@ -816,11 +888,13 @@ paths: examples: default: $ref: '#/components/examples/TagsAutocompleteResponseExample' - /api/v2/automations: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TagNameFragment' + /v2/automations: get: - operationId: ListAutomations tags: - - Automations + - Automations summary: List Automations description: | Lists all automations for the current account. @@ -860,6 +934,7 @@ paths: See [Pagination](/api-reference/introduction/pagination/). Returns a maximum of 100 records per page. + operationId: ListAutomations responses: "200": description: Success response @@ -871,9 +946,8 @@ paths: default: $ref: '#/components/examples/AutomationsResponseExample' post: - operationId: CreateAutomation tags: - - Automations + - Automations summary: Create Automation description: | Creates an automation. @@ -888,6 +962,7 @@ paths: #### Allowed For * Agents + operationId: CreateAutomation responses: "201": description: Created response @@ -898,19 +973,16 @@ paths: examples: default: $ref: '#/components/examples/AutomationCreateResponseExample' - /api/v2/automations/{automation_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AutomationId' + /v2/automations/{automationId}: get: - operationId: ShowAutomation tags: - - Automations + - Automations summary: Show Automation description: | #### Allowed For * Agents + operationId: ShowAutomation responses: "200": description: Success response @@ -922,9 +994,8 @@ paths: default: $ref: '#/components/examples/AutomationResponseExample' put: - operationId: UpdateAutomation tags: - - Automations + - Automations summary: Update Automation description: | Updates an automation. @@ -941,6 +1012,7 @@ paths: #### Allowed For * Agents + operationId: UpdateAutomation responses: "200": description: Success response @@ -952,9 +1024,8 @@ paths: default: $ref: '#/components/examples/AutomationResponseExample' delete: - operationId: DeleteAutomation tags: - - Automations + - Automations summary: Delete Automation description: | **Note**: You might be restricted from deleting some default automations. @@ -962,14 +1033,17 @@ paths: #### Allowed For * Agents + operationId: DeleteAutomation responses: "204": description: No Content response - /api/v2/automations/active: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AutomationId' + /v2/automations/active: get: - operationId: ListActiveAutomations tags: - - Automations + - Automations summary: List Active Automations description: | Lists all active automations. @@ -999,6 +1073,7 @@ paths: | usage_24h | The number of times each automation has been used in the past day | usage_7d | The number of times each automation has been used in the past week | usage_30d | The number of times each automation has been used in the past thirty days + operationId: ListActiveAutomations responses: "200": description: Success response @@ -1009,11 +1084,10 @@ paths: examples: default: $ref: '#/components/examples/AutomationsResponseExample' - /api/v2/automations/destroy_many: + /v2/automations/destroy_many: delete: - operationId: BulkDeleteAutomations tags: - - Automations + - Automations summary: Bulk Delete Automations description: | Deletes the automations corresponding to the provided comma-separated list of IDs. @@ -1039,30 +1113,26 @@ paths: "ids": "25,23,27,22" } ``` + operationId: BulkDeleteAutomations parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: The IDs of the automations to delete - schema: - type: array - items: - type: integer + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: The IDs of the automations to delete + required: false + style: form + explode: true + schema: + type: array + items: + type: integer responses: "204": description: No Content response - /api/v2/automations/search: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AutomationSearchQuery' - - $ref: '#/components/parameters/AutomationActive' - - $ref: '#/components/parameters/AutomationSortBy' - - $ref: '#/components/parameters/AutomationSortOrder' - - $ref: '#/components/parameters/AutomationInclude' + /v2/automations/search: get: - operationId: SearchAutomations tags: - - Automations + - Automations summary: Search Automations description: | #### Pagination @@ -1087,6 +1157,7 @@ paths: | usage_24h | The number of times each automation has been used in the past day | usage_7d | The number of times each automation has been used in the past week | usage_30d | The number of times each automation has been used in the past thirty days + operationId: SearchAutomations responses: "200": description: Success response @@ -1097,11 +1168,17 @@ paths: examples: default: $ref: '#/components/examples/AutomationsSearchResponseExample' - /api/v2/automations/update_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AutomationSearchQuery' + - $ref: '#/components/parameters/AutomationActive' + - $ref: '#/components/parameters/AutomationSortBy' + - $ref: '#/components/parameters/AutomationSortOrder' + - $ref: '#/components/parameters/AutomationInclude' + /v2/automations/update_many: put: - operationId: UpdateManyAutomations tags: - - Automations + - Automations summary: Update Many Automations description: | **Note**: You might be restricted from updating some default automations. If included in a bulk update, the unrestricted automations will be updated. @@ -1134,6 +1211,7 @@ paths: ] } ``` + operationId: UpdateManyAutomations responses: "200": description: Success response @@ -1144,15 +1222,15 @@ paths: examples: default: $ref: '#/components/examples/AutomationsUpdateManyResponseExample' - /api/v2/bookmarks: + /v2/bookmarks: get: - operationId: ListBookmarks tags: - - Bookmarks + - Bookmarks summary: List Bookmarks description: |- #### Allowed For - Agents + operationId: ListBookmarks responses: "200": description: Successful response @@ -1164,13 +1242,13 @@ paths: default: $ref: '#/components/examples/BookmarksResponse' post: - operationId: CreateBookmark tags: - - Bookmarks + - Bookmarks summary: Create Bookmark description: |- #### Allowed For - Agents + operationId: CreateBookmark requestBody: content: application/json: @@ -1198,28 +1276,27 @@ paths: examples: default: $ref: '#/components/examples/BookmarkResponse' - /api/v2/bookmarks/{bookmark_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/BookmarkId' + /v2/bookmarks/{bookmarkId}: delete: - operationId: DeleteBookmark tags: - - Bookmarks + - Bookmarks summary: Delete Bookmark description: |- #### Allowed For - Agents (own bookmarks only) If the bookmark already exists with a specified ticket id, the response status will be `http Status: 200 OK`. + operationId: DeleteBookmark responses: "204": description: No content - /api/v2/brands: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/BookmarkId' + /v2/brands: get: - operationId: ListBrands tags: - - Brands + - Brands summary: List Brands description: |- Returns a list of all brands for your account sorted by name. @@ -1234,6 +1311,7 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListBrands responses: "200": description: Successful response @@ -1245,13 +1323,13 @@ paths: default: $ref: '#/components/examples/BrandsResponseExample' post: - operationId: CreateBrand tags: - - Brands + - Brands summary: Create Brand description: |- #### Allowed for - Admins + operationId: CreateBrand requestBody: content: application/json: @@ -1270,11 +1348,10 @@ paths: examples: default: $ref: '#/components/examples/BrandResponseExample' - /api/v2/brands/{brand_id}: + /v2/brands/{brandId}: get: - operationId: ShowBrand tags: - - Brands + - Brands summary: Show a Brand description: |- Returns a brand for your account. @@ -1282,9 +1359,10 @@ paths: #### Allowed for * Admins, Agents + operationId: ShowBrand parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/BrandId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/BrandId' responses: "200": description: Successful response @@ -1296,9 +1374,8 @@ paths: default: $ref: '#/components/examples/BrandResponseExample' put: - operationId: UpdateBrand tags: - - Brands + - Brands summary: Update a Brand description: |- Returns an updated brand. @@ -1308,9 +1385,10 @@ paths: #### Updating a Brand's Image A brand image can be updated by uploading a local file using the update brand endpoint. See the **Using curl** sections below for more information. + operationId: UpdateBrand parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/BrandId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/BrandId' requestBody: content: application/json: @@ -1332,35 +1410,35 @@ paths: image/jpg: {} image/png: {} delete: - operationId: DeleteBrand tags: - - Brands + - Brands summary: Delete a Brand description: |- Deletes a brand. #### Allowed for - Admins + operationId: DeleteBrand parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/BrandId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/BrandId' responses: "204": description: No Content response - /api/v2/brands/{brand_id}/check_host_mapping: + /v2/brands/{brandId}/check_host_mapping: get: - operationId: CheckHostMappingValidityForExistingBrand tags: - - Brands + - Brands summary: Check Host Mapping Validity for an Existing Brand description: |- Returns a JSON object determining whether a host mapping is valid for the given brand. #### Allowed for - Admins + operationId: CheckHostMappingValidityForExistingBrand parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/BrandId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/BrandId' responses: "200": description: Successful response @@ -1375,11 +1453,10 @@ paths: $ref: '#/components/examples/HostMappingResponseInvalidCNAMEExample' wrongCNAMEExample: $ref: '#/components/examples/HostMappingResponseWrongCNAMEExample' - /api/v2/brands/check_host_mapping: + /v2/brands/check_host_mapping: get: - operationId: CheckHostMappingValidity tags: - - Brands + - Brands summary: Check Host Mapping Validity description: |- Returns a JSON object determining whether a host mapping is valid for a given subdomain. @@ -1387,10 +1464,11 @@ paths: #### Allowed for * Admins + operationId: CheckHostMappingValidity parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/HostMapping' - - $ref: '#/components/parameters/Subdomain' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/HostMapping' + - $ref: '#/components/parameters/Subdomain' responses: "200": description: Successful response @@ -1405,17 +1483,17 @@ paths: $ref: '#/components/examples/HostMappingResponseInvalidCNAMEExample' wrongCNAMEExample: $ref: '#/components/examples/HostMappingResponseWrongCNAMEExample' - /api/v2/channels/twitter/monitored_twitter_handles: + /v2/channels/twitter/monitored_twitter_handles: get: - operationId: ListMonitoredTwitterHandles tags: - - Twitter Channel + - Twitter Channel summary: List Monitored Twitter Handles description: | #### Allowed For * Admins * Agents + operationId: ListMonitoredTwitterHandles responses: "200": description: Success response @@ -1426,20 +1504,17 @@ paths: examples: default: $ref: '#/components/examples/TwitterChannelsResponseExample' - /api/v2/channels/twitter/monitored_twitter_handles/{monitored_twitter_handle_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MonitoredTwitterHandleId' + /v2/channels/twitter/monitored_twitter_handles/{monitoredTwitterHandleId}: get: - operationId: ShowMonitoredTwitterHandle tags: - - Twitter Channel + - Twitter Channel summary: Show Monitored Twitter Handle description: | #### Allowed For * Admins * Agents + operationId: ShowMonitoredTwitterHandle responses: "200": description: Success response @@ -1450,11 +1525,13 @@ paths: examples: default: $ref: '#/components/examples/TwitterChannelResponseExample' - /api/v2/channels/twitter/tickets: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MonitoredTwitterHandleId' + /v2/channels/twitter/tickets: post: - operationId: CreateTicketFromTweet tags: - - Twitter Channel + - Twitter Channel summary: Create Ticket from Tweet description: | Turns a tweet into a ticket. You must provide the tweet id as well as the id of a monitored twitter handle configured for your account. @@ -1464,6 +1541,7 @@ paths: #### Allowed For * Agents + operationId: CreateTicketFromTweet responses: "201": description: description @@ -1474,27 +1552,28 @@ paths: description: Empty response example: "" example: "" - /api/v2/channels/twitter/tickets/{comment_id}/statuses: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CommentId' + /v2/channels/twitter/tickets/{commentId}/statuses: get: - operationId: GettingTwicketStatus tags: - - Twitter Channel + - Twitter Channel summary: List Twicket statuses description: | #### Allowed For * Agents + operationId: GettingTwicketStatus parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Optional comment ids to retrieve tweet information for only particular comments - schema: - type: string - example: 1,3,5 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Optional comment ids to retrieve tweet information for only particular + comments + required: false + style: form + explode: true + schema: + type: string + example: "1,3,5" responses: "200": description: Success response @@ -1505,11 +1584,13 @@ paths: examples: default: $ref: '#/components/examples/TwitterChannelTwicketStatusResponseExample' - /api/v2/channels/voice/agents/{agent_id}/tickets/{ticket_id}/display: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CommentId' + /v2/channels/voice/agents/{agentId}/tickets/{ticketId}/display: post: - operationId: OpenTicketInAgentBrowser tags: - - Basics + - Basics summary: Open Ticket in Agent's Browser description: |- Allows you to instruct an agent's browser to open a ticket. @@ -1528,11 +1609,12 @@ paths: #### Allowed For * Agents + operationId: OpenTicketInAgentBrowser parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AgentId' - - $ref: '#/components/parameters/TicketId' - responses: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AgentId' + - $ref: '#/components/parameters/TicketId' + responses: "200": description: Successful response content: @@ -1551,11 +1633,10 @@ paths: description: Invalid attribute example: "" example: "" - /api/v2/channels/voice/agents/{agent_id}/users/{user_id}/display: + /v2/channels/voice/agents/{agentId}/users/{userId}/display: post: - operationId: OpenUsersProfileInAgentBrowser tags: - - Basics + - Basics summary: Open a User's Profile in an Agent's Browser description: |- Allows you to instruct an agent's browser to open a user's profile. @@ -1574,10 +1655,11 @@ paths: #### Allowed For * Agents + operationId: OpenUsersProfileInAgentBrowser parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AgentId' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AgentId' + - $ref: '#/components/parameters/UserId' responses: "200": description: Successful response @@ -1597,11 +1679,10 @@ paths: description: Invalid attribute example: "" example: "" - /api/v2/channels/voice/tickets: + /v2/channels/voice/tickets: post: - operationId: CreateTicketOrVoicemailTicket tags: - - Basics + - Basics summary: Create Ticket or Voicemail Ticket description: |- #### Allowed For @@ -1647,10 +1728,11 @@ paths: | answered_by_id | integer | The agent who answered the call | transcription_text | string | Transcription of the call (optional) | location | string | Location of the caller (optional) + operationId: CreateTicketOrVoicemailTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AgentId' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AgentId' + - $ref: '#/components/parameters/TicketId' requestBody: content: application/json: @@ -1678,14 +1760,10 @@ paths: description: Invalid attribute example: "" example: "" - /api/v2/chat_file_redactions/{ticket_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + /v2/chat_file_redactions/{ticketId}: put: - operationId: RedactChatCommentAttachment tags: - - Ticket Comments + - Ticket Comments summary: Redact Chat Comment Attachment description: | Permanently removes one or more chat attachments from a chat ticket. @@ -1736,6 +1814,7 @@ paths: ] } ``` + operationId: RedactChatCommentAttachment responses: "200": description: Success response @@ -1746,16 +1825,47 @@ paths: examples: default: $ref: '#/components/examples/TicketChatCommentAttachmentRedactionResponseExample' - /api/v2/chat_redactions/{ticket_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/chat_redactions/{ticketId}: put: - operationId: RedactChatComment tags: - - Ticket Comments + - Ticket Comments summary: Redact Chat Comment - description: "Permanently removes words or strings from a chat ticket's comment. \n\nWrap `` tags around the content in the chat comment you want redacted. Example: \n\n```json\n{\n \"text\": \"My ID number is 847564!\"\n}\n```\n\nThe characters contained in the tag will be replaced by the â–‡ symbol.\n\n**Note**: This does not work on active chats. For chat tickets that predate March 2020, consider using [Redact Ticket Comment In Agent Workspace](#redact-ticket-comment-in-agent-workspace).\n\n#### Allowed For\n\n- Agents\n\n[Agent Workspace](https://support.zendesk.com/hc/en-us/articles/360024218473) must enabled for the account. Deleting tickets must be enabled for agents.\n\n#### Request Body Properties\n\n| Name | Type | Required | Description |\n| ------------------------ | ------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| chat_id | string | true | The `chat_id` in the `ChatStartedEvent` event in the ticket audit. See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits) |\n| chat_index | integer | true | The `chat_index` in the `ChatMessage` event in the ticket audit. See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits) |\n| text | string | true | The `message` in the `ChatMessage` event in the ticket audit. See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits). Wrap `message` with `` tags |\n\nTo get the required body properties, make a request to the [Ticket Audit](/api-reference/ticketing/tickets/ticket_audits) endpoint. Example response:\n\n```http\nStatus 200 OK\n{\n \"audits\": [\n \"events\": [\n {\n \"id\": 1932802680168,\n \"type\": \"ChatStartedEvent\",\n \"value\": {\n \"visitor_id\": \"10502823-16EkM3T6VNq7KMd\",\n \"chat_id\": \"2109.10502823.Sjuj2YrBpXwei\",\n \"history\": [\n {\n \"chat_index\": 0,\n \"type\": \"ChatMessage\",\n \"message\": \"My ID number is 847564!\"\n }\n ]\n }\n }\n ]\n ]\n}\n```\n" + description: "Permanently removes words or strings from a chat ticket's comment.\ + \ \n\nWrap `` tags around the content in the chat comment you want\ + \ redacted. Example: \n\n```json\n{\n \"text\": \"My ID number is 847564!\"\ + \n}\n```\n\nThe characters contained in the tag will be replaced by the â–‡\ + \ symbol.\n\n**Note**: This does not work on active chats. For chat tickets\ + \ that predate March 2020, consider using [Redact Ticket Comment In Agent\ + \ Workspace](#redact-ticket-comment-in-agent-workspace).\n\n#### Allowed For\n\ + \n- Agents\n\n[Agent Workspace](https://support.zendesk.com/hc/en-us/articles/360024218473)\ + \ must enabled for the account. Deleting tickets must be enabled for agents.\n\ + \n#### Request Body Properties\n\n| Name | Type | Required\ + \ | Description \ + \ \ + \ |\n| ------------------------ | ------- | --------\ + \ | -----------------------------------------------------------------------------------------------------------------------------------------------------------------------\ + \ |\n| chat_id | string | true | The `chat_id` in the\ + \ `ChatStartedEvent` event in the ticket audit. See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits)\ + \ |\n| chat_index | integer\ + \ | true | The `chat_index` in the `ChatMessage` event in the ticket audit.\ + \ See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits) \ + \ |\n| text | string |\ + \ true | The `message` in the `ChatMessage` event in the ticket audit.\ + \ See [Ticket Audits](/api-reference/ticketing/tickets/ticket_audits). Wrap\ + \ `message` with `` tags |\n\nTo get the required body properties,\ + \ make a request to the [Ticket Audit](/api-reference/ticketing/tickets/ticket_audits)\ + \ endpoint. Example response:\n\n```http\nStatus 200 OK\n{\n \"audits\":\ + \ [\n \"events\": [\n {\n \"id\": 1932802680168,\n \"\ + type\": \"ChatStartedEvent\",\n \"value\": {\n \"visitor_id\"\ + : \"10502823-16EkM3T6VNq7KMd\",\n \"chat_id\": \"2109.10502823.Sjuj2YrBpXwei\"\ + ,\n \"history\": [\n {\n \"chat_index\":\ + \ 0,\n \"type\": \"ChatMessage\",\n \"message\"\ + : \"My ID number is 847564!\"\n }\n ]\n }\n \ + \ }\n ]\n ]\n}\n```\n" + operationId: RedactChatComment responses: "200": description: Success response @@ -1766,16 +1876,53 @@ paths: examples: default: $ref: '#/components/examples/TicketChatCommentRedactionResponseExample' - /api/v2/comment_redactions/{ticket_comment_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketCommentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/comment_redactions/{ticketCommentId}: put: - operationId: RedactTicketCommentInAgentWorkspace tags: - - Ticket Comments + - Ticket Comments summary: Redact Ticket Comment In Agent Workspace - description: "Redaction allows you to permanently remove words, strings, or attachments from a ticket comment.\n\nIn the `html_body` of the comment, wrap the content you want redacted in `` tags. Example:\n\n```json\n{\n \"html_body\": \"
My ID number is 847564!
\",\n \"ticket_id\":100\n}\n```\n\nThe characters in the redact tag will be replaced by the â–‡ symbol.\n\nTo redact HTML elements such inline images, anchor tags, and links, add the `redact` tag attribute to the element as well as the `` tag to inner text, if any. Example: \n\n`some link`\n\nThe `redact` attribute only redacts the tag. Any inner text will be left behind if not enclosed in a `` tag.\n\nRedaction is permanent and can not be undone. Data is permanently deleted from Zendesk servers with no way to recover it.\n\nThis endpoint provides all the same functionality that the [Redact String in Comment](/api-reference/ticketing/tickets/ticket_comments/#redact-string-in-comment) endpoint provides, plus:\n\n- Redaction of comments in closed tickets\n\n- Redaction of comments in archived tickets\n\n- Redaction of formatted text (bold, italics, hyperlinks)\n\n**Limitations**: When content is redacted from an email comment, the content is also redacted from the original email through a background job. It may take a while for the changes to be completed.\n\n**Note**: We recommend using this endpoint instead of the [Redact String in Comment](/api-reference/ticketing/tickets/ticket_comments/#redact-string-in-comment) endpoint, which will eventually be deprecated.\n\n#### Allowed For\n\n- Agents\n\n[Agent Workspace](https://support.zendesk.com/hc/en-us/articles/360024218473) must be enabled on the account. For professional accounts, deleting tickets must be enabled for agents. On Enterprise accounts, you can assign agents to a custom role with permissions to redact ticket content.\n\n#### Request Body Properties\n\n| Name | Type | Required | Description |\n| -------------------------| ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |\n| ticket_id | integer | true | The ID of the ticket |\n| html_body | string | false | The `html_body` of the comment containing `` tags or `redact` attributes |\n| external_attachment_urls | array | false | Array of attachment URLs belonging to the comment to be redacted. See [`content_url` property of Attachment](/api-reference/ticketing/tickets/ticket-attachments/) |\n" + description: "Redaction allows you to permanently remove words, strings, or\ + \ attachments from a ticket comment.\n\nIn the `html_body` of the comment,\ + \ wrap the content you want redacted in `` tags. Example:\n\n```json\n\ + {\n \"html_body\": \"
My ID\ + \ number is 847564!
\",\n \"ticket_id\":100\n}\n```\n\ + \nThe characters in the redact tag will be replaced by the â–‡ symbol.\n\nTo\ + \ redact HTML elements such inline images, anchor tags, and links, add the\ + \ `redact` tag attribute to the element as well as the `` tag to inner\ + \ text, if any. Example: \n\n`some\ + \ link`\n\nThe `redact` attribute only redacts the tag. Any inner\ + \ text will be left behind if not enclosed in a `` tag.\n\nRedaction\ + \ is permanent and can not be undone. Data is permanently deleted from Zendesk\ + \ servers with no way to recover it.\n\nThis endpoint provides all the same\ + \ functionality that the [Redact String in Comment](/api-reference/ticketing/tickets/ticket_comments/#redact-string-in-comment)\ + \ endpoint provides, plus:\n\n- Redaction of comments in closed tickets\n\n\ + - Redaction of comments in archived tickets\n\n- Redaction of formatted text\ + \ (bold, italics, hyperlinks)\n\n**Limitations**: When content is redacted\ + \ from an email comment, the content is also redacted from the original email\ + \ through a background job. It may take a while for the changes to be completed.\n\ + \n**Note**: We recommend using this endpoint instead of the [Redact String\ + \ in Comment](/api-reference/ticketing/tickets/ticket_comments/#redact-string-in-comment)\ + \ endpoint, which will eventually be deprecated.\n\n#### Allowed For\n\n-\ + \ Agents\n\n[Agent Workspace](https://support.zendesk.com/hc/en-us/articles/360024218473)\ + \ must be enabled on the account. For professional accounts, deleting tickets\ + \ must be enabled for agents. On Enterprise accounts, you can assign agents\ + \ to a custom role with permissions to redact ticket content.\n\n#### Request\ + \ Body Properties\n\n| Name | Type | Required | Description\ + \ \ + \ |\n| -------------------------|\ + \ ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------\ + \ |\n| ticket_id | integer | true | The ID of the ticket\ + \ \ + \ |\n| html_body \ + \ | string | false | The `html_body` of the comment containing\ + \ `` tags or `redact` attributes \ + \ |\n| external_attachment_urls | array | false | Array of attachment\ + \ URLs belonging to the comment to be redacted. See [`content_url` property\ + \ of Attachment](/api-reference/ticketing/tickets/ticket-attachments/) |\n" + operationId: RedactTicketCommentInAgentWorkspace responses: "200": description: Success response @@ -1786,16 +1933,19 @@ paths: examples: default: $ref: '#/components/examples/TicketCommentsRedactionInAgentWorkspaceResponseExample' - /api/v2/custom_objects: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketCommentId' + /v2/custom_objects: get: - operationId: ListCustomObjects tags: - - Custom Objects + - Custom Objects summary: List Custom Objects description: |- Lists all undeleted custom objects for the account #### Allowed For * Agents + operationId: ListCustomObjects responses: "200": description: Success response @@ -1807,14 +1957,14 @@ paths: default: $ref: '#/components/examples/CustomObjectsResponseExample' post: - operationId: CreateCustomObject tags: - - Custom Objects + - Custom Objects summary: Create Custom Object description: | Creates an object describing all the properties required to create a custom object record #### Allowed For * Admins + operationId: CreateCustomObject requestBody: content: application/json: @@ -1833,19 +1983,19 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectsCreateResponseExample' - /api/v2/custom_objects/{custom_object_key}: + /v2/custom_objects/{customObjectKey}: get: - operationId: ShowCustomObject tags: - - Custom Objects + - Custom Objects summary: Show Custom Object description: | Returns an object with the specified key #### Allowed For * Agents + operationId: ShowCustomObject parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' responses: "200": description: Custom Object @@ -1856,10 +2006,24 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectsCreateResponseExample' + delete: + tags: + - Custom Objects + summary: Delete Custom Object + description: |- + Permanently deletes the custom object with the specified key + #### Allowed For + * Admins + operationId: DeleteCustomObject + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + responses: + "204": + description: No content response patch: - operationId: UpdateCustomObject tags: - - Custom Objects + - Custom Objects summary: Update Custom Object description: |- Updates an individual custom object. The updating rules are as follows: @@ -1867,9 +2031,10 @@ paths: * The `key` property cannot be updated #### Allowed For * Admins + operationId: UpdateCustomObject parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' responses: "200": description: Success response @@ -1880,26 +2045,10 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectsCreateResponseExample' - delete: - operationId: DeleteCustomObject - tags: - - Custom Objects - summary: Delete Custom Object - description: |- - Permanently deletes the custom object with the specified key - #### Allowed For - * Admins - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - responses: - "204": - description: No content response - /api/v2/custom_objects/{custom_object_key}/fields: + /v2/custom_objects/{customObjectKey}/fields: get: - operationId: ListCustomObjectFields tags: - - Custom Object Fields + - Custom Object Fields summary: List Custom Object Fields description: |- Lists all undeleted custom fields for the specified object. @@ -1912,10 +2061,11 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListCustomObjectFields parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/IncludeStandardFields' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/IncludeStandardFields' responses: "200": description: Success response @@ -1927,9 +2077,8 @@ paths: default: $ref: '#/components/examples/CustomObjectFieldsResponseExample' post: - operationId: CreateCustomObjectField tags: - - Custom Object Fields + - Custom Object Fields summary: Create Custom Object Field description: | Creates any of the following custom field types: @@ -1949,9 +2098,10 @@ paths: #### Allowed For * Admins + operationId: CreateCustomObjectField parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' requestBody: content: application/json: @@ -1970,20 +2120,20 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectFieldCreateResponseExample' - /api/v2/custom_objects/{custom_object_key}/fields/{custom_object_field_key_or_id}: + /v2/custom_objects/{customObjectKey}/fields/{customObjectFieldKeyOrId}: get: - operationId: ShowCustomObjectField tags: - - Custom Object Fields + - Custom Object Fields summary: Show Custom Object Field description: | Returns a custom field for a specific object using a provided key or id of the field. #### Allowed For * Agents + operationId: ShowCustomObjectField parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' responses: "200": description: Custom Object Field @@ -1994,10 +2144,25 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectFieldCreateResponseExample' + delete: + tags: + - Custom Object Fields + summary: Delete Custom Object Field + description: |- + Deletes a field with the specified key. Note: You can't delete standard fields. + #### Allowed For + * Admins + operationId: DeleteCustomObjectField + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' + responses: + "204": + description: No content response patch: - operationId: UpdateCustomObjectField tags: - - Custom Object Fields + - Custom Object Fields summary: Update Custom Object Field description: |- Updates individual custom object fields. The updating rules are as follows: @@ -2006,10 +2171,11 @@ paths: * If updating a standard field, only the `title` and `description` properties can be updated. #### Allowed For * Admins + operationId: UpdateCustomObjectField parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' responses: "200": description: Success response @@ -2020,36 +2186,20 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectFieldCreateResponseExample' - delete: - operationId: DeleteCustomObjectField - tags: - - Custom Object Fields - summary: Delete Custom Object Field - description: |- - Deletes a field with the specified key. Note: You can't delete standard fields. - #### Allowed For - * Admins - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectFieldKeyOrId' - responses: - "204": - description: No content response - /api/v2/custom_objects/{custom_object_key}/fields/reorder: + /v2/custom_objects/{customObjectKey}/fields/reorder: put: - operationId: ReorderCustomObjectFields tags: - - Custom Object Fields + - Custom Object Fields summary: Reorder Custom Fields of an Object description: | Sets a preferred order of custom fields for a specific object by providing field ids in the desired order. #### Allowed For * Admins + operationId: ReorderCustomObjectFields parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' responses: "200": description: Reordered @@ -2060,11 +2210,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/custom_objects/{custom_object_key}/jobs: + /v2/custom_objects/{customObjectKey}/jobs: post: - operationId: CustomObjectRecordBulkJobs tags: - - Custom Object Records + - Custom Object Records summary: Custom Object Record Bulk Jobs description: | Queues a background job to perform bulk actions on up to 100 custom object records per single request. @@ -2087,9 +2236,10 @@ paths: #### Response ### This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information. + operationId: CustomObjectRecordBulkJobs parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' requestBody: content: application/json: @@ -2108,19 +2258,19 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsJobsResponseExample' - /api/v2/custom_objects/{custom_object_key}/limits/field_limit: + /v2/custom_objects/{customObjectKey}/limits/field_limit: get: - operationId: CustomObjectFieldsLimit tags: - - Custom Object Fields + - Custom Object Fields summary: Custom Object Fields Limit description: |- List the current count and the limit for a custom object's fields #### Allowed For * Agents + operationId: CustomObjectFieldsLimit parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' responses: "200": description: Success response @@ -2131,11 +2281,10 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectFieldsLimitResponseExample' - /api/v2/custom_objects/{custom_object_key}/records: + /v2/custom_objects/{customObjectKey}/records: get: - operationId: ListCustomObjectRecords tags: - - Custom Object Records + - Custom Object Records summary: List Custom Object Records description: |- Lists all undeleted custom object records for the specified object @@ -2145,57 +2294,85 @@ paths: * [Cursor pagination](/api-reference/introduction/pagination/#cursor-pagination) only. #### Allowed For * Agents + operationId: ListCustomObjectRecords parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - name: filter[ids] - in: query - description: Optional comma-separated list of ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive. - schema: - type: string - examples: - multipleIds: - summary: Example of multiple ids - value: id_1,id_2,id_3 - oneId: - summary: Example of a single id - value: id_1 - - name: filter[external_ids] - in: query - description: Optional comma-separated list of external ids to filter records by. If one or more ids are specified, only matching records are returned. The ids must be unique and are case sensitive. - schema: - type: string - examples: - multipleIds: - summary: Example of multiple ids - value: ex_id_1,ex_id_2,ex_id_3 - oneId: - summary: Example of a single id - value: ex_id_1 - - name: sort - in: query - description: | - One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending. - schema: - type: string - - name: page[before] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[after] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[size] - in: query - description: | - Specifies how many records should be returned in the response. You can specify up to 100 records per page. - schema: - type: integer + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - name: "filter[ids]" + in: query + description: "Optional comma-separated list of ids to filter records by. If\ + \ one or more ids are specified, only matching records are returned. The\ + \ ids must be unique and are case sensitive" + required: false + style: form + explode: true + schema: + type: string + examples: + multipleIds: + summary: Example of multiple ids + value: "id_1,id_2,id_3" + oneId: + summary: Example of a single id + value: id_1 + x-ballerina-name: filterIds + - name: "filter[external_ids]" + in: query + description: "Optional comma-separated list of external ids to filter records\ + \ by. If one or more ids are specified, only matching records are returned.\ + \ The ids must be unique and are case sensitive" + required: false + style: form + explode: true + schema: + type: string + examples: + multipleIds: + summary: Example of multiple ids + value: "ex_id_1,ex_id_2,ex_id_3" + oneId: + summary: Example of a single id + value: ex_id_1 + x-ballerina-name: filterExternalIds + - name: sort + in: query + description: | + One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending + required: false + style: form + explode: true + schema: + type: string + - name: "page[before]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageBefore + - name: "page[after]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageAfter + - name: "page[size]" + in: query + description: | + Specifies how many records should be returned in the response. You can specify up to 100 records per page + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: pageSize responses: "200": description: Success response @@ -2207,17 +2384,17 @@ paths: default: $ref: '#/components/examples/CustomObjectRecordsIndexResponseExample' post: - operationId: CreateCustomObjectRecord tags: - - Custom Object Records + - Custom Object Records summary: Create Custom Object Record description: | Creates a custom object record according to all the properties described by a custom object definition #### Allowed For * Agents + operationId: CreateCustomObjectRecord parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' requestBody: content: application/json: @@ -2236,19 +2413,35 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsCreateResponseExample' + delete: + tags: + - Custom Object Records + summary: Delete Custom Object Record by External Id + description: | + Deletes a record with the specified external id. + #### Allowed For + * Agents + operationId: DeleteCustomObjectRecordByExternalId + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectRecordExternalId' + responses: + "204": + description: No content response patch: - operationId: UpsertCustomObjectRecord tags: - - Custom Object Records + - Custom Object Records summary: Set Custom Object Record by External Id description: | If a record exists for the given external id, updates it. Only the specified attributes are updated. Otherwise, creates a new record with the provided external id and attributes. #### Allowed For * Agents + operationId: UpsertCustomObjectRecord parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectRecordExternalId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectRecordExternalId' requestBody: content: application/json: @@ -2267,36 +2460,20 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsUpsertResponseExample' - delete: - operationId: DeleteCustomObjectRecordByExternalId - tags: - - Custom Object Records - summary: Delete Custom Object Record by External Id - description: | - Deletes a record with the specified external id. - #### Allowed For - * Agents - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectRecordExternalId' - responses: - "204": - description: No content response - /api/v2/custom_objects/{custom_object_key}/records/{custom_object_record_id}: + /v2/custom_objects/{customObjectKey}/records/{customObjectRecordId}: get: - operationId: ShowCustomObjectRecord tags: - - Custom Object Records + - Custom Object Records summary: Show Custom Object Record description: | Returns a custom record for a specific object using a provided id. #### Allowed For * Agents + operationId: ShowCustomObjectRecord parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectRecordId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectRecordId' responses: "200": description: Custom Object Record @@ -2307,10 +2484,25 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsCreateResponseExample' + delete: + tags: + - Custom Object Records + summary: Delete Custom Object Record + description: |- + Deletes a record with the specified id + #### Allowed For + * Agents + operationId: DeleteCustomObjectRecord + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectRecordId' + responses: + "204": + description: No content response patch: - operationId: UpdateCustomObjectRecord tags: - - Custom Object Records + - Custom Object Records summary: Update Custom Object Record description: |- Updates an individual custom object record. The updating rules are as follows: @@ -2318,10 +2510,11 @@ paths: * The custom object fields should be nested inside a `custom_object_fields` object #### Allowed For * Agents + operationId: UpdateCustomObjectRecord parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectRecordId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/CustomObjectRecordId' responses: "200": description: Success response @@ -2332,27 +2525,10 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsCreateResponseExample' - delete: - operationId: DeleteCustomObjectRecord - tags: - - Custom Object Records - summary: Delete Custom Object Record - description: |- - Deletes a record with the specified id - #### Allowed For - * Agents - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - $ref: '#/components/parameters/CustomObjectRecordId' - responses: - "204": - description: No content response - /api/v2/custom_objects/{custom_object_key}/records/autocomplete: + /v2/custom_objects/{customObjectKey}/records/autocomplete: get: - operationId: AutocompleteCustomObjectRecordSearch tags: - - Custom Object Records + - Custom Object Records summary: Autocomplete Custom Object Record Search description: |- Retrieves an array of custom object records that have a field value that matches the value specified in the `name` parameter. @@ -2363,44 +2539,67 @@ paths: * Returns the first 10,000 records sorted by relevancy with page limits. #### Allowed For * Agents + operationId: AutocompleteCustomObjectRecordSearch parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - name: name - in: query - description: Part of a name of the record you are searching for - schema: - type: string - - name: page[before] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[after] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[size] - in: query - description: | - The number of records to return in the response. You can specify up to 100 records per page. - schema: - type: integer - - name: field_id - in: query - description: | - The id of the lookup field. If the field has a relationship filter, the filter is applied to the results. Must be used with `source` param. - schema: - type: string - - name: source - in: query - description: | - One of "zen:user", "zen:ticket", "zen:organization", or "zen:custom_object:CUSTOM_OBJECT_KEY". Represents the object `field_id` belongs to. Must be used with field_id param. - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - name: name + in: query + description: Part of a name of the record you are searching for + required: false + style: form + explode: true + schema: + type: string + - name: "page[before]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageBefore + - name: "page[after]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageAfter + - name: "page[size]" + in: query + description: | + The number of records to return in the response. You can specify up to 100 records per page + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: pageSize + - name: field_id + in: query + description: | + The id of the lookup field. If the field has a relationship filter, the filter is applied to the results. Must be used with `source` param + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: fieldId + - name: source + in: query + description: | + One of "zen:user", "zen:ticket", "zen:organization", or "zen:custom_object:CUSTOM_OBJECT_KEY". Represents the object `field_id` belongs to. Must be used with field_id param + required: false + style: form + explode: true + schema: + type: string responses: "200": description: Success response @@ -2411,51 +2610,36 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsAutocompleteResponseExample' - /api/v2/custom_objects/{custom_object_key}/records/count: + /v2/custom_objects/{customObjectKey}/records/count: get: - operationId: CountCustomObjectRecords tags: - - Custom Object Records + - Custom Object Records summary: Count Custom Object Records description: |- Returns a total count of records for a specific custom object as well as the time the count was refreshed. #### Allowed For * Agents + operationId: CountCustomObjectRecords parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' responses: "200": description: Success response content: application/json: schema: - type: object - properties: - count: - type: object - additionalProperties: - properties: - refreshed_at: - description: The time the last count was performed - format: date-time - readOnly: true - type: string - value: - description: Number of records at the time of the latest count operation - readOnly: true - type: integer + $ref: '#/components/schemas/InlineResponse2001' examples: default: value: count: - refreshed_at: "2022-09-02T22:44:35Z" + refreshed_at: 2022-09-02T22:44:35Z value: 7 - /api/v2/custom_objects/{custom_object_key}/records/search: + /v2/custom_objects/{customObjectKey}/records/search: get: - operationId: SearchCustomObjectRecords tags: - - Custom Object Records + - Custom Object Records summary: Search Custom Object Records description: |- Returns an array of custom object records that meet the search criteria @@ -2466,45 +2650,64 @@ paths: * Returns the records sorted by relevancy with page limits. Without a `sort` parameter, only the first 10,000 records are returned. With a `sort` parameter, all records are returned. #### Allowed For * Agents + operationId: SearchCustomObjectRecords parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomObjectKey' - - name: query - in: query - description: | - The query parameter is used to search text-based fields for records that match specific query terms. - The query can be multiple words or numbers. Every record that matches the beginning of any word or number in the query string is returned.

+ - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomObjectKey' + - name: query + in: query + description: | + The query parameter is used to search text-based fields for records that match specific query terms. + The query can be multiple words or numbers. Every record that matches the beginning of any word or number in the query string is returned.

- For example, you might want to search for records related to Tesla vehicles: `query=Tesla`. In this example the API would return every record for the given custom object where any of the text fields contain the word 'Tesla'.

+ For example, you might want to search for records related to Tesla vehicles: `query=Tesla`. In this example the API would return every record for the given custom object where any of the text fields contain the word 'Tesla'.

- If needed, you could include multiple words or numbers in your search. For example: `query=Tesla Honda 2020`. This would be URL encoded as `query=Tesla%20Honda%202020`. In this example, the API would return every record for the custom object for which any of the text fields contained 'Tesla', 'Honda', or '2020'. - schema: - type: string - example: jdoe - - name: sort - in: query - description: | - One of `name`, `created_at`, `updated_at`, `-name`, `-created_at`, or `-updated_at`. The `-` denotes the sort will be descending. Defaults to sorting by relevance. - schema: - type: string - - name: page[before] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[after] - in: query - description: | - A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. - schema: - type: string - - name: page[size] - in: query - description: | - Specifies how many records should be returned in the response. You can specify up to 100 records per page. - schema: - type: integer + If needed, you could include multiple words or numbers in your search. For example: `query=Tesla Honda 2020`. This would be URL encoded as `query=Tesla%20Honda%202020`. In this example, the API would return every record for the custom object for which any of the text fields contained 'Tesla', 'Honda', or '2020' + required: false + style: form + explode: true + schema: + type: string + example: jdoe + - name: sort + in: query + description: | + One of `name`, `created_at`, `updated_at`, `-name`, `-created_at`, or `-updated_at`. The `-` denotes the sort will be descending. Defaults to sorting by relevance + required: false + style: form + explode: true + schema: + type: string + - name: "page[before]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageBefore + - name: "page[after]" + in: query + description: | + A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: pageAfter + - name: "page[size]" + in: query + description: | + Specifies how many records should be returned in the response. You can specify up to 100 records per page + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: pageSize responses: "200": description: Success response @@ -2515,16 +2718,16 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsSearchResponseExample' - /api/v2/custom_objects/limits/object_limit: + /v2/custom_objects/limits/object_limit: get: - operationId: CustomObjectsLimit tags: - - Custom Objects + - Custom Objects summary: Custom Objects Limit description: |- List the current count and the limit for custom objects #### Allowed For * Admins + operationId: CustomObjectsLimit responses: "200": description: Success response @@ -2535,16 +2738,16 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectsLimitResponseExample' - /api/v2/custom_objects/limits/record_limit: + /v2/custom_objects/limits/record_limit: get: - operationId: CustomObjectRecordsLimit tags: - - Custom Object Records + - Custom Object Records summary: Custom Object Records Limit description: |- List the current count and the limit for custom object records #### Allowed For * Agents + operationId: CustomObjectRecordsLimit responses: "200": description: Success response @@ -2555,11 +2758,10 @@ paths: examples: default: $ref: '#/components/examples/CustomObjectRecordsLimitResponseExample' - /api/v2/custom_roles: + /v2/custom_roles: get: - operationId: ListCustomRoles tags: - - Custom Roles + - Custom Roles summary: List Custom Roles description: | #### Availability @@ -2569,6 +2771,7 @@ paths: #### Allowed For * Agents + operationId: ListCustomRoles responses: "200": description: Success response @@ -2580,9 +2783,8 @@ paths: default: $ref: '#/components/examples/CustomRolesResponseExample' post: - operationId: CreateCustomRole tags: - - Custom Roles + - Custom Roles summary: Create Custom Role description: | #### Availability @@ -2593,6 +2795,7 @@ paths: * Administrators * Agents with the `manage_roles` permission + operationId: CreateCustomRole responses: "200": description: Created response @@ -2603,14 +2806,10 @@ paths: examples: default: $ref: '#/components/examples/CustomRoleResponseExample' - /api/v2/custom_roles/{custom_role_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomRoleId' + /v2/custom_roles/{customRoleId}: get: - operationId: ShowCustomRoleById tags: - - Custom Roles + - Custom Roles summary: Show Custom Role description: | #### Availability @@ -2621,6 +2820,7 @@ paths: * Administrators * Agents with the `manage_roles` permission + operationId: ShowCustomRoleById responses: "200": description: Success response @@ -2632,9 +2832,8 @@ paths: default: $ref: '#/components/examples/CustomRoleResponseExample' put: - operationId: UpdateCustomRoleById tags: - - Custom Roles + - Custom Roles summary: Update Custom Role description: | #### Availability @@ -2645,6 +2844,7 @@ paths: * Administrators Agents with the `manage_roles` permission + operationId: UpdateCustomRoleById responses: "200": description: Success response @@ -2656,9 +2856,8 @@ paths: default: $ref: '#/components/examples/CustomRoleResponseExample' delete: - operationId: DeleteCustomRoleById tags: - - Custom Roles + - Custom Roles summary: Delete Custom Role description: | #### Availability @@ -2669,14 +2868,17 @@ paths: * Administrators * Agents with the `manage_roles` permission + operationId: DeleteCustomRoleById responses: "204": description: No Contetnt response - /api/v2/custom_status/default: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomRoleId' + /v2/custom_status/default: put: - operationId: BulkUpdateDefaultCustomStatus tags: - - Custom Ticket Statuses + - Custom Ticket Statuses summary: Bulk Update Default Custom Ticket Status description: | Updates the default values for many custom ticket statuses at once. @@ -2684,6 +2886,7 @@ paths: #### Allowed For * Admins + operationId: BulkUpdateDefaultCustomStatus requestBody: content: application/json: @@ -2702,11 +2905,10 @@ paths: examples: default: $ref: '#/components/examples/BulkUpdateDefaultCustomStatusResponseExample' - /api/v2/custom_statuses: + /v2/custom_statuses: get: - operationId: ListCustomStatuses tags: - - Custom Ticket Statuses + - Custom Ticket Statuses summary: List Custom Ticket Statuses description: | Lists all undeleted custom ticket statuses for the account. No pagination is provided. @@ -2714,23 +2916,39 @@ paths: #### Allowed For * End Users + operationId: ListCustomStatuses parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: status_categories - in: query - description: Filter the list of custom ticket statuses by a comma-separated list of status categories - schema: - type: string - - name: active - in: query - description: If true, show only active custom ticket statuses. If false, show only inactive custom ticket statuses. If the filter is not used, show all custom ticket statuses - schema: - type: boolean - - name: default - in: query - description: If true, show only default custom ticket statuses. If false, show only non-default custom ticket statuses. If the filter is not used, show all custom ticket statuses - schema: - type: boolean + - $ref: '#/components/parameters/AcceptHeader' + - name: status_categories + in: query + description: Filter the list of custom ticket statuses by a comma-separated + list of status categories + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: statusCategories + - name: active + in: query + description: "If true, show only active custom ticket statuses. If false,\ + \ show only inactive custom ticket statuses. If the filter is not used,\ + \ show all custom ticket statuses" + required: false + style: form + explode: true + schema: + type: boolean + - name: default + in: query + description: "If true, show only default custom ticket statuses. If false,\ + \ show only non-default custom ticket statuses. If the filter is not used,\ + \ show all custom ticket statuses" + required: false + style: form + explode: true + schema: + type: boolean responses: "200": description: List custom ticket statuses @@ -2742,9 +2960,8 @@ paths: default: $ref: '#/components/examples/CustomStatusesResponseExample' post: - operationId: CreateCustomStatus tags: - - Custom Ticket Statuses + - Custom Ticket Statuses summary: Create Custom Ticket Status description: | Takes a `custom_status` object that specifies the custom ticket status properties to create. @@ -2752,6 +2969,7 @@ paths: #### Allowed For * Admins + operationId: CreateCustomStatus requestBody: content: application/json: @@ -2770,11 +2988,10 @@ paths: examples: default: $ref: '#/components/examples/CustomStatusResponseExample' - /api/v2/custom_statuses/{custom_status_id}: + /v2/custom_statuses/{customStatusId}: get: - operationId: ShowCustomStatus tags: - - Custom Ticket Statuses + - Custom Ticket Statuses summary: Show Custom Ticket Status description: | Returns the custom ticket status object. @@ -2782,9 +2999,10 @@ paths: #### Allowed For * End Users + operationId: ShowCustomStatus parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomStatusId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomStatusId' responses: "200": description: Custom Status @@ -2796,9 +3014,8 @@ paths: default: $ref: '#/components/examples/CustomStatusResponseExample' put: - operationId: UpdateCustomStatus tags: - - Custom Ticket Statuses + - Custom Ticket Statuses summary: Update Custom Ticket Status description: | Takes a `custom_status` object that specifies the properties to update. @@ -2806,9 +3023,10 @@ paths: #### Allowed For * Admins + operationId: UpdateCustomStatus parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/CustomStatusId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/CustomStatusId' requestBody: content: application/json: @@ -2827,11 +3045,10 @@ paths: examples: default: $ref: '#/components/examples/CustomStatusResponseExample' - /api/v2/deleted_tickets: + /v2/deleted_tickets: get: - operationId: ListDeletedTickets tags: - - Tickets + - Tickets summary: List Deleted Tickets description: |- Returns a maximum of 100 deleted tickets per page. See [Pagination](/api-reference/introduction/pagination/). @@ -2864,10 +3081,11 @@ paths: When making requests beyond page 100, you can make 5 requests every 1 minute. The rate limiting mechanism behaves as described in [Monitoring your request activity](/api-reference/ticketing/account-configuration/usage_limits/#monitoring-your-request-activity) in the API introduction. + operationId: ListDeletedTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketSortBy' - - $ref: '#/components/parameters/TicketSortOrder' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketSortBy' + - $ref: '#/components/parameters/TicketSortOrder' responses: "200": description: Successful response @@ -2878,11 +3096,10 @@ paths: examples: default: $ref: '#/components/examples/ListDeletedTicketsResponseExample' - /api/v2/deleted_tickets/{ticket_id}: + /v2/deleted_tickets/{ticketId}: delete: - operationId: DeleteTicketPermanently tags: - - Tickets + - Tickets summary: Delete Ticket Permanently description: |- Permanently deletes a soft-deleted ticket. See [Soft delete](https://support.zendesk.com/hc/en-us/articles/4408834005530#topic_zrm_wbj_1db) @@ -2898,9 +3115,10 @@ paths: #### Allowed For * Agents + operationId: DeleteTicketPermanently parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -2911,19 +3129,19 @@ paths: examples: default: $ref: '#/components/examples/PermanentlyDeleteTicketJobStatusResponseExample' - /api/v2/deleted_tickets/{ticket_id}/restore: + /v2/deleted_tickets/{ticketId}/restore: put: - operationId: RestoreDeletedTicket tags: - - Tickets + - Tickets summary: Restore a Previously Deleted Ticket description: |- #### Allowed For * Agents + operationId: RestoreDeletedTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Empty response @@ -2934,11 +3152,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/deleted_tickets/destroy_many: + /v2/deleted_tickets/destroy_many: delete: - operationId: BulkPermanentlyDeleteTickets tags: - - Tickets + - Tickets summary: Delete Multiple Tickets Permanently description: |- Permanently deletes up to 100 soft-deleted tickets. See [Soft delete](https://support.zendesk.com/hc/en-us/articles/4408834005530#topic_zrm_wbj_1db) @@ -2955,9 +3172,10 @@ paths: #### Allowed For * Agents + operationId: BulkPermanentlyDeleteTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketIds' responses: "200": description: Successful response @@ -2968,19 +3186,19 @@ paths: examples: default: $ref: '#/components/examples/PermanentlyDeleteTicketJobStatusResponseExample' - /api/v2/deleted_tickets/restore_many: + /v2/deleted_tickets/restore_many: put: - operationId: BulkRestoreDeletedTickets tags: - - Tickets + - Tickets summary: Restore Previously Deleted Tickets in Bulk description: |- #### Allowed For * Agents + operationId: BulkRestoreDeletedTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketIds' responses: "200": description: Empty response @@ -2991,11 +3209,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/deleted_users: + /v2/deleted_users: get: - operationId: ListDeletedUsers tags: - - Users + - Users summary: List Deleted Users description: | Returns deleted users, including permanently deleted users. @@ -3016,6 +3233,7 @@ paths: #### Allowed For * Agents + operationId: ListDeletedUsers responses: "200": description: Success response @@ -3026,14 +3244,10 @@ paths: examples: default: $ref: '#/components/examples/DeletedUsersResponseExample' - /api/v2/deleted_users/{deleted_user_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DeletedUserId' + /v2/deleted_users/{deletedUserId}: get: - operationId: ShowDeletedUser tags: - - Users + - Users summary: Show Deleted User description: | Returns users that have been deleted but not permanently yet. See [Permanently Delete User](#permanently-delete-user). @@ -3041,6 +3255,7 @@ paths: #### Allowed For: * Agents + operationId: ShowDeletedUser responses: "200": description: Success response @@ -3052,9 +3267,8 @@ paths: default: $ref: '#/components/examples/DeletedUserResponseExample' delete: - operationId: PermanentlyDeleteUser tags: - - Users + - Users summary: Permanently Delete User description: | Before permanently deleting a user, you must delete the user first. See [Delete User](/api-reference/ticketing/users/users/#delete-user). @@ -3071,6 +3285,7 @@ paths: #### Allowed For * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage end users or team members + operationId: PermanentlyDeleteUser responses: "200": description: Success response @@ -3081,11 +3296,13 @@ paths: examples: default: $ref: '#/components/examples/DeletedUserResponseExample' - /api/v2/deleted_users/count: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DeletedUserId' + /v2/deleted_users/count: get: - operationId: CountDeletedUsers tags: - - Users + - Users summary: Count Deleted Users description: | Returns an approximate count of deleted users, including permanently deleted users. If the count exceeds 100,000, it is updated every 24 hours. @@ -3098,6 +3315,7 @@ paths: #### Allowed For * Agents + operationId: CountDeletedUsers responses: "200": description: Success response @@ -3108,11 +3326,10 @@ paths: examples: default: $ref: '#/components/examples/DeletedUsersCountResponseExample' - /api/v2/dynamic_content/items: + /v2/dynamic_content/items: get: - operationId: ListDynamicContents tags: - - Dynamic Content + - Dynamic Content summary: List Items description: | Returns a list of all dynamic content items for your account if accessed as an admin or agents who have permission to manage dynamic content. @@ -3127,6 +3344,7 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListDynamicContents responses: "200": description: Success response @@ -3138,9 +3356,8 @@ paths: default: $ref: '#/components/examples/DynamicContentsResponseExample' post: - operationId: CreateDynamicContent tags: - - Dynamic Content + - Dynamic Content summary: Create Item description: | Create a new content item, with one or more variants in the item's `variants` array. See [Specifying item variants](#specifying-item-variants). @@ -3150,6 +3367,7 @@ paths: #### Allowed For * Admins, Agents + operationId: CreateDynamicContent responses: "201": description: Created response @@ -3160,19 +3378,16 @@ paths: examples: default: $ref: '#/components/examples/DynamicContentResponseExample' - /api/v2/dynamic_content/items/{dynamic_content_item_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DynamicContentItemId' + /v2/dynamic_content/items/{dynamicContentItemId}: get: - operationId: ShowDynamicContentItem tags: - - Dynamic Content + - Dynamic Content summary: Show Item description: | #### Allowed For * Admins, Agents + operationId: ShowDynamicContentItem responses: "200": description: Success response @@ -3184,9 +3399,8 @@ paths: default: $ref: '#/components/examples/DynamicContentResponseExample' put: - operationId: UpdateDynamicContentItem tags: - - Dynamic Content + - Dynamic Content summary: Update Item description: | The only attribute you can change is the name. @@ -3196,6 +3410,7 @@ paths: #### Allowed For * Admins, Agents + operationId: UpdateDynamicContentItem responses: "200": description: Success response @@ -3207,25 +3422,24 @@ paths: default: $ref: '#/components/examples/DynamicContentUpdateResponseExample' delete: - operationId: DeleteDynamicContentItem tags: - - Dynamic Content + - Dynamic Content summary: Delete Item description: | #### Allowed For * Admins, Agents + operationId: DeleteDynamicContentItem responses: "204": description: No Content response - /api/v2/dynamic_content/items/{dynamic_content_item_id}/variants: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DynamicContentItemId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DynamicContentItemId' + /v2/dynamic_content/items/{dynamicContentItemId}/variants: get: - operationId: DynamicContentListVariants tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: List Variants description: | Returns all the variants of the specified dynamic content item. @@ -3240,6 +3454,7 @@ paths: * Cursor pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: DynamicContentListVariants responses: "200": description: Success response @@ -3251,9 +3466,8 @@ paths: default: $ref: '#/components/examples/DynamicContentVariantsResponseExample' post: - operationId: CreateDynamicContentVariant tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Create Variant description: | You can only create one variant for each locale id. If a locale variant already exists, the request is rejected. @@ -3261,6 +3475,7 @@ paths: #### Allowed For * Admins, Agents + operationId: CreateDynamicContentVariant responses: "201": description: Created response @@ -3271,20 +3486,19 @@ paths: examples: default: $ref: '#/components/examples/DynamicContentVariantResponseExample' - /api/v2/dynamic_content/items/{dynamic_content_item_id}/variants/{dynammic_content_variant_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DynamicContentItemId' - - $ref: '#/components/parameters/DynamicContentVariantId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DynamicContentItemId' + /v2/dynamic_content/items/{dynamicContentItemId}/variants/{dynammicContentVariantId}: get: - operationId: ShowDynamicContentVariant tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Show Variant description: | #### Allowed For * Admins, Agents + operationId: ShowDynamicContentVariant responses: "200": description: Success response @@ -3296,9 +3510,8 @@ paths: default: $ref: '#/components/examples/DynamicContentVariantResponseExample' put: - operationId: UpdateDynamicContentVariant tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Update Variant description: | Updates the specified variant. You don't need to include all the properties. If you just want to update content, for example, then include just that. @@ -3308,6 +3521,7 @@ paths: #### Allowed For * Admins, Agents + operationId: UpdateDynamicContentVariant responses: "200": description: Success response @@ -3319,30 +3533,31 @@ paths: default: $ref: '#/components/examples/DynamicContentVariantUpdateResponseExample' delete: - operationId: DeleteDynamicContentVariant tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Delete Variant description: | #### Allowed For * Admins, Agents + operationId: DeleteDynamicContentVariant responses: "204": description: No Content response - /api/v2/dynamic_content/items/{dynamic_content_item_id}/variants/create_many: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DynamicContentItemId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DynamicContentItemId' + - $ref: '#/components/parameters/DynamicContentVariantId' + /v2/dynamic_content/items/{dynamicContentItemId}/variants/create_many: post: - operationId: CreateManyDynamicContentVariants tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Create Many Variants description: | #### Allowed For * Admins, Agents + operationId: CreateManyDynamicContentVariants responses: "201": description: Created response @@ -3353,14 +3568,13 @@ paths: examples: default: $ref: '#/components/examples/DynamicContentVariantsCreateManyResponseExample' - /api/v2/dynamic_content/items/{dynamic_content_item_id}/variants/update_many: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/DynamicContentItemId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DynamicContentItemId' + /v2/dynamic_content/items/{dynamicContentItemId}/variants/update_many: put: - operationId: UpdateManyDynamicContentVariants tags: - - Dynamic Content Item Variants + - Dynamic Content Item Variants summary: Update Many Variants description: | Updates one or more variants. See [Update Variant](/api-reference/ticketing/ticket-management/dynamic_content_item_variants/#update-variant). @@ -3370,6 +3584,7 @@ paths: #### Allowed For * Admins, Agents + operationId: UpdateManyDynamicContentVariants responses: "200": description: Success response @@ -3380,11 +3595,13 @@ paths: examples: default: $ref: '#/components/examples/DynamicContentVariantsUpdateManyResponseExample' - /api/v2/dynamic_content/items/show_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/DynamicContentItemId' + /v2/dynamic_content/items/show_many: get: - operationId: ShowManyDynamicContents tags: - - Dynamic Content + - Dynamic Content summary: Show Many Items description: | #### Stability @@ -3394,14 +3611,18 @@ paths: #### Allowed For * Admins, Agents + operationId: ShowManyDynamicContents parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: identifiers - in: query - description: Identifiers for the dynamic contents - schema: - type: string - example: item1,item2 + - $ref: '#/components/parameters/AcceptHeader' + - name: identifiers + in: query + description: Identifiers for the dynamic contents + required: false + style: form + explode: true + schema: + type: string + example: "item1,item2" responses: "200": description: Success response @@ -3412,11 +3633,10 @@ paths: examples: default: $ref: '#/components/examples/DynamicContentsResponseExample' - /api/v2/group_memberships: + /v2/group_memberships: get: - operationId: ListGroupMemberships tags: - - Group Memberships + - Group Memberships summary: List Memberships description: | #### Pagination @@ -3431,6 +3651,7 @@ paths: #### Allowed For: * Agents + operationId: ListGroupMemberships responses: "200": description: Success response @@ -3442,9 +3663,8 @@ paths: default: $ref: '#/components/examples/GroupMembershipsResponseExample' post: - operationId: CreateGroupMembership tags: - - Group Memberships + - Group Memberships summary: Create Membership description: | Assigns an agent to a given group. @@ -3453,6 +3673,7 @@ paths: * Admins * Agents assigned to a custom role with permissions to manage group memberships (Enterprise only) + operationId: CreateGroupMembership responses: "201": description: Created response @@ -3463,15 +3684,10 @@ paths: examples: default: $ref: '#/components/examples/GroupMembershipResponseExample' - /api/v2/group_memberships/{group_membership_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/GroupMembershipId' - - $ref: '#/components/parameters/UserId' + /v2/group_memberships/{groupMembershipId}: get: - operationId: ShowGroupMembershipById tags: - - Group Memberships + - Group Memberships summary: Show Membership description: | The 'id' is the group membership id, not a group id. @@ -3479,6 +3695,7 @@ paths: #### Allowed For * Agents + operationId: ShowGroupMembershipById responses: "200": description: Success response @@ -3490,9 +3707,8 @@ paths: default: $ref: '#/components/examples/GroupMembershipResponseExample' delete: - operationId: DeleteGroupMembership tags: - - Group Memberships + - Group Memberships summary: Delete Membership description: | Immediately removes a user from a group and schedules a job to unassign all working tickets that are assigned to the given user and group combination. @@ -3501,14 +3717,18 @@ paths: * Admins * Agents assigned to a custom role with permissions to manage group memberships (Enterprise only) + operationId: DeleteGroupMembership responses: "204": description: No content response - /api/v2/group_memberships/assignable: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/GroupMembershipId' + - $ref: '#/components/parameters/UserId' + /v2/group_memberships/assignable: get: - operationId: ListAssignableGroupMemberships tags: - - Group Memberships + - Group Memberships summary: List Assignable Memberships description: | Returns a maximum of 100 group memberships per page. @@ -3525,6 +3745,7 @@ paths: #### Allowed For: * Agents + operationId: ListAssignableGroupMemberships responses: "200": description: Success response @@ -3535,11 +3756,10 @@ paths: examples: default: $ref: '#/components/examples/GroupMembershipsResponseExample' - /api/v2/group_memberships/create_many: + /v2/group_memberships/create_many: post: - operationId: GroupMembershipBulkCreate tags: - - Group Memberships + - Group Memberships summary: Bulk Create Memberships description: | Assigns up to 100 agents to given groups. @@ -3552,6 +3772,7 @@ paths: #### Response This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. + operationId: GroupMembershipBulkCreate responses: "200": description: Success response @@ -3562,11 +3783,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/group_memberships/destroy_many: + /v2/group_memberships/destroy_many: delete: - operationId: GroupMembershipBulkDelete tags: - - Group Memberships + - Group Memberships summary: Bulk Delete Memberships description: | Immediately removes users from groups and schedules a job to unassign all working tickets that are assigned to the given user and group combinations. @@ -3575,14 +3795,18 @@ paths: * Admins * Agents assigned to a custom role with permissions to manage group memberships (Enterprise only) + operationId: GroupMembershipBulkDelete parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Id of the group memberships to delete. Comma separated - schema: - type: string - example: 1,2,3 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Id of the group memberships to delete. Comma separated + required: false + style: form + explode: true + schema: + type: string + example: "1,2,3" responses: "200": description: Success response @@ -3593,16 +3817,16 @@ paths: examples: default: $ref: '#/components/examples/JobStatusBulkDeleteResponseExample' - /api/v2/group_slas/policies: + /v2/group_slas/policies: get: - operationId: ListGroupSLAPolicies tags: - - Group SLA Policies + - Group SLA Policies summary: List Group SLA Policies description: | #### Allowed For * Admins + operationId: ListGroupSLAPolicies responses: "200": description: Success response @@ -3614,14 +3838,14 @@ paths: default: $ref: '#/components/examples/GroupSLAPoliciesResponseExample' post: - operationId: CreateGroupSLAPolicy tags: - - Group SLA Policies + - Group SLA Policies summary: Create Group SLA Policy description: | #### Allowed For * Admins + operationId: CreateGroupSLAPolicy responses: "201": description: Created response @@ -3632,19 +3856,16 @@ paths: examples: default: $ref: '#/components/examples/GroupSLAPolicyCreateResponse' - /api/v2/group_slas/policies/{group_sla_policy_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/GroupSLAPolicyId' + /v2/group_slas/policies/{groupSlaPolicyId}: get: - operationId: ShowGroupSLAPolicy tags: - - Group SLA Policies + - Group SLA Policies summary: Show Group SLA Policy description: | #### Allowed For * Admins + operationId: ShowGroupSLAPolicy responses: "200": description: Success response @@ -3656,9 +3877,8 @@ paths: default: $ref: '#/components/examples/GroupSLAPolicyResponseExample' put: - operationId: UpdateGroupSLAPolicy tags: - - Group SLA Policies + - Group SLA Policies summary: Update Group SLA Policy description: | Updates the specified policy. @@ -3666,6 +3886,7 @@ paths: #### Allowed For * Admins + operationId: UpdateGroupSLAPolicy responses: "200": description: Success response @@ -3677,27 +3898,30 @@ paths: default: $ref: '#/components/examples/GroupSLAPolicyUpdateResponse' delete: - operationId: DeleteGroupSLAPolicy tags: - - Group SLA Policies + - Group SLA Policies summary: Delete Group SLA Policy description: | #### Allowed For * Admins + operationId: DeleteGroupSLAPolicy responses: "204": description: No Content response - /api/v2/group_slas/policies/definitions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/GroupSLAPolicyId' + /v2/group_slas/policies/definitions: get: - operationId: RetrieveGroupSLAPolicyFilterDefinitionItems tags: - - Group SLA Policies + - Group SLA Policies summary: Retrieve Supported Filter Definition Items description: | #### Allowed For * Admins + operationId: RetrieveGroupSLAPolicyFilterDefinitionItems responses: "200": description: Success response @@ -3708,25 +3932,29 @@ paths: examples: default: $ref: '#/components/examples/GroupSLAPolicyFilterDefinitionResponseExample' - /api/v2/group_slas/policies/reorder: + /v2/group_slas/policies/reorder: put: - operationId: ReorderGroupSLAPolicies tags: - - Group SLA Policies + - Group SLA Policies summary: Reorder Group SLA Policies description: | #### Allowed For * Admins + operationId: ReorderGroupSLAPolicies parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: group_sla_policy_ids - in: query - description: The ids of the Group SLA policies to reorder - schema: - type: array - items: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: group_sla_policy_ids + in: query + description: The ids of the Group SLA policies to reorder + required: false + style: form + explode: true + schema: + type: array + items: + type: string + x-ballerina-name: groupSlaPolicyIds responses: "200": description: Success response @@ -3737,11 +3965,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/groups: + /v2/groups: get: - operationId: ListGroups tags: - - Groups + - Groups summary: List Groups description: | #### Pagination @@ -3757,10 +3984,11 @@ paths: * Admins * Agents + operationId: ListGroups parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/ExcludeDeleted' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/ExcludeDeleted' responses: "200": description: Success response @@ -3772,15 +4000,15 @@ paths: default: $ref: '#/components/examples/GroupsResponseExample' post: - operationId: CreateGroup tags: - - Groups + - Groups summary: Create Group description: | #### Allowed For * Admins * Agents assigned to a custom role with permissions to manage groups (Enterprise only) + operationId: CreateGroup responses: "201": description: Created response @@ -3791,20 +4019,17 @@ paths: examples: default: $ref: '#/components/examples/GroupCreateResponseExample' - /api/v2/groups/{group_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/GroupId' + /v2/groups/{groupId}: get: - operationId: ShowGroupById tags: - - Groups + - Groups summary: Show Group description: | #### Allowed For * Admins * Agents + operationId: ShowGroupById responses: "200": description: Success response @@ -3816,14 +4041,14 @@ paths: default: $ref: '#/components/examples/GroupResponseExample' put: - operationId: UpdateGroup tags: - - Groups + - Groups summary: Update Group description: | #### Allowed For * Admins + operationId: UpdateGroup responses: "200": description: Success response @@ -3835,26 +4060,25 @@ paths: default: $ref: '#/components/examples/GroupUpdateResponseExample' delete: - operationId: DeleteGroup tags: - - Groups + - Groups summary: Delete Group description: | #### Allowed For * Admins * Agents assigned to a custom role with permissions to manage groups (Enterprise only) + operationId: DeleteGroup responses: "204": description: No content response - /api/v2/groups/{group_id}/memberships: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/GroupId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/GroupId' + /v2/groups/{groupId}/memberships: get: - operationId: ListGroupMembershipsByGroupId tags: - - Group Memberships + - Group Memberships summary: List Memberships description: | #### Pagination @@ -3869,6 +4093,7 @@ paths: #### Allowed For: * Agents + operationId: ListGroupMembershipsByGroupId responses: "200": description: Success response @@ -3879,11 +4104,13 @@ paths: examples: default: $ref: '#/components/examples/GroupMembershipsResponseExample' - /api/v2/groups/assignable: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/GroupId' + /v2/groups/assignable: get: - operationId: ListAssignableGroups tags: - - Groups + - Groups summary: List Assignable Groups description: | #### Pagination @@ -3899,6 +4126,7 @@ paths: * Admins * Agents + operationId: ListAssignableGroups responses: "200": description: Success response @@ -3909,14 +4137,10 @@ paths: examples: default: $ref: '#/components/examples/GroupsResponseExample' - /api/v2/groups/count: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + /v2/groups/count: get: - operationId: CountGroups tags: - - Groups + - Groups summary: Count Groups description: | Returns an approximate count of groups. If the count exceeds 100,000, it is updated every 24 hours. @@ -3929,6 +4153,7 @@ paths: * Admins * Agents + operationId: CountGroups responses: "200": description: Success response @@ -3939,19 +4164,22 @@ paths: examples: default: $ref: '#/components/examples/GroupsCountResponseExample' - /api/v2/imports/tickets: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/imports/tickets: post: - operationId: TicketImport tags: - - Ticket Import + - Ticket Import summary: Ticket Import description: |- #### Allowed For * Admins + operationId: TicketImport parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ArchiveImmediately' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ArchiveImmediately' requestBody: content: application/json: @@ -3970,11 +4198,10 @@ paths: examples: default: $ref: '#/components/examples/TicketResponseExample' - /api/v2/imports/tickets/create_many: + /v2/imports/tickets/create_many: post: - operationId: TicketBulkImport tags: - - Ticket Import + - Ticket Import summary: Ticket Bulk Import description: |- Accepts an array of up to 100 ticket objects. @@ -3982,9 +4209,10 @@ paths: #### Allowed For * Admins + operationId: TicketBulkImport parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ArchiveImmediately' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ArchiveImmediately' requestBody: content: application/json: @@ -4003,15 +4231,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/incremental/{incremental_resource}/sample: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' - - $ref: '#/components/parameters/IncrementalResource' + /v2/incremental/{incrementalResource}/sample: get: - operationId: IncrementalSampleExport tags: - - Incremental Export + - Incremental Export summary: Incremental Sample Export description: | Use this endpoint to test the incremental export format. It's more strict in terms of rate limiting, @@ -4019,6 +4242,7 @@ paths: results per request. Otherwise, it's identical to the above APIs. Use the `incremental_resource` parameter to specify the resource. Possible values are "tickets", "ticket_events", "users", or "organizations". + operationId: IncrementalSampleExport responses: "200": description: Success response @@ -4029,14 +4253,14 @@ paths: examples: default: $ref: '#/components/examples/TimeBasedExportIncrementalTicketsResponseExample' - /api/v2/incremental/organizations: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + - $ref: '#/components/parameters/IncrementalResource' + /v2/incremental/organizations: get: - operationId: IncrementalOrganizationExport tags: - - Incremental Export + - Incremental Export summary: Incremental Organization Export description: | #### Allowed For @@ -4046,6 +4270,7 @@ paths: #### Sideloading See [Organizations sideloads](/documentation/ticketing/using-the-zendesk-api/side_loading/#supported-endpoints). + operationId: IncrementalOrganizationExport responses: "200": description: Success response @@ -4056,11 +4281,13 @@ paths: examples: default: $ref: '#/components/examples/ExportIncrementalOrganizationsResponseExample' - /api/v2/incremental/routing/attribute_values: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + /v2/incremental/routing/attribute_values: get: - operationId: IncrementalSkilBasedRoutingAttributeValuesExport tags: - - Incremental Skill Based Routing + - Incremental Skill Based Routing summary: Incremental Attributes Values Export description: | Returns a stream of changes that occurred on routing attribute values. @@ -4076,6 +4303,7 @@ paths: | Name | Type | Comment | ------ | ------ | ------- | cursor | string | The `cursor` parameter is a non-human-readable argument you can use to move forward or backward in time. The cursor is a read-only URL parameter that's only available in API responses. See [Pagination](#pagination). + operationId: IncrementalSkilBasedRoutingAttributeValuesExport responses: "200": description: Success response @@ -4086,11 +4314,10 @@ paths: examples: default: $ref: '#/components/examples/IncrementalSkillBasedRoutingAttributeValuesExample' - /api/v2/incremental/routing/attributes: + /v2/incremental/routing/attributes: get: - operationId: IncrementalSkilBasedRoutingAttributesExport tags: - - Incremental Skill Based Routing + - Incremental Skill Based Routing summary: Incremental Attributes Export description: | Returns a stream of changes that occurred on routing attributes. @@ -4107,6 +4334,7 @@ paths: | Name | Type | Comment | ------ | ------ | ------- | cursor | string | The `cursor` parameter is a non-human-readable argument you can use to move forward or backward in time. The cursor is a read-only URL parameter that's only available in API responses. See [Pagination](#pagination). + operationId: IncrementalSkilBasedRoutingAttributesExport responses: "200": description: Success response @@ -4117,11 +4345,10 @@ paths: examples: default: $ref: '#/components/examples/IncrementalSkillBasedRoutingAttributesExample' - /api/v2/incremental/routing/instance_values: + /v2/incremental/routing/instance_values: get: - operationId: IncrementalSkilBasedRoutingInstanceValuesExport tags: - - Incremental Skill Based Routing + - Incremental Skill Based Routing summary: Incremental Instance Values Export description: | Returns a stream of changes that occurred on routing instance values. Changes are grouped by `attribute_value_id`, @@ -4138,6 +4365,7 @@ paths: | Name | Type | Comment | ------ | ------ | ------- | cursor | string | The `cursor` parameter is a non-human-readable argument you can use to move forward or backward in time. The cursor is a read-only URL parameter that's only available in API responses. See [Pagination](#pagination). + operationId: IncrementalSkilBasedRoutingInstanceValuesExport responses: "200": description: Success response @@ -4148,14 +4376,10 @@ paths: examples: default: $ref: '#/components/examples/IncrementalSkillBasedRoutingInstanceValuesExample' - /api/v2/incremental/ticket_events: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' + /v2/incremental/ticket_events: get: - operationId: IncrementalTicketEvents tags: - - Incremental Export + - Incremental Export summary: Incremental Ticket Event Export description: | Returns a stream of changes that occurred on tickets. Each event is tied @@ -4202,6 +4426,7 @@ paths: ], ... ``` + operationId: IncrementalTicketEvents responses: "200": description: Success response @@ -4212,11 +4437,13 @@ paths: examples: default: $ref: '#/components/examples/ExportIncrementalTicketEventsResponseExample' - /api/v2/incremental/ticket_metric_events: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + /v2/incremental/ticket_metric_events: get: - operationId: ListTicketMetricEvents tags: - - Ticket Metric Events + - Ticket Metric Events summary: List Ticket Metric Events description: |- Returns ticket metric events that occurred on or after the start time. @@ -4235,15 +4462,20 @@ paths: #### Allowed For * Admins + operationId: ListTicketMetricEvents parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: start_time - in: query - description: 'The Unix UTC epoch time of the oldest event you''re interested in. Example: 1332034771.' - required: true - schema: - type: integer - example: 1332034771 + - $ref: '#/components/parameters/AcceptHeader' + - name: start_time + in: query + description: "The Unix UTC epoch time of the oldest event you're interested\ + \ in. Example: 1332034771" + required: true + style: form + explode: true + schema: + type: integer + example: 1332034771 + x-ballerina-name: startTime responses: "200": description: Successful response @@ -4254,15 +4486,11 @@ paths: examples: default: $ref: '#/components/examples/TicketMetricEventsResponseExample' - /api/v2/incremental/tickets: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' + /v2/incremental/tickets: get: - operationId: IncrementalTicketExportTime tags: - - Incremental Export - summary: Incremental Ticket Export, Time Based + - Incremental Export + summary: "Incremental Ticket Export, Time Based" description: | Returns the tickets that changed since the start time. For more information, see [Exporting tickets](/documentation/ticketing/managing-tickets/using-the-incremental-export-api#exporting-tickets) in [Using the Incremental Exports API](/documentation/ticketing/managing-tickets/using-the-incremental-export-api). @@ -4290,6 +4518,7 @@ paths: See [Tickets sideloads](/documentation/ticketing/using-the-zendesk-api/side_loading/#supported-endpoints). For performance reasons, `last_audits` sideloads aren't supported. + operationId: IncrementalTicketExportTime responses: "200": description: Success response @@ -4300,16 +4529,14 @@ paths: examples: default: $ref: '#/components/examples/TimeBasedExportIncrementalTicketsResponseExample' - /api/v2/incremental/tickets/cursor: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' - - $ref: '#/components/parameters/IncrementalCursor' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + /v2/incremental/tickets/cursor: get: - operationId: IncrementalTicketExportCursor tags: - - Incremental Export - summary: Incremental Ticket Export, Cursor Based + - Incremental Export + summary: "Incremental Ticket Export, Cursor Based" description: | Returns the tickets that changed since the start time. For more information, see [Exporting tickets](/documentation/ticketing/managing-tickets/using-the-incremental-export-api#exporting-tickets) in [Using the Incremental Exports API](/documentation/ticketing/managing-tickets/using-the-incremental-export-api). @@ -4328,6 +4555,7 @@ paths: See [Tickets sideloads](/documentation/ticketing/using-the-zendesk-api/side_loading/#supported-endpoints). For performance reasons, `last_audits` sideloads aren't supported. + operationId: IncrementalTicketExportCursor responses: "200": description: Success response @@ -4338,16 +4566,15 @@ paths: examples: default: $ref: '#/components/examples/CursorBasedExportIncrementalTicketsResponseExample' - /api/v2/incremental/users: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' - - $ref: '#/components/parameters/IncrementalPage' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + - $ref: '#/components/parameters/IncrementalCursor' + /v2/incremental/users: get: - operationId: IncrementalUserExportTime tags: - - Incremental Export - summary: Incremental User Export, Time Based + - Incremental Export + summary: "Incremental User Export, Time Based" description: | #### Allowed For @@ -4356,6 +4583,7 @@ paths: #### Sideloading See [Users sideloads](/documentation/ticketing/using-the-zendesk-api/side_loading/#supported-endpoints). + operationId: IncrementalUserExportTime responses: "200": description: Success response @@ -4366,17 +4594,15 @@ paths: examples: default: $ref: '#/components/examples/TimeBasedExportIncrementalUsersResponseExample' - /api/v2/incremental/users/cursor: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/IncrementalUnixTime' - - $ref: '#/components/parameters/IncrementalCursor' - - $ref: '#/components/parameters/IncrementalPage' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + - $ref: '#/components/parameters/IncrementalPage' + /v2/incremental/users/cursor: get: - operationId: IncrementalUserExportCursor tags: - - Incremental Export - summary: Incremental User Export, Cursor Based + - Incremental Export + summary: "Incremental User Export, Cursor Based" description: | #### Allowed For @@ -4385,6 +4611,7 @@ paths: #### Sideloading See [Users sideloads](/documentation/ticketing/using-the-zendesk-api/side_loading/#supported-endpoints). + operationId: IncrementalUserExportCursor responses: "200": description: Success response @@ -4395,11 +4622,15 @@ paths: examples: default: $ref: '#/components/examples/CursorBasedExportIncrementalUsersResponseExample' - /api/v2/job_statuses: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/IncrementalUnixTime' + - $ref: '#/components/parameters/IncrementalCursor' + - $ref: '#/components/parameters/IncrementalPage' + /v2/job_statuses: get: - operationId: ListJobStatuses tags: - - Job Statuses + - Job Statuses summary: List Job Statuses description: | Shows the statuses for background jobs. Statuses are sorted first by completion date and then by creation date in descending order. @@ -4413,6 +4644,7 @@ paths: * Cursor pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListJobStatuses responses: "200": description: Success Response @@ -4423,14 +4655,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusesResponseExample' - /api/v2/job_statuses/{job_status_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/JobStatusId' + /v2/job_statuses/{jobStatusId}: get: - operationId: ShowJobStatus tags: - - Job Statuses + - Job Statuses summary: Show Job Status description: | Shows the status of a background job. @@ -4438,6 +4666,7 @@ paths: #### Allowed For: * Agents + operationId: ShowJobStatus responses: "200": description: Success Response @@ -4448,11 +4677,13 @@ paths: examples: default: $ref: '#/components/examples/ShowJobStatusResponseExample' - /api/v2/job_statuses/show_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/JobStatusId' + /v2/job_statuses/show_many: get: - operationId: ShowManyJobStatuses tags: - - Job Statuses + - Job Statuses summary: Show Many Job Statuses description: | Accepts a comma-separated list of job status ids. @@ -4460,15 +4691,18 @@ paths: #### Allowed For: * Agents + operationId: ShowManyJobStatuses parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Comma-separated list of job status ids. - required: true - schema: - type: string - example: 8b726e606741012ffc2d782bcb7848fe,e7665094164c498781ebe4c8db6d2af5 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Comma-separated list of job status ids + required: true + style: form + explode: true + schema: + type: string + example: "8b726e606741012ffc2d782bcb7848fe,e7665094164c498781ebe4c8db6d2af5" responses: "200": description: Success Response @@ -4479,11 +4713,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusesResponseExample' - /api/v2/locales: + /v2/locales: get: - operationId: ListLocales tags: - - Locales + - Locales summary: List Locales description: | Lists the translation locales available for the account. @@ -4493,6 +4726,7 @@ paths: #### Allowed For * Anyone + operationId: ListLocales responses: "200": description: Success response @@ -4503,19 +4737,16 @@ paths: examples: default: $ref: '#/components/examples/LocalesResponseExample' - /api/v2/locales/{locale_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/LocaleId' + /v2/locales/{localeId}: get: - operationId: ShowLocaleById tags: - - Locales + - Locales summary: Show Locale description: | #### Allowed For * Anyone + operationId: ShowLocaleById responses: "200": description: Success Response @@ -4526,11 +4757,13 @@ paths: examples: default: $ref: '#/components/examples/LocaleResponseExample' - /api/v2/locales/agent: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/LocaleId' + /v2/locales/agent: get: - operationId: ListLocalesForAgent tags: - - Locales + - Locales summary: List Locales for Agent description: | Lists the translation locales that have been localized for agents on a specific account. @@ -4538,6 +4771,7 @@ paths: #### Allowed For * Anyone + operationId: ListLocalesForAgent responses: "200": description: Success response @@ -4548,11 +4782,10 @@ paths: examples: default: $ref: '#/components/examples/LocalesResponseExample' - /api/v2/locales/current: + /v2/locales/current: get: - operationId: ShowCurrentLocale tags: - - Locales + - Locales summary: Show Current Locale description: | This works like [Show Locale](#show-locale), but instead of taking a locale id as an argument, it renders the locale of the user performing the request. @@ -4560,6 +4793,7 @@ paths: #### Allowed For * Anyone + operationId: ShowCurrentLocale responses: "200": description: Success response @@ -4570,16 +4804,16 @@ paths: examples: default: $ref: '#/components/examples/LocaleResponseExample' - /api/v2/locales/detect_best_locale: + /v2/locales/detect_best_locale: get: - operationId: DetectBestLocale tags: - - Locales + - Locales summary: Detect Best Language for User description: | #### Allowed For * Anyone + operationId: DetectBestLocale responses: "200": description: Success response @@ -4590,11 +4824,10 @@ paths: examples: default: $ref: '#/components/examples/LocaleDetectBestLanguageResponseExample' - /api/v2/locales/public: + /v2/locales/public: get: - operationId: ListAvailablePublicLocales tags: - - Locales + - Locales summary: List Available Public Locales description: | Lists the translation locales that are available to all accounts. @@ -4602,6 +4835,7 @@ paths: #### Allowed For * Anyone + operationId: ListAvailablePublicLocales responses: "200": description: Success response @@ -4612,11 +4846,10 @@ paths: examples: default: $ref: '#/components/examples/LocalesResponseExample' - /api/v2/macros: + /v2/macros: get: - operationId: ListMacros tags: - - Macros + - Macros summary: List Macros description: | Lists all shared and personal macros available to the current user. For admins, the API returns all macros for the account, including the personal macros of agents and other admins. @@ -4632,16 +4865,17 @@ paths: #### Allowed For * Agents + operationId: ListMacros parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroInclude' - - $ref: '#/components/parameters/MacroAccess' - - $ref: '#/components/parameters/MacroActive' - - $ref: '#/components/parameters/MacroCategory' - - $ref: '#/components/parameters/MacroGroupId' - - $ref: '#/components/parameters/MacroOnlyViewable' - - $ref: '#/components/parameters/MacroSortBy' - - $ref: '#/components/parameters/MacroSortOrder' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroInclude' + - $ref: '#/components/parameters/MacroAccess' + - $ref: '#/components/parameters/MacroActive' + - $ref: '#/components/parameters/MacroCategory' + - $ref: '#/components/parameters/MacroGroupId' + - $ref: '#/components/parameters/MacroOnlyViewable' + - $ref: '#/components/parameters/MacroSortBy' + - $ref: '#/components/parameters/MacroSortOrder' responses: "200": description: Success Response @@ -4653,28 +4887,25 @@ paths: default: $ref: '#/components/examples/MacrosResponseExample' post: - operationId: CreateMacro tags: - - Macros + - Macros summary: Create Macro description: | #### Allowed For * Agents + operationId: CreateMacro requestBody: content: application/json: schema: - type: object - properties: - macro: - $ref: '#/components/schemas/MacroInput' + $ref: '#/components/schemas/V2MacrosBody' examples: default: value: macro: actions: - - field: status - value: solved + - field: status + value: solved title: Roger Wilco responses: "200": @@ -4682,25 +4913,19 @@ paths: content: application/json: schema: - type: object - properties: - macro: - $ref: '#/components/schemas/MacroObject' + $ref: '#/components/schemas/InlineResponse2002' examples: default: $ref: '#/components/examples/CreateMacroResponseExample' - /api/v2/macros/{macro_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroId' + /v2/macros/{macroId}: get: - operationId: ShowMacro tags: - - Macros + - Macros summary: Show Macro description: | #### Allowed For * Agents + operationId: ShowMacro responses: "200": description: Success Response @@ -4712,28 +4937,25 @@ paths: default: $ref: '#/components/examples/MacroResponseExample' put: - operationId: UpdateMacro tags: - - Macros + - Macros summary: Update Macro description: | #### Allowed For * Agents + operationId: UpdateMacro requestBody: content: application/json: schema: - type: object - properties: - macro: - $ref: '#/components/schemas/MacroInput' + $ref: '#/components/schemas/V2MacrosBody' examples: default: value: macro: actions: - - field: status - value: solved + - field: status + value: solved title: Sets the ticket status to `solved` responses: "200": @@ -4741,32 +4963,28 @@ paths: content: application/json: schema: - type: object - properties: - macro: - $ref: '#/components/schemas/MacroObject' + $ref: '#/components/schemas/InlineResponse2002' examples: default: $ref: '#/components/examples/UpdateMacroResponseExample' delete: - operationId: DeleteMacro tags: - - Macros + - Macros summary: Delete Macro description: | #### Allowed For * Agents, with restrictions applying on certain actions + operationId: DeleteMacro responses: "204": description: No Content - /api/v2/macros/{macro_id}/apply: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroId' + /v2/macros/{macroId}/apply: get: - operationId: ShowChangesToTicket tags: - - Macros + - Macros summary: Show Changes to Ticket description: | Returns the changes the macro would make to a ticket. It doesn't actually @@ -4779,6 +4997,7 @@ paths: #### Allowed For * Agents + operationId: ShowChangesToTicket responses: "200": description: Success Response @@ -4789,20 +5008,20 @@ paths: examples: default: $ref: '#/components/examples/MacroChangesToTicketsResponseExample' - /api/v2/macros/{macro_id}/attachments: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroId' + /v2/macros/{macroId}/attachments: get: - operationId: ListMacroAttachments tags: - - Macros + - Macros summary: List Macro Attachments description: | Lists the attachments associated with a macro. #### Allowed For * Agents + operationId: ListMacroAttachments responses: "200": description: Success Response @@ -4814,9 +5033,8 @@ paths: default: $ref: '#/components/examples/MacroAttachmentsResponseExample' post: - operationId: CreateAssociatedMacroAttachment tags: - - Macros + - Macros summary: Create Macro Attachment description: | Allows an attachment to be uploaded and associated with a macro at the same time. @@ -4826,6 +5044,7 @@ paths: #### Allowed For * Agents + operationId: CreateAssociatedMacroAttachment responses: "201": description: Success Response @@ -4836,50 +5055,47 @@ paths: examples: default: $ref: '#/components/examples/MacroAttachmentResponseExample' - /api/v2/macros/actions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroId' + /v2/macros/actions: get: - operationId: ListMacrosActions tags: - - Macros + - Macros summary: List Supported Actions for Macros description: | #### Allowed For * Agents + operationId: ListMacrosActions responses: "200": description: Success Response content: application/json: schema: - type: object - properties: - actions: - type: array - items: - type: object - additionalProperties: true + $ref: '#/components/schemas/InlineResponse2003' examples: default: $ref: '#/components/examples/MacroActionsResponseExample' - /api/v2/macros/active: + /v2/macros/active: get: - operationId: ListActiveMacros tags: - - Macros + - Macros summary: List Active Macros description: | Lists all active shared and personal macros available to the current user. #### Allowed For * Agents + operationId: ListActiveMacros parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroInclude' - - $ref: '#/components/parameters/MacroAccess' - - $ref: '#/components/parameters/MacroCategory' - - $ref: '#/components/parameters/MacroGroupId' - - $ref: '#/components/parameters/MacroSortBy' - - $ref: '#/components/parameters/MacroSortOrder' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroInclude' + - $ref: '#/components/parameters/MacroAccess' + - $ref: '#/components/parameters/MacroCategory' + - $ref: '#/components/parameters/MacroGroupId' + - $ref: '#/components/parameters/MacroSortBy' + - $ref: '#/components/parameters/MacroSortOrder' responses: "200": description: Success Response @@ -4890,11 +5106,10 @@ paths: examples: default: $ref: '#/components/examples/MacrosResponseExample' - /api/v2/macros/attachments: + /v2/macros/attachments: post: - operationId: CreateMacroAttachment tags: - - Macros + - Macros summary: Create Unassociated Macro Attachment description: | Allows an attachment to be uploaded that can be associated with a macro at a later time. @@ -4904,6 +5119,7 @@ paths: #### Allowed For * Agents + operationId: CreateMacroAttachment responses: "201": description: Created Response @@ -4914,20 +5130,17 @@ paths: examples: default: $ref: '#/components/examples/MacroAttachmentResponseExample' - /api/v2/macros/attachments/{attachment_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/AttachmentId' + /v2/macros/attachments/{attachmentId}: get: - operationId: ShowMacroAttachment tags: - - Macros + - Macros summary: Show Macro Attachment description: | Shows the properties of the specified macro attachment. #### Allowed For * Agents + operationId: ShowMacroAttachment responses: "200": description: Success Response @@ -4938,17 +5151,20 @@ paths: examples: default: $ref: '#/components/examples/MacroAttachmentResponseExample' - /api/v2/macros/categories: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AttachmentId' + /v2/macros/categories: get: - operationId: ListMacroCategories tags: - - Macros + - Macros summary: List Macro Categories description: | Lists all macro categories available to the current user. #### Allowed For * Agents + operationId: ListMacroCategories responses: "200": description: Success Response @@ -4959,11 +5175,10 @@ paths: examples: default: $ref: '#/components/examples/MacroCategoriesResponseExample' - /api/v2/macros/definitions: + /v2/macros/definitions: get: - operationId: ListMacroActionDefinitions tags: - - Macros + - Macros summary: List Macro Action Definitions description: | Returns the definitions of the actions a macro can perform. For example, @@ -4974,68 +5189,51 @@ paths: #### Allowed For * Agents + operationId: ListMacroActionDefinitions responses: "200": description: Success Response content: application/json: schema: - type: object - properties: - definitions: - type: object - properties: - actions: - type: array - items: - type: object - additionalProperties: true + $ref: '#/components/schemas/InlineResponse2004' examples: default: $ref: '#/components/examples/ShowDerivedMacroResponseExample' - /api/v2/macros/destroy_many: + /v2/macros/destroy_many: delete: - operationId: DeleteManyMacros tags: - - Macros + - Macros summary: Bulk Delete Macros description: | Deletes the macros corresponding to the provided comma-separated list of IDs. #### Allowed For * Agents + operationId: DeleteManyMacros parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: The IDs of the macros to delete - required: true - schema: - type: array - items: - type: integer - example: - - 1 - - 2 - - 3 - responses: - "204": - description: No Content - /api/v2/macros/new: - parameters: - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroIdQuery' - - name: ticket_id + - name: ids in: query - description: The ID of the ticket from which to build a macro replica + description: The IDs of the macros to delete required: true + style: form + explode: true schema: - type: integer - example: 35436 + type: array + items: + type: integer + example: + - 1 + - 2 + - 3 + responses: + "204": + description: No Content + /v2/macros/new: get: - operationId: ShowDerivedMacro tags: - - Macros + - Macros summary: Show Macro Replica description: | Returns an unpersisted macro representation derived from a ticket or macro. @@ -5044,6 +5242,7 @@ paths: #### Allowed For * Agents + operationId: ShowDerivedMacro responses: "200": description: Success Response @@ -5054,22 +5253,23 @@ paths: examples: default: $ref: '#/components/examples/MacroResponseExample' - /api/v2/macros/search: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroInclude' - - $ref: '#/components/parameters/MacroAccess' - - $ref: '#/components/parameters/MacroActive' - - $ref: '#/components/parameters/MacroCategory' - - $ref: '#/components/parameters/MacroGroupId' - - $ref: '#/components/parameters/MacroOnlyViewable' - - $ref: '#/components/parameters/MacroSortBy' - - $ref: '#/components/parameters/MacroSortOrder' - - $ref: '#/components/parameters/MacroQuery' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroIdQuery' + - name: ticket_id + in: query + description: The ID of the ticket from which to build a macro replica + required: true + style: form + explode: true + schema: + type: integer + example: 35436 + x-ballerina-name: ticketId + /v2/macros/search: get: - operationId: SearchMacro tags: - - Macros + - Macros summary: Search Macros description: | #### Pagination @@ -5080,6 +5280,7 @@ paths: #### Allowed For * Agents + operationId: SearchMacro responses: "200": description: Success Response @@ -5090,17 +5291,28 @@ paths: examples: default: $ref: '#/components/examples/MacrosResponseExample' - /api/v2/macros/update_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroInclude' + - $ref: '#/components/parameters/MacroAccess' + - $ref: '#/components/parameters/MacroActive' + - $ref: '#/components/parameters/MacroCategory' + - $ref: '#/components/parameters/MacroGroupId' + - $ref: '#/components/parameters/MacroOnlyViewable' + - $ref: '#/components/parameters/MacroSortBy' + - $ref: '#/components/parameters/MacroSortOrder' + - $ref: '#/components/parameters/MacroQuery' + /v2/macros/update_many: put: - operationId: UpdateManyMacros tags: - - Macros + - Macros summary: Update Many Macros description: | Updates the provided macros with the specified changes. #### Allowed For * Agents + operationId: UpdateManyMacros requestBody: content: application/json: @@ -5110,10 +5322,10 @@ paths: default: value: macros: - - active: false - id: 25 - - id: 23 - position: 5 + - active: false + id: 25 + - id: 23 + position: 5 responses: "200": description: Success Response @@ -5124,19 +5336,16 @@ paths: examples: default: $ref: '#/components/examples/MacrosResponseExample' - /api/v2/object_layouts/{object_type}/essentials_card: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/EssentialsCardKey' + /v2/object_layouts/{objectType}/essentials_card: get: - operationId: ShowEssentialsCard tags: - - Essentials Card + - Essentials Card summary: Show Essentials Card description: | Gets the essentials card for an object type. #### Allowed For * Admins and agents + operationId: ShowEssentialsCard responses: "200": description: Success response @@ -5148,14 +5357,14 @@ paths: default: $ref: '#/components/examples/EssentialsCardExample' put: - operationId: UpdateEssentialsCard tags: - - Essentials Card + - Essentials Card summary: Update Essentials Card description: | Updates the essentials card for an object type. #### Allowed For * Admins + operationId: UpdateEssentialsCard responses: "200": description: Success response @@ -5167,27 +5376,30 @@ paths: default: $ref: '#/components/examples/EssentialsCardExample' delete: - operationId: DeleteEssentialsCard tags: - - Essentials Card + - Essentials Card summary: Delete Essentials Card description: | Delete the essentials card for an object type. #### Allowed For * Admins and agents + operationId: DeleteEssentialsCard responses: "204": description: Success response - /api/v2/object_layouts/essentials_cards: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/EssentialsCardKey' + /v2/object_layouts/essentials_cards: get: - operationId: ShowEssentialsCards tags: - - Essentials Card + - Essentials Card summary: List of Essentials Cards description: | Gets the list of essentials cards. #### Allowed For * Admins + operationId: ShowEssentialsCards responses: "200": description: Success response @@ -5198,11 +5410,10 @@ paths: examples: default: $ref: '#/components/examples/EssentialsCardsExample' - /api/v2/organization_fields: + /v2/organization_fields: get: - operationId: ListOrganizationFields tags: - - Organization Fields + - Organization Fields summary: List Organization Fields description: | Returns a list of custom organization fields in your account. Fields are returned in the order that you specify in your organization fields configuration in Zendesk Support. Clients should cache this resource for the duration of their API usage and map the key for each organization field to the values returned under the `organization_fields` attribute on the [organization](/api-reference/ticketing/organizations/organizations/) resource. @@ -5219,6 +5430,7 @@ paths: #### Allowed For * Agents + operationId: ListOrganizationFields responses: "200": description: Success response @@ -5230,9 +5442,8 @@ paths: default: $ref: '#/components/examples/OrganizationFieldsResponseExample' post: - operationId: CreateOrganizationField tags: - - Organization Fields + - Organization Fields summary: Create Organization Field description: | Creates any of the following custom field types: @@ -5252,6 +5463,7 @@ paths: #### Allowed For * Admins + operationId: CreateOrganizationField responses: "201": description: Created response @@ -5262,19 +5474,16 @@ paths: examples: default: $ref: '#/components/examples/OrganizationFieldCreateResponseExample' - /api/v2/organization_fields/{organization_field_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationFieldId' + /v2/organization_fields/{organizationFieldId}: get: - operationId: ShowOrganizationField tags: - - Organization Fields + - Organization Fields summary: Show Organization Field description: | #### Allowed for * Agents + operationId: ShowOrganizationField responses: "200": description: Success response @@ -5286,9 +5495,8 @@ paths: default: $ref: '#/components/examples/OrganizationFieldResponseExample' put: - operationId: UpdateOrganizationField tags: - - Organization Fields + - Organization Fields summary: Update Organization Field description: | #### Updating a Drop-down (Tagger) Field @@ -5312,6 +5520,7 @@ paths: #### Allowed for * Admins + operationId: UpdateOrganizationField responses: "200": description: Success response @@ -5323,27 +5532,30 @@ paths: default: $ref: '#/components/examples/OrganizationFieldUpdateResponseExample' delete: - operationId: DeleteOrganizationField tags: - - Organization Fields + - Organization Fields summary: Delete Organization Field description: | #### Allowed for * Admins + operationId: DeleteOrganizationField responses: "204": description: No Content response - /api/v2/organization_fields/reorder: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationFieldId' + /v2/organization_fields/reorder: put: - operationId: ReorderOrganizationField tags: - - Organization Fields + - Organization Fields summary: Reorder Organization Field description: | #### Allowed For * Admins + operationId: ReorderOrganizationField responses: "200": description: Success response @@ -5354,11 +5566,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/organization_memberships: + /v2/organization_memberships: get: - operationId: ListOrganizationMemberships tags: - - Organization Memberships + - Organization Memberships summary: List Memberships description: | Returns a list of organization memberships for the account, user or organization in question. @@ -5378,6 +5589,7 @@ paths: - Agents - End users + operationId: ListOrganizationMemberships responses: "200": description: Success response @@ -5389,9 +5601,8 @@ paths: default: $ref: '#/components/examples/OrganizationMembershipsResponseExample' post: - operationId: CreateOrganizationMembership tags: - - Organization Memberships + - Organization Memberships summary: Create Membership description: | Assigns a user to a given organization. Returns an error with status 422 if the user is already assigned to the organization. @@ -5400,6 +5611,7 @@ paths: * Admins * Agents when creating a new organization membership for an end user + operationId: CreateOrganizationMembership responses: "201": description: Created response @@ -5410,19 +5622,16 @@ paths: examples: default: $ref: '#/components/examples/OrganizationMembershipCreateResponseExample' - /api/v2/organization_memberships/{organization_membership_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationMembershipId' + /v2/organization_memberships/{organizationMembershipId}: get: - operationId: ShowOrganizationMembershipById tags: - - Organization Memberships + - Organization Memberships summary: Show Membership description: | #### Allowed for * Agents + operationId: ShowOrganizationMembershipById responses: "200": description: Success response @@ -5434,9 +5643,8 @@ paths: default: $ref: '#/components/examples/OrganizationMembershipResponseExample' delete: - operationId: DeleteOrganizationMembership tags: - - Organization Memberships + - Organization Memberships summary: Delete Membership description: | Immediately removes a user from an organization and schedules a job to unassign all working tickets currently assigned to the user and organization combination. The `organization_id` of the unassigned tickets is set to null. @@ -5445,14 +5653,17 @@ paths: * Admins * Agents when deleting an organization membership for an end user + operationId: DeleteOrganizationMembership responses: "204": description: No Content response - /api/v2/organization_memberships/create_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationMembershipId' + /v2/organization_memberships/create_many: post: - operationId: CreateManyOrganizationMemberships tags: - - Organization Memberships + - Organization Memberships summary: Create Many Memberships description: | This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information. @@ -5460,6 +5671,7 @@ paths: #### Allowed For * Admins * Agents + operationId: CreateManyOrganizationMemberships responses: "200": description: Success response @@ -5470,11 +5682,10 @@ paths: examples: default: $ref: '#/components/examples/OrganizationMembershipCreateManyResponseExample' - /api/v2/organization_memberships/destroy_many: + /v2/organization_memberships/destroy_many: delete: - operationId: DeleteManyOrganizationMemberships tags: - - Organization Memberships + - Organization Memberships summary: Bulk Delete Memberships description: | Immediately removes a user from an organization and schedules a job to unassign all working tickets currently assigned to the user and organization combination. The `organization_id` of the unassigned tickets is set to null. @@ -5486,15 +5697,19 @@ paths: #### Allowed For * Agents + operationId: DeleteManyOrganizationMemberships parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: The IDs of the organization memberships to delete - schema: - type: array - items: - type: integer + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: The IDs of the organization memberships to delete + required: false + style: form + explode: true + schema: + type: array + items: + type: integer responses: "200": description: Success response @@ -5505,11 +5720,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusBulkDeleteResponseExample' - /api/v2/organization_subscriptions: + /v2/organization_subscriptions: get: - operationId: ListOrganizationSubscriptions tags: - - Organization Subscriptions + - Organization Subscriptions summary: List Organization Subscriptions description: |- #### Pagination @@ -5527,6 +5741,7 @@ paths: * End users For end users, the response will only list the subscriptions created by the requesting end user. + operationId: ListOrganizationSubscriptions responses: "200": description: Successful response @@ -5538,9 +5753,8 @@ paths: default: $ref: '#/components/examples/OrganizationSubscriptionsResponseExample' post: - operationId: CreateOrganizationSubscription tags: - - Organization Subscriptions + - Organization Subscriptions summary: Create Organization Subscription description: |- #### Allowed For: @@ -5549,6 +5763,7 @@ paths: * End users End users can only subscribe to shared organizations in which they're members. + operationId: CreateOrganizationSubscription requestBody: content: application/json: @@ -5567,11 +5782,10 @@ paths: examples: default: $ref: '#/components/examples/OrganizationSubscriptionResponseExample' - /api/v2/organization_subscriptions/{organization_subscription_id}: + /v2/organization_subscriptions/{organizationSubscriptionId}: get: - operationId: ShowOrganizationSubscription tags: - - Organization Subscriptions + - Organization Subscriptions summary: Show Organization Subscription description: |- #### Allowed For: @@ -5580,9 +5794,10 @@ paths: * End users For end users, the response will only list the subscriptions created by the requesting end user. + operationId: ShowOrganizationSubscription parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationSubscriptionId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationSubscriptionId' responses: "200": description: Successful response @@ -5594,26 +5809,25 @@ paths: default: $ref: '#/components/examples/OrganizationSubscriptionResponseExample' delete: - operationId: DeleteOrganizationSubscription tags: - - Organization Subscriptions + - Organization Subscriptions summary: Delete Organization Subscription description: |- #### Allowed For: * Agents * End users + operationId: DeleteOrganizationSubscription parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationSubscriptionId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationSubscriptionId' responses: "204": description: No content - /api/v2/organizations: + /v2/organizations: get: - operationId: ListOrganizations tags: - - Organizations + - Organizations summary: List Organizations description: | #### Pagination @@ -5630,6 +5844,7 @@ paths: * Agents, with certain restrictions If the agent has a custom agent role that restricts their access to only users in their own organization, a 403 Forbidden error is returned. See [Creating custom agent roles](https://support.zendesk.com/hc/en-us/articles/203662026-Creating-custom-roles-and-assigning-agents#topic_cxn_hig_bd) in Zendesk help. + operationId: ListOrganizations responses: "200": description: Success response @@ -5641,9 +5856,8 @@ paths: default: $ref: '#/components/examples/OrganizationsResponseExample' post: - operationId: CreateOrganization tags: - - Organizations + - Organizations summary: Create Organization description: | You must provide a unique `name` for each organization. Normally @@ -5656,6 +5870,7 @@ paths: * Admins * Agents assigned to a custom role with permissions to manage organizations (Enterprise only) + operationId: CreateOrganization responses: "201": description: Created @@ -5666,20 +5881,17 @@ paths: examples: default: $ref: '#/components/examples/CreatedOrganizationResponseExample' - /api/v2/organizations/{organization_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationId' + /v2/organizations/{organizationId}: get: - operationId: ShowOrganization tags: - - Organizations + - Organizations summary: Show Organization description: | #### Allowed For * Admins * Agents + operationId: ShowOrganization responses: "200": description: Success response @@ -5691,9 +5903,8 @@ paths: default: $ref: '#/components/examples/OrganizationResponseExample' put: - operationId: UpdateOrganization tags: - - Organizations + - Organizations summary: Update Organization description: | #### Allowed For @@ -5714,6 +5925,7 @@ paths: } } ``` + operationId: UpdateOrganization responses: "200": description: Success response @@ -5734,34 +5946,34 @@ paths: default: value: errors: - - code: TooManyRequests - title: Too many requests to update + - code: TooManyRequests + title: Too many requests to update delete: - operationId: DeleteOrganization tags: - - Organizations + - Organizations summary: Delete Organization description: | #### Allowed For * Admins * Agents assigned to a custom role with permissions to manage organizations (Enterprise only) + operationId: DeleteOrganization responses: "204": description: No Content Response - /api/v2/organizations/{organization_id}/related: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationId' + /v2/organizations/{organizationId}/related: get: - operationId: OrganizationRelated tags: - - Organizations + - Organizations summary: Show Organization's Related Information description: | #### Allowed For * Agents + operationId: OrganizationRelated responses: "200": description: Success response @@ -5772,16 +5984,13 @@ paths: examples: default: $ref: '#/components/examples/OrganizationsRelatedResponse' - /api/v2/organizations/autocomplete: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationQueryFragment' - - $ref: '#/components/parameters/LookupRelationshipAutocompleteFieldIdFragment' - - $ref: '#/components/parameters/LookupRelationshipAutocompleteSourceFragment' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationId' + /v2/organizations/autocomplete: get: - operationId: AutocompleteOrganizations tags: - - Organizations + - Organizations summary: Autocomplete Organizations description: | Returns an array of organizations whose name starts with the @@ -5796,6 +6005,7 @@ paths: #### Allowed For * Agents + operationId: AutocompleteOrganizations responses: "200": description: Success response @@ -5816,8 +6026,8 @@ paths: default: value: errors: - - code: QueryError - title: Invalid type:sample_type + - code: QueryError + title: Invalid type:sample_type "429": description: Too Many Requests content: @@ -5828,8 +6038,8 @@ paths: default: value: errors: - - code: TooManyRequests - title: Too many requests to autocomplete + - code: TooManyRequests + title: Too many requests to autocomplete "500": description: Internal Server Error content: @@ -5840,13 +6050,17 @@ paths: default: value: errors: - - code: Unavailable - title: Internal Server Error - /api/v2/organizations/count: + - code: Unavailable + title: Internal Server Error + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationQueryFragment' + - $ref: '#/components/parameters/LookupRelationshipAutocompleteFieldIdFragment' + - $ref: '#/components/parameters/LookupRelationshipAutocompleteSourceFragment' + /v2/organizations/count: get: - operationId: CountOrganizations tags: - - Organizations + - Organizations summary: Count Organizations description: | Returns an approximate count of organizations. If the count exceeds @@ -5863,6 +6077,7 @@ paths: #### Allowed For * Agents + operationId: CountOrganizations responses: "200": description: Success response @@ -5873,11 +6088,10 @@ paths: examples: default: $ref: '#/components/examples/CountOrganizationsResponseExample' - /api/v2/organizations/create_many: + /v2/organizations/create_many: post: - operationId: CreateManyOrganizations tags: - - Organizations + - Organizations summary: Create Many Organizations description: | Accepts an array of up to 100 organization objects. @@ -5889,6 +6103,7 @@ paths: #### Allowed For * Agents, with restrictions applying on certain actions + operationId: CreateManyOrganizations responses: "200": description: Success response @@ -5899,11 +6114,10 @@ paths: examples: default: $ref: '#/components/examples/ShowJobStatusResponseExample' - /api/v2/organizations/create_or_update: + /v2/organizations/create_or_update: post: - operationId: CreateOrUpdateOrganization tags: - - Organizations + - Organizations summary: Create Or Update Organization description: | Creates an organization if it doesn't already exist, or updates @@ -5916,6 +6130,7 @@ paths: #### Allowed For * Agents, with restrictions on certain actions + operationId: CreateOrUpdateOrganization responses: "200": description: Success response @@ -5935,15 +6150,10 @@ paths: examples: default: $ref: '#/components/examples/CreatedOrganizationResponseExample' - /api/v2/organizations/destroy_many: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationIds' - - $ref: '#/components/parameters/OrganizationExternalIds' + /v2/organizations/destroy_many: delete: - operationId: DeleteManyOrganizations tags: - - Organizations + - Organizations summary: Bulk Delete Organizations description: | Accepts a comma-separated list of up to 100 organization ids or external ids. @@ -5956,6 +6166,7 @@ paths: * Admins * Agents assigned to a custom role with permissions to manage organizations (Enterprise only) + operationId: DeleteManyOrganizations responses: "200": description: Success response @@ -5966,15 +6177,14 @@ paths: examples: default: $ref: '#/components/examples/JobStatusBulkDeleteResponseExample' - /api/v2/organizations/search: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationExternalId' - - $ref: '#/components/parameters/OrganizationName' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationIds' + - $ref: '#/components/parameters/OrganizationExternalIds' + /v2/organizations/search: get: - operationId: SearchOrganizations tags: - - Organizations + - Organizations summary: Search Organizations description: | Returns an array of organizations matching the criteria. You may search by an organization's `external_id` or `name`, but not both: @@ -5995,6 +6205,7 @@ paths: * Agents assigned to a custom role with permissions to add or modify organizations (Enterprise only) See [Creating custom agent roles](https://support.zendesk.com/hc/en-us/articles/203662026#topic_cxn_hig_bd) in the Support Help Center. + operationId: SearchOrganizations responses: "200": description: Success response @@ -6005,15 +6216,14 @@ paths: examples: default: $ref: '#/components/examples/OrganizationsResponseExample' - /api/v2/organizations/show_many: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationIds' - - $ref: '#/components/parameters/OrganizationExternalIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationExternalId' + - $ref: '#/components/parameters/OrganizationName' + /v2/organizations/show_many: get: - operationId: ShowManyOrganizations tags: - - Organizations + - Organizations summary: Show Many Organizations description: | Accepts a comma-separated list of up to 100 organization ids or external ids. @@ -6022,6 +6232,7 @@ paths: * Admins * Agents + operationId: ShowManyOrganizations responses: "200": description: Success response @@ -6032,15 +6243,14 @@ paths: examples: default: $ref: '#/components/examples/AutocompleteOrganizationsResponseExample' - /api/v2/organizations/update_many: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationIds' - - $ref: '#/components/parameters/OrganizationExternalIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationIds' + - $ref: '#/components/parameters/OrganizationExternalIds' + /v2/organizations/update_many: put: - operationId: UpdateManyOrganizations tags: - - Organizations + - Organizations summary: Update Many Organizations description: | Bulk or batch updates up to 100 organizations. @@ -6084,6 +6294,7 @@ paths: * Agents Agents with no permissions restrictions can only update "notes" on organizations. + operationId: UpdateManyOrganizations responses: "200": description: Success response @@ -6094,11 +6305,14 @@ paths: examples: default: $ref: '#/components/examples/ShowJobStatusResponseExample' - /api/v2/problems: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationIds' + - $ref: '#/components/parameters/OrganizationExternalIds' + /v2/problems: get: - operationId: ListTicketProblems tags: - - Tickets + - Tickets summary: List Ticket Problems description: |- The response is always ordered by `updated_at` in descending order @@ -6113,6 +6327,7 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListTicketProblems responses: "200": description: Successful response @@ -6123,11 +6338,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketProblemsResponseExample' - /api/v2/problems/autocomplete: + /v2/problems/autocomplete: post: - operationId: AutocompleteProblems tags: - - Tickets + - Tickets summary: Autocomplete Problems description: |- Returns tickets whose type is "problem" and whose subject contains the string specified in the `text` parameter. @@ -6139,22 +6353,22 @@ paths: #### Allowed For * Agents + operationId: AutocompleteProblems parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: text - in: query - description: The text to search for - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: text + in: query + description: The text to search for + required: false + style: form + explode: true + schema: + type: string requestBody: content: application/json: schema: - type: object - properties: - text: - type: string - description: The text to search for + $ref: '#/components/schemas/ProblemsAutocompleteBody' example: text: fire responses: @@ -6167,11 +6381,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketProblemsResponseExample' - /api/v2/push_notification_devices/destroy_many: + /v2/push_notification_devices/destroy_many: post: - operationId: PushNotificationDevices tags: - - Push Notification Devices + - Push Notification Devices summary: Bulk Unregister Push Notification Devices description: |- Unregisters the mobile devices that are receiving push notifications. Specify the devices as an array of mobile device tokens. @@ -6179,6 +6392,7 @@ paths: #### Allowed for * Admins + operationId: PushNotificationDevices requestBody: content: application/json: @@ -6197,16 +6411,16 @@ paths: description: empty example: "" example: "" - /api/v2/queues: + /v2/queues: get: - operationId: ListQueues tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: List queues description: | #### Allowed For * Admins + operationId: ListQueues responses: "200": description: Success response @@ -6218,14 +6432,14 @@ paths: default: $ref: '#/components/examples/QueuesResponseExample' post: - operationId: CreateQueue tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: Create queue description: | #### Allowed For * Admins + operationId: CreateQueue responses: "201": description: Created response @@ -6236,19 +6450,16 @@ paths: examples: default: $ref: '#/components/examples/QueueCreateResponseExample' - /api/v2/queues/{queue_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OcrQueueId' + /v2/queues/{queueId}: get: - operationId: ShowQueueById tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: Show Queue description: | #### Allowed For * Admins + operationId: ShowQueueById responses: "200": description: Success response @@ -6260,14 +6471,14 @@ paths: default: $ref: '#/components/examples/QueueResponseExample' put: - operationId: UpdateQueue tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: Update queue description: | #### Allowed For * Admins + operationId: UpdateQueue responses: "200": description: Success response @@ -6279,27 +6490,30 @@ paths: default: $ref: '#/components/examples/QueuesUpdateResponseExample' delete: - operationId: DeleteQueue tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: Delete queue description: | #### Allowed For * Admins + operationId: DeleteQueue responses: "204": description: No content response - /api/v2/queues/definitions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OcrQueueId' + /v2/queues/definitions: get: - operationId: ListQueueDefinitions tags: - - Omnichannel Routing Queues + - Omnichannel Routing Queues summary: List queue definitions description: | #### Allowed For * Admins + operationId: ListQueueDefinitions responses: "200": description: Success response @@ -6310,11 +6524,10 @@ paths: examples: default: $ref: '#/components/examples/DefinitionsResponseExample' - /api/v2/recipient_addresses: + /v2/recipient_addresses: get: - operationId: ListSupportAddresses tags: - - Support Addresses + - Support Addresses summary: List Support Addresses description: | Lists all the support addresses for the account. @@ -6332,6 +6545,7 @@ paths: * Admins * Agents + operationId: ListSupportAddresses responses: "200": description: Success response @@ -6343,9 +6557,8 @@ paths: default: $ref: '#/components/examples/SupportAddressesResponseExample' post: - operationId: CreateSupportAddress tags: - - Support Addresses + - Support Addresses summary: Create Support Address description: | Adds a Zendesk or external support address to your account. @@ -6359,6 +6572,7 @@ paths: * Admins * Agents with permission to manage channels and extensions. See the system permissions in [Creating custom roles and assigning agents (Enterprise)](https://support.zendesk.com/hc/en-us/articles/203662026-Creating-custom-roles-and-assigning-agents-Enterprise-#topic_cxn_hig_bd) in the Support Help Center + operationId: CreateSupportAddress responses: "201": description: Created response @@ -6369,20 +6583,17 @@ paths: examples: default: $ref: '#/components/examples/SupportAddressCreateResponseExample' - /api/v2/recipient_addresses/{support_address_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SupportAddressId' + /v2/recipient_addresses/{supportAddressId}: get: - operationId: ShowSupportAddress tags: - - Support Addresses + - Support Addresses summary: Show Support Address description: | #### Allowed For * Admins * Agents + operationId: ShowSupportAddress responses: "200": description: Success response @@ -6394,9 +6605,8 @@ paths: default: $ref: '#/components/examples/SupportAddressResponseExample' put: - operationId: UpdateSupportAddress tags: - - Support Addresses + - Support Addresses summary: Update Support Address description: | Updates an existing support address for your account. @@ -6409,6 +6619,7 @@ paths: * Admins * Agents with permission to manage channels and extensions. See the system permissions in [Creating custom roles and assigning agents (Enterprise)](https://support.zendesk.com/hc/en-us/articles/203662026-Creating-custom-roles-and-assigning-agents-Enterprise-#topic_cxn_hig_bd) in the Support Help Center + operationId: UpdateSupportAddress responses: "200": description: Success response @@ -6420,9 +6631,8 @@ paths: default: $ref: '#/components/examples/SupportAddressUpdateResponseExample' delete: - operationId: DeleteRecipientAddress tags: - - Support Addresses + - Support Addresses summary: Delete Support Address description: | Deletes a support address. @@ -6431,17 +6641,17 @@ paths: * Admins * Agents with permission to manage channels and extensions. See the system permissions in [Creating custom roles and assigning agents (Enterprise)](https://support.zendesk.com/hc/en-us/articles/203662026-Creating-custom-roles-and-assigning-agents-Enterprise-#topic_cxn_hig_bd) in the Support Help Center + operationId: DeleteRecipientAddress responses: "204": description: No Content response - /api/v2/recipient_addresses/{support_address_id}/verify: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SupportAddressId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SupportAddressId' + /v2/recipient_addresses/{supportAddressId}/verify: put: - operationId: VerifySupportAddressForwarding tags: - - Support Addresses + - Support Addresses summary: Verify Support Address Forwarding description: | Sends a test email to the specified support address to verify that email forwarding for the address works. An external support address won't work in Zendesk Support until it's verified. @@ -6464,6 +6674,7 @@ paths: * Admins * Agents with permission to manage channels and extensions. See the system permissions in [Creating custom roles and assigning agents (Enterprise)](https://support.zendesk.com/hc/en-us/articles/203662026-Creating-custom-roles-and-assigning-agents-Enterprise-#topic_cxn_hig_bd) in the Support Help Center + operationId: VerifySupportAddressForwarding responses: "200": description: Success response @@ -6474,36 +6685,45 @@ paths: description: Empty response example: "" example: "" - /api/v2/relationships/definitions/{target_type}: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SupportAddressId' + /v2/relationships/definitions/{targetType}: get: - operationId: GetRelationshipFilterDefinitions tags: - - Lookup Relationships + - Lookup Relationships summary: Filter Definitions description: | Returns filter definitions based on the given target type. Target types include users (zen:user), tickets (zen:ticket), organizations (zen:organization), or custom objects (zen:custom_object:CUSTOM_OBJECT_KEY). The returned filter definitions are the options that you can use to build a custom field or ticket field's `relationship_filter`. + operationId: GetRelationshipFilterDefinitions parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: target_type - in: path - description: | - The target type for which you would like to see filter definitions. - The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" - required: true - schema: - type: string - example: zen:custom_object:apartment - - name: source_type - in: query - description: | - The source type for which you would like to see filter definitions. - The options are "zen:user", "zen:ticket", and "zen:organization" - schema: - type: string - example: zen:user + - $ref: '#/components/parameters/AcceptHeader' + - name: targetType + in: path + description: | + The target type for which you would like to see filter definitions. + The options are "zen:user", "zen:ticket", "zen:organization", and "zen:custom_object:CUSTOM_OBJECT_KEY" + required: true + style: simple + explode: false + schema: + type: string + example: zen:custom_object:apartment + - name: source_type + in: query + description: | + The source type for which you would like to see filter definitions. + The options are "zen:user", "zen:ticket", and "zen:organization" + required: false + style: form + explode: true + schema: + type: string + example: zen:user + x-ballerina-name: sourceType responses: "200": description: Success response @@ -6514,11 +6734,10 @@ paths: examples: default: $ref: '#/components/examples/RelationshipFilterDefinitionExample' - /api/v2/requests: + /v2/requests: get: - operationId: ListRequests tags: - - Requests + - Requests summary: List Requests description: | #### Allowed for @@ -6531,18 +6750,27 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListRequests parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: sort_by - in: query - description: Possible values are "updated_at", "created_at" - schema: - type: string - - name: sort_order - in: query - description: One of "asc", "desc". Defaults to "asc" - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: sort_by + in: query + description: "Possible values are \"updated_at\", \"created_at\"" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: "One of \"asc\", \"desc\". Defaults to \"asc\"" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -6554,9 +6782,8 @@ paths: default: $ref: '#/components/examples/RequestsResponseExample' post: - operationId: CreateRequest tags: - - Requests + - Requests summary: Create Request description: | Accepts a `request` object that sets one or more properties. @@ -6579,6 +6806,7 @@ paths: #### Creating follow-up requests Once a ticket is closed (as distinct from solved), it can't be reopened. However, you can create a new request that references the closed ticket. To create the follow-up request, include a `via_followup_source_id` property in the `request` object that specifies the closed ticket. The parameter only works with closed tickets. It has no effect with other tickets. + operationId: CreateRequest responses: "201": description: Created response @@ -6589,14 +6817,10 @@ paths: examples: default: $ref: '#/components/examples/RequestCreateResponseExample' - /api/v2/requests/{request_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/RequestId' + /v2/requests/{requestId}: get: - operationId: ShowRequest tags: - - Requests + - Requests summary: Show Request description: | #### Sideloads @@ -6610,6 +6834,7 @@ paths: #### Allowed For * End Users + operationId: ShowRequest responses: "200": description: Success response @@ -6621,9 +6846,8 @@ paths: default: $ref: '#/components/examples/RequestResponseExample' put: - operationId: UpdateRequest tags: - - Requests + - Requests summary: Update Request description: | Updates a request with a comment or collaborators (cc's). The end user who created the request can also use it to mark the request as solved. The endpoint can't be used to update other request attributes. @@ -6640,6 +6864,7 @@ paths: #### Allowed For * End users + operationId: UpdateRequest responses: "200": description: Success response @@ -6650,14 +6875,13 @@ paths: examples: default: $ref: '#/components/examples/RequestCreateResponseExample' - /api/v2/requests/{request_id}/comments: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/RequestId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/RequestId' + /v2/requests/{requestId}/comments: get: - operationId: ListComments tags: - - Requests + - Requests summary: Listing Comments description: | #### Pagination @@ -6687,18 +6911,26 @@ paths: #### Allowed For * End Users + operationId: ListComments parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: since - in: query - description: Filters the comments from the given datetime - schema: - type: string - - name: role - in: query - description: One of "agent", "end_user". If not specified it does not filter - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: since + in: query + description: Filters the comments from the given datetime + required: false + style: form + explode: true + schema: + type: string + - name: role + in: query + description: "One of \"agent\", \"end_user\". If not specified it does not\ + \ filter" + required: false + style: form + explode: true + schema: + type: string responses: "200": description: Success response @@ -6709,20 +6941,19 @@ paths: examples: default: $ref: '#/components/examples/RequestListCommentsResponseExample' - /api/v2/requests/{request_id}/comments/{ticket_comment_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/RequestId' - - $ref: '#/components/parameters/TicketCommentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/RequestId' + /v2/requests/{requestId}/comments/{ticketCommentId}: get: - operationId: ShowComment tags: - - Requests + - Requests summary: Getting Comments description: | #### Allowed For * End Users + operationId: ShowComment responses: "200": description: Success response @@ -6733,11 +6964,14 @@ paths: examples: default: $ref: '#/components/examples/RequestGetCommentResponseExample' - /api/v2/requests/search: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/RequestId' + - $ref: '#/components/parameters/TicketCommentId' + /v2/requests/search: get: - operationId: SearchRequests tags: - - Requests + - Requests summary: Search Requests description: | Examples: @@ -6760,13 +6994,20 @@ paths: #### Allowed For * End Users + operationId: SearchRequests parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: The syntax and matching logic for the string is detailed in the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226). See also [Query basics](/api-reference/ticketing/ticket-management/search/#query-basics) in the Tickets API doc. - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: "The syntax and matching logic for the string is detailed in\ + \ the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226).\ + \ See also [Query basics](/api-reference/ticketing/ticket-management/search/#query-basics)\ + \ in the Tickets API doc" + required: false + style: form + explode: true + schema: + type: string responses: "200": description: Success response @@ -6777,11 +7018,10 @@ paths: examples: default: $ref: '#/components/examples/RequestsResponseExample' - /api/v2/resource_collections: + /v2/resource_collections: get: - operationId: ListResourceCollections tags: - - Resource Collections + - Resource Collections summary: List Resource Collections description: | Lists resource collections for the account. @@ -6789,6 +7029,7 @@ paths: #### Allowed for * Admins + operationId: ListResourceCollections responses: "200": description: Success response @@ -6800,9 +7041,8 @@ paths: default: $ref: '#/components/examples/ResourceCollectionsResponseExample' post: - operationId: CreateResourceCollection tags: - - Resource Collections + - Resource Collections summary: Create Resource Collection description: | Creates a resource collection from a provided `payload` object. The `payload` object is specified the same way as the content of a requirements.json file in a Zendesk app. See [Specifying Apps Requirements](/documentation/apps/app-developer-guide/apps_requirements/) in the Zendesk Apps framework docs. @@ -6813,6 +7053,7 @@ paths: #### Allowed for * Admins + operationId: CreateResourceCollection responses: "200": description: Success response @@ -6823,14 +7064,10 @@ paths: examples: default: $ref: '#/components/examples/ResourceCollectionCreateResponseExample' - /api/v2/resource_collections/{resource_collection_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ResourceCollectionId' + /v2/resource_collections/{resourceCollectionId}: get: - operationId: RetrieveResourceCollection tags: - - Resource Collections + - Resource Collections summary: Show Resource Collection description: | Retrieves details for a specified resource collection. @@ -6838,6 +7075,7 @@ paths: #### Allowed for * Admins + operationId: RetrieveResourceCollection responses: "200": description: Success response @@ -6849,9 +7087,8 @@ paths: default: $ref: '#/components/examples/ResourceCollectionResponseExample' put: - operationId: UpdateResourceCollection tags: - - Resource Collections + - Resource Collections summary: Update Resource Collection description: | Updates a resource collection using a provided `payload` object. The `payload` object is specified the same way as the content of a requirements.json file in a Zendesk app. See [Specifying Apps Requirements](/documentation/apps/app-developer-guide/apps_requirements/) in the Zendesk Apps framework docs. @@ -6862,6 +7099,7 @@ paths: #### Allowed for * Admins + operationId: UpdateResourceCollection responses: "200": description: Success response @@ -6873,9 +7111,8 @@ paths: default: $ref: '#/components/examples/ResourceCollectionUpdateResponseExample' delete: - operationId: DeleteResourceCollection tags: - - Resource Collections + - Resource Collections summary: Delete Resource Collection description: | Deletes a specified resource collection. @@ -6886,6 +7123,7 @@ paths: #### Allowed for * Admins + operationId: DeleteResourceCollection responses: "200": description: Success response @@ -6896,14 +7134,13 @@ paths: examples: default: $ref: '#/components/examples/ResourceCollectionDeleteResponseExample' - /api/v2/routing/agents/{user_id}/instance_values: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ResourceCollectionId' + /v2/routing/agents/{userId}/instance_values: get: - operationId: ListAGentAttributeValues tags: - - Skill Based Routing + - Skill Based Routing summary: List Agent Attribute Values description: | Returns an attribute value. @@ -6911,6 +7148,7 @@ paths: #### Allowed For * Agents and admins + operationId: ListAGentAttributeValues responses: "200": description: Success response @@ -6922,9 +7160,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValuesResponseExample' post: - operationId: SetAgentAttributeValues tags: - - Skill Based Routing + - Skill Based Routing summary: Set Agent Attribute Values description: | Adds the specified attributes if no attributes exists, or replaces all existing attributes with the specified attributes. @@ -6932,6 +7169,7 @@ paths: #### Allowed For * Admins + operationId: SetAgentAttributeValues responses: "200": description: Success response @@ -6942,11 +7180,13 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValuesResponseExample' - /api/v2/routing/attributes: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/routing/attributes: get: - operationId: ListAccountAttributes tags: - - Skill Based Routing + - Skill Based Routing summary: List Account Attributes description: | Returns a list of attributes for the account. @@ -6962,6 +7202,7 @@ paths: #### Allowed For * Agents and admins + operationId: ListAccountAttributes responses: "200": description: Success response @@ -6973,9 +7214,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingAttributesResponseExample' post: - operationId: CreateAttribute tags: - - Skill Based Routing + - Skill Based Routing summary: Create Attribute description: | Creates an attribute. @@ -6983,6 +7223,7 @@ paths: #### Allowed For * Agents + operationId: CreateAttribute responses: "201": description: Created response @@ -6993,14 +7234,10 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeCreateResponseExample' - /api/v2/routing/attributes/{attribute_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' + /v2/routing/attributes/{attributeId}: get: - operationId: ShowAttribute tags: - - Skill Based Routing + - Skill Based Routing summary: Show Attribute description: | Returns an attribute. @@ -7008,6 +7245,7 @@ paths: #### Allowed For * Admins + operationId: ShowAttribute responses: "200": description: Success response @@ -7019,9 +7257,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingAttributeResponseExample' put: - operationId: UpdateAttribute tags: - - Skill Based Routing + - Skill Based Routing summary: Update Attribute description: | Updates an attribute. @@ -7029,6 +7266,7 @@ paths: #### Allowed For * Admins + operationId: UpdateAttribute responses: "200": description: Success response @@ -7040,9 +7278,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingAttributeUpdateResponseExample' delete: - operationId: DeleteAttribute tags: - - Skill Based Routing + - Skill Based Routing summary: Delete Attribute description: | Deletes an attribute. @@ -7050,17 +7287,17 @@ paths: #### Allowed For * Admins + operationId: DeleteAttribute responses: "204": description: No Content response - /api/v2/routing/attributes/{attribute_id}/values: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' + /v2/routing/attributes/{attributeId}/values: get: - operationId: ListAttributeValues tags: - - Skill Based Routing + - Skill Based Routing summary: List Attribute Values for an Attribute description: | Returns a list of attribute values for a provided attribute. @@ -7068,6 +7305,7 @@ paths: #### Allowed For * Admins + operationId: ListAttributeValues responses: "200": description: Success response @@ -7079,9 +7317,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValuesResponseExample' post: - operationId: CreateAttributeValue tags: - - Skill Based Routing + - Skill Based Routing summary: Create Attribute Value description: | Creates an attribute value. @@ -7089,6 +7326,7 @@ paths: #### Allowed For * Admins + operationId: CreateAttributeValue responses: "201": description: Created response @@ -7099,15 +7337,13 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValueCreateResponseExample' - /api/v2/routing/attributes/{attribute_id}/values/{attribute_value_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' - - $ref: '#/components/parameters/SkillBasedRoutingAttributeValueId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' + /v2/routing/attributes/{attributeId}/values/{attributeValueId}: get: - operationId: ShowAttributeValue tags: - - Skill Based Routing + - Skill Based Routing summary: Show Attribute Value description: | Returns an attribute value. @@ -7115,6 +7351,7 @@ paths: #### Allowed For * Admins + operationId: ShowAttributeValue responses: "200": description: Success response @@ -7125,10 +7362,23 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValueResponseExample' + delete: + tags: + - Skill Based Routing + summary: Delete Attribute Value + description: | + Deletes an attribute value. + + #### Allowed For + + * Agents + operationId: DeleteAttributeValue + responses: + "204": + description: No Content response patch: - operationId: UpdateAttributeValue tags: - - Skill Based Routing + - Skill Based Routing summary: Update Attribute Value description: | Updates an attribute value. @@ -7136,6 +7386,7 @@ paths: #### Allowed For * Admins + operationId: UpdateAttributeValue responses: "200": description: Success response @@ -7146,25 +7397,14 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeValueUpdateResponseExample' - delete: - operationId: DeleteAttributeValue - tags: - - Skill Based Routing - summary: Delete Attribute Value - description: | - Deletes an attribute value. - - #### Allowed For - - * Agents - responses: - "204": - description: No Content response - /api/v2/routing/attributes/definitions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SkillBasedRoutingAttributeId' + - $ref: '#/components/parameters/SkillBasedRoutingAttributeValueId' + /v2/routing/attributes/definitions: get: - operationId: ListRoutingAttributeDefinitions tags: - - Skill Based Routing + - Skill Based Routing summary: List Routing Attribute Definitions description: | Returns the condition definitions that can be configured to apply attributes to a ticket. @@ -7172,6 +7412,7 @@ paths: #### Allowed For * Admins + operationId: ListRoutingAttributeDefinitions responses: "200": description: Success response @@ -7182,11 +7423,10 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingAttributeDefinitionsExample' - /api/v2/routing/requirements/fulfilled: + /v2/routing/requirements/fulfilled: get: - operationId: ListTicketsFullfilledByUser tags: - - Skill Based Routing + - Skill Based Routing summary: List Tickets Fulfilled by a User description: | Returns a list of ticket ids that contain attributes matching the current user's attributes. Accepts a `ticket_ids` parameter for relevant tickets to check for matching attributes. @@ -7194,15 +7434,19 @@ paths: #### Allowed For * Agents and admins + operationId: ListTicketsFullfilledByUser parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ticket_ids - in: query - description: The IDs of the relevant tickets to check for matching attributes - required: true - schema: - type: integer - example: 1 + - $ref: '#/components/parameters/AcceptHeader' + - name: ticket_ids + in: query + description: The IDs of the relevant tickets to check for matching attributes + required: true + style: form + explode: true + schema: + type: integer + example: 1 + x-ballerina-name: ticketIds responses: "200": description: Success response @@ -7213,14 +7457,10 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingTicketFulfilledResponseExample' - /api/v2/routing/tickets/{ticket_id}/instance_values: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + /v2/routing/tickets/{ticketId}/instance_values: get: - operationId: ListTicketAttributeValues tags: - - Skill Based Routing + - Skill Based Routing summary: List Ticket Attribute Values description: | Returns a list of attributes values for the ticket. @@ -7228,6 +7468,7 @@ paths: #### Allowed For * Agents and admins + operationId: ListTicketAttributeValues responses: "200": description: Success response @@ -7239,9 +7480,8 @@ paths: default: $ref: '#/components/examples/SkillBasedRoutingTicketAttributesResponseExample' post: - operationId: SetTicketAttributeValues tags: - - Skill Based Routing + - Skill Based Routing summary: Set Ticket Attribute Values description: | Adds the specified attributes if no attributes exists, or replaces all existing attributes with the specified attributes. @@ -7251,6 +7491,7 @@ paths: #### Allowed For * Admins + operationId: SetTicketAttributeValues responses: "200": description: Success response @@ -7261,13 +7502,13 @@ paths: examples: default: $ref: '#/components/examples/SkillBasedRoutingTicketAttributesResponseExample' - /api/v2/satisfaction_ratings: parameters: - - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/satisfaction_ratings: get: - operationId: ListSatisfactionRatings tags: - - Satisfaction Ratings + - Satisfaction Ratings summary: List Satisfaction Ratings description: | #### Allowed For @@ -7295,6 +7536,7 @@ paths: * `/api/v2/satisfaction_ratings.json?score=bad` * `/api/v2/satisfaction_ratings.json?score=bad&start_time=1498151194` * `/api/v2/satisfaction_ratings.json?start_time=1340384793&end_time=1371920793` + operationId: ListSatisfactionRatings responses: "200": description: Success response @@ -7305,11 +7547,12 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionRatingsResponseExample' - /api/v2/satisfaction_ratings/{satisfaction_rating_id}: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + /v2/satisfaction_ratings/{satisfactionRatingId}: get: - operationId: ShowSatisfactionRating tags: - - Satisfaction Ratings + - Satisfaction Ratings summary: Show Satisfaction Rating description: | Returns a specific satisfaction rating. You can get the id from @@ -7318,15 +7561,18 @@ paths: #### Allowed For * Admins + operationId: ShowSatisfactionRating parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: satisfaction_rating_id - in: path - description: The id of the satisfaction rating to retrieve - required: true - schema: - type: integer - example: 35436 + - $ref: '#/components/parameters/AcceptHeader' + - name: satisfactionRatingId + in: path + description: The id of the satisfaction rating to retrieve + required: true + style: simple + explode: false + schema: + type: integer + example: 35436 responses: "200": description: Success response @@ -7337,11 +7583,10 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionRatingResponseExample' - /api/v2/satisfaction_ratings/count: + /v2/satisfaction_ratings/count: get: - operationId: CountSatisfactionRatings tags: - - Satisfaction Ratings + - Satisfaction Ratings summary: Count Satisfaction Ratings description: |- Returns an approximate count of satisfaction ratings in the account. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -7353,6 +7598,7 @@ paths: #### Allowed For * Agents + operationId: CountSatisfactionRatings responses: "200": description: Count of satisfaction ratings @@ -7363,11 +7609,10 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionRatingsCountResponseExample' - /api/v2/satisfaction_reasons: + /v2/satisfaction_reasons: get: - operationId: ListSatisfactionRatingReasons tags: - - Satisfaction Reasons + - Satisfaction Reasons summary: List Reasons for Satisfaction Rating description: | List all reasons for an account @@ -7375,6 +7620,7 @@ paths: #### Allowed For * Admins + operationId: ListSatisfactionRatingReasons responses: "200": description: Success response @@ -7385,25 +7631,27 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionReasonsResponseExample' - /api/v2/satisfaction_reasons/{satisfaction_reason_id}: + /v2/satisfaction_reasons/{satisfactionReasonId}: get: - operationId: ShowSatisfactionRatings tags: - - Satisfaction Reasons + - Satisfaction Reasons summary: Show Reason for Satisfaction Rating description: | #### Allowed For * Admins + operationId: ShowSatisfactionRatings parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: satisfaction_reason_id - in: path - description: The id of the satisfaction rating reason - required: true - schema: - type: integer - example: 35121 + - $ref: '#/components/parameters/AcceptHeader' + - name: satisfactionReasonId + in: path + description: The id of the satisfaction rating reason + required: true + style: simple + explode: false + schema: + type: integer + example: 35121 responses: "200": description: Success response @@ -7414,32 +7662,60 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionReasonResponseExample' - /api/v2/search: + /v2/search: get: - operationId: ListSearchResults tags: - - Search + - Search summary: List Search Results - description: "Use the ampersand character (&) to append the `sort_by` or `sort_order` parameters to the URL.\n\nFor examples, see [Searching with Zendesk API](/documentation/ticketing/using-the-zendesk-api/searching-with-the-zendesk-api).\n\n#### Pagination\n\n* Offset pagination only\n\nOffset pagination may result in duplicate results when paging. You can also use the \n[Export Search Results](/api-reference/ticketing/ticket-management/search/#export-search-results) endpoint, which \nuses cursor-based pagination and doesn't return duplicate results. See \n[Pagination](/api-reference/introduction/pagination/) for more information.\n\n#### Allowed For\n\n* Admins, Agents and Light Agents\n\n\n#### Errors JSON Format\n\nErrors are represented as JSON objects which have the following keys:\n\n| Name | Type | Comment\n| --------------------- | ---------------------| --------------------\n| error | string | The type of error. Examples: \"unavailable\", \"invalid\"\n| description | string |\n\n##### Example Error\n```js\n{\n \"error\": \"unavailable\",\n \"description\": \"Sorry, we could not complete your search query. Please try again in a moment.\"\n}\n```\n" + description: "Use the ampersand character (&) to append the `sort_by` or `sort_order`\ + \ parameters to the URL.\n\nFor examples, see [Searching with Zendesk API](/documentation/ticketing/using-the-zendesk-api/searching-with-the-zendesk-api).\n\ + \n#### Pagination\n\n* Offset pagination only\n\nOffset pagination may result\ + \ in duplicate results when paging. You can also use the \n[Export Search\ + \ Results](/api-reference/ticketing/ticket-management/search/#export-search-results)\ + \ endpoint, which \nuses cursor-based pagination and doesn't return duplicate\ + \ results. See \n[Pagination](/api-reference/introduction/pagination/) for\ + \ more information.\n\n#### Allowed For\n\n* Admins, Agents and Light Agents\n\ + \n\n#### Errors JSON Format\n\nErrors are represented as JSON objects which\ + \ have the following keys:\n\n| Name | Type \ + \ | Comment\n| --------------------- | ---------------------| --------------------\n\ + | error | string | The type of error. Examples:\ + \ \"unavailable\", \"invalid\"\n| description | string \ + \ |\n\n##### Example Error\n```js\n{\n \"error\": \"unavailable\",\n\ + \ \"description\": \"Sorry, we could not complete your search query. Please\ + \ try again in a moment.\"\n}\n```\n" + operationId: ListSearchResults parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) - required: true - schema: - type: string - example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket status:closed&sort_by=status&sort_order=desc - - name: sort_by - in: query - description: One of `updated_at`, `created_at`, `priority`, `status`, or `ticket_type`. Defaults to sorting by relevance - schema: - type: string - - name: sort_order - in: query - description: One of `asc` or `desc`. Defaults to `desc` - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: "The search query. See [Query basics](#query-basics) above. For\ + \ details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226)" + required: true + style: form + explode: true + schema: + type: string + example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket + status:closed&sort_by=status&sort_order=desc + - name: sort_by + in: query + description: "One of `updated_at`, `created_at`, `priority`, `status`, or\ + \ `ticket_type`. Defaults to sorting by relevance" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: One of `asc` or `desc`. Defaults to `desc` + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -7450,23 +7726,26 @@ paths: examples: default: $ref: '#/components/examples/SearchResponseExample' - /api/v2/search/count: + /v2/search/count: get: - operationId: CountSearchResults tags: - - Search + - Search summary: Show Results Count description: | Returns the number of items matching the query rather than the items. The search string works the same as a regular search. + operationId: CountSearchResults parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: The search query - required: true - schema: - type: string - example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket status:closed + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: The search query + required: true + style: form + explode: true + schema: + type: string + example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket + status:closed responses: "200": description: Success response @@ -7477,11 +7756,10 @@ paths: examples: default: $ref: '#/components/examples/SearchCountResponseExample' - /api/v2/search/export: + /v2/search/export: get: - operationId: ExportSearchResults tags: - - Search + - Search summary: Export Search Results description: | Exports a set of results. See [Query basics](#query-basics) for the syntax of the `query` parameter. @@ -7532,25 +7810,39 @@ paths: * `meta` - Has the following nested properties: `has_more` and `after_cursor`. The `has_more` property indicates whether the next page has more results. The `after_cursor` property is the cursor used to paginate to the next page. It expires after one hour. There's no `count` property. + operationId: ExportSearchResults parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: The search query. See [Query basics](#query-basics) above. For details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226) - required: true - schema: - type: string - example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket status:closed&sort_by=status&sort_order=desc - - name: page[size] - in: query - description: The number of results shown in a page. - schema: - type: integer - - name: filter[type] - in: query - description: The object type returned by the export query. Can be `ticket`, `organization`, `user`, or `group`. - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: "The search query. See [Query basics](#query-basics) above. For\ + \ details on the query syntax, see the [Zendesk Support search reference](https://support.zendesk.com/hc/en-us/articles/203663226)" + required: true + style: form + explode: true + schema: + type: string + example: https://subdomain.zendesk.com/api/v2/search.json?query=type:ticket + status:closed&sort_by=status&sort_order=desc + - name: "page[size]" + in: query + description: The number of results shown in a page + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: pageSize + - name: "filter[type]" + in: query + description: "The object type returned by the export query. Can be `ticket`,\ + \ `organization`, `user`, or `group`" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: filterType responses: "200": description: Success response @@ -7561,14 +7853,10 @@ paths: examples: default: $ref: '#/components/examples/SearchExportResponseExample' - /api/v2/sessions: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + /v2/sessions: get: - operationId: ListSessions tags: - - Sessions + - Sessions summary: List Sessions description: | If authenticated as an admin, returns all the account's sessions. If authenticated as an agent or end user, returns only the sessions of the user making the request. @@ -7583,6 +7871,7 @@ paths: #### Allowed For * Admins, Agents, End users + operationId: ListSessions responses: "200": description: Success response @@ -7593,16 +7882,19 @@ paths: examples: default: $ref: '#/components/examples/SessionsResponseExample' - /api/v2/sharing_agreements: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/sharing_agreements: get: - operationId: ListSharingAgreements tags: - - Sharing Agreements + - Sharing Agreements summary: List Sharing Agreements description: | #### Allowed For * Agents + operationId: ListSharingAgreements responses: "200": description: Success response @@ -7614,14 +7906,14 @@ paths: default: $ref: '#/components/examples/SharingAgreementsResponseExample' post: - operationId: CreateSharingAgreement tags: - - Sharing Agreements + - Sharing Agreements summary: Create Sharing Agreement description: | #### Allowed For * Admins + operationId: CreateSharingAgreement responses: "201": description: Created response @@ -7632,14 +7924,10 @@ paths: examples: default: $ref: '#/components/examples/SharingAgreementResponseExample' - /api/v2/sharing_agreements/{sharing_agreement_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SharingAgreementId' + /v2/sharing_agreements/{sharingAgreementId}: get: - operationId: ShowSharingAgreement tags: - - Sharing Agreements + - Sharing Agreements summary: Show a Sharing Agreement description: | Returns a sharing agreement for your account. @@ -7647,6 +7935,7 @@ paths: #### Allowed For * Agents + operationId: ShowSharingAgreement responses: "200": description: Success response @@ -7658,9 +7947,8 @@ paths: default: $ref: '#/components/examples/SharingAgreementResponseExample' put: - operationId: UpdateSharingAgreement tags: - - Sharing Agreements + - Sharing Agreements summary: Update a Sharing Agreement description: | Returns an updated sharing agreement. Only `status` is allowed to be updated. @@ -7668,6 +7956,7 @@ paths: #### Allowed For * Admins + operationId: UpdateSharingAgreement responses: "200": description: Success response @@ -7679,9 +7968,8 @@ paths: default: $ref: '#/components/examples/SharingAgreementUpdateResponseExample' delete: - operationId: DeleteSharingAgreement tags: - - Sharing Agreements + - Sharing Agreements summary: Delete a Sharing Agreement description: | Deletes a sharing agreement. @@ -7689,14 +7977,17 @@ paths: #### Allowed For * Admins + operationId: DeleteSharingAgreement responses: "204": description: No Content response - /api/v2/skips: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SharingAgreementId' + /v2/skips: post: - operationId: RecordNewSkip tags: - - Ticket Skips + - Ticket Skips summary: Record a New Skip for the Current User description: | Record a new ticket skip for the current user. @@ -7704,6 +7995,7 @@ paths: #### Allowed For * Agents + operationId: RecordNewSkip responses: "201": description: Success response @@ -7714,11 +8006,10 @@ paths: examples: default: $ref: '#/components/examples/TicketSkipCreationExample' - /api/v2/slas/policies: + /v2/slas/policies: get: - operationId: ListSLAPolicies tags: - - SLA Policies + - SLA Policies summary: List SLA Policies description: | #### Availability @@ -7728,6 +8019,7 @@ paths: #### Allowed For * Admins + operationId: ListSLAPolicies responses: "200": description: Success response @@ -7739,9 +8031,8 @@ paths: default: $ref: '#/components/examples/SLAPoliciesResponseExample' post: - operationId: CreateSLAPolicy tags: - - SLA Policies + - SLA Policies summary: Create SLA Policy description: | #### Availability @@ -7751,6 +8042,7 @@ paths: #### Allowed For * Admins + operationId: CreateSLAPolicy responses: "201": description: Created response @@ -7761,14 +8053,10 @@ paths: examples: default: $ref: '#/components/examples/SLAPolicyCreateResponse' - /api/v2/slas/policies/{sla_policy_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SLAPolicyId' + /v2/slas/policies/{slaPolicyId}: get: - operationId: ShowSLAPolicy tags: - - SLA Policies + - SLA Policies summary: Show SLA Policy description: | #### Availability @@ -7778,6 +8066,7 @@ paths: #### Allowed For * Admins + operationId: ShowSLAPolicy responses: "200": description: Success response @@ -7789,9 +8078,8 @@ paths: default: $ref: '#/components/examples/SLAPolicyResponseExample' put: - operationId: UpdateSLAPolicy tags: - - SLA Policies + - SLA Policies summary: Update SLA Policy description: | Updates the specified policy. @@ -7803,6 +8091,7 @@ paths: #### Allowed For * Admins + operationId: UpdateSLAPolicy responses: "200": description: Success response @@ -7814,9 +8103,8 @@ paths: default: $ref: '#/components/examples/SLAPolicyUpdateResponse' delete: - operationId: DeleteSLAPolicy tags: - - SLA Policies + - SLA Policies summary: Delete SLA Policy description: | #### Availability @@ -7826,14 +8114,17 @@ paths: #### Allowed For * Admins + operationId: DeleteSLAPolicy responses: "204": description: No Content response - /api/v2/slas/policies/definitions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SLAPolicyId' + /v2/slas/policies/definitions: get: - operationId: RetrieveSLAPolicyFilterDefinitionItems tags: - - SLA Policies + - SLA Policies summary: Retrieve Supported Filter Definition Items description: | #### Availability @@ -7843,6 +8134,7 @@ paths: #### Allowed For * Admins + operationId: RetrieveSLAPolicyFilterDefinitionItems responses: "200": description: Success response @@ -7853,11 +8145,10 @@ paths: examples: default: $ref: '#/components/examples/SLAPolicyFilterDefinitionResponseExample' - /api/v2/slas/policies/reorder: + /v2/slas/policies/reorder: put: - operationId: ReorderSLAPolicies tags: - - SLA Policies + - SLA Policies summary: Reorder SLA Policies description: | #### Availability @@ -7867,15 +8158,20 @@ paths: #### Allowed For * Admins + operationId: ReorderSLAPolicies parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: sla_policy_ids - in: query - description: The IDs of the SLA Policies to reorder - schema: - type: array - items: - type: integer + - $ref: '#/components/parameters/AcceptHeader' + - name: sla_policy_ids + in: query + description: The IDs of the SLA Policies to reorder + required: false + style: form + explode: true + schema: + type: array + items: + type: integer + x-ballerina-name: slaPolicyIds responses: "200": description: Success response @@ -7886,15 +8182,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/suspended_tickets: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketsSortBy' - - $ref: '#/components/parameters/SuspendedTicketsSortOrder' + /v2/suspended_tickets: get: - operationId: ListSuspendedTickets tags: - - Suspended Tickets + - Suspended Tickets summary: List Suspended Tickets description: | #### Allowed For @@ -7911,6 +8202,7 @@ paths: * Cursor pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListSuspendedTickets responses: "200": description: Success response @@ -7921,20 +8213,24 @@ paths: examples: default: $ref: '#/components/examples/SuspendedTicketsResponseExample' - /api/v2/suspended_tickets/{id}: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketsSortBy' + - $ref: '#/components/parameters/SuspendedTicketsSortOrder' + /v2/suspended_tickets/{id}: get: - operationId: ShowSuspendedTickets tags: - - Suspended Tickets + - Suspended Tickets summary: Show Suspended Ticket description: | #### Allowed For * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage suspended tickets on Enterprise plans * Unrestricted agents on all other plans + operationId: ShowSuspendedTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketId' responses: "200": description: Success response @@ -7946,25 +8242,24 @@ paths: default: $ref: '#/components/examples/SuspendedTicketsResponseExample' delete: - operationId: DeleteSuspendedTicket tags: - - Suspended Tickets + - Suspended Tickets summary: Delete Suspended Ticket description: | #### Allowed For * Unrestricted agents + operationId: DeleteSuspendedTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketId' responses: "204": description: No Content response - /api/v2/suspended_tickets/{id}/recover: + /v2/suspended_tickets/{id}/recover: put: - operationId: RecoverSuspendedTicket tags: - - Suspended Tickets + - Suspended Tickets summary: Recover Suspended Ticket description: | **Note**: During recovery, the API sets the requester to the authenticated agent who called the API, not the original requester. This prevents the ticket from being re-suspended after recovery. To preserve the original requester, use the [Recover Multiple Suspended Tickets](#recover-multiple-suspended-tickets) endpoint with the single ticket. @@ -7978,9 +8273,10 @@ paths: * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage suspended tickets on Enterprise plans * Unrestricted agents on all other plans + operationId: RecoverSuspendedTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketId' responses: "200": description: Success response @@ -8000,14 +8296,10 @@ paths: examples: default: $ref: '#/components/examples/RecoverSuspendedTicketUnprocessableContentResponseExample' - /api/v2/suspended_tickets/attachments: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketId' + /v2/suspended_tickets/attachments: post: - operationId: SuspendedTicketsAttachments tags: - - Suspended Tickets + - Suspended Tickets summary: Suspended Ticket Attachments description: | Makes copies of any attachments on a suspended ticket and returns them as [attachment tokens](/api-reference/ticketing/tickets/ticket-attachments/). If the ticket is manually recovered, you can include the attachment tokens on the new ticket. @@ -8016,6 +8308,7 @@ paths: * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage suspended tickets on Enterprise plans * Unrestricted agents on all other plans + operationId: SuspendedTicketsAttachments responses: "200": description: Success response @@ -8026,14 +8319,13 @@ paths: examples: default: $ref: '#/components/examples/SuspendedTicketsAttachmentsResponseExample' - /api/v2/suspended_tickets/destroy_many: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketsDeleteIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketId' + /v2/suspended_tickets/destroy_many: delete: - operationId: DeleteSuspendedTickets tags: - - Suspended Tickets + - Suspended Tickets summary: Delete Multiple Suspended Tickets description: | Accepts up to 100 ids (the auto-generated id, not the ticket id.) @@ -8042,14 +8334,17 @@ paths: * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage suspended tickets on Enterprise plans * Unrestricted agents on all other plans + operationId: DeleteSuspendedTickets responses: "204": description: No Content response - /api/v2/suspended_tickets/export: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketsDeleteIds' + /v2/suspended_tickets/export: post: - operationId: ExportSuspendedTickets tags: - - Suspended Tickets + - Suspended Tickets summary: Export Suspended Tickets description: | Exports a list of suspended tickets for the Zendesk Support instance. To export the list, the endpoint enqueues a job to create a CSV file with the data. When done, Zendesk sends the requester an email containing a link to the CSV file. In the CSV, tickets are sorted by the update timestamp in ascending order. @@ -8063,6 +8358,7 @@ paths: Limited to one request per minute and up to one million records in return. The rate-limiting mechanism behaves identically to the one described in [Usage limits](/api-reference/ticketing/account-configuration/usage_limits/#monitoring-your-request-activity). We recommend using the `Retry-After` header value as described in [Catching errors caused by rate limiting](/documentation/ticketing/using-the-zendesk-api/best-practices-for-avoiding-rate-limiting#catch). + operationId: ExportSuspendedTickets responses: "200": description: Ok @@ -8073,14 +8369,10 @@ paths: examples: default: $ref: '#/components/examples/SuspendedTicketsExportResponseExample' - /api/v2/suspended_tickets/recover_many: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SuspendedTicketsRecoverIds' + /v2/suspended_tickets/recover_many: put: - operationId: RecoverSuspendedTickets tags: - - Suspended Tickets + - Suspended Tickets summary: Recover Multiple Suspended Tickets description: | Accepts up to 100 ids (the auto-generated id, not the ticket id.) Note that suspended tickets that fail to be recovered are still included in the response. @@ -8089,6 +8381,7 @@ paths: * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage suspended tickets on Enterprise plans * Unrestricted agents on all other plans + operationId: RecoverSuspendedTickets responses: "200": description: Success response @@ -8099,11 +8392,13 @@ paths: examples: default: $ref: '#/components/examples/RecoverSuspendedTicketsResponseExample' - /api/v2/tags: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SuspendedTicketsRecoverIds' + /v2/tags: get: - operationId: ListTags tags: - - Tags + - Tags summary: List Tags description: | Lists up to the 20,000 most popular tags in the last 60 days, in decreasing popularity. @@ -8120,6 +8415,7 @@ paths: #### Allowed For * Agents + operationId: ListTags responses: "200": description: Success response @@ -8130,11 +8426,10 @@ paths: examples: default: $ref: '#/components/examples/TagsResponseExample' - /api/v2/tags/count: + /v2/tags/count: get: - operationId: CountTags tags: - - Tags + - Tags summary: Count Tags description: | Returns an approximate count of tags. If the count exceeds 100,000, it @@ -8151,6 +8446,7 @@ paths: #### Allowed For * Admins + operationId: CountTags responses: "200": description: Success response @@ -8161,11 +8457,10 @@ paths: examples: default: $ref: '#/components/examples/TagCountResponseExample' - /api/v2/target_failures: + /v2/target_failures: get: - operationId: ListTargetFailures tags: - - Target Failures + - Target Failures summary: List Target Failures description: | Returns the 25 most recent target failures, per target. @@ -8177,6 +8472,7 @@ paths: #### Allowed For * Admins + operationId: ListTargetFailures responses: "200": description: Success response @@ -8187,14 +8483,10 @@ paths: examples: default: $ref: '#/components/examples/TargetFailuresResponseExample' - /api/v2/target_failures/{target_failure_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TargetFailureId' + /v2/target_failures/{targetFailureId}: get: - operationId: ShowTargetFailure tags: - - Target Failures + - Target Failures summary: Show Target Failure description: | #### Stability @@ -8204,6 +8496,7 @@ paths: #### Allowed For * Admins + operationId: ShowTargetFailure responses: "200": description: Success response @@ -8214,16 +8507,19 @@ paths: examples: default: $ref: '#/components/examples/TargetFailureResponseExample' - /api/v2/targets: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TargetFailureId' + /v2/targets: get: - operationId: ListTargets tags: - - Targets + - Targets summary: List Targets description: | #### Allowed For * Agents + operationId: ListTargets responses: "200": description: Success response @@ -8235,14 +8531,14 @@ paths: default: $ref: '#/components/examples/TargetsResponseExample' post: - operationId: CreateTarget tags: - - Targets + - Targets summary: Create Target description: | #### Allowed For * Admins + operationId: CreateTarget responses: "201": description: Created response @@ -8253,19 +8549,16 @@ paths: examples: default: $ref: '#/components/examples/TargetCreateResponseExample' - /api/v2/targets/{target_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TargetId' + /v2/targets/{targetId}: get: - operationId: ShowTarget tags: - - Targets + - Targets summary: Show Target description: | #### Allowed For * Agents + operationId: ShowTarget responses: "200": description: Success response @@ -8277,13 +8570,13 @@ paths: default: $ref: '#/components/examples/TargetResponseExample' put: - operationId: UpdateTarget tags: - - Targets + - Targets summary: Update Target description: | #### Allowed For * Admins + operationId: UpdateTarget responses: "200": description: Success response @@ -8295,30 +8588,44 @@ paths: default: $ref: '#/components/examples/TargetUpdateResponseExample' delete: - operationId: DeleteTarget tags: - - Targets + - Targets summary: Delete Target description: | #### Allowed For * Admins + operationId: DeleteTarget responses: "204": description: No Content response - /api/v2/ticket_audits: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TargetId' + /v2/ticket_audits: get: - operationId: ListTicketAudits tags: - - Ticket Audits + - Ticket Audits summary: List All Ticket Audits - description: "Returns ticket audits. Archived tickets are not included in the response. Use the [List Audits for a Ticket](#list-audits-for-a-ticket) endpoint to \nretrieve audit records for an archived ticket. To learn more about archived tickets, see [About archived tickets](https://support.zendesk.com/hc/en-us/articles/203657756).\n\nThis endpoint should not be used for capturing change data. When continually chasing the tail of a cursor, some records will be skipped. For this use case, use the [Incremental Ticket Event Export API](/api-reference/ticketing/ticket-management/incremental_exports/#incremental-ticket-event-export).\n\n#### Pagination\n\n- Cursor pagination\n\nSee [Pagination](/api-reference/introduction/pagination/).\n\nReturns a maximum of 100 records per page.\n\n#### Allowed For\n\n* Admins\n" + description: "Returns ticket audits. Archived tickets are not included in the\ + \ response. Use the [List Audits for a Ticket](#list-audits-for-a-ticket)\ + \ endpoint to \nretrieve audit records for an archived ticket. To learn more\ + \ about archived tickets, see [About archived tickets](https://support.zendesk.com/hc/en-us/articles/203657756).\n\ + \nThis endpoint should not be used for capturing change data. When continually\ + \ chasing the tail of a cursor, some records will be skipped. For this use\ + \ case, use the [Incremental Ticket Event Export API](/api-reference/ticketing/ticket-management/incremental_exports/#incremental-ticket-event-export).\n\ + \n#### Pagination\n\n- Cursor pagination\n\nSee [Pagination](/api-reference/introduction/pagination/).\n\ + \nReturns a maximum of 100 records per page.\n\n#### Allowed For\n\n* Admins\n" + operationId: ListTicketAudits parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: limit - in: query - description: Maximum number of results returned - schema: - type: integer + - $ref: '#/components/parameters/AcceptHeader' + - name: limit + in: query + description: Maximum number of results returned + required: false + style: form + explode: true + schema: + type: integer responses: "200": description: Success response @@ -8329,11 +8636,10 @@ paths: examples: default: $ref: '#/components/examples/TicketAuditsResponseExample' - /api/v2/ticket_fields: + /v2/ticket_fields: get: - operationId: ListTicketFields tags: - - Ticket Fields + - Ticket Fields summary: List Ticket Fields description: | Returns a list of all system and custom ticket fields in your account. @@ -8366,24 +8672,31 @@ paths: #### Allowed For * Agents + operationId: ListTicketFields parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: locale - in: query - description: | - Forces the `title_in_portal` property to return a dynamic content variant for the specified locale. - Only accepts [active locale ids](/api-reference/ticketing/account-configuration/locales/#list-locales). - Example: `locale="de"`. - schema: - type: string - - name: creator - in: query - description: | - Displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created - by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field - is not created by an app, `creator_app_name` is null - schema: - type: boolean + - $ref: '#/components/parameters/AcceptHeader' + - name: locale + in: query + description: | + Forces the `title_in_portal` property to return a dynamic content variant for the specified locale. + Only accepts [active locale ids](/api-reference/ticketing/account-configuration/locales/#list-locales). + Example: `locale="de"` + required: false + style: form + explode: true + schema: + type: string + - name: creator + in: query + description: | + Displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created + by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field + is not created by an app, `creator_app_name` is null + required: false + style: form + explode: true + schema: + type: boolean responses: "200": description: Success response @@ -8395,9 +8708,8 @@ paths: default: $ref: '#/components/examples/TicketFieldsResponseExample' post: - operationId: CreateTicketField tags: - - Ticket Fields + - Ticket Fields summary: Create Ticket Field description: | Creates any of the following custom field types: @@ -8428,6 +8740,7 @@ paths: * 400 ticket fields per account if your account doesn't have ticket forms * 400 ticket fields per ticket form if your account has ticket forms + operationId: CreateTicketField responses: "201": description: Created response @@ -8438,15 +8751,10 @@ paths: examples: default: $ref: '#/components/examples/TicketFieldResponseExample' - /api/v2/ticket_fields/{ticket_field_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketFieldId' - - $ref: '#/components/parameters/Creator' + /v2/ticket_fields/{ticketFieldId}: get: - operationId: ShowTicketfield tags: - - Ticket Fields + - Ticket Fields summary: Show Ticket Field description: | #### Allowed for @@ -8460,6 +8768,7 @@ paths: | Name | Will sideload | ---------------- | ------------- | users | The user or users that created the ticket field + operationId: ShowTicketfield responses: "200": description: Success response @@ -8471,9 +8780,8 @@ paths: default: $ref: '#/components/examples/TicketFieldResponseExample' put: - operationId: UpdateTicketField tags: - - Ticket Fields + - Ticket Fields summary: Update Ticket Field description: | #### Updating drop-down field options @@ -8531,6 +8839,7 @@ paths: #### Allowed for * Admins + operationId: UpdateTicketField responses: "200": description: Success response @@ -8542,25 +8851,25 @@ paths: default: $ref: '#/components/examples/TicketFieldUpdateResponseExample' delete: - operationId: DeleteTicketField tags: - - Ticket Fields + - Ticket Fields summary: Delete Ticket Field description: | #### Allowed for * Admins + operationId: DeleteTicketField responses: "204": description: No Content response - /api/v2/ticket_fields/{ticket_field_id}/options: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketFieldId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketFieldId' + - $ref: '#/components/parameters/Creator' + /v2/ticket_fields/{ticketFieldId}/options: get: - operationId: ListTicketFieldOptions tags: - - Ticket Fields + - Ticket Fields summary: List Ticket Field Options description: | Returns a list of custom ticket field options for the given drop-down ticket field. @@ -8575,6 +8884,7 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListTicketFieldOptions responses: "200": description: Success response @@ -8586,9 +8896,8 @@ paths: default: $ref: '#/components/examples/CustomTicketFieldOptionsResponseExample' post: - operationId: CreateOrUpdateTicketFieldOption tags: - - Ticket Fields + - Ticket Fields summary: Create or Update Ticket Field Option description: | Creates or updates an option for the given drop-down ticket field. @@ -8618,6 +8927,7 @@ paths: #### Field Option Limits * 2000 options per ticket field + operationId: CreateOrUpdateTicketFieldOption responses: "200": description: Success response @@ -8637,19 +8947,18 @@ paths: examples: default: $ref: '#/components/examples/CustomTicketFieldOptionCreateResponseExample' - /api/v2/ticket_fields/{ticket_field_id}/options/{ticket_field_option_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketFieldId' - - $ref: '#/components/parameters/TicketFieldOptionId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketFieldId' + /v2/ticket_fields/{ticketFieldId}/options/{ticketFieldOptionId}: get: - operationId: ShowTicketFieldOption tags: - - Ticket Fields + - Ticket Fields summary: Show Ticket Field Option description: | #### Allowed for * Agents + operationId: ShowTicketFieldOption responses: "200": description: Success response @@ -8661,21 +8970,24 @@ paths: default: $ref: '#/components/examples/CustomTicketFieldOptionResponseExample' delete: - operationId: DeleteTicketFieldOption tags: - - Ticket Fields + - Ticket Fields summary: Delete Ticket Field Option description: | #### Allowed for * Admins + operationId: DeleteTicketFieldOption responses: "204": description: No Content response - /api/v2/ticket_fields/count: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketFieldId' + - $ref: '#/components/parameters/TicketFieldOptionId' + /v2/ticket_fields/count: get: - operationId: CountTicketFields tags: - - Ticket Fields + - Ticket Fields summary: Count Ticket Fields description: |- Returns an approximate count of system and custom ticket fields in the account. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -8687,6 +8999,7 @@ paths: #### Allowed For * Agents + operationId: CountTicketFields responses: "200": description: Count of ticket fields @@ -8697,11 +9010,10 @@ paths: examples: default: $ref: '#/components/examples/TicketFieldCountResponseExample' - /api/v2/ticket_forms: + /v2/ticket_forms: get: - operationId: ListTicketForms tags: - - Ticket Forms + - Ticket Forms summary: List Ticket Forms description: | Returns a list of all ticket forms for your account if accessed as an admin or agent. End users only see ticket forms that have `end_user_visible` set to true. @@ -8709,28 +9021,49 @@ paths: #### Allowed For * Anyone + operationId: ListTicketForms parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: active - in: query - description: true returns active ticket forms; false returns inactive ticket forms. If not present, returns both - schema: - type: boolean - - name: end_user_visible - in: query - description: true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both - schema: - type: boolean - - name: fallback_to_default - in: query - description: true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms - schema: - type: boolean - - name: associated_to_brand - in: query - description: true returns the ticket forms of the brand specified by the url's subdomain - schema: - type: boolean + - $ref: '#/components/parameters/AcceptHeader' + - name: active + in: query + description: "true returns active ticket forms; false returns inactive ticket\ + \ forms. If not present, returns both" + required: false + style: form + explode: true + schema: + type: boolean + - name: end_user_visible + in: query + description: "true returns ticket forms where `end_user_visible`; false returns\ + \ ticket forms that are not end-user visible. If not present, returns both" + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: endUserVisible + - name: fallback_to_default + in: query + description: true returns the default ticket form when the criteria defined + by the parameters results in a set without active and end-user visible ticket + forms + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: fallbackToDefault + - name: associated_to_brand + in: query + description: true returns the ticket forms of the brand specified by the url's + subdomain + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: associatedToBrand responses: "200": description: Success response @@ -8742,14 +9075,14 @@ paths: default: $ref: '#/components/examples/TicketFormsResponseExample' post: - operationId: CreateTicketForm tags: - - Ticket Forms + - Ticket Forms summary: Create Ticket Form description: | #### Allowed For * Admins + operationId: CreateTicketForm responses: "201": description: Created response @@ -8760,19 +9093,16 @@ paths: examples: default: $ref: '#/components/examples/TicketFormCreateResponseExample' - /api/v2/ticket_forms/{ticket_form_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketFormId' + /v2/ticket_forms/{ticketFormId}: get: - operationId: ShowTicketForm tags: - - Ticket Forms + - Ticket Forms summary: Show Ticket Form description: | #### Allowed For * Admins, Agents, and End Users + operationId: ShowTicketForm responses: "200": description: Success response @@ -8784,13 +9114,13 @@ paths: default: $ref: '#/components/examples/TicketFormResponseExample' put: - operationId: UpdateTicketForm tags: - - Ticket Forms + - Ticket Forms summary: Update Ticket Form description: | #### Allowed For * Admins + operationId: UpdateTicketForm responses: "200": description: Success response @@ -8802,29 +9132,29 @@ paths: default: $ref: '#/components/examples/TicketFormUpdateResponseExample' delete: - operationId: DeleteTicketForm tags: - - Ticket Forms + - Ticket Forms summary: Delete Ticket Form description: | #### Allowed For * Admins + operationId: DeleteTicketForm responses: "204": description: No Content response - /api/v2/ticket_forms/{ticket_form_id}/clone: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketFormId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketFormId' + /v2/ticket_forms/{ticketFormId}/clone: post: - operationId: CloneTicketForm tags: - - Ticket Forms + - Ticket Forms summary: Clone an Already Existing Ticket Form description: | #### Allowed For * Admins + operationId: CloneTicketForm responses: "200": description: Success response @@ -8835,11 +9165,13 @@ paths: examples: default: $ref: '#/components/examples/TicketFormResponseExample' - /api/v2/ticket_forms/reorder: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketFormId' + /v2/ticket_forms/reorder: put: - operationId: ReorderTicketForms tags: - - Ticket Forms + - Ticket Forms summary: Reorder Ticket Forms description: | #### Allowed For @@ -8852,6 +9184,7 @@ paths: | Name | Type | Comment | ------------------- | ------ | -------- | ticket_form_ids | array | An array of ticket form ids. Example: "[2, 23, 46, 50]" + operationId: ReorderTicketForms responses: "200": description: Success response @@ -8862,11 +9195,10 @@ paths: examples: default: $ref: '#/components/examples/TicketFormsResponseExample' - /api/v2/ticket_forms/show_many: + /v2/ticket_forms/show_many: get: - operationId: ShowManyTicketForms tags: - - Ticket Forms + - Ticket Forms summary: Show Many Ticket Forms description: | Takes an `ids` query parameter that accepts a comma-separated list of up to 100 ticket form ids. This endpoint is used primarily by the [mobile SDK](/documentation/classic-web-widget-sdks/) and the [Web Widget](/api-reference/widget/introduction/). @@ -8874,35 +9206,58 @@ paths: #### Allowed For * Anyone + operationId: ShowManyTicketForms parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: IDs of the ticket forms to be shown - required: true - schema: - type: string - example: 1,2,3 - - name: active - in: query - description: true returns active ticket forms; false returns inactive ticket forms. If not present, returns both - schema: - type: boolean - - name: end_user_visible - in: query - description: true returns ticket forms where `end_user_visible`; false returns ticket forms that are not end-user visible. If not present, returns both - schema: - type: boolean - - name: fallback_to_default - in: query - description: true returns the default ticket form when the criteria defined by the parameters results in a set without active and end-user visible ticket forms - schema: - type: boolean - - name: associated_to_brand - in: query - description: true returns the ticket forms of the brand specified by the url's subdomain - schema: - type: boolean + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: IDs of the ticket forms to be shown + required: true + style: form + explode: true + schema: + type: string + example: "1,2,3" + - name: active + in: query + description: "true returns active ticket forms; false returns inactive ticket\ + \ forms. If not present, returns both" + required: false + style: form + explode: true + schema: + type: boolean + - name: end_user_visible + in: query + description: "true returns ticket forms where `end_user_visible`; false returns\ + \ ticket forms that are not end-user visible. If not present, returns both" + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: endUserVisible + - name: fallback_to_default + in: query + description: true returns the default ticket form when the criteria defined + by the parameters results in a set without active and end-user visible ticket + forms + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: fallbackToDefault + - name: associated_to_brand + in: query + description: true returns the ticket forms of the brand specified by the url's + subdomain + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: associatedToBrand responses: "200": description: Success response @@ -8913,11 +9268,10 @@ paths: examples: default: $ref: '#/components/examples/TicketFormsResponseExample' - /api/v2/ticket_metrics: + /v2/ticket_metrics: get: - operationId: ListTicketMetrics tags: - - Ticket Metrics + - Ticket Metrics summary: List Ticket Metrics description: | Returns a list of tickets with their metrics. @@ -8943,6 +9297,7 @@ paths: #### Allowed For * Agents + operationId: ListTicketMetrics responses: "200": description: Success response @@ -8953,11 +9308,10 @@ paths: examples: default: $ref: '#/components/examples/TicketMetricsResponseExample' - /api/v2/ticket_metrics/{ticket_metric_id}: + /v2/ticket_metrics/{ticketMetricId}: get: - operationId: ShowTicketMetrics tags: - - Ticket Metrics + - Ticket Metrics summary: Show Ticket Metrics description: | Returns a specific metric, or the metrics of a specific ticket. @@ -8974,15 +9328,18 @@ paths: #### Allowed For * Agents + operationId: ShowTicketMetrics parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ticket_metric_id - in: path - description: The id of the ticket metric to retrieve - required: true - schema: - type: string - example: "10001" + - $ref: '#/components/parameters/AcceptHeader' + - name: ticketMetricId + in: path + description: The id of the ticket metric to retrieve + required: true + style: simple + explode: false + schema: + type: string + example: "10001" responses: "200": description: Success response @@ -8993,19 +9350,25 @@ paths: examples: default: $ref: '#/components/examples/TicketMetricResponseExample' - /api/v2/tickets: + /v2/tickets: get: - operationId: ListTickets tags: - - Tickets + - Tickets summary: List Tickets + operationId: ListTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: external_id - in: query - description: Lists tickets by external id. External ids don't have to be unique for each ticket. As a result, the request may return multiple tickets with the same external id. - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: external_id + in: query + description: "Lists tickets by external id. External ids don't have to be\ + \ unique for each ticket. As a result, the request may return multiple tickets\ + \ with the same external id" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: externalId responses: "200": description: List tickets @@ -9017,10 +9380,10 @@ paths: default: $ref: '#/components/examples/TicketsResponseExample' post: - operationId: CreateTicket tags: - - Tickets + - Tickets summary: Create Ticket + operationId: CreateTicket requestBody: content: application/json: @@ -9035,6 +9398,8 @@ paths: headers: Location: description: The URL of the created ticket + style: simple + explode: false schema: type: string format: url @@ -9045,20 +9410,20 @@ paths: examples: default: $ref: '#/components/examples/TicketResponseExample' - /api/v2/tickets/{ticket_id}: + /v2/tickets/{ticketId}: get: - operationId: ShowTicket tags: - - Tickets + - Tickets summary: Show Ticket description: |- Returns a number of ticket properties though not the ticket comments. To get the comments, use [List Comments](/api-reference/ticketing/tickets/ticket_comments/#list-comments) #### Allowed For * Agents + operationId: ShowTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Ticket @@ -9070,13 +9435,13 @@ paths: default: $ref: '#/components/examples/TicketResponseExample' put: - operationId: UpdateTicket tags: - - Tickets + - Tickets summary: Update Ticket + operationId: UpdateTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' requestBody: content: application/json: @@ -9096,9 +9461,8 @@ paths: default: $ref: '#/components/examples/TicketUpdateResponseExample' delete: - operationId: DeleteTicket tags: - - Tickets + - Tickets summary: Delete Ticket description: |- #### Allowed For @@ -9117,20 +9481,17 @@ paths: [Rate limits](/api-reference/introduction/rate-limits/) in the API introduction. Zendesk recommends that you obey the Retry-After header values. To delete many tickets, you may use [Bulk Delete Tickets](/api-reference/ticketing/tickets/tickets/#bulk-delete-tickets). + operationId: DeleteTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "204": description: No content - /api/v2/tickets/{ticket_id}/audits: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + /v2/tickets/{ticketId}/audits: get: - operationId: ListAuditsForTicket tags: - - Ticket Audits + - Ticket Audits summary: List Audits for a Ticket description: | Lists the audits for a specified ticket. @@ -9149,6 +9510,7 @@ paths: #### Allowed for * Agents + operationId: ListAuditsForTicket responses: "200": description: OK response @@ -9159,20 +9521,19 @@ paths: examples: default: $ref: '#/components/examples/TicketAuditsForTicketResponseExample' - /api/v2/tickets/{ticket_id}/audits/{ticket_audit_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' - - $ref: '#/components/parameters/TicketAuditId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/tickets/{ticketId}/audits/{ticketAuditId}: get: - operationId: ShowTicketAudit tags: - - Ticket Audits + - Ticket Audits summary: Show Audit description: | #### Allowed for * Agents + operationId: ShowTicketAudit responses: "200": description: OK response @@ -9183,20 +9544,20 @@ paths: examples: default: $ref: '#/components/examples/TicketAuditResponseExample' - /api/v2/tickets/{ticket_id}/audits/{ticket_audit_id}/make_private: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' - - $ref: '#/components/parameters/TicketAuditId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/TicketAuditId' + /v2/tickets/{ticketId}/audits/{ticketAuditId}/make_private: put: - operationId: MakeTicketCommentPrivateFromAudits tags: - - Ticket Audits + - Ticket Audits summary: Change a Comment From Public To Private description: | #### Allowed for * Agents + operationId: MakeTicketCommentPrivateFromAudits responses: "200": description: description @@ -9207,14 +9568,14 @@ paths: description: Empty response example: "" example: "" - /api/v2/tickets/{ticket_id}/audits/count: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/TicketAuditId' + /v2/tickets/{ticketId}/audits/count: get: - operationId: CountAuditsForTicket tags: - - Ticket Audits + - Ticket Audits summary: Count Audits for a Ticket description: | Returns an approximate count of audits for a specified ticket. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -9227,6 +9588,7 @@ paths: #### Allowed for * Agents + operationId: CountAuditsForTicket responses: "200": description: Count of audits on a ticket @@ -9237,19 +9599,22 @@ paths: examples: default: $ref: '#/components/examples/TicketAuditsCountResponseExample' - /api/v2/tickets/{ticket_id}/collaborators: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/tickets/{ticketId}/collaborators: get: - operationId: ListTicketCollaborators tags: - - Tickets + - Tickets summary: List Collaborators for a Ticket description: |- #### Allowed For * Agents + operationId: ListTicketCollaborators parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9260,14 +9625,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketCollaboratorsResponseExample' - /api/v2/tickets/{ticket_id}/comments: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + /v2/tickets/{ticketId}/comments: get: - operationId: ListTicketComments tags: - - Ticket Comments + - Ticket Comments summary: List Comments description: | Returns the comments added to the ticket. @@ -9302,19 +9663,32 @@ paths: #### Allowed For * Agents + operationId: ListTicketComments parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: include_inline_images - in: query - description: Default is false. When true, inline images are also listed as attachments in the response - schema: - type: boolean - - name: include - in: query - description: 'Accepts "users". Use this parameter to list email CCs by side-loading users. Example: `?include=users`. **Note**: If the comment source is email, a deleted user will be represented as the CCd email address. If the comment source is anything else, a deleted user will be represented as the user name.' - schema: - type: string - responses: + - $ref: '#/components/parameters/AcceptHeader' + - name: include_inline_images + in: query + description: "Default is false. When true, inline images are also listed as\ + \ attachments in the response" + required: false + style: form + explode: true + schema: + type: boolean + x-ballerina-name: includeInlineImages + - name: include + in: query + description: "Accepts \"users\". Use this parameter to list email CCs by side-loading\ + \ users. Example: `?include=users`. **Note**: If the comment source is email,\ + \ a deleted user will be represented as the CCd email address. If the comment\ + \ source is anything else, a deleted user will be represented as the user\ + \ name" + required: false + style: form + explode: true + schema: + type: string + responses: "200": description: Success response content: @@ -9324,16 +9698,13 @@ paths: examples: default: $ref: '#/components/examples/TicketCommentsResponseExample' - /api/v2/tickets/{ticket_id}/comments/{comment_id}/attachments/{attachment_id}/redact: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' - - $ref: '#/components/parameters/CommentId' - - $ref: '#/components/parameters/AttachmentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/tickets/{ticketId}/comments/{commentId}/attachments/{attachmentId}/redact: put: - operationId: RedactCommentAttachment tags: - - Attachments + - Attachments summary: Redact Comment Attachment description: | Redaction allows you to permanently remove attachments from an existing comment on a ticket. Once removed from a comment, the attachment is replaced with an empty "redacted.txt" file. @@ -9347,6 +9718,7 @@ paths: * Admins * Agents when [deleting tickets is enabled for agents on professional accounts](https://support.zendesk.com/hc/en-us/articles/360002128107) * Agents assigned to a custom role with permissions to redact ticket content (Enterprise only) + operationId: RedactCommentAttachment responses: "200": description: OK response @@ -9357,20 +9729,21 @@ paths: examples: default: $ref: '#/components/examples/AttachmentResponseExample' - /api/v2/tickets/{ticket_id}/comments/{ticket_comment_id}/make_private: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' - - $ref: '#/components/parameters/TicketCommentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/CommentId' + - $ref: '#/components/parameters/AttachmentId' + /v2/tickets/{ticketId}/comments/{ticketCommentId}/make_private: put: - operationId: MakeTicketCommentPrivate tags: - - Ticket Comments + - Ticket Comments summary: Make Comment Private description: | #### Allowed For * Agents + operationId: MakeTicketCommentPrivate responses: "200": description: description @@ -9381,15 +9754,14 @@ paths: description: Empty response example: "" example: "" - /api/v2/tickets/{ticket_id}/comments/{ticket_comment_id}/redact: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' - - $ref: '#/components/parameters/TicketCommentId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/TicketCommentId' + /v2/tickets/{ticketId}/comments/{ticketCommentId}/redact: put: - operationId: RedactStringInComment tags: - - Ticket Comments + - Ticket Comments summary: Redact String in Comment description: | Permanently removes words or strings from a ticket comment. Specify the string to redact in an object with a `text` property. Example: `'{"text": "987-65-4320"}'`. The characters of the word or string are replaced by the ▇ symbol. @@ -9405,6 +9777,7 @@ paths: #### Allowed For * Agents + operationId: RedactStringInComment responses: "200": description: Success response @@ -9415,11 +9788,14 @@ paths: examples: default: $ref: '#/components/examples/TicketCommentStringRedactResponseExample' - /api/v2/tickets/{ticket_id}/comments/count: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/TicketCommentId' + /v2/tickets/{ticketId}/comments/count: get: - operationId: CountTicketComments tags: - - Ticket Comments + - Ticket Comments summary: Count Ticket Comments description: |- Returns an approximate count of the comments added to the ticket. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -9431,9 +9807,10 @@ paths: #### Allowed For * Agents + operationId: CountTicketComments parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Count of ticket comments @@ -9444,11 +9821,10 @@ paths: examples: default: $ref: '#/components/examples/TicketCommentsCountResponseExample' - /api/v2/tickets/{ticket_id}/email_ccs: + /v2/tickets/{ticketId}/email_ccs: get: - operationId: ListTicketEmailCCs tags: - - Tickets + - Tickets summary: List Email CCs for a Ticket description: |- Returns any users cc'd on the ticket. @@ -9462,9 +9838,10 @@ paths: #### Allowed For * Agents + operationId: ListTicketEmailCCs parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9475,11 +9852,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketEmailCCsResponseExample' - /api/v2/tickets/{ticket_id}/followers: + /v2/tickets/{ticketId}/followers: get: - operationId: ListTicketFollowers tags: - - Tickets + - Tickets summary: List Followers for a Ticket description: |- Returns any users who follow the ticket. @@ -9491,9 +9867,10 @@ paths: #### Allowed For * Agents + operationId: ListTicketFollowers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9504,11 +9881,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketFollowersResponseExample' - /api/v2/tickets/{ticket_id}/incidents: + /v2/tickets/{ticketId}/incidents: get: - operationId: ListTicketIncidents tags: - - Tickets + - Tickets summary: List Ticket Incidents description: |- #### Allowed For @@ -9520,9 +9896,10 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListTicketIncidents parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9533,21 +9910,10 @@ paths: examples: default: $ref: '#/components/examples/ListTicketIncidentsResponseExample' - /api/v2/tickets/{ticket_id}/macros/{macro_id}/apply: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/MacroId' - - name: ticket_id - in: path - description: The ID of the ticket - required: true - schema: - type: integer - example: 35436 + /v2/tickets/{ticketId}/macros/{macroId}/apply: get: - operationId: ShowTicketAfterChanges tags: - - Macros + - Macros summary: Show Ticket After Changes description: | Returns the full ticket object as it would be after applying the macro to the ticket. @@ -9559,6 +9925,7 @@ paths: #### Allowed For * Agents + operationId: ShowTicketAfterChanges responses: "200": description: Success Response @@ -9569,19 +9936,31 @@ paths: examples: default: $ref: '#/components/examples/MacroChangesToTicketsResponseExample' - /api/v2/tickets/{ticket_id}/mark_as_spam: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/MacroId' + - name: ticketId + in: path + description: The ID of the ticket + required: true + style: simple + explode: false + schema: + type: integer + example: 35436 + /v2/tickets/{ticketId}/mark_as_spam: put: - operationId: MarkTicketAsSpamAndSuspendRequester tags: - - Tickets + - Tickets summary: Mark Ticket as Spam and Suspend Requester description: |- #### Allowed For * Agents + operationId: MarkTicketAsSpamAndSuspendRequester parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9591,11 +9970,10 @@ paths: type: string example: "" example: "" - /api/v2/tickets/{ticket_id}/merge: + /v2/tickets/{ticketId}/merge: post: - operationId: MergeTicketsIntoTargetTicket tags: - - Tickets + - Tickets summary: Merge Tickets into Target Ticket description: |- Merges one or more tickets into the ticket with the specified id. @@ -9635,9 +10013,10 @@ paths: * Any of the sources or target tickets were created through X (formerly Twitter), Facebook or the Channel framework In any other case, comments default to private but can be modified with the comment privacy parameters. + operationId: MergeTicketsIntoTargetTicket parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' requestBody: content: application/json: @@ -9656,11 +10035,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/tickets/{ticket_id}/related: + /v2/tickets/{ticketId}/related: get: - operationId: TicketRelatedInformation tags: - - Tickets + - Tickets summary: Ticket Related Information description: |- The request returns a data object with the following properties: @@ -9676,9 +10054,10 @@ paths: #### Allowed For * Agents + operationId: TicketRelatedInformation parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' responses: "200": description: Successful response @@ -9689,20 +10068,10 @@ paths: examples: default: $ref: '#/components/examples/TicketRelatedInformationExample' - /api/v2/tickets/{ticket_id}/satisfaction_rating: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ticket_id - in: path - description: The id of the ticket - required: true - schema: - type: integer - example: 35436 + /v2/tickets/{ticketId}/satisfaction_rating: post: - operationId: CreateTicketSatisfactionRating tags: - - Satisfaction Ratings + - Satisfaction Ratings summary: Create a Satisfaction Rating description: | Creates a CSAT rating for a solved ticket, or for a ticket that was previously @@ -9715,6 +10084,7 @@ paths: * End user who requested the ticket The end user must be a verified user. + operationId: CreateTicketSatisfactionRating responses: "200": description: Success response @@ -9725,19 +10095,27 @@ paths: examples: default: $ref: '#/components/examples/SatisfactionRatingResponseExample' - /api/v2/tickets/{ticket_id}/tags: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - name: ticketId + in: path + description: The id of the ticket + required: true + style: simple + explode: false + schema: + type: integer + example: 35436 + /v2/tickets/{ticketId}/tags: get: - operationId: ListResourceTags tags: - - Tags + - Tags summary: List Resource Tags description: | #### Allowed For * Agents + operationId: ListResourceTags responses: "200": description: Success response @@ -9748,29 +10126,9 @@ paths: examples: default: $ref: '#/components/examples/TagsByObjectIdResponse' - post: - operationId: SetTagsTicket - tags: - - Tags - summary: Set Tags - description: | - #### Allowed For - - * Agents - responses: - "201": - description: Created response - content: - application/json: - schema: - $ref: '#/components/schemas/TagsByObjectIdResponse' - examples: - default: - $ref: '#/components/examples/TagsByObjectIdResponse' put: - operationId: PutTagsTicket tags: - - Tags + - Tags summary: Add Tags description: | You can also add tags to multiple tickets with the [Update Many @@ -9807,6 +10165,7 @@ paths: #### Allowed For * Agents + operationId: PutTagsTicket responses: "200": description: Success response @@ -9817,10 +10176,28 @@ paths: examples: default: $ref: '#/components/examples/TagsByObjectIdResponse' + post: + tags: + - Tags + summary: Set Tags + description: | + #### Allowed For + + * Agents + operationId: SetTagsTicket + responses: + "201": + description: Created response + content: + application/json: + schema: + $ref: '#/components/schemas/TagsByObjectIdResponse' + examples: + default: + $ref: '#/components/examples/TagsByObjectIdResponse' delete: - operationId: DeleteTagsTicket tags: - - Tags + - Tags summary: Remove Tags description: | You can also delete tags from multiple tickets with the @@ -9831,14 +10208,17 @@ paths: #### Allowed For * Agents + operationId: DeleteTagsTicket responses: "204": description: No Content response - /api/v2/tickets/count: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketId' + /v2/tickets/count: get: - operationId: CountTickets tags: - - Tickets + - Tickets summary: Count Tickets description: |- Returns an approximate count of tickets in the account. If the count exceeds 100,000, it is updated every 24 hours. @@ -9852,33 +10232,24 @@ paths: #### Allowed For * Agents + operationId: CountTickets responses: "200": description: Count of tickets content: application/json: schema: - type: object - properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer + $ref: '#/components/schemas/InlineResponse2005' examples: default: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 - /api/v2/tickets/create_many: + /v2/tickets/create_many: post: - operationId: TicketsCreateMany tags: - - Tickets + - Tickets summary: Create Many Tickets description: |- Accepts an array of up to 100 ticket objects. **Note**: Every ticket created with this endpoint may be affected by your business rules, which can include sending email notifications to your end users. If you are importing historical tickets or creating more than 1000 tickets, consider using the [Ticket Bulk Import](/api-reference/ticketing/tickets/ticket_import/#ticket-bulk-import) endpoint. @@ -9887,6 +10258,7 @@ paths: #### Allowed For * Agents + operationId: TicketsCreateMany requestBody: content: application/json: @@ -9905,11 +10277,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/tickets/destroy_many: + /v2/tickets/destroy_many: delete: - operationId: BulkDeleteTickets tags: - - Tickets + - Tickets summary: Bulk Delete Tickets description: |- Accepts a comma-separated list of up to 100 ticket ids. @@ -9924,9 +10295,10 @@ paths: in the Support Help Center. This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information. + operationId: BulkDeleteTickets parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketIds' responses: "200": description: Successful response @@ -9937,11 +10309,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/tickets/mark_many_as_spam: + /v2/tickets/mark_many_as_spam: put: - operationId: MarkManyTicketsAsSpam tags: - - Tickets + - Tickets summary: Bulk Mark Tickets as Spam description: |- Accepts a comma-separated list of up to 100 ticket ids. @@ -9951,9 +10322,10 @@ paths: #### Allowed For * Agents + operationId: MarkManyTicketsAsSpam parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketIds' responses: "200": description: Successful response @@ -9964,11 +10336,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/tickets/show_many: + /v2/tickets/show_many: get: - operationId: TicketsShowMany tags: - - Tickets + - Tickets summary: Show Multiple Tickets description: |- Accepts a comma-separated list of ticket ids to return. @@ -9977,9 +10348,10 @@ paths: #### Allowed For * Agents + operationId: TicketsShowMany parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TicketIds' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TicketIds' responses: "200": description: List tickets @@ -9990,21 +10362,25 @@ paths: examples: default: $ref: '#/components/examples/TicketsResponseExample' - /api/v2/tickets/update_many: + /v2/tickets/update_many: put: - operationId: TicketsUpdateMany tags: - - Tickets + - Tickets summary: Update Many Tickets - description: Accepts an array of up to 100 ticket objects, or a comma-separated list of up to 100 ticket ids. + description: "Accepts an array of up to 100 ticket objects, or a comma-separated\ + \ list of up to 100 ticket ids." + operationId: TicketsUpdateMany parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Comma-separated list of ticket ids - schema: - type: string - example: 35436,35437 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Comma-separated list of ticket ids + required: false + style: form + explode: true + schema: + type: string + example: "35436,35437" responses: "200": description: Successful response @@ -10015,11 +10391,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/trigger_categories: + /v2/trigger_categories: get: - operationId: ListTriggerCategories tags: - - Trigger Categories + - Trigger Categories summary: List Trigger Categories description: | Returns all the trigger categories in the account. @@ -10030,75 +10405,74 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListTriggerCategories parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: page - in: query - description: Pagination parameters - style: deepObject - explode: true - schema: - type: object - properties: - after: - type: string - before: - type: string - size: - type: integer - example: - after: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 - before: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 - size: 50 - - name: sort - in: query - description: Sort parameters - schema: - type: string - enum: - - position - - -position - - name - - -name - - created_at - - -created_at - - updated_at - - -updated_at - - name: include - in: query - description: Allowed sideloads - schema: - type: string - enum: - - rule_counts + - $ref: '#/components/parameters/AcceptHeader' + - name: page + in: query + description: Pagination parameters + required: false + style: deepObject + explode: true + schema: + $ref: '#/components/schemas/Page' + example: + after: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 + before: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 + size: 50 + - name: sort + in: query + description: Sort parameters + required: false + style: form + explode: true + schema: + type: string + enum: + - position + - -position + - name + - -name + - created_at + - -created_at + - updated_at + - -updated_at + - name: include + in: query + description: Allowed sideloads + required: false + style: form + explode: true + schema: + type: string + enum: + - rule_counts responses: "200": description: A paged array of trigger categories content: application/json: schema: - allOf: - - $ref: '#/components/schemas/TriggerCategoriesResponse' - - $ref: '#/components/schemas/Pagination' + $ref: '#/components/schemas/InlineResponse2006' example: links: - next: https://{subdomain}.zendesk.com/api/v2/trigger_categories.json?include=rule_counts&page[after]=eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9&page[size]=2&sort=position - prev: https://{subdomain}.zendesk.com/api/v2/trigger_categories.json?include=rule_counts&page[before]=eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9&page[size]=2&sort=position + next: "https://{subdomain}.zendesk.com/api/v2/trigger_categories.json?include=rule_counts&page[after]=eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9&page[size]=2&sort=position" + prev: "https://{subdomain}.zendesk.com/api/v2/trigger_categories.json?include=rule_counts&page[before]=eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9&page[size]=2&sort=position" meta: after_cursor: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 before_cursor: eyJvIjoiLXNjb3JlLGlkIiwidiI6ImFRSUFBQUFBQUFBQWFRMHBJUUVBQUFBQSJ9 has_more: true trigger_categories: - - created_at: "2020-07-17T01:30:07Z" - id: "10001" - name: Email Triggers - position: 0 - updated_at: "2020-07-17T01:30:07Z" - - created_at: "2020-07-17T01:30:07Z" - id: "10002" - name: SMS Triggers - position: 1 - updated_at: "2020-07-17T01:30:07Z" + - created_at: 2020-07-17T01:30:07Z + id: "10001" + name: Email Triggers + position: 0 + updated_at: 2020-07-17T01:30:07Z + - created_at: 2020-07-17T01:30:07Z + id: "10002" + name: SMS Triggers + position: 1 + updated_at: 2020-07-17T01:30:07Z "400": description: Error content: @@ -10107,8 +10481,8 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: InvalidPaginationParameter - title: page[after] is not valid + - code: InvalidPaginationParameter + title: "page[after] is not valid" "403": description: Error content: @@ -10117,29 +10491,24 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: TriggerCategoriesNotEnabled - title: Trigger categories are not enabled for your account + - code: TriggerCategoriesNotEnabled + title: Trigger categories are not enabled for your account post: - operationId: CreateTriggerCategory tags: - - Trigger Categories + - Trigger Categories summary: Create Trigger Category description: Creates a trigger category. + operationId: CreateTriggerCategory requestBody: - required: true content: application/json: schema: - type: object - properties: - trigger_category: - allOf: - - $ref: '#/components/schemas/TriggerCategoryRequest' - - $ref: '#/components/schemas/TriggerCategoryRequestRequired' + $ref: '#/components/schemas/V2TriggerCategoriesBody' example: trigger_category: name: All Notification Triggers position: 0 + required: true responses: "200": description: The created trigger category @@ -10149,11 +10518,11 @@ paths: $ref: '#/components/schemas/TriggerCategoryResponse' example: trigger_category: - created_at: "2020-07-17T01:30:07Z" + created_at: 2020-07-17T01:30:07Z id: "10001" name: All Notification Triggers position: 0 - updated_at: "2020-07-17T01:30:07Z" + updated_at: 2020-07-17T01:30:07Z "400": description: Error content: @@ -10162,8 +10531,8 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: InvalidTriggerCategory - title: Name cannot be blank + - code: InvalidTriggerCategory + title: Name cannot be blank "403": description: Error content: @@ -10172,26 +10541,28 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: TriggerCategoriesNotEnabled - title: Trigger categories are not enabled for your account - - code: ProductLimitExceeded - title: Your account has reached the limit of 500 trigger categories. - /api/v2/trigger_categories/{trigger_category_id}: + - code: TriggerCategoriesNotEnabled + title: Trigger categories are not enabled for your account + - code: ProductLimitExceeded + title: Your account has reached the limit of 500 trigger categories. + /v2/trigger_categories/{triggerCategoryId}: get: - operationId: ShowTriggerCategoryById tags: - - Trigger Categories + - Trigger Categories summary: Show Trigger Category description: Returns the trigger category with the specified ID. + operationId: ShowTriggerCategoryById parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: trigger_category_id - in: path - description: The id of the trigger category to retrieve - required: true - schema: - type: string - example: "10001" + - $ref: '#/components/parameters/AcceptHeader' + - name: triggerCategoryId + in: path + description: The id of the trigger category to retrieve + required: true + style: simple + explode: false + schema: + type: string + example: "10001" responses: "200": description: The requested trigger category @@ -10201,11 +10572,51 @@ paths: $ref: '#/components/schemas/TriggerCategoryResponse' example: trigger_category: - created_at: "2020-07-17T01:30:07Z" + created_at: 2020-07-17T01:30:07Z id: "10001" name: All Notification Triggers position: 0 - updated_at: "2020-07-17T01:30:07Z" + updated_at: 2020-07-17T01:30:07Z + "404": + description: Error + content: + application/json: + schema: + $ref: '#/components/schemas/Errors' + example: + errors: + - code: TriggerCategoryNotFound + title: Category can’t be found. Check the ID and try again. + delete: + tags: + - Trigger Categories + summary: Delete Trigger Category + description: Deletes the trigger category with the specified ID. + operationId: DeleteTriggerCategory + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - name: triggerCategoryId + in: path + description: The id of the trigger category to delete + required: true + style: simple + explode: false + schema: + type: string + example: "10001" + responses: + "204": + description: No content + "400": + description: Error + content: + application/json: + schema: + $ref: '#/components/schemas/Errors' + example: + errors: + - code: TriggerCategoryNotEmpty + title: A category with active triggers cannot be deleted. "404": description: Error content: @@ -10214,36 +10625,35 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: TriggerCategoryNotFound - title: Category can’t be found. Check the ID and try again. + - code: TriggerCategoryNotFound + title: Category can’t be found. Check the ID and try again. patch: - operationId: UpdateTriggerCategory tags: - - Trigger Categories + - Trigger Categories summary: Update Trigger Category description: Updates the trigger category with the specified ID. + operationId: UpdateTriggerCategory parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: trigger_category_id - in: path - description: The id of the trigger category to update - required: true - schema: - type: string - example: "10001" - requestBody: + - $ref: '#/components/parameters/AcceptHeader' + - name: triggerCategoryId + in: path + description: The id of the trigger category to update required: true + style: simple + explode: false + schema: + type: string + example: "10001" + requestBody: content: application/json: schema: - type: object - properties: - trigger_category: - $ref: '#/components/schemas/TriggerCategoryRequest' + $ref: '#/components/schemas/TriggerCategoriestriggerCategoryIdBody' example: trigger_category: name: All Notification Triggers Updated position: 10 + required: true responses: "200": description: The updated trigger category @@ -10253,11 +10663,11 @@ paths: $ref: '#/components/schemas/TriggerCategoryResponse' example: trigger_category: - created_at: "2020-07-17T01:30:07Z" + created_at: 2020-07-17T01:30:07Z id: "10001" name: All Notification Triggers Updated position: 10 - updated_at: "2020-07-18T05:23:32Z" + updated_at: 2020-07-18T05:23:32Z "400": description: Error content: @@ -10266,8 +10676,8 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: InvalidTriggerCategory - title: Name cannot be blank + - code: InvalidTriggerCategory + title: Name cannot be blank "404": description: Error content: @@ -10276,55 +10686,17 @@ paths: $ref: '#/components/schemas/Errors' example: errors: - - code: TriggerCategoryNotFound - title: Category can’t be found. Check the ID and try again. - delete: - operationId: DeleteTriggerCategory + - code: TriggerCategoryNotFound + title: Category can’t be found. Check the ID and try again. + /v2/trigger_categories/jobs: + post: tags: - - Trigger Categories - summary: Delete Trigger Category - description: Deletes the trigger category with the specified ID. - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: trigger_category_id - in: path - description: The id of the trigger category to delete - required: true - schema: - type: string - example: "10001" - responses: - "204": - description: No content - "400": - description: Error - content: - application/json: - schema: - $ref: '#/components/schemas/Errors' - example: - errors: - - code: TriggerCategoryNotEmpty - title: A category with active triggers cannot be deleted. - "404": - description: Error - content: - application/json: - schema: - $ref: '#/components/schemas/Errors' - example: - errors: - - code: TriggerCategoryNotFound - title: Category can’t be found. Check the ID and try again. - /api/v2/trigger_categories/jobs: - post: - operationId: BatchOperateTriggerCategories - tags: - - Trigger Categories + - Trigger Categories summary: Create Batch Job for Trigger Categories - description: Creates a job that performs a batch operation for the given trigger categories. + description: Creates a job that performs a batch operation for the given trigger + categories. + operationId: BatchOperateTriggerCategories requestBody: - required: true content: application/json: schema: @@ -10334,19 +10706,20 @@ paths: action: patch items: trigger_categories: - - id: "10001" - position: 0 - - id: "10002" - position: 1 + - id: "10001" + position: 0 + - id: "10002" + position: 1 triggers: - - active: false - category_id: "10001" - id: "10011" - position: 10 - - active: true - category_id: "10002" - id: "10012" - position: 1 + - active: false + category_id: "10001" + id: "10011" + position: 10 + - active: true + category_id: "10002" + id: "10012" + position: 1 + required: true responses: "200": description: The response to the batch job @@ -10357,41 +10730,41 @@ paths: example: results: trigger_categories: - - created_at: "2020-07-18T01:24:53Z" - id: "10001" - name: Notifications - position: 0 - updated_at: "2020-07-20T01:30:07Z" - - created_at: "2020-07-17T06:31:12Z" - id: "10002" - name: Apply Tags - position: 1 - updated_at: "2020-07-20T01:30:07Z" + - created_at: 2020-07-18T01:24:53Z + id: "10001" + name: Notifications + position: 0 + updated_at: 2020-07-20T01:30:07Z + - created_at: 2020-07-17T06:31:12Z + id: "10002" + name: Apply Tags + position: 1 + updated_at: 2020-07-20T01:30:07Z triggers: - - actions: - - {} - active: true - conditions: {} - created_at: "2012-09-25T22:50:26Z" - description: Notify external target - id: 10012 - position: 1 - raw_title: Notify target - title: Notify Target - updated_at: "2020-07-20T01:30:07Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/10012.json - - actions: - - {} - active: false - conditions: {} - created_at: "2012-09-25T22:50:26Z" - description: Close and save a ticket - id: 10011 - position: 10 - raw_title: Close and Save - title: Close and Save - updated_at: "2020-07-20T01:30:07Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/10011.json + - actions: + - {} + active: true + conditions: {} + created_at: 2012-09-25T22:50:26Z + description: Notify external target + id: 10012 + position: 1 + raw_title: Notify target + title: Notify Target + updated_at: 2020-07-20T01:30:07Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/10012.json" + - actions: + - {} + active: false + conditions: {} + created_at: 2012-09-25T22:50:26Z + description: Close and save a ticket + id: 10011 + position: 10 + raw_title: Close and Save + title: Close and Save + updated_at: 2020-07-20T01:30:07Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/10011.json" status: complete "400": description: Error @@ -10401,15 +10774,14 @@ paths: $ref: '#/components/schemas/BatchJobResponse' example: errors: - - code: InvalidTrigger - title: category_id is not valid - trigger_id: "10001" + - code: InvalidTrigger + title: category_id is not valid + trigger_id: "10001" status: failed - /api/v2/triggers: + /v2/triggers: get: - operationId: ListTriggers tags: - - Triggers + - Triggers summary: List Triggers description: | Lists all triggers for the current account. @@ -10439,13 +10811,14 @@ paths: | usage_24h | The number of times each trigger has been used in the past day | usage_7d | The number of times each trigger has been used in the past week | usage_30d | The number of times each trigger has been used in the past thirty days + operationId: ListTriggers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerActive' - - $ref: '#/components/parameters/TriggerSort' - - $ref: '#/components/parameters/TriggerSortBy' - - $ref: '#/components/parameters/TriggerSortOrder' - - $ref: '#/components/parameters/TriggerCategoryId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerActive' + - $ref: '#/components/parameters/TriggerSort' + - $ref: '#/components/parameters/TriggerSortBy' + - $ref: '#/components/parameters/TriggerSortOrder' + - $ref: '#/components/parameters/TriggerCategoryId' responses: "200": description: Success response @@ -10457,16 +10830,15 @@ paths: default: $ref: '#/components/examples/TriggersResponseExample' post: - operationId: CreateTrigger tags: - - Triggers + - Triggers summary: Create Trigger description: | #### Allowed For * Agents + operationId: CreateTrigger requestBody: - required: true content: application/json: schema: @@ -10474,6 +10846,7 @@ paths: examples: default: $ref: '#/components/examples/TriggerWithCategoryRequestExample' + required: true responses: "201": description: Created response @@ -10484,14 +10857,10 @@ paths: examples: default: $ref: '#/components/examples/TriggerResponseExample' - /api/v2/triggers/{trigger_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerId' + /v2/triggers/{triggerId}: get: - operationId: GetTrigger tags: - - Triggers + - Triggers summary: Show Trigger description: | #### Allowed For @@ -10499,6 +10868,7 @@ paths: * Agents The Via Type value is a number instead of a text string. See [Via types reference](/documentation/ticketing/reference-guides/via-types/) for the keys. + operationId: GetTrigger responses: "200": description: Success response @@ -10510,9 +10880,8 @@ paths: default: $ref: '#/components/examples/TriggerResponseExample' put: - operationId: UpdateTrigger tags: - - Triggers + - Triggers summary: Update Trigger description: | #### Allowed For @@ -10524,8 +10893,8 @@ paths: Updating a condition or action updates both the conditions and actions arrays, clearing all existing values of both arrays. Include all your conditions and actions when updating any condition or action. + operationId: UpdateTrigger requestBody: - required: true content: application/json: schema: @@ -10533,6 +10902,7 @@ paths: examples: default: $ref: '#/components/examples/TriggerWithCategoryRequestExample' + required: true responses: "200": description: Success response @@ -10544,25 +10914,24 @@ paths: default: $ref: '#/components/examples/TriggerResponseExample' delete: - operationId: DeleteTrigger tags: - - Triggers + - Triggers summary: Delete Trigger description: | #### Allowed For * Agents + operationId: DeleteTrigger responses: "204": description: No Content response - /api/v2/triggers/{trigger_id}/revisions: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerId' + /v2/triggers/{triggerId}/revisions: get: - operationId: ListTriggerRevisions tags: - - Triggers + - Triggers summary: List Trigger Revisions description: | List the revisions associated with a trigger. Trigger revision history is only available on Enterprise plans. @@ -10600,6 +10969,7 @@ paths: You can request a maximum of 1000 records using the `limit` parameter. If no `limit` parameter is supplied, it will default to 1,000. + operationId: ListTriggerRevisions responses: "200": description: Success response @@ -10610,15 +10980,13 @@ paths: examples: default: $ref: '#/components/examples/TriggerRevisionsResponseExample' - /api/v2/triggers/{trigger_id}/revisions/{trigger_revision_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerId' - - $ref: '#/components/parameters/TriggerRevisionId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerId' + /v2/triggers/{triggerId}/revisions/{triggerRevisionId}: get: - operationId: TriggerRevision tags: - - Triggers + - Triggers summary: Show Trigger Revision description: | Fetches a revision associated with a trigger. Trigger revision history is only available on Enterprise plans. @@ -10634,6 +11002,7 @@ paths: | Name | Will sideload | ----- | ------------- | users | The user that authored each revision + operationId: TriggerRevision responses: "200": description: Success response @@ -10644,17 +11013,14 @@ paths: examples: default: $ref: '#/components/examples/TriggerRevisionResponseExample' - /api/v2/triggers/active: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerSort' - - $ref: '#/components/parameters/TriggerSortBy' - - $ref: '#/components/parameters/TriggerSortOrder' - - $ref: '#/components/parameters/TriggerCategoryId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerId' + - $ref: '#/components/parameters/TriggerRevisionId' + /v2/triggers/active: get: - operationId: ListActiveTriggers tags: - - Triggers + - Triggers summary: List Active Triggers description: | Lists all active triggers. @@ -10683,6 +11049,7 @@ paths: | usage_24h | The number of times each trigger has been used in the past day | usage_7d | The number of times each trigger has been used in the past week | usage_30d | The number of times each trigger has been used in the past thirty days + operationId: ListActiveTriggers responses: "200": description: Success response @@ -10693,11 +11060,16 @@ paths: examples: default: $ref: '#/components/examples/TriggersActiveResponseExample' - /api/v2/triggers/definitions: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerSort' + - $ref: '#/components/parameters/TriggerSortBy' + - $ref: '#/components/parameters/TriggerSortOrder' + - $ref: '#/components/parameters/TriggerCategoryId' + /v2/triggers/definitions: get: - operationId: ListTriggerActionConditionDefinitions tags: - - Triggers + - Triggers summary: List Trigger Action and Condition Definitions description: | Returns the definitions of the actions a trigger can perform and the @@ -10712,6 +11084,7 @@ paths: #### Allowed For * Agents + operationId: ListTriggerActionConditionDefinitions responses: "200": description: Success response @@ -10722,14 +11095,10 @@ paths: examples: default: $ref: '#/components/examples/TriggerDefinitionResponseExample' - /api/v2/triggers/destroy_many: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerIds' + /v2/triggers/destroy_many: delete: - operationId: DeleteManyTriggers tags: - - Triggers + - Triggers summary: Bulk Delete Triggers description: | Deletes the triggers corresponding to the provided comma-separated list of IDs. @@ -10754,14 +11123,17 @@ paths: "ids": "25,23,27,22" } ``` + operationId: DeleteManyTriggers responses: "204": description: No content response - /api/v2/triggers/reorder: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerIds' + /v2/triggers/reorder: put: - operationId: ReorderTriggers tags: - - Triggers + - Triggers summary: Reorder Triggers description: | Alters the firing order of triggers in the account. See @@ -10776,6 +11148,7 @@ paths: #### Allowed For * Agents + operationId: ReorderTriggers responses: "200": description: Success response @@ -10786,20 +11159,10 @@ paths: examples: default: $ref: '#/components/examples/TriggerResponseExample' - /api/v2/triggers/search: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/TriggerSearchQuery' - - $ref: '#/components/parameters/TriggerSearchFilter' - - $ref: '#/components/parameters/TriggerActive' - - $ref: '#/components/parameters/TriggerSort' - - $ref: '#/components/parameters/TriggerSortBy' - - $ref: '#/components/parameters/TriggerSortOrder' - - $ref: '#/components/parameters/TriggerInclude' + /v2/triggers/search: get: - operationId: SearchTriggers tags: - - Triggers + - Triggers summary: Search Triggers description: | #### Pagination @@ -10836,6 +11199,7 @@ paths: } } ``` + operationId: SearchTriggers responses: "200": description: Success response @@ -10846,11 +11210,19 @@ paths: examples: default: $ref: '#/components/examples/TriggersSearchResponseExample' - /api/v2/triggers/update_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/TriggerSearchQuery' + - $ref: '#/components/parameters/TriggerSearchFilter' + - $ref: '#/components/parameters/TriggerActive' + - $ref: '#/components/parameters/TriggerSort' + - $ref: '#/components/parameters/TriggerSortBy' + - $ref: '#/components/parameters/TriggerSortOrder' + - $ref: '#/components/parameters/TriggerInclude' + /v2/triggers/update_many: put: - operationId: UpdateManyTriggers tags: - - Triggers + - Triggers summary: Update Many Triggers description: | Updates the position or the active status of multiple triggers. Any additional properties are ignored. @@ -10884,8 +11256,8 @@ paths: ] } ``` + operationId: UpdateManyTriggers requestBody: - required: true content: application/json: schema: @@ -10893,6 +11265,7 @@ paths: examples: default: $ref: '#/components/examples/TriggerBulkUpdateRequestExample' + required: true responses: "200": description: Success response @@ -10903,11 +11276,10 @@ paths: examples: default: $ref: '#/components/examples/TriggersResponseExample' - /api/v2/uploads: + /v2/uploads: post: - operationId: UploadFiles tags: - - Attachments + - Attachments summary: Upload Files description: | Uploads a file that can be attached to a ticket comment. It doesn't attach the file to the comment. For details and examples, see [Attaching ticket comments with the API](/documentation/ticketing/using-the-zendesk-api/adding-ticket-attachments-with-the-api). @@ -10923,6 +11295,7 @@ paths: #### Allowed For * End users + operationId: UploadFiles responses: "201": description: Created response @@ -10933,33 +11306,34 @@ paths: examples: default: $ref: '#/components/examples/AttachmentUploadResponseExample' - /api/v2/uploads/{token}: + /v2/uploads/{token}: delete: - operationId: DeleteUpload tags: - - Attachments + - Attachments summary: Delete Upload description: | #### Allowed for * End Users + operationId: DeleteUpload parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: token - in: path - description: The token of the uploaded attachment - required: true - schema: - type: string - example: 6bk3gql82em5nmf + - $ref: '#/components/parameters/AcceptHeader' + - name: token + in: path + description: The token of the uploaded attachment + required: true + style: simple + explode: false + schema: + type: string + example: 6bk3gql82em5nmf responses: "204": description: No Content response - /api/v2/user_fields: + /v2/user_fields: get: - operationId: ListUserFields tags: - - User Fields + - User Fields summary: List User Fields description: | Returns a list of custom user fields in your account. Fields are returned in the order that you specify in your user fields configuration in Zendesk Support. Clients should cache this resource for the duration of their API usage and map the key for each User Field to the values returned under the `user_fields` attribute on the [User](/api-reference/ticketing/users/users/) resource. @@ -10976,6 +11350,7 @@ paths: #### Allowed For * Agents + operationId: ListUserFields responses: "200": description: Success response @@ -10987,9 +11362,8 @@ paths: default: $ref: '#/components/examples/UserFieldsResponseExample' post: - operationId: CreateUserField tags: - - User Fields + - User Fields summary: Create User Field description: | Creates any of the following custom field types: @@ -11009,6 +11383,7 @@ paths: #### Allowed For * Admins + operationId: CreateUserField responses: "201": description: Created response @@ -11019,19 +11394,16 @@ paths: examples: default: $ref: '#/components/examples/UserFieldCreateResponseExample' - /api/v2/user_fields/{user_field_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserFieldId' + /v2/user_fields/{userFieldId}: get: - operationId: ShowUserField tags: - - User Fields + - User Fields summary: Show User Field description: | #### Allowed for * Agents + operationId: ShowUserField responses: "200": description: Success response @@ -11043,9 +11415,8 @@ paths: default: $ref: '#/components/examples/UserFieldResponseExample' put: - operationId: UpdateUserField tags: - - User Fields + - User Fields summary: Update User Field description: | #### Updating a Dropdown (Tagger) Field @@ -11070,6 +11441,7 @@ paths: #### Allowed for * Admins + operationId: UpdateUserField responses: "200": description: Success response @@ -11081,25 +11453,24 @@ paths: default: $ref: '#/components/examples/UserFieldUpdateResponseExample' delete: - operationId: DeleteUserField tags: - - User Fields + - User Fields summary: Delete User Field description: | #### Allowed for * Admins + operationId: DeleteUserField responses: "204": description: No Content response - /api/v2/user_fields/{user_field_id}/options: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserFieldId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserFieldId' + /v2/user_fields/{userFieldId}/options: get: - operationId: ListUserFieldOptions tags: - - User Fields + - User Fields summary: List User Field Options description: | Returns a list of custom user field options for the given dropdown user field. @@ -11116,6 +11487,7 @@ paths: #### Allowed For * Agents + operationId: ListUserFieldOptions responses: "200": description: Success response @@ -11127,9 +11499,8 @@ paths: default: $ref: '#/components/examples/CustomUserFieldOptionsResponseExample' post: - operationId: CreateOrUpdateUserFieldOption tags: - - User Fields + - User Fields summary: Create or Update a User Field Option description: | Creates a new option or updates an existing option for the given drop-down user field. @@ -11146,6 +11517,7 @@ paths: #### Allowed For * Admins + operationId: CreateOrUpdateUserFieldOption responses: "200": description: Success response @@ -11165,19 +11537,18 @@ paths: examples: default: $ref: '#/components/examples/CustomUserFieldOptionCreateResponseExample' - /api/v2/user_fields/{user_field_id}/options/{user_field_option_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserFieldId' - - $ref: '#/components/parameters/UserFieldOptionId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserFieldId' + /v2/user_fields/{userFieldId}/options/{userFieldOptionId}: get: - operationId: ShowUserFieldOption tags: - - User Fields + - User Fields summary: Show a User Field Option description: | #### Allowed for * Agents + operationId: ShowUserFieldOption responses: "200": description: Success response @@ -11189,26 +11560,30 @@ paths: default: $ref: '#/components/examples/CustomUserFieldOptionResponseExample' delete: - operationId: DeleteUserFieldOption tags: - - User Fields + - User Fields summary: Delete User Field Option description: | #### Allowed for * Admins + operationId: DeleteUserFieldOption responses: "204": description: No Content response - /api/v2/user_fields/reorder: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserFieldId' + - $ref: '#/components/parameters/UserFieldOptionId' + /v2/user_fields/reorder: put: - operationId: ReorderUserField tags: - - User Fields + - User Fields summary: Reorder User Field description: | #### Allowed For * Admins + operationId: ReorderUserField responses: "200": description: Success response @@ -11219,11 +11594,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/users: + /v2/users: get: - operationId: ListUsers tags: - - Users + - Users summary: List Users description: | #### Pagination @@ -11238,12 +11612,13 @@ paths: #### Allowed For * Admins, Agents and Light Agents + operationId: ListUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserRoleFilter' - - $ref: '#/components/parameters/UserRolesFilter' - - $ref: '#/components/parameters/UserPermissionSetFilter' - - $ref: '#/components/parameters/UserExternalIdFilter' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserRoleFilter' + - $ref: '#/components/parameters/UserRolesFilter' + - $ref: '#/components/parameters/UserPermissionSetFilter' + - $ref: '#/components/parameters/UserExternalIdFilter' responses: "200": description: Success response @@ -11255,12 +11630,11 @@ paths: default: $ref: '#/components/examples/UsersResponseExample' post: - operationId: CreateUser tags: - - Users + - Users summary: Create User + operationId: CreateUser requestBody: - required: true content: application/json: schema: @@ -11268,6 +11642,7 @@ paths: examples: default: $ref: '#/components/examples/UserRequestExample' + required: true responses: "201": description: Created response @@ -11278,19 +11653,16 @@ paths: examples: default: $ref: '#/components/examples/UserCreateResponseExample' - /api/v2/users/{user_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + /v2/users/{userId}: get: - operationId: ShowUser tags: - - Users + - Users summary: Show User description: | #### Allowed For * Agents + operationId: ShowUser responses: "200": description: Success response @@ -11302,12 +11674,11 @@ paths: default: $ref: '#/components/examples/UserResponseExample' put: - operationId: UpdateUser tags: - - Users + - Users summary: Update User + operationId: UpdateUser requestBody: - required: true content: application/json: schema: @@ -11315,6 +11686,7 @@ paths: examples: default: $ref: '#/components/examples/UpdateUserRequestExample' + required: true responses: "200": description: Success response @@ -11326,9 +11698,8 @@ paths: default: $ref: '#/components/examples/UpdateUserResponseExample' delete: - operationId: DeleteUser tags: - - Users + - Users summary: Delete User description: | Deletes the user and associated records from the account. @@ -11343,6 +11714,7 @@ paths: #### Allowed For * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage end users or team members + operationId: DeleteUser responses: "200": description: Success response @@ -11353,14 +11725,13 @@ paths: examples: default: $ref: '#/components/examples/DeleteUserResponseExample' - /api/v2/users/{user_id}/compliance_deletion_statuses: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/compliance_deletion_statuses: get: - operationId: ShowUserComplianceDeletionStatuses tags: - - Users + - Users summary: Show Compliance Deletion Statuses description: | Returns the GDPR status for each user per area of compliance. A Zendesk area of compliance is typically a product like "support/explore" but can be more fine-grained for areas within the product lines. @@ -11385,14 +11756,18 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ShowUserComplianceDeletionStatuses parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: application - in: query - description: Area of compliance - schema: - type: string - example: chat + - $ref: '#/components/parameters/AcceptHeader' + - name: application + in: query + description: Area of compliance + required: false + style: form + explode: true + schema: + type: string + example: chat responses: "200": description: Success response @@ -11403,14 +11778,13 @@ paths: examples: default: $ref: '#/components/examples/ComplianceDeletionStatusesResponseExample' - /api/v2/users/{user_id}/group_memberships: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/group_memberships: get: - operationId: ListGroupMembershipsByUserId tags: - - Group Memberships + - Group Memberships summary: List Memberships description: | #### Pagination @@ -11425,6 +11799,7 @@ paths: #### Allowed For: * Agents + operationId: ListGroupMembershipsByUserId responses: "200": description: Success response @@ -11435,20 +11810,19 @@ paths: examples: default: $ref: '#/components/examples/GroupMembershipsResponseExample' - /api/v2/users/{user_id}/group_memberships/{group_membership_id}/make_default: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/GroupMembershipId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/group_memberships/{groupMembershipId}/make_default: put: - operationId: GroupMembershipSetDefault tags: - - Group Memberships + - Group Memberships summary: Set Membership as Default description: | #### Allowed For: * Agents + operationId: GroupMembershipSetDefault responses: "200": description: Success response @@ -11459,14 +11833,14 @@ paths: examples: default: $ref: '#/components/examples/GroupMembershipsResponseExample' - /api/v2/users/{user_id}/identities: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/GroupMembershipId' + /v2/users/{userId}/identities: get: - operationId: ListUserIdentities tags: - - User Identities + - User Identities summary: List Identities description: | Returns a list of identities for the given user. @@ -11486,6 +11860,7 @@ paths: * Agents * Verified end users + operationId: ListUserIdentities responses: "200": description: Success response @@ -11497,9 +11872,8 @@ paths: default: $ref: '#/components/examples/UserIdentitiesResponseExample' post: - operationId: CreateUserIdentity tags: - - User Identities + - User Identities summary: Create Identity description: | Adds an identity to a user's profile. An agent can add an identity to any user profile. @@ -11520,6 +11894,7 @@ paths: #### Allowed For * Agents + operationId: CreateUserIdentity responses: "201": description: Created response @@ -11530,15 +11905,13 @@ paths: examples: default: $ref: '#/components/examples/UserIdentityCreateResponseExample' - /api/v2/users/{user_id}/identities/{user_identity_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/UserIdentityId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/identities/{userIdentityId}: get: - operationId: ShowUserIdentity tags: - - User Identities + - User Identities summary: Show Identity description: | Shows the identity with the given id for a given user. @@ -11549,6 +11922,7 @@ paths: * Agents * Verified end users + operationId: ShowUserIdentity responses: "200": description: Success response @@ -11560,9 +11934,8 @@ paths: default: $ref: '#/components/examples/UserIdentityResponseExample' put: - operationId: UpdateUserIdentity tags: - - User Identities + - User Identities summary: Update Identity description: | This endpoint allows you to: @@ -11575,6 +11948,7 @@ paths: #### Allowed For * Agents + operationId: UpdateUserIdentity responses: "200": description: Success response @@ -11586,9 +11960,8 @@ paths: default: $ref: '#/components/examples/UserIdentityUpdateResponseExample' delete: - operationId: DeleteUserIdentity tags: - - User Identities + - User Identities summary: Delete Identity description: | Deletes the identity for a given user. @@ -11596,18 +11969,18 @@ paths: #### Allowed For * Agents + operationId: DeleteUserIdentity responses: "204": description: No Content response - /api/v2/users/{user_id}/identities/{user_identity_id}/make_primary: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/UserIdentityId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/UserIdentityId' + /v2/users/{userId}/identities/{userIdentityId}/make_primary: put: - operationId: MakeUserIdentityPrimary tags: - - User Identities + - User Identities summary: Make Identity Primary description: | Sets the specified identity as primary. To change other attributes, use the [Update Identity](#update-identity) endpoint. This is a collection-level operation and the correct behavior for an API client is to subsequently reload the entire collection. @@ -11618,6 +11991,7 @@ paths: * Agents * Verified end users + operationId: MakeUserIdentityPrimary responses: "200": description: Success response @@ -11628,15 +12002,14 @@ paths: examples: default: $ref: '#/components/examples/UserIdentitiesResponseExample' - /api/v2/users/{user_id}/identities/{user_identity_id}/request_verification: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/UserIdentityId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/UserIdentityId' + /v2/users/{userId}/identities/{userIdentityId}/request_verification: put: - operationId: RequestUserVerfication tags: - - User Identities + - User Identities summary: Request User Verification description: | Sends the user a verification email with a link to verify ownership of the email address. @@ -11644,6 +12017,7 @@ paths: #### Allowed For * Agents + operationId: RequestUserVerfication responses: "200": description: Success description @@ -11654,15 +12028,14 @@ paths: description: Empty response example: "" example: "" - /api/v2/users/{user_id}/identities/{user_identity_id}/verify: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/UserIdentityId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/UserIdentityId' + /v2/users/{userId}/identities/{userIdentityId}/verify: put: - operationId: VerifyUserIdentity tags: - - User Identities + - User Identities summary: Verify Identity description: | Sets the specified identity as verified. @@ -11672,6 +12045,7 @@ paths: #### Allowed For * Agents + operationId: VerifyUserIdentity responses: "200": description: Success response @@ -11682,14 +12056,14 @@ paths: examples: default: $ref: '#/components/examples/UserIdentityResponseExample' - /api/v2/users/{user_id}/merge: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/UserIdentityId' + /v2/users/{userId}/merge: put: - operationId: MergeEndUsers tags: - - Users + - Users summary: Merge End Users description: | Merges the end user specified in the path parameter into the existing end user specified in the request body. @@ -11703,8 +12077,8 @@ paths: #### Allowed For * Admins or agents with permission to edit end users + operationId: MergeEndUsers requestBody: - required: true content: application/json: schema: @@ -11712,6 +12086,7 @@ paths: examples: default: $ref: '#/components/examples/MergeEndUsersRequestExample' + required: true responses: "200": description: Success response @@ -11722,15 +12097,13 @@ paths: examples: default: $ref: '#/components/examples/UserResponseExample' - /api/v2/users/{user_id}/organization_memberships/{organization_membership_id}/make_default: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/OrganizationMembershipId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/organization_memberships/{organizationMembershipId}/make_default: put: - operationId: SetOrganizationMembershipAsDefault tags: - - Organization Memberships + - Organization Memberships summary: Set Membership as Default description: | Sets the default organization membership of a given user. @@ -11739,6 +12112,7 @@ paths: * Admins * Agents when setting the default organization membership for an end user + operationId: SetOrganizationMembershipAsDefault responses: "200": description: Success response @@ -11749,15 +12123,14 @@ paths: examples: default: $ref: '#/components/examples/OrganizationMembershipsResponseExample' - /api/v2/users/{user_id}/organizations/{organization_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/OrganizationId' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/OrganizationMembershipId' + /v2/users/{userId}/organizations/{organizationId}: delete: - operationId: UnassignOrganization tags: - - Organization Memberships + - Organization Memberships summary: Unassign Organization description: | Immediately removes a user from an organization and schedules a job to unassign all working tickets currently assigned to the user and organization combination. The `organization_id` of the unassigned tickets is set to null. @@ -11765,18 +12138,18 @@ paths: #### Allowed For * Agents + operationId: UnassignOrganization responses: "204": description: No Content response - /api/v2/users/{user_id}/organizations/{organization_id}/make_default: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - - $ref: '#/components/parameters/OrganizationId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/OrganizationId' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/organizations/{organizationId}/make_default: put: - operationId: SetOrganizationAsDefault tags: - - Organization Memberships + - Organization Memberships summary: Set Organization as Default description: | Sets the default organization membership of a given user. @@ -11784,6 +12157,7 @@ paths: #### Allowed For * Agents + operationId: SetOrganizationAsDefault responses: "200": description: Success response @@ -11794,21 +12168,23 @@ paths: examples: default: $ref: '#/components/examples/OrganizationMembershipResponseExample' - /api/v2/users/{user_id}/password: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' - post: - operationId: SetUserPassword + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/OrganizationId' + /v2/users/{userId}/password: + put: tags: - - User Passwords - summary: Set a User's Password + - User Passwords + summary: Change Your Password description: | - An admin can set a user's password only if the setting is enabled in Zendesk Support under **Settings** > **Security** > **Global**. The setting is off by default. Only the account owner can access and change this setting. + You can only change your own password. Nobody can change the password of another user because it requires knowing the user's existing password. However, an admin can set a new password for another user without knowing the existing password. See [Set a User's Password](#set-a-users-password) above. #### Allowed For - * Admins + * Agents + * End Users + operationId: ChangeOwnPassword responses: "200": description: Success description @@ -11819,18 +12195,17 @@ paths: description: Empty response example: "" example: "" - put: - operationId: ChangeOwnPassword + post: tags: - - User Passwords - summary: Change Your Password + - User Passwords + summary: Set a User's Password description: | - You can only change your own password. Nobody can change the password of another user because it requires knowing the user's existing password. However, an admin can set a new password for another user without knowing the existing password. See [Set a User's Password](#set-a-users-password) above. + An admin can set a user's password only if the setting is enabled in Zendesk Support under **Settings** > **Security** > **Global**. The setting is off by default. Only the account owner can access and change this setting. #### Allowed For - * Agents - * End Users + * Admins + operationId: SetUserPassword responses: "200": description: Success description @@ -11841,20 +12216,20 @@ paths: description: Empty response example: "" example: "" - /api/v2/users/{user_id}/password/requirements: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/password/requirements: get: - operationId: GetUserPasswordRequirements tags: - - User Passwords + - User Passwords summary: List password requirements description: | #### Allowed For * Agents * End Users + operationId: GetUserPasswordRequirements responses: "200": description: Success response @@ -11865,15 +12240,15 @@ paths: examples: default: $ref: '#/components/examples/UserPasswordRequirementsResponseExample' - /api/v2/users/{user_id}/related: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/related: get: - operationId: ShowUserRelated tags: - - Users + - Users summary: Show User Related Information + operationId: ShowUserRelated responses: "200": description: Success response @@ -11884,14 +12259,13 @@ paths: examples: default: $ref: '#/components/examples/UserRelatedResponseExample' - /api/v2/users/{user_id}/sessions: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/sessions: delete: - operationId: BulkDeleteSessionsByUserId tags: - - Sessions + - Sessions summary: Bulk Delete Sessions description: | Deletes all the sessions for a user. @@ -11899,23 +12273,23 @@ paths: #### Allowed For * Admins, Agents, End users + operationId: BulkDeleteSessionsByUserId responses: "204": description: No Content - /api/v2/users/{user_id}/sessions/{session_id}: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SessionId' - - $ref: '#/components/parameters/UserId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/sessions/{sessionId}: get: - operationId: ShowSession tags: - - Sessions + - Sessions summary: Show Session description: | #### Allowed For * Admins, Agents, End users + operationId: ShowSession responses: "200": description: Success response @@ -11927,27 +12301,25 @@ paths: default: $ref: '#/components/examples/SessionResponseExample' delete: - operationId: DeleteSession tags: - - Sessions + - Sessions summary: Delete Session description: | #### Allowed For * Admins, Agents, End users + operationId: DeleteSession responses: "204": description: No Content - /api/v2/users/{user_id}/skips: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/SkipTicketUserId' - - $ref: '#/components/parameters/TicketSortOrder' - - $ref: '#/components/parameters/TicketId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SessionId' + - $ref: '#/components/parameters/UserId' + /v2/users/{userId}/skips: get: - operationId: ListTicketSkips tags: - - Ticket Skips + - Ticket Skips summary: List Ticket Skips description: | Archived tickets are not included in the response. See @@ -11967,6 +12339,7 @@ paths: * Agents with "View only" or higher reports permissions in Support. These permissions are distinct from Explore permissions. * Agents retrieving their own skips + operationId: ListTicketSkips responses: "200": description: Success response @@ -11977,11 +12350,15 @@ paths: examples: default: $ref: '#/components/examples/TicketSkipResponseExample' - /api/v2/users/autocomplete: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/SkipTicketUserId' + - $ref: '#/components/parameters/TicketSortOrder' + - $ref: '#/components/parameters/TicketId' + /v2/users/autocomplete: get: - operationId: AutocompleteUsers tags: - - Users + - Users summary: Autocomplete Users description: | Returns an array of users whose name starts with the value specified in the `name` parameter. @@ -11990,18 +12367,21 @@ paths: #### Allowed For * Agents + operationId: AutocompleteUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: name - in: query - description: | - The name to search for the user. - required: true - schema: - type: string - example: gil - - $ref: '#/components/parameters/LookupRelationshipAutocompleteFieldIdFragment' - - $ref: '#/components/parameters/LookupRelationshipAutocompleteSourceFragment' + - $ref: '#/components/parameters/AcceptHeader' + - name: name + in: query + description: | + The name to search for the user + required: true + style: form + explode: true + schema: + type: string + example: gil + - $ref: '#/components/parameters/LookupRelationshipAutocompleteFieldIdFragment' + - $ref: '#/components/parameters/LookupRelationshipAutocompleteSourceFragment' responses: "200": description: Success response @@ -12012,11 +12392,10 @@ paths: examples: default: $ref: '#/components/examples/SearchUsersResponseExample' - /api/v2/users/count: + /v2/users/count: get: - operationId: CountUsers tags: - - Users + - Users summary: Count Users description: | Returns an approximate count of users. If the count exceeds 100,000, it is updated every 24 hours. @@ -12029,11 +12408,12 @@ paths: #### Allowed For * Admins, Agents and Light Agents + operationId: CountUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/UserRoleFilter' - - $ref: '#/components/parameters/UserRolesFilter' - - $ref: '#/components/parameters/UserPermissionSetFilter' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/UserRoleFilter' + - $ref: '#/components/parameters/UserRolesFilter' + - $ref: '#/components/parameters/UserPermissionSetFilter' responses: "200": description: Success response @@ -12044,11 +12424,10 @@ paths: examples: default: $ref: '#/components/examples/UserCountResponseExample' - /api/v2/users/create_many: + /v2/users/create_many: post: - operationId: CreateManyUsers tags: - - Users + - Users summary: Create Many Users description: | Accepts an array of up to 100 user objects. @@ -12068,8 +12447,8 @@ paths: #### Response This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information. + operationId: CreateManyUsers requestBody: - required: true content: application/json: schema: @@ -12077,6 +12456,7 @@ paths: examples: default: $ref: '#/components/examples/UsersCreateManyRequestExample' + required: true responses: "200": description: Success response @@ -12087,11 +12467,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/users/create_or_update: + /v2/users/create_or_update: post: - operationId: CreateOrUpdateUser tags: - - Users + - Users summary: Create Or Update User description: | Creates a user if the user does not already exist, or updates an existing user @@ -12115,8 +12494,8 @@ paths: #### Allowed For * Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage end users or team members + operationId: CreateOrUpdateUser requestBody: - required: true content: application/json: schema: @@ -12124,9 +12503,10 @@ paths: examples: default: $ref: '#/components/examples/UserRequestExample' + required: true responses: "200": - description: Successful response, when user exits + description: "Successful response, when user exits" content: application/json: schema: @@ -12135,7 +12515,7 @@ paths: default: $ref: '#/components/examples/UserCreateResponseExample' "201": - description: Created response, when user is new + description: "Created response, when user is new" content: application/json: schema: @@ -12143,15 +12523,28 @@ paths: examples: default: $ref: '#/components/examples/UserCreateResponseExample' - /api/v2/users/create_or_update_many: + /v2/users/create_or_update_many: post: - operationId: CreateOrUpdateManyUsers tags: - - Users + - Users summary: Create Or Update Many Users - description: "Accepts an array of up to 100 user objects. For each user, the user is created if it does not\nalready exist, or the existing user is updated.\n\n**Note**: To protect the data in your Zendesk account, bulk user imports are not enabled by default in Zendesk accounts. The account owner must contact [Zendesk Customer Support](https://support.zendesk.com/hc/en-us/articles/4408843597850) to enable the imports. A 403 Forbidden\nerror is returned if data imports are not enabled. \n\nEach individual user object can identify an existing user by `email` or by `external_id`.\n\nThis endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information.\n\n#### Allowed For\n\n* Admins and [agents in custom roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd) to manage end users or team members\n" + description: "Accepts an array of up to 100 user objects. For each user, the\ + \ user is created if it does not\nalready exist, or the existing user is updated.\n\ + \n**Note**: To protect the data in your Zendesk account, bulk user imports\ + \ are not enabled by default in Zendesk accounts. The account owner must contact\ + \ [Zendesk Customer Support](https://support.zendesk.com/hc/en-us/articles/4408843597850)\ + \ to enable the imports. A 403 Forbidden\nerror is returned if data imports\ + \ are not enabled. \n\nEach individual user object can identify an existing\ + \ user by `email` or by `external_id`.\n\nThis endpoint returns a `job_status`\ + \ [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format)\ + \ and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status)\ + \ endpoint to check for the job's completion. Only a certain number of jobs\ + \ can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit)\ + \ for more information.\n\n#### Allowed For\n\n* Admins and [agents in custom\ + \ roles with permission](https://support.zendesk.com/hc/en-us/articles/4408882153882#topic_cxn_hig_bd)\ + \ to manage end users or team members\n" + operationId: CreateOrUpdateManyUsers requestBody: - required: true content: application/json: schema: @@ -12159,6 +12552,7 @@ paths: examples: default: $ref: '#/components/examples/UsersRequestExample' + required: true responses: "200": description: Success response @@ -12169,11 +12563,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/users/destroy_many: + /v2/users/destroy_many: delete: - operationId: DestroyManyUsers tags: - - Users + - Users summary: Bulk Delete Users description: | Accepts a comma-separated list of up to 100 user ids. @@ -12187,20 +12580,28 @@ paths: #### Response This endpoint returns a `job_status` [JSON object](/api-reference/ticketing/ticket-management/job_statuses/#json-format) and queues a background job to do the work. Use the [Show Job Status](/api-reference/ticketing/ticket-management/job_statuses/#show-job-status) endpoint to check for the job's completion. Only a certain number of jobs can be queued or running at the same time. See [Job limit](/api-reference/introduction/rate-limits/#job-limit) for more information. + operationId: DestroyManyUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Id of the users to delete. Comma separated - schema: - type: string - example: 1,2,3 - - name: external_ids - in: query - description: External Id of the users to delete. Comma separated - schema: - type: string - example: abc,def,ghi + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Id of the users to delete. Comma separated + required: false + style: form + explode: true + schema: + type: string + example: "1,2,3" + - name: external_ids + in: query + description: External Id of the users to delete. Comma separated + required: false + style: form + explode: true + schema: + type: string + example: "abc,def,ghi" + x-ballerina-name: externalIds responses: "200": description: Success response @@ -12211,11 +12612,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusBulkDeleteResponseExample' - /api/v2/users/logout_many: + /v2/users/logout_many: post: - operationId: LogoutManyUsers tags: - - Users + - Users summary: Logout many users description: | Accepts a comma-separated list of up to 100 user ids. @@ -12223,15 +12623,19 @@ paths: #### Allowed For: * Admins + operationId: LogoutManyUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: | - Accepts a comma-separated list of up to 100 user ids. - schema: - type: string - example: 1,2 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: | + Accepts a comma-separated list of up to 100 user ids + required: false + style: form + explode: true + schema: + type: string + example: "1,2" responses: "202": description: Accepted response @@ -12242,11 +12646,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/users/me: + /v2/users/me: get: - operationId: ShowCurrentUser tags: - - Users + - Users summary: Show Self description: | #### Allowed For @@ -12258,6 +12661,7 @@ paths: The endpoint returns an `authenticity_token`. Zendesk API calls made by end users from a Zendesk help center must include this token in the `X-CSRF-Token` HTTP header. This helps prevent [cross-site request forgery (CSRF)](https://en.wikipedia.org/wiki/Cross-site_request_forgery) attacks. For an example using an authenticity token, see the AJAX request in the [Upgrading from Templating API v1](https://developer.zendesk.com/documentation/help_center/help-center-templates/v1#jquery) documentation. + operationId: ShowCurrentUser responses: "200": description: Success response @@ -12268,11 +12672,10 @@ paths: examples: default: $ref: '#/components/examples/CurrentUserResponseExample' - /api/v2/users/me/logout: + /v2/users/me/logout: delete: - operationId: DeleteAuthenticatedSession tags: - - Sessions + - Sessions summary: Delete the Authenticated Session description: | Deletes the current session. In practice, this only works when using session auth for requests, such as client-side requests @@ -12281,19 +12684,20 @@ paths: #### Allowed For * Admins, Agents, End users + operationId: DeleteAuthenticatedSession responses: "204": description: No Content - /api/v2/users/me/session: + /v2/users/me/session: get: - operationId: ShowCurrentlyAuthenticatedSession tags: - - Sessions + - Sessions summary: Show the Currently Authenticated Session description: | #### Allowed For * Admins, Agents, End users + operationId: ShowCurrentlyAuthenticatedSession responses: "200": description: Success response @@ -12304,16 +12708,16 @@ paths: examples: default: $ref: '#/components/examples/SessionResponseExample' - /api/v2/users/me/session/renew: + /v2/users/me/session/renew: get: - operationId: RenewCurrentSession tags: - - Sessions + - Sessions summary: Renew the current session description: | #### Allowed For * Admins, Agents, End users + operationId: RenewCurrentSession responses: "200": description: Success response @@ -12324,11 +12728,10 @@ paths: examples: default: $ref: '#/components/examples/RenewSessionResponseExample' - /api/v2/users/request_create: + /v2/users/request_create: post: - operationId: RequestUserCreate tags: - - Users + - Users summary: Request User Create description: | Sends the owner a reminder email to update their subscription so more agents can be created. @@ -12336,8 +12739,8 @@ paths: #### Allowed For * Agents + operationId: RequestUserCreate requestBody: - required: true content: application/json: schema: @@ -12345,6 +12748,7 @@ paths: examples: default: $ref: '#/components/examples/RequestUserCreateRequestExample' + required: true responses: "200": description: description @@ -12355,11 +12759,10 @@ paths: description: Empty response example: "" example: "" - /api/v2/users/search: + /v2/users/search: get: - operationId: SearchUsers tags: - - Users + - Users summary: Search Users description: | Returns an array of users who meet the search criteria. @@ -12373,26 +12776,34 @@ paths: #### Allowed For * Admins, Agents and Light Agents + operationId: SearchUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: | - The `query` parameter supports the Zendesk search syntax for more advanced - user searches. It can specify a partial or full value of any - user property, including name, email address, notes, or phone. Example: - `query="jdoe"`. - See the [Search API](/api-reference/ticketing/ticket-management/search/). - schema: - type: string - example: jdoe - - name: external_id - in: query - description: | - The `external_id` parameter does not support the search syntax. It only accepts ids. - schema: - type: string - example: abc124 + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: | + The `query` parameter supports the Zendesk search syntax for more advanced + user searches. It can specify a partial or full value of any + user property, including name, email address, notes, or phone. Example: + `query="jdoe"`. + See the [Search API](/api-reference/ticketing/ticket-management/search/) + required: false + style: form + explode: true + schema: + type: string + example: jdoe + - name: external_id + in: query + description: | + The `external_id` parameter does not support the search syntax. It only accepts ids + required: false + style: form + explode: true + schema: + type: string + example: abc124 + x-ballerina-name: externalId responses: "200": description: Success response @@ -12403,11 +12814,10 @@ paths: examples: default: $ref: '#/components/examples/SearchUsersResponseExample' - /api/v2/users/show_many: + /v2/users/show_many: get: - operationId: ShowManyUsers tags: - - Users + - Users summary: Show Many Users description: | Accepts a comma-separated list of up to 100 user ids or external ids. @@ -12415,22 +12825,30 @@ paths: #### Allowed For: * Agents + operationId: ShowManyUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: | - Accepts a comma-separated list of up to 100 user ids. - schema: - type: string - example: 1,2 - - name: external_ids - in: query - description: | - Accepts a comma-separated list of up to 100 external ids. - schema: - type: string - example: abc,def + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: | + Accepts a comma-separated list of up to 100 user ids + required: false + style: form + explode: true + schema: + type: string + example: "1,2" + - name: external_ids + in: query + description: | + Accepts a comma-separated list of up to 100 external ids + required: false + style: form + explode: true + schema: + type: string + example: "abc,def" + x-ballerina-name: externalIds responses: "200": description: Success response @@ -12441,38 +12859,42 @@ paths: examples: default: $ref: '#/components/examples/ShowManyUsersResponseExample' - /api/v2/users/update_many: + /v2/users/update_many: put: - operationId: UpdateManyUsers tags: - - Users + - Users summary: Update Many Users + operationId: UpdateManyUsers parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: Id of the users to update. Comma separated - schema: - type: string - example: 1,2,3 - - name: external_ids - in: query - description: External Id of the users to update. Comma separated - schema: - type: string - example: abc,def,ghi + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: Id of the users to update. Comma separated + required: false + style: form + explode: true + schema: + type: string + example: "1,2,3" + - name: external_ids + in: query + description: External Id of the users to update. Comma separated + required: false + style: form + explode: true + schema: + type: string + example: "abc,def,ghi" + x-ballerina-name: externalIds requestBody: - required: true content: application/json: schema: - oneOf: - - $ref: '#/components/schemas/UserRequest' - - $ref: '#/components/schemas/UsersRequest' - additionalProperties: true + $ref: '#/components/schemas/UsersUpdateManyBody' examples: default: $ref: '#/components/examples/UpdateManyUsersRequestExample' + required: true responses: "200": description: Successful response @@ -12483,11 +12905,10 @@ paths: examples: default: $ref: '#/components/examples/JobStatusResponseExample' - /api/v2/views: + /v2/views: get: - operationId: ListViews tags: - - Views + - Views summary: List Views description: | Lists shared and personal views available to the current user. @@ -12513,33 +12934,55 @@ paths: #### Allowed For * Agents + operationId: ListViews parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: access - in: query - description: Only views with given access. May be "personal", "shared", or "account" - schema: - type: string - - name: active - in: query - description: Only active views if true, inactive views if false - schema: - type: boolean - - name: group_id - in: query - description: Only views belonging to given group - schema: - type: integer - - name: sort_by - in: query - description: Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" - schema: - type: string - - name: sort_order - in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: access + in: query + description: "Only views with given access. May be \"personal\", \"shared\"\ + , or \"account\"" + required: false + style: form + explode: true + schema: + type: string + - name: active + in: query + description: "Only active views if true, inactive views if false" + required: false + style: form + explode: true + schema: + type: boolean + - name: group_id + in: query + description: Only views belonging to given group + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: groupId + - name: sort_by + in: query + description: "Possible values are \"alphabetical\", \"created_at\", or \"\ + updated_at\". Defaults to \"position\"" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -12551,9 +12994,8 @@ paths: default: $ref: '#/components/examples/ViewsResponseExample' post: - operationId: CreateView tags: - - Views + - Views summary: Create View description: | #### Allowed For @@ -12671,6 +13113,7 @@ paths: |-----------------------------| ----------- | `group_by`, `sort_by` | Sort or group the tickets by a column in the [View columns](#view-columns) table. The `subject` and `submitter` columns are not supported | `group_order`, `sort_order` | Either "asc" or "desc" + operationId: CreateView responses: "200": description: Success response @@ -12681,19 +13124,16 @@ paths: examples: default: $ref: '#/components/examples/ViewCreateResponseExample' - /api/v2/views/{view_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ViewId' + /v2/views/{viewId}: get: - operationId: ShowView tags: - - Views + - Views summary: Show View description: | #### Allowed For * Agents + operationId: ShowView responses: "200": description: Success response @@ -12705,9 +13145,8 @@ paths: default: $ref: '#/components/examples/ViewResponseExample' put: - operationId: UpdateView tags: - - Views + - Views summary: Update View description: | #### Allowed For @@ -12764,6 +13203,7 @@ paths: } } ``` + operationId: UpdateView responses: "200": description: Success response @@ -12775,24 +13215,23 @@ paths: default: $ref: '#/components/examples/ViewUpdateResponseExample' delete: - operationId: DeleteView tags: - - Views + - Views summary: Delete View description: | #### Allowed For * Agents + operationId: DeleteView responses: "204": description: No Content response - /api/v2/views/{view_id}/count: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ViewId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ViewId' + /v2/views/{viewId}/count: get: - operationId: GetViewCount tags: - - Views + - Views summary: Count Tickets in View description: | Returns the ticket count for a single view. @@ -12828,6 +13267,7 @@ paths: } } ``` + operationId: GetViewCount responses: "200": description: Success response @@ -12838,14 +13278,13 @@ paths: examples: default: $ref: '#/components/examples/ViewCountResponseExample' - /api/v2/views/{view_id}/execute: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ViewId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ViewId' + /v2/views/{viewId}/execute: get: - operationId: ExecuteView tags: - - Views + - Views summary: Execute View description: | Returns the column titles and the rows of the specified view. @@ -12874,18 +13313,29 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ExecuteView parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: sort_by - in: query - description: The ticket field used for sorting. This will either be a title or a custom field id. - schema: - type: string - - name: sort_order - in: query - description: The direction the tickets are sorted. May be one of 'asc' or 'desc' - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: sort_by + in: query + description: The ticket field used for sorting. This will either be a title + or a custom field id + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: The direction the tickets are sorted. May be one of 'asc' or + 'desc' + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -12896,14 +13346,13 @@ paths: examples: default: $ref: '#/components/examples/ViewExecuteResponseExample' - /api/v2/views/{view_id}/export: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ViewId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ViewId' + /v2/views/{viewId}/export: get: - operationId: ExportView tags: - - Views + - Views summary: Export View description: | Returns the csv attachment of the specified view if possible. Enqueues a job to produce the csv if necessary. @@ -12911,6 +13360,7 @@ paths: #### Allowed For * Agents + operationId: ExportView responses: "200": description: Success response @@ -12921,14 +13371,13 @@ paths: examples: default: $ref: '#/components/examples/ViewExportResponseExample' - /api/v2/views/{view_id}/tickets: parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/ViewId' + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ViewId' + /v2/views/{viewId}/tickets: get: - operationId: ListTicketsFromView tags: - - Views + - Views summary: List Tickets From a View description: | #### Allowed For @@ -12940,18 +13389,29 @@ paths: * Offset pagination See [Pagination](/api-reference/introduction/pagination/). + operationId: ListTicketsFromView parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: sort_by - in: query - description: Sort or group the tickets by a column in the [View columns](#view-columns) table. The `subject` and `submitter` columns are not supported - schema: - type: string - - name: sort_order - in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: sort_by + in: query + description: "Sort or group the tickets by a column in the [View columns](#view-columns)\ + \ table. The `subject` and `submitter` columns are not supported" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -12962,11 +13422,13 @@ paths: examples: default: $ref: '#/components/examples/ViewListTicketsResponseEXample' - /api/v2/views/active: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/ViewId' + /v2/views/active: get: - operationId: ListActiveViews tags: - - Views + - Views summary: List Active Views description: | Lists active shared and personal views available to the current user. @@ -12991,28 +13453,47 @@ paths: #### Allowed For * Agents + operationId: ListActiveViews parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: access - in: query - description: Only views with given access. May be "personal", "shared", or "account" - schema: - type: string - - name: group_id - in: query - description: Only views belonging to given group - schema: - type: integer - - name: sort_by - in: query - description: Possible values are "alphabetical", "created_at", or "updated_at". Defaults to "position" - schema: - type: string - - name: sort_order - in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - schema: - type: string + - $ref: '#/components/parameters/AcceptHeader' + - name: access + in: query + description: "Only views with given access. May be \"personal\", \"shared\"\ + , or \"account\"" + required: false + style: form + explode: true + schema: + type: string + - name: group_id + in: query + description: Only views belonging to given group + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: groupId + - name: sort_by + in: query + description: "Possible values are \"alphabetical\", \"created_at\", or \"\ + updated_at\". Defaults to \"position\"" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder responses: "200": description: Success response @@ -13023,11 +13504,10 @@ paths: examples: default: $ref: '#/components/examples/ViewsActiveResponseExample' - /api/v2/views/compact: + /v2/views/compact: get: - operationId: ListCompactViews tags: - - Views + - Views summary: List Views - Compact description: | A compacted list of shared and personal views available to the current user. This endpoint never returns more than 32 records and does not respect the "per_page" option. @@ -13035,6 +13515,7 @@ paths: #### Allowed For * Agents + operationId: ListCompactViews responses: "200": description: Success response @@ -13045,11 +13526,10 @@ paths: examples: default: $ref: '#/components/examples/ViewsResponseExample' - /api/v2/views/count: + /v2/views/count: get: - operationId: CountViews tags: - - Views + - Views summary: Count Views description: |- Returns an approximate count of shared and personal views available to the current user. If the count exceeds 100,000, the count will return a cached result. This cached result will update every 24 hours. @@ -13061,6 +13541,7 @@ paths: #### Allowed For * Agents + operationId: CountViews responses: "200": description: Count of views @@ -13071,11 +13552,10 @@ paths: examples: default: $ref: '#/components/examples/ViewsCountResponseExample' - /api/v2/views/count_many: + /v2/views/count_many: get: - operationId: GetViewCounts tags: - - Views + - Views summary: Count Tickets in Views description: | Returns the ticket count of each view in a list of views. Accepts up to 20 view ids per request. For the ticket count of a single view, see [Count Tickets in View](#count-tickets-in-view). @@ -13087,15 +13567,18 @@ paths: #### Allowed For * Agents + operationId: GetViewCounts parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: List of view's ids separated by commas. - required: true - schema: - type: string - example: 1,2,3 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: List of view's ids separated by commas + required: true + style: form + explode: true + schema: + type: string + example: "1,2,3" responses: "200": description: Success response @@ -13106,34 +13589,35 @@ paths: examples: default: $ref: '#/components/examples/ViewCountsResponseExample' - /api/v2/views/destroy_many: + /v2/views/destroy_many: delete: - operationId: BulkDeleteViews tags: - - Views + - Views summary: Bulk Delete Views description: | Deletes the views corresponding to the provided list of IDs. #### Allowed For * Agents + operationId: BulkDeleteViews parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: The IDs of the views to delete - required: true - schema: - type: string - example: 1,2,3 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: The IDs of the views to delete + required: true + style: form + explode: true + schema: + type: string + example: "1,2,3" responses: "204": description: No Content response - /api/v2/views/preview: + /v2/views/preview: post: - operationId: PreviewViews tags: - - Views + - Views summary: Preview Views description: | You can preview views by constructing the conditions in the proper format and nesting them under the `view` property. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference/). The output can also be controlled by passing in any of the following parameters and nesting them under the `output` property. @@ -13151,6 +13635,7 @@ paths: #### Allowed For * Agents + operationId: PreviewViews responses: "200": description: Success response @@ -13161,11 +13646,10 @@ paths: examples: default: $ref: '#/components/examples/ViewPreviewResponseExample' - /api/v2/views/preview/count: + /v2/views/preview/count: post: - operationId: PreviewCount tags: - - Views + - Views summary: Preview Ticket Count description: | Returns the ticket count for a single preview. @@ -13173,6 +13657,7 @@ paths: #### Allowed For * Agents + operationId: PreviewCount responses: "200": description: Success response @@ -13183,11 +13668,10 @@ paths: examples: default: $ref: '#/components/examples/ViewCountResponseExample' - /api/v2/views/search: + /v2/views/search: get: - operationId: SearchViews tags: - - Views + - Views summary: Search Views description: | #### Pagination @@ -13208,46 +13692,73 @@ paths: | ---------------- | ------------- | app_installation | The app installation that requires each view, if present | permissions | The permissions for each view + operationId: SearchViews parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: query - in: query - description: Query string used to find all views with matching title - required: true - schema: - type: string - example: sales&group_id=25789188 - - name: access - in: query - description: Filter views by access. May be "personal", "shared", or "account" - schema: - type: string - - name: active - in: query - description: Filter by active views if true or inactive views if false - schema: - type: boolean - - name: group_id - in: query - description: Filter views by group - schema: - type: integer - - name: sort_by - in: query - description: Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the views are sorted by relevance - schema: - type: string - - name: sort_order - in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others - schema: - type: string - - name: include - in: query - description: A sideload to include in the response. See [Sideloads](#sideloads-3) - schema: - type: string - example: permissions + - $ref: '#/components/parameters/AcceptHeader' + - name: query + in: query + description: Query string used to find all views with matching title + required: true + style: form + explode: true + schema: + type: string + example: sales&group_id=25789188 + - name: access + in: query + description: "Filter views by access. May be \"personal\", \"shared\", or\ + \ \"account\"" + required: false + style: form + explode: true + schema: + type: string + - name: active + in: query + description: Filter by active views if true or inactive views if false + required: false + style: form + explode: true + schema: + type: boolean + - name: group_id + in: query + description: Filter views by group + required: false + style: form + explode: true + schema: + type: integer + x-ballerina-name: groupId + - name: sort_by + in: query + description: "Possible values are \"alphabetical\", \"created_at\", \"updated_at\"\ + , and \"position\". If unspecified, the views are sorted by relevance" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortBy + - name: sort_order + in: query + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true + schema: + type: string + x-ballerina-name: sortOrder + - name: include + in: query + description: "A sideload to include in the response. See [Sideloads](#sideloads-3)" + required: false + style: form + explode: true + schema: + type: string + example: permissions responses: "200": description: Success response @@ -13258,11 +13769,10 @@ paths: examples: default: $ref: '#/components/examples/ViewsResponseExample' - /api/v2/views/show_many: + /v2/views/show_many: get: - operationId: ListViewsById tags: - - Views + - Views summary: List Views By ID description: | #### Allowed For @@ -13277,20 +13787,26 @@ paths: | ---------------- | ------------- | app_installation | The app installation that requires each view, if present | permissions | The permissions for each view + operationId: ListViewsById parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: List of view's ids separated by commas. - required: true - schema: - type: string - example: 1,2,3 - - name: active - in: query - description: Only active views if true, inactive views if false - schema: - type: boolean + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: List of view's ids separated by commas + required: true + style: form + explode: true + schema: + type: string + example: "1,2,3" + - name: active + in: query + description: "Only active views if true, inactive views if false" + required: false + style: form + explode: true + schema: + type: boolean responses: "200": description: Success response @@ -13301,11 +13817,10 @@ paths: examples: default: $ref: '#/components/examples/ViewsResponseExample' - /api/v2/views/update_many: + /v2/views/update_many: put: - operationId: UpdateManyViews tags: - - Views + - Views summary: Update Many Views description: | #### Allowed For @@ -13336,6 +13851,7 @@ paths: ] } ``` + operationId: UpdateManyViews responses: "200": description: Success response @@ -13346,16 +13862,16 @@ paths: examples: default: $ref: '#/components/examples/ViewsUpdateManyResponseExample' - /api/v2/workspaces: + /v2/workspaces: get: - operationId: ListWorkspaces tags: - - Workspaces + - Workspaces summary: List Workspaces description: | #### Allowed For * Admins, Agents + operationId: ListWorkspaces responses: "200": description: Success Response @@ -13370,76 +13886,73 @@ paths: next_page: null previous_page: null workspaces: - - activated: true - apps: - - expand: false - id: 360000080413 - position: 1 - conditions: - all: - - field: ticket_form_id - operator: is - value: "360000014173" - any: [] - created_at: "2018-11-13T19:08:13Z" - description: Test rules - id: 3133 - macro_ids: - - 360005374974 + - activated: true + apps: + - expand: false + id: 360000080413 position: 1 - prefer_workspace_app_order: true - selected_macros: - - actions: - - field: status - value: solved - active: true - created_at: "2018-02-08T23:45:30Z" - description: null - id: 360005374974 - position: 9999 - restriction: - id: 360002226093 - ids: - - 360002226093 - type: Group - title: Close and redirect to topics - updated_at: "2018-11-08T22:27:00Z" - url: https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json - usage_7d: 0 - ticket_form_id: 360000014173 - title: Test Workspace 1 - updated_at: "2018-12-17T22:37:40Z" - url: https://{subdomain}.zendesk.com/api/v2/workspaces.json + conditions: + all: + - field: ticket_form_id + operator: is + value: "360000014173" + any: [] + created_at: 2018-11-13T19:08:13Z + description: Test rules + id: 3133 + macro_ids: + - 360005374974 + position: 1 + prefer_workspace_app_order: true + selected_macros: + - actions: + - field: status + value: solved + active: true + created_at: 2018-02-08T23:45:30Z + description: null + id: 360005374974 + position: 9999 + restriction: + id: 360002226093 + ids: + - 360002226093 + type: Group + title: Close and redirect to topics + updated_at: 2018-11-08T22:27:00Z + url: "https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json" + usage_7d: 0 + ticket_form_id: 360000014173 + title: Test Workspace 1 + updated_at: 2018-12-17T22:37:40Z + url: "https://{subdomain}.zendesk.com/api/v2/workspaces.json" post: - operationId: CreateWorkspace tags: - - Workspaces + - Workspaces summary: Create Workspace description: | #### Allowed For * Admins + operationId: CreateWorkspace requestBody: content: application/json: schema: - type: object - properties: - workspace: - $ref: '#/components/schemas/WorkspaceInput' + $ref: '#/components/schemas/V2WorkspacesBody' examples: default: value: workspace: conditions: all: - - field: ticket_form_id - operator: is - value: "360000014173" + - field: ticket_form_id + operator: is + value: "360000014173" any: [] description: Test rules macros: - - 360005374974 + - 360005374974 ticket_form_id: 360000014173 title: Test Workspace 1 responses: @@ -13448,10 +13961,7 @@ paths: content: application/json: schema: - type: object - properties: - workspace: - $ref: '#/components/schemas/WorkspaceObject' + $ref: '#/components/schemas/InlineResponse201' examples: default: value: @@ -13460,61 +13970,55 @@ paths: apps: [] conditions: all: - - field: ticket_form_id - operator: is - value: "360000014173" + - field: ticket_form_id + operator: is + value: "360000014173" any: [] - created_at: "2018-11-13T19:08:13Z" + created_at: 2018-11-13T19:08:13Z description: Test rules id: 3133 macro_ids: - - 360005374974 + - 360005374974 position: 1 prefer_workspace_app_order: true selected_macros: - - actions: - - field: status - value: solved - active: true - created_at: "2018-02-08T23:45:30Z" - description: null - id: 360005374974 - position: 9999 - restriction: - id: 360002226093 - ids: - - 360002226093 - type: Group - title: Close and redirect to topics - updated_at: "2018-11-08T22:27:00Z" - url: https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json - usage_7d: 0 + - actions: + - field: status + value: solved + active: true + created_at: 2018-02-08T23:45:30Z + description: null + id: 360005374974 + position: 9999 + restriction: + id: 360002226093 + ids: + - 360002226093 + type: Group + title: Close and redirect to topics + updated_at: 2018-11-08T22:27:00Z + url: "https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json" + usage_7d: 0 ticket_form_id: 360000014173 title: Test Workspace 1 - updated_at: "2018-12-17T22:37:40Z" - url: https://{subdomain}.zendesk.com/api/v2/workspaces.json - /api/v2/workspaces/{workspace_id}: - parameters: - - $ref: '#/components/parameters/AcceptHeader' - - $ref: '#/components/parameters/WorkspaceId' + updated_at: 2018-12-17T22:37:40Z + url: "https://{subdomain}.zendesk.com/api/v2/workspaces.json" + /v2/workspaces/{workspaceId}: get: - operationId: ShowWorkspace tags: - - Workspaces + - Workspaces summary: Show Workspace description: | #### Allowed For * Admins + operationId: ShowWorkspace responses: "200": description: Successful response content: application/json: schema: - type: object - properties: - workspace: - $ref: '#/components/schemas/WorkspaceObject' + $ref: '#/components/schemas/InlineResponse201' examples: default: value: @@ -13523,68 +14027,65 @@ paths: apps: [] conditions: all: - - field: ticket_form_id - operator: is - value: "360000014173" + - field: ticket_form_id + operator: is + value: "360000014173" any: [] - created_at: "2018-11-13T19:08:13Z" + created_at: 2018-11-13T19:08:13Z description: Test rules id: 3133 macro_ids: - - 360005374974 + - 360005374974 position: 1 prefer_workspace_app_order: true selected_macros: - - actions: - - field: status - value: solved - active: true - created_at: "2018-02-08T23:45:30Z" - description: null - id: 360005374974 - position: 9999 - restriction: - id: 360002226093 - ids: - - 360002226093 - type: Group - title: Close and redirect to topics - updated_at: "2018-11-08T22:27:00Z" - url: https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json - usage_7d: 0 + - actions: + - field: status + value: solved + active: true + created_at: 2018-02-08T23:45:30Z + description: null + id: 360005374974 + position: 9999 + restriction: + id: 360002226093 + ids: + - 360002226093 + type: Group + title: Close and redirect to topics + updated_at: 2018-11-08T22:27:00Z + url: "https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json" + usage_7d: 0 ticket_form_id: 360000014173 title: Test Workspace 1 - updated_at: "2018-12-17T22:37:40Z" - url: https://{subdomain}.zendesk.com/api/v2/workspaces.json + updated_at: 2018-12-17T22:37:40Z + url: "https://{subdomain}.zendesk.com/api/v2/workspaces.json" put: - operationId: UpdateWorkspace tags: - - Workspaces + - Workspaces summary: Update Workspace description: |- #### Allowed For * Admins + operationId: UpdateWorkspace requestBody: content: application/json: schema: - type: object - properties: - workspace: - $ref: '#/components/schemas/WorkspaceInput' + $ref: '#/components/schemas/V2WorkspacesBody' examples: default: value: workspace: conditions: all: - - field: ticket_form_id - operator: is - value: "360000014173" + - field: ticket_form_id + operator: is + value: "360000014173" any: [] description: Test rules macros: - - 360005374974 + - 360005374974 ticket_form_id: 360000014173 title: Test Workspace 1 responses: @@ -13593,10 +14094,7 @@ paths: content: application/json: schema: - type: object - properties: - workspace: - $ref: '#/components/schemas/WorkspaceObject' + $ref: '#/components/schemas/InlineResponse201' examples: default: value: @@ -13605,73 +14103,78 @@ paths: apps: [] conditions: all: - - field: ticket_form_id - operator: is - value: "360000014173" + - field: ticket_form_id + operator: is + value: "360000014173" any: [] - created_at: "2018-11-13T19:08:13Z" + created_at: 2018-11-13T19:08:13Z description: Test rules id: 3133 macro_ids: - - 360005374974 + - 360005374974 position: 1 prefer_workspace_app_order: true selected_macros: - - actions: - - field: status - value: solved - active: true - created_at: "2018-02-08T23:45:30Z" - description: null - id: 360005374974 - position: 9999 - restriction: - id: 360002226093 - ids: - - 360002226093 - type: Group - title: Close and redirect to topics - updated_at: "2018-11-08T22:27:00Z" - url: https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json - usage_7d: 0 + - actions: + - field: status + value: solved + active: true + created_at: 2018-02-08T23:45:30Z + description: null + id: 360005374974 + position: 9999 + restriction: + id: 360002226093 + ids: + - 360002226093 + type: Group + title: Close and redirect to topics + updated_at: 2018-11-08T22:27:00Z + url: "https://{subdomain}.zendesk.com/api/v2/macros/360005374974.json" + usage_7d: 0 ticket_form_id: 360000014173 title: Test Workspace 1 - updated_at: "2018-12-17T22:37:40Z" - url: https://{subdomain}.zendesk.com/api/v2/workspaces.json + updated_at: 2018-12-17T22:37:40Z + url: "https://{subdomain}.zendesk.com/api/v2/workspaces.json" delete: - operationId: DeleteWorkspace tags: - - Workspaces + - Workspaces summary: Delete Workspace description: | #### Allowed For * Admins + operationId: DeleteWorkspace responses: "204": description: No Content - /api/v2/workspaces/destroy_many: + parameters: + - $ref: '#/components/parameters/AcceptHeader' + - $ref: '#/components/parameters/WorkspaceId' + /v2/workspaces/destroy_many: delete: - operationId: DestroyManyWorkspaces tags: - - Workspaces + - Workspaces summary: Bulk Delete Workspaces description: | #### Allowed For * Admins + operationId: DestroyManyWorkspaces parameters: - - $ref: '#/components/parameters/AcceptHeader' - - name: ids - in: query - description: The ids of the workspaces to delete - required: true - schema: - type: array - items: - type: integer - example: - - 1 - - 2 - - 3 + - $ref: '#/components/parameters/AcceptHeader' + - name: ids + in: query + description: The ids of the workspaces to delete + required: true + style: form + explode: true + schema: + type: array + items: + type: integer + example: + - 1 + - 2 + - 3 responses: "200": description: Succesful response @@ -13682,33 +14185,28 @@ paths: description: Empty response example: "" example: "" - /api/v2/workspaces/reorder: + /v2/workspaces/reorder: put: - operationId: ReorderWorkspaces tags: - - Workspaces + - Workspaces summary: Reorder Workspaces description: | #### Allowed For * Admins + operationId: ReorderWorkspaces requestBody: content: application/json: schema: - type: object - properties: - ids: - type: array - items: - type: number + $ref: '#/components/schemas/WorkspacesReorderBody' examples: default: value: ids: - - 12 - - 32 - - 48 - - 60 + - 12 + - 32 + - 48 + - 60 responses: "200": description: Succesful response @@ -13721,6099 +14219,5528 @@ paths: example: "" components: schemas: - AccountSettingsActiveFeaturesObject: + TicketMetricEventBreachObject: + title: Ticket Metric Event + type: object + allOf: + - $ref: '#/components/schemas/TicketMetricEventBaseObject' + - $ref: '#/components/schemas/TicketMetricEventBreachObjectAllOf2' + TicketRelatedInformation: type: object - description: The active features for an account. See [Active Features](#active-features) properties: - advanced_analytics: - type: boolean - agent_forwarding: - type: boolean - allow_ccs: - type: boolean - allow_email_template_customization: - type: boolean - automatic_answers: - type: boolean - bcc_archiving: - type: boolean - benchmark_opt_out: - type: boolean - business_hours: - type: boolean - chat: - type: boolean - chat_about_my_ticket: - type: boolean - csat_reason_code: - type: boolean - custom_dkim_domain: - type: boolean - customer_context_as_default: - type: boolean - customer_satisfaction: - type: boolean - dynamic_contents: - type: boolean - explore: - type: boolean - explore_on_support_ent_plan: - type: boolean - explore_on_support_pro_plan: - type: boolean - facebook: - type: boolean - facebook_login: - type: boolean - fallback_composer: - type: boolean - forum_analytics: - type: boolean - good_data_and_explore: - type: boolean - google_login: - type: boolean - insights: - type: boolean - is_abusive: - type: boolean - light_agents: - type: boolean - markdown: - type: boolean - on_hold_status: - type: boolean - organization_access_enabled: - type: boolean - rich_content_in_emails: - type: boolean - sandbox: - type: boolean - satisfaction_prediction: - type: boolean - suspended_ticket_notification: - type: boolean - ticket_forms: - type: boolean - ticket_tagging: - type: boolean - topic_suggestion: - type: boolean twitter: + type: object + additionalProperties: true + description: X (formerly Twitter) information associated with the ticket + followup_source_ids: + type: array + items: + type: string + description: Sources to follow up + x-ballerina-name: followupSourceIds + incidents: + type: integer + description: A count of related incident occurrences + topic_id: + type: string + description: Related topic in the Web portal (deprecated feature) + nullable: true + x-ballerina-name: topicId + from_archive: type: boolean - twitter_login: - type: boolean - user_org_fields: - type: boolean - user_tagging: - type: boolean - voice: - type: boolean - AccountSettingsAgentObject: + description: Is true if the current ticket is archived + x-ballerina-name: fromArchive + AccountSettingsGoogleAppsObject: type: object - description: Configuration for the agent workspace. See [Agents](#agents) properties: - agent_home: - type: boolean - agent_workspace: - type: boolean - aw_self_serve_migration_enabled: - type: boolean - focus_mode: - type: boolean - idle_timeout_enabled: + has_google_apps_admin: type: boolean - unified_agent_statuses: + x-ballerina-name: hasGoogleAppsAdmin + has_google_apps: type: boolean - AccountSettingsApiObject: + x-ballerina-name: hasGoogleApps + description: "Google Apps configuration. See [G Suite](#g-suite)" + TargetCampfire: + required: + - room + - subdomain + - token type: object - description: API configuration options. See [API](#api) properties: - accepted_api_agreement: - type: boolean - api_password_access: - type: string - api_token_access: + subdomain: type: string - AccountSettingsAppsObject: - type: object - description: Apps configuration options. See [Apps](#apps) - properties: - create_private: - type: boolean - create_public: + preserve_format: type: boolean - use: + x-ballerina-name: preserveFormat + ssl: type: boolean - AccountSettingsBillingObject: - type: object - description: Billing configuration options. See [Billing](#billing) - properties: - backend: - type: string - AccountSettingsBrandingObject: - type: object - description: Branding settings. See [Branding](#branding) - properties: - favicon_url: - type: string - nullable: true - header_color: - type: string - header_logo_url: - type: string - nullable: true - page_background_color: - type: string - tab_background_color: + room: type: string - text_color: + token: type: string - AccountSettingsBrandsObject: + TriggerCategoryRuleCounts: type: object - description: Brand settings. See [Brands](#brands) properties: - default_brand_id: + inactive_count: type: integer - require_brand_on_new_tickets: - type: boolean - AccountSettingsCdnObject: + format: int64 + x-ballerina-name: inactiveCount + active_count: + type: integer + format: int64 + x-ballerina-name: activeCount + UserIdentityObject: + required: + - type + - user_id + - value type: object - description: CDN settings properties: - cdn_provider: - type: string - fallback_cdn_provider: + updated_at: type: string - hosts: - type: array - items: - type: object - properties: - name: - type: string - url: - type: string - AccountSettingsChatObject: - type: object - description: Zendesk Chat settings. See [Chat](#chat) - properties: - available: - type: boolean - enabled: - type: boolean - integrated: + description: The time the identity was updated + format: date-time + readOnly: true + x-ballerina-name: updatedAt + deliverable_state: + type: string + description: "Email identity type only. Indicates if Zendesk sends notifications\ + \ to the email address. See [Deliverable state](#deliverable-state)" + readOnly: true + x-ballerina-name: deliverableState + user_id: + type: integer + description: The id of the user + readOnly: true + x-ballerina-name: userId + undeliverable_count: + type: integer + description: The number of times a soft-bounce response was received at + that address + readOnly: true + x-ballerina-name: undeliverableCount + verified: type: boolean - maximum_request_count: + description: If the identity has been verified + created_at: + type: string + description: The time the identity was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + id: type: integer - welcome_message: + description: Automatically assigned on creation + readOnly: true + type: type: string - AccountSettingsCrossSellObject: + description: The type of this identity + readOnly: true + enum: + - email + - twitter + - facebook + - google + - phone_number + - agent_forwarding + - any_channel + - foreign + - sdk + value: + type: string + description: "The identifier for this identity, such as an email address" + readOnly: true + url: + type: string + description: The API url of this identity + readOnly: true + primary: + type: boolean + description: "If the identity is the primary identity. *Writable only when\ + \ creating, not when updating. Use the [Make Identity Primary](#make-identity-primary)\ + \ endpoint instead" + example: + created_at: 2011-07-20T22:55:29Z + deliverable_state: deliverable + id: 35436 + primary: true + type: email + updated_at: 2011-07-20T22:55:29Z + url: https://company.zendesk.com/api/v2/users/135/identities/35436.json + user_id: 135 + value: someone@example.com + verified: true + TargetResponse: type: object - description: Cross Sell settings properties: - show_chat_tooltip: - type: boolean - xsell_source: - type: string - nullable: true - AccountSettingsGooddataAdvancedAnalyticsObject: + target: + $ref: '#/components/schemas/TargetObject' + MacroApplyTicketResponseResultTicketComment: type: object - description: GoodData settings, used for insights. Legacy configuration prior to Zendesk Explore. See [GoodData Advanced Analytics](#gooddata-advanced-analytics) properties: - enabled: + public: type: boolean - AccountSettingsGoogleAppsObject: + scoped_body: + type: array + items: + type: array + items: + type: string + x-ballerina-name: scopedBody + body: + type: string + CustomRolesResponse: type: object - description: Google Apps configuration. See [G Suite](#g-suite) properties: - has_google_apps: - type: boolean - has_google_apps_admin: - type: boolean - AccountSettingsGroupObject: + custom_roles: + type: array + items: + $ref: '#/components/schemas/CustomRoleObject' + x-ballerina-name: customRoles + PaginationMeta: type: object - description: Group configuration properties: - check_group_name_uniqueness: + after_cursor: + type: string + x-ballerina-name: afterCursor + before_cursor: + type: string + x-ballerina-name: beforeCursor + has_more: type: boolean - AccountSettingsLimitsObject: + x-ballerina-name: hasMore + CustomFieldObject: + required: + - key + - title + - type type: object - description: Account limits configuration. See [Limits](#limits) properties: - attachment_size: + raw_title: + type: string + description: "The dynamic content placeholder, if present, or the `title`\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawTitle + custom_field_options: + type: array + description: Required and presented for a custom field of type "dropdown". + Each option is represented by an object with a `name` and `value` property + items: + $ref: '#/components/schemas/CustomFieldOptionObject' + x-ballerina-name: customFieldOptions + active: + type: boolean + description: "If true, this field is available for use" + created_at: + type: string + description: The time of the last update of the ticket field + format: date-time + readOnly: true + x-ballerina-name: createdAt + description: + type: string + description: User-defined description of this field's purpose + title: + type: string + description: The title of the custom field + type: + type: string + description: "The custom field type: \"checkbox\", \"date\", \"decimal\"\ + , \"dropdown\", \"integer\", [\"lookup\"](/api-reference/ticketing/lookup_relationships/lookup_relationships/),\ + \ \"regexp\", \"text\", or \"textarea\"" + raw_description: + type: string + description: "The dynamic content placeholder, if present, or the `description`\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawDescription + url: + type: string + description: The URL for this resource + readOnly: true + system: + type: boolean + description: "If true, only active and position values of this field can\ + \ be changed" + readOnly: true + updated_at: + type: string + description: The time of the last update of the ticket field + format: date-time + readOnly: true + x-ballerina-name: updatedAt + relationship_target_type: + type: string + description: "A representation of what type of object the field references.\ + \ Options are \"zen:user\", \"zen:organization\", \"zen:ticket\", and\ + \ \"zen:custom_object:{key}\" where key is a custom object key. For example\ + \ \"zen:custom_object:apartment\"" + x-ballerina-name: relationshipTargetType + regexp_for_validation: + type: string + description: Regular expression field only. The validation pattern for a + field value to be deemed valid + nullable: true + x-ballerina-name: regexpForValidation + relationship_filter: + type: object + description: A filter definition that allows your autocomplete to filter + down results + x-ballerina-name: relationshipFilter + id: type: integer - AccountSettingsLocalizationObject: + description: Automatically assigned upon creation + readOnly: true + position: + type: integer + description: Ordering of the field relative to other fields + tag: + type: string + description: Optional for custom field of type "checkbox"; not presented + otherwise + key: + type: string + description: "A unique key that identifies this custom field. This is used\ + \ for updating the field and referencing in placeholders. The key must\ + \ consist of only letters, numbers, and underscores. It can't be only\ + \ numbers and can't be reused if deleted" + RecoverSuspendedTicketResponse: type: object - description: Internationalization configuration settings. See [Localization](#localization) properties: - locale_ids: + ticket: type: array items: - type: integer - AccountSettingsLotusObject: + $ref: '#/components/schemas/SuspendedTicketObject' + TicketCommentResponse: type: object - description: Support UI settings. See [Lotus](#lotus) properties: - pod_id: - type: integer - prefer_lotus: - type: boolean - reporting: - type: boolean - AccountSettingsMetricsObject: + comment: + $ref: '#/components/schemas/TicketCommentObject' + DeletedUserResponse: type: object - description: Account metrics settings. See [Metrics](#metrics) properties: - account_size: + deleted_user: + allOf: + - $ref: '#/components/schemas/DeletedUserObject' + x-ballerina-name: deletedUser + TagCountResponse: + type: object + properties: + count: + $ref: '#/components/schemas/TagCountObject' + OrganizationsResponse: + type: object + properties: + next_page: type: string - AccountSettingsObject: + nullable: true + x-ballerina-name: nextPage + count: + type: integer + organizations: + type: array + items: + $ref: '#/components/schemas/OrganizationObject' + previous_page: + type: string + nullable: true + x-ballerina-name: previousPage + TriggerCategoryResponse: type: object properties: - active_features: - $ref: '#/components/schemas/AccountSettingsActiveFeaturesObject' - agents: - $ref: '#/components/schemas/AccountSettingsAgentObject' - api: - $ref: '#/components/schemas/AccountSettingsApiObject' - apps: - $ref: '#/components/schemas/AccountSettingsAppsObject' - billing: - $ref: '#/components/schemas/AccountSettingsBillingObject' - branding: - $ref: '#/components/schemas/AccountSettingsBrandingObject' - brands: - $ref: '#/components/schemas/AccountSettingsBrandsObject' - cdn: - $ref: '#/components/schemas/AccountSettingsCdnObject' - chat: - $ref: '#/components/schemas/AccountSettingsChatObject' - cross_sell: - $ref: '#/components/schemas/AccountSettingsCrossSellObject' - gooddata_advanced_analytics: - $ref: '#/components/schemas/AccountSettingsGooddataAdvancedAnalyticsObject' - google_apps: - $ref: '#/components/schemas/AccountSettingsGoogleAppsObject' - groups: - $ref: '#/components/schemas/AccountSettingsGroupObject' - limits: - $ref: '#/components/schemas/AccountSettingsLimitsObject' - localization: - $ref: '#/components/schemas/AccountSettingsLocalizationObject' - lotus: - $ref: '#/components/schemas/AccountSettingsLotusObject' - metrics: - $ref: '#/components/schemas/AccountSettingsMetricsObject' - onboarding: - $ref: '#/components/schemas/AccountSettingsOnboardingObject' - routing: - $ref: '#/components/schemas/AccountSettingsRoutingObject' - rule: - $ref: '#/components/schemas/AccountSettingsRuleObject' - side_conversations: - $ref: '#/components/schemas/AccountSettingsSideConversationsObject' - statistics: - $ref: '#/components/schemas/AccountSettingsStatisticsObject' - ticket_form: - $ref: '#/components/schemas/AccountSettingsTicketFormObject' - ticket_sharing_partners: - $ref: '#/components/schemas/AccountSettingsTicketSharingPartnersObject' - tickets: - $ref: '#/components/schemas/AccountSettingsTicketObject' - twitter: - $ref: '#/components/schemas/AccountSettingsTwitterObject' - user: - $ref: '#/components/schemas/AccountSettingsUserObject' - voice: - $ref: '#/components/schemas/AccountSettingsVoiceObject' - example: - active_features: - advanced_analytics: false - agent_forwarding: false - allow_ccs: true - allow_email_template_customization: true - automatic_answers: false - bcc_archiving: false - benchmark_opt_out: false - business_hours: false - chat: false - chat_about_my_ticket: false - csat_reason_code: false - custom_dkim_domain: true - customer_context_as_default: false - customer_satisfaction: false - dynamic_contents: false - explore: true - explore_on_support_ent_plan: false - explore_on_support_pro_plan: false - facebook: false - facebook_login: false - fallback_composer: false - forum_analytics: true - good_data_and_explore: false - google_login: false - insights: false - is_abusive: false - light_agents: false - markdown: false - on_hold_status: false - organization_access_enabled: true - rich_content_in_emails: true - sandbox: false - satisfaction_prediction: false - suspended_ticket_notification: false - ticket_forms: true - ticket_tagging: true - topic_suggestion: false - twitter: true - twitter_login: false - user_org_fields: true - user_tagging: true - voice: true - agents: - agent_home: false - agent_workspace: false - aw_self_serve_migration_enabled: true - focus_mode: false - idle_timeout_enabled: false - unified_agent_statuses: false - api: - accepted_api_agreement: true - api_password_access: "true" - api_token_access: "true" - apps: - create_private: true - create_public: false - use: true - billing: - backend: zuora - branding: - favicon_url: null - header_color: 78A300 - header_logo_url: null - page_background_color: "333333" - tab_background_color: 7FA239 - text_color: FFFFFF - brands: - default_brand_id: 1873 - require_brand_on_new_tickets: false - cdn: - cdn_provider: default - fallback_cdn_provider: cloudfront - hosts: - - name: default - url: https://p18.zdassets.com - - name: cloudfront - url: https://d2y9oszrd3dhjh.cloudfront.net - chat: - available: true - enabled: false - integrated: true - maximum_request_count: 1 - welcome_message: Hi there. How can I help today? - cross_sell: - show_chat_tooltip: true - xsell_source: null - gooddata_advanced_analytics: - enabled: true - google_apps: - has_google_apps: false - has_google_apps_admin: false - groups: - check_group_name_uniqueness: true - limits: - attachment_size: 52428800 - localization: - locale_ids: - - 1042 - lotus: - pod_id: 999 - prefer_lotus: true - reporting: true - metrics: - account_size: 100-399 - onboarding: - checklist_onboarding_version: 2 - onboarding_segments: null - product_sign_up: null - routing: - autorouting_tag: "" - enabled: false - max_email_capacity: 0 - max_messaging_capacity: 0 - reassignment_messaging_enabled: true - reassignment_messaging_timeout: 30 - reassignment_talk_timeout: 30 - rule: - macro_most_used: true - macro_order: alphabetical - skill_based_filtered_views: [] - using_skill_based_routing: false - side_conversations: - email_channel: false - msteams_channel: false - show_in_context_panel: false - slack_channel: false - tickets_channel: false - statistics: - forum: true - rule_usage: true - search: true - ticket_form: - raw_ticket_forms_instructions: Please choose your issue below - ticket_forms_instructions: Please choose your issue below - ticket_sharing_partners: - support_addresses: - - support@grokpetre.zendesk.com - tickets: - accepted_new_collaboration_tos: false - agent_collision: true - agent_invitation_enabled: true - agent_ticket_deletion: false - allow_group_reset: true - assign_default_organization: true - assign_tickets_upon_solve: true - auto_translation_enabled: false - auto_updated_ccs_followers_rules: false - chat_sla_enablement: false - collaboration: true - comments_public_by_default: true - email_attachments: false - emoji_autocompletion: true - follower_and_email_cc_collaborations: false - has_color_text: true - is_first_comment_private_enabled: true - light_agent_email_ccs_allowed: false - list_empty_views: true - list_newest_comments_first: true - markdown_ticket_comments: false - maximum_personal_views_to_list: 8 - private_attachments: false - rich_text_comments: true - status_hold: false - tagging: true - using_skill_based_routing: false - twitter: - shorten_url: optional - user: - agent_created_welcome_emails: true - end_user_phone_number_validation: false - have_gravatars_enabled: true - language_selection: true - multiple_organizations: false - tagging: true - time_zone_selection: true - voice: - agent_confirmation_when_forwarding: true - agent_wrap_up_after_calls: true - enabled: true - logging: true - maximum_queue_size: 5 - maximum_queue_wait_time: 1 - only_during_business_hours: false - outbound_enabled: true - recordings_public: true - uk_mobile_forwarding: true - AccountSettingsOnboardingObject: + trigger_category: + allOf: + - $ref: '#/components/schemas/TriggerCategory' + x-ballerina-name: triggerCategory + TicketObject: + required: + - requester_id type: object - description: Onboarding settings properties: - checklist_onboarding_version: - type: integer - onboarding_segments: + from_messaging_channel: + type: boolean + description: "If true, the ticket's [via type](/documentation/ticketing/reference-guides/via-object-reference/)\ + \ is a messaging channel" + readOnly: true + x-ballerina-name: fromMessagingChannel + metadata: + type: object + description: "Write only. Metadata for the audit. In the `audit` object,\ + \ the data is specified in the `custom` property of the `metadata` object.\ + \ See [Setting Metadata](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-metadata)" + writeOnly: true + email_cc_ids: + type: array + description: "The ids of agents or end users currently CC'ed on the ticket.\ + \ See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233)\ + \ in the Support Help Center" + items: + type: integer + x-ballerina-name: emailCcIds + subject: type: string - nullable: true - product_sign_up: + description: | + The value of the subject field for this ticket. See [Subject](/api-reference/ticketing/tickets/tickets/#subject) + voice_comment: + type: object + description: "Write only. See [Creating voicemail ticket](/api-reference/voice/talk-partner-edition-api/reference/#creating-voicemail-tickets)" + writeOnly: true + x-ballerina-name: voiceComment + macro_ids: + type: array + description: POST requests only. List of macro IDs to be recorded in the + ticket audit + items: + type: integer + x-ballerina-name: macroIds + type: + type: string + description: The type of this ticket + enum: + - problem + - incident + - question + - task + updated_stamp: + type: string + description: Write only. Datetime of last update received from API. See + the `safe_update` property + writeOnly: true + x-ballerina-name: updatedStamp + via: + description: "For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference)" + allOf: + - $ref: '#/components/schemas/TicketObjectVia' + email_ccs: + type: object + description: "Write only. An array of objects that represent agent or end\ + \ users email CCs to add or delete from the ticket. See [Setting email\ + \ CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-email-ccs)" + writeOnly: true + x-ballerina-name: emailCcs + collaborators: + type: array + description: "POST requests only. Users to add as cc's when creating a ticket.\ + \ See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators)" + items: + $ref: '#/components/schemas/CollaboratorObject' + due_at: type: string + description: "If this is a ticket of type \"task\" it has a due date. Due\ + \ date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format" + format: date-time nullable: true - AccountSettingsResponse: - type: object - properties: - settings: - $ref: '#/components/schemas/AccountSettingsObject' - example: - settings: - active_features: - advanced_analytics: false - agent_forwarding: false - allow_ccs: true - allow_email_template_customization: true - automatic_answers: false - bcc_archiving: false - benchmark_opt_out: false - business_hours: false - chat: false - chat_about_my_ticket: false - csat_reason_code: false - custom_dkim_domain: true - customer_context_as_default: false - customer_satisfaction: false - dynamic_contents: false - explore: true - explore_on_support_ent_plan: false - explore_on_support_pro_plan: false - facebook: false - facebook_login: false - fallback_composer: false - forum_analytics: true - good_data_and_explore: false - google_login: false - insights: false - is_abusive: false - light_agents: false - markdown: false - on_hold_status: false - organization_access_enabled: true - rich_content_in_emails: true - sandbox: false - satisfaction_prediction: false - suspended_ticket_notification: false - ticket_forms: true - ticket_tagging: true - topic_suggestion: false - twitter: true - twitter_login: false - user_org_fields: true - user_tagging: true - voice: true - agents: - agent_home: false - agent_workspace: false - aw_self_serve_migration_enabled: true - focus_mode: false - idle_timeout_enabled: false - unified_agent_statuses: false - api: - accepted_api_agreement: true - api_password_access: "true" - api_token_access: "true" - apps: - create_private: true - create_public: false - use: true - billing: - backend: zuora - branding: - favicon_url: null - header_color: 78A300 - header_logo_url: null - page_background_color: "333333" - tab_background_color: 7FA239 - text_color: FFFFFF - brands: - default_brand_id: 1873 - require_brand_on_new_tickets: false - cdn: - cdn_provider: default - fallback_cdn_provider: cloudfront - hosts: - - name: default - url: https://p18.zdassets.com - - name: cloudfront - url: https://d2y9oszrd3dhjh.cloudfront.net - chat: - available: true - enabled: false - integrated: true - maximum_request_count: 1 - welcome_message: Hi there. How can I help today? - cross_sell: - show_chat_tooltip: true - xsell_source: null - gooddata_advanced_analytics: - enabled: true - google_apps: - has_google_apps: false - has_google_apps_admin: false - groups: - check_group_name_uniqueness: true - limits: - attachment_size: 52428800 - localization: - locale_ids: - - 1042 - lotus: - pod_id: 999 - prefer_lotus: true - reporting: true - metrics: - account_size: 100-399 - onboarding: - checklist_onboarding_version: 2 - onboarding_segments: null - product_sign_up: null - routing: - autorouting_tag: "" - enabled: false - max_email_capacity: 0 - max_messaging_capacity: 0 - rule: - macro_most_used: true - macro_order: alphabetical - skill_based_filtered_views: [] - using_skill_based_routing: false - side_conversations: - email_channel: false - msteams_channel: false - show_in_context_panel: false - slack_channel: false - tickets_channel: false - statistics: - forum: true - rule_usage: true - search: true - ticket_form: - raw_ticket_forms_instructions: Please choose your issue below - ticket_forms_instructions: Please choose your issue below - ticket_sharing_partners: - support_addresses: - - support@grokpetre.zendesk.com - tickets: - accepted_new_collaboration_tos: false - agent_collision: true - agent_invitation_enabled: true - agent_ticket_deletion: false - allow_group_reset: true - assign_default_organization: true - assign_tickets_upon_solve: true - auto_translation_enabled: false - auto_updated_ccs_followers_rules: false - chat_sla_enablement: false - collaboration: true - comments_public_by_default: true - email_attachments: false - emoji_autocompletion: true - follower_and_email_cc_collaborations: false - has_color_text: true - is_first_comment_private_enabled: true - light_agent_email_ccs_allowed: false - list_empty_views: true - list_newest_comments_first: true - markdown_ticket_comments: false - maximum_personal_views_to_list: 8 - private_attachments: false - rich_text_comments: true - status_hold: false - tagging: true - using_skill_based_routing: false - twitter: - shorten_url: optional - user: - agent_created_welcome_emails: true - end_user_phone_number_validation: false - have_gravatars_enabled: true - language_selection: true - multiple_organizations: false - tagging: true - time_zone_selection: true - voice: - agent_confirmation_when_forwarding: true - agent_wrap_up_after_calls: true - enabled: true - logging: true - maximum_queue_size: 5 - maximum_queue_wait_time: 1 - only_during_business_hours: false - outbound_enabled: true - recordings_public: true - uk_mobile_forwarding: true - AccountSettingsRoutingObject: - type: object - description: Configuration for routing. See [Routing](#routing) - properties: - autorouting_tag: + x-ballerina-name: dueAt + id: + type: integer + description: Automatically assigned when the ticket is created + readOnly: true + raw_subject: type: string - enabled: + description: | + The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + x-ballerina-name: rawSubject + requester: + type: object + description: "Write only. See [Creating a ticket with a new requester](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#creating-a-ticket-with-a-new-requester)" + writeOnly: true + safe_update: type: boolean - max_email_capacity: - type: integer - max_messaging_capacity: - type: integer - reassignment_messaging_enabled: + description: "Write only. Optional boolean. When true and an `update_stamp`\ + \ date is included, protects against ticket update collisions and returns\ + \ a message to let you know if one occurs. See [Protecting against ticket\ + \ update collisions](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#protecting-against-ticket-update-collisions).\ + \ A value of false has the same effect as true. Omit the property to force\ + \ the updates to not be safe" + writeOnly: true + x-ballerina-name: safeUpdate + custom_fields: + type: array + description: "Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values)" + items: + $ref: '#/components/schemas/TicketObjectCustomFields' + x-ballerina-name: customFields + allow_channelback: type: boolean - reassignment_messaging_timeout: + description: "Is false if channelback is disabled, true otherwise. Only\ + \ applicable for channels framework ticket" + readOnly: true + x-ballerina-name: allowChannelback + satisfaction_rating: + type: object + additionalProperties: true + description: "The satisfaction rating of the ticket, if it exists, or the\ + \ state of satisfaction, \"offered\" or \"unoffered\". The value is null\ + \ for plan types that don't support CSAT" + readOnly: true + x-ballerina-name: satisfactionRating + priority: + type: string + description: The urgency with which the ticket should be addressed + enum: + - urgent + - high + - normal + - low + brand_id: type: integer - reassignment_talk_timeout: + description: "The id of the brand this ticket is associated with. See [Setting\ + \ up multiple brands](https://support.zendesk.com/hc/en-us/articles/4408829476378)" + x-ballerina-name: brandId + tags: + type: array + description: The array of tags applied to this ticket + items: + type: string + followers: + type: object + description: "Write only. An array of objects that represent agent followers\ + \ to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-followers)" + writeOnly: true + sharing_agreement_ids: + type: array + description: The ids of the sharing agreements used for this ticket + readOnly: true + items: + type: integer + x-ballerina-name: sharingAgreementIds + organization_id: type: integer - AccountSettingsRuleObject: - type: object - description: Rules settings for triggers, macros, views, and automations. See [Rules](#rules) - properties: - macro_most_used: + description: "The organization of the requester. You can only specify the\ + \ ID of an organization associated with the requester. See [Organization\ + \ Memberships](/api-reference/ticketing/organizations/organization_memberships/)" + x-ballerina-name: organizationId + via_followup_source_id: + type: integer + description: "POST requests only. The id of a closed ticket when creating\ + \ a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket)" + x-ballerina-name: viaFollowupSourceId + has_incidents: type: boolean - macro_order: - type: string - skill_based_filtered_views: + description: "Is true if a ticket is a problem type and has one or more\ + \ incidents linked to it. Otherwise, the value is false" + readOnly: true + x-ballerina-name: hasIncidents + attribute_value_ids: type: array + description: Write only. An array of the IDs of attribute values to be associated + with the ticket + writeOnly: true items: - type: object - additionalProperties: true - using_skill_based_routing: + type: integer + x-ballerina-name: attributeValueIds + via_id: + type: integer + description: "Write only. For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference/)" + writeOnly: true + x-ballerina-name: viaId + requester_id: + type: integer + description: The user who requested this ticket + x-ballerina-name: requesterId + status: + type: string + description: | + The state of the ticket. + + If your account has activated custom ticket statuses, this is the ticket's + status category. See [custom ticket statuses](#custom-ticket-statuses) + enum: + - new + - open + - pending + - hold + - solved + - closed + created_at: + type: string + description: When this record was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + custom_status_id: + type: integer + description: "The custom ticket status id of the ticket. See [custom ticket\ + \ statuses](#custom-ticket-statuses)" + x-ballerina-name: customStatusId + description: + type: string + description: | + Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) + readOnly: true + external_id: + type: string + description: An id you can use to link Zendesk Support tickets to local + records + x-ballerina-name: externalId + allow_attachments: type: boolean - AccountSettingsSideConversationsObject: - type: object - description: Side conversations settings - properties: - email_channel: - type: boolean - msteams_channel: - type: boolean - show_in_context_panel: - type: boolean - slack_channel: - type: boolean - tickets_channel: - type: boolean - AccountSettingsStatisticsObject: - type: object - description: Account statistics settings. See [Statistics](#statistics) - properties: - forum: - type: boolean - rule_usage: - type: boolean - search: - type: boolean - AccountSettingsTicketFormObject: - type: object - description: Ticket form settings. See [Ticket Form](#ticket-form) - properties: - raw_ticket_forms_instructions: + description: Permission for agents to add add attachments to a comment. + Defaults to true + readOnly: true + x-ballerina-name: allowAttachments + assignee_email: type: string - ticket_forms_instructions: + description: Write only. The email address of the agent to assign the ticket + to + writeOnly: true + x-ballerina-name: assigneeEmail + updated_at: type: string - AccountSettingsTicketObject: - type: object - description: Ticket settings. See [Tickets](#tickets) - properties: - accepted_new_collaboration_tos: - type: boolean - agent_collision: - type: boolean - agent_invitation_enabled: - type: boolean - agent_ticket_deletion: - type: boolean - allow_group_reset: - type: boolean - assign_default_organization: - type: boolean - assign_tickets_upon_solve: - type: boolean - auto_translation_enabled: - type: boolean - auto_updated_ccs_followers_rules: - type: boolean - chat_sla_enablement: - type: boolean - collaboration: - type: boolean - comments_public_by_default: - type: boolean - email_attachments: - type: boolean - emoji_autocompletion: - type: boolean - follower_and_email_cc_collaborations: - type: boolean - has_color_text: - type: boolean - is_first_comment_private_enabled: - type: boolean - light_agent_email_ccs_allowed: - type: boolean - list_empty_views: - type: boolean - list_newest_comments_first: - type: boolean - markdown_ticket_comments: - type: boolean - maximum_personal_views_to_list: + description: "When this record last got updated. It is updated only if the\ + \ update generates a [ticket event](#incremental-ticket-event-export)" + format: date-time + readOnly: true + x-ballerina-name: updatedAt + problem_id: type: integer - private_attachments: - type: boolean - rich_text_comments: - type: boolean - status_hold: - type: boolean - tagging: - type: boolean - using_skill_based_routing: - type: boolean - AccountSettingsTicketSharingPartnersObject: - type: object - description: Ticket sharing partners settings. See [Ticket Sharing Partners](#ticket-sharing-partners) - properties: - support_addresses: + description: "For tickets of type \"incident\", the ID of the problem the\ + \ incident is linked to" + x-ballerina-name: problemId + follower_ids: type: array + description: "The ids of agents currently following the ticket. See [CCs\ + \ and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233)" items: - type: string - AccountSettingsTwitterObject: - type: object - description: X (formerly Twitter) settings. See [X](#x-formerly-twitter) - properties: - shorten_url: + type: integer + x-ballerina-name: followerIds + assignee_id: + type: integer + description: The agent currently assigned to the ticket + x-ballerina-name: assigneeId + forum_topic_id: + type: integer + description: "The topic in the Zendesk Web portal this ticket originated\ + \ from, if any. The Web portal is deprecated" + readOnly: true + x-ballerina-name: forumTopicId + macro_id: + type: integer + description: Write only. A macro ID to be recorded in the ticket audit + writeOnly: true + x-ballerina-name: macroId + submitter_id: + type: integer + description: The user who submitted the ticket. The submitter always becomes + the author of the first comment on the ticket + x-ballerina-name: submitterId + collaborator_ids: + type: array + description: The ids of users currently CC'ed on the ticket + items: + type: integer + x-ballerina-name: collaboratorIds + url: type: string - AccountSettingsUserObject: - type: object - description: User settings. See [Users](#users) - properties: - agent_created_welcome_emails: - type: boolean - end_user_phone_number_validation: - type: boolean - have_gravatars_enabled: - type: boolean - language_selection: - type: boolean - multiple_organizations: - type: boolean - tagging: - type: boolean - time_zone_selection: - type: boolean - AccountSettingsVoiceObject: - type: object - description: Zendesk Talk settings. See [Voice](#voice) - properties: - agent_confirmation_when_forwarding: - type: boolean - agent_wrap_up_after_calls: - type: boolean - enabled: - type: boolean - logging: - type: boolean - maximum_queue_size: + description: The API url of this ticket + readOnly: true + ticket_form_id: type: integer - maximum_queue_wait_time: + description: Enterprise only. The id of the ticket form to render for the + ticket + x-ballerina-name: ticketFormId + group_id: type: integer - only_during_business_hours: - type: boolean - outbound_enabled: - type: boolean - recordings_public: - type: boolean - uk_mobile_forwarding: + description: The group this ticket is assigned to + x-ballerina-name: groupId + followup_ids: + type: array + description: The ids of the followups created from this ticket. Ids are + only visible once the ticket is closed + readOnly: true + items: + type: integer + x-ballerina-name: followupIds + is_public: type: boolean - ActionObject: + description: "Is true if any comments are public, false otherwise" + readOnly: true + x-ballerina-name: isPublic + recipient: + type: string + description: The original recipient e-mail address of the ticket. Notification + emails for the ticket are sent from this address + comment: + type: object + description: "Write only. An object that adds a comment to the ticket. See\ + \ [Ticket comments](/api-reference/ticketing/tickets/ticket_comments/).\ + \ To include an attachment with the comment, see [Attaching files](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#attaching-files)" + writeOnly: true + example: + assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + custom_status_id: 123 + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + from_messaging_channel: false + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + BatchErrorItemAllOf2: type: object properties: - field: + trigger_id: type: string - description: The name of a ticket field to modify - value: - type: string - description: The new value of the field - ActionsObject: + x-ballerina-name: triggerId + AttachmentUploadResponseUpload: type: object properties: - actions: + attachments: type: array items: - $ref: '#/components/schemas/ActionObject' - ActivitiesCountResponse: + $ref: '#/components/schemas/AttachmentObject' + attachment: + $ref: '#/components/schemas/AttachmentObject' + token: + type: string + description: Token for subsequent request + readOnly: true + TrialAccountResponse: type: object properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - ActivitiesResponse: + account: + $ref: '#/components/schemas/TrialAccountObject' + TicketFieldsResponse: type: object properties: - activities: - type: array - items: - $ref: '#/components/schemas/ActivityObject' - readOnly: true - actors: + ticket_fields: type: array items: - type: object - additionalProperties: true - readOnly: true - count: - type: integer - readOnly: true + $ref: '#/components/schemas/TicketFieldObject' + x-ballerina-name: ticketFields + TicketAuditsResponseNoneCursor: + type: object + properties: next_page: type: string nullable: true readOnly: true + x-ballerina-name: nextPage + count: + type: integer + readOnly: true previous_page: type: string nullable: true readOnly: true - users: + x-ballerina-name: previousPage + audits: type: array items: - type: object - additionalProperties: true - readOnly: true - example: - activities: - - actor: - active: true - alias: "" - created_at: "2020-11-17T00:32:12Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: cgoddard+ted@zendesk.com - external_id: null - iana_time_zone: America/Juneau - id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Tedd - notes: "" - only_private_comments: false - organization_id: null - phone: null - photo: null - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: "" - suspended: false - tags: [] - ticket_restriction: null - time_zone: Alaska - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" - url: https://example.zendesk.com/api/v2/users/158488612.json - user_fields: - its_remember_september: null - skittles: null - user_field_1: null - verified: true - actor_id: 158488612 - created_at: "2020-11-17T00:34:40Z" - id: 29183462 - object: - ticket: - id: 1521 - subject: test - target: - ticket: - id: 1521 - subject: test - title: 'Tedd assigned ticket #1521 to you.' - updated_at: "2020-11-17T00:34:40Z" - url: https://example.zendesk.com/api/v2/activities/29183462.json - user: - active: true - alias: test - created_at: "2017-08-14T20:13:53Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: user@zendesk.com - external_id: oev7jj - iana_time_zone: Pacific/Pago_Pago - id: 3343 - last_login_at: "2020-11-16T22:57:45Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Samwise Gamgee - notes: test - only_private_comments: false - organization_id: 1873 - phone: null - photo: - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - deleted: false - file_name: 1f84950b8d7949b3.gif - height: 80 - id: 8730791 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - size: 4566 - thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 - url: https://example.zendesk.com/api/v2/attachments/8730791.json - width: 80 - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: test - suspended: false - tags: - - "101" - ticket_restriction: null - time_zone: American Samoa - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" - url: https://example.zendesk.com/api/v2/users/3343.json - user_fields: - its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" - user_field_1: "101" - verified: true - user_id: 3343 - verb: tickets.assignment - actors: - - active: true - alias: "" - created_at: "2020-11-17T00:32:12Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: cgoddard+ted@zendesk.com - external_id: null - iana_time_zone: America/Juneau - id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Tedd - notes: "" - only_private_comments: false - organization_id: null - phone: null - photo: null - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: "" - suspended: false - tags: [] - ticket_restriction: null - time_zone: Alaska - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" - url: https://example.zendesk.com/api/v2/users/158488612.json - user_fields: - its_remember_september: null - skittles: null - user_field_1: null - verified: true - count: 1 - next_page: null - previous_page: null + $ref: '#/components/schemas/TicketAuditObject' + CursorBasedExportIncrementalUsersResponse: + type: object + properties: + before_url: + type: string + nullable: true + x-ballerina-name: beforeUrl + end_of_stream: + type: boolean + x-ballerina-name: endOfStream + after_cursor: + type: string + nullable: true + x-ballerina-name: afterCursor + after_url: + type: string + nullable: true + x-ballerina-name: afterUrl + before_cursor: + type: string + nullable: true + x-ballerina-name: beforeCursor users: - - active: true - alias: test - created_at: "2017-08-14T20:13:53Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: user@zendesk.com - external_id: oev7jj - iana_time_zone: Pacific/Pago_Pago - id: 3343 - last_login_at: "2020-11-16T22:57:45Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Samwise Gamgee - notes: test - only_private_comments: false - organization_id: 1873 - phone: null - photo: - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - deleted: false - file_name: 1f84950b8d7949b3.gif - height: 80 - id: 8730791 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - size: 4566 - thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 - url: https://example.zendesk.com/api/v2/attachments/8730791.json - width: 80 - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: test - suspended: false - tags: - - "101" - ticket_restriction: null - time_zone: American Samoa - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" - url: https://example.zendesk.com/api/v2/users/3343.json - user_fields: - its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" - user_field_1: "101" - verified: true - ActivityObject: - title: Ticket Activities + type: array + items: + $ref: '#/components/schemas/UserObject' + example: + after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 + after_url: https://example.zendesk.com/api/v2/incremental/users/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8 + before_cursor: null + before_url: null + end_of_stream: true + users: + - active: true + alias: Mr. Johnny + created_at: 2009-07-20T22:55:29Z + custom_role_id: 9373643 + details: "" + email: johnny@example.com + external_id: sai989sur98w9 + id: 35436 + last_login_at: 2011-05-05T10:38:52Z + locale: en-US + locale_id: 1 + moderator: true + name: Johnny Agent + notes: Johnny is a nice guy! + only_private_comments: false + organization_id: 57542 + phone: "+15551234567" + photo: + content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png + id: 928374 + name: my_funny_profile_pic.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png + id: 928375 + name: my_funny_profile_pic_thumb.png + size: 58298 + restricted_agent: true + role: agent + role_type: 0 + shared: false + shared_agent: false + signature: "Have a nice day, Johnny" + suspended: true + tags: + - enterprise + - other_tag + ticket_restriction: assigned + time_zone: Copenhagen + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/users/35436.json + user_fields: + user_date: 2012-07-23T00:00:00Z + user_decimal: 5.1 + user_dropdown: option_1 + verified: true + RequestsResponse: type: object properties: - actor: - type: object - description: The full user record of the user responsible for the ticket activity. See [Users](/api-reference/ticketing/users/users/) - allOf: - - $ref: '#/components/schemas/UserObject' - readOnly: true - actor_id: - type: integer - description: The id of the user responsible for the ticket activity. An `actor_id` of "-1" is a Zendesk system user, such as an automations action. - readOnly: true - created_at: + requests: + type: array + items: + $ref: '#/components/schemas/RequestObject' + ReverseLookupResponse: + type: object + anyOf: + - $ref: '#/components/schemas/UsersResponse' + WorkspaceResponse: + type: object + allOf: + - $ref: '#/components/schemas/WorkspaceResponseAllOf1' + - $ref: '#/components/schemas/OffsetPaginationObject' + AssigneeFieldAssignableAgentObject: + title: AssigneeFieldAssignableAgents + type: object + properties: + avatar_url: type: string - description: When the record was created - readOnly: true + description: URL of Agent's avatar + nullable: true + x-ballerina-name: avatarUrl + name: + type: string + description: Name of the agent id: type: integer - description: Automatically assigned on creation - readOnly: true - object: - type: object - description: The content of the activity. Can be a ticket, comment, or change. - additionalProperties: true + description: Agent Support ID + example: + avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png + id: 6473829100 + name: Joe Smith + InlineResponse2001Count: + properties: + refreshed_at: + type: string + description: The time the last count was performed + format: date-time readOnly: true - target: - type: object - description: The target of the activity, a ticket. - additionalProperties: true + value: + type: integer + description: Number of records at the time of the latest count operation readOnly: true - title: + CustomFieldOptionsResponse: + type: object + properties: + next_page: type: string - description: Description of the activity + description: URL of the next page + nullable: true readOnly: true - updated_at: - type: string - description: When the record was last updated + x-ballerina-name: nextPage + custom_field_options: + type: array + items: + $ref: '#/components/schemas/CustomFieldOptionObject' + x-ballerina-name: customFieldOptions + count: + type: integer + description: Total count of records retrieved readOnly: true - url: + previous_page: type: string - description: The API url of the activity + description: URL of the previous page + nullable: true readOnly: true - user: - type: object - description: The full user record of the agent making the request. See [Users](/api-reference/ticketing/users/users/) - allOf: - - $ref: '#/components/schemas/UserObject' + x-ballerina-name: previousPage + TicketMetricEventGroupSLAObject: + title: Ticket Metric Event + type: object + allOf: + - $ref: '#/components/schemas/TicketMetricEventBaseObject' + - $ref: '#/components/schemas/TicketMetricEventGroupSLAObjectAllOf2' + MacroAttachmentsResponse: + type: object + properties: + macro_attachments: + type: array + items: + $ref: '#/components/schemas/MacroAttachmentObject' + x-ballerina-name: macroAttachments + SkillBasedRoutingAttributesResponse: + type: object + properties: + next_page: + type: string + nullable: true readOnly: true - user_id: + x-ballerina-name: nextPage + count: type: integer - description: The id of the agent making the request readOnly: true - verb: + attributes: + type: array + items: + $ref: '#/components/schemas/SkillBasedRoutingAttributeObject' + previous_page: type: string - description: The type of activity. Can be "tickets.assignment", "tickets.comment", or "tickets.priority_increase" + nullable: true readOnly: true - example: - actor: - id: 8678530 - name: James A. Rosen - actor_id: 23546 - created_at: "2019-03-05T10:38:52Z" - id: 35 - object: {} - target: {} - title: 'John Hopeful assigned ticket #123 to you' - updated_at: "2019-03-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/activities/35.json - user: - id: 223443 - name: Johnny Agent - user_id: 29451 - verb: tickets.assignment - ActivityResponse: + x-ballerina-name: previousPage + TargetFailureResponse: type: object properties: - activity: - $ref: '#/components/schemas/ActivityObject' - example: - activity: - actor: - active: true - alias: "" - created_at: "2020-11-17T00:32:12Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: cgoddard+ted@zendesk.com - external_id: null - iana_time_zone: America/Juneau - id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Tedd - notes: "" - only_private_comments: false - organization_id: null - phone: null - photo: null - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: "" - suspended: false - tags: [] - ticket_restriction: null - time_zone: Alaska - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" - url: https://example.zendesk.com/api/v2/users/158488612.json - user_fields: - its_remember_september: null - skittles: null - user_field_1: null - verified: true - actor_id: 158488612 - created_at: "2020-11-17T00:34:40Z" - id: 29183462 - object: - ticket: - id: 1521 - subject: test - target: - ticket: - id: 1521 - subject: test - title: 'Tedd assigned ticket #1521 to you.' - updated_at: "2020-11-17T00:34:40Z" - url: https://example.zendesk.com/api/v2/activities/29183462.json - user: - active: true - alias: test - created_at: "2017-08-14T20:13:53Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: user@zendesk.com - external_id: oev7jj - iana_time_zone: Pacific/Pago_Pago - id: 3343 - last_login_at: "2020-11-16T22:57:45Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Samwise Gamgee - notes: test - only_private_comments: false - organization_id: 1873 - phone: null - photo: - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - deleted: false - file_name: 1f84950b8d7949b3.gif - height: 80 - id: 8730791 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - size: 4566 - thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 - url: https://example.zendesk.com/api/v2/attachments/8730791.json - width: 80 - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: test - suspended: false - tags: - - "101" - ticket_restriction: null - time_zone: American Samoa - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" - url: https://example.zendesk.com/api/v2/users/3343.json - user_fields: - its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" - user_field_1: "101" - verified: true - user_id: 3343 - verb: tickets.assignment - AssigneeFieldAssignableAgentObject: - title: AssigneeFieldAssignableAgents + target_failure: + allOf: + - $ref: '#/components/schemas/TargetFailureObject' + x-ballerina-name: targetFailure + ListTicketProblemsResponse: + type: object + additionalProperties: true + TriggerCategoriesResponse: type: object properties: - avatar_url: - type: string - description: URL of Agent's avatar - nullable: true - id: - type: integer - description: Agent Support ID - name: - type: string - description: Name of the agent - example: - avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png - id: 6473829100 - name: Joe Smith - AssigneeFieldAssignableGroupAgentsResponse: + trigger_categories: + type: array + items: + $ref: '#/components/schemas/TriggerCategoriesResponseTriggerCategories' + x-ballerina-name: triggerCategories + TicketCommentObject: type: object properties: - agents: + metadata: + type: object + additionalProperties: true + description: "System information (web client, IP address, etc.) and comment\ + \ flags, if any. See [Comment flags](#comment-flags)" + readOnly: true + attachments: type: array + description: "Attachments, if any. See [Attachment](/api-reference/ticketing/tickets/ticket-attachments/)" + readOnly: true items: - $ref: '#/components/schemas/AssigneeFieldAssignableAgentObject' - count: - type: integer - description: Number of agents listed in `agents` property. - next_page: + $ref: '#/components/schemas/AttachmentObject' + html_body: type: string - nullable: true + description: "The comment formatted as HTML. See [Bodies](#bodies)" + x-ballerina-name: htmlBody + created_at: + type: string + description: The time the comment was created + format: date-time readOnly: true - previous_page: + x-ballerina-name: createdAt + plain_body: type: string - nullable: true + description: "The comment presented as plain text. See [Bodies](#bodies)" readOnly: true - example: - agents: - - avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png - id: 6473829100 - name: Joe Smith - - avatar_url: https://z3n-example.zendesk.com/system/photos/412005192023/my_profile.png - id: 9182736400 - name: Jane Doe - - avatar_url: https://z3n-example.zendesk.com/system/photos/887005192023/my_profile.png - id: 1928373460 - name: Cookie Monster - count: 3 - next_page: null - previous_page: null - AssigneeFieldAssignableGroupObject: - title: AssigneeFieldAssignableGroups - type: object - properties: - description: + x-ballerina-name: plainBody + body: type: string - description: Description of the group + description: "The comment string. See [Bodies](#bodies)" + type: + type: string + description: "`Comment` or `VoiceComment`. The JSON object for adding voice\ + \ comments to tickets is different. See [Adding voice comments to tickets](/documentation/ticketing/managing-tickets/adding-voice-comments-to-tickets)" readOnly: true - id: + uploads: + type: array + description: "List of tokens received from [uploading files](/api-reference/ticketing/tickets/ticket-attachments/#upload-files)\ + \ for comment attachments. The files are attached by creating or updating\ + \ tickets with the tokens. See [Attaching files](/api-reference/ticketing/tickets/tickets/#attaching-files)\ + \ in Tickets" + items: + type: string + via: + $ref: '#/components/schemas/TicketAuditViaObject' + audit_id: type: integer - description: Group ID + description: "The id of the ticket audit record. See [Show Audit](/api-reference/ticketing/tickets/ticket_audits/#show-audit)" readOnly: true - name: - type: string - description: Name of the group + x-ballerina-name: auditId + public: + type: boolean + description: true if a public comment; false if an internal note. The initial + value set on ticket creation persists for any additional comment unless + you change it + id: + type: integer + description: Automatically assigned when the comment is created readOnly: true + author_id: + type: integer + description: "The id of the comment author. See [Author id](#author-id)" + x-ballerina-name: authorId example: - description: Engineering team for bugs - id: 9182736455 - name: Engineering - AssigneeFieldAssignableGroupsAndAgentsSearchResponse: + attachments: + - content_type: text/plain + content_url: https://company.zendesk.com/attachments/crash.log + file_name: crash.log + id: 498483 + size: 2532 + thumbnails: [] + author_id: 123123 + body: Thanks for your help! + created_at: 2009-07-20T22:55:29Z + id: 1274 + metadata: + system: + client: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36\ + \ (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36" + ip_address: 1.1.1.1 + latitude: -37.000000000001 + location: "Melbourne, 07, Australia" + longitude: 144.0000000000002 + via: + channel: web + source: + from: {} + rel: web_widget + to: {} + public: true + type: Comment + TicketImportInput: type: object properties: - agents: + comments: type: array + additionalProperties: true + description: "The conversation between requesters, collaborators, and agents" items: - $ref: '#/components/schemas/AssigneeFieldAssignableSearchAgentObject' - count: + $ref: '#/components/schemas/TicketImportInputComments' + subject: + type: string + description: The value of the subject field for this ticket + description: + type: string + description: "Read-only first comment on the ticket. When [creating a ticket](#create-ticket),\ + \ use `comment` to set the description. See [Description and first comment](#description-and-first-comment)" + assignee_id: type: integer - description: Number of agents + groups listed from search result. - groups: + description: The agent currently assigned to the ticket + x-ballerina-name: assigneeId + requester_id: + type: integer + description: The user who requested this ticket + x-ballerina-name: requesterId + tags: type: array + description: The array of tags applied to this ticket items: - $ref: '#/components/schemas/AssigneeFieldAssignableSearchGroupObject' - example: - agents: - - group: Tech - group_id: 6574839201 - id: 8392017465 - name: Sam Technologist - photo_url: https://z3n-example.zendesk.com/system/photos/410305192023/my_profile.png - count: 2 - groups: - - id: 6574839201 - name: Tech - AssigneeFieldAssignableGroupsResponse: + type: string + TwitterChannelTwicketStatusResponse: type: object properties: - count: - type: integer - description: Number of groups listed in `groups` property. - groups: + statuses: type: array items: - $ref: '#/components/schemas/AssigneeFieldAssignableGroupObject' - next_page: - type: string - nullable: true - readOnly: true - previous_page: - type: string - nullable: true - readOnly: true - example: - count: 3 - groups: - - description: Engineering - id: 9182736455 - name: Group for Bugs for Engineering - - description: Product - id: 1928374655 - name: Group for feature requests - - description: Customer Support - id: 5519283746 - name: Group for customer inquiries - next_page: null - previous_page: null - AssigneeFieldAssignableSearchAgentObject: + $ref: '#/components/schemas/TwitterChannelTwicketStatusResponseStatuses' + AccountSettingsActiveFeaturesObject: type: object properties: - group: - type: string - description: Name of the agent's group - group_id: - type: integer - description: Agent's Group ID - id: - type: integer - description: Agent ID - name: - type: string - description: Name of the agent - photo_url: - type: string - description: URL of Avatar - nullable: true - example: - group: Engineering - group_id: 9182736455 - id: 6473829100 - name: Joe Smith - photo_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png - AssigneeFieldAssignableSearchGroupObject: + business_hours: + type: boolean + x-ballerina-name: businessHours + voice: + type: boolean + fallback_composer: + type: boolean + x-ballerina-name: fallbackComposer + bcc_archiving: + type: boolean + x-ballerina-name: bccArchiving + ticket_tagging: + type: boolean + x-ballerina-name: ticketTagging + benchmark_opt_out: + type: boolean + x-ballerina-name: benchmarkOptOut + allow_email_template_customization: + type: boolean + x-ballerina-name: allowEmailTemplateCustomization + csat_reason_code: + type: boolean + x-ballerina-name: csatReasonCode + twitter: + type: boolean + satisfaction_prediction: + type: boolean + x-ballerina-name: satisfactionPrediction + customer_satisfaction: + type: boolean + x-ballerina-name: customerSatisfaction + dynamic_contents: + type: boolean + x-ballerina-name: dynamicContents + advanced_analytics: + type: boolean + x-ballerina-name: advancedAnalytics + explore_on_support_pro_plan: + type: boolean + x-ballerina-name: exploreOnSupportProPlan + customer_context_as_default: + type: boolean + x-ballerina-name: customerContextAsDefault + markdown: + type: boolean + ticket_forms: + type: boolean + x-ballerina-name: ticketForms + agent_forwarding: + type: boolean + x-ballerina-name: agentForwarding + user_org_fields: + type: boolean + x-ballerina-name: userOrgFields + automatic_answers: + type: boolean + x-ballerina-name: automaticAnswers + good_data_and_explore: + type: boolean + x-ballerina-name: goodDataAndExplore + chat_about_my_ticket: + type: boolean + x-ballerina-name: chatAboutMyTicket + topic_suggestion: + type: boolean + x-ballerina-name: topicSuggestion + explore: + type: boolean + on_hold_status: + type: boolean + x-ballerina-name: onHoldStatus + insights: + type: boolean + light_agents: + type: boolean + x-ballerina-name: lightAgents + user_tagging: + type: boolean + x-ballerina-name: userTagging + facebook: + type: boolean + sandbox: + type: boolean + suspended_ticket_notification: + type: boolean + x-ballerina-name: suspendedTicketNotification + facebook_login: + type: boolean + x-ballerina-name: facebookLogin + rich_content_in_emails: + type: boolean + x-ballerina-name: richContentInEmails + allow_ccs: + type: boolean + x-ballerina-name: allowCcs + explore_on_support_ent_plan: + type: boolean + x-ballerina-name: exploreOnSupportEntPlan + is_abusive: + type: boolean + x-ballerina-name: isAbusive + organization_access_enabled: + type: boolean + x-ballerina-name: organizationAccessEnabled + twitter_login: + type: boolean + x-ballerina-name: twitterLogin + chat: + type: boolean + custom_dkim_domain: + type: boolean + x-ballerina-name: customDkimDomain + google_login: + type: boolean + x-ballerina-name: googleLogin + forum_analytics: + type: boolean + x-ballerina-name: forumAnalytics + description: "The active features for an account. See [Active Features](#active-features)" + BookmarkInput: type: object properties: - id: + ticket_id: type: integer - description: Group ID - name: - type: string - description: Name of the group - example: - id: 9182736455 - name: Engineering - AttachmentBaseObject: + description: The id of the ticket the bookmark is for + x-ballerina-name: ticketId + BookmarkResponse: type: object properties: - content_type: - type: string - description: 'The content type of the image. Example value: "image/png"' - readOnly: true - content_url: + bookmark: + $ref: '#/components/schemas/BookmarkObject' + CountOrganizationObject: + type: object + properties: + refreshed_at: type: string - description: A full URL where the attachment image file can be downloaded. The file may be hosted externally so take care not to inadvertently send Zendesk authentication credentials. See [Working with url properties](/documentation/ticketing/managing-tickets/working-with-url-properties) readOnly: true - deleted: - type: boolean - description: If true, the attachment has been deleted - readOnly: true - file_name: - type: string - description: The name of the image file + x-ballerina-name: refreshedAt + value: + type: integer readOnly: true - height: + IncrementalSkillBasedRoutingInstanceValue: + type: object + properties: + instance_id: type: string - description: The height of the image file in pixels. If height is unknown, returns null + description: Id of the associated agent or ticket readOnly: true + x-ballerina-name: instanceId id: - type: integer - description: Automatically assigned when created - readOnly: true - inline: - type: boolean - description: | - If true, the attachment is excluded from the attachment list and the attachment's URL - can be referenced within the comment of a ticket. Default is false - readOnly: true - malware_access_override: - type: boolean - description: If true, you can download an attachment flagged as malware. If false, you can't download such an attachment. - readOnly: true - malware_scan_result: type: string - description: 'The result of the malware scan. There is a delay between the time the attachment is uploaded and when the malware scan is completed. Usually the scan is done within a few seconds, but high load conditions can delay the scan results. Possible values: "malware_found", "malware_not_found", "failed_to_scan", "not_scanned"' + description: Automatically assigned when an instance value is created readOnly: true - mapped_content_url: + time: type: string - description: The URL the attachment image file has been mapped to - readOnly: true - size: - type: integer - description: The size of the image file in bytes + description: The time the instance value was created or deleted + format: date-time readOnly: true - url: + attribute_value_id: type: string - description: A URL to access the attachment details + description: Id of the associated attribute value readOnly: true - width: + x-ballerina-name: attributeValueId + type: type: string - description: The width of the image file in pixels. If width is unknown, returns null + description: "One of \"associate_agent\", \"unassociate_agent\", \"associate_ticket\"\ + , or \"unassociate_ticket\"" readOnly: true - AttachmentObject: - type: object - description: A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - allOf: - - $ref: '#/components/schemas/AttachmentBaseObject' - - $ref: '#/components/schemas/AttachmentThumbnails' - example: - content_type: image/png - content_url: https://company.zendesk.com/attachments/my_funny_profile_pic.png - file_name: my_funny_profile_pic.png - id: 928374 - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/attachments/my_funny_profile_pic_thumb.png - file_name: my_funny_profile_pic_thumb.png - id: 928375 - size: 58298 - AttachmentResponse: - type: object - properties: - attachment: - $ref: '#/components/schemas/AttachmentObject' - AttachmentThumbnails: + ChannelFrameworkPushResultsResponse: type: object properties: - thumbnails: + results: type: array - description: An array of attachment objects. Note that photo thumbnails do not have thumbnails + description: "An array of [result objects](#result-object)" items: - $ref: '#/components/schemas/AttachmentBaseObject' - readOnly: true - AttachmentUpdateInput: - type: object - properties: - malware_access_override: - type: boolean - description: If true, allows access to attachments with detected malware. - AttachmentUpdateRequest: - type: object - properties: - attachment: - $ref: '#/components/schemas/AttachmentUpdateInput' - AttachmentUploadResponse: - type: object - properties: - upload: - type: object - properties: - attachment: - $ref: '#/components/schemas/AttachmentObject' - attachments: - type: array - items: - $ref: '#/components/schemas/AttachmentObject' - token: - type: string - description: Token for subsequent request - readOnly: true - AuditLogObject: + $ref: '#/components/schemas/ChannelFrameworkResultObject' + AutomationObject: type: object properties: - action: - type: string - description: | - Type of change made. Possible values are "create", "destroy", "exported", "login", and "update" - readOnly: true - action_label: + raw_title: type: string - description: Localized string of action field - readOnly: true - actor_id: - type: integer - description: id of the user or system that initiated the change + description: The raw title of the automation readOnly: true - actor_name: - type: string - description: Name of the user or system that initiated the change + x-ballerina-name: rawTitle + default: + type: boolean + description: "If true, the automation is a default automation" readOnly: true - change_description: + updated_at: type: string - description: The description of the change that occurred + description: The time of the last update of the automation + format: date-time readOnly: true + x-ballerina-name: updatedAt + active: + type: boolean + description: Whether the automation is active created_at: type: string + description: The time the automation was created format: date-time - description: The time the audit got created readOnly: true + x-ballerina-name: createdAt id: type: integer - description: The id automatically assigned upon creation - readOnly: true - ip_address: - type: string - description: The IP address of the user doing the audit + description: Automatically assigned when created readOnly: true - source_id: + position: type: integer - description: The id of the item being audited - readOnly: true - source_label: - type: string - description: The name of the item being audited - readOnly: true - source_type: - type: string - description: | - Item type being audited. Typically describes the system where the change - was initiated. Possible values vary based on your account's Zendesk - products and activity. Common values include "apitoken", "rule", "ticket", - "user", and "zendesk/app_market/app". The "rule" value is used for - [automations](https://support.zendesk.com/hc/en-us/articles/4408832701850), - [macros](https://support.zendesk.com/hc/en-us/articles/4408844187034), - [triggers](https://support.zendesk.com/hc/en-us/articles/4408822236058), - [views](https://support.zendesk.com/hc/en-us/articles/4408888828570), - and other automated business rules - readOnly: true - url: + description: The position of the automation which specifies the order it + will be executed + conditions: + $ref: '#/components/schemas/ConditionsObject' + title: type: string - description: The URL to access the audit log - readOnly: true + description: The title of the automation + actions: + type: array + description: "An object describing what the automation will do. See [Actions\ + \ reference](/documentation/ticketing/reference-guides/actions-reference)" + items: + $ref: '#/components/schemas/ActionObject' example: - action: update - action_label: Updated - actor_id: 1234 - actor_name: Sameer Patel - change_description: Role changed from Administrator to End User - created_at: "2012-03-05T11:32:44Z" - id: 498483 - ip_address: 209.119.38.228 - source_id: 3456 - source_label: John Doe - source_type: user - url: https://company.zendesk.com/api/v2/audit_logs/498483.json - AuditLogResponse: + actions: + - field: priority + value: high + active: true + conditions: + all: + - field: status + operator: is + value: open + - field: priority + operator: less_than + value: high + any: [] + default: false + id: 9873843 + position: 8 + raw_title: Roger Wilco + title: Roger Wilco + TriggerCategoriesResponseTriggerCategories: type: object - properties: - audit_log: - $ref: '#/components/schemas/AuditLogObject' - AuditLogsResponse: + allOf: + - $ref: '#/components/schemas/TriggerCategory' + anyOf: + - $ref: '#/components/schemas/TriggerCategoryRuleCounts' + InlineResponse2001: type: object properties: - audit_logs: - type: array - items: - $ref: '#/components/schemas/AuditLogObject' - AuditObject: + count: + type: object + additionalProperties: + $ref: '#/components/schemas/InlineResponse2001Count' + TicketObjectCustomFields: type: object properties: - author_id: + id: type: integer + description: The id of the custom field + value: + type: string + description: The value of the custom field + SearchExportResponse: + type: object + properties: + meta: + description: Metadata for the export query response + allOf: + - $ref: '#/components/schemas/SearchExportResponseMeta' + links: + description: The links to the previous and next entries via the cursor ids + in the metadata + allOf: + - $ref: '#/components/schemas/SearchExportResponseLinks' + results: + type: array + description: "May consist of tickets, users, groups, or organizations, as\ + \ specified by the `result_type` property in each result object" readOnly: true - created_at: + items: + $ref: '#/components/schemas/SearchResultObject' + facets: type: string - format: date-time + description: The facets corresponding to the search query + nullable: true readOnly: true - events: + example: + facets: null + links: + next: https://example.zendesk.com/api/v2/search/export.json?filter%5Btype%5D=ticket&page%5Bafter%5D=eyJmaWVsZCI6ImNyZWF0ZWRfYXQiLCJkZXNjIjp0cnVlLCJ0aWVCcmVha0ZpZWxkIjoiaWQiLCJ0aWVCcmVha0Rlc2MiOmZhbHNlLCJzb3J0VmFsdWVzIjpudWxsLCJleHBvcnRlZFRodXNGYXIiOjAsInNlc3Npb25TdGFydCI6MTYwNzAzOTI1Mzk4NSwiY3JlYXRlZEF0IjoxNjA3MDM5MjUzOTg1LCJzYWx0ZWRSZXF1ZXN0SGFzaCI6LTQ5ODM0ODc3LCJzYWx0ZWRDdXJzb3JIYXNoIjotMjQwMzQ4MjgwfQ%3D%3D&page%5Bsize%5D=100&query=hello%26page%5Bsize%5D%3D100%26filter%5Btype%5D%3Dticket + prev: null + meta: + after_cursor: eyJmaWVsZCI6ImNyZWF0ZWRfYXQiLCJkZXNjIjp0cnVlLCJ0aWVCcmVha0ZpZWxkIjoiaWQiLCJ0aWVCcmVha0Rlc2MiOmZhbHNlLCJzb3J0VmFsdWVzIjpudWxsLCJleHBvcnRlZFRodXNGYXIiOjAsInNlc3Npb25TdGFydCI6MTYwNzAzOTI1Mzk4NSwiY3JlYXRlZEF0IjoxNjA3MDM5MjUzOTg1LCJzYWx0ZWRSZXF1ZXN0SGFzaCI6LTQ5ODM0ODc3LCJzYWx0ZWRDdXJzb3JIYXNoIjotMjQwMzQ4MjgwfQ== + before_cursor: null + has_more: true + results: [] + InlineResponse2003: + type: object + properties: + actions: type: array items: type: object - properties: - body: - type: string - readOnly: true - field_name: - type: string - readOnly: true - id: - type: integer - readOnly: true - type: - type: string - readOnly: true - value: - oneOf: - - type: string - - type: integer - readOnly: true - id: + additionalProperties: true + ComplianceDeletionStatusObject: + required: + - account_subdomain + - action + - application + - created_at + - executer_id + - user_id + type: object + properties: + account_subdomain: + type: string + x-ballerina-name: accountSubdomain + application: + type: string + user_id: type: integer - readOnly: true - metadata: - type: object - readOnly: true - ticket_id: + x-ballerina-name: userId + executer_id: type: integer - readOnly: true - via: - $ref: '#/components/schemas/ViaObject' - AuthorObject: + nullable: true + x-ballerina-name: executerId + action: + type: string + created_at: + type: string + x-ballerina-name: createdAt + UserRelatedResponse: type: object properties: - email: + user_related: + allOf: + - $ref: '#/components/schemas/UserRelatedObject' + x-ballerina-name: userRelated + InlineResponse2002: + type: object + properties: + macro: + $ref: '#/components/schemas/MacroObject' + InlineResponse2005: + type: object + properties: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + InlineResponse2004: + type: object + properties: + definitions: + $ref: '#/components/schemas/InlineResponse2003' + TriggerConditionObject: + type: object + properties: + field: type: string - description: The author email - readOnly: true - id: - type: integer - description: The author id - readOnly: true - name: + value: + oneOf: + - type: string + - type: integer + - type: array + items: + oneOf: + - type: string + - type: integer + operator: type: string - description: The author name - readOnly: true - AutomationObject: + example: + field: status + operator: less_than + value: solved + AccountSettingsVoiceObject: type: object properties: - actions: - type: array - description: An object describing what the automation will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) - items: - $ref: '#/components/schemas/ActionObject' - active: + agent_wrap_up_after_calls: type: boolean - description: Whether the automation is active - conditions: - $ref: '#/components/schemas/ConditionsObject' + x-ballerina-name: agentWrapUpAfterCalls + outbound_enabled: + type: boolean + x-ballerina-name: outboundEnabled + only_during_business_hours: + type: boolean + x-ballerina-name: onlyDuringBusinessHours + maximum_queue_wait_time: + type: integer + x-ballerina-name: maximumQueueWaitTime + logging: + type: boolean + maximum_queue_size: + type: integer + x-ballerina-name: maximumQueueSize + recordings_public: + type: boolean + x-ballerina-name: recordingsPublic + uk_mobile_forwarding: + type: boolean + x-ballerina-name: ukMobileForwarding + agent_confirmation_when_forwarding: + type: boolean + x-ballerina-name: agentConfirmationWhenForwarding + enabled: + type: boolean + description: "Zendesk Talk settings. See [Voice](#voice)" + SupportAddressObject: + required: + - email + type: object + properties: + cname_status: + type: string + description: "Whether all of the required CNAME records are set. Possible\ + \ values: \"unknown\", \"verified\", \"failed\"" + readOnly: true + enum: + - unknown + - verified + - failed + x-ballerina-name: cnameStatus + forwarding_status: + type: string + description: "Status of email forwarding. Possible values: \"unknown\",\ + \ \"waiting\", \"verified\", or \"failed\"" + readOnly: true + enum: + - unknown + - waiting + - verified + - failed + x-ballerina-name: forwardingStatus created_at: type: string + description: When the address was created format: date-time - description: The time the automation was created readOnly: true + x-ballerina-name: createdAt + spf_status: + type: string + description: "Whether the SPF record is set up correctly. Possible values:\ + \ \"unknown\", \"verified\", \"failed\"" + readOnly: true + enum: + - unknown + - verified + - failed + x-ballerina-name: spfStatus + brand_id: + type: integer + description: "The ID of the [brand](/api-reference/ticketing/account-configuration/brands/)" + x-ballerina-name: brandId default: type: boolean - description: If true, the automation is a default automation + description: Whether the address is the account's default support address + updated_at: + type: string + description: When the address was updated + format: date-time readOnly: true + x-ballerina-name: updatedAt + name: + type: string + description: The name for the address id: type: integer description: Automatically assigned when created readOnly: true - position: - type: integer - description: The position of the automation which specifies the order it will be executed - raw_title: + domain_verification_status: type: string - description: The raw title of the automation + description: "Whether the domain verification record is valid. Possible\ + \ values: \"unknown\", \"verified\", \"failed\"" readOnly: true - title: + enum: + - unknown + - verified + - failed + x-ballerina-name: domainVerificationStatus + dns_results: type: string - description: The title of the automation - updated_at: + description: "Verification statuses for the domain and CNAME records. Possible\ + \ types: \"verified\", \"failed\"" + readOnly: true + enum: + - verified + - failed + x-ballerina-name: dnsResults + domain_verification_code: type: string - format: date-time - description: The time of the last update of the automation + description: "Verification string to be added as a TXT record to the domain.\ + \ Possible types: string or null" readOnly: true + x-ballerina-name: domainVerificationCode + email: + type: string + description: The email address. You can't change the email address of an + existing support address example: - actions: - - field: priority - value: high - active: true - conditions: - all: - - field: status - operator: is - value: open - - field: priority - operator: less_than - value: high - any: [] - default: false - id: 9873843 - position: 8 - raw_title: Roger Wilco - title: Roger Wilco - AutomationResponse: + brand_id: 123 + cname_status: verified + created_at: 2015-07-20T22:55:29Z + default: true + domain_verification_status: verified + email: support@example.zendesk.com + forwarding_status: unknown + id: 35436 + name: all + spf_status: verified + updated_at: 2016-09-21T20:15:20Z + InlineResponse2006: + allOf: + - $ref: '#/components/schemas/TriggerCategoriesResponse' + - $ref: '#/components/schemas/Pagination' + TicketUpdateRequest: type: object properties: - automation: - $ref: '#/components/schemas/AutomationObject' - AutomationsResponse: + ticket: + $ref: '#/components/schemas/TicketUpdateInput' + ActionsObject: type: object properties: - automations: + actions: type: array items: - $ref: '#/components/schemas/AutomationObject' - count: - type: integer - readOnly: true - next_page: - type: string - nullable: true - readOnly: true - previous_page: - type: string - nullable: true - readOnly: true - BatchErrorItem: - type: object - allOf: - - $ref: '#/components/schemas/Error' - - type: object - properties: - trigger_id: - type: string - BatchJobRequest: - type: object - properties: - job: - type: object - properties: - action: - type: string - enum: - - patch - items: - type: object - properties: - trigger_categories: - type: array - items: - $ref: '#/components/schemas/TriggerCategoryBatchRequest' - triggers: - type: array - items: - $ref: '#/components/schemas/TriggerBatchRequest' - BatchJobResponse: + $ref: '#/components/schemas/ActionObject' + TicketBulkImportRequest: type: object properties: - errors: + tickets: type: array items: - $ref: '#/components/schemas/BatchErrorItem' - results: - type: object - properties: - trigger_categories: - type: array - items: - $ref: '#/components/schemas/TriggerCategory' - triggers: - type: array - items: - $ref: '#/components/schemas/TriggerObject' - status: - type: string - enum: - - complete - - failed - BookmarkCreateRequest: + $ref: '#/components/schemas/TicketImportInput' + TicketObjectVia: type: object properties: - bookmark: - $ref: '#/components/schemas/BookmarkInput' - BookmarkInput: + channel: + type: string + description: | + This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" + source: + type: object + additionalProperties: true + description: | + For some channels a source object gives more information about how or why the ticket or event was created + description: "For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference)" + AccountSettingsBrandsObject: type: object properties: - ticket_id: + default_brand_id: type: integer - description: The id of the ticket the bookmark is for. - BookmarkObject: - title: Bookmarks + x-ballerina-name: defaultBrandId + require_brand_on_new_tickets: + type: boolean + x-ballerina-name: requireBrandOnNewTickets + description: "Brand settings. See [Brands](#brands)" + TicketAuditObject: type: object properties: + metadata: + type: object + additionalProperties: true + description: "Metadata for the audit, custom and system data" + readOnly: true created_at: type: string + description: The time the audit was created format: date-time - description: The time the bookmark was created readOnly: true + x-ballerina-name: createdAt id: type: integer - description: Automatically assigned when the bookmark is created + description: Automatically assigned when creating audits readOnly: true - ticket: - type: object - allOf: - - $ref: '#/components/schemas/TicketObject' + author_id: + type: integer + description: The user who created the audit readOnly: true - url: - type: string - description: The API url of this bookmark + x-ballerina-name: authorId + ticket_id: + type: integer + description: The ID of the associated ticket readOnly: true + x-ballerina-name: ticketId + events: + type: array + description: "An array of the events that happened in this audit. See the\ + \ [Ticket Audit events reference](/documentation/ticketing/reference-guides/ticket-audit-events-reference)" + items: + type: object + additionalProperties: true + via: + $ref: '#/components/schemas/TicketAuditViaObject' example: - created_at: "2014-11-20T22:55:29Z" + author_id: 35436 + created_at: 2009-07-20T22:55:29Z + events: + - attachments: [] + body: Thanks for your help! + id: 1564245 + public: true + type: Comment + - body: "Ticket #47 has been updated" + id: 1564246 + subject: Your ticket has been updated + type: Notification id: 35436 - ticket: - description: The fire is very colorful. - id: 60 - priority: high - requester_id: 156 - subject: Help, my printer is on fire! - url: https://{subdomain}.zendesk.com/api/v2/bookmarks/35436.json - BookmarkResponse: - type: object - properties: - bookmark: - $ref: '#/components/schemas/BookmarkObject' - BookmarksResponse: - title: Bookmarks - type: object - allOf: - - $ref: '#/components/schemas/OffsetPaginationObject' - - type: object - properties: - bookmarks: - type: array - items: - $ref: '#/components/schemas/BookmarkObject' - BrandCreateRequest: + metadata: + custom: + time_spent: 3m22s + system: + ip_address: 184.106.40.75 + ticket_id: 47 + via: + channel: web + PaginationLinks: type: object properties: - brand: - $ref: '#/components/schemas/BrandObject' - BrandObject: - title: Brands + next: + type: string + prev: + type: string + OrganizationMembershipObject: + required: + - default + - organization_id + - user_id type: object properties: - active: + view_tickets: type: boolean - description: If the brand is set as active - brand_url: - type: string - description: The url of the brand - created_at: - type: string - format: date-time - description: The time the brand was created + description: Denotes whether the user can or cannot have access to all organization's + tickets readOnly: true + x-ballerina-name: viewTickets default: type: boolean - description: Is the brand the default brand for this account - has_help_center: - type: boolean - description: If the brand has a Help Center - help_center_state: + description: "Denotes whether this is the default organization membership\ + \ for the user. If false, returns `null`" + nullable: true + updated_at: type: string - description: The state of the Help Center - enum: - - enabled - - disabled - - restricted + description: When this record last got updated + format: date-time readOnly: true - host_mapping: + x-ballerina-name: updatedAt + user_id: + type: integer + description: The ID of the user for whom this memberships belongs + readOnly: true + x-ballerina-name: userId + organization_id: + type: integer + description: "The ID of the organization associated with this user, in this\ + \ membership" + readOnly: true + x-ballerina-name: organizationId + created_at: type: string - description: The hostmapping to this brand, if any. Only admins view this property. + description: When this record was created + format: date-time + readOnly: true + x-ballerina-name: createdAt id: type: integer - description: The ID automatically assigned when the brand is created + description: Automatically assigned when the membership is created readOnly: true - is_deleted: - type: boolean - description: If the brand object is deleted or not - logo: - $ref: '#/components/schemas/AttachmentObject' - name: + organization_name: type: string - description: The name of the brand - signature_template: + description: "The name of the organization associated with this user, in\ + \ this membership" + readOnly: true + x-ballerina-name: organizationName + url: type: string - description: The signature template for a brand - subdomain: + description: The API url of this membership + readOnly: true + example: + created_at: 2009-05-13T00:07:08Z + default: true + id: 4 + organization_id: 12 + organization_name: first organization + updated_at: 2011-07-22T00:11:12Z + url: https://example.zendesk.com/api/v2/organization_memberships/4.json + user_id: 29 + view_tickets: true + QueueObjectDefinitionAll: + type: object + properties: + field: type: string - description: The subdomain of the brand - ticket_form_ids: - type: array - description: The ids of ticket forms that are available for use by a brand - items: - type: integer + value: + type: string + operator: + type: string + TicketMetricEventBaseObject: + title: Ticket Metric Events + type: object + properties: + instance_id: + type: integer + description: "The instance of the metric associated with the event. See\ + \ [instance_id](#instance_id)" readOnly: true - updated_at: + x-ballerina-name: instanceId + metric: + type: string + description: The metric being tracked + readOnly: true + enum: + - agent_work_time + - pausable_update_time + - periodic_update_time + - reply_time + - requester_wait_time + - resolution_time + id: + type: integer + description: Automatically assigned when the record is created + readOnly: true + time: type: string + description: The time the event occurred format: date-time - description: The time of the last update of the brand readOnly: true - url: + ticket_id: + type: integer + description: Id of the associated ticket + readOnly: true + x-ballerina-name: ticketId + type: type: string - description: The API url of this brand + description: "The type of the metric event. See [Ticket metric event types\ + \ reference](/documentation/ticketing/reference-guides/ticket-metric-event-types-reference)" readOnly: true + enum: + - activate + - pause + - fulfill + - apply_sla + - breach + - update_status + - measure example: - active: true - brand_url: https://brand1.com - created_at: "2012-04-02T22:55:29Z" - default: true - has_help_center: true - help_center_state: enabled - host_mapping: brand1.com - id: 47 - logo: - content_type: image/png - content_url: https://company.zendesk.com/logos/brand1_logo.png - file_name: brand1_logo.png - id: 928374 - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png - file_name: brand1_logo_thumb.png - id: 928375 - mapped_content_url: https://company.com/photos/brand1_logo_thumb.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928375.json - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_small.png - file_name: brand1_logo_small.png - id: 928376 - mapped_content_url: https://company.com/photos/brand1_logo_small.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928376.json - url: https://company.zendesk.com/api/v2/attachments/928374.json - name: Brand 1 - signature_template: '{{agent.signature}}' - subdomain: brand1 - ticket_form_ids: - - 47 - - 33 - - 22 - updated_at: "2012-04-02T22:55:29Z" - url: https://company.zendesk.com/api/v2/brands/47.json - required: - - name - - subdomain - BrandResponse: - type: object - properties: - brand: - $ref: '#/components/schemas/BrandObject' - BrandUpdateRequest: - type: object - properties: - brand: - $ref: '#/components/schemas/BrandObject' - BrandsResponse: - title: Brands - type: object - allOf: - - $ref: '#/components/schemas/OffsetPaginationObject' - - type: object - properties: - brands: - type: array - description: Array of brands - items: - $ref: '#/components/schemas/BrandObject' - BulkUpdateDefaultCustomStatusRequest: + id: 926256957613 + instance_id: 1 + metric: agent_work_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: measure + UserMergeByIdInput: type: object properties: - ids: - type: string - description: The comma-separated list of custom ticket status ids to be set as default for their status categories - BulkUpdateDefaultCustomStatusResponse: - type: object - ChannelFrameworkPushResultsResponse: + id: + type: integer + AssigneeFieldAssignableGroupsAndAgentsSearchResponse: type: object properties: - results: + count: + type: integer + description: Number of agents + groups listed from search result + groups: type: array - description: An array of [result objects](#result-object) items: - $ref: '#/components/schemas/ChannelFrameworkResultObject' - ChannelFrameworkResultObject: + $ref: '#/components/schemas/AssigneeFieldAssignableSearchGroupObject' + agents: + type: array + items: + $ref: '#/components/schemas/AssigneeFieldAssignableSearchAgentObject' + example: + agents: + - group: Tech + group_id: 6574839201 + id: 8392017465 + name: Sam Technologist + photo_url: https://z3n-example.zendesk.com/system/photos/410305192023/my_profile.png + count: 2 + groups: + - id: 6574839201 + name: Tech + TimeBasedExportIncrementalTicketsResponse: type: object properties: - external_resource_id: + next_page: type: string - description: The external ID of the resource, as passed in - readOnly: true - status: - $ref: '#/components/schemas/ChannelFrameworkResultStatusObject' - ChannelFrameworkResultStatusObject: + nullable: true + x-ballerina-name: nextPage + end_of_stream: + type: boolean + x-ballerina-name: endOfStream + tickets: + type: array + items: + $ref: '#/components/schemas/TicketObject' + count: + type: integer + end_time: + type: integer + x-ballerina-name: endTime + description: | + See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example + example: + count: 2 + end_of_stream: true + end_time: 1390362485 + next_page: "https://{subdomain}.zendesk.com/api/v2/incremental/tickets.json?per_page=3&start_time=1390362485" + tickets: + - assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + TargetYammer: type: object - description: The status of the import for the indicated resource properties: - code: + group_id: type: string - description: A code indicating the status of the import of the resource, as described in [status codes](#status-codes) - readOnly: true - description: + x-ballerina-name: groupId + token: type: string - description: In the case of an exception, a description of the exception. Otherwise, not present. - readOnly: true - CollaboratorObject: + EmailCCObjectAllOf2: type: object properties: - email: + user_email: type: string - format: email - name: + x-ballerina-name: userEmail + user_id: type: string - example: - email: someone@example.com - name: Someone Special - ComplianceDeletionStatusObject: - type: object - properties: - account_subdomain: + x-ballerina-name: userId + user_name: type: string + x-ballerina-name: userName action: type: string - application: - type: string + enum: + - put + - delete + AuditObject: + type: object + properties: + metadata: + type: object + readOnly: true created_at: type: string - executer_id: + format: date-time + readOnly: true + x-ballerina-name: createdAt + id: type: integer - nullable: true - user_id: + readOnly: true + author_id: type: integer - required: - - action - - application - - account_subdomain - - executer_id - - user_id - - created_at - ComplianceDeletionStatusesResponse: - type: object - properties: - compliance_deletion_statuses: + readOnly: true + x-ballerina-name: authorId + ticket_id: + type: integer + readOnly: true + x-ballerina-name: ticketId + events: type: array + readOnly: true items: - $ref: '#/components/schemas/ComplianceDeletionStatusObject' - ConditionObject: + $ref: '#/components/schemas/AuditObjectEvents' + via: + $ref: '#/components/schemas/ViaObject' + TriggerCategoryBatchRequest: + required: + - id + - position type: object properties: - field: - type: string - description: The name of a ticket field - operator: - type: string - description: A comparison operator - value: + id: type: string - description: The value of a ticket field - ConditionsObject: + position: + type: integer + format: int64 + CustomObjectRecordsBulkCreateRequestJob: type: object - description: An object that describes the conditions under which the automation will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) properties: - all: - type: array - description: Logical AND. Tickets must fulfill all of the conditions to be considered matching - items: - $ref: '#/components/schemas/ConditionObject' - any: + action: + type: string + items: type: array - description: Logical OR. Tickets may satisfy any of the conditions to be considered matching + description: "An array of record objects for job actions that create, update,\ + \ or set. An array of strings for job actions that delete" items: - $ref: '#/components/schemas/ConditionObject' - CountOrganizationObject: + $ref: '#/components/schemas/CustomObjectRecord' + OrganizationResponse: type: object properties: - refreshed_at: + organization: + $ref: '#/components/schemas/OrganizationObject' + TargetCommonFields: + required: + - title + - type + type: object + properties: + active: + type: boolean + description: Whether or not the target is activated + created_at: type: string + description: The time the target was created + format: date-time readOnly: true - value: + x-ballerina-name: createdAt + id: type: integer + description: Automatically assigned when created readOnly: true - CountOrganizationResponse: + title: + type: string + description: A name for the target + type: + type: string + description: "A pre-defined target, such as \"basecamp_target\". See the\ + \ additional attributes for the type that follow" + TicketsCreateRequest: type: object properties: - count: - $ref: '#/components/schemas/CountOrganizationObject' - CountResponse: + tickets: + type: array + items: + $ref: '#/components/schemas/TicketCreateInput' + TriggersResponse: type: object properties: + next_page: + type: string + nullable: true + x-ballerina-name: nextPage count: - type: object - properties: - refreshed_at: - type: string - format: datetime - value: - type: integer - CreateResourceResult: - type: object - properties: - id: type: integer - description: the id of the new resource - index: - type: integer - description: the index number of the resul - required: - - id - - index - CurrentUserResponse: - type: object - properties: - user: - allOf: - - $ref: '#/components/schemas/UserObject' - # Todo: Enable - # - type: object - # properties: - # authenticity_token: - # type: string - # description: CSRF token required by some Zendesk APIs. - # readOnly: true - CursorBasedExportIncrementalTicketsResponse: - type: object - description: | - See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example. - properties: - after_cursor: - type: string - nullable: true - after_url: - type: string - nullable: true - before_cursor: - type: string - nullable: true - before_url: + previous_page: type: string nullable: true - end_of_stream: - type: boolean - tickets: + x-ballerina-name: previousPage + triggers: type: array items: - $ref: '#/components/schemas/TicketObject' - example: - after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 - after_url: https://{subdomain}.zendesk.com/api/v2/incremental/tickets/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8 - before_cursor: null - before_url: null - end_of_stream: true - tickets: - - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - group_id: 98738 - has_incidents: false - id: 35436 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - CursorBasedExportIncrementalUsersResponse: + $ref: '#/components/schemas/TriggerObject' + TriggerCategoryRequestRequired: + required: + - name + type: object + UserForAdmin: + title: Users + required: + - name type: object properties: - after_cursor: + shared: + type: boolean + description: If the user is shared from a different Zendesk Support instance. + Ticket sharing accounts only + readOnly: true + last_login_at: type: string - nullable: true - after_url: + description: | + Last time the user signed in to Zendesk Support or made an API request + using an API token or basic authentication + format: datetime + readOnly: true + x-ballerina-name: lastLoginAt + notes: type: string - nullable: true - before_cursor: + description: Any notes you want to store about the user + role: type: string - nullable: true - before_url: + description: "The user's role. Possible values are \"end-user\", \"agent\"\ + , or \"admin\"" + signature: type: string + description: The user's signature. Only agents and admins can have signatures + custom_role_id: + type: integer + description: A custom role if the user is an agent on the Enterprise plan + or above nullable: true - end_of_stream: + x-ballerina-name: customRoleId + moderator: type: boolean - users: - type: array - items: - $ref: '#/components/schemas/UserObject' - example: - after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 - after_url: https://example.zendesk.com/api/v2/incremental/users/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8 - before_cursor: null - before_url: null - end_of_stream: true - users: - - active: true - alias: Mr. Johnny - created_at: "2009-07-20T22:55:29Z" - custom_role_id: 9373643 - details: "" - email: johnny@example.com - external_id: sai989sur98w9 - id: 35436 - last_login_at: "2011-05-05T10:38:52Z" - locale: en-US - locale_id: 1 - moderator: true - name: Johnny Agent - notes: Johnny is a nice guy! - only_private_comments: false - organization_id: 57542 - phone: "+15551234567" - photo: - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png - id: 928374 - name: my_funny_profile_pic.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png - id: 928375 - name: my_funny_profile_pic_thumb.png - size: 58298 - restricted_agent: true - role: agent - role_type: 0 - shared: false - shared_agent: false - signature: Have a nice day, Johnny - suspended: true - tags: - - enterprise - - other_tag - ticket_restriction: assigned - time_zone: Copenhagen - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/users/35436.json - user_fields: - user_date: "2012-07-23T00:00:00Z" - user_decimal: 5.1 - user_dropdown: option_1 - verified: true - CustomFieldObject: - type: object - properties: - active: + description: Designates whether the user has forum moderation capabilities + shared_agent: type: boolean - description: If true, this field is available for use + description: If the user is a shared agent from a different Zendesk Support + instance. Ticket sharing accounts only + readOnly: true + x-ballerina-name: sharedAgent created_at: type: string - format: date-time - description: The time of the last update of the ticket field + description: The time the user was created + format: datetime readOnly: true - custom_field_options: - type: array - description: Required and presented for a custom field of type "dropdown". Each option is represented by an object with a `name` and `value` property - items: - $ref: '#/components/schemas/CustomFieldOptionObject' - description: + x-ballerina-name: createdAt + external_id: type: string - description: User-defined description of this field's purpose - id: - type: integer - description: Automatically assigned upon creation - readOnly: true - key: + description: "A unique identifier from another system. The API treats the\ + \ id as case insensitive. Example: \"ian1\" and \"IAN1\" are the same\ + \ value" + nullable: true + x-ballerina-name: externalId + locale: type: string - description: A unique key that identifies this custom field. This is used for updating the field and referencing in placeholders. The key must consist of only letters, numbers, and underscores. It can't be only numbers and can't be reused if deleted. - position: + description: "The user's locale. A BCP-47 compliant tag for the locale.\ + \ If both \"locale\" and \"locale_id\" are present on create or update,\ + \ \"locale_id\" is ignored and only \"locale\" is used" + default_group_id: type: integer - description: Ordering of the field relative to other fields - raw_description: - type: string - description: The dynamic content placeholder, if present, or the `description` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_title: - type: string - description: The dynamic content placeholder, if present, or the `title` value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - regexp_for_validation: + description: The id of the user's default group + x-ballerina-name: defaultGroupId + locale_id: + type: integer + description: The user's language identifier + x-ballerina-name: localeId + remote_photo_url: type: string - description: Regular expression field only. The validation pattern for a field value to be deemed valid - nullable: true - relationship_filter: + description: A URL pointing to the user's profile picture + x-ballerina-name: remotePhotoUrl + user_fields: type: object - description: A filter definition that allows your autocomplete to filter down results - relationship_target_type: + additionalProperties: true + description: "Values of custom fields in the user's profile. See [User Fields](#user-fields)" + x-ballerina-name: userFields + updated_at: type: string - description: A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", and "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment". - system: + description: The time the user was last updated + format: datetime + readOnly: true + x-ballerina-name: updatedAt + report_csv: type: boolean - description: If true, only active and position values of this field can be changed + description: | + This parameter is inert and has no effect. It may be deprecated in the + future. + + Previously, this parameter determined whether a user could access a CSV + report in a legacy Guide dashboard. This dashboard has been removed. See + [Announcing Guide legacy reporting upgrade to + Explore](https://support.zendesk.com/hc/en-us/articles/4762263171610-Announcing-Guide-legacy-reporting-upgrade-to-Explore-) readOnly: true - tag: - type: string - description: Optional for custom field of type "checkbox"; not presented otherwise. - title: - type: string - description: The title of the custom field - type: - type: string - description: 'The custom field type: "checkbox", "date", "decimal", "dropdown", "integer", ["lookup"](/api-reference/ticketing/lookup_relationships/lookup_relationships/), "regexp", "text", or "textarea"' - updated_at: + x-ballerina-name: reportCsv + alias: type: string - format: date-time - description: The time of the last update of the ticket field - readOnly: true - url: + description: An alias displayed to end users + details: type: string - description: The URL for this resource - readOnly: true - required: - - key - - type - - title - CustomFieldOptionObject: - type: object - properties: + description: "Any details you want to store about the user, such as an address" id: type: integer - description: Automatically assigned upon creation + description: Automatically assigned when the user is created readOnly: true - name: + email: type: string - description: Name of the dropdown option - position: + description: "The user's primary email address. *Writeable on create only.\ + \ On update, a secondary email is added. See [Email Address](#email-address)" + restricted_agent: + type: boolean + description: "If the agent has any restrictions; false for admins and unrestricted\ + \ agents, true for other agents" + x-ballerina-name: restrictedAgent + two_factor_auth_enabled: + type: boolean + description: If two factor authentication is enabled + nullable: true + readOnly: true + x-ballerina-name: twoFactorAuthEnabled + role_type: type: integer - description: Position of the dropdown option - raw_name: - type: string - description: Raw name of the dropdown option + description: "The user's role id. 0 for a custom agent, 1 for a light agent,\ + \ 2 for a chat agent, 3 for a chat agent added to the Support account\ + \ as a contributor ([Chat Phase 4](https://support.zendesk.com/hc/en-us/articles/360022365373#topic_djh_1zk_4fb)),\ + \ 4 for an admin, and 5 for a billing admin" + nullable: true readOnly: true - url: + x-ballerina-name: roleType + only_private_comments: + type: boolean + description: true if the user can only create private comments + x-ballerina-name: onlyPrivateComments + iana_time_zone: type: string - description: URL of the dropdown option + description: The time zone for the user readOnly: true - value: + x-ballerina-name: ianaTimeZone + shared_phone_number: + type: boolean + description: "Whether the `phone` number is shared or not. See [Phone Number](#phone-number)\ + \ below" + nullable: true + x-ballerina-name: sharedPhoneNumber + verified: + type: boolean + description: "Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities)" + active: + type: boolean + description: false if the user has been deleted + readOnly: true + photo: + type: object + additionalProperties: true + description: "The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/)\ + \ object" + nullable: true + time_zone: type: string - description: Value of the dropdown option - required: - - name - - value - CustomFieldOptionResponse: - type: object - properties: - custom_field_option: - $ref: '#/components/schemas/CustomFieldOptionObject' - CustomFieldOptionsResponse: - type: object - properties: - count: - type: integer - description: Total count of records retrieved + description: "The user's time zone. See [Time Zone](#time-zone)" + x-ballerina-name: timeZone + suspended: + type: boolean + description: "If the agent is suspended. Tickets from suspended users are\ + \ also suspended, and these users cannot sign in to the end user portal" + url: + type: string + description: The user's API url readOnly: true - custom_field_options: + tags: type: array + description: The user's tags. Only present if your account has user tagging + enabled items: - $ref: '#/components/schemas/CustomFieldOptionObject' - next_page: + type: string + phone: type: string - description: URL of the next page + description: "The user's primary phone number. See [Phone Number](#phone-number)\ + \ below" nullable: true + organization_id: + type: integer + description: "The id of the user's organization. If the user has more than\ + \ one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/),\ + \ the id of the user's default organization. If updating, see [Organization\ + \ ID](#organization-id)" + nullable: true + x-ballerina-name: organizationId + name: + type: string + description: The user's name + chat_only: + type: boolean + description: Whether or not the user is a chat-only agent readOnly: true - previous_page: + x-ballerina-name: chatOnly + ticket_restriction: type: string - description: URL of the previous page + description: "Specifies which tickets the user has access to. Possible values\ + \ are: \"organization\", \"groups\", \"assigned\", \"requested\", null.\ + \ \"groups\" and \"assigned\" are valid only for agents. If you pass an\ + \ invalid value to an end user (for example, \"groups\"), they will be\ + \ assigned to \"requested\", regardless of their previous access" nullable: true - readOnly: true - CustomObject: + x-ballerina-name: ticketRestriction + example: + active: true + alias: Mr. Johnny + created_at: 2009-07-20T22:55:29Z + custom_role_id: 9373643 + details: "" + email: johnny@example.com + external_id: sai989sur98w9 + iana_time_zone: Pacific/Pago_Pago + id: 35436 + last_login_at: 2011-05-05T10:38:52Z + locale: en-US + locale_id: 1 + moderator: true + name: Johnny Agent + notes: Johnny is a nice guy! + only_private_comments: false + organization_id: 57542 + phone: "+15551234567" + photo: + content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png + id: 928374 + name: my_funny_profile_pic.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png + id: 928375 + name: my_funny_profile_pic_thumb.png + size: 58298 + restricted_agent: true + role: agent + role_type: 0 + shared: false + shared_agent: false + signature: "Have a nice day, Johnny" + suspended: true + tags: + - enterprise + - other_tag + ticket_restriction: assigned + time_zone: Copenhagen + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/users/35436.json + user_fields: + user_date: 2012-07-23T00:00:00Z + user_decimal: 5.1 + user_dropdown: option_1 + verified: true + MacroObjectAllOf2: type: object properties: - created_at: - type: string - format: date-time - description: The time the object type was created - readOnly: true - created_by_user_id: - type: string - description: Id of a user who created the object - readOnly: true - description: - type: string - description: User-defined description of the object - key: + app_installation: type: string - description: A user-defined unique identifier. Writable on create only. Cannot be reused if deleted. - readOnly: true - raw_description: - type: string - description: The dynamic content placeholder, if present, or the "raw_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_title: + description: "The app installation that requires each macro, if present" + nullable: true + x-ballerina-name: appInstallation + usage_24h: + type: integer + description: The number of times each macro has been used in the past day + x-ballerina-name: usage24h + usage_30d: + type: integer + description: The number of times each macro has been used in the past thirty + days + x-ballerina-name: usage30d + usage_1h: + type: integer + description: The number of times each macro has been used in the past hour + x-ballerina-name: usage1h + permissions: type: string - description: The dynamic content placeholder, if present, or the "title" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_title_pluralized: + description: Permissions for each macro + nullable: true + categories: type: string - description: The dynamic content placeholder, if present, or the "raw_title_pluralized" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + description: The macro categories + nullable: true + usage_7d: + type: integer + description: The number of times each macro has been used in the past week + x-ballerina-name: usage7d + BulkUpdateDefaultCustomStatusResponse: + type: object + TwitterChannelsResponse: + type: object + properties: + monitored_twitter_handles: + type: array + items: + $ref: '#/components/schemas/TwitterChannelObject' + x-ballerina-name: monitoredTwitterHandles + GroupSLAPolicyFilterDefinitionResponseDefinitionsValuesList: + type: object + properties: title: type: string - description: User-defined display name for the object - title_pluralized: - type: string - description: User-defined pluralized version of the object's title - updated_at: - type: string - format: date-time - description: The time of the last update of the object - readOnly: true - updated_by_user_id: - type: string - description: Id of the last user who updated the object - readOnly: true - url: - type: string - description: Direct link to the specific custom object - readOnly: true + value: + type: integer + nullable: true + UserRelatedObject: + type: object + properties: + organization_subscriptions: + type: integer + description: Count of organization subscriptions + x-ballerina-name: organizationSubscriptions + requested_tickets: + type: integer + description: Count of requested tickets + x-ballerina-name: requestedTickets + assigned_tickets: + type: integer + description: Count of assigned tickets + x-ballerina-name: assignedTickets + ccd_tickets: + type: integer + description: Count of collaborated tickets + x-ballerina-name: ccdTickets + TriggerBulkUpdateItem: required: - - key - - title - - title_pluralized - CustomObjectCreateInput: + - id type: object properties: - key: - type: string - description: Unique identifier. Writable on create only - title: - type: string - description: Display name for the object - title_pluralized: + category_id: type: string - description: Pluralized version of the object's title - CustomObjectField: - type: object - allOf: - - $ref: '#/components/schemas/CustomFieldObject' + description: The ID of the new category the trigger is to be moved to + x-ballerina-name: categoryId + active: + type: boolean + description: The active status of the trigger (true or false) + id: + type: integer + description: The ID of the trigger to update + position: + type: integer + description: The new position of the trigger example: active: true - created_at: "2022-09-07T23:21:59Z" - description: Make - id: 4398096842879 - key: make - position: 0 - raw_description: Make - raw_title: Make - regexp_for_validation: null - system: false - title: Make - type: text - updated_at: "2022-09-07T23:22:00Z" - url: https://company.zendesk.com/api/v2/custom_objects/car/fields/4398096842879.json - CustomObjectFieldResponse: + category_id: "10026" + id: 25 + position: 8 + SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll: type: object properties: - custom_object_field: - $ref: '#/components/schemas/CustomObjectField' - CustomObjectFieldsCreateRequest: + subject: + type: string + title: + type: string + TicketFormResponse: type: object properties: - custom_object_field: - $ref: '#/components/schemas/CustomObjectField' - CustomObjectFieldsResponse: + ticket_form: + allOf: + - $ref: '#/components/schemas/TicketFormObject' + x-ballerina-name: ticketForm + SuspendedTicketsExportResponse: type: object properties: - custom_object_fields: - type: array - items: - $ref: '#/components/schemas/CustomObjectField' - CustomObjectLimitsResponse: + export: + $ref: '#/components/schemas/SuspendedTicketsExportResponseExport' + TicketMetricObject: type: object properties: - count: + group_stations: type: integer - description: The current numnber of the requested resource + description: Number of groups the ticket passed through readOnly: true - limit: + x-ballerina-name: groupStations + on_hold_time_in_minutes: + type: object + description: Number of minutes on hold + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: onHoldTimeInMinutes + reopens: type: integer - description: The maximum allowed number for the requested resource + description: Total number of times the ticket was reopened readOnly: true - CustomObjectRecord: - type: object - properties: - created_at: + requester_updated_at: type: string + description: When the requester last updated the ticket format: date-time - description: The time the object was created readOnly: true - created_by_user_id: + x-ballerina-name: requesterUpdatedAt + reply_time_in_minutes: + type: object + description: Number of minutes to the first reply during calendar and business + hours + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: replyTimeInMinutes + assignee_stations: + type: integer + description: Number of assignees the ticket had + readOnly: true + x-ballerina-name: assigneeStations + created_at: type: string - description: Id of a user who created the object + description: When the record was created + format: date-time readOnly: true - custom_object_fields: - type: object - additionalProperties: true - custom_object_key: + x-ballerina-name: createdAt + custom_status_updated_at: type: string - description: A user-defined unique identifier + description: The date and time the ticket's custom status was last updated + format: date-time readOnly: true - external_id: + x-ballerina-name: customStatusUpdatedAt + ticket_id: + type: integer + description: Id of the associated ticket + readOnly: true + x-ballerina-name: ticketId + url: type: string - description: An id you can use to link custom object records to external data - nullable: true - id: + description: The API url of the ticket metric + readOnly: true + initially_assigned_at: type: string - description: Automatically assigned upon creation + description: When the ticket was initially assigned + format: date-time readOnly: true - name: + x-ballerina-name: initiallyAssignedAt + latest_comment_added_at: type: string - description: User-defined display name for the object + description: When the latest comment was added + format: date-time + readOnly: true + x-ballerina-name: latestCommentAddedAt + replies: + type: integer + description: The number of public replies added to a ticket by an agent readOnly: true updated_at: type: string + description: When the record was last updated format: date-time - description: The time of the last update of the object readOnly: true - updated_by_user_id: + x-ballerina-name: updatedAt + solved_at: type: string - description: Id of the last user who updated the object + description: When the ticket was solved + format: date-time readOnly: true - url: + x-ballerina-name: solvedAt + assigned_at: type: string - description: Direct link to the specific custom object + description: When the ticket was assigned + format: date-time readOnly: true - required: - - name - CustomObjectRecordResponse: + x-ballerina-name: assignedAt + id: + type: integer + description: Automatically assigned when the client is created + readOnly: true + agent_wait_time_in_minutes: + type: object + description: Number of minutes the agent spent waiting during calendar and + business hours + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: agentWaitTimeInMinutes + full_resolution_time_in_minutes: + type: object + description: Number of minutes to the full resolution during calendar and + business hours + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: fullResolutionTimeInMinutes + reply_time_in_seconds: + type: object + description: "Number of seconds to the first reply during calendar hours,\ + \ only available for Messaging tickets" + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: replyTimeInSeconds + requester_wait_time_in_minutes: + type: object + description: Number of minutes the requester spent waiting during calendar + and business hours + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: requesterWaitTimeInMinutes + first_resolution_time_in_minutes: + type: object + description: Number of minutes to the first resolution time during calendar + and business hours + readOnly: true + allOf: + - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: firstResolutionTimeInMinutes + assignee_updated_at: + type: string + description: When the assignee last updated the ticket + format: date-time + readOnly: true + x-ballerina-name: assigneeUpdatedAt + status_updated_at: + type: string + description: When the status of the ticket was last updated + format: date-time + readOnly: true + x-ballerina-name: statusUpdatedAt + example: + agent_wait_time_in_minutes: + business: 737 + calendar: 2391 + assigned_at: 2011-05-05T10:38:52Z + assignee_stations: 1 + assignee_updated_at: 2011-05-06T10:38:52Z + created_at: 2009-07-20T22:55:29Z + custom_status_updated_at: 2011-05-09T10:38:52Z + first_resolution_time_in_minutes: + business: 737 + calendar: 2391 + full_resolution_time_in_minutes: + business: 737 + calendar: 2391 + group_stations: 7 + id: 33 + initially_assigned_at: 2011-05-03T10:38:52Z + latest_comment_added_at: 2011-05-09T10:38:52Z + on_hold_time_in_minutes: + business: 637 + calendar: 2290 + reopens: 55 + replies: 322 + reply_time_in_minutes: + business: 737 + calendar: 2391 + reply_time_in_seconds: + calendar: 143460 + requester_updated_at: 2011-05-07T10:38:52Z + requester_wait_time_in_minutes: + business: 737 + calendar: 2391 + solved_at: 2011-05-09T10:38:52Z + status_updated_at: 2011-05-04T10:38:52Z + ticket_id: 4343 + updated_at: 2011-05-05T10:38:52Z + CountOrganizationResponse: type: object properties: - custom_object_record: - $ref: '#/components/schemas/CustomObjectRecord' - CustomObjectRecordsBulkCreateRequest: + count: + $ref: '#/components/schemas/CountOrganizationObject' + GroupSLAPolicyFilterConditionObjectValue: + oneOf: + - $ref: '#/components/schemas/ValueOneOf1' + - $ref: '#/components/schemas/ValueValueOneOf12' + TicketSkipCreation: type: object properties: - job: - type: object - properties: - action: - type: string - items: - type: array - description: An array of record objects for job actions that create, update, or set. An array of strings for job actions that delete. - items: - $ref: '#/components/schemas/CustomObjectRecord' - CustomObjectRecordsCreateRequest: + skip: + $ref: '#/components/schemas/TicketSkipObject' + UserInput: + additionalProperties: true + anyOf: + - $ref: '#/components/schemas/UserCreateInput' + - $ref: '#/components/schemas/UserMergePropertiesInput' + - $ref: '#/components/schemas/UserMergeByIdInput' + TicketAuditsCountResponse: type: object properties: - custom_object_record: - $ref: '#/components/schemas/CustomObjectRecord' - CustomObjectRecordsJobsResponse: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + AccountSettingsTicketSharingPartnersObject: type: object properties: - job_status: - type: object - properties: - id: - type: string - message: - type: string - nullable: true - progress: - type: integer - nullable: true - results: - type: array - items: - $ref: '#/components/schemas/CustomObjectRecord' - nullable: true - status: - type: string - total: - type: integer - url: - type: string - CustomObjectRecordsResponse: + support_addresses: + type: array + items: + type: string + x-ballerina-name: supportAddresses + description: "Ticket sharing partners settings. See [Ticket Sharing Partners](#ticket-sharing-partners)" + ExportIncrementalOrganizationsResponse: type: object properties: + next_page: + type: string + nullable: true + x-ballerina-name: nextPage + end_of_stream: + type: boolean + x-ballerina-name: endOfStream count: type: integer - description: The number of results returned for the current request - readOnly: true - custom_object_records: + end_time: + type: integer + x-ballerina-name: endTime + organizations: type: array items: - $ref: '#/components/schemas/CustomObjectRecord' - links: - type: object - properties: - next: - type: string - nullable: true - prev: - type: string - nullable: true - required: - - prev - - next - meta: - type: object - properties: - after_cursor: - type: string - nullable: true - before_cursor: - type: string - nullable: true - has_more: - type: boolean - required: - - has_more - - after_cursor - - before_cursor - CustomObjectRecordsUpsertRequest: - type: object - properties: - custom_object_record: - $ref: '#/components/schemas/CustomObjectRecord' - CustomObjectResponse: + $ref: '#/components/schemas/OrganizationObject' + example: + count: 1 + end_of_stream: true + end_time: 1601357503 + next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 + organizations: + - created_at: 2018-11-14T00:14:52Z + details: caterpillar =) + domain_names: + - remain.com + external_id: ABC198 + group_id: 1835962 + id: 4112492 + name: Groablet Enterprises + notes: donkey + organization_fields: + datepudding: 2018-11-04T00:00:00+00:00 + org_field_1: happy happy + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z + url: https://example.zendesk.com/api/v2/organizations/4112492.json + OffsetPaginationObject: type: object properties: - custom_object: - $ref: '#/components/schemas/CustomObject' - CustomObjectsCreateRequest: + next_page: + type: string + description: the URL of the next page + format: url + nullable: true + x-ballerina-name: nextPage + count: + type: integer + description: the total record count + previous_page: + type: string + description: the URL of the previous page + format: url + nullable: true + x-ballerina-name: previousPage + V2MacrosBody: type: object properties: - custom_object: - $ref: '#/components/schemas/CustomObjectCreateInput' - CustomObjectsResponse: + macro: + $ref: '#/components/schemas/MacroInput' + OrganizationFieldResponse: type: object properties: - custom_objects: - type: array - items: - $ref: '#/components/schemas/CustomObject' - CustomRoleConfigurationObject: + organization_field: + allOf: + - $ref: '#/components/schemas/OrganizationFieldObject' + x-ballerina-name: organizationField + AccountSettingsStatisticsObject: type: object - description: Configuration settings for the role. See [Configuration](#configuration) properties: - assign_tickets_to_any_group: + forum: type: boolean - description: Whether or not the agent can assign tickets to any group - readOnly: true - chat_access: + search: type: boolean - description: Whether or not the agent has access to Chat - readOnly: true - end_user_list_access: + rule_usage: + type: boolean + x-ballerina-name: ruleUsage + description: "Account statistics settings. See [Statistics](#statistics)" + AccountSettingsLimitsObject: + type: object + properties: + attachment_size: + type: integer + x-ballerina-name: attachmentSize + description: "Account limits configuration. See [Limits](#limits)" + TriggerActionObject: + type: object + properties: + field: type: string - description: 'Whether or not the agent can view lists of user profiles. Allowed values: "full", "none"' - end_user_profile_access: + value: + oneOf: + - type: string + - type: integer + - type: array + items: + oneOf: + - type: string + - type: integer + example: + field: status + value: solved + AccountSettingsCdnObjectHosts: + type: object + properties: + name: type: string - description: 'What the agent can do with end-user profiles. Allowed values: "edit", "edit-within-org", "full", "readonly"' - explore_access: + url: type: string - description: 'Allowed values: "edit", "full", "none", "readonly"' - forum_access: + SharingAgreementObject: + type: object + properties: + partner_name: type: string - description: 'The kind of access the agent has to Guide. Allowed values: "edit-topics", "full", "readonly"' - forum_access_restricted_content: - type: boolean - group_access: - type: boolean - description: Whether or not the agent can add or modify groups + description: "Can be one of the following: \"jira\", null" + nullable: true + x-ballerina-name: partnerName + remote_subdomain: + type: string + description: Subdomain of the remote account or null if not associated with + an account + x-ballerina-name: remoteSubdomain + name: + type: string + description: Name of this sharing agreement + created_at: + type: string + description: The time the record was created + format: date-time readOnly: true - light_agent: - type: boolean + x-ballerina-name: createdAt + id: + type: integer + description: Automatically assigned upon creation readOnly: true - macro_access: + type: type: string - description: 'What the agent can do with macros. Allowed values: "full", "manage-group", "manage-personal", "readonly"' - manage_business_rules: - type: boolean - description: Whether or not the agent can manage business rules - manage_contextual_workspaces: - type: boolean - description: Whether or not the agent can view, add, and edit contextual workspaces - manage_dynamic_content: - type: boolean - description: Whether or not the agent can access dynamic content - manage_extensions_and_channels: - type: boolean - description: Whether or not the agent can manage channels and extensions - manage_facebook: - type: boolean - description: Whether or not the agent can manage Facebook pages - manage_organization_fields: - type: boolean - description: Whether or not the agent can create and manage organization fields - manage_ticket_fields: - type: boolean - description: Whether or not the agent can create and manage ticket fields - manage_ticket_forms: - type: boolean - description: Whether or not the agent can create and manage ticket forms - manage_user_fields: - type: boolean - description: Whether or not the agent can create and manage user fields - moderate_forums: - type: boolean - readOnly: true - organization_editing: - type: boolean - description: Whether or not the agent can add or modify organizations - organization_notes_editing: - type: boolean - description: Whether or not the agent can add or modify organization notes - readOnly: true - report_access: + description: "Can be one of the following: \"inbound\", \"outbound\"" + url: type: string - description: 'What the agent can do with reports. Allowed values: "full", "none", "readonly"' - side_conversation_create: - type: boolean - description: Whether or not the agent can contribute to side conversations - ticket_access: + description: URL of the sharing agreement record + readOnly: true + status: type: string - description: 'What kind of tickets the agent can access. Allowed values: "all", "assigned-only", "within-groups", "within-groups-and-public-groups", "within-organization"' - ticket_comment_access: + description: "Can be one of the following: \"accepted\", \"declined\", \"\ + pending\", \"inactive\", \"failed\", \"ssl_error\", \"configuration_error\"" + example: + created_at: 2012-02-20T22:55:29Z + id: 88335 + name: Ticket Sharing + partner_name: jira + status: accepted + type: inbound + url: https://company.zendesk.com/api/v2/agreements/88335.json + ListDeletedTicketsResponseActor: + type: object + properties: + name: type: string - description: 'What type of comments the agent can make. Allowed values: "public", "none"' - ticket_deletion: - type: boolean - description: Whether or not the agent can delete tickets - ticket_editing: - type: boolean - description: Whether or not the agent can edit ticket properties - ticket_merge: - type: boolean - description: Whether or not the agent can merge tickets - ticket_tag_editing: - type: boolean - description: Whether or not the agent can edit ticket tags - twitter_search_access: + id: + type: integer + MacroCommonObject: + required: + - actions + - title + type: object + properties: + default: type: boolean - user_view_access: - type: string - description: 'What the agent can do with customer lists. Allowed values: "full", "manage-group", "manage-personal", "none", "readonly"' - view_access: + description: "If true, the macro is a default macro" + readOnly: true + updated_at: type: string - description: 'What the agent can do with views. Allowed values: "full", "manage-group", "manage-personal", "playonly", "readonly"' - view_deleted_tickets: - type: boolean - description: Whether or not the agent can view deleted tickets - voice_access: - type: boolean - description: Whether or not the agent can answer and place calls to end users - voice_dashboard_access: + description: The time of the last update of the macro + format: date-time + x-ballerina-name: updatedAt + restriction: + type: object + additionalProperties: true + description: Access to this macro. A null value allows unrestricted access + for all users in the account + nullable: true + active: type: boolean - description: Whether or not the agent can view details about calls on the Talk dashboard - CustomRoleObject: - title: Custom Agent Roles - type: object - properties: - configuration: - $ref: '#/components/schemas/CustomRoleConfigurationObject' + description: Useful for determining if the macro should be displayed created_at: type: string + description: The time the macro was created format: date-time - description: The time the record was created - readOnly: true + x-ballerina-name: createdAt description: type: string - description: A description of the role + description: The description of the macro + nullable: true id: type: integer - description: Automatically assigned on creation - readOnly: true - name: - type: string - description: Name of the custom role - role_type: - type: integer - description: The user's role. 0 stands for a custom agent, 1 for a light agent, 2 for a chat agent, 3 for a contributor, 4 for an admin and 5 for a billing admin. See [Understanding standard agent roles in Zendesk Support](https://support.zendesk.com/hc/en-us/articles/4409155971354-Understanding-standard-agent-roles-in-Zendesk-Support) in Zendesk help - readOnly: true - team_member_count: + description: The ID automatically assigned when a macro is created + position: type: integer - description: The number of team members assigned to this role - readOnly: true - updated_at: + description: The position of the macro + title: type: string - format: date-time - description: The time the record was last updated - readOnly: true - required: - - name - - role_type - CustomRoleResponse: - type: object - properties: - custom_role: - $ref: '#/components/schemas/CustomRoleObject' - CustomRolesResponse: - type: object - properties: - custom_roles: + description: The title of the macro + actions: type: array + description: "Each action describes what the macro will do. See [Actions\ + \ reference](/documentation/ticketing/reference-guides/actions-reference)" items: - $ref: '#/components/schemas/CustomRoleObject' - CustomStatusCreateInput: + $ref: '#/components/schemas/ActionObject' + url: + type: string + description: A URL to access the macro's details + example: + actions: + - field: status + value: solved + - field: priority + value: normal + - field: type + value: incident + - field: assignee_id + value: current_user + - field: group_id + value: current_groups + - field: comment_value + value: "Thanks for your request. This issue you reported is a known issue.\ + \ For more information, please visit our forums. " + active: true + created_at: 2019-09-16T02:17:38Z + default: false + description: null + id: 360111062754 + position: 9999 + restriction: null + title: Close and redirect to topics + updated_at: 2019-09-16T02:17:38Z + url: https://subdomain.zendesk.com/api/v2/macros/360111062754.json + OrganizationFieldObject: type: object + example: + active: true + created_at: 2012-10-16T16:04:06Z + description: Description of Custom Field + id: 7 + key: custom_field_1 + position: 9999 + raw_description: "{{dc.my_description}}" + raw_title: Custom Field 1 + regexp_for_validation: null + title: Custom Field 1 + type: text + updated_at: 2012-10-16T16:04:06Z + url: https://company.zendesk.com/api/v2/organization_fields/7.json allOf: - - $ref: '#/components/schemas/CustomStatusUpdateInput' - - type: object - properties: - status_category: - type: string - description: The status category the custom ticket status belongs to - enum: - - new - - open - - pending - - hold - - solved - CustomStatusCreateRequest: - type: object - properties: - custom_status: - $ref: '#/components/schemas/CustomStatusCreateInput' - CustomStatusObject: + - $ref: '#/components/schemas/CustomFieldObject' + TriggerActionDefinitionObject: type: object properties: - active: + nullable: type: boolean - description: If true, the custom status is set to active, If false, the custom status is set to inactive - agent_label: - type: string - description: The label displayed to agents. Maximum length is 48 characters - created_at: - type: string - format: date-time - description: The date and time the custom ticket status was created - readOnly: true - default: + repeatable: type: boolean - description: If true, the custom status is set to default. If false, the custom status is set to non-default - description: - type: string - description: The description of when the user should select this custom ticket status - end_user_description: - type: string - description: The description displayed to end users - end_user_label: - type: string - description: The label displayed to end users. Maximum length is 48 characters - id: - type: integer - description: Automatically assigned when the custom ticket status is created - readOnly: true - raw_agent_label: - type: string - description: The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "agent_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - readOnly: true - raw_description: - type: string - description: The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "description" value. [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - readOnly: true - raw_end_user_description: + subject: type: string - description: The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_description" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - readOnly: true - raw_end_user_label: + values: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsValues' + title: type: string - description: The dynamic content placeholder. If the dynamic content placeholder is not available, this is the "end_user_label" value. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - readOnly: true - status_category: + type: type: string - description: The status category the custom ticket status belongs to - enum: - - new - - open - - pending - - hold - - solved - updated_at: + group: type: string - format: date-time - description: The date and time the custom ticket status was last updated - readOnly: true - required: - - status_category - - agent_label - CustomStatusResponse: + SkillBasedRoutingAttributeDefinitionsDefinitions: type: object properties: - custom_status: - $ref: '#/components/schemas/CustomStatusObject' - CustomStatusUpdateInput: + conditions_any: + type: array + items: + $ref: '#/components/schemas/SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll' + x-ballerina-name: conditionsAny + conditions_all: + type: array + items: + $ref: '#/components/schemas/SkillBasedRoutingAttributeDefinitionsDefinitionsConditionsAll' + x-ballerina-name: conditionsAll + DefinitionsResponseDefinitionsConditionsAll: type: object properties: - active: + nullable: type: boolean - description: True if the custom status is set as active; inactive if false - agent_label: + operators: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsOperators' + repeatable: + type: boolean + subject: type: string - description: The dynamic content placeholder, if present, or the "agent_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - description: + values: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsValues' + title: type: string - description: The dynamic content placeholder, if present, or the "description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - end_user_description: + type: type: string - description: The dynamic content placeholder, if present, or the "end_user_description" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - end_user_label: + group: type: string - description: The dynamic content placeholder, if present, or the "end_user_label" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - CustomStatusUpdateRequest: + EmailCCObject: type: object - properties: - custom_status: - $ref: '#/components/schemas/CustomStatusUpdateInput' - CustomStatusesResponse: + allOf: + - $ref: '#/components/schemas/FollowerObject' + - $ref: '#/components/schemas/EmailCCObjectAllOf2' + GroupMembershipsResponse: type: object properties: - custom_statuses: + group_memberships: type: array items: - $ref: '#/components/schemas/CustomStatusObject' - DefinitionsResponse: + $ref: '#/components/schemas/GroupMembershipObject' + x-ballerina-name: groupMemberships + TriggerBulkUpdateRequest: type: object properties: - definitions: - type: object - properties: - conditions_all: - type: array - items: - type: object - properties: - group: - type: string - nullable: - type: boolean - operators: - type: array - items: - type: object - properties: - terminal: - type: boolean - title: - type: string - value: - type: string - repeatable: - type: boolean - subject: - type: string - title: - type: string - type: - type: string - values: - type: array - items: - type: object - properties: - enabled: - type: boolean - title: - type: string - value: - type: string - conditions_any: - type: array - items: - type: object - properties: - group: - type: string - nullable: - type: boolean - operators: - type: array - items: - type: object - properties: - terminal: - type: boolean - title: - type: string - value: - type: string - repeatable: - type: boolean - subject: - type: string - title: - type: string - type: - type: string - values: - type: array - items: - type: object - properties: - enabled: - type: boolean - title: - type: string - value: - type: string - DeletedUserObject: + triggers: + type: array + items: + $ref: '#/components/schemas/TriggerBulkUpdateItem' + GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators: type: object properties: - active: - type: boolean - created_at: - type: string - email: - type: string - id: - type: integer - locale: - type: string - locale_id: - type: integer - name: - type: string - organization_id: - type: integer - phone: - type: string - nullable: true - photo: - type: object - nullable: true - role: + title: type: string - shared_phone_number: + value: type: string - nullable: true - time_zone: + SLAPolicyFilterConditionObject: + type: object + properties: + field: type: string - updated_at: + description: The name of a ticket field + value: + description: The value of a ticket field + oneOf: + - type: string + - type: array + items: + oneOf: + - type: string + - type: integer + operator: type: string - url: + description: A comparison operator + ChannelFrameworkResultObject: + type: object + properties: + external_resource_id: type: string - required: - - id - - url - - name - - email - - created_at - - updated_at - - time_zone - - phone - - shared_phone_number - - photo - - locale_id - - locale - - organization_id - - role - - active - DeletedUserResponse: + description: "The external ID of the resource, as passed in" + readOnly: true + x-ballerina-name: externalResourceId + status: + $ref: '#/components/schemas/ChannelFrameworkResultStatusObject' + V2TriggerCategoriesBody: type: object properties: - deleted_user: - $ref: '#/components/schemas/DeletedUserObject' - DeletedUsersResponse: + trigger_category: + allOf: + - $ref: '#/components/schemas/TriggerCategoryRequest' + - $ref: '#/components/schemas/TriggerCategoryRequestRequired' + x-ballerina-name: triggerCategory + AccountSettingsBillingObject: type: object properties: - deleted_users: + backend: + type: string + description: "Billing configuration options. See [Billing](#billing)" + TicketMetricEventsResponseAllOf1: + type: object + properties: + ticket_metric_events: type: array items: - $ref: '#/components/schemas/DeletedUserObject' - DynamicContentObject: - title: Dynamic Content Items + $ref: '#/components/schemas/TicketMetricEventBaseObject' + x-ballerina-name: ticketMetricEvents + CustomObjectField: + type: object + example: + active: true + created_at: 2022-09-07T23:21:59Z + description: Make + id: 4398096842879 + key: make + position: 0 + raw_description: Make + raw_title: Make + regexp_for_validation: null + system: false + title: Make + type: text + updated_at: 2022-09-07T23:22:00Z + url: https://company.zendesk.com/api/v2/custom_objects/car/fields/4398096842879.json + allOf: + - $ref: '#/components/schemas/CustomFieldObject' + CustomStatusCreateInput: + type: object + allOf: + - $ref: '#/components/schemas/CustomStatusUpdateInput' + - $ref: '#/components/schemas/CustomStatusCreateInputAllOf2' + MacroUpdateManyInputMacros: + required: + - id type: object properties: - created_at: - type: string - format: date-time - description: When this record was created - readOnly: true - default_locale_id: - type: integer - description: The default locale for the item. Must be one of the [locales the account has active](/api-reference/ticketing/account-configuration/locales/#list-locales). + active: + type: boolean + description: The active status of the macro (true or false) id: type: integer - description: Automatically assigned when creating items - readOnly: true - name: + description: The ID of the macro to update + position: + type: integer + description: The new position of the macro + CustomObjectRecord: + required: + - name + type: object + properties: + updated_at: type: string - description: The unique name of the item - outdated: - type: boolean - description: Indicates the item has outdated variants within it + description: The time of the last update of the object + format: date-time readOnly: true - placeholder: + x-ballerina-name: updatedAt + updated_by_user_id: type: string - description: Automatically generated placeholder for the item, derived from name + description: Id of the last user who updated the object readOnly: true - updated_at: + x-ballerina-name: updatedByUserId + custom_object_key: type: string - format: date-time - description: When this record was last updated + description: A user-defined unique identifier readOnly: true - url: + x-ballerina-name: customObjectKey + name: type: string - description: The API url of this item + description: User-defined display name for the object readOnly: true - variants: - type: array - description: All variants within this item. See [Dynamic Content Item Variants](/api-reference/ticketing/ticket-management/dynamic_content_item_variants/) - items: - $ref: '#/components/schemas/DynamicContentVariantObject' - required: - - name - - default_locale_id - - variants - DynamicContentResponse: - type: object - properties: - item: - $ref: '#/components/schemas/DynamicContentObject' - DynamicContentVariantObject: - type: object - properties: - active: - type: boolean - description: If the variant is active and useable - content: - type: string - description: The content of the variant created_at: type: string + description: The time the object was created format: date-time - description: When the variant was created readOnly: true - default: - type: boolean - description: If the variant is the default for the item it belongs to + x-ballerina-name: createdAt + external_id: + type: string + description: An id you can use to link custom object records to external + data + nullable: true + x-ballerina-name: externalId + custom_object_fields: + type: object + additionalProperties: true + x-ballerina-name: customObjectFields id: - type: integer - description: Automatically assigned when the variant is created - readOnly: true - locale_id: - type: integer - description: An active locale - outdated: - type: boolean - description: If the variant is outdated + type: string + description: Automatically assigned upon creation readOnly: true - updated_at: + created_by_user_id: type: string - format: date-time - description: When the variant was last updated + description: Id of a user who created the object readOnly: true + x-ballerina-name: createdByUserId url: type: string - description: The API url of the variant + description: Direct link to the specific custom object readOnly: true + TriggerCategoryRequest: + type: object + properties: + name: + type: string + position: + type: integer + format: int64 + ViaObject: + type: object + properties: + channel: + type: string + description: | + This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" + source: + description: | + For some channels a source object gives more information about how or why the ticket or event was created + allOf: + - $ref: '#/components/schemas/ViaObjectSource' + description: | + An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) + readOnly: true example: - active: true - content: This is my dynamic content in English - created_at: "2014-04-09T19:53:23Z" - default: true - id: 23 - locale_id: 125 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json - required: - - content - - locale_id - DynamicContentVariantResponse: + channel: rule + source: + from: + id: 22472716 + title: Assign to first responder + rel: trigger + to: {} + CustomStatusResponse: type: object properties: - variant: - $ref: '#/components/schemas/DynamicContentVariantObject' - DynamicContentVariantsResponse: + custom_status: + allOf: + - $ref: '#/components/schemas/CustomStatusObject' + x-ballerina-name: customStatus + BatchJobResponseResults: type: object properties: - variants: + trigger_categories: type: array items: - $ref: '#/components/schemas/DynamicContentVariantObject' - DynamicContentsResponse: - type: object - properties: - items: + $ref: '#/components/schemas/TriggerCategory' + x-ballerina-name: triggerCategories + triggers: type: array items: - $ref: '#/components/schemas/DynamicContentObject' - EmailCCObject: - type: object - allOf: - - $ref: '#/components/schemas/FollowerObject' - - type: object - properties: - action: - type: string - enum: - - put - - delete - user_email: - type: string - user_id: - type: string - user_name: - type: string - Error: + $ref: '#/components/schemas/TriggerObject' + UserCreateInputOrganization: + required: + - name type: object properties: - code: - type: string - detail: - type: string - id: + name: type: string - links: - type: object - source: + TicketCreateVoicemailTicketInput: + type: object + properties: + voice_comment: type: object - status: - type: string - title: + description: Required if creating voicemail ticket + allOf: + - $ref: '#/components/schemas/TicketCreateVoicemailTicketVoiceCommentInput' + x-ballerina-name: voiceComment + comment: + $ref: '#/components/schemas/TicketCommentObject' + priority: type: string - required: - - code - - title - Errors: + description: The urgency with which the ticket should be addressed + enum: + - urgent + - high + - normal + - low + via_id: + type: integer + description: Required for Create Ticket operation + enum: + - 44 + - 45 + - 46 + x-ballerina-name: viaId + TriggerConditionsDiffObject: type: object properties: - errors: + all: type: array + nullable: true items: - $ref: '#/components/schemas/Error' - EssentialsCardObject: + $ref: '#/components/schemas/TriggerConditionDiffObject' + any: + type: array + nullable: true + items: + $ref: '#/components/schemas/TriggerConditionDiffObject' + UserFieldResponse: type: object properties: - created_at: + user_field: + allOf: + - $ref: '#/components/schemas/UserFieldObject' + x-ballerina-name: userField + GroupSLAPolicyObject: + required: + - filter + - title + type: object + properties: + filter: + $ref: '#/components/schemas/GroupSLAPolicyFilterObject' + updated_at: type: string + description: The time of the last update of the Group SLA policy format: date-time - description: Date and time the essentials card were created - readOnly: true - default: - type: boolean - description: If true, the system has used the first twenty fields for the custom object type as the essentials card. readOnly: true - fields: + x-ballerina-name: updatedAt + policy_metrics: type: array - description: Fields that are displayed in the essentials card details. The order is defined by the order of the fields in the array + description: "Array of [policy metric](#policy-metric) objects" items: - type: object - additionalProperties: true - id: + $ref: '#/components/schemas/GroupSLAPolicyMetricObject' + x-ballerina-name: policyMetrics + created_at: type: string - description: | - id of the essentials card - nullable: true + description: The time the Group SLA policy was created + format: date-time readOnly: true - key: + x-ballerina-name: createdAt + description: type: string - description: | - Object type. Example: `zen:user` refers to `User` type - readOnly: true - layout: + description: The description of the Group SLA policy + id: type: string - description: | - layout type + description: Automatically assigned when created readOnly: true - max_count: + position: type: integer - description: Maximum number of fields allowed in the essentials card - readOnly: true - updated_at: + description: "Position of the Group SLA policy. This position determines\ + \ the order in which policies are matched to tickets. If not specified,\ + \ the Group SLA policy is added at the last position" + title: type: string - format: date-time - description: Date and time the essentials card were last updated + description: The title of the Group SLA policy + url: + type: string + description: URL of the Group SLA policy record readOnly: true example: - created_at: "2012-04-02T22:55:29Z" - default: true - fields: - - id: null - zrn: zen:user:identity:email - - id: null - zrn: zen:user:field:standard:external_id - - id: null - zrn: zen:user:field:standard:iana_time_zone - - id: null - zrn: zen:user:field:standard:locale - - id: null - zrn: zen:user:field:standard:organization_id - id: "123" - key: zen:custom_object:boat - layout: essentials_card - max_count: 20 - updated_at: "2012-04-02T22:55:29Z" - required: - - fields - EssentialsCardResponse: - type: object - properties: - object_layout: - $ref: '#/components/schemas/EssentialsCardObject' - EssentialsCardsResponse: - type: object - properties: - object_layouts: - type: array - items: - $ref: '#/components/schemas/EssentialsCardObject' - ExportIncrementalOrganizationsResponse: + created_at: 2023-03-17T22:50:26Z + description: "Group: Tier 1" + filter: + all: [] + id: 01H078CBDY28BZG7P6BONY09DN + policy_metrics: + - business_hours: false + metric: group_ownership_time + priority: low + target: 3600 + position: 3 + title: Tier 1 + updated_at: 2023-03-17T22:50:26Z + url: https://company.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json + TicketMetricTimeObject: type: object properties: - count: + calendar: type: integer - end_of_stream: - type: boolean - end_time: + description: Time in calendar hours + readOnly: true + business: type: integer - next_page: - type: string - nullable: true - organizations: - type: array - items: - $ref: '#/components/schemas/OrganizationObject' - example: - count: 1 - end_of_stream: true - end_time: 1601357503 - next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 - organizations: - - created_at: "2018-11-14T00:14:52Z" - details: caterpillar =) - domain_names: - - remain.com - external_id: ABC198 - group_id: 1835962 - id: 4112492 - name: Groablet Enterprises - notes: donkey - organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" - org_field_1: happy happy - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" - url: https://example.zendesk.com/api/v2/organizations/4112492.json - ExportIncrementalTicketEventsResponse: + description: Time in business hours + readOnly: true + TicketFieldObject: + required: + - title + - type type: object properties: - count: - type: integer - end_of_stream: - type: boolean - end_time: - type: integer - next_page: + raw_title: type: string - nullable: true - ticket_events: + description: "The dynamic content placeholder if present, or the `title`\ + \ value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawTitle + creator_app_name: + type: string + description: "Name of the app that created the ticket field, or a null value\ + \ if no app created the ticket field" + x-ballerina-name: creatorAppName + custom_field_options: type: array + description: Required and presented for a custom ticket field of type "multiselect" + or "tagger" items: - $ref: '#/components/schemas/TicketMetricEventBaseObject' - example: - count: 1 - end_of_stream: true - end_time: 1601357503 - next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 - ticket_events: - - id: 926256957613 - instance_id: 1 - metric: agent_work_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: measure - FollowerObject: - type: object - properties: - action: - type: string - enum: - - put - - delete - user_email: - type: string - format: email - user_id: - type: string - GroupMembershipObject: - type: object - properties: + $ref: '#/components/schemas/CustomFieldOptionObject' + x-ballerina-name: customFieldOptions + visible_in_portal: + type: boolean + description: Whether this field is visible to end users in Help Center + x-ballerina-name: visibleInPortal created_at: type: string + description: The time the custom ticket field was created format: date-time - description: The time the group was created readOnly: true - default: + x-ballerina-name: createdAt + description: + type: string + description: Describes the purpose of the ticket field to users + title: + type: string + description: The title of the ticket field + type: + type: string + description: "System or custom field type. Editable for custom field types\ + \ and only on creation. See [Create Ticket Field](#create-ticket-field)" + required: type: boolean - description: If true, tickets assigned directly to the agent will assume this membership's group - group_id: - type: integer - description: The id of a group - id: - type: integer - description: Automatically assigned upon creation + description: "If true, agents must enter a value in the field to change\ + \ the ticket status to solved" + editable_in_portal: + type: boolean + description: Whether this field is editable by end users in Help Center + x-ballerina-name: editableInPortal + custom_statuses: + type: array + description: List of customized ticket statuses. Only presented for a system + ticket field of type "custom_status" readOnly: true + items: + $ref: '#/components/schemas/TicketFieldCustomStatusObject' + x-ballerina-name: customStatuses updated_at: type: string + description: The time the custom ticket field was last updated format: date-time - description: The time of the last update of the group readOnly: true - url: - type: string - description: The API url of this record - readOnly: true - user_id: - type: integer - description: The id of an agent - required: - - user_id - - group_id - GroupMembershipResponse: - type: object - properties: - group_membership: - $ref: '#/components/schemas/GroupMembershipObject' - GroupMembershipsResponse: - type: object - properties: - group_memberships: + x-ballerina-name: updatedAt + system_field_options: type: array + description: "Presented for a system ticket field of type \"tickettype\"\ + , \"priority\" or \"status\"" + readOnly: true items: - $ref: '#/components/schemas/GroupMembershipObject' - GroupObject: - type: object - properties: - created_at: + $ref: '#/components/schemas/SystemFieldOptionObject' + x-ballerina-name: systemFieldOptions + relationship_target_type: type: string - format: date-time - description: The time the group was created - readOnly: true - default: - type: boolean - description: If the group is the default one for the account - readOnly: true - deleted: - type: boolean - description: Deleted groups get marked as such - readOnly: true - description: + description: "A representation of what type of object the field references.\ + \ Options are \"zen:user\", \"zen:organization\", \"zen:ticket\", or \"\ + zen:custom_object:{key}\" where key is a custom object key. For example\ + \ \"zen:custom_object:apartment\"" + x-ballerina-name: relationshipTargetType + regexp_for_validation: type: string - description: The description of the group + description: For "regexp" fields only. The validation pattern for a field + value to be deemed valid + nullable: true + x-ballerina-name: regexpForValidation + relationship_filter: + type: object + description: A filter definition that allows your autocomplete to filter + down results + x-ballerina-name: relationshipFilter id: type: integer - description: Automatically assigned when creating groups + description: Automatically assigned when created readOnly: true - is_public: - type: boolean - description: | - If true, the group is public. - If false, the group is private. - You can't change a private group to a public group - name: + tag: type: string - description: The name of the group - updated_at: + description: For "checkbox" fields only. A tag added to tickets when the + checkbox field is selected + nullable: true + creator_user_id: + type: integer + description: "The id of the user that created the ticket field, or a value\ + \ of \"-1\" if an app created the ticket field" + x-ballerina-name: creatorUserId + collapsed_for_agents: + type: boolean + description: "If true, the field is shown to agents by default. If false,\ + \ the field is hidden alongside infrequently used fields. Classic interface\ + \ only" + x-ballerina-name: collapsedForAgents + active: + type: boolean + description: Whether this field is available + agent_description: type: string - format: date-time - description: The time of the last update of the group - readOnly: true - url: + description: A description of the ticket field that only agents can see + x-ballerina-name: agentDescription + raw_title_in_portal: type: string - description: The API url of the group - readOnly: true - example: - created_at: "2009-07-20T22:55:29Z" - default: true - deleted: false - description: Some clever description here - id: 3432 - is_public: true - name: First Level Support - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/groups/3432.json - required: - - name - GroupResponse: - type: object - properties: - group: - $ref: '#/components/schemas/GroupObject' - GroupSLAPoliciesResponse: - type: object - properties: - count: - type: integer - readOnly: true - group_sla_policies: - type: array - items: - $ref: '#/components/schemas/GroupSLAPolicyObject' - next_page: + description: "The dynamic content placeholder if present, or the \"title_in_portal\"\ + \ value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawTitleInPortal + raw_description: type: string - nullable: true - readOnly: true - previous_page: + description: "The dynamic content placeholder if present, or the `description`\ + \ value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawDescription + url: type: string - nullable: true + description: The URL for this resource readOnly: true - GroupSLAPolicyFilterConditionObject: - type: object - properties: - field: - type: string - description: The name of a ticket field - operator: + required_in_portal: + type: boolean + description: "If true, end users must enter a value in the field to create\ + \ the request" + x-ballerina-name: requiredInPortal + removable: + type: boolean + description: "If false, this field is a system field that must be present\ + \ on all tickets" + readOnly: true + sub_type_id: + type: integer + description: For system ticket fields of type "priority" and "status". Defaults + to 0. A "priority" sub type of 1 removes the "Low" and "Urgent" options. + A "status" sub type of 1 adds the "On-Hold" option + x-ballerina-name: subTypeId + position: + type: integer + description: "The relative position of the ticket field on a ticket. Note\ + \ that for accounts with ticket forms, positions are controlled by the\ + \ different forms" + title_in_portal: type: string - description: A comparison operator - value: - type: array - description: The value of a ticket field - items: - oneOf: - - type: string - - type: integer - GroupSLAPolicyFilterDefinitionResponse: + description: The title of the ticket field for end users in Help Center + x-ballerina-name: titleInPortal + example: + active: true + agent_description: This is the agent only description for the subject field + collapsed_for_agents: false + created_at: 2009-07-20T22:55:29Z + description: This is the subject field of a ticket + editable_in_portal: true + id: 34 + position: 21 + raw_description: This is the subject field of a ticket + raw_title: "{{dc.my_title}}" + raw_title_in_portal: "{{dc.my_title_in_portal}}" + regexp_for_validation: null + removable: false + required: true + required_in_portal: true + tag: null + title: Subject + title_in_portal: Subject + type: subject + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/ticket_fields/34.json + visible_in_portal: true + RequestResponse: type: object properties: - definitions: - type: object - properties: - all: - type: array - items: - type: object - properties: - group: - type: string - operators: - type: array - items: - type: object - properties: - title: - type: string - value: - type: string - title: - type: string - value: - type: string - values: - type: object - properties: - list: - type: array - items: - type: object - properties: - title: - type: string - value: - type: integer - nullable: true - type: - type: string - GroupSLAPolicyFilterObject: + request: + $ref: '#/components/schemas/RequestObject' + ComplianceDeletionStatusesResponse: type: object - description: An object that describes the conditions a ticket must match for a Group SLA policy to be applied to the ticket. See [Filter](#filter). properties: - all: + compliance_deletion_statuses: type: array items: - $ref: '#/components/schemas/GroupSLAPolicyFilterConditionObject' - GroupSLAPolicyMetricObject: + $ref: '#/components/schemas/ComplianceDeletionStatusObject' + x-ballerina-name: complianceDeletionStatuses + TicketFieldCustomStatusObject: type: object properties: - business_hours: + default: type: boolean - description: Whether the metric targets are being measured in business hours or calendar hours - metric: - type: string - description: The definition of the time that is being measured - priority: - type: string - description: Priority that a ticket must match - target: - type: integer - description: The time within which the end-state for a metric should be met - GroupSLAPolicyObject: - type: object - properties: - created_at: - type: string - format: date-time - description: The time the Group SLA policy was created - readOnly: true - description: - type: string - description: The description of the Group SLA policy - filter: - $ref: '#/components/schemas/GroupSLAPolicyFilterObject' - id: + description: "If true, the custom status is set to default. If false, the\ + \ custom status is set to non-default" + end_user_label: type: string - description: Automatically assigned when created - readOnly: true - policy_metrics: - type: array - description: Array of [policy metric](#policy-metric) objects - items: - $ref: '#/components/schemas/GroupSLAPolicyMetricObject' - position: - type: integer - description: Position of the Group SLA policy. This position determines the order in which policies are matched to tickets. If not specified, the Group SLA policy is added at the last position - title: + description: The label displayed to end users + x-ballerina-name: endUserLabel + status_category: type: string - description: The title of the Group SLA policy + description: The status category the custom ticket status belongs to + enum: + - new + - open + - pending + - hold + - solved + x-ballerina-name: statusCategory updated_at: type: string + description: The date and time at which the custom ticket status was last + updated format: date-time - description: The time of the last update of the Group SLA policy - readOnly: true - url: - type: string - description: URL of the Group SLA policy record readOnly: true - example: - created_at: "2023-03-17T22:50:26Z" - description: 'Group: Tier 1' - filter: - all: [] - id: 01H078CBDY28BZG7P6BONY09DN - policy_metrics: - - business_hours: false - metric: group_ownership_time - priority: low - target: 3600 - position: 3 - title: Tier 1 - updated_at: "2023-03-17T22:50:26Z" - url: https://company.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json - required: - - title - - filter - GroupSLAPolicyResponse: - type: object - properties: - group_sla_policy: - $ref: '#/components/schemas/GroupSLAPolicyObject' - GroupsCountObject: - type: object - properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - description: Timestamp that indicates when the count was last updated - readOnly: true - value: - type: integer - description: Approximate count of groups - readOnly: true - GroupsResponse: - type: object - properties: - groups: - type: array - items: - $ref: '#/components/schemas/GroupObject' - HostMappingObject: - title: Host Mapping - type: object - properties: - cname: + x-ballerina-name: updatedAt + end_user_description: type: string - description: The canonical name record for a host mapping - expected_cnames: - type: array - description: Array of expected CNAME records for host mapping(s) of a given brand - items: - type: string - is_valid: + description: The description displayed to end users + x-ballerina-name: endUserDescription + active: type: boolean - description: Whether a host mapping is valid or not for a given brand - reason: + description: "If true, if the custom status is set to active. If false,\ + \ the custom status is set to inactive" + created_at: type: string - description: Reason why a host mapping is valid or not - example: - cname: google.com - expected_cnames: - - bar.zendesk.coom - is_valid: false - reason: wrong_cname - IncrementalSkillBasedRouting: - title: Incremental Skill-based Routing - type: object - properties: - attribute_values: - type: array - description: Routing attribute values - items: - $ref: '#/components/schemas/IncrementalSkillBasedRoutingAttributeValue' - attributes: - type: array - description: Routing attributes - items: - $ref: '#/components/schemas/IncrementalSkillBasedRoutingAttribute' - count: - type: integer - description: The number of results returned for the current request + description: The date and time at which the custom ticket status was created + format: date-time readOnly: true - end_time: + x-ballerina-name: createdAt + description: + type: string + description: The description of when the user should select this custom + ticket status + id: type: integer - description: The most recent resource creation time present in this result set in Unix epoch time + description: Automatically assigned when the custom ticket status is created readOnly: true - instance_values: - type: array - description: Routing instance values - items: - $ref: '#/components/schemas/IncrementalSkillBasedRoutingInstanceValue' - next_page: + agent_label: type: string - description: The URL that should be called to get the next set of results - readOnly: true - IncrementalSkillBasedRoutingAttribute: + description: The label displayed to agents + x-ballerina-name: agentLabel + AccountSettingsResponse: type: object properties: - id: - type: string - description: Automatically assigned when an attribute is created - readOnly: true - name: - type: string - description: The name of the attribute - readOnly: true - time: - type: string - format: date-time - description: The time the attribute was created, updated, or deleted - readOnly: true - type: - type: string - description: One of "create", "update", or "delete" - readOnly: true - IncrementalSkillBasedRoutingAttributeValue: + settings: + $ref: '#/components/schemas/AccountSettingsObject' + example: + settings: + active_features: + advanced_analytics: false + agent_forwarding: false + allow_ccs: true + allow_email_template_customization: true + automatic_answers: false + bcc_archiving: false + benchmark_opt_out: false + business_hours: false + chat: false + chat_about_my_ticket: false + csat_reason_code: false + custom_dkim_domain: true + customer_context_as_default: false + customer_satisfaction: false + dynamic_contents: false + explore: true + explore_on_support_ent_plan: false + explore_on_support_pro_plan: false + facebook: false + facebook_login: false + fallback_composer: false + forum_analytics: true + good_data_and_explore: false + google_login: false + insights: false + is_abusive: false + light_agents: false + markdown: false + on_hold_status: false + organization_access_enabled: true + rich_content_in_emails: true + sandbox: false + satisfaction_prediction: false + suspended_ticket_notification: false + ticket_forms: true + ticket_tagging: true + topic_suggestion: false + twitter: true + twitter_login: false + user_org_fields: true + user_tagging: true + voice: true + agents: + agent_home: false + agent_workspace: false + aw_self_serve_migration_enabled: true + focus_mode: false + idle_timeout_enabled: false + unified_agent_statuses: false + api: + accepted_api_agreement: true + api_password_access: "true" + api_token_access: "true" + apps: + create_private: true + create_public: false + use: true + billing: + backend: zuora + branding: + favicon_url: null + header_color: 78A300 + header_logo_url: null + page_background_color: "333333" + tab_background_color: 7FA239 + text_color: FFFFFF + brands: + default_brand_id: 1873 + require_brand_on_new_tickets: false + cdn: + cdn_provider: default + fallback_cdn_provider: cloudfront + hosts: + - name: default + url: https://p18.zdassets.com + - name: cloudfront + url: https://d2y9oszrd3dhjh.cloudfront.net + chat: + available: true + enabled: false + integrated: true + maximum_request_count: 1 + welcome_message: Hi there. How can I help today? + cross_sell: + show_chat_tooltip: true + xsell_source: null + gooddata_advanced_analytics: + enabled: true + google_apps: + has_google_apps: false + has_google_apps_admin: false + groups: + check_group_name_uniqueness: true + limits: + attachment_size: 52428800 + localization: + locale_ids: + - 1042 + lotus: + pod_id: 999 + prefer_lotus: true + reporting: true + metrics: + account_size: 100-399 + onboarding: + checklist_onboarding_version: 2 + onboarding_segments: null + product_sign_up: null + routing: + autorouting_tag: "" + enabled: false + max_email_capacity: 0 + max_messaging_capacity: 0 + rule: + macro_most_used: true + macro_order: alphabetical + skill_based_filtered_views: [] + using_skill_based_routing: false + side_conversations: + email_channel: false + msteams_channel: false + show_in_context_panel: false + slack_channel: false + tickets_channel: false + statistics: + forum: true + rule_usage: true + search: true + ticket_form: + raw_ticket_forms_instructions: Please choose your issue below + ticket_forms_instructions: Please choose your issue below + ticket_sharing_partners: + support_addresses: + - support@grokpetre.zendesk.com + tickets: + accepted_new_collaboration_tos: false + agent_collision: true + agent_invitation_enabled: true + agent_ticket_deletion: false + allow_group_reset: true + assign_default_organization: true + assign_tickets_upon_solve: true + auto_translation_enabled: false + auto_updated_ccs_followers_rules: false + chat_sla_enablement: false + collaboration: true + comments_public_by_default: true + email_attachments: false + emoji_autocompletion: true + follower_and_email_cc_collaborations: false + has_color_text: true + is_first_comment_private_enabled: true + light_agent_email_ccs_allowed: false + list_empty_views: true + list_newest_comments_first: true + markdown_ticket_comments: false + maximum_personal_views_to_list: 8 + private_attachments: false + rich_text_comments: true + status_hold: false + tagging: true + using_skill_based_routing: false + twitter: + shorten_url: optional + user: + agent_created_welcome_emails: true + end_user_phone_number_validation: false + have_gravatars_enabled: true + language_selection: true + multiple_organizations: false + tagging: true + time_zone_selection: true + voice: + agent_confirmation_when_forwarding: true + agent_wrap_up_after_calls: true + enabled: true + logging: true + maximum_queue_size: 5 + maximum_queue_wait_time: 1 + only_during_business_hours: false + outbound_enabled: true + recordings_public: true + uk_mobile_forwarding: true + CustomObjectResponse: type: object properties: - attribute_id: - type: string - description: Id of the associated attribute - readOnly: true - id: + custom_object: + allOf: + - $ref: '#/components/schemas/CustomObject' + x-ballerina-name: customObject + AccountSettingsTwitterObject: + type: object + properties: + shorten_url: type: string - description: Automatically assigned when an attribute value is created - readOnly: true - name: + x-ballerina-name: shortenUrl + description: "X (formerly Twitter) settings. See [X](#x-formerly-twitter)" + CustomObjectRecordsJobsResponse: + type: object + properties: + job_status: + allOf: + - $ref: '#/components/schemas/CustomObjectRecordsJobsResponseJobStatus' + x-ballerina-name: jobStatus + IncrementalSkillBasedRouting: + title: Incremental Skill-based Routing + type: object + properties: + next_page: type: string - description: The name of the attribute value + description: The URL that should be called to get the next set of results readOnly: true - time: - type: string - format: date-time - description: The time the attribute value was created, updated, or deleted + x-ballerina-name: nextPage + instance_values: + type: array + description: Routing instance values + items: + $ref: '#/components/schemas/IncrementalSkillBasedRoutingInstanceValue' + x-ballerina-name: instanceValues + attribute_values: + type: array + description: Routing attribute values + items: + $ref: '#/components/schemas/IncrementalSkillBasedRoutingAttributeValue' + x-ballerina-name: attributeValues + count: + type: integer + description: The number of results returned for the current request readOnly: true - type: - type: string - description: One of "create", "update", or "delete" + end_time: + type: integer + description: The most recent resource creation time present in this result + set in Unix epoch time readOnly: true - IncrementalSkillBasedRoutingInstanceValue: + x-ballerina-name: endTime + attributes: + type: array + description: Routing attributes + items: + $ref: '#/components/schemas/IncrementalSkillBasedRoutingAttribute' + AssigneeFieldAssignableGroupAgentsResponse: type: object properties: - attribute_value_id: + next_page: type: string - description: Id of the associated attribute value + nullable: true readOnly: true - id: - type: string - description: Automatically assigned when an instance value is created - readOnly: true - instance_id: - type: string - description: Id of the associated agent or ticket - readOnly: true - time: - type: string - format: date-time - description: The time the instance value was created or deleted - readOnly: true - type: - type: string - description: One of "associate_agent", "unassociate_agent", "associate_ticket", or "unassociate_ticket" - readOnly: true - JobStatusObject: - type: object - properties: - id: - type: string - description: Automatically assigned when the job is queued - readOnly: true - job_type: - type: string - description: The type of the job - readOnly: true - message: - type: string - description: Message from the job worker, if any - nullable: true - readOnly: true - progress: + x-ballerina-name: nextPage + count: type: integer - description: Number of tasks that have already been completed - nullable: true - readOnly: true - results: - description: Result data from processed tasks. See [Results](#results) below - oneOf: - - type: array - items: - $ref: '#/components/schemas/JobStatusResultObject' - nullable: true - - type: object - properties: - success: - type: boolean - description: Whether the action was successful or not - readOnly: true - required: - - success - readOnly: true - status: + description: Number of agents listed in `agents` property + previous_page: type: string - description: 'The current status. One of the following: "queued", "working", "failed", "completed"' - readOnly: true - total: - type: integer - description: The total number of tasks this job is batching through nullable: true readOnly: true - url: - type: string - description: The URL to poll for status updates - readOnly: true + x-ballerina-name: previousPage + agents: + type: array + items: + $ref: '#/components/schemas/AssigneeFieldAssignableAgentObject' example: - id: 82de0b044094f0c67893ac9fe64f1a99 - message: Completed at 2018-03-08 10:07:04 +0000 - progress: 2 - results: - - action: update - id: 244 - status: Updated - success: true - - action: update - id: 245 - status: Updated - success: true - status: completed - total: 2 - url: https://example.zendesk.com/api/v2/job_statuses/82de0b0467893ac9fe64f1a99.json - JobStatusResponse: + agents: + - avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png + id: 6473829100 + name: Joe Smith + - avatar_url: https://z3n-example.zendesk.com/system/photos/412005192023/my_profile.png + id: 9182736400 + name: Jane Doe + - avatar_url: https://z3n-example.zendesk.com/system/photos/887005192023/my_profile.png + id: 1928373460 + name: Cookie Monster + count: 3 + next_page: null + previous_page: null + SkillBasedRoutingAttributeDefinitions: type: object properties: - job_status: - $ref: '#/components/schemas/JobStatusObject' - JobStatusResultObject: - oneOf: - - $ref: '#/components/schemas/CreateResourceResult' - - $ref: '#/components/schemas/UpdateResourceResult' - additionalProperties: true - JobStatusesResponse: + definitions: + $ref: '#/components/schemas/SkillBasedRoutingAttributeDefinitionsDefinitions' + CustomRoleResponse: type: object properties: - job_statuses: - type: array - items: - $ref: '#/components/schemas/JobStatusObject' + custom_role: + allOf: + - $ref: '#/components/schemas/CustomRoleObject' + x-ballerina-name: customRole + UsersRequest: required: - - job_statuses - ListDeletedTicketsResponse: - type: object - allOf: - - type: object - properties: - deleted_tickets: - type: array - items: - type: object - properties: - actor: - type: object - properties: - id: - type: integer - name: - type: string - deleted_at: - type: string - id: - type: integer - previous_state: - type: string - subject: - type: string - - $ref: '#/components/schemas/OffsetPaginationObject' - ListTicketCollaboratorsResponse: + - users type: object - additionalProperties: true - ListTicketEmailCCsResponse: + properties: + users: + type: array + items: + $ref: '#/components/schemas/UserInput' + TriggerDefinitionObject: type: object - additionalProperties: true + properties: + conditions_any: + type: array + items: + $ref: '#/components/schemas/TriggerConditionDefinitionObjectAny' + x-ballerina-name: conditionsAny + conditions_all: + type: array + items: + $ref: '#/components/schemas/TriggerConditionDefinitionObjectAll' + x-ballerina-name: conditionsAll + actions: + type: array + items: + $ref: '#/components/schemas/TriggerActionDefinitionObject' ListTicketFollowersResponse: type: object additionalProperties: true - ListTicketIncidentsResponse: + AttachmentUpdateRequest: type: object - additionalProperties: true - ListTicketProblemsResponse: + properties: + attachment: + $ref: '#/components/schemas/AttachmentUpdateInput' + DynamicContentResponse: type: object - additionalProperties: true - LocaleObject: + properties: + item: + $ref: '#/components/schemas/DynamicContentObject' + AccountSettingsLocalizationObject: type: object properties: - created_at: + locale_ids: + type: array + items: + type: integer + x-ballerina-name: localeIds + description: "Internationalization configuration settings. See [Localization](#localization)" + UserForEndUser: + required: + - name + type: object + properties: + role: type: string - format: date-time - description: The ISO 8601 formatted date-time the locale was created + description: "The role of the user. Possible values: `\"end-user\"`, `\"\ + agent\"`, `\"admin\"`" + iana_time_zone: + type: string + description: The time zone for the user readOnly: true - id: - type: integer - description: The unique ID of the locale + x-ballerina-name: ianaTimeZone + shared_phone_number: + type: boolean + description: "Whether the `phone` number is shared or not. See [Phone Number](/api-reference/ticketing/users/users/#phone-number)\ + \ in the Users API" + x-ballerina-name: sharedPhoneNumber + verified: + type: boolean + description: "Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities)" + created_at: + type: string + description: The time the user was created + format: datetime readOnly: true + x-ballerina-name: createdAt + photo: + type: object + additionalProperties: true + description: "The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/)\ + \ object" locale: type: string - description: The name of the locale + description: The locale for this user readOnly: true - name: + time_zone: type: string - description: The name of the language + description: The time-zone of this user + x-ballerina-name: timeZone + url: + type: string + description: The API url of this user readOnly: true + locale_id: + type: integer + description: The language identifier for this user + x-ballerina-name: localeId updated_at: type: string - format: date-time - description: The ISO 8601 formatted date-time when the locale was last updated + description: The time of the last update of the user + format: datetime readOnly: true - url: + x-ballerina-name: updatedAt + phone: type: string - description: The URL of the locale record + description: "The primary phone number of this user. See [Phone Number](/api-reference/ticketing/users/users/#phone-number)\ + \ in the Users API" + organization_id: + type: integer + description: "The id of the user's organization. If the user has more than\ + \ one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/),\ + \ the id of the user's default organization. If updating, see [Organization\ + \ ID](/api-reference/ticketing/users/users/#organization-id)" + x-ballerina-name: organizationId + name: + type: string + description: The name of the user + id: + type: integer + description: Automatically assigned when creating users readOnly: true - example: - created_at: "2009-07-20T22:55:29Z" - id: 1 - locale: en-US - name: English - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/locales/en-US.json - LocaleResponse: - type: object - properties: - locale: - $ref: '#/components/schemas/LocaleObject' - LocalesResponse: + email: + type: string + description: "The primary email address of this user. If the primary email\ + \ address is not [verified](https://support.zendesk.com/hc/en-us/articles/4408886752410),\ + \ the secondary email address is used" + SkillBasedRoutingTicketFulfilledResponse: type: object properties: - locales: + fulfilled_ticket_ids: type: array items: - $ref: '#/components/schemas/LocaleObject' - MacroApplyTicketResponse: + type: integer + x-ballerina-name: fulfilledTicketIds + BrandUpdateRequest: type: object properties: - result: - type: object - properties: - ticket: - type: object - properties: - assignee_id: - type: integer - comment: - type: object - properties: - body: - type: string - public: - type: boolean - scoped_body: - type: array - items: - type: array - items: - type: string - fields: - type: object - properties: - id: - type: integer - value: - type: string - group_id: - type: integer - id: - type: integer - url: - type: string - MacroAttachmentObject: + brand: + $ref: '#/components/schemas/BrandObject' + TicketChatCommentRedactionResponseChatEvent: type: object properties: - content_type: - type: string - description: 'The content type of the image. Example value: "image/png"' + id: + type: integer + description: Id assigned to the chat event object readOnly: true - content_url: + type: type: string - description: A full URL where the attachment image file can be downloaded + description: Type of chat event readOnly: true - created_at: - type: string - format: date-time - description: The time when this attachment was created - filename: + value: + description: The value of the chat event object + allOf: + - $ref: '#/components/schemas/TicketChatCommentRedactionResponseChatEventValue' + description: Chat event object + readOnly: true + OrganizationFieldsResponse: + type: object + properties: + next_page: type: string - description: The name of the image file + description: URL of the next page + nullable: true readOnly: true - id: + x-ballerina-name: nextPage + organization_fields: + type: array + items: + $ref: '#/components/schemas/OrganizationFieldObject' + x-ballerina-name: organizationFields + count: type: integer - description: Automatically assigned when created + description: Total count of records retrieved readOnly: true - size: - type: integer - description: The size of the image file in bytes + previous_page: + type: string + description: URL of the previous page + nullable: true readOnly: true - MacroAttachmentResponse: - type: object - properties: - macro_attachment: - $ref: '#/components/schemas/MacroAttachmentObject' - MacroAttachmentsResponse: + x-ballerina-name: previousPage + AccountSettingsCrossSellObject: type: object properties: - macro_attachments: - type: array - items: - $ref: '#/components/schemas/MacroAttachmentObject' - MacroCategoriesResponse: + show_chat_tooltip: + type: boolean + x-ballerina-name: showChatTooltip + xsell_source: + type: string + nullable: true + x-ballerina-name: xsellSource + description: Cross Sell settings + DeletedUsersResponse: type: object properties: - categories: + deleted_users: type: array items: - type: string - MacroCommonObject: + $ref: '#/components/schemas/DeletedUserObject' + x-ballerina-name: deletedUsers + GroupSLAPolicyFilterObject: type: object properties: - actions: + all: type: array - description: Each action describes what the macro will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) items: - $ref: '#/components/schemas/ActionObject' - active: + $ref: '#/components/schemas/GroupSLAPolicyFilterConditionObject' + description: "An object that describes the conditions a ticket must match for\ + \ a Group SLA policy to be applied to the ticket. See [Filter](#filter)" + SuspendedTicketsAttachmentsResponse: + type: object + properties: + upload: + $ref: '#/components/schemas/SuspendedTicketsAttachmentsResponseUpload' + TwitterChannelObject: + title: Monitored Twitter handles + required: + - id + - screen_name + - twitter_user_id + type: object + properties: + can_reply: type: boolean - description: Useful for determining if the macro should be displayed - created_at: + description: If replies are allowed for this handle + readOnly: true + x-ballerina-name: canReply + twitter_user_id: + type: integer + description: The country's code + readOnly: true + x-ballerina-name: twitterUserId + avatar_url: + type: string + description: The profile image url of the handle + readOnly: true + x-ballerina-name: avatarUrl + updated_at: type: string + description: The time of the last update of the handle format: date-time - description: The time the macro was created - default: + readOnly: true + x-ballerina-name: updatedAt + screen_name: + type: string + description: The Twitter handle + readOnly: true + x-ballerina-name: screenName + allow_reply: type: boolean - description: If true, the macro is a default macro + description: If replies are allowed for this handle readOnly: true - description: + x-ballerina-name: allowReply + name: type: string - description: The description of the macro - nullable: true + description: The profile name of the handle + readOnly: true + created_at: + type: string + description: The time the handle was created + format: date-time + readOnly: true + x-ballerina-name: createdAt id: type: integer - description: The ID automatically assigned when a macro is created - position: + description: Automatically assigned upon creation + readOnly: true + brand_id: type: integer - description: The position of the macro - restriction: - type: object - description: Access to this macro. A null value allows unrestricted access for all users in the account - additionalProperties: true - nullable: true - title: - type: string - description: The title of the macro - updated_at: - type: string - format: date-time - description: The time of the last update of the macro - url: - type: string - description: A URL to access the macro's details + description: What brand the handle is associated with + readOnly: true + x-ballerina-name: brandId example: - actions: - - field: status - value: solved - - field: priority - value: normal - - field: type - value: incident - - field: assignee_id - value: current_user - - field: group_id - value: current_groups - - field: comment_value - value: 'Thanks for your request. This issue you reported is a known issue. For more information, please visit our forums. ' - active: true - created_at: "2019-09-16T02:17:38Z" - default: false - description: null - id: 360111062754 - position: 9999 - restriction: null - title: Close and redirect to topics - updated_at: "2019-09-16T02:17:38Z" - url: https://subdomain.zendesk.com/api/v2/macros/360111062754.json - required: - - actions - - title - MacroInput: + created_at: 2009-05-13T00:07:08Z + id: 211 + screen_name: '@zendesk' + twitter_user_id: 67462376832 + updated_at: 2011-07-22T00:11:12Z + TriggerRevisionResponseTriggerRevisionSnapshot: type: object properties: - actions: - type: array - description: Each action describes what the macro will do - items: - $ref: '#/components/schemas/ActionObject' active: type: boolean - description: Useful for determining if the macro should be displayed description: type: string - description: The description of the macro nullable: true - restriction: - type: object - description: Who may access this macro. Will be null when everyone in the account can access it - properties: - id: - type: integer - description: The numeric ID of the group or user - ids: - type: array - description: The numeric IDs of the groups - items: - type: integer - type: - type: string - description: Allowed values are Group or User - additionalProperties: true + conditions: + $ref: '#/components/schemas/TriggerConditionsObject' title: type: string - description: The title of the macro - required: - - title - - actions - MacroObject: - type: object - allOf: - - $ref: '#/components/schemas/MacroCommonObject' - - type: object - properties: - app_installation: - type: string - description: The app installation that requires each macro, if present - nullable: true - categories: - type: string - description: The macro categories - nullable: true - permissions: - type: string - description: Permissions for each macro - nullable: true - usage_1h: - type: integer - description: The number of times each macro has been used in the past hour - usage_7d: - type: integer - description: The number of times each macro has been used in the past week - usage_24h: - type: integer - description: The number of times each macro has been used in the past day - usage_30d: - type: integer - description: The number of times each macro has been used in the past thirty days - example: - actions: [] - active: true - description: Sets the ticket status to `solved` - id: 25 - position: 42 - restriction: - id: 4 - type: User - title: Close and Save - MacroResponse: - type: object - properties: - macro: - $ref: '#/components/schemas/MacroObject' - MacroUpdateManyInput: - type: object - properties: - macros: + actions: type: array items: - type: object - properties: - active: - type: boolean - description: The active status of the macro (true or false) - id: - type: integer - description: The ID of the macro to update - position: - type: integer - description: The new position of the macro - required: - - id - MacrosResponse: - type: object - allOf: - - type: object - properties: - macros: - type: array - items: - $ref: '#/components/schemas/MacroObject' - - $ref: '#/components/schemas/OffsetPaginationObject' - OffsetPaginationObject: + $ref: '#/components/schemas/TriggerActionObject' + GroupSLAPolicyFilterConditionObject: type: object properties: - count: - type: integer - description: the total record count - next_page: + field: type: string - format: url - description: the URL of the next page - nullable: true - previous_page: + description: The name of a ticket field + value: + type: array + description: The value of a ticket field + items: + $ref: '#/components/schemas/GroupSLAPolicyFilterConditionObjectValue' + operator: type: string - format: url - description: the URL of the previous page - nullable: true - OrganizationFieldObject: + description: A comparison operator + SharingAgreementResponse: type: object - allOf: - - $ref: '#/components/schemas/CustomFieldObject' - example: - active: true - created_at: "2012-10-16T16:04:06Z" - description: Description of Custom Field - id: 7 - key: custom_field_1 - position: 9999 - raw_description: '{{dc.my_description}}' - raw_title: Custom Field 1 - regexp_for_validation: null - title: Custom Field 1 - type: text - updated_at: "2012-10-16T16:04:06Z" - url: https://company.zendesk.com/api/v2/organization_fields/7.json - OrganizationFieldResponse: + properties: + sharing_agreement: + allOf: + - $ref: '#/components/schemas/SharingAgreementObject' + x-ballerina-name: sharingAgreement + QueueObjectDefinition: type: object properties: - organization_field: - $ref: '#/components/schemas/OrganizationFieldObject' - OrganizationFieldsResponse: + all: + type: array + items: + $ref: '#/components/schemas/QueueObjectDefinitionAll' + any: + type: array + items: + $ref: '#/components/schemas/QueueObjectDefinitionAll' + description: Conditions when queue could be applied + SuspendedTicketsAttachmentsResponseUpload: type: object properties: - count: - type: integer - description: Total count of records retrieved - readOnly: true - next_page: - type: string - description: URL of the next page - nullable: true - readOnly: true - organization_fields: + attachments: type: array items: - $ref: '#/components/schemas/OrganizationFieldObject' - previous_page: + $ref: '#/components/schemas/AttachmentObject' + token: type: string - description: URL of the previous page - nullable: true + description: Token for subsequent request readOnly: true - OrganizationMembershipObject: + QueueObject: type: object properties: - created_at: + updated_at: type: string + description: The time of the queue's last update format: date-time - description: When this record was created - readOnly: true - default: - type: boolean - description: Denotes whether this is the default organization membership for the user. If false, returns `null` - nullable: true - id: - type: integer - description: Automatically assigned when the membership is created readOnly: true - organization_id: - type: integer - description: The ID of the organization associated with this user, in this membership - readOnly: true - organization_name: + x-ballerina-name: updatedAt + primary_groups: + description: Primary group ids linked to the queue + allOf: + - $ref: '#/components/schemas/QueueObjectPrimaryGroups' + x-ballerina-name: primaryGroups + name: type: string - description: The name of the organization associated with this user, in this membership - readOnly: true - updated_at: + description: The name of the queue + created_at: type: string + description: The time the queue was created format: date-time - description: When this record last got updated readOnly: true - url: + x-ballerina-name: createdAt + description: type: string - description: The API url of this membership + description: The description of the queue + definition: + description: Conditions when queue could be applied + allOf: + - $ref: '#/components/schemas/QueueObjectDefinition' + id: + type: string + description: Automatically assigned when creating queue readOnly: true - user_id: + priority: type: integer - description: The ID of the user for whom this memberships belongs - readOnly: true - view_tickets: - type: boolean - description: Denotes whether the user can or cannot have access to all organization's tickets. + description: The queue-applied priority + url: + type: string + description: The API URL of the queue readOnly: true + order: + type: integer + description: The queue-applied order + secondary_groups: + description: Secondary group ids linked to the queue + allOf: + - $ref: '#/components/schemas/QueueObjectSecondaryGroups' + x-ballerina-name: secondaryGroups example: - created_at: "2009-05-13T00:07:08Z" - default: true - id: 4 - organization_id: 12 - organization_name: first organization - updated_at: "2011-07-22T00:11:12Z" - url: https://example.zendesk.com/api/v2/organization_memberships/4.json - user_id: 29 - view_tickets: true + created_at: 2023-11-27T09:03:59Z + definition: + all: + - field: priority + operator: is + value: urgent + any: [] + description: Queue description + id: 01HG80ATNNZK1N7XRFVKX48XD6 + name: New queue with valid definition + order: 1 + primary_groups: + count: 2 + groups: + - id: 6784729637757 + name: EWR + - id: 5399674286077 + name: test + priority: 1 + secondary_groups: + count: 0 + groups: [] + updated_at: 2023-11-27T09:03:59Z + url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json + CustomObjectRecordsResponseLinks: required: - - user_id - - organization_id - - default - OrganizationMembershipResponse: - type: object - properties: - organization_membership: - $ref: '#/components/schemas/OrganizationMembershipObject' - OrganizationMembershipsResponse: - type: object - properties: - organization_memberships: - type: array - items: - $ref: '#/components/schemas/OrganizationMembershipObject' - OrganizationMetadataObject: - type: object - properties: - tickets_count: - type: integer - description: The number of tickets for the organization - users_count: - type: integer - description: The number of users for the organization - OrganizationObject: + - next + - prev type: object properties: - created_at: - type: string - description: The time the organization was created - readOnly: true - details: - type: string - description: Any details obout the organization, such as the address - nullable: true - domain_names: - type: array - description: An array of domain names associated with this organization - items: - type: string - external_id: + next: type: string - description: A unique external id to associate organizations to an external record. The id is case-insensitive. For example, "company1" and "Company1" are considered the same - nullable: true - group_id: - type: integer - description: New tickets from users in this organization are automatically put in this group nullable: true - id: - type: integer - description: Automatically assigned when the organization is created - name: - type: string - description: A unique name for the organization - notes: + prev: type: string - description: Any notes you have about the organization - nullable: true - organization_fields: - type: object - description: Custom fields for this organization. See [Custom organization fields](/api-reference/ticketing/organizations/organizations/#custom-organization-fields) - additionalProperties: - oneOf: - - type: string - - type: number nullable: true - shared_comments: - type: boolean - description: End users in this organization are able to comment on each other's tickets - shared_tickets: - type: boolean - description: End users in this organization are able to see each other's tickets - tags: - type: array - description: The tags of the organization - items: - type: string - updated_at: - type: string - description: The time of the last update of the organization - readOnly: true - url: - type: string - description: The API url of this organization - example: - created_at: "2009-07-20T22:55:29Z" - details: This is a kind of organization - domain_names: - - example.com - - test.com - external_id: ABC123 - group_id: null - id: 35436 - name: One Organization - notes: "" - organization_fields: - org_decimal: 5.2 - org_dropdown: option_1 - shared_comments: true - shared_tickets: true - tags: - - enterprise - - other_tag - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/organizations/35436.json - OrganizationResponse: - type: object - properties: - organization: - $ref: '#/components/schemas/OrganizationObject' - OrganizationSubscriptionCreateRequest: + TriggerWithCategoryRequest: type: object properties: - organization_subscription: - $ref: '#/components/schemas/OrganizationSubscriptionInput' - OrganizationSubscriptionInput: + trigger: + allOf: + - $ref: '#/components/schemas/TriggerObject' + MacroApplyTicketResponseResultTicket: type: object properties: - organization_id: - type: integer - description: The ID of the organization - user_id: + group_id: type: integer - description: The ID of the user - OrganizationSubscriptionObject: - title: Organization Subscriptions - type: object - properties: - created_at: - type: string - format: date-time - description: The date the organization subscription was created + x-ballerina-name: groupId + comment: + $ref: '#/components/schemas/MacroApplyTicketResponseResultTicketComment' id: type: integer - description: The ID of the organization subscription - organization_id: - type: integer - description: The ID of the organization - user_id: + fields: + $ref: '#/components/schemas/MacroApplyTicketResponseResultTicketFields' + url: + type: string + assignee_id: type: integer - description: The ID of the user - example: - created_at: "2009-07-20T22:55:29Z" - id: 1234 - organization_id: 32 - user_id: 482 - OrganizationSubscriptionResponse: - type: object - properties: - organization_subscription: - $ref: '#/components/schemas/OrganizationSubscriptionObject' - OrganizationSubscriptionsResponse: - type: object - allOf: - - $ref: '#/components/schemas/OffsetPaginationObject' - - type: object - properties: - organization_subscriptions: - type: array - description: An array of organization subscriptions - items: - $ref: '#/components/schemas/OrganizationSubscriptionObject' - OrganizationsRelatedResponse: - type: object - properties: - organization_related: - $ref: '#/components/schemas/OrganizationMetadataObject' - OrganizationsResponse: + x-ballerina-name: assigneeId + GroupsResponse: type: object properties: - count: - type: integer - next_page: - type: string - nullable: true - organizations: + groups: type: array items: - $ref: '#/components/schemas/OrganizationObject' - previous_page: - type: string - nullable: true - Pagination: - type: object - properties: - links: - type: object - properties: - next: - type: string - prev: - type: string - meta: - type: object - properties: - after_cursor: - type: string - before_cursor: - type: string - has_more: - type: boolean - PushNotificationDevicesInput: - type: array - items: - type: string - description: Mobile device token - PushNotificationDevicesRequest: - type: object - properties: - push_notification_devices: - $ref: '#/components/schemas/PushNotificationDevicesInput' - QueueObject: + $ref: '#/components/schemas/GroupObject' + AuditLogObject: type: object properties: - created_at: + change_description: type: string - format: date-time - description: The time the queue was created + description: The description of the change that occurred readOnly: true - definition: - type: object - description: Conditions when queue could be applied - properties: - all: - type: array - items: - type: object - properties: - field: - type: string - operator: - type: string - value: - type: string - any: - type: array - items: - type: object - properties: - field: - type: string - operator: - type: string - value: - type: string - description: + x-ballerina-name: changeDescription + source_label: type: string - description: The description of the queue - id: + description: The name of the item being audited + readOnly: true + x-ballerina-name: sourceLabel + actor_name: type: string - description: Automatically assigned when creating queue + description: Name of the user or system that initiated the change readOnly: true - name: + x-ballerina-name: actorName + action: type: string - description: The name of the queue - order: - type: integer - description: The queue-applied order - primary_groups: - type: object - description: Primary group ids linked to the queue - properties: - count: - type: integer - groups: - type: array - items: - type: object - properties: - id: - type: integer - name: - type: string - priority: - type: integer - description: The queue-applied priority - secondary_groups: - type: object - description: Secondary group ids linked to the queue - properties: - count: - type: integer - groups: - type: array - items: - type: object - properties: - id: - type: integer - name: - type: string - updated_at: + description: | + Type of change made. Possible values are "create", "destroy", "exported", "login", and "update" + readOnly: true + created_at: type: string + description: The time the audit got created format: date-time - description: The time of the queue's last update readOnly: true + x-ballerina-name: createdAt + source_type: + type: string + description: | + Item type being audited. Typically describes the system where the change + was initiated. Possible values vary based on your account's Zendesk + products and activity. Common values include "apitoken", "rule", "ticket", + "user", and "zendesk/app_market/app". The "rule" value is used for + [automations](https://support.zendesk.com/hc/en-us/articles/4408832701850), + [macros](https://support.zendesk.com/hc/en-us/articles/4408844187034), + [triggers](https://support.zendesk.com/hc/en-us/articles/4408822236058), + [views](https://support.zendesk.com/hc/en-us/articles/4408888828570), + and other automated business rules + readOnly: true + x-ballerina-name: sourceType + actor_id: + type: integer + description: id of the user or system that initiated the change + readOnly: true + x-ballerina-name: actorId + id: + type: integer + description: The id automatically assigned upon creation + readOnly: true + ip_address: + type: string + description: The IP address of the user doing the audit + readOnly: true + x-ballerina-name: ipAddress + source_id: + type: integer + description: The id of the item being audited + readOnly: true + x-ballerina-name: sourceId + action_label: + type: string + description: Localized string of action field + readOnly: true + x-ballerina-name: actionLabel url: type: string - description: The API URL of the queue + description: The URL to access the audit log readOnly: true example: - created_at: "2023-11-27T09:03:59Z" - definition: - all: - - field: priority - operator: is - value: urgent - any: [] - description: Queue description - id: 01HG80ATNNZK1N7XRFVKX48XD6 - name: New queue with valid definition - order: 1 - primary_groups: - count: 2 - groups: - - id: 6784729637757 - name: EWR - - id: 5399674286077 - name: test - priority: 1 - secondary_groups: - count: 0 - groups: [] - updated_at: "2023-11-27T09:03:59Z" - url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json - QueueResponse: + action: update + action_label: Updated + actor_id: 1234 + actor_name: Sameer Patel + change_description: Role changed from Administrator to End User + created_at: 2012-03-05T11:32:44Z + id: 498483 + ip_address: 209.119.38.228 + source_id: 3456 + source_label: John Doe + source_type: user + url: https://company.zendesk.com/api/v2/audit_logs/498483.json + ActivityResponse: type: object properties: - queue: - $ref: '#/components/schemas/QueueObject' - QueuesResponse: + activity: + $ref: '#/components/schemas/ActivityObject' + example: + activity: + actor: + active: true + alias: "" + created_at: 2020-11-17T00:32:12Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: cgoddard+ted@zendesk.com + external_id: null + iana_time_zone: America/Juneau + id: 158488612 + last_login_at: 2020-11-17T00:33:44Z + locale: en-gb + locale_id: 5 + moderator: true + name: Tedd + notes: "" + only_private_comments: false + organization_id: null + phone: null + photo: null + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: "" + suspended: false + tags: [] + ticket_restriction: null + time_zone: Alaska + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:34:38Z + url: https://example.zendesk.com/api/v2/users/158488612.json + user_fields: + its_remember_september: null + skittles: null + user_field_1: null + verified: true + actor_id: 158488612 + created_at: 2020-11-17T00:34:40Z + id: 29183462 + object: + ticket: + id: 1521 + subject: test + target: + ticket: + id: 1521 + subject: test + title: "Tedd assigned ticket #1521 to you." + updated_at: 2020-11-17T00:34:40Z + url: https://example.zendesk.com/api/v2/activities/29183462.json + user: + active: true + alias: test + created_at: 2017-08-14T20:13:53Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: user@zendesk.com + external_id: oev7jj + iana_time_zone: Pacific/Pago_Pago + id: 3343 + last_login_at: 2020-11-16T22:57:45Z + locale: en-gb + locale_id: 5 + moderator: true + name: Samwise Gamgee + notes: test + only_private_comments: false + organization_id: 1873 + phone: null + photo: + content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + deleted: false + file_name: 1f84950b8d7949b3.gif + height: 80 + id: 8730791 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + size: 4566 + thumbnails: + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 + url: https://example.zendesk.com/api/v2/attachments/8730791.json + width: 80 + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: test + suspended: false + tags: + - "101" + ticket_restriction: null + time_zone: American Samoa + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:33:55Z + url: https://example.zendesk.com/api/v2/users/3343.json + user_fields: + its_remember_september: null + skittles: 2018-09-14T00:00:00+00:00 + user_field_1: "101" + verified: true + user_id: 3343 + verb: tickets.assignment + CustomObjectRecordsUpsertRequest: type: object properties: - queues: - type: array - items: - $ref: '#/components/schemas/QueueObject' - RecoverSuspendedTicketResponse: + custom_object_record: + allOf: + - $ref: '#/components/schemas/CustomObjectRecord' + x-ballerina-name: customObjectRecord + CustomStatusUpdateRequest: type: object properties: - ticket: - type: array - items: - $ref: '#/components/schemas/SuspendedTicketObject' - RecoverSuspendedTicketUnprocessableContentResponse: + custom_status: + allOf: + - $ref: '#/components/schemas/CustomStatusUpdateInput' + x-ballerina-name: customStatus + SLAPolicyFilterDefinitionResponseDefinitionsValuesList: type: object properties: - ticket: - type: array - items: - $ref: '#/components/schemas/SuspendedTicketObject' - RecoverSuspendedTicketsResponse: + title: + type: string + value: + type: string + nullable: true + TicketsResponse: type: object properties: tickets: type: array items: - $ref: '#/components/schemas/SuspendedTicketObject' - RelationshipFilterDefinition: - type: object - properties: - conditions_all: - type: array - items: - $ref: '#/components/schemas/TriggerConditionDefinitionObjectAll' - conditions_any: - type: array - items: - $ref: '#/components/schemas/TriggerConditionDefinitionObjectAny' - RelationshipFilterDefinitionResponse: - type: object - properties: - definitions: - $ref: '#/components/schemas/RelationshipFilterDefinition' - RenewSessionResponse: - type: object - properties: - authenticity_token: - type: string - description: A token of authenticity for the request - RequestObject: + $ref: '#/components/schemas/TicketObject' + ViewObject: type: object properties: - assignee_id: - type: integer - description: The id of the assignee if the field is visible to end users - readOnly: true - can_be_solved_by_me: + execution: + type: object + additionalProperties: true + description: "Describes how the view should be executed. See [Execution](#execution)" + default: type: boolean - description: If true, an end user can mark the request as solved. See [Update Request](/api-reference/ticketing/tickets/ticket-requests/#update-request) - readOnly: true - collaborator_ids: - type: array - description: The ids of users currently CC'ed on the ticket - items: - type: integer + description: "If true, the view is a default view" readOnly: true - created_at: + updated_at: type: string + description: The time the view was last updated format: date-time - description: When this record was created readOnly: true - custom_fields: - type: array - description: Custom fields for the request. See [Setting custom field values](/api-reference/ticketing/tickets/tickets/#setting-custom-field-values) in the Tickets doc - items: - type: object - properties: - id: - type: integer - value: - type: string - custom_status_id: - type: integer - description: The custom ticket status id of the ticket - description: - type: string - description: Read-only first comment on the request. When [creating a request](#create-request), use `comment` to set the description - readOnly: true - due_at: + x-ballerina-name: updatedAt + restriction: + type: object + additionalProperties: true + description: Who may access this account. Is null when everyone in the account + can access it + active: + type: boolean + description: Whether the view is active + created_at: type: string + description: The time the view was created format: date-time - description: When the task is due (only applies if the request is of type "task") - email_cc_ids: - type: array - description: The ids of users who are currently email CCs on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center - items: - type: integer - readOnly: true - followup_source_id: - type: integer - description: The id of the original ticket if this request is a follow-up ticket. See [Create Request](#create-request) - readOnly: true - group_id: - type: integer - description: The id of the assigned group if the field is visible to end users - readOnly: true - id: - type: integer - description: Automatically assigned when creating requests - readOnly: true - is_public: - type: boolean - description: Is true if any comments are public, false otherwise - readOnly: true - organization_id: - type: integer - description: The organization of the requester readOnly: true - priority: - type: string - description: The priority of the request, "low", "normal", "high", "urgent" - recipient: + x-ballerina-name: createdAt + description: type: string - description: The original recipient e-mail address of the request - requester_id: + description: The description of the view + id: type: integer - description: The id of the requester + description: Automatically assigned when created readOnly: true - solved: - type: boolean - description: Whether or not request is solved (an end user can set this if "can_be_solved_by_me", above, is true for that user) - status: - type: string - description: The state of the request, "new", "open", "pending", "hold", "solved", "closed" - subject: - type: string - description: The value of the subject field for this request if the subject field is visible to end users; a truncated version of the description otherwise - ticket_form_id: + position: type: integer - description: The numeric id of the ticket form associated with this request if the form is visible to end users - only applicable for enterprise accounts - type: - type: string - description: The type of the request, "question", "incident", "problem", "task" - updated_at: - type: string - format: date-time - description: When this record last got updated - readOnly: true - url: + description: The position of the view + conditions: + type: object + additionalProperties: true + description: "Describes how the view is constructed. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference)" + title: type: string - description: The API url of this request - readOnly: true - via: - $ref: '#/components/schemas/TicketAuditViaObject' + description: The title of the view example: - assignee_id: 72983 - can_be_solved_by_me: false - collaborator_ids: [] - created_at: "2009-07-20T22:55:29Z" - description: The fire is very colorful. - due_at: "2011-05-24T12:00:00Z" - group_id: 8665 - id: 35436 - organization_id: 509974 - priority: normal - requester_id: 1462 - status: open - subject: Help, my printer is on fire! - ticket_form_id: 2 - type: problem - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/requests/35436.json - via: - channel: web - required: - - subject - RequestResponse: - type: object - properties: - request: - $ref: '#/components/schemas/RequestObject' - RequestsResponse: + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: [] + default: false + description: View for recent tickets + execution: + columns: + - id: status + title: Status + - id: updated + title: Updated + - id: 5 + title: Account + type: text + url: https://example.zendesk.com/api/v2/ticket_fields/5.json + group: + id: status + order: desc + title: Status + sort: + id: updated + order: desc + title: Updated + id: 25 + position: 8 + restriction: + id: 4 + type: User + title: Tickets updated <12 Hours + SuspendedTicketResponse: type: object properties: - requests: + suspended_ticket: type: array items: - $ref: '#/components/schemas/RequestObject' - ResourceCollectionObject: + $ref: '#/components/schemas/SuspendedTicketObject' + x-ballerina-name: suspendedTicket + ConditionsObject: type: object properties: - created_at: - type: string - format: date-time - description: When the resource collection was created - readOnly: true - id: - type: integer - description: id for the resource collection. Automatically assigned upon creation - readOnly: true - resources: + all: type: array - description: Array of resource metadata objects. See [Resource objects](#resource-objects) + description: Logical AND. Tickets must fulfill all of the conditions to + be considered matching items: - type: object - properties: - deleted: - type: boolean - identifier: - type: string - resource_id: - type: integer - type: - type: string - readOnly: true - updated_at: - type: string - format: date-time - description: Last time the resource collection was updated - readOnly: true - example: - created_at: "2011-07-20T22:55:29Z" - id: 35436 - resources: - - deleted: false - identifier: email_on_ticket_solved - resource_id: 10824486485524 - type: triggers - - deleted: false - identifier: support_description - resource_id: 10824486482580 - type: ticket_fields - updated_at: "2011-07-20T22:55:29Z" - ResourceCollectionResponse: + $ref: '#/components/schemas/ConditionObject' + any: + type: array + description: Logical OR. Tickets may satisfy any of the conditions to be + considered matching + items: + $ref: '#/components/schemas/ConditionObject' + description: "An object that describes the conditions under which the automation\ + \ will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference)" + OrganizationsRelatedResponse: type: object properties: - resource_collection: - $ref: '#/components/schemas/ResourceCollectionObject' - ResourceCollectionsResponse: + organization_related: + allOf: + - $ref: '#/components/schemas/OrganizationMetadataObject' + x-ballerina-name: organizationRelated + SearchExportResponseLinks: type: object properties: - count: - type: integer - readOnly: true - next_page: + next: type: string + description: The url to the next entry via the cursor nullable: true readOnly: true - previous_page: + prev: type: string + description: The url to the previous entry via the cursor nullable: true readOnly: true - resource_collections: - type: array - items: - $ref: '#/components/schemas/ResourceCollectionObject' - ReverseLookupResponse: + description: The links to the previous and next entries via the cursor ids in + the metadata + AccountSettingsSideConversationsObject: type: object - anyOf: - - $ref: '#/components/schemas/UsersResponse' - SLAPoliciesResponse: + properties: + tickets_channel: + type: boolean + x-ballerina-name: ticketsChannel + slack_channel: + type: boolean + x-ballerina-name: slackChannel + email_channel: + type: boolean + x-ballerina-name: emailChannel + show_in_context_panel: + type: boolean + x-ballerina-name: showInContextPanel + msteams_channel: + type: boolean + x-ballerina-name: msteamsChannel + description: Side conversations settings + GroupSLAPoliciesResponse: type: object properties: - count: - type: integer - readOnly: true next_page: type: string nullable: true readOnly: true + x-ballerina-name: nextPage + count: + type: integer + readOnly: true + group_sla_policies: + type: array + items: + $ref: '#/components/schemas/GroupSLAPolicyObject' + x-ballerina-name: groupSlaPolicies previous_page: type: string nullable: true readOnly: true - sla_policies: - type: array - items: - $ref: '#/components/schemas/SLAPolicyObject' - SLAPolicyFilterConditionObject: + x-ballerina-name: previousPage + ProblemsAutocompleteBody: type: object properties: - field: + text: type: string - description: The name of a ticket field - operator: + description: The text to search for + AccountSettingsApiObject: + type: object + properties: + api_token_access: type: string - description: A comparison operator - value: - description: The value of a ticket field - oneOf: - - type: string - - type: array - items: - oneOf: - - type: string - - type: integer - SLAPolicyFilterDefinitionResponse: + x-ballerina-name: apiTokenAccess + accepted_api_agreement: + type: boolean + x-ballerina-name: acceptedApiAgreement + api_password_access: + type: string + x-ballerina-name: apiPasswordAccess + description: "API configuration options. See [API](#api)" + OrganizationMembershipResponse: type: object properties: - definitions: - type: object - properties: - all: - type: array - items: - type: object - properties: - group: - type: string - operators: - type: array - items: - type: object - properties: - title: - type: string - value: - type: string - target: - type: string - nullable: true - title: - type: string - value: - type: string - values: - type: object - properties: - list: - type: array - items: - type: object - properties: - title: - type: string - value: - type: string - nullable: true - type: - type: string - any: - type: array - items: - type: object - properties: - group: - type: string - operators: - type: array - items: - type: object - properties: - title: - type: string - value: - type: string - target: - type: string - nullable: true - title: - type: string - value: - type: string - values: - type: object - properties: - list: - type: array - items: - type: object - properties: - title: - type: string - value: - type: string - nullable: true - type: - type: string - SLAPolicyFilterObject: + organization_membership: + allOf: + - $ref: '#/components/schemas/OrganizationMembershipObject' + x-ballerina-name: organizationMembership + AccountSettingsUserObject: type: object - description: An object that describes the conditions that a ticket must match in order for an SLA policy to be applied to that ticket. See [Filter](#filter). properties: - all: - type: array - items: - $ref: '#/components/schemas/SLAPolicyFilterConditionObject' - any: - type: array - items: - $ref: '#/components/schemas/SLAPolicyFilterConditionObject' - SLAPolicyMetricObject: + tagging: + type: boolean + end_user_phone_number_validation: + type: boolean + x-ballerina-name: endUserPhoneNumberValidation + agent_created_welcome_emails: + type: boolean + x-ballerina-name: agentCreatedWelcomeEmails + language_selection: + type: boolean + x-ballerina-name: languageSelection + multiple_organizations: + type: boolean + x-ballerina-name: multipleOrganizations + time_zone_selection: + type: boolean + x-ballerina-name: timeZoneSelection + have_gravatars_enabled: + type: boolean + x-ballerina-name: haveGravatarsEnabled + description: "User settings. See [Users](#users)" + GroupsCountObject: type: object properties: - business_hours: - type: boolean - description: Whether the metric targets are being measured in business hours or calendar hours - metric: - type: string - description: The definition of the time that is being measured - priority: - type: string - description: Priority that a ticket must match - target: - type: integer - description: The time within which the end-state for a metric should be met - SLAPolicyObject: + count: + $ref: '#/components/schemas/GroupsCountObjectCount' + ResourceCollectionObjectResources: type: object properties: - created_at: - type: string - format: date-time - description: The time the SLA policy was created - readOnly: true - description: + identifier: type: string - description: The description of the SLA policy - filter: - $ref: '#/components/schemas/SLAPolicyFilterObject' - id: - type: integer - description: Automatically assigned when created - readOnly: true - policy_metrics: - type: array - description: Array of [Policy Metric](#policy-metric) objects - items: - $ref: '#/components/schemas/SLAPolicyMetricObject' - position: + deleted: + type: boolean + resource_id: type: integer - description: Position of the SLA policy that determines the order they will be matched. If not specified, the SLA policy is added as the last position - title: + x-ballerina-name: resourceId + type: type: string - description: The title of the SLA policy - updated_at: + MacroAttachmentObject: + type: object + properties: + filename: type: string - format: date-time - description: The time of the last update of the SLA policy + description: The name of the image file readOnly: true - url: + content_type: type: string - description: URL of the SLA Policy reacord + description: "The content type of the image. Example value: \"image/png\"" readOnly: true - example: - created_at: "2015-03-17T22:50:26Z" - description: 'Organizations: Silver Plan' - filter: - all: - - field: type - operator: is - value: incident - - field: via_id - operator: is - value: "4" - - field: custom_status_id - operator: includes - value: - - "1" - - "2" - any: [] - id: 25 - policy_metrics: - - business_hours: false - metric: first_reply_time - priority: low - target: 60 - position: 3 - title: Silver Plan - updated_at: "2015-03-17T22:50:26Z" - url: https://company.zendesk.com/api/v2/slas/policies/25.json - required: - - title - - filter - SLAPolicyResponse: - type: object - properties: - sla_policy: - $ref: '#/components/schemas/SLAPolicyObject' - SatisfactionRatingObject: - type: object - properties: - assignee_id: + x-ballerina-name: contentType + size: type: integer - description: The id of agent assigned to at the time of rating + description: The size of the image file in bytes readOnly: true - comment: - type: string - description: The comment received with this rating, if available created_at: type: string + description: The time when this attachment was created format: date-time - description: The time the satisfaction rating got created - readOnly: true - group_id: - type: integer - description: The id of group assigned to at the time of rating - readOnly: true - id: - type: integer - description: Automatically assigned upon creation - readOnly: true - reason: + x-ballerina-name: createdAt + content_url: type: string - description: The reason for a bad rating given by the requester in a follow-up question. Satisfaction reasons must be [enabled](https://support.zendesk.com/hc/en-us/articles/223152967) - reason_code: - type: integer - description: The default reasons the user can select from a list menu for giving a negative rating. See [Reason codes](/api-reference/ticketing/ticket-management/satisfaction_reasons/#reason-codes) in the Satisfaction Reasons API. Can only be set on ratings with a `score` of "bad". Responses don't include this property - reason_id: - type: integer - description: id for the reason the user gave a negative rating. Can only be set on ratings with a `score` of "bad". To get a descriptive value for the id, use the [Show Reason for Satisfaction Rating](/api-reference/ticketing/ticket-management/satisfaction_reasons/#show-reason-for-satisfaction-rating) endpoint - requester_id: - type: integer - description: The id of ticket requester submitting the rating + description: A full URL where the attachment image file can be downloaded readOnly: true - score: - type: string - description: The rating "offered", "unoffered", "good" or "bad" - ticket_id: + x-ballerina-name: contentUrl + id: type: integer - description: The id of ticket being rated - readOnly: true - updated_at: - type: string - format: date-time - description: The time the satisfaction rating got updated - readOnly: true - url: - type: string - description: The API url of this rating + description: Automatically assigned when created readOnly: true - example: - assignee_id: 135 - created_at: "2011-07-20T22:55:29Z" - group_id: 44 - id: 35436 - requester_id: 7881 - score: good - ticket_id: 208 - updated_at: "2011-07-20T22:55:29Z" - url: https://company.zendesk.com/api/v2/satisfaction_ratings/62.json - required: - - assignee_id - - group_id - - requester_id - - ticket_id - - score - SatisfactionRatingResponse: + CustomObjectsResponse: type: object properties: - satisfaction_rating: + custom_objects: type: array items: - $ref: '#/components/schemas/SatisfactionRatingObject' - SatisfactionRatingsCountResponse: + $ref: '#/components/schemas/CustomObject' + x-ballerina-name: customObjects + UsersResponse: type: object properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - SatisfactionRatingsResponse: + users: + type: array + items: + $ref: '#/components/schemas/UserObject' + OrganizationSubscriptionsResponseAllOf2: type: object properties: - satisfaction_ratings: + organization_subscriptions: type: array + description: An array of organization subscriptions items: - $ref: '#/components/schemas/SatisfactionRatingObject' - SatisfactionReasonObject: + $ref: '#/components/schemas/OrganizationSubscriptionObject' + x-ballerina-name: organizationSubscriptions + CustomObjectRecordsResponseMeta: + required: + - after_cursor + - before_cursor + - has_more type: object properties: - created_at: + after_cursor: type: string - format: date-time - description: The time the reason was created - readOnly: true - deleted_at: + nullable: true + x-ballerina-name: afterCursor + before_cursor: type: string - format: date-time - description: The time the reason was deleted - readOnly: true - id: - type: integer - description: Automatically assigned upon creation - readOnly: true - raw_value: + nullable: true + x-ballerina-name: beforeCursor + has_more: + type: boolean + x-ballerina-name: hasMore + InlineResponse201: + type: object + properties: + workspace: + $ref: '#/components/schemas/WorkspaceObject' + InlineResponse200: + type: object + properties: + success: + type: boolean + GroupSLAPolicyFilterDefinitionResponse: + type: object + properties: + definitions: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitions' + ViaObjectSourceFrom: + type: object + properties: + address: type: string - description: The dynamic content placeholder, if present, or the current "value", if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - reason_code: + nullable: true + name: + type: string + nullable: true + id: type: integer - description: An account-level code for referencing the reason. Custom reasons are assigned an auto-incrementing integer (non-system reason codes begin at 1000). See [Reason codes](#reason-codes) - readOnly: true - updated_at: + nullable: true + title: type: string - format: date-time - description: The time the reason was updated - readOnly: true - url: + nullable: true + PushNotificationDevicesRequest: + type: object + properties: + push_notification_devices: + allOf: + - $ref: '#/components/schemas/PushNotificationDevicesInput' + x-ballerina-name: pushNotificationDevices + GroupSLAPolicyFilterDefinitionResponseDefinitionsAll: + type: object + properties: + operators: + type: array + items: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators' + values: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitionsValues' + title: type: string - description: API URL for the resource - readOnly: true value: type: string - description: Translated value of the reason in the account locale - example: - created_at: "2011-07-20T22:55:29Z" - deleted_at: "2012-03-12T12:45:32Z" - id: 35436 - raw_value: '{{dc.reason_code_1003}}' - reason_code: 1003 - updated_at: "2011-07-20T22:55:29Z" - url: https://example.zendesk.com/api/v2/satisfaction_reasons/35436.json - value: Agent did not respond quickly - required: - - value - SatisfactionReasonResponse: + group: + type: string + CustomStatusCreateRequest: type: object properties: - reason: - type: array - items: - $ref: '#/components/schemas/SatisfactionReasonObject' - SatisfactionReasonsResponse: + custom_status: + allOf: + - $ref: '#/components/schemas/CustomStatusCreateInput' + x-ballerina-name: customStatus + SLAPolicyFilterObject: type: object properties: - reasons: + all: type: array items: - $ref: '#/components/schemas/SatisfactionReasonObject' - SearchCountResponse: + $ref: '#/components/schemas/SLAPolicyFilterConditionObject' + any: + type: array + items: + $ref: '#/components/schemas/SLAPolicyFilterConditionObject' + description: "An object that describes the conditions that a ticket must match\ + \ in order for an SLA policy to be applied to that ticket. See [Filter](#filter)" + AssigneeFieldAssignableSearchAgentObject: type: object properties: - count: + group_id: type: integer - SearchExportResponse: + description: Agent's Group ID + x-ballerina-name: groupId + name: + type: string + description: Name of the agent + id: + type: integer + description: Agent ID + photo_url: + type: string + description: URL of Avatar + nullable: true + x-ballerina-name: photoUrl + group: + type: string + description: Name of the agent's group + example: + group: Engineering + group_id: 9182736455 + id: 6473829100 + name: Joe Smith + photo_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png + TargetTwitter: type: object properties: - facets: + secret: type: string - description: The facets corresponding to the search query - nullable: true - readOnly: true - links: - type: object - description: The links to the previous and next entries via the cursor ids in the metadata. - properties: - next: - type: string - description: The url to the next entry via the cursor. - nullable: true - readOnly: true - prev: - type: string - description: The url to the previous entry via the cursor. - nullable: true - readOnly: true - meta: - type: object - description: Metadata for the export query response. - properties: - after_cursor: - type: string - description: The cursor id for the next object. - nullable: true - readOnly: true - before_cursor: - type: string - description: The cursor id for the previous object. - nullable: true - readOnly: true - has_more: - type: boolean - description: Whether there are more items yet to be returned by the cursor. - readOnly: true - results: + description: only writable + token: + type: string + DynamicContentsResponse: + type: object + properties: + items: type: array - description: May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object items: - $ref: '#/components/schemas/SearchResultObject' - readOnly: true - example: - facets: null - links: - next: https://example.zendesk.com/api/v2/search/export.json?filter%5Btype%5D=ticket&page%5Bafter%5D=eyJmaWVsZCI6ImNyZWF0ZWRfYXQiLCJkZXNjIjp0cnVlLCJ0aWVCcmVha0ZpZWxkIjoiaWQiLCJ0aWVCcmVha0Rlc2MiOmZhbHNlLCJzb3J0VmFsdWVzIjpudWxsLCJleHBvcnRlZFRodXNGYXIiOjAsInNlc3Npb25TdGFydCI6MTYwNzAzOTI1Mzk4NSwiY3JlYXRlZEF0IjoxNjA3MDM5MjUzOTg1LCJzYWx0ZWRSZXF1ZXN0SGFzaCI6LTQ5ODM0ODc3LCJzYWx0ZWRDdXJzb3JIYXNoIjotMjQwMzQ4MjgwfQ%3D%3D&page%5Bsize%5D=100&query=hello%26page%5Bsize%5D%3D100%26filter%5Btype%5D%3Dticket - prev: null - meta: - after_cursor: eyJmaWVsZCI6ImNyZWF0ZWRfYXQiLCJkZXNjIjp0cnVlLCJ0aWVCcmVha0ZpZWxkIjoiaWQiLCJ0aWVCcmVha0Rlc2MiOmZhbHNlLCJzb3J0VmFsdWVzIjpudWxsLCJleHBvcnRlZFRodXNGYXIiOjAsInNlc3Npb25TdGFydCI6MTYwNzAzOTI1Mzk4NSwiY3JlYXRlZEF0IjoxNjA3MDM5MjUzOTg1LCJzYWx0ZWRSZXF1ZXN0SGFzaCI6LTQ5ODM0ODc3LCJzYWx0ZWRDdXJzb3JIYXNoIjotMjQwMzQ4MjgwfQ== - before_cursor: null - has_more: true - results: [] - SearchResponse: + $ref: '#/components/schemas/DynamicContentObject' + QueueObjectPrimaryGroups: type: object properties: count: type: integer - description: The number of resources returned by the query corresponding to this page of results in the paginated response + groups: + type: array + items: + $ref: '#/components/schemas/ListDeletedTicketsResponseActor' + description: Primary group ids linked to the queue + TriggerCategoryId: + type: string + TargetEmail: + required: + - email + - subject + type: object + properties: + subject: + type: string + email: + type: string + AuditObjectEvents: + type: object + properties: + id: + type: integer readOnly: true - facets: + body: type: string - description: The facets corresponding to the search query - nullable: true readOnly: true - next_page: + type: type: string - description: URL to the next page of results - nullable: true readOnly: true - previous_page: + value: + oneOf: + - type: string + - type: integer + field_name: type: string - description: URL to the previous page of results - nullable: true readOnly: true - results: + x-ballerina-name: fieldName + JobStatusesResponse: + required: + - job_statuses + type: object + properties: + job_statuses: type: array - description: May consist of tickets, users, groups, or organizations, as specified by the `result_type` property in each result object items: - $ref: '#/components/schemas/SearchResultObject' - readOnly: true - example: - count: 1 - facets: null - next_page: null - previous_page: null - results: - - created_at: "2018-04-06T03:17:05Z" - default: false - deleted: false - description: "" - id: 1835972 - name: Ragtail - result_type: group - updated_at: "2018-04-06T03:17:05Z" - url: https://example.zendesk.com/api/v2/groups/1835972.json - SearchResultObject: + $ref: '#/components/schemas/JobStatusObject' + x-ballerina-name: jobStatuses + Error: + required: + - code + - title type: object properties: - created_at: + code: type: string - description: When the resource was created - default: - type: boolean - description: Flag to indicate whether this is the default resource - deleted: - type: boolean - description: Flag to indicate whether or not resource has been deleted - description: + links: + type: object + detail: type: string - description: The description of the resource id: - type: integer - description: The ID of the resource - name: - type: string - description: The name of the resource - result_type: type: string - description: The type of the resource - updated_at: + source: + type: object + title: type: string - description: When the resource was last updated - url: + status: type: string - description: The url of the resource - SessionObject: + TicketMetricEventUpdateStatusObject: + title: Ticket Metric Event + type: object + allOf: + - $ref: '#/components/schemas/TicketMetricEventBaseObject' + - $ref: '#/components/schemas/TicketMetricEventUpdateStatusObjectAllOf2' + AuditLogResponse: type: object properties: - authenticated_at: - type: string - description: When the session was created - nullable: true - id: - type: integer - description: Automatically assigned when the session is created - last_seen_at: + audit_log: + allOf: + - $ref: '#/components/schemas/AuditLogObject' + x-ballerina-name: auditLog + ResourceCollectionResponse: + type: object + properties: + resource_collection: + allOf: + - $ref: '#/components/schemas/ResourceCollectionObject' + x-ballerina-name: resourceCollection + TargetObject: + type: object + additionalProperties: true + example: + active: false + created_at: 2012-02-20T22:55:29Z + id: 88335 + title: basecamp target + type: basecamp_target + url: https://company.zendesk.com/api/v2/targets/88335.json + allOf: + - $ref: '#/components/schemas/TargetCommonFields' + SystemFieldOptionObject: + type: object + properties: + name: type: string - description: The last approximate time this session was seen. This does not update on every request. - nullable: true - url: + description: Name of the system field option + readOnly: true + value: type: string - description: The API URL of this session - nullable: true - user_id: - type: integer - description: The id of the user - nullable: true - example: - authenticated_at: "2014-11-18T17:24:29Z" - id: 3432 - last_seen_at: "2014-11-18T17:30:52Z" - url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json - user_id: 12345 - required: - - id - SessionResponse: + description: Value of the system field option + readOnly: true + QueuesResponse: type: object properties: - session: + queues: type: array items: - $ref: '#/components/schemas/SessionObject' - SessionsResponse: + $ref: '#/components/schemas/QueueObject' + AuditLogsResponse: type: object properties: - sessions: + audit_logs: type: array items: - $ref: '#/components/schemas/SessionObject' - SharingAgreementObject: + $ref: '#/components/schemas/AuditLogObject' + x-ballerina-name: auditLogs + TagListTagObject: type: object properties: - created_at: - type: string - format: date-time - description: The time the record was created - readOnly: true - id: + count: type: integer - description: Automatically assigned upon creation + description: The number of tags readOnly: true name: type: string - description: Name of this sharing agreement - partner_name: - type: string - description: 'Can be one of the following: "jira", null' - nullable: true - remote_subdomain: - type: string - description: Subdomain of the remote account or null if not associated with an account - status: - type: string - description: 'Can be one of the following: "accepted", "declined", "pending", "inactive", "failed", "ssl_error", "configuration_error"' - type: - type: string - description: 'Can be one of the following: "inbound", "outbound"' - url: - type: string - description: URL of the sharing agreement record - readOnly: true - example: - created_at: "2012-02-20T22:55:29Z" - id: 88335 - name: Ticket Sharing - partner_name: jira - status: accepted - type: inbound - url: https://company.zendesk.com/api/v2/agreements/88335.json - SharingAgreementResponse: + description: A name for the tag + CurrentUserResponse: type: object properties: - sharing_agreement: - $ref: '#/components/schemas/SharingAgreementObject' - SharingAgreementsResponse: + user: + allOf: + - $ref: '#/components/schemas/UserObject' + ViewResponse: type: object properties: - sharing_agreements: + view: + $ref: '#/components/schemas/ViewObject' + columns: type: array items: - $ref: '#/components/schemas/SharingAgreementObject' - SkillBasedRoutingAttributeDefinitions: - type: object - properties: - definitions: - type: object - properties: - conditions_all: - type: array - items: - type: object - properties: - subject: - type: string - title: - type: string - conditions_any: - type: array - items: - type: object - properties: - subject: - type: string - title: - type: string - SkillBasedRoutingAttributeObject: + type: object + additionalProperties: true + groups: + type: array + items: + type: object + additionalProperties: true + rows: + type: array + items: + type: object + additionalProperties: true + CustomObjectFieldsResponse: type: object properties: - created_at: - type: string - format: date-time - description: When this record was created - readOnly: true - id: + custom_object_fields: + type: array + items: + $ref: '#/components/schemas/CustomObjectField' + x-ballerina-name: customObjectFields + UserIdentitiesResponse: + type: object + properties: + identities: + type: array + items: + $ref: '#/components/schemas/UserIdentityObject' + TriggerCategory: + type: object + properties: + updated_at: type: string - description: Automatically assigned when an attribute is created readOnly: true + x-ballerina-name: updatedAt name: type: string - description: The name of the attribute - updated_at: + created_at: type: string - format: date-time - description: When this record was last updated readOnly: true - url: + x-ballerina-name: createdAt + id: type: string - description: URL of the attribute readOnly: true - example: - created_at: "2017-12-01T19:29:31Z" - id: 15821cba-7326-11e8-b07e-950ba849aa27 - name: color - updated_at: "2017-12-01T19:29:31Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/15821cba-7326-11e8-b07e-950ba849aa27.json - required: - - name - SkillBasedRoutingAttributeResponse: + position: + type: integer + format: int64 + TriggerResponse: type: object properties: - attribute: - $ref: '#/components/schemas/SkillBasedRoutingAttributeObject' - SkillBasedRoutingAttributeValueObject: + trigger: + $ref: '#/components/schemas/TriggerObject' + DynamicContentObject: + title: Dynamic Content Items + required: + - default_locale_id + - name + - variants type: object properties: - attribute_id: - type: string - description: Id of the associated attribute - created_at: - type: string - format: date-time - description: When this record was created + outdated: + type: boolean + description: Indicates the item has outdated variants within it readOnly: true - id: + updated_at: type: string - description: Automatically assigned when an attribute value is created + description: When this record was last updated + format: date-time readOnly: true + x-ballerina-name: updatedAt + default_locale_id: + type: integer + description: "The default locale for the item. Must be one of the [locales\ + \ the account has active](/api-reference/ticketing/account-configuration/locales/#list-locales)" + x-ballerina-name: defaultLocaleId name: type: string - description: The name of the attribute value - updated_at: + description: The unique name of the item + created_at: type: string + description: When this record was created format: date-time - description: When this record was last updated - readOnly: true - url: - type: string - description: URL of the attribute value readOnly: true - SkillBasedRoutingAttributeValueResponse: - type: object - properties: - attribute_value: - $ref: '#/components/schemas/SkillBasedRoutingAttributeValueObject' - SkillBasedRoutingAttributeValuesResponse: - type: object - properties: - attribute_values: - type: array - items: - $ref: '#/components/schemas/SkillBasedRoutingAttributeValueObject' - SkillBasedRoutingAttributesResponse: - type: object - properties: - attributes: - type: array - items: - $ref: '#/components/schemas/SkillBasedRoutingAttributeObject' - count: + x-ballerina-name: createdAt + id: type: integer + description: Automatically assigned when creating items readOnly: true - next_page: + placeholder: type: string - nullable: true + description: "Automatically generated placeholder for the item, derived\ + \ from name" readOnly: true - previous_page: + variants: + type: array + description: "All variants within this item. See [Dynamic Content Item Variants](/api-reference/ticketing/ticket-management/dynamic_content_item_variants/)" + items: + $ref: '#/components/schemas/DynamicContentVariantObject' + url: type: string - nullable: true + description: The API url of this item readOnly: true - SkillBasedRoutingTicketFulfilledResponse: + RequestObject: + required: + - subject type: object properties: - fulfilled_ticket_ids: + email_cc_ids: type: array + description: "The ids of users who are currently email CCs on the ticket.\ + \ See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233)\ + \ in the Support Help Center" + readOnly: true items: type: integer - SupportAddressObject: - type: object - properties: - brand_id: - type: integer - description: The ID of the [brand](/api-reference/ticketing/account-configuration/brands/) - cname_status: + x-ballerina-name: emailCcIds + subject: type: string - description: 'Whether all of the required CNAME records are set. Possible values: "unknown", "verified", "failed"' - enum: - - unknown - - verified - - failed - readOnly: true + description: The value of the subject field for this request if the subject + field is visible to end users; a truncated version of the description + otherwise created_at: type: string + description: When this record was created format: date-time - description: When the address was created readOnly: true - default: - type: boolean - description: Whether the address is the account's default support address - dns_results: + x-ballerina-name: createdAt + custom_status_id: + type: integer + description: The custom ticket status id of the ticket + x-ballerina-name: customStatusId + description: type: string - description: 'Verification statuses for the domain and CNAME records. Possible types: "verified", "failed"' - enum: - - verified - - failed + description: "Read-only first comment on the request. When [creating a request](#create-request),\ + \ use `comment` to set the description" readOnly: true - domain_verification_code: + solved: + type: boolean + description: "Whether or not request is solved (an end user can set this\ + \ if \"can_be_solved_by_me\", above, is true for that user)" + type: type: string - description: 'Verification string to be added as a TXT record to the domain. Possible types: string or null.' - readOnly: true - domain_verification_status: + description: "The type of the request, \"question\", \"incident\", \"problem\"\ + , \"task\"" + via: + $ref: '#/components/schemas/TicketAuditViaObject' + updated_at: type: string - description: 'Whether the domain verification record is valid. Possible values: "unknown", "verified", "failed"' - enum: - - unknown - - verified - - failed + description: When this record last got updated + format: date-time readOnly: true - email: - type: string - description: The email address. You can't change the email address of an existing support address. - forwarding_status: + x-ballerina-name: updatedAt + due_at: type: string - description: 'Status of email forwarding. Possible values: "unknown", "waiting", "verified", or "failed"' - enum: - - unknown - - waiting - - verified - - failed - readOnly: true + description: When the task is due (only applies if the request is of type + "task") + format: date-time + x-ballerina-name: dueAt id: type: integer - description: Automatically assigned when created - readOnly: true - name: - type: string - description: The name for the address - spf_status: - type: string - description: 'Whether the SPF record is set up correctly. Possible values: "unknown", "verified", "failed"' - enum: - - unknown - - verified - - failed + description: Automatically assigned when creating requests readOnly: true - updated_at: - type: string - format: date-time - description: When the address was updated + assignee_id: + type: integer + description: The id of the assignee if the field is visible to end users readOnly: true - example: - brand_id: 123 - cname_status: verified - created_at: "2015-07-20T22:55:29Z" - default: true - domain_verification_status: verified - email: support@example.zendesk.com - forwarding_status: unknown - id: 35436 - name: all - spf_status: verified - updated_at: "2016-09-21T20:15:20Z" - required: - - email - SupportAddressResponse: - type: object - properties: - recipient_address: - $ref: '#/components/schemas/SupportAddressObject' - SupportAddressesResponse: - type: object - properties: - recipient_addresses: + x-ballerina-name: assigneeId + custom_fields: type: array + description: "Custom fields for the request. See [Setting custom field values](/api-reference/ticketing/tickets/tickets/#setting-custom-field-values)\ + \ in the Tickets doc" items: - $ref: '#/components/schemas/SupportAddressObject' - SuspendedTicketObject: - type: object - properties: - attachments: + $ref: '#/components/schemas/MacroApplyTicketResponseResultTicketFields' + x-ballerina-name: customFields + collaborator_ids: type: array - description: The attachments, if any associated to this suspended ticket. See [Attachments](/api-reference/ticketing/tickets/ticket-attachments/) - items: - $ref: '#/components/schemas/AttachmentObject' - nullable: true - readOnly: true - author: - type: object - description: The author id (if available), name and email - allOf: - - $ref: '#/components/schemas/AuthorObject' - readOnly: true - brand_id: - type: integer - description: The id of the brand this ticket is associated with. Only applicable for Enterprise accounts + description: The ids of users currently CC'ed on the ticket readOnly: true - cause: + items: + type: integer + x-ballerina-name: collaboratorIds + priority: type: string - description: Why the ticket was suspended + description: "The priority of the request, \"low\", \"normal\", \"high\"\ + , \"urgent\"" + url: + type: string + description: The API url of this request readOnly: true - cause_id: + ticket_form_id: type: integer - description: The ID of the cause - readOnly: true - content: - type: string - description: The content that was flagged + description: The numeric id of the ticket form associated with this request + if the form is visible to end users - only applicable for enterprise accounts + x-ballerina-name: ticketFormId + followup_source_id: + type: integer + description: "The id of the original ticket if this request is a follow-up\ + \ ticket. See [Create Request](#create-request)" readOnly: true - created_at: - type: string - format: date-time - description: The ticket ID this suspended email is associated with, if available + x-ballerina-name: followupSourceId + group_id: + type: integer + description: The id of the assigned group if the field is visible to end + users readOnly: true - error_messages: - type: array - description: The error messages if any associated to this suspended ticket - items: - type: object - nullable: true + x-ballerina-name: groupId + can_be_solved_by_me: + type: boolean + description: "If true, an end user can mark the request as solved. See [Update\ + \ Request](/api-reference/ticketing/tickets/ticket-requests/#update-request)" readOnly: true - id: + x-ballerina-name: canBeSolvedByMe + organization_id: type: integer - description: Automatically assigned + description: The organization of the requester readOnly: true - message_id: - type: string - description: The ID of the email, if available + x-ballerina-name: organizationId + is_public: + type: boolean + description: "Is true if any comments are public, false otherwise" readOnly: true + x-ballerina-name: isPublic recipient: type: string - description: The original recipient e-mail address of the ticket + description: The original recipient e-mail address of the request + requester_id: + type: integer + description: The id of the requester readOnly: true - subject: + x-ballerina-name: requesterId + status: + type: string + description: "The state of the request, \"new\", \"open\", \"pending\",\ + \ \"hold\", \"solved\", \"closed\"" + example: + assignee_id: 72983 + can_be_solved_by_me: false + collaborator_ids: [] + created_at: 2009-07-20T22:55:29Z + description: The fire is very colorful. + due_at: 2011-05-24T12:00:00Z + group_id: 8665 + id: 35436 + organization_id: 509974 + priority: normal + requester_id: 1462 + status: open + subject: "Help, my printer is on fire!" + ticket_form_id: 2 + type: problem + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/requests/35436.json + via: + channel: web + TicketAuditsResponse: + type: object + properties: + before_url: type: string - description: The value of the subject field for this ticket readOnly: true - ticket_id: - type: integer - description: The ticket ID this suspended email is associated with, if available + x-ballerina-name: beforeUrl + after_cursor: + type: string readOnly: true - updated_at: + x-ballerina-name: afterCursor + after_url: type: string - format: date-time - description: When the ticket was assigned readOnly: true - url: + x-ballerina-name: afterUrl + before_cursor: type: string - description: The API url of this ticket readOnly: true - via: - $ref: '#/components/schemas/ViaObject' - example: - attachments: [] - author: - email: styx@example.com - id: 1111 - name: Mr. Roboto - brand_id: 123 - cause: Detected as spam - cause_id: 0 - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - error_messages: null - id: 435 - message_id: Spambot@spam.co.evil - recipient: john@example.com - subject: Help, my printer is on fire! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: email - source: - from: - address: totallylegit@emailaddress.com - name: TotallyLegit - rel: null - to: - address: support@example.zendesk.com - name: Example Account - SuspendedTicketResponse: + x-ballerina-name: beforeCursor + audits: + type: array + items: + $ref: '#/components/schemas/TicketAuditObject' + OrganizationMembershipsResponse: type: object properties: - suspended_ticket: + organization_memberships: type: array items: - $ref: '#/components/schemas/SuspendedTicketObject' - SuspendedTicketsAttachmentsResponse: + $ref: '#/components/schemas/OrganizationMembershipObject' + x-ballerina-name: organizationMemberships + TriggerRevisionResponseTriggerRevision: type: object properties: - upload: - type: object - properties: - attachments: - type: array - items: - $ref: '#/components/schemas/AttachmentObject' - token: - type: string - description: Token for subsequent request - readOnly: true - SuspendedTicketsExportResponse: + created_at: + type: string + x-ballerina-name: createdAt + id: + type: integer + author_id: + type: integer + x-ballerina-name: authorId + snapshot: + $ref: '#/components/schemas/TriggerRevisionResponseTriggerRevisionSnapshot' + url: + type: string + SessionObject: + required: + - id type: object properties: - export: - type: object - properties: - status: - type: string - readOnly: true - view_id: - type: string - readOnly: true - SuspendedTicketsResponse: + user_id: + type: integer + description: The id of the user + nullable: true + x-ballerina-name: userId + authenticated_at: + type: string + description: When the session was created + nullable: true + x-ballerina-name: authenticatedAt + id: + type: integer + description: Automatically assigned when the session is created + last_seen_at: + type: string + description: The last approximate time this session was seen. This does + not update on every request + nullable: true + x-ballerina-name: lastSeenAt + url: + type: string + description: The API URL of this session + nullable: true + example: + authenticated_at: 2014-11-18T17:24:29Z + id: 3432 + last_seen_at: 2014-11-18T17:30:52Z + url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json + user_id: 12345 + RelationshipFilterDefinitionResponse: type: object properties: - suspended_tickets: - type: array - items: - $ref: '#/components/schemas/SuspendedTicketObject' - SystemFieldOptionObject: + definitions: + $ref: '#/components/schemas/RelationshipFilterDefinition' + SatisfactionReasonObject: + required: + - value type: object properties: - name: + reason_code: + type: integer + description: "An account-level code for referencing the reason. Custom reasons\ + \ are assigned an auto-incrementing integer (non-system reason codes begin\ + \ at 1000). See [Reason codes](#reason-codes)" + readOnly: true + x-ballerina-name: reasonCode + raw_value: type: string - description: Name of the system field option + description: "The dynamic content placeholder, if present, or the current\ + \ \"value\", if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawValue + updated_at: + type: string + description: The time the reason was updated + format: date-time + readOnly: true + x-ballerina-name: updatedAt + created_at: + type: string + description: The time the reason was created + format: date-time readOnly: true + x-ballerina-name: createdAt + id: + type: integer + description: Automatically assigned upon creation + readOnly: true + deleted_at: + type: string + description: The time the reason was deleted + format: date-time + readOnly: true + x-ballerina-name: deletedAt value: type: string - description: Value of the system field option + description: Translated value of the reason in the account locale + url: + type: string + description: API URL for the resource readOnly: true + example: + created_at: 2011-07-20T22:55:29Z + deleted_at: 2012-03-12T12:45:32Z + id: 35436 + raw_value: "{{dc.reason_code_1003}}" + reason_code: 1003 + updated_at: 2011-07-20T22:55:29Z + url: https://example.zendesk.com/api/v2/satisfaction_reasons/35436.json + value: Agent did not respond quickly TagCountObject: type: object properties: @@ -19821,3784 +19748,5709 @@ components: type: string description: The time that the count value was last refreshed readOnly: true + x-ballerina-name: refreshedAt value: type: integer description: The count of tags created in the last 24 hours readOnly: true - TagCountResponse: - type: object - properties: - count: - $ref: '#/components/schemas/TagCountObject' - TagListTagObject: - type: object - properties: - count: - type: integer - description: The number of tags - readOnly: true - name: - type: string - description: A name for the tag - TagUrlObject: + ActivitiesResponse: type: object properties: - url: + next_page: type: string - description: The url associated to the api request + nullable: true readOnly: true - TagsByObjectIdResponse: - type: object - properties: - tags: + x-ballerina-name: nextPage + actors: type: array - description: An array of strings + readOnly: true items: - type: string - required: - - tags - TagsResponse: - type: object - properties: + type: object + additionalProperties: true + activities: + type: array + readOnly: true + items: + $ref: '#/components/schemas/ActivityObject' count: type: integer - description: The number of pages - readOnly: true - next_page: - type: string - description: The url of the previous page - nullable: true readOnly: true previous_page: type: string - description: The url of the next page nullable: true readOnly: true - tags: + x-ballerina-name: previousPage + users: type: array + readOnly: true items: - $ref: '#/components/schemas/TagListTagObject' - TargetBasecamp: - type: object - properties: - message_id: - type: string - description: Can be filled if it is a "message" resource - password: - type: string - description: The 37Signals password for the Basecamp account (only writable) - project_id: - type: string - description: The ID of the project in Basecamp where updates should be pushed - resource: - type: string - description: '"todo" or "message"' - target_url: - type: string - description: The URL of your Basecamp account, including protocol and path - todo_list_id: - type: string - description: Can be filled if it is a "todo" resource - token: - type: string - description: Get the API token from My info > Show your tokens > Token for feed readers or the Basecamp API in your Basecamp account - username: - type: string - description: The 37Signals username of the account you use to log in to Basecamp - required: - - target_url - - token - - project_id - - resource - TargetCampfire: - type: object - properties: - preserve_format: - type: boolean - room: - type: string - ssl: - type: boolean - subdomain: - type: string - token: - type: string - required: - - subdomain - - room - - token - TargetClickatell: - type: object - properties: - api_id: - type: string - attribute: - type: string - description: Read-only - from: - type: string - method: - type: string - description: Read-only - password: - type: string - description: only writable - target_url: - type: string - description: Read-only - to: - type: string - us_small_business_account: - type: string - username: - type: string - required: - - username - - password - - api_id - - to - TargetCommonFields: + type: object + additionalProperties: true + example: + activities: + - actor: + active: true + alias: "" + created_at: 2020-11-17T00:32:12Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: cgoddard+ted@zendesk.com + external_id: null + iana_time_zone: America/Juneau + id: 158488612 + last_login_at: 2020-11-17T00:33:44Z + locale: en-gb + locale_id: 5 + moderator: true + name: Tedd + notes: "" + only_private_comments: false + organization_id: null + phone: null + photo: null + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: "" + suspended: false + tags: [] + ticket_restriction: null + time_zone: Alaska + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:34:38Z + url: https://example.zendesk.com/api/v2/users/158488612.json + user_fields: + its_remember_september: null + skittles: null + user_field_1: null + verified: true + actor_id: 158488612 + created_at: 2020-11-17T00:34:40Z + id: 29183462 + object: + ticket: + id: 1521 + subject: test + target: + ticket: + id: 1521 + subject: test + title: "Tedd assigned ticket #1521 to you." + updated_at: 2020-11-17T00:34:40Z + url: https://example.zendesk.com/api/v2/activities/29183462.json + user: + active: true + alias: test + created_at: 2017-08-14T20:13:53Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: user@zendesk.com + external_id: oev7jj + iana_time_zone: Pacific/Pago_Pago + id: 3343 + last_login_at: 2020-11-16T22:57:45Z + locale: en-gb + locale_id: 5 + moderator: true + name: Samwise Gamgee + notes: test + only_private_comments: false + organization_id: 1873 + phone: null + photo: + content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + deleted: false + file_name: 1f84950b8d7949b3.gif + height: 80 + id: 8730791 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + size: 4566 + thumbnails: + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 + url: https://example.zendesk.com/api/v2/attachments/8730791.json + width: 80 + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: test + suspended: false + tags: + - "101" + ticket_restriction: null + time_zone: American Samoa + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:33:55Z + url: https://example.zendesk.com/api/v2/users/3343.json + user_fields: + its_remember_september: null + skittles: 2018-09-14T00:00:00+00:00 + user_field_1: "101" + verified: true + user_id: 3343 + verb: tickets.assignment + actors: + - active: true + alias: "" + created_at: 2020-11-17T00:32:12Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: cgoddard+ted@zendesk.com + external_id: null + iana_time_zone: America/Juneau + id: 158488612 + last_login_at: 2020-11-17T00:33:44Z + locale: en-gb + locale_id: 5 + moderator: true + name: Tedd + notes: "" + only_private_comments: false + organization_id: null + phone: null + photo: null + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: "" + suspended: false + tags: [] + ticket_restriction: null + time_zone: Alaska + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:34:38Z + url: https://example.zendesk.com/api/v2/users/158488612.json + user_fields: + its_remember_september: null + skittles: null + user_field_1: null + verified: true + count: 1 + next_page: null + previous_page: null + users: + - active: true + alias: test + created_at: 2017-08-14T20:13:53Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: user@zendesk.com + external_id: oev7jj + iana_time_zone: Pacific/Pago_Pago + id: 3343 + last_login_at: 2020-11-16T22:57:45Z + locale: en-gb + locale_id: 5 + moderator: true + name: Samwise Gamgee + notes: test + only_private_comments: false + organization_id: 1873 + phone: null + photo: + content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + deleted: false + file_name: 1f84950b8d7949b3.gif + height: 80 + id: 8730791 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + size: 4566 + thumbnails: + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 + url: https://example.zendesk.com/api/v2/attachments/8730791.json + width: 80 + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: test + suspended: false + tags: + - "101" + ticket_restriction: null + time_zone: American Samoa + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:33:55Z + url: https://example.zendesk.com/api/v2/users/3343.json + user_fields: + its_remember_september: null + skittles: 2018-09-14T00:00:00+00:00 + user_field_1: "101" + verified: true + TicketMetricEventBreachObjectAllOf2: type: object properties: - active: + deleted: type: boolean - description: Whether or not the target is activated - created_at: - type: string - format: date-time - description: The time the target was created + description: "Available if `type` is `breach`. In general, you can ignore\ + \ any breach event when `deleted` is true. See [deleted](#deleted)" readOnly: true - id: + ListTicketIncidentsResponse: + type: object + additionalProperties: true + AccountSettingsLotusObject: + type: object + properties: + pod_id: type: integer - description: Automatically assigned when created - readOnly: true + x-ballerina-name: podId + prefer_lotus: + type: boolean + x-ballerina-name: preferLotus + reporting: + type: boolean + description: "Support UI settings. See [Lotus](#lotus)" + DefinitionsResponse: + type: object + properties: + definitions: + $ref: '#/components/schemas/DefinitionsResponseDefinitions' + TriggerChangeObject: + type: object + properties: + change: + type: string + description: "One of `-`, `+`, `=` representing the type of change" + content: + description: The value of the item it represents + oneOf: + - type: boolean + - type: string + - type: integer + - type: array + items: + oneOf: + - type: string + - type: integer + - type: boolean + example: + change: "+" + content: solved + TriggerConditionDefinitionObjectAny: + type: object + properties: + nullable: + type: boolean + operators: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsOperators' + repeatable: + type: boolean + subject: + type: string title: type: string - description: A name for the target type: type: string - description: A pre-defined target, such as "basecamp_target". See the additional attributes for the type that follow - required: - - title - - type - TargetEmail: + group: + type: string + MacroResponse: type: object properties: - email: - type: string - subject: - type: string - required: - - email - - subject - TargetFailureObject: + macro: + $ref: '#/components/schemas/MacroObject' + AttachmentThumbnails: type: object properties: - consecutive_failure_count: - type: integer - description: Number of times the target failed consecutively + thumbnails: + type: array + description: An array of attachment objects. Note that photo thumbnails + do not have thumbnails readOnly: true - created_at: + items: + $ref: '#/components/schemas/AttachmentBaseObject' + TicketSkipsResponse: + type: object + properties: + skips: + type: array + items: + $ref: '#/components/schemas/TicketSkipObject' + ResourceCollectionsResponse: + type: object + properties: + next_page: type: string - format: date-time - description: Time of the failure + nullable: true readOnly: true - id: + x-ballerina-name: nextPage + count: type: integer - description: The ID of the target failure - readOnly: true - raw_request: - type: string - description: The raw message of the target request readOnly: true - raw_response: + resource_collections: + type: array + items: + $ref: '#/components/schemas/ResourceCollectionObject' + x-ballerina-name: resourceCollections + previous_page: type: string - description: The raw response of the failure + nullable: true readOnly: true - status_code: + x-ballerina-name: previousPage + JobStatusResponse: + type: object + properties: + job_status: + allOf: + - $ref: '#/components/schemas/JobStatusObject' + x-ballerina-name: jobStatus + ViewsResponse: + type: object + properties: + next_page: + type: string + nullable: true + readOnly: true + x-ballerina-name: nextPage + count: type: integer - description: HTTP status code of the target failure readOnly: true - target_name: + previous_page: type: string - description: Name of the target failure + nullable: true readOnly: true - url: + x-ballerina-name: previousPage + views: + type: array + items: + $ref: '#/components/schemas/ViewObject' + SessionsResponse: + type: object + properties: + sessions: + type: array + items: + $ref: '#/components/schemas/SessionObject' + UserCreateInputIdentities: + required: + - type + - value + type: object + properties: + type: type: string - description: The API url of the failure record - readOnly: true - example: - consecutive_failure_count: 1 - created_at: "2017-09-05T10:38:52Z" - id: 6001326 - raw_request: "GET /api/v2/tickets.json HTTP/1.1\r\nUser-Agent: Zendesk Target\r\n ..." - raw_response: "HTTP/1.1 401 Unauthorized\r\nServer: nginx\r\n ..." - status_code: 401 - target_name: My URL Target - url: https://example.zendesk.com/api/v2/target_failures/6001326.json - TargetFailureResponse: + value: + type: string + DynamicContentVariantResponse: type: object properties: - target_failure: - $ref: '#/components/schemas/TargetFailureObject' - TargetFailuresResponse: + variant: + $ref: '#/components/schemas/DynamicContentVariantObject' + SatisfactionReasonsResponse: type: object properties: - target_failures: + reasons: type: array items: - $ref: '#/components/schemas/TargetFailureObject' - TargetFlowdock: + $ref: '#/components/schemas/SatisfactionReasonObject' + BookmarksResponseAllOf2: type: object properties: - api_token: - type: string - required: - - api_token - TargetGetSatisfaction: + bookmarks: + type: array + items: + $ref: '#/components/schemas/BookmarkObject' + ValueValueOneOf12: + type: integer + AccountSettingsChatObject: type: object properties: - account_name: - type: string - email: + available: + type: boolean + welcome_message: type: string - password: + x-ballerina-name: welcomeMessage + enabled: + type: boolean + maximum_request_count: + type: integer + x-ballerina-name: maximumRequestCount + integrated: + type: boolean + description: "Zendesk Chat settings. See [Chat](#chat)" + OrganizationSubscriptionsResponse: + type: object + allOf: + - $ref: '#/components/schemas/OffsetPaginationObject' + - $ref: '#/components/schemas/OrganizationSubscriptionsResponseAllOf2' + DefinitionsResponseDefinitionsOperators: + type: object + properties: + terminal: + type: boolean + title: type: string - description: only writable - target_url: + value: type: string - required: - - email - - password - - account_name - TargetHTTP: + LocaleObject: type: object properties: - content_type: + updated_at: type: string - description: '"application/json", "application/xml", or "application/x-www-form-urlencoded"' - method: + description: The ISO 8601 formatted date-time when the locale was last updated + format: date-time + readOnly: true + x-ballerina-name: updatedAt + name: type: string - description: '"get", "patch", "put", "post", or "delete"' - password: + description: The name of the language + readOnly: true + created_at: type: string - description: only writable - target_url: + description: The ISO 8601 formatted date-time the locale was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + id: + type: integer + description: The unique ID of the locale + readOnly: true + locale: type: string - username: + description: The name of the locale + readOnly: true + url: type: string - required: - - target_url - - method - - content_type - TargetJira: + description: The URL of the locale record + readOnly: true + example: + created_at: 2009-07-20T22:55:29Z + id: 1 + locale: en-US + name: English + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/locales/en-US.json + AttachmentUploadResponse: type: object properties: - password: - type: string - description: only writable - target_url: - type: string - username: - type: string + upload: + $ref: '#/components/schemas/AttachmentUploadResponseUpload' + CreateResourceResult: required: - - target_url - - username - - password - TargetObject: + - id + - index type: object - allOf: - - $ref: '#/components/schemas/TargetCommonFields' - # Todo - Enable - # - anyOf: - # - $ref: '#/components/schemas/TargetBasecamp' - # - $ref: '#/components/schemas/TargetCampfire' - # - $ref: '#/components/schemas/TargetClickatell' - # - $ref: '#/components/schemas/TargetEmail' - # - $ref: '#/components/schemas/TargetFlowdock' - # - $ref: '#/components/schemas/TargetGetSatisfaction' - # - $ref: '#/components/schemas/TargetJira' - # - $ref: '#/components/schemas/TargetPivotal' - # - $ref: '#/components/schemas/TargetTwitter' - # - $ref: '#/components/schemas/TargetURL' - # - $ref: '#/components/schemas/TargetHTTP' - # - $ref: '#/components/schemas/TargetYammer' - additionalProperties: true - example: - active: false - created_at: "2012-02-20T22:55:29Z" - id: 88335 - title: basecamp target - type: basecamp_target - url: https://company.zendesk.com/api/v2/targets/88335.json - TargetPivotal: + properties: + index: + type: integer + description: the index number of the resul + id: + type: integer + description: the id of the new resource + V2WorkspacesBody: type: object properties: - owner_by: - type: string - project_id: - type: string - requested_by: - type: string - story_labels: - type: string - story_title: - type: string - story_type: - type: string - token: - type: string - required: - - token - - project_id - - story_type - - story_title - TargetResponse: + workspace: + $ref: '#/components/schemas/WorkspaceInput' + TicketMetricEventGroupSLAObjectAllOf2: type: object properties: - target: - $ref: '#/components/schemas/TargetObject' - TargetTwitter: + group_sla: + type: object + description: "Available if `type` is \"apply_group_sla\". The Group SLA\ + \ policy and target being enforced on the ticket and metric in question,\ + \ if any. See [group_sla](#group_sla)" + readOnly: true + x-ballerina-name: groupSla + SatisfactionRatingResponse: type: object properties: - secret: - type: string - description: only writable - token: - type: string - TargetURL: + satisfaction_rating: + type: array + items: + $ref: '#/components/schemas/SatisfactionRatingObject' + x-ballerina-name: satisfactionRating + TagUrlObject: type: object properties: - attribute: - type: string - method: - type: string - description: '"get"' - password: - type: string - description: only writable - target_url: - type: string - username: + url: type: string - required: - - target_url - - attribute - TargetYammer: + description: The url associated to the api request + readOnly: true + CustomStatusUpdateInput: type: object properties: - group_id: + end_user_label: type: string - token: + description: "The dynamic content placeholder, if present, or the \"end_user_label\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: endUserLabel + end_user_description: type: string - TargetsResponse: + description: "The dynamic content placeholder, if present, or the \"end_user_description\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: endUserDescription + active: + type: boolean + description: True if the custom status is set as active; inactive if false + description: + type: string + description: "The dynamic content placeholder, if present, or the \"description\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + agent_label: + type: string + description: "The dynamic content placeholder, if present, or the \"agent_label\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: agentLabel + SessionResponse: type: object properties: - targets: + session: type: array items: - $ref: '#/components/schemas/TargetObject' - TicketAuditObject: + $ref: '#/components/schemas/SessionObject' + ActivityObject: + title: Ticket Activities type: object properties: - author_id: + actor: + type: object + description: "The full user record of the user responsible for the ticket\ + \ activity. See [Users](/api-reference/ticketing/users/users/)" + readOnly: true + allOf: + - $ref: '#/components/schemas/UserObject' + updated_at: + type: string + description: When the record was last updated + readOnly: true + x-ballerina-name: updatedAt + user_id: type: integer - description: The user who created the audit + description: The id of the agent making the request + readOnly: true + x-ballerina-name: userId + verb: + type: string + description: "The type of activity. Can be \"tickets.assignment\", \"tickets.comment\"\ + , or \"tickets.priority_increase\"" readOnly: true created_at: type: string - format: date-time - description: The time the audit was created + description: When the record was created readOnly: true - events: - type: array - description: An array of the events that happened in this audit. See the [Ticket Audit events reference](/documentation/ticketing/reference-guides/ticket-audit-events-reference) - items: - type: object - additionalProperties: true - id: + x-ballerina-name: createdAt + actor_id: type: integer - description: Automatically assigned when creating audits + description: "The id of the user responsible for the ticket activity. An\ + \ `actor_id` of \"-1\" is a Zendesk system user, such as an automations\ + \ action" readOnly: true - metadata: - type: object - description: Metadata for the audit, custom and system data - additionalProperties: true - readOnly: true - ticket_id: + x-ballerina-name: actorId + id: type: integer - description: The ID of the associated ticket + description: Automatically assigned on creation readOnly: true - via: - $ref: '#/components/schemas/TicketAuditViaObject' - example: - author_id: 35436 - created_at: "2009-07-20T22:55:29Z" - events: - - attachments: [] - body: Thanks for your help! - id: 1564245 - public: true - type: Comment - - body: 'Ticket #47 has been updated' - id: 1564246 - subject: Your ticket has been updated - type: Notification - id: 35436 - metadata: - custom: - time_spent: 3m22s - system: - ip_address: 184.106.40.75 - ticket_id: 47 - via: - channel: web - TicketAuditResponse: - type: object - properties: - audit: - $ref: '#/components/schemas/TicketAuditObject' - TicketAuditViaObject: - type: object - description: Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - properties: - channel: + title: type: string - description: 'This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system"' + description: Description of the activity readOnly: true - source: + user: + type: object + description: "The full user record of the agent making the request. See\ + \ [Users](/api-reference/ticketing/users/users/)" + readOnly: true + allOf: + - $ref: '#/components/schemas/UserObject' + url: + type: string + description: The API url of the activity + readOnly: true + object: type: object - description: For some channels a source object gives more information about how or why the ticket or event was created additionalProperties: true + description: "The content of the activity. Can be a ticket, comment, or\ + \ change" readOnly: true - TicketAuditsCountResponse: - type: object - properties: - count: + target: type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - TicketAuditsResponse: + additionalProperties: true + description: "The target of the activity, a ticket" + readOnly: true + example: + actor: + id: 8678530 + name: James A. Rosen + actor_id: 23546 + created_at: 2019-03-05T10:38:52Z + id: 35 + object: {} + target: {} + title: "John Hopeful assigned ticket #123 to you" + updated_at: 2019-03-05T10:38:52Z + url: https://company.zendesk.com/api/v2/activities/35.json + user: + id: 223443 + name: Johnny Agent + user_id: 29451 + verb: tickets.assignment + SLAPolicyFilterDefinitionResponseDefinitionsValues: type: object properties: - after_cursor: - type: string - readOnly: true - after_url: - type: string - readOnly: true - audits: + list: type: array items: - $ref: '#/components/schemas/TicketAuditObject' - before_cursor: - type: string - readOnly: true - before_url: + $ref: '#/components/schemas/SLAPolicyFilterDefinitionResponseDefinitionsValuesList' + type: type: string - readOnly: true - TicketAuditsResponseNoneCursor: + TwitterChannelResponse: type: object properties: - audits: + monitored_twitter_handle: + allOf: + - $ref: '#/components/schemas/TwitterChannelObject' + x-ballerina-name: monitoredTwitterHandle + BatchJobRequestJobItems: + type: object + properties: + trigger_categories: type: array items: - $ref: '#/components/schemas/TicketAuditObject' - count: + $ref: '#/components/schemas/TriggerCategoryBatchRequest' + x-ballerina-name: triggerCategories + triggers: + type: array + items: + $ref: '#/components/schemas/TriggerBatchRequest' + DynamicContentVariantObject: + required: + - content + - locale_id + type: object + properties: + locale_id: type: integer + description: An active locale + x-ballerina-name: localeId + default: + type: boolean + description: If the variant is the default for the item it belongs to + outdated: + type: boolean + description: If the variant is outdated readOnly: true - next_page: + updated_at: type: string - nullable: true + description: When the variant was last updated + format: date-time readOnly: true - previous_page: + x-ballerina-name: updatedAt + active: + type: boolean + description: If the variant is active and useable + created_at: type: string - nullable: true + description: When the variant was created + format: date-time readOnly: true - TicketBulkImportRequest: - type: object - properties: - tickets: - type: array - items: - $ref: '#/components/schemas/TicketImportInput' - TicketChatCommentRedactionResponse: - type: object - properties: - chat_event: - type: object - description: Chat event object - properties: - id: - type: integer - description: Id assigned to the chat event object - readOnly: true - type: - type: string - description: Type of chat event - readOnly: true - value: - type: object - description: The value of the chat event object - properties: - chat_id: - type: string - description: Id of the chat session - readOnly: true - history: - type: array - description: Chat events within the chat session - items: - type: object - additionalProperties: true - visitor_id: - type: string - description: Id assigned to the visitor - readOnly: true - readOnly: true + x-ballerina-name: createdAt + id: + type: integer + description: Automatically assigned when the variant is created + readOnly: true + content: + type: string + description: The content of the variant + url: + type: string + description: The API url of the variant readOnly: true example: - chat_event: - id: 1932802680168 - type: ChatStartedEvent - value: - chat_id: 2109.10502823.Sjuj2YrBpXwei - history: - - actor_id: 1900448983828 - actor_name: Visitor 36044085 - actor_type: end-user - chat_index: 0 - timestamp: 1632470783218 - type: ChatJoin - visitor_id: 10502823-16EkM3T6VNq7KMd - TicketCommentObject: + active: true + content: This is my dynamic content in English + created_at: 2014-04-09T19:53:23Z + default: true + id: 23 + locale_id: 125 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json + IncrementalSkillBasedRoutingAttribute: type: object properties: - attachments: - type: array - description: Attachments, if any. See [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) - items: - $ref: '#/components/schemas/AttachmentObject' - readOnly: true - audit_id: - type: integer - description: The id of the ticket audit record. See [Show Audit](/api-reference/ticketing/tickets/ticket_audits/#show-audit) + name: + type: string + description: The name of the attribute readOnly: true - author_id: - type: integer - description: The id of the comment author. See [Author id](#author-id) - body: + id: type: string - description: The comment string. See [Bodies](#bodies) - created_at: + description: Automatically assigned when an attribute is created + readOnly: true + time: type: string + description: "The time the attribute was created, updated, or deleted" format: date-time - description: The time the comment was created readOnly: true - html_body: + type: type: string - description: The comment formatted as HTML. See [Bodies](#bodies) - id: - type: integer - description: Automatically assigned when the comment is created + description: "One of \"create\", \"update\", or \"delete\"" readOnly: true - metadata: + TicketMetricEventSLAObjectAllOf2: + type: object + properties: + sla: type: object - description: System information (web client, IP address, etc.) and comment flags, if any. See [Comment flags](#comment-flags) - additionalProperties: true + description: "Available if `type` is `apply_sla`. The SLA policy and target\ + \ being enforced on the ticket and metric in question, if any. See [sla](#sla)" readOnly: true - plain_body: + SLAPolicyFilterDefinitionResponse: + type: object + properties: + definitions: + $ref: '#/components/schemas/SLAPolicyFilterDefinitionResponseDefinitions' + ViewCountObject: + type: object + properties: + pretty: type: string - description: The comment presented as plain text. See [Bodies](#bodies) + description: A pretty-printed text approximation of the view count readOnly: true - public: + view_id: + type: integer + description: The id of the view + readOnly: true + x-ballerina-name: viewId + active: type: boolean - description: true if a public comment; false if an internal note. The initial value set on ticket creation persists for any additional comment unless you change it - type: + description: "Only active views if true, inactive views if false, all views\ + \ if null" + readOnly: true + fresh: + type: boolean + description: false if the cached data is stale and the system is still loading + and caching new data + readOnly: true + value: + type: integer + description: The cached number of tickets in the view. Can also be null + if the system is loading and caching new data. Not to be confused with + 0 tickets + nullable: true + readOnly: true + url: type: string - description: '`Comment` or `VoiceComment`. The JSON object for adding voice comments to tickets is different. See [Adding voice comments to tickets](/documentation/ticketing/managing-tickets/adding-voice-comments-to-tickets)' + description: The API url of the count readOnly: true - uploads: - type: array - description: List of tokens received from [uploading files](/api-reference/ticketing/tickets/ticket-attachments/#upload-files) for comment attachments. The files are attached by creating or updating tickets with the tokens. See [Attaching files](/api-reference/ticketing/tickets/tickets/#attaching-files) in Tickets - items: - type: string - via: - $ref: '#/components/schemas/TicketAuditViaObject' - example: - attachments: - - content_type: text/plain - content_url: https://company.zendesk.com/attachments/crash.log - file_name: crash.log - id: 498483 - size: 2532 - thumbnails: [] - author_id: 123123 - body: Thanks for your help! - created_at: "2009-07-20T22:55:29Z" - id: 1274 - metadata: - system: - client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36 - ip_address: 1.1.1.1 - latitude: -37.000000000001 - location: Melbourne, 07, Australia - longitude: 144.0000000000002 - via: - channel: web - source: - from: {} - rel: web_widget - to: {} - public: true - type: Comment - TicketCommentResponse: + QueueResponse: type: object properties: - comment: - $ref: '#/components/schemas/TicketCommentObject' - TicketCommentsCountResponse: + queue: + $ref: '#/components/schemas/QueueObject' + FollowerObject: type: object properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - TicketCommentsResponse: + user_email: + type: string + format: email + x-ballerina-name: userEmail + user_id: + type: string + x-ballerina-name: userId + action: + type: string + enum: + - put + - delete + TicketMetricsResponse: type: object properties: - comments: + ticket_metrics: type: array items: - $ref: '#/components/schemas/TicketCommentObject' - TicketCreateInput: - type: object - allOf: - - $ref: '#/components/schemas/TicketUpdateInput' - - type: object - properties: - brand_id: - type: integer - description: Enterprise only. The id of the brand this ticket is associated with - collaborators: - type: array - description: POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) - items: - $ref: '#/components/schemas/CollaboratorObject' - email_cc_ids: - type: array - description: The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center - items: - type: integer - follower_ids: - type: array - description: The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) - items: - type: integer - macro_ids: - type: array - description: POST requests only. List of macro IDs to be recorded in the ticket audit - items: - type: integer - raw_subject: - type: string - description: | - The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - recipient: - type: string - description: The original recipient e-mail address of the ticket - submitter_id: - type: integer - description: The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket - ticket_form_id: - type: integer - description: Enterprise only. The id of the ticket form to render for the ticket - via: - $ref: '#/components/schemas/ViaObject' - via_followup_source_id: - type: integer - description: POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) - required: - - comment - example: - comment: - body: The smoke is very colorful. - priority: urgent - subject: My printer is on fire! - TicketCreateRequest: + $ref: '#/components/schemas/TicketMetricObject' + x-ballerina-name: ticketMetrics + LocaleResponse: type: object properties: - ticket: - $ref: '#/components/schemas/TicketCreateInput' - TicketCreateVoicemailTicketInput: + locale: + $ref: '#/components/schemas/LocaleObject' + OrganizationObject: type: object properties: - comment: - $ref: '#/components/schemas/TicketCommentObject' - priority: + shared_tickets: + type: boolean + description: End users in this organization are able to see each other's + tickets + x-ballerina-name: sharedTickets + notes: type: string - description: The urgency with which the ticket should be addressed. - enum: - - urgent - - high - - normal - - low - via_id: - type: integer - description: Required for Create Ticket operation - enum: - - 44 - - 45 - - 46 - voice_comment: + description: Any notes you have about the organization + nullable: true + created_at: + type: string + description: The time the organization was created + readOnly: true + x-ballerina-name: createdAt + external_id: + type: string + description: "A unique external id to associate organizations to an external\ + \ record. The id is case-insensitive. For example, \"company1\" and \"\ + Company1\" are considered the same" + nullable: true + x-ballerina-name: externalId + url: + type: string + description: The API url of this organization + domain_names: + type: array + description: An array of domain names associated with this organization + items: + type: string + x-ballerina-name: domainNames + tags: + type: array + description: The tags of the organization + items: + type: string + organization_fields: type: object - description: Required if creating voicemail ticket - allOf: - - $ref: '#/components/schemas/TicketCreateVoicemailTicketVoiceCommentInput' - TicketCreateVoicemailTicketRequest: + additionalProperties: + oneOf: + - type: string + - type: number + description: "Custom fields for this organization. See [Custom organization\ + \ fields](/api-reference/ticketing/organizations/organizations/#custom-organization-fields)" + nullable: true + x-ballerina-name: organizationFields + updated_at: + type: string + description: The time of the last update of the organization + readOnly: true + x-ballerina-name: updatedAt + group_id: + type: integer + description: New tickets from users in this organization are automatically + put in this group + nullable: true + x-ballerina-name: groupId + name: + type: string + description: A unique name for the organization + details: + type: string + description: "Any details obout the organization, such as the address" + nullable: true + id: + type: integer + description: Automatically assigned when the organization is created + shared_comments: + type: boolean + description: End users in this organization are able to comment on each + other's tickets + x-ballerina-name: sharedComments + example: + created_at: 2009-07-20T22:55:29Z + details: This is a kind of organization + domain_names: + - example.com + - test.com + external_id: ABC123 + group_id: null + id: 35436 + name: One Organization + notes: "" + organization_fields: + org_decimal: 5.2 + org_dropdown: option_1 + shared_comments: true + shared_tickets: true + tags: + - enterprise + - other_tag + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/organizations/35436.json + MacrosResponseAllOf1: type: object properties: - display_to_agent: - type: integer - description: Optional value such as the ID of the agent that will see the newly created ticket. - ticket: - type: object - description: Ticket object that lists the values to set when the ticket is created - allOf: - - $ref: '#/components/schemas/TicketCreateVoicemailTicketInput' - TicketCreateVoicemailTicketVoiceCommentInput: + macros: + type: array + items: + $ref: '#/components/schemas/MacroObject' + WorkspaceResponseAllOf1: type: object properties: - answered_by_id: - type: integer - description: The agent who answered the call - call_duration: - type: integer - description: Duration in seconds of the call - from: - type: string - description: Incoming phone number - location: - type: string - description: Location of the caller (optional) - recording_url: - type: string - description: Incoming phone number - started_at: - type: string - format: date-time - description: '[ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp of the call starting time' - to: + workspaces: + type: array + items: + $ref: '#/components/schemas/WorkspaceObject' + CollaboratorObject: + type: object + properties: + name: type: string - description: Dialed phone number - transcription_text: + email: type: string - description: Transcription of the call (optional) - TicketFieldCountResponse: + format: email + example: + email: someone@example.com + name: Someone Special + SupportAddressResponse: type: object properties: - count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - TicketFieldCustomStatusObject: + recipient_address: + allOf: + - $ref: '#/components/schemas/SupportAddressObject' + x-ballerina-name: recipientAddress + AccountSettingsTicketFormObject: type: object properties: - active: - type: boolean - description: If true, if the custom status is set to active. If false, the custom status is set to inactive - agent_label: + ticket_forms_instructions: type: string - description: The label displayed to agents + x-ballerina-name: ticketFormsInstructions + raw_ticket_forms_instructions: + type: string + x-ballerina-name: rawTicketFormsInstructions + description: "Ticket form settings. See [Ticket Form](#ticket-form)" + SatisfactionRatingObject: + required: + - assignee_id + - group_id + - requester_id + - score + - ticket_id + type: object + properties: + reason: + type: string + description: "The reason for a bad rating given by the requester in a follow-up\ + \ question. Satisfaction reasons must be [enabled](https://support.zendesk.com/hc/en-us/articles/223152967)" created_at: type: string + description: The time the satisfaction rating got created format: date-time - description: The date and time at which the custom ticket status was created readOnly: true - default: - type: boolean - description: If true, the custom status is set to default. If false, the custom status is set to non-default - description: - type: string - description: The description of when the user should select this custom ticket status - end_user_description: - type: string - description: The description displayed to end users - end_user_label: - type: string - description: The label displayed to end users - id: + x-ballerina-name: createdAt + ticket_id: type: integer - description: Automatically assigned when the custom ticket status is created + description: The id of ticket being rated readOnly: true - status_category: - type: string - description: The status category the custom ticket status belongs to - enum: - - new - - open - - pending - - hold - - solved - updated_at: + x-ballerina-name: ticketId + url: type: string - format: date-time - description: The date and time at which the custom ticket status was last updated + description: The API url of this rating readOnly: true - TicketFieldObject: - type: object - properties: - active: - type: boolean - description: Whether this field is available - agent_description: + reason_id: + type: integer + description: "id for the reason the user gave a negative rating. Can only\ + \ be set on ratings with a `score` of \"bad\". To get a descriptive value\ + \ for the id, use the [Show Reason for Satisfaction Rating](/api-reference/ticketing/ticket-management/satisfaction_reasons/#show-reason-for-satisfaction-rating)\ + \ endpoint" + x-ballerina-name: reasonId + reason_code: + type: integer + description: "The default reasons the user can select from a list menu for\ + \ giving a negative rating. See [Reason codes](/api-reference/ticketing/ticket-management/satisfaction_reasons/#reason-codes)\ + \ in the Satisfaction Reasons API. Can only be set on ratings with a `score`\ + \ of \"bad\". Responses don't include this property" + x-ballerina-name: reasonCode + score: type: string - description: A description of the ticket field that only agents can see - collapsed_for_agents: - type: boolean - description: If true, the field is shown to agents by default. If false, the field is hidden alongside infrequently used fields. Classic interface only - created_at: + description: "The rating \"offered\", \"unoffered\", \"good\" or \"bad\"" + updated_at: type: string + description: The time the satisfaction rating got updated format: date-time - description: The time the custom ticket field was created readOnly: true - creator_app_name: - type: string - description: Name of the app that created the ticket field, or a null value if no app created the ticket field - creator_user_id: + x-ballerina-name: updatedAt + group_id: type: integer - description: The id of the user that created the ticket field, or a value of "-1" if an app created the ticket field - custom_field_options: - type: array - description: Required and presented for a custom ticket field of type "multiselect" or "tagger" - items: - $ref: '#/components/schemas/CustomFieldOptionObject' - custom_statuses: - type: array - description: List of customized ticket statuses. Only presented for a system ticket field of type "custom_status" - items: - $ref: '#/components/schemas/TicketFieldCustomStatusObject' + description: The id of group assigned to at the time of rating readOnly: true - description: + x-ballerina-name: groupId + comment: type: string - description: Describes the purpose of the ticket field to users - editable_in_portal: - type: boolean - description: Whether this field is editable by end users in Help Center + description: "The comment received with this rating, if available" id: type: integer - description: Automatically assigned when created + description: Automatically assigned upon creation readOnly: true - position: + assignee_id: type: integer - description: The relative position of the ticket field on a ticket. Note that for accounts with ticket forms, positions are controlled by the different forms - raw_description: - type: string - description: The dynamic content placeholder if present, or the `description` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_title: - type: string - description: The dynamic content placeholder if present, or the `title` value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_title_in_portal: - type: string - description: The dynamic content placeholder if present, or the "title_in_portal" value if not. See [Dynamic Content](/api-reference/ticketing/ticket-management/dynamic_content/) - regexp_for_validation: - type: string - description: For "regexp" fields only. The validation pattern for a field value to be deemed valid - nullable: true - relationship_filter: - type: object - description: A filter definition that allows your autocomplete to filter down results - relationship_target_type: - type: string - description: A representation of what type of object the field references. Options are "zen:user", "zen:organization", "zen:ticket", or "zen:custom_object:{key}" where key is a custom object key. For example "zen:custom_object:apartment". - removable: - type: boolean - description: If false, this field is a system field that must be present on all tickets + description: The id of agent assigned to at the time of rating readOnly: true - required: - type: boolean - description: If true, agents must enter a value in the field to change the ticket status to solved - required_in_portal: - type: boolean - description: If true, end users must enter a value in the field to create the request - sub_type_id: + x-ballerina-name: assigneeId + requester_id: type: integer - description: For system ticket fields of type "priority" and "status". Defaults to 0. A "priority" sub type of 1 removes the "Low" and "Urgent" options. A "status" sub type of 1 adds the "On-Hold" option - system_field_options: - type: array - description: Presented for a system ticket field of type "tickettype", "priority" or "status" - items: - $ref: '#/components/schemas/SystemFieldOptionObject' - readOnly: true - tag: - type: string - description: For "checkbox" fields only. A tag added to tickets when the checkbox field is selected - nullable: true - title: - type: string - description: The title of the ticket field - title_in_portal: - type: string - description: The title of the ticket field for end users in Help Center - type: - type: string - description: System or custom field type. Editable for custom field types and only on creation. See [Create Ticket Field](#create-ticket-field) - updated_at: - type: string - format: date-time - description: The time the custom ticket field was last updated - readOnly: true - url: - type: string - description: The URL for this resource + description: The id of ticket requester submitting the rating readOnly: true - visible_in_portal: - type: boolean - description: Whether this field is visible to end users in Help Center + x-ballerina-name: requesterId example: - active: true - agent_description: This is the agent only description for the subject field - collapsed_for_agents: false - created_at: "2009-07-20T22:55:29Z" - description: This is the subject field of a ticket - editable_in_portal: true - id: 34 - position: 21 - raw_description: This is the subject field of a ticket - raw_title: '{{dc.my_title}}' - raw_title_in_portal: '{{dc.my_title_in_portal}}' - regexp_for_validation: null - removable: false - required: true - required_in_portal: true - tag: null - title: Subject - title_in_portal: Subject - type: subject - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/ticket_fields/34.json - visible_in_portal: true + assignee_id: 135 + created_at: 2011-07-20T22:55:29Z + group_id: 44 + id: 35436 + requester_id: 7881 + score: good + ticket_id: 208 + updated_at: 2011-07-20T22:55:29Z + url: https://company.zendesk.com/api/v2/satisfaction_ratings/62.json + TicketCreateInputAllOf2: required: - - type - - title - TicketFieldResponse: - type: object - properties: - ticket_field: - $ref: '#/components/schemas/TicketFieldObject' - TicketFieldsResponse: + - comment type: object properties: - ticket_fields: + raw_subject: + type: string + description: | + The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) + x-ballerina-name: rawSubject + ticket_form_id: + type: integer + description: Enterprise only. The id of the ticket form to render for the + ticket + x-ballerina-name: ticketFormId + email_cc_ids: type: array + description: "The ids of agents or end users currently CC'ed on the ticket.\ + \ See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233)\ + \ in the Support Help Center" items: - $ref: '#/components/schemas/TicketFieldObject' - TicketFormObject: - type: object - properties: - active: - type: boolean - description: If the form is set as active - agent_conditions: + type: integer + x-ballerina-name: emailCcIds + follower_ids: type: array - description: Array of condition sets for agent workspaces + description: "The ids of agents currently following the ticket. See [CCs\ + \ and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233)" items: - type: object - additionalProperties: true - created_at: - type: string - format: date-time - description: The time the ticket form was created - readOnly: true - default: - type: boolean - description: Is the form the default form for this account - display_name: + type: integer + x-ballerina-name: followerIds + recipient: type: string - description: The name of the form that is displayed to an end user - end_user_conditions: + description: The original recipient e-mail address of the ticket + via_followup_source_id: + type: integer + description: "POST requests only. The id of a closed ticket when creating\ + \ a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket)" + x-ballerina-name: viaFollowupSourceId + collaborators: type: array - description: Array of condition sets for end user products + description: "POST requests only. Users to add as cc's when creating a ticket.\ + \ See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators)" items: - type: object - additionalProperties: true - end_user_visible: + $ref: '#/components/schemas/CollaboratorObject' + submitter_id: + type: integer + description: The user who submitted the ticket. The submitter always becomes + the author of the first comment on the ticket + x-ballerina-name: submitterId + macro_ids: + type: array + description: POST requests only. List of macro IDs to be recorded in the + ticket audit + items: + type: integer + x-ballerina-name: macroIds + brand_id: + type: integer + description: Enterprise only. The id of the brand this ticket is associated + with + x-ballerina-name: brandId + via: + $ref: '#/components/schemas/ViaObject' + TwitterChannelTwicketStatusResponseStatuses: + type: object + properties: + user_followed: type: boolean - description: Is the form visible to the end user + x-ballerina-name: userFollowed id: type: integer - description: Automatically assigned when creating ticket form - readOnly: true - in_all_brands: + favorited: type: boolean - description: Is the form available for use in all brands on this account - name: + retweeted: + type: boolean + SkillBasedRoutingAttributeObject: + required: + - name + type: object + properties: + updated_at: type: string - description: The name of the form - position: - type: integer - description: The position of this form among other forms in the account, i.e. dropdown - raw_display_name: + description: When this record was last updated + format: date-time + readOnly: true + x-ballerina-name: updatedAt + name: type: string - description: The dynamic content placeholder, if present, or the "display_name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - raw_name: + description: The name of the attribute + created_at: type: string - description: The dynamic content placeholder, if present, or the "name" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - restricted_brand_ids: - type: array - description: ids of all brands that this ticket form is restricted to - items: - type: integer + description: When this record was created + format: date-time readOnly: true - ticket_field_ids: - type: array - description: ids of all ticket fields which are in this ticket form. The products use the order of the ids to show the field values in the tickets - items: - type: integer - updated_at: + x-ballerina-name: createdAt + id: type: string - format: date-time - description: The time of the last update of the ticket form + description: Automatically assigned when an attribute is created readOnly: true url: type: string - description: URL of the ticket form + description: URL of the attribute readOnly: true example: - active: true - agent_conditions: - - child_fields: - - id: 101 - is_required: false - required_on_statuses: - statuses: - - new - - open - - pending - - hold - type: SOME_STATUSES - - id: 200 - is_required: true - required_on_statuses: - statuses: - - solved - type: SOME_STATUSES - parent_field_id: 100 - value: matching_value - - child_fields: - - id: 102 - is_required: true - required_on_statuses: - type: ALL_STATUSES - - id: 200 - is_required: false - required_on_statuses: - type: NO_STATUSES - parent_field_id: 101 - value: matching_value_2 - created_at: "2012-04-02T22:55:29Z" - default: true - display_name: Snowboard Damage - end_user_conditions: - - child_fields: - - id: 101 - is_required: true - parent_field_id: 100 - value: matching_value - - child_fields: - - id: 202 - is_required: false - parent_field_id: 200 - value: matching_value - end_user_visible: true - id: 47 - in_all_brands: false - name: Snowboard Problem - position: 9999 - raw_display_name: '{{dc.my_display_name}}' - raw_name: Snowboard Problem - restricted_brand_ids: - - 47 - - 33 - - 22 - ticket_field_ids: - - 2 - - 4 - - 5 - - 10 - - 100 - - 101 - - 102 - - 200 - updated_at: "2012-04-02T22:55:29Z" - url: https://company.zendesk.com/api/v2/ticket_forms/47.json - required: - - name - TicketFormResponse: - type: object - properties: - ticket_form: - $ref: '#/components/schemas/TicketFormObject' - TicketFormsResponse: + created_at: 2017-12-01T19:29:31Z + id: 15821cba-7326-11e8-b07e-950ba849aa27 + name: color + updated_at: 2017-12-01T19:29:31Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/15821cba-7326-11e8-b07e-950ba849aa27.json" + UserMergePropertiesInput: type: object properties: - ticket_forms: - type: array - items: - $ref: '#/components/schemas/TicketFormObject' - TicketImportInput: + password: + type: string + organization_id: + type: integer + x-ballerina-name: organizationId + name: + type: string + email: + type: string + AccountSettingsBrandingObject: type: object properties: - assignee_id: - type: integer - description: The agent currently assigned to the ticket - comments: - type: array - description: The conversation between requesters, collaborators, and agents - items: - allOf: - - type: object - properties: - value: - type: string - description: The comment string value - - $ref: '#/components/schemas/TicketCommentObject' - additionalProperties: true - description: + tab_background_color: type: string - description: Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) - requester_id: - type: integer - description: The user who requested this ticket - subject: + x-ballerina-name: tabBackgroundColor + favicon_url: type: string - description: The value of the subject field for this ticket - tags: + nullable: true + x-ballerina-name: faviconUrl + header_color: + type: string + x-ballerina-name: headerColor + page_background_color: + type: string + x-ballerina-name: pageBackgroundColor + text_color: + type: string + x-ballerina-name: textColor + header_logo_url: + type: string + nullable: true + x-ballerina-name: headerLogoUrl + description: "Branding settings. See [Branding](#branding)" + AttachmentUpdateInput: + type: object + properties: + malware_access_override: + type: boolean + description: "If true, allows access to attachments with detected malware" + x-ballerina-name: malwareAccessOverride + MacroCategoriesResponse: + type: object + properties: + categories: type: array - description: The array of tags applied to this ticket items: type: string - TicketImportRequest: + TicketCreateRequest: type: object properties: ticket: - $ref: '#/components/schemas/TicketImportInput' - TicketMergeInput: + $ref: '#/components/schemas/TicketCreateInput' + TicketMetricEventsResponseTicketMetricEventsResponseAllOf12: type: object properties: - ids: - type: array - description: Ids of tickets to merge into the target ticket - items: - type: integer - source_comment: + next_page: type: string - description: Private comment to add to the source ticket - source_comment_is_public: - type: boolean - description: Whether comment in source tickets are public or private - target_comment: - type: string - description: Private comment to add to the target ticket - target_comment_is_public: - type: boolean - description: Whether comment in target ticket is public or private - required: - - ids - TicketMetricEventBaseObject: - title: Ticket Metric Events - type: object - properties: - id: - type: integer - description: Automatically assigned when the record is created - readOnly: true - instance_id: + x-ballerina-name: nextPage + count: type: integer - description: The instance of the metric associated with the event. See [instance_id](#instance_id) - readOnly: true - metric: - type: string - description: The metric being tracked - enum: - - agent_work_time - - pausable_update_time - - periodic_update_time - - reply_time - - requester_wait_time - - resolution_time - readOnly: true - ticket_id: + end_time: type: integer - description: Id of the associated ticket - readOnly: true - time: - type: string - format: date-time - description: The time the event occurred - readOnly: true - type: - type: string - description: The type of the metric event. See [Ticket metric event types reference](/documentation/ticketing/reference-guides/ticket-metric-event-types-reference) - enum: - - activate - - pause - - fulfill - - apply_sla - - breach - - update_status - - measure - readOnly: true - example: - id: 926256957613 - instance_id: 1 - metric: agent_work_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: measure - TicketMetricEventBreachObject: - title: Ticket Metric Event - type: object - allOf: - - $ref: '#/components/schemas/TicketMetricEventBaseObject' - - type: object - properties: - deleted: - type: boolean - description: Available if `type` is `breach`. In general, you can ignore any breach event when `deleted` is true. See [deleted](#deleted) - readOnly: true - TicketMetricEventGroupSLAObject: - title: Ticket Metric Event - type: object - allOf: - - $ref: '#/components/schemas/TicketMetricEventBaseObject' - - type: object - properties: - group_sla: - type: object - description: Available if `type` is "apply_group_sla". The Group SLA policy and target being enforced on the ticket and metric in question, if any. See [group_sla](#group_sla) - readOnly: true - TicketMetricEventSLAObject: - title: Ticket Metric Event - type: object - allOf: - - $ref: '#/components/schemas/TicketMetricEventBaseObject' - - type: object - properties: - sla: - type: object - description: Available if `type` is `apply_sla`. The SLA policy and target being enforced on the ticket and metric in question, if any. See [sla](#sla) - readOnly: true - TicketMetricEventUpdateStatusObject: - title: Ticket Metric Event - type: object - allOf: - - $ref: '#/components/schemas/TicketMetricEventBaseObject' - - type: object - properties: - status: - type: object - description: Available if `type` is `update_status`. Minutes since the metric has been open. See [status](#status) - readOnly: true - TicketMetricEventsResponse: + x-ballerina-name: endTime + GroupResponse: type: object - allOf: - - type: object - properties: - ticket_metric_events: - type: array - items: - $ref: '#/components/schemas/TicketMetricEventBaseObject' - - type: object - properties: - count: - type: integer - end_time: - type: integer - next_page: - type: string - TicketMetricObject: + properties: + group: + $ref: '#/components/schemas/GroupObject' + SkillBasedRoutingAttributeValueObject: type: object properties: - agent_wait_time_in_minutes: - type: object - description: Number of minutes the agent spent waiting during calendar and business hours - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' - readOnly: true - assigned_at: + updated_at: type: string + description: When this record was last updated format: date-time - description: When the ticket was assigned - readOnly: true - assignee_stations: - type: integer - description: Number of assignees the ticket had readOnly: true - assignee_updated_at: + x-ballerina-name: updatedAt + attribute_id: type: string - format: date-time - description: When the assignee last updated the ticket - readOnly: true + description: Id of the associated attribute + x-ballerina-name: attributeId + name: + type: string + description: The name of the attribute value created_at: type: string + description: When this record was created format: date-time - description: When the record was created readOnly: true - custom_status_updated_at: + x-ballerina-name: createdAt + id: type: string - format: date-time - description: The date and time the ticket's custom status was last updated + description: Automatically assigned when an attribute value is created readOnly: true - first_resolution_time_in_minutes: - type: object - description: Number of minutes to the first resolution time during calendar and business hours - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' + url: + type: string + description: URL of the attribute value readOnly: true - full_resolution_time_in_minutes: - type: object - description: Number of minutes to the full resolution during calendar and business hours + CustomObjectsCreateRequest: + type: object + properties: + custom_object: allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' + - $ref: '#/components/schemas/CustomObjectCreateInput' + x-ballerina-name: customObject + SuspendedTicketObject: + type: object + properties: + attachments: + type: array + description: "The attachments, if any associated to this suspended ticket.\ + \ See [Attachments](/api-reference/ticketing/tickets/ticket-attachments/)" + nullable: true readOnly: true - group_stations: - type: integer - description: Number of groups the ticket passed through + items: + $ref: '#/components/schemas/AttachmentObject' + author: + type: object + description: "The author id (if available), name and email" readOnly: true - id: - type: integer - description: Automatically assigned when the client is created + allOf: + - $ref: '#/components/schemas/AuthorObject' + subject: + type: string + description: The value of the subject field for this ticket readOnly: true - initially_assigned_at: + cause: type: string - format: date-time - description: When the ticket was initially assigned + description: Why the ticket was suspended readOnly: true - latest_comment_added_at: + created_at: type: string + description: "The ticket ID this suspended email is associated with, if\ + \ available" format: date-time - description: When the latest comment was added - readOnly: true - on_hold_time_in_minutes: - type: object - description: Number of minutes on hold - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' readOnly: true - reopens: + x-ballerina-name: createdAt + cause_id: type: integer - description: Total number of times the ticket was reopened + description: The ID of the cause readOnly: true - replies: + x-ballerina-name: causeId + message_id: + type: string + description: "The ID of the email, if available" + readOnly: true + x-ballerina-name: messageId + ticket_id: type: integer - description: The number of public replies added to a ticket by an agent + description: "The ticket ID this suspended email is associated with, if\ + \ available" readOnly: true - reply_time_in_minutes: - type: object - description: Number of minutes to the first reply during calendar and business hours - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' + x-ballerina-name: ticketId + content: + type: string + description: The content that was flagged readOnly: true - reply_time_in_seconds: - type: object - description: Number of seconds to the first reply during calendar hours, only available for Messaging tickets - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' + error_messages: + type: array + description: The error messages if any associated to this suspended ticket + nullable: true readOnly: true - requester_updated_at: + items: + type: object + x-ballerina-name: errorMessages + url: type: string - format: date-time - description: When the requester last updated the ticket + description: The API url of this ticket readOnly: true - requester_wait_time_in_minutes: - type: object - description: Number of minutes the requester spent waiting during calendar and business hours - allOf: - - $ref: '#/components/schemas/TicketMetricTimeObject' + brand_id: + type: integer + description: The id of the brand this ticket is associated with. Only applicable + for Enterprise accounts readOnly: true - solved_at: + x-ballerina-name: brandId + via: + $ref: '#/components/schemas/ViaObject' + updated_at: type: string + description: When the ticket was assigned format: date-time - description: When the ticket was solved readOnly: true - status_updated_at: + x-ballerina-name: updatedAt + recipient: type: string - format: date-time - description: When the status of the ticket was last updated + description: The original recipient e-mail address of the ticket readOnly: true - ticket_id: + id: type: integer - description: Id of the associated ticket + description: Automatically assigned readOnly: true + example: + attachments: [] + author: + email: styx@example.com + id: 1111 + name: Mr. Roboto + brand_id: 123 + cause: Detected as spam + cause_id: 0 + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + error_messages: null + id: 435 + message_id: Spambot@spam.co.evil + recipient: john@example.com + subject: "Help, my printer is on fire!" + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: email + source: + from: + address: totallylegit@emailaddress.com + name: TotallyLegit + rel: null + to: + address: support@example.zendesk.com + name: Example Account + OrganizationSubscriptionResponse: + type: object + properties: + organization_subscription: + allOf: + - $ref: '#/components/schemas/OrganizationSubscriptionObject' + x-ballerina-name: organizationSubscription + ResourceCollectionObject: + type: object + properties: updated_at: type: string + description: Last time the resource collection was updated format: date-time - description: When the record was last updated readOnly: true - url: + x-ballerina-name: updatedAt + created_at: type: string - description: The API url of the ticket metric + description: When the resource collection was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + resources: + type: array + description: "Array of resource metadata objects. See [Resource objects](#resource-objects)" + readOnly: true + items: + $ref: '#/components/schemas/ResourceCollectionObjectResources' + id: + type: integer + description: id for the resource collection. Automatically assigned upon + creation readOnly: true example: - agent_wait_time_in_minutes: - business: 737 - calendar: 2391 - assigned_at: "2011-05-05T10:38:52Z" - assignee_stations: 1 - assignee_updated_at: "2011-05-06T10:38:52Z" - created_at: "2009-07-20T22:55:29Z" - custom_status_updated_at: "2011-05-09T10:38:52Z" - first_resolution_time_in_minutes: - business: 737 - calendar: 2391 - full_resolution_time_in_minutes: - business: 737 - calendar: 2391 - group_stations: 7 - id: 33 - initially_assigned_at: "2011-05-03T10:38:52Z" - latest_comment_added_at: "2011-05-09T10:38:52Z" - on_hold_time_in_minutes: - business: 637 - calendar: 2290 - reopens: 55 - replies: 322 - reply_time_in_minutes: - business: 737 - calendar: 2391 - reply_time_in_seconds: - calendar: 143460 - requester_updated_at: "2011-05-07T10:38:52Z" - requester_wait_time_in_minutes: - business: 737 - calendar: 2391 - solved_at: "2011-05-09T10:38:52Z" - status_updated_at: "2011-05-04T10:38:52Z" - ticket_id: 4343 - updated_at: "2011-05-05T10:38:52Z" - TicketMetricTimeObject: + created_at: 2011-07-20T22:55:29Z + id: 35436 + resources: + - deleted: false + identifier: email_on_ticket_solved + resource_id: 10824486485524 + type: triggers + - deleted: false + identifier: support_description + resource_id: 10824486482580 + type: ticket_fields + updated_at: 2011-07-20T22:55:29Z + TargetHTTP: + required: + - content_type + - method + - target_url type: object properties: - business: - type: integer - description: Time in business hours - readOnly: true - calendar: - type: integer - description: Time in calendar hours - readOnly: true - TicketMetricsByTicketMetricIdResponse: + password: + type: string + description: only writable + content_type: + type: string + description: "\"application/json\", \"application/xml\", or \"application/x-www-form-urlencoded\"" + x-ballerina-name: contentType + method: + type: string + description: "\"get\", \"patch\", \"put\", \"post\", or \"delete\"" + target_url: + type: string + x-ballerina-name: targetUrl + username: + type: string + TriggerRevisionsResponseDiff: type: object properties: - ticket_metric: + active: type: array + description: "An array of [change](#change) objects" items: - $ref: '#/components/schemas/TicketMetricObject' - TicketMetricsResponse: - type: object - properties: - ticket_metrics: + $ref: '#/components/schemas/TriggerChangeObject' + description: type: array + description: "An array of [change](#change) objects" items: - $ref: '#/components/schemas/TicketMetricObject' - TicketObject: - type: object - properties: - allow_attachments: - type: boolean - description: Permission for agents to add add attachments to a comment. Defaults to true - readOnly: true - allow_channelback: - type: boolean - description: Is false if channelback is disabled, true otherwise. Only applicable for channels framework ticket - readOnly: true - assignee_email: - type: string - description: Write only. The email address of the agent to assign the ticket to - writeOnly: true - assignee_id: + $ref: '#/components/schemas/TriggerChangeObject' + target_id: type: integer - description: The agent currently assigned to the ticket - attribute_value_ids: - type: array - description: Write only. An array of the IDs of attribute values to be associated with the ticket - items: - type: integer - writeOnly: true - brand_id: + description: ID of the target revision + x-ballerina-name: targetId + source_id: type: integer - description: The id of the brand this ticket is associated with. See [Setting up multiple brands](https://support.zendesk.com/hc/en-us/articles/4408829476378) - collaborator_ids: + description: ID of the source revision + x-ballerina-name: sourceId + conditions: + $ref: '#/components/schemas/TriggerConditionDiffObject' + title: type: array - description: The ids of users currently CC'ed on the ticket + description: "An array of [change](#change) objects" items: - type: integer - collaborators: + $ref: '#/components/schemas/TriggerChangeObject' + actions: type: array - description: POST requests only. Users to add as cc's when creating a ticket. See [Setting Collaborators](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-collaborators) + description: "An array that contain [action diff objects](#Action Diffs)" items: - $ref: '#/components/schemas/CollaboratorObject' + $ref: '#/components/schemas/TriggerActionDiffObject' + TicketCreateInput: + type: object + example: comment: - type: object - description: Write only. An object that adds a comment to the ticket. See [Ticket comments](/api-reference/ticketing/tickets/ticket_comments/). To include an attachment with the comment, see [Attaching files](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#attaching-files) - writeOnly: true - created_at: + body: The smoke is very colorful. + priority: urgent + subject: My printer is on fire! + allOf: + - $ref: '#/components/schemas/TicketUpdateInput' + - $ref: '#/components/schemas/TicketCreateInputAllOf2' + TrialAccountObject: + type: object + properties: + name: type: string - format: date-time - description: When this record was created - readOnly: true - custom_fields: - type: array - description: Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) - items: - type: object - properties: - id: - type: integer - description: The id of the custom field - value: - type: string - description: The value of the custom field - custom_status_id: - type: integer - description: The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) - description: + description: The name of the account + subdomain: type: string - description: | - Read-only first comment on the ticket. When [creating a ticket](#create-ticket), use `comment` to set the description. See [Description and first comment](#description-and-first-comment) - readOnly: true - due_at: + description: The subdomain of the account + url: type: string - format: date-time - description: If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format. - nullable: true - email_cc_ids: + description: The URL of the account + WorkspaceObject: + type: object + properties: + macros: type: array - description: The ids of agents or end users currently CC'ed on the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) in the Support Help Center + description: The ids of the macros associated to this workspace items: type: integer - email_ccs: - type: object - description: Write only. An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-email-ccs) - writeOnly: true - external_id: + created_at: type: string - description: An id you can use to link Zendesk Support tickets to local records - follower_ids: - type: array - description: The ids of agents currently following the ticket. See [CCs and followers resources](https://support.zendesk.com/hc/en-us/articles/360020585233) - items: - type: integer - followers: - type: object - description: Write only. An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-followers) - writeOnly: true - followup_ids: + description: The time the workspace was created + format: date-time + x-ballerina-name: createdAt + description: + type: string + description: User-defined description of this workspace's purpose + macro_ids: type: array - description: The ids of the followups created from this ticket. Ids are only visible once the ticket is closed + description: The ids of the macros associated to this workspace items: type: integer - readOnly: true - forum_topic_id: - type: integer - description: The topic in the Zendesk Web portal this ticket originated from, if any. The Web portal is deprecated - readOnly: true - from_messaging_channel: + x-ballerina-name: macroIds + prefer_workspace_app_order: type: boolean - description: If true, the ticket's [via type](/documentation/ticketing/reference-guides/via-object-reference/) is a messaging channel. - readOnly: true - group_id: + description: "If true, the order of apps within the workspace will be preserved" + x-ballerina-name: preferWorkspaceAppOrder + title: + type: string + description: The title of the workspace + url: + type: string + description: The URL for this resource + ticket_form_id: type: integer - description: The group this ticket is assigned to - has_incidents: - type: boolean - description: Is true if a ticket is a problem type and has one or more incidents linked to it. Otherwise, the value is false. - readOnly: true + description: The id of the ticket web form associated to this workspace + x-ballerina-name: ticketFormId + updated_at: + type: string + description: The time of the last update of the workspace + format: date-time + x-ballerina-name: updatedAt + selected_macros: + type: array + description: "An array of the macro objects that will be used in this workspace.\ + \ See [Macros](/api-reference/ticketing/business-rules/macros/)" + items: + $ref: '#/components/schemas/MacroObject' + x-ballerina-name: selectedMacros id: type: integer - description: Automatically assigned when the ticket is created - readOnly: true - is_public: - type: boolean - description: Is true if any comments are public, false otherwise - readOnly: true - macro_id: + description: Automatically assigned upon creation + position: type: integer - description: Write only. A macro ID to be recorded in the ticket audit - writeOnly: true - macro_ids: + description: Ordering of the workspace relative to other workspaces + conditions: + $ref: '#/components/schemas/ConditionsObject' + activated: + type: boolean + description: "If true, this workspace is available for use" + apps: type: array - description: POST requests only. List of macro IDs to be recorded in the ticket audit + description: The apps associated to this workspace items: - type: integer - metadata: - type: object - description: Write only. Metadata for the audit. In the `audit` object, the data is specified in the `custom` property of the `metadata` object. See [Setting Metadata](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#setting-metadata) - writeOnly: true - organization_id: - type: integer - description: The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) - priority: + type: object + additionalProperties: true + ConditionObject: + type: object + properties: + field: type: string - description: The urgency with which the ticket should be addressed - enum: - - urgent - - high - - normal - - low - problem_id: - type: integer - description: For tickets of type "incident", the ID of the problem the incident is linked to - raw_subject: + description: The name of a ticket field + value: type: string - description: | - The dynamic content placeholder, if present, or the "subject" value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/) - recipient: + description: The value of a ticket field + operator: type: string - description: The original recipient e-mail address of the ticket. Notification emails for the ticket are sent from this address - requester: - type: object - description: Write only. See [Creating a ticket with a new requester](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#creating-a-ticket-with-a-new-requester) - writeOnly: true - requester_id: - type: integer - description: The user who requested this ticket - safe_update: - type: boolean - description: Write only. Optional boolean. When true and an `update_stamp` date is included, protects against ticket update collisions and returns a message to let you know if one occurs. See [Protecting against ticket update collisions](/documentation/ticketing/managing-tickets/creating-and-updating-tickets/#protecting-against-ticket-update-collisions). A value of false has the same effect as true. Omit the property to force the updates to not be safe - writeOnly: true - satisfaction_rating: - type: object - description: The satisfaction rating of the ticket, if it exists, or the state of satisfaction, "offered" or "unoffered". The value is null for plan types that don't support CSAT - additionalProperties: true + description: A comparison operator + SLAPolicyObject: + required: + - filter + - title + type: object + properties: + filter: + $ref: '#/components/schemas/SLAPolicyFilterObject' + updated_at: + type: string + description: The time of the last update of the SLA policy + format: date-time readOnly: true - sharing_agreement_ids: + x-ballerina-name: updatedAt + policy_metrics: type: array - description: The ids of the sharing agreements used for this ticket + description: "Array of [Policy Metric](#policy-metric) objects" items: - type: integer - readOnly: true - status: + $ref: '#/components/schemas/SLAPolicyMetricObject' + x-ballerina-name: policyMetrics + created_at: type: string - description: | - The state of the ticket. - - If your account has activated custom ticket statuses, this is the ticket's - status category. See [custom ticket statuses](#custom-ticket-statuses) - enum: - - new - - open - - pending - - hold - - solved - - closed - subject: + description: The time the SLA policy was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + description: type: string - description: | - The value of the subject field for this ticket. See [Subject](/api-reference/ticketing/tickets/tickets/#subject) - submitter_id: - type: integer - description: The user who submitted the ticket. The submitter always becomes the author of the first comment on the ticket - tags: - type: array - description: The array of tags applied to this ticket - items: - type: string - ticket_form_id: + description: The description of the SLA policy + id: type: integer - description: Enterprise only. The id of the ticket form to render for the ticket - type: - type: string - description: The type of this ticket - enum: - - problem - - incident - - question - - task - updated_at: - type: string - format: date-time - description: When this record last got updated. It is updated only if the update generates a [ticket event](#incremental-ticket-event-export) + description: Automatically assigned when created readOnly: true - updated_stamp: + position: + type: integer + description: "Position of the SLA policy that determines the order they\ + \ will be matched. If not specified, the SLA policy is added as the last\ + \ position" + title: type: string - description: Write only. Datetime of last update received from API. See the `safe_update` property - writeOnly: true + description: The title of the SLA policy url: type: string - description: The API url of this ticket + description: URL of the SLA Policy reacord readOnly: true - via: - type: object - description: For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) - properties: - channel: - type: string - description: | - This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" - source: - type: object - description: | - For some channels a source object gives more information about how or why the ticket or event was created - additionalProperties: true - via_followup_source_id: + example: + created_at: 2015-03-17T22:50:26Z + description: "Organizations: Silver Plan" + filter: + all: + - field: type + operator: is + value: incident + - field: via_id + operator: is + value: "4" + - field: custom_status_id + operator: includes + value: + - "1" + - "2" + any: [] + id: 25 + policy_metrics: + - business_hours: false + metric: first_reply_time + priority: low + target: 60 + position: 3 + title: Silver Plan + updated_at: 2015-03-17T22:50:26Z + url: https://company.zendesk.com/api/v2/slas/policies/25.json + OrganizationMetadataObject: + type: object + properties: + tickets_count: type: integer - description: POST requests only. The id of a closed ticket when creating a follow-up ticket. See [Creating a follow-up ticket](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#creating-a-follow-up-ticket) - via_id: + description: The number of tickets for the organization + x-ballerina-name: ticketsCount + users_count: type: integer - description: Write only. For more information, see the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference/) - writeOnly: true - voice_comment: + description: The number of users for the organization + x-ballerina-name: usersCount + PushNotificationDevicesInput: + type: array + items: + type: string + description: Mobile device token + TicketMetricEventUpdateStatusObjectAllOf2: + type: object + properties: + status: type: object - description: Write only. See [Creating voicemail ticket](/api-reference/voice/talk-partner-edition-api/reference/#creating-voicemail-tickets) - writeOnly: true - example: - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - custom_status_id: 123 - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - from_messaging_channel: false - group_id: 98738 - has_incidents: false - id: 35436 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web + description: "Available if `type` is `update_status`. Minutes since the\ + \ metric has been open. See [status](#status)" + readOnly: true + TargetGetSatisfaction: required: - - requester_id - TicketRelatedInformation: + - account_name + - email + - password type: object properties: - followup_source_ids: - type: array - items: - type: string - description: Sources to follow up - from_archive: - type: boolean - description: Is true if the current ticket is archived - incidents: + password: + type: string + description: only writable + account_name: + type: string + x-ballerina-name: accountName + target_url: + type: string + x-ballerina-name: targetUrl + email: + type: string + ListDeletedTicketsResponseDeletedTickets: + type: object + properties: + actor: + $ref: '#/components/schemas/ListDeletedTicketsResponseActor' + previous_state: + type: string + x-ballerina-name: previousState + subject: + type: string + id: type: integer - description: A count of related incident occurrences - topic_id: + deleted_at: type: string - description: Related topic in the Web portal (deprecated feature) - nullable: true - twitter: - type: object - description: X (formerly Twitter) information associated with the ticket - additionalProperties: true - TicketResponse: + x-ballerina-name: deletedAt + BrandCreateRequest: type: object properties: - ticket: - $ref: '#/components/schemas/TicketObject' - TicketSkipCreation: + brand: + $ref: '#/components/schemas/BrandObject' + Page: type: object properties: - skip: - $ref: '#/components/schemas/TicketSkipObject' - TicketSkipObject: + size: + type: integer + before: + type: string + after: + type: string + CustomObjectLimitsResponse: type: object properties: + count: + type: integer + description: The current numnber of the requested resource + readOnly: true + limit: + type: integer + description: The maximum allowed number for the requested resource + readOnly: true + CustomRoleObject: + title: Custom Agent Roles + required: + - name + - role_type + type: object + properties: + team_member_count: + type: integer + description: The number of team members assigned to this role + readOnly: true + x-ballerina-name: teamMemberCount + role_type: + type: integer + description: "The user's role. 0 stands for a custom agent, 1 for a light\ + \ agent, 2 for a chat agent, 3 for a contributor, 4 for an admin and 5\ + \ for a billing admin. See [Understanding standard agent roles in Zendesk\ + \ Support](https://support.zendesk.com/hc/en-us/articles/4409155971354-Understanding-standard-agent-roles-in-Zendesk-Support)\ + \ in Zendesk help" + readOnly: true + x-ballerina-name: roleType + updated_at: + type: string + description: The time the record was last updated + format: date-time + readOnly: true + x-ballerina-name: updatedAt + configuration: + $ref: '#/components/schemas/CustomRoleConfigurationObject' + name: + type: string + description: Name of the custom role created_at: type: string + description: The time the record was created format: date-time - description: Time the skip was created readOnly: true + x-ballerina-name: createdAt + description: + type: string + description: A description of the role id: type: integer - description: Automatically assigned upon creation + description: Automatically assigned on creation readOnly: true - reason: + EssentialsCardObject: + required: + - fields + type: object + properties: + layout: type: string - description: Reason for skipping the ticket + description: | + layout type readOnly: true - ticket: - type: object - description: The skipped ticket. See the [Ticket object reference](/api-reference/ticketing/tickets/tickets/#json-format) - allOf: - - $ref: '#/components/schemas/TicketObject' - ticket_id: + max_count: type: integer - description: ID of the skipped ticket + description: Maximum number of fields allowed in the essentials card + readOnly: true + x-ballerina-name: maxCount + default: + type: boolean + description: "If true, the system has used the first twenty fields for the\ + \ custom object type as the essentials card" readOnly: true updated_at: type: string + description: Date and time the essentials card were last updated format: date-time - description: Time the skip was last updated readOnly: true - user_id: - type: integer - description: ID of the skipping agent + x-ballerina-name: updatedAt + created_at: + type: string + description: Date and time the essentials card were created + format: date-time + readOnly: true + x-ballerina-name: createdAt + id: + type: string + description: | + id of the essentials card + nullable: true + readOnly: true + fields: + type: array + description: Fields that are displayed in the essentials card details. The + order is defined by the order of the fields in the array + items: + type: object + additionalProperties: true + key: + type: string + description: | + Object type. Example: `zen:user` refers to `User` type readOnly: true example: - created_at: "2015-09-30T21:44:03Z" - id: 1 - reason: I have no idea. - ticket: - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - from_messaging_channel: false - group_id: 98738 - has_incidents: false - id: 123 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - ticket_id: 123 - updated_at: "2015-09-30T21:44:03Z" - user_id: 456 - TicketSkipsResponse: + created_at: 2012-04-02T22:55:29Z + default: true + fields: + - id: null + zrn: zen:user:identity:email + - id: null + zrn: zen:user:field:standard:external_id + - id: null + zrn: zen:user:field:standard:iana_time_zone + - id: null + zrn: zen:user:field:standard:locale + - id: null + zrn: zen:user:field:standard:organization_id + id: "123" + key: zen:custom_object:boat + layout: essentials_card + max_count: 20 + updated_at: 2012-04-02T22:55:29Z + CustomObjectRecordsResponse: type: object properties: - skips: + meta: + $ref: '#/components/schemas/CustomObjectRecordsResponseMeta' + count: + type: integer + description: The number of results returned for the current request + readOnly: true + links: + $ref: '#/components/schemas/CustomObjectRecordsResponseLinks' + custom_object_records: type: array items: - $ref: '#/components/schemas/TicketSkipObject' - TicketUpdateInput: + $ref: '#/components/schemas/CustomObjectRecord' + x-ballerina-name: customObjectRecords + ListTicketCollaboratorsResponse: + type: object + additionalProperties: true + TicketImportInputComments: + allOf: + - $ref: '#/components/schemas/CommentsAllOf1' + - $ref: '#/components/schemas/TicketCommentObject' + TicketAuditViaObject: type: object properties: - additional_collaborators: - type: array - description: An array of numeric IDs, emails, or objects containing name and email properties. See [Setting Collaborators](/api-reference/ticketing/tickets/tickets/#setting-collaborators). An email notification is sent to them when the ticket is updated - items: - $ref: '#/components/schemas/CollaboratorObject' - assignee_email: - type: string - format: email - description: The email address of the agent to assign the ticket to - assignee_id: - type: integer - description: The agent currently assigned to the ticket - attribute_value_ids: - type: array - description: An array of the IDs of attribute values to be associated with the ticket - items: - type: integer - collaborator_ids: - type: array - description: The ids of users currently CC'ed on the ticket - items: - type: integer - comment: - $ref: '#/components/schemas/TicketCommentObject' - custom_fields: - type: array - description: Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values) - items: - $ref: '#/components/schemas/CustomFieldObject' - custom_status_id: - type: integer - description: The custom ticket status id of the ticket. See [custom ticket statuses](#custom-ticket-statuses) - due_at: - type: string - format: date-time - description: If this is a ticket of type "task" it has a due date. Due date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format. - nullable: true - email_ccs: - type: array - description: An array of objects that represent agent or end users email CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-email-ccs) - items: - $ref: '#/components/schemas/EmailCCObject' - external_id: + channel: type: string - description: An id you can use to link Zendesk Support tickets to local records - followers: - type: array - description: An array of objects that represent agent followers to add or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-followers) - items: - $ref: '#/components/schemas/FollowerObject' - group_id: + description: "This tells you how the ticket or event was created. Examples:\ + \ \"web\", \"mobile\", \"rule\", \"system\"" + readOnly: true + source: + type: object + additionalProperties: true + description: For some channels a source object gives more information about + how or why the ticket or event was created + readOnly: true + description: "Describes how the object was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference)" + UserRequest: + required: + - user + type: object + properties: + user: + $ref: '#/components/schemas/UserInput' + OrganizationSubscriptionObject: + title: Organization Subscriptions + type: object + properties: + user_id: type: integer - description: The group this ticket is assigned to + description: The ID of the user + x-ballerina-name: userId organization_id: type: integer - description: The organization of the requester. You can only specify the ID of an organization associated with the requester. See [Organization Memberships](/api-reference/ticketing/organizations/organization_memberships/) - priority: - type: string - description: The urgency with which the ticket should be addressed. - enum: - - urgent - - high - - normal - - low - problem_id: - type: integer - description: For tickets of type "incident", the ID of the problem the incident is linked to - requester_id: - type: integer - description: The user who requested this ticket - safe_update: - type: boolean - description: Optional boolean. Prevents updates with outdated ticket data (`updated_stamp` property required when true) - sharing_agreement_ids: - type: array - description: An array of the numeric IDs of sharing agreements. Note that this replaces any existing agreements - items: - type: integer - status: - type: string - description: | - The state of the ticket. - - If your account has activated custom ticket statuses, this is the ticket's - status category. See [custom ticket statuses](#custom-ticket-statuses). - enum: - - new - - open - - pending - - hold - - solved - - closed - subject: - type: string - description: The value of the subject field for this ticket - tags: - type: array - description: The array of tags applied to this ticket - items: - type: string - type: - type: string - description: The type of this ticket. - enum: - - problem - - incident - - question - - task - updated_stamp: + description: The ID of the organization + x-ballerina-name: organizationId + created_at: type: string + description: The date the organization subscription was created format: date-time - description: Datetime of last update received from API. See the safe_update property + x-ballerina-name: createdAt + id: + type: integer + description: The ID of the organization subscription example: - comment: - body: The smoke is very colorful. - priority: urgent - subject: My printer is on fire! - TicketUpdateRequest: + created_at: 2009-07-20T22:55:29Z + id: 1234 + organization_id: 32 + user_id: 482 + AccountSettingsMetricsObject: type: object properties: - ticket: - $ref: '#/components/schemas/TicketUpdateInput' - TicketUpdateResponse: + account_size: + type: string + x-ballerina-name: accountSize + description: "Account metrics settings. See [Metrics](#metrics)" + MacrosResponse: type: object - properties: - audit: - $ref: '#/components/schemas/AuditObject' - ticket: - $ref: '#/components/schemas/TicketObject' - TicketsCreateRequest: + allOf: + - $ref: '#/components/schemas/MacrosResponseAllOf1' + - $ref: '#/components/schemas/OffsetPaginationObject' + TicketMetricEventSLAObject: + title: Ticket Metric Event + type: object + allOf: + - $ref: '#/components/schemas/TicketMetricEventBaseObject' + - $ref: '#/components/schemas/TicketMetricEventSLAObjectAllOf2' + SkillBasedRoutingAttributeValueResponse: type: object properties: - tickets: - type: array - items: - $ref: '#/components/schemas/TicketCreateInput' - TicketsResponse: + attribute_value: + allOf: + - $ref: '#/components/schemas/SkillBasedRoutingAttributeValueObject' + x-ballerina-name: attributeValue + SLAPoliciesResponse: type: object properties: - tickets: + next_page: + type: string + nullable: true + readOnly: true + x-ballerina-name: nextPage + count: + type: integer + readOnly: true + previous_page: + type: string + nullable: true + readOnly: true + x-ballerina-name: previousPage + sla_policies: type: array items: - $ref: '#/components/schemas/TicketObject' - TimeBasedExportIncrementalTicketsResponse: + $ref: '#/components/schemas/SLAPolicyObject' + x-ballerina-name: slaPolicies + CountResponse: type: object - description: | - See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example. properties: count: - type: integer - end_of_stream: + $ref: '#/components/schemas/CountResponseCount' + GroupObject: + required: + - name + type: object + properties: + default: type: boolean - end_time: + description: If the group is the default one for the account + readOnly: true + deleted: + type: boolean + description: Deleted groups get marked as such + readOnly: true + updated_at: + type: string + description: The time of the last update of the group + format: date-time + readOnly: true + x-ballerina-name: updatedAt + is_public: + type: boolean + description: | + If true, the group is public. + If false, the group is private. + You can't change a private group to a public group + x-ballerina-name: isPublic + name: + type: string + description: The name of the group + created_at: + type: string + description: The time the group was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + description: + type: string + description: The description of the group + id: type: integer - next_page: + description: Automatically assigned when creating groups + readOnly: true + url: type: string - nullable: true - tickets: - type: array - items: - $ref: '#/components/schemas/TicketObject' + description: The API url of the group + readOnly: true example: - count: 2 - end_of_stream: true - end_time: 1390362485 - next_page: https://{subdomain}.zendesk.com/api/v2/incremental/tickets.json?per_page=3&start_time=1390362485 + created_at: 2009-07-20T22:55:29Z + default: true + deleted: false + description: Some clever description here + id: 3432 + is_public: true + name: First Level Support + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/groups/3432.json + AccountSettingsOnboardingObject: + type: object + properties: + product_sign_up: + type: string + nullable: true + x-ballerina-name: productSignUp + checklist_onboarding_version: + type: integer + x-ballerina-name: checklistOnboardingVersion + onboarding_segments: + type: string + nullable: true + x-ballerina-name: onboardingSegments + description: Onboarding settings + SearchResponse: + type: object + properties: + next_page: + type: string + description: URL to the next page of results + nullable: true + readOnly: true + x-ballerina-name: nextPage + count: + type: integer + description: The number of resources returned by the query corresponding + to this page of results in the paginated response + readOnly: true + previous_page: + type: string + description: URL to the previous page of results + nullable: true + readOnly: true + x-ballerina-name: previousPage + results: + type: array + description: "May consist of tickets, users, groups, or organizations, as\ + \ specified by the `result_type` property in each result object" + readOnly: true + items: + $ref: '#/components/schemas/SearchResultObject' + facets: + type: string + description: The facets corresponding to the search query + nullable: true + readOnly: true + example: + count: 1 + facets: null + next_page: null + previous_page: null + results: + - created_at: 2018-04-06T03:17:05Z + default: false + deleted: false + description: "" + id: 1835972 + name: Ragtail + result_type: group + updated_at: 2018-04-06T03:17:05Z + url: https://example.zendesk.com/api/v2/groups/1835972.json + ViewExportResponse: + type: object + properties: + export: + $ref: '#/components/schemas/ViewExportResponseExport' + DefinitionsResponseDefinitionsValues: + type: object + properties: + title: + type: string + value: + type: string + enabled: + type: boolean + AttachmentBaseObject: + type: object + properties: + malware_access_override: + type: boolean + description: "If true, you can download an attachment flagged as malware.\ + \ If false, you can't download such an attachment" + readOnly: true + x-ballerina-name: malwareAccessOverride + mapped_content_url: + type: string + description: The URL the attachment image file has been mapped to + readOnly: true + x-ballerina-name: mappedContentUrl + file_name: + type: string + description: The name of the image file + readOnly: true + x-ballerina-name: fileName + malware_scan_result: + type: string + description: "The result of the malware scan. There is a delay between the\ + \ time the attachment is uploaded and when the malware scan is completed.\ + \ Usually the scan is done within a few seconds, but high load conditions\ + \ can delay the scan results. Possible values: \"malware_found\", \"malware_not_found\"\ + , \"failed_to_scan\", \"not_scanned\"" + readOnly: true + x-ballerina-name: malwareScanResult + url: + type: string + description: A URL to access the attachment details + readOnly: true + deleted: + type: boolean + description: "If true, the attachment has been deleted" + readOnly: true + content_type: + type: string + description: "The content type of the image. Example value: \"image/png\"" + readOnly: true + x-ballerina-name: contentType + inline: + type: boolean + description: | + If true, the attachment is excluded from the attachment list and the attachment's URL + can be referenced within the comment of a ticket. Default is false + readOnly: true + size: + type: integer + description: The size of the image file in bytes + readOnly: true + width: + type: string + description: "The width of the image file in pixels. If width is unknown,\ + \ returns null" + readOnly: true + content_url: + type: string + description: "A full URL where the attachment image file can be downloaded.\ + \ The file may be hosted externally so take care not to inadvertently\ + \ send Zendesk authentication credentials. See [Working with url properties](/documentation/ticketing/managing-tickets/working-with-url-properties)" + readOnly: true + x-ballerina-name: contentUrl + id: + type: integer + description: Automatically assigned when created + readOnly: true + height: + type: string + description: "The height of the image file in pixels. If height is unknown,\ + \ returns null" + readOnly: true + UpdateResourceResult: + required: + - action + - id + - status + - success + type: object + properties: + success: + type: boolean + description: | + whether the action was successful or not (`"success": true`) + action: + type: string + description: | + the action the job attempted (`"action": "update"`) + id: + type: integer + description: the id of the resource the job attempted to update + status: + type: string + description: | + the status (`"status": "Updated"`) + UserPasswordRequirementsResponse: + type: object + properties: + requirements: + type: array + items: + type: string + TicketCommentsCountResponse: + type: object + properties: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + DefinitionsResponseDefinitions: + type: object + properties: + conditions_any: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsConditionsAll' + x-ballerina-name: conditionsAny + conditions_all: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsConditionsAll' + x-ballerina-name: conditionsAll + SatisfactionRatingsResponse: + type: object + properties: + satisfaction_ratings: + type: array + items: + $ref: '#/components/schemas/SatisfactionRatingObject' + x-ballerina-name: satisfactionRatings + MacroApplyTicketResponseResultTicketFields: + type: object + properties: + id: + type: integer + value: + type: string + TicketCreateVoicemailTicketVoiceCommentInput: + type: object + properties: + transcription_text: + type: string + description: Transcription of the call (optional) + x-ballerina-name: transcriptionText + recording_url: + type: string + description: Incoming phone number + x-ballerina-name: recordingUrl + answered_by_id: + type: integer + description: The agent who answered the call + x-ballerina-name: answeredById + started_at: + type: string + description: "[ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp\ + \ of the call starting time" + format: date-time + x-ballerina-name: startedAt + from: + type: string + description: Incoming phone number + location: + type: string + description: Location of the caller (optional) + to: + type: string + description: Dialed phone number + call_duration: + type: integer + description: Duration in seconds of the call + x-ballerina-name: callDuration + SearchResultObject: + type: object + properties: + result_type: + type: string + description: The type of the resource + x-ballerina-name: resultType + default: + type: boolean + description: Flag to indicate whether this is the default resource + deleted: + type: boolean + description: Flag to indicate whether or not resource has been deleted + updated_at: + type: string + description: When the resource was last updated + x-ballerina-name: updatedAt + name: + type: string + description: The name of the resource + created_at: + type: string + description: When the resource was created + x-ballerina-name: createdAt + description: + type: string + description: The description of the resource + id: + type: integer + description: The ID of the resource + url: + type: string + description: The url of the resource + SupportAddressesResponse: + type: object + properties: + recipient_addresses: + type: array + items: + $ref: '#/components/schemas/SupportAddressObject' + x-ballerina-name: recipientAddresses + TriggerConditionDefinitionObjectAll: + type: object + properties: + nullable: + type: boolean + operators: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsOperators' + repeatable: + type: boolean + subject: + type: string + values: + type: array + items: + $ref: '#/components/schemas/DefinitionsResponseDefinitionsValues' + title: + type: string + type: + type: string + group: + type: string + CustomStatusCreateInputAllOf2: + type: object + properties: + status_category: + type: string + description: The status category the custom ticket status belongs to + enum: + - new + - open + - pending + - hold + - solved + x-ballerina-name: statusCategory + AccountSettingsTicketObject: + type: object + properties: + auto_translation_enabled: + type: boolean + x-ballerina-name: autoTranslationEnabled + agent_ticket_deletion: + type: boolean + x-ballerina-name: agentTicketDeletion + tagging: + type: boolean + using_skill_based_routing: + type: boolean + x-ballerina-name: usingSkillBasedRouting + has_color_text: + type: boolean + x-ballerina-name: hasColorText + allow_group_reset: + type: boolean + x-ballerina-name: allowGroupReset + rich_text_comments: + type: boolean + x-ballerina-name: richTextComments + comments_public_by_default: + type: boolean + x-ballerina-name: commentsPublicByDefault + follower_and_email_cc_collaborations: + type: boolean + x-ballerina-name: followerAndEmailCcCollaborations + light_agent_email_ccs_allowed: + type: boolean + x-ballerina-name: lightAgentEmailCcsAllowed + is_first_comment_private_enabled: + type: boolean + x-ballerina-name: isFirstCommentPrivateEnabled + list_empty_views: + type: boolean + x-ballerina-name: listEmptyViews + chat_sla_enablement: + type: boolean + x-ballerina-name: chatSlaEnablement + agent_invitation_enabled: + type: boolean + x-ballerina-name: agentInvitationEnabled + accepted_new_collaboration_tos: + type: boolean + x-ballerina-name: acceptedNewCollaborationTos + assign_default_organization: + type: boolean + x-ballerina-name: assignDefaultOrganization + emoji_autocompletion: + type: boolean + x-ballerina-name: emojiAutocompletion + private_attachments: + type: boolean + x-ballerina-name: privateAttachments + auto_updated_ccs_followers_rules: + type: boolean + x-ballerina-name: autoUpdatedCcsFollowersRules + email_attachments: + type: boolean + x-ballerina-name: emailAttachments + list_newest_comments_first: + type: boolean + x-ballerina-name: listNewestCommentsFirst + status_hold: + type: boolean + x-ballerina-name: statusHold + markdown_ticket_comments: + type: boolean + x-ballerina-name: markdownTicketComments + agent_collision: + type: boolean + x-ballerina-name: agentCollision + maximum_personal_views_to_list: + type: integer + x-ballerina-name: maximumPersonalViewsToList + assign_tickets_upon_solve: + type: boolean + x-ballerina-name: assignTicketsUponSolve + collaboration: + type: boolean + description: "Ticket settings. See [Tickets](#tickets)" + TagsByObjectIdResponse: + required: + - tags + type: object + properties: + tags: + type: array + description: An array of strings + items: + type: string + CountResponseCount: + type: object + properties: + refreshed_at: + type: string + format: datetime + x-ballerina-name: refreshedAt + value: + type: integer + TicketResponse: + type: object + properties: + ticket: + $ref: '#/components/schemas/TicketObject' + TriggerConditionsObject: + type: object + properties: + all: + type: array + nullable: true + items: + $ref: '#/components/schemas/TriggerConditionObject' + any: + type: array + nullable: true + items: + $ref: '#/components/schemas/TriggerConditionObject' + description: "An object that describes the conditions under which the trigger\ + \ will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference)" + example: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + - field: custom_status_id + operator: includes + value: + - "1" + - "2" + any: + - field: status + operator: less_than + value: solved + - field: custom_status_id + operator: includes + value: + - "1" + - "2" + AccountSettingsAgentObject: + type: object + properties: + agent_workspace: + type: boolean + x-ballerina-name: agentWorkspace + aw_self_serve_migration_enabled: + type: boolean + x-ballerina-name: awSelfServeMigrationEnabled + agent_home: + type: boolean + x-ballerina-name: agentHome + idle_timeout_enabled: + type: boolean + x-ballerina-name: idleTimeoutEnabled + unified_agent_statuses: + type: boolean + x-ballerina-name: unifiedAgentStatuses + focus_mode: + type: boolean + x-ballerina-name: focusMode + description: "Configuration for the agent workspace. See [Agents](#agents)" + TicketMetricsByTicketMetricIdResponse: + type: object + properties: + ticket_metric: + type: array + items: + $ref: '#/components/schemas/TicketMetricObject' + x-ballerina-name: ticketMetric + TicketFormObject: + required: + - name + type: object + properties: + raw_name: + type: string + description: "The dynamic content placeholder, if present, or the \"name\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawName + in_all_brands: + type: boolean + description: Is the form available for use in all brands on this account + x-ballerina-name: inAllBrands + ticket_field_ids: + type: array + description: ids of all ticket fields which are in this ticket form. The + products use the order of the ids to show the field values in the tickets + items: + type: integer + x-ballerina-name: ticketFieldIds + active: + type: boolean + description: If the form is set as active + agent_conditions: + type: array + description: Array of condition sets for agent workspaces + items: + type: object + additionalProperties: true + x-ballerina-name: agentConditions + created_at: + type: string + description: The time the ticket form was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + raw_display_name: + type: string + description: "The dynamic content placeholder, if present, or the \"display_name\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawDisplayName + display_name: + type: string + description: The name of the form that is displayed to an end user + x-ballerina-name: displayName + url: + type: string + description: URL of the ticket form + readOnly: true + default: + type: boolean + description: Is the form the default form for this account + end_user_conditions: + type: array + description: Array of condition sets for end user products + items: + type: object + additionalProperties: true + x-ballerina-name: endUserConditions + updated_at: + type: string + description: The time of the last update of the ticket form + format: date-time + readOnly: true + x-ballerina-name: updatedAt + end_user_visible: + type: boolean + description: Is the form visible to the end user + x-ballerina-name: endUserVisible + name: + type: string + description: The name of the form + id: + type: integer + description: Automatically assigned when creating ticket form + readOnly: true + position: + type: integer + description: "The position of this form among other forms in the account,\ + \ i.e. dropdown" + restricted_brand_ids: + type: array + description: ids of all brands that this ticket form is restricted to + readOnly: true + items: + type: integer + x-ballerina-name: restrictedBrandIds + example: + active: true + agent_conditions: + - child_fields: + - id: 101 + is_required: false + required_on_statuses: + statuses: + - new + - open + - pending + - hold + type: SOME_STATUSES + - id: 200 + is_required: true + required_on_statuses: + statuses: + - solved + type: SOME_STATUSES + parent_field_id: 100 + value: matching_value + - child_fields: + - id: 102 + is_required: true + required_on_statuses: + type: ALL_STATUSES + - id: 200 + is_required: false + required_on_statuses: + type: NO_STATUSES + parent_field_id: 101 + value: matching_value_2 + created_at: 2012-04-02T22:55:29Z + default: true + display_name: Snowboard Damage + end_user_conditions: + - child_fields: + - id: 101 + is_required: true + parent_field_id: 100 + value: matching_value + - child_fields: + - id: 202 + is_required: false + parent_field_id: 200 + value: matching_value + end_user_visible: true + id: 47 + in_all_brands: false + name: Snowboard Problem + position: 9999 + raw_display_name: "{{dc.my_display_name}}" + raw_name: Snowboard Problem + restricted_brand_ids: + - 47 + - 33 + - 22 + ticket_field_ids: + - 2 + - 4 + - 5 + - 10 + - 100 + - 101 + - 102 + - 200 + updated_at: 2012-04-02T22:55:29Z + url: https://company.zendesk.com/api/v2/ticket_forms/47.json + ListDeletedTicketsResponse: + type: object + allOf: + - $ref: '#/components/schemas/ListDeletedTicketsResponseAllOf1' + - $ref: '#/components/schemas/OffsetPaginationObject' + TargetsResponse: + type: object + properties: + targets: + type: array + items: + $ref: '#/components/schemas/TargetObject' + UserObject: + additionalProperties: true + anyOf: + - $ref: '#/components/schemas/UserForAdmin' + - $ref: '#/components/schemas/UserForEndUser' + WorkspaceInput: + type: object + properties: + macros: + type: array + items: + type: number + ticket_form_id: + type: number + x-ballerina-name: ticketFormId + description: + type: string + description: User-defined description of this workspace's purpose + conditions: + $ref: '#/components/schemas/ConditionsObject' + title: + type: string + description: The title of the workspace + ActionObject: + type: object + properties: + field: + type: string + description: The name of a ticket field to modify + value: + type: string + description: The new value of the field + UserResponse: + type: object + properties: + user: + $ref: '#/components/schemas/UserObject' + ValueOneOf1: + type: string + TriggerRevisionsResponseTriggerRevisions: + type: object + properties: + created_at: + type: string + x-ballerina-name: createdAt + diff: + $ref: '#/components/schemas/TriggerRevisionsResponseDiff' + id: + type: integer + author_id: + type: integer + x-ballerina-name: authorId + snapshot: + $ref: '#/components/schemas/TriggerSnapshotObject' + url: + type: string + CustomRoleConfigurationObject: + type: object + properties: + moderate_forums: + type: boolean + readOnly: true + x-ballerina-name: moderateForums + side_conversation_create: + type: boolean + description: Whether or not the agent can contribute to side conversations + x-ballerina-name: sideConversationCreate + voice_access: + type: boolean + description: Whether or not the agent can answer and place calls to end + users + x-ballerina-name: voiceAccess + user_view_access: + type: string + description: "What the agent can do with customer lists. Allowed values:\ + \ \"full\", \"manage-group\", \"manage-personal\", \"none\", \"readonly\"" + x-ballerina-name: userViewAccess + ticket_merge: + type: boolean + description: Whether or not the agent can merge tickets + x-ballerina-name: ticketMerge + light_agent: + type: boolean + readOnly: true + x-ballerina-name: lightAgent + ticket_access: + type: string + description: "What kind of tickets the agent can access. Allowed values:\ + \ \"all\", \"assigned-only\", \"within-groups\", \"within-groups-and-public-groups\"\ + , \"within-organization\"" + x-ballerina-name: ticketAccess + voice_dashboard_access: + type: boolean + description: Whether or not the agent can view details about calls on the + Talk dashboard + x-ballerina-name: voiceDashboardAccess + assign_tickets_to_any_group: + type: boolean + description: Whether or not the agent can assign tickets to any group + readOnly: true + x-ballerina-name: assignTicketsToAnyGroup + explore_access: + type: string + description: "Allowed values: \"edit\", \"full\", \"none\", \"readonly\"" + x-ballerina-name: exploreAccess + macro_access: + type: string + description: "What the agent can do with macros. Allowed values: \"full\"\ + , \"manage-group\", \"manage-personal\", \"readonly\"" + x-ballerina-name: macroAccess + organization_notes_editing: + type: boolean + description: Whether or not the agent can add or modify organization notes + readOnly: true + x-ballerina-name: organizationNotesEditing + view_deleted_tickets: + type: boolean + description: Whether or not the agent can view deleted tickets + x-ballerina-name: viewDeletedTickets + end_user_list_access: + type: string + description: "Whether or not the agent can view lists of user profiles.\ + \ Allowed values: \"full\", \"none\"" + x-ballerina-name: endUserListAccess + end_user_profile_access: + type: string + description: "What the agent can do with end-user profiles. Allowed values:\ + \ \"edit\", \"edit-within-org\", \"full\", \"readonly\"" + x-ballerina-name: endUserProfileAccess + manage_ticket_fields: + type: boolean + description: Whether or not the agent can create and manage ticket fields + x-ballerina-name: manageTicketFields + report_access: + type: string + description: "What the agent can do with reports. Allowed values: \"full\"\ + , \"none\", \"readonly\"" + x-ballerina-name: reportAccess + manage_dynamic_content: + type: boolean + description: Whether or not the agent can access dynamic content + x-ballerina-name: manageDynamicContent + forum_access: + type: string + description: "The kind of access the agent has to Guide. Allowed values:\ + \ \"edit-topics\", \"full\", \"readonly\"" + x-ballerina-name: forumAccess + ticket_comment_access: + type: string + description: "What type of comments the agent can make. Allowed values:\ + \ \"public\", \"none\"" + x-ballerina-name: ticketCommentAccess + twitter_search_access: + type: boolean + x-ballerina-name: twitterSearchAccess + forum_access_restricted_content: + type: boolean + x-ballerina-name: forumAccessRestrictedContent + group_access: + type: boolean + description: Whether or not the agent can add or modify groups + readOnly: true + x-ballerina-name: groupAccess + ticket_editing: + type: boolean + description: Whether or not the agent can edit ticket properties + x-ballerina-name: ticketEditing + manage_user_fields: + type: boolean + description: Whether or not the agent can create and manage user fields + x-ballerina-name: manageUserFields + manage_business_rules: + type: boolean + description: Whether or not the agent can manage business rules + x-ballerina-name: manageBusinessRules + manage_organization_fields: + type: boolean + description: Whether or not the agent can create and manage organization + fields + x-ballerina-name: manageOrganizationFields + ticket_deletion: + type: boolean + description: Whether or not the agent can delete tickets + x-ballerina-name: ticketDeletion + view_access: + type: string + description: "What the agent can do with views. Allowed values: \"full\"\ + , \"manage-group\", \"manage-personal\", \"playonly\", \"readonly\"" + x-ballerina-name: viewAccess + ticket_tag_editing: + type: boolean + description: Whether or not the agent can edit ticket tags + x-ballerina-name: ticketTagEditing + manage_facebook: + type: boolean + description: Whether or not the agent can manage Facebook pages + x-ballerina-name: manageFacebook + manage_contextual_workspaces: + type: boolean + description: "Whether or not the agent can view, add, and edit contextual\ + \ workspaces" + x-ballerina-name: manageContextualWorkspaces + manage_ticket_forms: + type: boolean + description: Whether or not the agent can create and manage ticket forms + x-ballerina-name: manageTicketForms + manage_extensions_and_channels: + type: boolean + description: Whether or not the agent can manage channels and extensions + x-ballerina-name: manageExtensionsAndChannels + organization_editing: + type: boolean + description: Whether or not the agent can add or modify organizations + x-ballerina-name: organizationEditing + chat_access: + type: boolean + description: Whether or not the agent has access to Chat + readOnly: true + x-ballerina-name: chatAccess + description: "Configuration settings for the role. See [Configuration](#configuration)" + SLAPolicyFilterDefinitionResponseDefinitions: + type: object + properties: + all: + type: array + items: + $ref: '#/components/schemas/SLAPolicyFilterDefinitionResponseDefinitionsAll' + any: + type: array + items: + $ref: '#/components/schemas/SLAPolicyFilterDefinitionResponseDefinitionsAll' + SLAPolicyResponse: + type: object + properties: + sla_policy: + allOf: + - $ref: '#/components/schemas/SLAPolicyObject' + x-ballerina-name: slaPolicy + GroupsCountObjectCount: + type: object + properties: + refreshed_at: + type: string + description: Timestamp that indicates when the count was last updated + format: date-time + readOnly: true + x-ballerina-name: refreshedAt + value: + type: integer + description: Approximate count of groups + readOnly: true + TriggerConditionDiffObject: + type: object + properties: + field: + type: array + description: "An array of [change](#change) objects" + items: + $ref: '#/components/schemas/TriggerChangeObject' + value: + type: array + description: "An array of [change](#change) objects" + items: + $ref: '#/components/schemas/TriggerChangeObject' + operator: + type: array + description: "An array of [change](#change) objects" + items: + $ref: '#/components/schemas/TriggerChangeObject' + example: + field: + - change: = + content: status + operator: + - change: = + content: less_than + value: + - change: "+" + content: solved + UserFieldsResponse: + type: object + properties: + next_page: + type: string + description: URL of the next page + nullable: true + readOnly: true + x-ballerina-name: nextPage + user_fields: + type: array + items: + $ref: '#/components/schemas/UserFieldObject' + x-ballerina-name: userFields + count: + type: integer + description: Total count of records retrieved + readOnly: true + previous_page: + type: string + description: URL of the previous page + nullable: true + readOnly: true + x-ballerina-name: previousPage + ViewsCountResponse: + type: object + properties: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + MacroInputRestriction: + type: object + properties: + id: + type: integer + description: The numeric ID of the group or user + ids: + type: array + description: The numeric IDs of the groups + items: + type: integer + type: + type: string + description: Allowed values are Group or User + additionalProperties: true + description: Who may access this macro. Will be null when everyone in the account + can access it + TicketMergeInput: + required: + - ids + type: object + properties: + source_comment_is_public: + type: boolean + description: Whether comment in source tickets are public or private + x-ballerina-name: sourceCommentIsPublic + target_comment_is_public: + type: boolean + description: Whether comment in target ticket is public or private + x-ballerina-name: targetCommentIsPublic + target_comment: + type: string + description: Private comment to add to the target ticket + x-ballerina-name: targetComment + ids: + type: array + description: Ids of tickets to merge into the target ticket + items: + type: integer + source_comment: + type: string + description: Private comment to add to the source ticket + x-ballerina-name: sourceComment + AssigneeFieldAssignableGroupObject: + title: AssigneeFieldAssignableGroups + type: object + properties: + name: + type: string + description: Name of the group + readOnly: true + description: + type: string + description: Description of the group + readOnly: true + id: + type: integer + description: Group ID + readOnly: true + example: + description: Engineering team for bugs + id: 9182736455 + name: Engineering + CustomFieldOptionResponse: + type: object + properties: + custom_field_option: + allOf: + - $ref: '#/components/schemas/CustomFieldOptionObject' + x-ballerina-name: customFieldOption + SLAPolicyMetricObject: + type: object + properties: + business_hours: + type: boolean + description: Whether the metric targets are being measured in business hours + or calendar hours + x-ballerina-name: businessHours + metric: + type: string + description: The definition of the time that is being measured + priority: + type: string + description: Priority that a ticket must match + target: + type: integer + description: The time within which the end-state for a metric should be + met + HostMappingObject: + title: Host Mapping + type: object + properties: + reason: + type: string + description: Reason why a host mapping is valid or not + expected_cnames: + type: array + description: Array of expected CNAME records for host mapping(s) of a given + brand + items: + type: string + x-ballerina-name: expectedCnames + is_valid: + type: boolean + description: Whether a host mapping is valid or not for a given brand + x-ballerina-name: isValid + cname: + type: string + description: The canonical name record for a host mapping + example: + cname: google.com + expected_cnames: + - bar.zendesk.coom + is_valid: false + reason: wrong_cname + AssigneeFieldAssignableSearchGroupObject: + type: object + properties: + name: + type: string + description: Name of the group + id: + type: integer + description: Group ID + example: + id: 9182736455 + name: Engineering + CustomObject: + required: + - key + - title + - title_pluralized + type: object + properties: + raw_title: + type: string + description: "The dynamic content placeholder, if present, or the \"title\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawTitle + title_pluralized: + type: string + description: User-defined pluralized version of the object's title + x-ballerina-name: titlePluralized + updated_at: + type: string + description: The time of the last update of the object + format: date-time + readOnly: true + x-ballerina-name: updatedAt + updated_by_user_id: + type: string + description: Id of the last user who updated the object + readOnly: true + x-ballerina-name: updatedByUserId + raw_title_pluralized: + type: string + description: "The dynamic content placeholder, if present, or the \"raw_title_pluralized\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawTitlePluralized + created_at: + type: string + description: The time the object type was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + description: + type: string + description: User-defined description of the object + title: + type: string + description: User-defined display name for the object + created_by_user_id: + type: string + description: Id of a user who created the object + readOnly: true + x-ballerina-name: createdByUserId + raw_description: + type: string + description: "The dynamic content placeholder, if present, or the \"raw_description\"\ + \ value, if not. See [Dynamic Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + x-ballerina-name: rawDescription + key: + type: string + description: A user-defined unique identifier. Writable on create only. + Cannot be reused if deleted + readOnly: true + url: + type: string + description: Direct link to the specific custom object + readOnly: true + TicketFieldResponse: + type: object + properties: + ticket_field: + allOf: + - $ref: '#/components/schemas/TicketFieldObject' + x-ballerina-name: ticketField + ViaObjectSourceTo: + type: object + properties: + address: + type: string + name: + type: string + BrandObject: + title: Brands + required: + - name + - subdomain + type: object + properties: + host_mapping: + type: string + description: "The hostmapping to this brand, if any. Only admins view this\ + \ property" + x-ballerina-name: hostMapping + ticket_form_ids: + type: array + description: The ids of ticket forms that are available for use by a brand + readOnly: true + items: + type: integer + x-ballerina-name: ticketFormIds + active: + type: boolean + description: If the brand is set as active + created_at: + type: string + description: The time the brand was created + format: date-time + readOnly: true + x-ballerina-name: createdAt + help_center_state: + type: string + description: The state of the Help Center + readOnly: true + enum: + - enabled + - disabled + - restricted + x-ballerina-name: helpCenterState + url: + type: string + description: The API url of this brand + readOnly: true + brand_url: + type: string + description: The url of the brand + x-ballerina-name: brandUrl + default: + type: boolean + description: Is the brand the default brand for this account + has_help_center: + type: boolean + description: If the brand has a Help Center + x-ballerina-name: hasHelpCenter + is_deleted: + type: boolean + description: If the brand object is deleted or not + x-ballerina-name: isDeleted + updated_at: + type: string + description: The time of the last update of the brand + format: date-time + readOnly: true + x-ballerina-name: updatedAt + signature_template: + type: string + description: The signature template for a brand + x-ballerina-name: signatureTemplate + name: + type: string + description: The name of the brand + logo: + $ref: '#/components/schemas/AttachmentObject' + subdomain: + type: string + description: The subdomain of the brand + id: + type: integer + description: The ID automatically assigned when the brand is created + readOnly: true + example: + active: true + brand_url: https://brand1.com + created_at: 2012-04-02T22:55:29Z + default: true + has_help_center: true + help_center_state: enabled + host_mapping: brand1.com + id: 47 + logo: + content_type: image/png + content_url: https://company.zendesk.com/logos/brand1_logo.png + file_name: brand1_logo.png + id: 928374 + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png + file_name: brand1_logo_thumb.png + id: 928375 + mapped_content_url: https://company.com/photos/brand1_logo_thumb.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928375.json + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_small.png + file_name: brand1_logo_small.png + id: 928376 + mapped_content_url: https://company.com/photos/brand1_logo_small.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928376.json + url: https://company.zendesk.com/api/v2/attachments/928374.json + name: Brand 1 + signature_template: "{{agent.signature}}" + subdomain: brand1 + ticket_form_ids: + - 47 + - 33 + - 22 + updated_at: 2012-04-02T22:55:29Z + url: https://company.zendesk.com/api/v2/brands/47.json + AccountSettingsAppsObject: + type: object + properties: + create_public: + type: boolean + x-ballerina-name: createPublic + create_private: + type: boolean + x-ballerina-name: createPrivate + use: + type: boolean + description: "Apps configuration options. See [Apps](#apps)" + TargetURL: + required: + - attribute + - target_url + type: object + properties: + password: + type: string + description: only writable + method: + type: string + description: '"get"' + target_url: + type: string + x-ballerina-name: targetUrl + attribute: + type: string + username: + type: string + ViewCountResponse: + type: object + properties: + view_count: + allOf: + - $ref: '#/components/schemas/ViewCountObject' + x-ballerina-name: viewCount + CursorBasedExportIncrementalTicketsResponse: + type: object + properties: + before_url: + type: string + nullable: true + x-ballerina-name: beforeUrl + end_of_stream: + type: boolean + x-ballerina-name: endOfStream + tickets: + type: array + items: + $ref: '#/components/schemas/TicketObject' + after_cursor: + type: string + nullable: true + x-ballerina-name: afterCursor + after_url: + type: string + nullable: true + x-ballerina-name: afterUrl + before_cursor: + type: string + nullable: true + x-ballerina-name: beforeCursor + description: | + See [Tickets](/api-reference/ticketing/tickets/tickets/) for a detailed example + example: + after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 + after_url: "https://{subdomain}.zendesk.com/api/v2/incremental/tickets/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8" + before_cursor: null + before_url: null + end_of_stream: true + tickets: + - assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + OrganizationSubscriptionCreateRequest: + type: object + properties: + organization_subscription: + allOf: + - $ref: '#/components/schemas/OrganizationSubscriptionInput' + x-ballerina-name: organizationSubscription + TargetJira: + required: + - password + - target_url + - username + type: object + properties: + password: + type: string + description: only writable + target_url: + type: string + x-ballerina-name: targetUrl + username: + type: string + IncrementalSkillBasedRoutingAttributeValue: + type: object + properties: + attribute_id: + type: string + description: Id of the associated attribute + readOnly: true + x-ballerina-name: attributeId + name: + type: string + description: The name of the attribute value + readOnly: true + id: + type: string + description: Automatically assigned when an attribute value is created + readOnly: true + time: + type: string + description: "The time the attribute value was created, updated, or deleted" + format: date-time + readOnly: true + type: + type: string + description: "One of \"create\", \"update\", or \"delete\"" + readOnly: true + ActivitiesCountResponse: + type: object + properties: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + TicketFieldCountResponse: + type: object + properties: + count: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + TicketImportRequest: + type: object + properties: + ticket: + $ref: '#/components/schemas/TicketImportInput' + BulkUpdateDefaultCustomStatusRequest: + type: object + properties: + ids: + type: string + description: The comma-separated list of custom ticket status ids to be + set as default for their status categories + UserIdentityResponse: + type: object + properties: + identity: + $ref: '#/components/schemas/UserIdentityObject' + MacroInput: + required: + - actions + - title + type: object + properties: + restriction: + description: Who may access this macro. Will be null when everyone in the + account can access it + allOf: + - $ref: '#/components/schemas/MacroInputRestriction' + active: + type: boolean + description: Useful for determining if the macro should be displayed + description: + type: string + description: The description of the macro + nullable: true + title: + type: string + description: The title of the macro + actions: + type: array + description: Each action describes what the macro will do + items: + $ref: '#/components/schemas/ActionObject' + TicketChatCommentRedactionResponse: + type: object + properties: + chat_event: + description: Chat event object + allOf: + - $ref: '#/components/schemas/TicketChatCommentRedactionResponseChatEvent' + x-ballerina-name: chatEvent + example: + chat_event: + id: 1932802680168 + type: ChatStartedEvent + value: + chat_id: 2109.10502823.Sjuj2YrBpXwei + history: + - actor_id: 1900448983828 + actor_name: Visitor 36044085 + actor_type: end-user + chat_index: 0 + timestamp: 1632470783218 + type: ChatJoin + visitor_id: 10502823-16EkM3T6VNq7KMd + TriggerBatchRequest: + required: + - id + type: object + properties: + category_id: + type: string + x-ballerina-name: categoryId + active: + type: boolean + id: + type: string + position: + type: integer + format: int64 + ViaObjectSource: + type: object + properties: + from: + $ref: '#/components/schemas/ViaObjectSourceFrom' + rel: + type: string + nullable: true + to: + $ref: '#/components/schemas/ViaObjectSourceTo' + additionalProperties: true + description: | + For some channels a source object gives more information about how or why the ticket or event was created + CustomObjectRecordResponse: + type: object + properties: + custom_object_record: + allOf: + - $ref: '#/components/schemas/CustomObjectRecord' + x-ballerina-name: customObjectRecord + OrganizationSubscriptionInput: + type: object + properties: + user_id: + type: integer + description: The ID of the user + x-ballerina-name: userId + organization_id: + type: integer + description: The ID of the organization + x-ballerina-name: organizationId + SkillBasedRoutingAttributeValuesResponse: + type: object + properties: + attribute_values: + type: array + items: + $ref: '#/components/schemas/SkillBasedRoutingAttributeValueObject' + x-ballerina-name: attributeValues + TargetClickatell: + required: + - api_id + - password + - to + - username + type: object + properties: + api_id: + type: string + x-ballerina-name: apiId + us_small_business_account: + type: string + x-ballerina-name: usSmallBusinessAccount + password: + type: string + description: only writable + method: + type: string + description: Read-only + target_url: + type: string + description: Read-only + x-ballerina-name: targetUrl + from: + type: string + attribute: + type: string + description: Read-only + to: + type: string + username: + type: string + TriggerObject: + required: + - actions + - conditions + - title + type: object + properties: + raw_title: + type: string + description: The raw format of the title of the trigger + x-ballerina-name: rawTitle + active: + type: boolean + description: Whether the trigger is active + created_at: + type: string + description: The time the trigger was created + readOnly: true + x-ballerina-name: createdAt + description: + type: string + description: The description of the trigger + title: + type: string + description: The title of the trigger + url: + type: string + description: The url of the trigger + readOnly: true + default: + type: boolean + description: "If true, the trigger is a default trigger" + readOnly: true + category_id: + type: string + description: The ID of the category the trigger belongs to + x-ballerina-name: categoryId + updated_at: + type: string + description: The time of the last update of the trigger + readOnly: true + x-ballerina-name: updatedAt + id: + type: integer + description: Automatically assigned when created + readOnly: true + position: + type: integer + description: "Position of the trigger, determines the order they will execute\ + \ in" + conditions: + $ref: '#/components/schemas/TriggerConditionsObject' + actions: + type: array + description: "An array of actions describing what the trigger will do. See\ + \ [Actions reference](/documentation/ticketing/reference-guides/actions-reference)" + items: + $ref: '#/components/schemas/TriggerActionObject' + example: + actions: + - {} + active: true + category_id: "10026" + conditions: {} + created_at: 2012-09-25T22:50:26Z + default: false + description: Close and save a ticket + id: 25 + position: 8 + raw_title: Close and Save + title: Close and Save + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/25.json" + TicketUpdateResponse: + type: object + properties: + ticket: + $ref: '#/components/schemas/TicketObject' + audit: + $ref: '#/components/schemas/AuditObject' + UserCreateInput: + required: + - email + - name + type: object + properties: + identities: + type: array + items: + $ref: '#/components/schemas/UserCreateInputIdentities' + role: + type: string + custom_role_id: + type: integer + x-ballerina-name: customRoleId + organization: + $ref: '#/components/schemas/UserCreateInputOrganization' + organization_id: + type: integer + x-ballerina-name: organizationId + name: + type: string + external_id: + type: string + x-ballerina-name: externalId + email: + type: string + TargetFlowdock: + required: + - api_token + type: object + properties: + api_token: + type: string + x-ballerina-name: apiToken + AccountSettingsObject: + type: object + properties: + localization: + $ref: '#/components/schemas/AccountSettingsLocalizationObject' + voice: + $ref: '#/components/schemas/AccountSettingsVoiceObject' + side_conversations: + allOf: + - $ref: '#/components/schemas/AccountSettingsSideConversationsObject' + x-ballerina-name: sideConversations tickets: - - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - group_id: 98738 - has_incidents: false - id: 35436 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - TimeBasedExportIncrementalUsersResponse: + $ref: '#/components/schemas/AccountSettingsTicketObject' + branding: + $ref: '#/components/schemas/AccountSettingsBrandingObject' + lotus: + $ref: '#/components/schemas/AccountSettingsLotusObject' + rule: + $ref: '#/components/schemas/AccountSettingsRuleObject' + gooddata_advanced_analytics: + allOf: + - $ref: '#/components/schemas/AccountSettingsGooddataAdvancedAnalyticsObject' + x-ballerina-name: gooddataAdvancedAnalytics + active_features: + allOf: + - $ref: '#/components/schemas/AccountSettingsActiveFeaturesObject' + x-ballerina-name: activeFeatures + billing: + $ref: '#/components/schemas/AccountSettingsBillingObject' + ticket_form: + allOf: + - $ref: '#/components/schemas/AccountSettingsTicketFormObject' + x-ballerina-name: ticketForm + routing: + $ref: '#/components/schemas/AccountSettingsRoutingObject' + twitter: + $ref: '#/components/schemas/AccountSettingsTwitterObject' + onboarding: + $ref: '#/components/schemas/AccountSettingsOnboardingObject' + api: + $ref: '#/components/schemas/AccountSettingsApiObject' + limits: + $ref: '#/components/schemas/AccountSettingsLimitsObject' + apps: + $ref: '#/components/schemas/AccountSettingsAppsObject' + brands: + $ref: '#/components/schemas/AccountSettingsBrandsObject' + groups: + $ref: '#/components/schemas/AccountSettingsGroupObject' + cdn: + $ref: '#/components/schemas/AccountSettingsCdnObject' + cross_sell: + allOf: + - $ref: '#/components/schemas/AccountSettingsCrossSellObject' + x-ballerina-name: crossSell + agents: + $ref: '#/components/schemas/AccountSettingsAgentObject' + chat: + $ref: '#/components/schemas/AccountSettingsChatObject' + ticket_sharing_partners: + allOf: + - $ref: '#/components/schemas/AccountSettingsTicketSharingPartnersObject' + x-ballerina-name: ticketSharingPartners + metrics: + $ref: '#/components/schemas/AccountSettingsMetricsObject' + google_apps: + allOf: + - $ref: '#/components/schemas/AccountSettingsGoogleAppsObject' + x-ballerina-name: googleApps + user: + $ref: '#/components/schemas/AccountSettingsUserObject' + statistics: + $ref: '#/components/schemas/AccountSettingsStatisticsObject' + example: + active_features: + advanced_analytics: false + agent_forwarding: false + allow_ccs: true + allow_email_template_customization: true + automatic_answers: false + bcc_archiving: false + benchmark_opt_out: false + business_hours: false + chat: false + chat_about_my_ticket: false + csat_reason_code: false + custom_dkim_domain: true + customer_context_as_default: false + customer_satisfaction: false + dynamic_contents: false + explore: true + explore_on_support_ent_plan: false + explore_on_support_pro_plan: false + facebook: false + facebook_login: false + fallback_composer: false + forum_analytics: true + good_data_and_explore: false + google_login: false + insights: false + is_abusive: false + light_agents: false + markdown: false + on_hold_status: false + organization_access_enabled: true + rich_content_in_emails: true + sandbox: false + satisfaction_prediction: false + suspended_ticket_notification: false + ticket_forms: true + ticket_tagging: true + topic_suggestion: false + twitter: true + twitter_login: false + user_org_fields: true + user_tagging: true + voice: true + agents: + agent_home: false + agent_workspace: false + aw_self_serve_migration_enabled: true + focus_mode: false + idle_timeout_enabled: false + unified_agent_statuses: false + api: + accepted_api_agreement: true + api_password_access: "true" + api_token_access: "true" + apps: + create_private: true + create_public: false + use: true + billing: + backend: zuora + branding: + favicon_url: null + header_color: 78A300 + header_logo_url: null + page_background_color: "333333" + tab_background_color: 7FA239 + text_color: FFFFFF + brands: + default_brand_id: 1873 + require_brand_on_new_tickets: false + cdn: + cdn_provider: default + fallback_cdn_provider: cloudfront + hosts: + - name: default + url: https://p18.zdassets.com + - name: cloudfront + url: https://d2y9oszrd3dhjh.cloudfront.net + chat: + available: true + enabled: false + integrated: true + maximum_request_count: 1 + welcome_message: Hi there. How can I help today? + cross_sell: + show_chat_tooltip: true + xsell_source: null + gooddata_advanced_analytics: + enabled: true + google_apps: + has_google_apps: false + has_google_apps_admin: false + groups: + check_group_name_uniqueness: true + limits: + attachment_size: 52428800 + localization: + locale_ids: + - 1042 + lotus: + pod_id: 999 + prefer_lotus: true + reporting: true + metrics: + account_size: 100-399 + onboarding: + checklist_onboarding_version: 2 + onboarding_segments: null + product_sign_up: null + routing: + autorouting_tag: "" + enabled: false + max_email_capacity: 0 + max_messaging_capacity: 0 + reassignment_messaging_enabled: true + reassignment_messaging_timeout: 30 + reassignment_talk_timeout: 30 + rule: + macro_most_used: true + macro_order: alphabetical + skill_based_filtered_views: [] + using_skill_based_routing: false + side_conversations: + email_channel: false + msteams_channel: false + show_in_context_panel: false + slack_channel: false + tickets_channel: false + statistics: + forum: true + rule_usage: true + search: true + ticket_form: + raw_ticket_forms_instructions: Please choose your issue below + ticket_forms_instructions: Please choose your issue below + ticket_sharing_partners: + support_addresses: + - support@grokpetre.zendesk.com + tickets: + accepted_new_collaboration_tos: false + agent_collision: true + agent_invitation_enabled: true + agent_ticket_deletion: false + allow_group_reset: true + assign_default_organization: true + assign_tickets_upon_solve: true + auto_translation_enabled: false + auto_updated_ccs_followers_rules: false + chat_sla_enablement: false + collaboration: true + comments_public_by_default: true + email_attachments: false + emoji_autocompletion: true + follower_and_email_cc_collaborations: false + has_color_text: true + is_first_comment_private_enabled: true + light_agent_email_ccs_allowed: false + list_empty_views: true + list_newest_comments_first: true + markdown_ticket_comments: false + maximum_personal_views_to_list: 8 + private_attachments: false + rich_text_comments: true + status_hold: false + tagging: true + using_skill_based_routing: false + twitter: + shorten_url: optional + user: + agent_created_welcome_emails: true + end_user_phone_number_validation: false + have_gravatars_enabled: true + language_selection: true + multiple_organizations: false + tagging: true + time_zone_selection: true + voice: + agent_confirmation_when_forwarding: true + agent_wrap_up_after_calls: true + enabled: true + logging: true + maximum_queue_size: 5 + maximum_queue_wait_time: 1 + only_during_business_hours: false + outbound_enabled: true + recordings_public: true + uk_mobile_forwarding: true + BrandsResponse: + title: Brands + type: object + allOf: + - $ref: '#/components/schemas/OffsetPaginationObject' + - $ref: '#/components/schemas/BrandsResponseAllOf2' + TagsResponse: type: object properties: - count: - type: integer - end_of_stream: - type: boolean - end_time: - type: integer next_page: type: string + description: The url of the previous page nullable: true - users: - type: array - items: - $ref: '#/components/schemas/UserObject' - example: - count: 1 - end_of_stream: true - end_time: 1601357503 - next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 - users: - - active: true - alias: Mr. Johnny - created_at: "2009-07-20T22:55:29Z" - custom_role_id: 9373643 - details: "" - email: johnny@example.com - external_id: sai989sur98w9 - id: 35436 - last_login_at: "2011-05-05T10:38:52Z" - locale: en-US - locale_id: 1 - moderator: true - name: Johnny Agent - notes: Johnny is a nice guy! - only_private_comments: false - organization_id: 57542 - phone: "+15551234567" - photo: - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png - id: 928374 - name: my_funny_profile_pic.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png - id: 928375 - name: my_funny_profile_pic_thumb.png - size: 58298 - restricted_agent: true - role: agent - role_type: 0 - shared: false - shared_agent: false - signature: Have a nice day, Johnny - suspended: true - tags: - - enterprise - - other_tag - ticket_restriction: assigned - time_zone: Copenhagen - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/users/35436.json - user_fields: - user_date: "2012-07-23T00:00:00Z" - user_decimal: 5.1 - user_dropdown: option_1 - verified: true - TrialAccountObject: - type: object - properties: - name: - type: string - description: The name of the account - subdomain: - type: string - description: The subdomain of the account - url: - type: string - description: The URL of the account - TrialAccountResponse: - type: object - properties: - account: - $ref: '#/components/schemas/TrialAccountObject' - TriggerActionDefinitionObject: - type: object - properties: - group: - type: string - nullable: - type: boolean - repeatable: - type: boolean - subject: - type: string - title: - type: string - type: - type: string - values: - type: array - items: - type: object - properties: - enabled: - type: boolean - title: - type: string - value: - type: string - TriggerActionDiffObject: - type: object - properties: - field: - type: array - description: An array of [change](#change) objects. - items: - $ref: '#/components/schemas/TriggerChangeObject' - value: - type: array - description: An array of [change](#change) objects. - items: - $ref: '#/components/schemas/TriggerChangeObject' - example: - field: - - change: + - content: solved - value: - - change: '-' - content: open - TriggerActionObject: - type: object - properties: - field: - type: string - value: - oneOf: - - type: string - - type: integer - - type: array - items: - oneOf: - - type: string - - type: integer - example: - field: status - value: solved - TriggerBatchRequest: - type: object - properties: - active: - type: boolean - category_id: - type: string - id: - type: string - position: - type: integer - format: int64 - required: - - id - TriggerBulkUpdateItem: - type: object - properties: - active: - type: boolean - description: The active status of the trigger (true or false) - category_id: - type: string - description: The ID of the new category the trigger is to be moved to - id: - type: integer - description: The ID of the trigger to update - position: - type: integer - description: The new position of the trigger - example: - active: true - category_id: "10026" - id: 25 - position: 8 - required: - - id - TriggerBulkUpdateRequest: - type: object - properties: - triggers: - type: array - items: - $ref: '#/components/schemas/TriggerBulkUpdateItem' - TriggerCategoriesResponse: - type: object - properties: - trigger_categories: - type: array - items: - type: object - anyOf: - - $ref: '#/components/schemas/TriggerCategoryRuleCounts' - allOf: - - $ref: '#/components/schemas/TriggerCategory' - TriggerCategory: - type: object - properties: - created_at: - type: string readOnly: true - id: - type: string - readOnly: true - name: - type: string - position: + x-ballerina-name: nextPage + count: type: integer - format: int64 - updated_at: - type: string + description: The number of pages readOnly: true - TriggerCategoryBatchRequest: - type: object - properties: - id: - type: string - position: - type: integer - format: int64 - required: - - id - - position - TriggerCategoryId: - type: string - TriggerCategoryRequest: - type: object - properties: - name: - type: string - position: - type: integer - format: int64 - TriggerCategoryRequestRequired: - type: object - required: - - name - TriggerCategoryResponse: - type: object - properties: - trigger_category: - $ref: '#/components/schemas/TriggerCategory' - TriggerCategoryRuleCounts: - type: object - properties: - active_count: - type: integer - format: int64 - inactive_count: - type: integer - format: int64 - TriggerChangeObject: - type: object - properties: - change: - type: string - description: One of `-`, `+`, `=` representing the type of change - content: - description: The value of the item it represents - oneOf: - - type: boolean - - type: string - - type: integer - - type: array - items: - oneOf: - - type: string - - type: integer - - type: boolean - example: - change: + - content: solved - TriggerConditionDefinitionObjectAll: - type: object - properties: - group: - type: string - nullable: - type: boolean - operators: - type: array - items: - type: object - properties: - terminal: - type: boolean - title: - type: string - value: - type: string - repeatable: - type: boolean - subject: - type: string - title: - type: string - type: + previous_page: type: string - values: + description: The url of the next page + nullable: true + readOnly: true + x-ballerina-name: previousPage + tags: type: array items: - type: object - properties: - enabled: - type: boolean - title: - type: string - value: - type: string - TriggerConditionDefinitionObjectAny: + $ref: '#/components/schemas/TagListTagObject' + EssentialsCardsResponse: type: object properties: - group: - type: string - nullable: - type: boolean - operators: + object_layouts: type: array items: - type: object - properties: - terminal: - type: boolean - title: - type: string - value: - type: string - repeatable: - type: boolean - subject: - type: string - title: - type: string - type: - type: string - TriggerConditionDiffObject: + $ref: '#/components/schemas/EssentialsCardObject' + x-ballerina-name: objectLayouts + QueueObjectSecondaryGroups: type: object properties: - field: - type: array - description: An array of [change](#change) objects - items: - $ref: '#/components/schemas/TriggerChangeObject' - operator: + count: + type: integer + groups: type: array - description: An array of [change](#change) objects items: - $ref: '#/components/schemas/TriggerChangeObject' - value: + $ref: '#/components/schemas/ListDeletedTicketsResponseActor' + description: Secondary group ids linked to the queue + CustomObjectFieldResponse: + type: object + properties: + custom_object_field: + allOf: + - $ref: '#/components/schemas/CustomObjectField' + x-ballerina-name: customObjectField + TicketMetricEventsResponse: + type: object + allOf: + - $ref: '#/components/schemas/TicketMetricEventsResponseAllOf1' + - $ref: '#/components/schemas/TicketMetricEventsResponseTicketMetricEventsResponseAllOf12' + BatchJobResponse: + type: object + properties: + results: + $ref: '#/components/schemas/BatchJobResponseResults' + errors: type: array - description: An array of [change](#change) objects items: - $ref: '#/components/schemas/TriggerChangeObject' - example: - field: - - change: = - content: status - operator: - - change: = - content: less_than - value: - - change: + - content: solved - TriggerConditionObject: + $ref: '#/components/schemas/BatchErrorItem' + status: + type: string + enum: + - complete + - failed + GroupSLAPolicyResponse: type: object properties: - field: + group_sla_policy: + allOf: + - $ref: '#/components/schemas/GroupSLAPolicyObject' + x-ballerina-name: groupSlaPolicy + MacroApplyTicketResponse: + type: object + properties: + result: + $ref: '#/components/schemas/MacroApplyTicketResponseResult' + TargetBasecamp: + required: + - project_id + - resource + - target_url + - token + type: object + properties: + password: type: string - operator: + description: The 37Signals password for the Basecamp account (only writable) + project_id: type: string - value: - oneOf: - - type: string - - type: integer - - type: array - items: - oneOf: - - type: string - - type: integer - example: - field: status - operator: less_than - value: solved - TriggerConditionsDiffObject: + description: The ID of the project in Basecamp where updates should be pushed + x-ballerina-name: projectId + resource: + type: string + description: '"todo" or "message"' + target_url: + type: string + description: "The URL of your Basecamp account, including protocol and path" + x-ballerina-name: targetUrl + message_id: + type: string + description: Can be filled if it is a "message" resource + x-ballerina-name: messageId + todo_list_id: + type: string + description: Can be filled if it is a "todo" resource + x-ballerina-name: todoListId + token: + type: string + description: Get the API token from My info > Show your tokens > Token for + feed readers or the Basecamp API in your Basecamp account + username: + type: string + description: The 37Signals username of the account you use to log in to + Basecamp + TimeBasedExportIncrementalUsersResponse: type: object properties: - all: - type: array - items: - $ref: '#/components/schemas/TriggerConditionDiffObject' + next_page: + type: string nullable: true - any: + x-ballerina-name: nextPage + end_of_stream: + type: boolean + x-ballerina-name: endOfStream + count: + type: integer + end_time: + type: integer + x-ballerina-name: endTime + users: type: array items: - $ref: '#/components/schemas/TriggerConditionDiffObject' - nullable: true - TriggerConditionsObject: + $ref: '#/components/schemas/UserObject' + example: + count: 1 + end_of_stream: true + end_time: 1601357503 + next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 + users: + - active: true + alias: Mr. Johnny + created_at: 2009-07-20T22:55:29Z + custom_role_id: 9373643 + details: "" + email: johnny@example.com + external_id: sai989sur98w9 + id: 35436 + last_login_at: 2011-05-05T10:38:52Z + locale: en-US + locale_id: 1 + moderator: true + name: Johnny Agent + notes: Johnny is a nice guy! + only_private_comments: false + organization_id: 57542 + phone: "+15551234567" + photo: + content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png + id: 928374 + name: my_funny_profile_pic.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png + id: 928375 + name: my_funny_profile_pic_thumb.png + size: 58298 + restricted_agent: true + role: agent + role_type: 0 + shared: false + shared_agent: false + signature: "Have a nice day, Johnny" + suspended: true + tags: + - enterprise + - other_tag + ticket_restriction: assigned + time_zone: Copenhagen + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/users/35436.json + user_fields: + user_date: 2012-07-23T00:00:00Z + user_decimal: 5.1 + user_dropdown: option_1 + verified: true + ExportIncrementalTicketEventsResponse: type: object - description: An object that describes the conditions under which the trigger will execute. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) properties: - all: - type: array - items: - $ref: '#/components/schemas/TriggerConditionObject' + next_page: + type: string nullable: true - any: + x-ballerina-name: nextPage + end_of_stream: + type: boolean + x-ballerina-name: endOfStream + ticket_events: type: array items: - $ref: '#/components/schemas/TriggerConditionObject' - nullable: true + $ref: '#/components/schemas/TicketMetricEventBaseObject' + x-ballerina-name: ticketEvents + count: + type: integer + end_time: + type: integer + x-ballerina-name: endTime example: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - - field: custom_status_id - operator: includes - value: - - "1" - - "2" - any: - - field: status - operator: less_than - value: solved - - field: custom_status_id - operator: includes - value: - - "1" - - "2" - TriggerDefinitionObject: + count: 1 + end_of_stream: true + end_time: 1601357503 + next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 + ticket_events: + - id: 926256957613 + instance_id: 1 + metric: agent_work_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: measure + TargetFailureObject: + type: object + properties: + raw_request: + type: string + description: The raw message of the target request + readOnly: true + x-ballerina-name: rawRequest + status_code: + type: integer + description: HTTP status code of the target failure + readOnly: true + x-ballerina-name: statusCode + target_name: + type: string + description: Name of the target failure + readOnly: true + x-ballerina-name: targetName + created_at: + type: string + description: Time of the failure + format: date-time + readOnly: true + x-ballerina-name: createdAt + consecutive_failure_count: + type: integer + description: Number of times the target failed consecutively + readOnly: true + x-ballerina-name: consecutiveFailureCount + id: + type: integer + description: The ID of the target failure + readOnly: true + raw_response: + type: string + description: The raw response of the failure + readOnly: true + x-ballerina-name: rawResponse + url: + type: string + description: The API url of the failure record + readOnly: true + example: + consecutive_failure_count: 1 + created_at: 2017-09-05T10:38:52Z + id: 6001326 + raw_request: "GET /api/v2/tickets.json HTTP/1.1\r\nUser-Agent: Zendesk Target\r\ + \n ..." + raw_response: "HTTP/1.1 401 Unauthorized\r\nServer: nginx\r\n ..." + status_code: 401 + target_name: My URL Target + url: https://example.zendesk.com/api/v2/target_failures/6001326.json + TargetPivotal: + required: + - project_id + - story_title + - story_type + - token + type: object + properties: + story_type: + type: string + x-ballerina-name: storyType + owner_by: + type: string + x-ballerina-name: ownerBy + requested_by: + type: string + x-ballerina-name: requestedBy + project_id: + type: string + x-ballerina-name: projectId + story_title: + type: string + x-ballerina-name: storyTitle + story_labels: + type: string + x-ballerina-name: storyLabels + token: + type: string + CustomObjectCreateInput: type: object properties: - actions: - type: array - items: - $ref: '#/components/schemas/TriggerActionDefinitionObject' - conditions_all: + title_pluralized: + type: string + description: Pluralized version of the object's title + x-ballerina-name: titlePluralized + title: + type: string + description: Display name for the object + key: + type: string + description: Unique identifier. Writable on create only + TriggerActionDiffObject: + type: object + properties: + field: type: array + description: "An array of [change](#change) objects" items: - $ref: '#/components/schemas/TriggerConditionDefinitionObjectAll' - conditions_any: + $ref: '#/components/schemas/TriggerChangeObject' + value: type: array + description: "An array of [change](#change) objects" items: - $ref: '#/components/schemas/TriggerConditionDefinitionObjectAny' - TriggerDefinitionResponse: - type: object - properties: - definitions: - $ref: '#/components/schemas/TriggerDefinitionObject' - TriggerObject: + $ref: '#/components/schemas/TriggerChangeObject' + example: + field: + - change: "+" + content: solved + value: + - change: "-" + content: open + CustomFieldOptionObject: + required: + - name + - value type: object properties: - actions: - type: array - description: An array of actions describing what the trigger will do. See [Actions reference](/documentation/ticketing/reference-guides/actions-reference) - items: - $ref: '#/components/schemas/TriggerActionObject' - active: - type: boolean - description: Whether the trigger is active - category_id: - type: string - description: The ID of the category the trigger belongs to - conditions: - $ref: '#/components/schemas/TriggerConditionsObject' - created_at: + raw_name: type: string - description: The time the trigger was created - readOnly: true - default: - type: boolean - description: If true, the trigger is a default trigger + description: Raw name of the dropdown option readOnly: true - description: + x-ballerina-name: rawName + name: type: string - description: The description of the trigger + description: Name of the dropdown option id: type: integer - description: Automatically assigned when created + description: Automatically assigned upon creation readOnly: true position: type: integer - description: Position of the trigger, determines the order they will execute in - raw_title: - type: string - description: The raw format of the title of the trigger - title: - type: string - description: The title of the trigger - updated_at: + description: Position of the dropdown option + value: type: string - description: The time of the last update of the trigger - readOnly: true + description: Value of the dropdown option url: type: string - description: The url of the trigger + description: URL of the dropdown option readOnly: true - example: - actions: - - {} - active: true - category_id: "10026" - conditions: {} - created_at: "2012-09-25T22:50:26Z" - default: false - description: Close and save a ticket - id: 25 - position: 8 - raw_title: Close and Save - title: Close and Save - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/25.json - required: - - conditions - - actions - - title - TriggerResponse: - type: object - properties: - trigger: - $ref: '#/components/schemas/TriggerObject' - TriggerRevisionResponse: + BookmarkCreateRequest: type: object properties: - trigger_revision: - type: object - properties: - author_id: - type: integer - created_at: - type: string - id: - type: integer - snapshot: - type: object - properties: - actions: - type: array - items: - $ref: '#/components/schemas/TriggerActionObject' - active: - type: boolean - conditions: - $ref: '#/components/schemas/TriggerConditionsObject' - description: - type: string - nullable: true - title: - type: string - url: - type: string - TriggerRevisionsResponse: + bookmark: + $ref: '#/components/schemas/BookmarkInput' + TicketFormsResponse: type: object properties: - after_cursor: - type: string - after_url: - type: string - before_cursor: - type: string - before_url: - type: string - count: - type: integer - trigger_revisions: + ticket_forms: type: array items: - type: object - properties: - author_id: - type: integer - created_at: - type: string - diff: - type: object - properties: - actions: - type: array - description: An array that contain [action diff objects](#Action Diffs) - items: - $ref: '#/components/schemas/TriggerActionDiffObject' - active: - type: array - description: An array of [change](#change) objects - items: - $ref: '#/components/schemas/TriggerChangeObject' - conditions: - $ref: '#/components/schemas/TriggerConditionDiffObject' - description: - type: array - description: An array of [change](#change) objects - items: - $ref: '#/components/schemas/TriggerChangeObject' - source_id: - type: integer - description: ID of the source revision - target_id: - type: integer - description: ID of the target revision - title: - type: array - description: An array of [change](#change) objects - items: - $ref: '#/components/schemas/TriggerChangeObject' - id: - type: integer - snapshot: - $ref: '#/components/schemas/TriggerSnapshotObject' - url: - type: string - TriggerSnapshotObject: + $ref: '#/components/schemas/TicketFormObject' + x-ballerina-name: ticketForms + SuspendedTicketsExportResponseExport: type: object properties: - actions: - type: array - description: An array of [Actions](#actions) describing what the trigger will do - items: - $ref: '#/components/schemas/TriggerActionObject' - active: - type: boolean - description: Whether the trigger is active - conditions: - $ref: '#/components/schemas/TriggerConditionsObject' - description: + view_id: type: string - description: The description of the trigger - nullable: true - title: + readOnly: true + x-ballerina-name: viewId + status: type: string - description: The title of the trigger - example: - actions: [] - active: true - conditions: {} - description: Notifies requester that a comment was updated - title: Notify requester of comment update - TriggerWithCategoryRequest: + readOnly: true + SharingAgreementsResponse: type: object properties: - trigger: - allOf: - - $ref: '#/components/schemas/TriggerObject' - # Todo: Enable - # - anyOf: - # - $ref: '#/components/schemas/TriggerCategory' - # - $ref: '#/components/schemas/TriggerCategoryId' - TriggersResponse: + sharing_agreements: + type: array + items: + $ref: '#/components/schemas/SharingAgreementObject' + x-ballerina-name: sharingAgreements + SatisfactionReasonResponse: type: object properties: - count: - type: integer - next_page: - type: string - nullable: true - previous_page: - type: string - nullable: true - triggers: + reason: type: array items: - $ref: '#/components/schemas/TriggerObject' - TwitterChannelObject: - title: Monitored Twitter handles + $ref: '#/components/schemas/SatisfactionReasonObject' + BookmarkObject: + title: Bookmarks type: object properties: - allow_reply: - type: boolean - description: If replies are allowed for this handle + ticket: + type: object readOnly: true - avatar_url: + allOf: + - $ref: '#/components/schemas/TicketObject' + created_at: type: string - description: The profile image url of the handle + description: The time the bookmark was created + format: date-time readOnly: true - brand_id: + x-ballerina-name: createdAt + id: type: integer - description: What brand the handle is associated with + description: Automatically assigned when the bookmark is created readOnly: true - can_reply: - type: boolean - description: If replies are allowed for this handle + url: + type: string + description: The API url of this bookmark readOnly: true + example: + created_at: 2014-11-20T22:55:29Z + id: 35436 + ticket: + description: The fire is very colorful. + id: 60 + priority: high + requester_id: 156 + subject: "Help, my printer is on fire!" + url: "https://{subdomain}.zendesk.com/api/v2/bookmarks/35436.json" + CustomStatusObject: + required: + - agent_label + - status_category + type: object + properties: + end_user_description: + type: string + description: The description displayed to end users + x-ballerina-name: endUserDescription + active: + type: boolean + description: "If true, the custom status is set to active, If false, the\ + \ custom status is set to inactive" created_at: type: string + description: The date and time the custom ticket status was created format: date-time - description: The time the handle was created readOnly: true - id: - type: integer - description: Automatically assigned upon creation + x-ballerina-name: createdAt + description: + type: string + description: The description of when the user should select this custom + ticket status + raw_description: + type: string + description: "The dynamic content placeholder. If the dynamic content placeholder\ + \ is not available, this is the \"description\" value. [Dynamic Content\ + \ Items](/api-reference/ticketing/ticket-management/dynamic_content/)" readOnly: true - name: + x-ballerina-name: rawDescription + default: + type: boolean + description: "If true, the custom status is set to default. If false, the\ + \ custom status is set to non-default" + end_user_label: type: string - description: The profile name of the handle + description: The label displayed to end users. Maximum length is 48 characters + x-ballerina-name: endUserLabel + raw_agent_label: + type: string + description: "The dynamic content placeholder. If the dynamic content placeholder\ + \ is not available, this is the \"agent_label\" value. See [Dynamic Content\ + \ Items](/api-reference/ticketing/ticket-management/dynamic_content/)" readOnly: true - screen_name: + x-ballerina-name: rawAgentLabel + status_category: type: string - description: The Twitter handle + description: The status category the custom ticket status belongs to + enum: + - new + - open + - pending + - hold + - solved + x-ballerina-name: statusCategory + updated_at: + type: string + description: The date and time the custom ticket status was last updated + format: date-time readOnly: true - twitter_user_id: + x-ballerina-name: updatedAt + raw_end_user_description: + type: string + description: "The dynamic content placeholder. If the dynamic content placeholder\ + \ is not available, this is the \"end_user_description\" value. See [Dynamic\ + \ Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" + readOnly: true + x-ballerina-name: rawEndUserDescription + id: type: integer - description: The country's code + description: Automatically assigned when the custom ticket status is created readOnly: true - updated_at: + raw_end_user_label: type: string - format: date-time - description: The time of the last update of the handle + description: "The dynamic content placeholder. If the dynamic content placeholder\ + \ is not available, this is the \"end_user_label\" value. See [Dynamic\ + \ Content Items](/api-reference/ticketing/ticket-management/dynamic_content/)" readOnly: true - example: - created_at: "2009-05-13T00:07:08Z" - id: 211 - screen_name: '@zendesk' - twitter_user_id: 67462376832 - updated_at: "2011-07-22T00:11:12Z" - required: - - id - - screen_name - - twitter_user_id - TwitterChannelResponse: + x-ballerina-name: rawEndUserLabel + agent_label: + type: string + description: The label displayed to agents. Maximum length is 48 characters + x-ballerina-name: agentLabel + AutomationResponse: type: object properties: - monitored_twitter_handle: - $ref: '#/components/schemas/TwitterChannelObject' - TwitterChannelTwicketStatusResponse: + automation: + $ref: '#/components/schemas/AutomationObject' + SearchCountResponse: type: object properties: - statuses: - type: array - items: - type: object - properties: - favorited: - type: boolean - id: - type: integer - retweeted: - type: boolean - user_followed: - type: boolean - TwitterChannelsResponse: + count: + type: integer + TicketAuditResponse: type: object properties: - monitored_twitter_handles: - type: array - items: - $ref: '#/components/schemas/TwitterChannelObject' - UpdateResourceResult: + audit: + $ref: '#/components/schemas/TicketAuditObject' + AccountSettingsRoutingObject: type: object properties: - action: - type: string - description: | - the action the job attempted (`"action": "update"`) - id: + reassignment_messaging_enabled: + type: boolean + x-ballerina-name: reassignmentMessagingEnabled + reassignment_messaging_timeout: type: integer - description: the id of the resource the job attempted to update - status: + x-ballerina-name: reassignmentMessagingTimeout + autorouting_tag: type: string - description: | - the status (`"status": "Updated"`) - success: + x-ballerina-name: autoroutingTag + max_email_capacity: + type: integer + x-ballerina-name: maxEmailCapacity + enabled: type: boolean - description: | - whether the action was successful or not (`"success": true`) - required: - - id - - action - - success - - status - UrlObject: + max_messaging_capacity: + type: integer + x-ballerina-name: maxMessagingCapacity + reassignment_talk_timeout: + type: integer + x-ballerina-name: reassignmentTalkTimeout + description: "Configuration for routing. See [Routing](#routing)" + JobStatusObject: type: object properties: - url: + job_type: type: string + description: The type of the job readOnly: true - UserCreateInput: - type: object - properties: - custom_role_id: + x-ballerina-name: jobType + total: type: integer - email: + description: The total number of tasks this job is batching through + nullable: true + readOnly: true + progress: + type: integer + description: Number of tasks that have already been completed + nullable: true + readOnly: true + id: type: string - external_id: + description: Automatically assigned when the job is queued + readOnly: true + message: type: string - identities: - type: array - items: + description: "Message from the job worker, if any" + nullable: true + readOnly: true + results: + description: "Result data from processed tasks. See [Results](#results)\ + \ below" + readOnly: true + oneOf: + - type: array + nullable: true + items: + $ref: '#/components/schemas/JobStatusResultObject' + - required: + - success type: object properties: - type: - type: string - value: - type: string - required: - - type - - value - name: + success: + type: boolean + description: Whether the action was successful or not + readOnly: true + url: type: string - organization: - type: object - properties: - name: - type: string - required: - - name - organization_id: - type: integer - role: + description: The URL to poll for status updates + readOnly: true + status: type: string - required: - - name - - email - UserFieldObject: - type: object - allOf: - - $ref: '#/components/schemas/CustomFieldObject' + description: "The current status. One of the following: \"queued\", \"working\"\ + , \"failed\", \"completed\"" + readOnly: true example: - active: true - created_at: "2012-10-16T16:04:06Z" - description: Description of Custom Field - id: 7 - key: custom_field_1 - position: 9999 - raw_description: '{{dc.my_description}}' - raw_title: Custom Field 1 - regexp_for_validation: null - title: Custom Field 1 - type: text - updated_at: "2012-10-16T16:04:06Z" - url: https://company.zendesk.com/api/v2/user_fields/7.json - UserFieldResponse: + id: 82de0b044094f0c67893ac9fe64f1a99 + message: Completed at 2018-03-08 10:07:04 +0000 + progress: 2 + results: + - action: update + id: 244 + status: Updated + success: true + - action: update + id: 245 + status: Updated + success: true + status: completed + total: 2 + url: https://example.zendesk.com/api/v2/job_statuses/82de0b0467893ac9fe64f1a99.json + AccountSettingsGroupObject: type: object properties: - user_field: - $ref: '#/components/schemas/UserFieldObject' - UserFieldsResponse: + check_group_name_uniqueness: + type: boolean + x-ballerina-name: checkGroupNameUniqueness + description: Group configuration + AccountSettingsGooddataAdvancedAnalyticsObject: type: object properties: - count: - type: integer - description: Total count of records retrieved - readOnly: true - next_page: - type: string - description: URL of the next page - nullable: true - readOnly: true - previous_page: - type: string - description: URL of the previous page - nullable: true - readOnly: true - user_fields: - type: array - items: - $ref: '#/components/schemas/UserFieldObject' - UserForAdmin: - title: Users + enabled: + type: boolean + description: "GoodData settings, used for insights. Legacy configuration prior\ + \ to Zendesk Explore. See [GoodData Advanced Analytics](#gooddata-advanced-analytics)" + AuthorObject: type: object properties: - active: - type: boolean - description: false if the user has been deleted - readOnly: true - alias: - type: string - description: An alias displayed to end users - chat_only: - type: boolean - description: Whether or not the user is a chat-only agent - readOnly: true - created_at: - type: string - format: datetime - description: The time the user was created - readOnly: true - custom_role_id: - type: integer - description: A custom role if the user is an agent on the Enterprise plan or above - nullable: true - default_group_id: - type: integer - description: The id of the user's default group - details: - type: string - description: Any details you want to store about the user, such as an address - email: - type: string - description: The user's primary email address. *Writeable on create only. On update, a secondary email is added. See [Email Address](#email-address) - external_id: - type: string - description: 'A unique identifier from another system. The API treats the id as case insensitive. Example: "ian1" and "IAN1" are the same value.' - nullable: true - iana_time_zone: + name: type: string - description: The time zone for the user + description: The author name readOnly: true id: type: integer - description: Automatically assigned when the user is created + description: The author id readOnly: true - last_login_at: + email: type: string - format: datetime - description: | - Last time the user signed in to Zendesk Support or made an API request - using an API token or basic authentication + description: The author email readOnly: true - locale: + CustomStatusesResponse: + type: object + properties: + custom_statuses: + type: array + items: + $ref: '#/components/schemas/CustomStatusObject' + x-ballerina-name: customStatuses + MacroApplyTicketResponseResult: + type: object + properties: + ticket: + $ref: '#/components/schemas/MacroApplyTicketResponseResultTicket' + Pagination: + type: object + properties: + meta: + $ref: '#/components/schemas/PaginationMeta' + links: + $ref: '#/components/schemas/PaginationLinks' + RecoverSuspendedTicketUnprocessableContentResponse: + type: object + properties: + ticket: + type: array + items: + $ref: '#/components/schemas/SuspendedTicketObject' + TriggerDefinitionResponse: + type: object + properties: + definitions: + $ref: '#/components/schemas/TriggerDefinitionObject' + AttachmentObject: + type: object + description: "A file represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/)\ + \ object" + example: + content_type: image/png + content_url: https://company.zendesk.com/attachments/my_funny_profile_pic.png + file_name: my_funny_profile_pic.png + id: 928374 + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/attachments/my_funny_profile_pic_thumb.png + file_name: my_funny_profile_pic_thumb.png + id: 928375 + size: 58298 + allOf: + - $ref: '#/components/schemas/AttachmentBaseObject' + - $ref: '#/components/schemas/AttachmentThumbnails' + LocalesResponse: + type: object + properties: + locales: + type: array + items: + $ref: '#/components/schemas/LocaleObject' + MacroObject: + type: object + example: + actions: [] + active: true + description: Sets the ticket status to `solved` + id: 25 + position: 42 + restriction: + id: 4 + type: User + title: Close and Save + allOf: + - $ref: '#/components/schemas/MacroCommonObject' + - $ref: '#/components/schemas/MacroObjectAllOf2' + SkillBasedRoutingAttributeResponse: + type: object + properties: + attribute: + $ref: '#/components/schemas/SkillBasedRoutingAttributeObject' + AttachmentResponse: + type: object + properties: + attachment: + $ref: '#/components/schemas/AttachmentObject' + MacroUpdateManyInput: + type: object + properties: + macros: + type: array + items: + $ref: '#/components/schemas/MacroUpdateManyInputMacros' + SLAPolicyFilterDefinitionResponseDefinitionsAll: + type: object + properties: + operators: + type: array + items: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitionsOperators' + values: + $ref: '#/components/schemas/SLAPolicyFilterDefinitionResponseDefinitionsValues' + title: type: string - description: The user's locale. A BCP-47 compliant tag for the locale. If both "locale" and "locale_id" are present on create or update, "locale_id" is ignored and only "locale" is used. - locale_id: - type: integer - description: The user's language identifier - moderator: - type: boolean - description: Designates whether the user has forum moderation capabilities - name: + value: type: string - description: The user's name - notes: + group: type: string - description: Any notes you want to store about the user - only_private_comments: - type: boolean - description: true if the user can only create private comments - organization_id: - type: integer - description: The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](#organization-id) - nullable: true - phone: + target: type: string - description: The user's primary phone number. See [Phone Number](#phone-number) below nullable: true - photo: - type: object - description: The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - additionalProperties: true - nullable: true - remote_photo_url: - type: string - description: A URL pointing to the user's profile picture. - report_csv: - type: boolean - description: | - This parameter is inert and has no effect. It may be deprecated in the - future. - - Previously, this parameter determined whether a user could access a CSV - report in a legacy Guide dashboard. This dashboard has been removed. See - [Announcing Guide legacy reporting upgrade to - Explore](https://support.zendesk.com/hc/en-us/articles/4762263171610-Announcing-Guide-legacy-reporting-upgrade-to-Explore-) - readOnly: true - restricted_agent: - type: boolean - description: If the agent has any restrictions; false for admins and unrestricted agents, true for other agents - role: + AutomationsResponse: + type: object + properties: + next_page: type: string - description: The user's role. Possible values are "end-user", "agent", or "admin" - role_type: - type: integer - description: The user's role id. 0 for a custom agent, 1 for a light agent, 2 for a chat agent, 3 for a chat agent added to the Support account as a contributor ([Chat Phase 4](https://support.zendesk.com/hc/en-us/articles/360022365373#topic_djh_1zk_4fb)), 4 for an admin, and 5 for a billing admin nullable: true readOnly: true - shared: - type: boolean - description: If the user is shared from a different Zendesk Support instance. Ticket sharing accounts only - readOnly: true - shared_agent: - type: boolean - description: If the user is a shared agent from a different Zendesk Support instance. Ticket sharing accounts only - readOnly: true - shared_phone_number: - type: boolean - description: Whether the `phone` number is shared or not. See [Phone Number](#phone-number) below - nullable: true - signature: - type: string - description: The user's signature. Only agents and admins can have signatures - suspended: - type: boolean - description: If the agent is suspended. Tickets from suspended users are also suspended, and these users cannot sign in to the end user portal - tags: + x-ballerina-name: nextPage + automations: type: array - description: The user's tags. Only present if your account has user tagging enabled items: - type: string - ticket_restriction: - type: string - description: 'Specifies which tickets the user has access to. Possible values are: "organization", "groups", "assigned", "requested", null. "groups" and "assigned" are valid only for agents. If you pass an invalid value to an end user (for example, "groups"), they will be assigned to "requested", regardless of their previous access' - nullable: true - time_zone: - type: string - description: The user's time zone. See [Time Zone](#time-zone) - two_factor_auth_enabled: - type: boolean - description: If two factor authentication is enabled - nullable: true - readOnly: true - updated_at: - type: string - format: datetime - description: The time the user was last updated + $ref: '#/components/schemas/AutomationObject' + count: + type: integer readOnly: true - url: + previous_page: type: string - description: The user's API url + nullable: true readOnly: true - user_fields: - type: object - description: Values of custom fields in the user's profile. See [User Fields](#user-fields) - additionalProperties: true - verified: - type: boolean - description: Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) - example: - active: true - alias: Mr. Johnny - created_at: "2009-07-20T22:55:29Z" - custom_role_id: 9373643 - details: "" - email: johnny@example.com - external_id: sai989sur98w9 - iana_time_zone: Pacific/Pago_Pago - id: 35436 - last_login_at: "2011-05-05T10:38:52Z" - locale: en-US - locale_id: 1 - moderator: true - name: Johnny Agent - notes: Johnny is a nice guy! - only_private_comments: false - organization_id: 57542 - phone: "+15551234567" - photo: - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png - id: 928374 - name: my_funny_profile_pic.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png - id: 928375 - name: my_funny_profile_pic_thumb.png - size: 58298 - restricted_agent: true - role: agent - role_type: 0 - shared: false - shared_agent: false - signature: Have a nice day, Johnny - suspended: true - tags: - - enterprise - - other_tag - ticket_restriction: assigned - time_zone: Copenhagen - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/users/35436.json - user_fields: - user_date: "2012-07-23T00:00:00Z" - user_decimal: 5.1 - user_dropdown: option_1 - verified: true + x-ballerina-name: previousPage + GroupMembershipObject: required: - - name - UserForEndUser: + - group_id + - user_id type: object properties: - created_at: + default: + type: boolean + description: "If true, tickets assigned directly to the agent will assume\ + \ this membership's group" + updated_at: type: string - format: datetime - description: The time the user was created + description: The time of the last update of the group + format: date-time readOnly: true - email: - type: string - description: The primary email address of this user. If the primary email address is not [verified](https://support.zendesk.com/hc/en-us/articles/4408886752410), the secondary email address is used - iana_time_zone: + x-ballerina-name: updatedAt + group_id: + type: integer + description: The id of a group + x-ballerina-name: groupId + user_id: + type: integer + description: The id of an agent + x-ballerina-name: userId + created_at: type: string - description: The time zone for the user + description: The time the group was created + format: date-time readOnly: true + x-ballerina-name: createdAt id: type: integer - description: Automatically assigned when creating users + description: Automatically assigned upon creation readOnly: true - locale: + url: type: string - description: The locale for this user + description: The API url of this record readOnly: true - locale_id: - type: integer - description: The language identifier for this user - name: + JobStatusResultObject: + additionalProperties: true + oneOf: + - $ref: '#/components/schemas/CreateResourceResult' + - $ref: '#/components/schemas/UpdateResourceResult' + ActivitiesCountResponseCount: + type: object + properties: + refreshed_at: type: string - description: The name of the user - organization_id: + format: date-time + x-ballerina-name: refreshedAt + value: type: integer - description: The id of the user's organization. If the user has more than one [organization memberships](/api-reference/ticketing/organizations/organization_memberships/), the id of the user's default organization. If updating, see [Organization ID](/api-reference/ticketing/users/users/#organization-id) - phone: - type: string - description: The primary phone number of this user. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API - photo: - type: object - description: The user's profile picture represented as an [Attachment](/api-reference/ticketing/tickets/ticket-attachments/) object - additionalProperties: true + GroupMembershipResponse: + type: object + properties: + group_membership: + allOf: + - $ref: '#/components/schemas/GroupMembershipObject' + x-ballerina-name: groupMembership + ListTicketEmailCCsResponse: + type: object + additionalProperties: true + DeletedUserObject: + required: + - active + - created_at + - email + - id + - locale + - locale_id + - name + - organization_id + - phone + - photo + - role + - shared_phone_number + - time_zone + - updated_at + - url + type: object + properties: role: type: string - description: 'The role of the user. Possible values: `"end-user"`, `"agent"`, `"admin"`' shared_phone_number: + type: string + nullable: true + x-ballerina-name: sharedPhoneNumber + active: type: boolean - description: Whether the `phone` number is shared or not. See [Phone Number](/api-reference/ticketing/users/users/#phone-number) in the Users API + created_at: + type: string + x-ballerina-name: createdAt + photo: + type: object + nullable: true + locale: + type: string time_zone: type: string - description: The time-zone of this user + x-ballerina-name: timeZone + url: + type: string + locale_id: + type: integer + x-ballerina-name: localeId updated_at: type: string - format: datetime - description: The time of the last update of the user - readOnly: true - url: + x-ballerina-name: updatedAt + phone: type: string - description: The API url of this user - readOnly: true - verified: - type: boolean - description: Any of the user's identities is verified. See [User Identities](/api-reference/ticketing/users/user_identities) - required: - - name - UserIdentitiesResponse: + nullable: true + organization_id: + type: integer + x-ballerina-name: organizationId + name: + type: string + id: + type: integer + email: + type: string + GroupSLAPolicyFilterDefinitionResponseDefinitionsValues: + type: object + properties: + list: + type: array + items: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitionsValuesList' + type: + type: string + UserFieldObject: + type: object + example: + active: true + created_at: 2012-10-16T16:04:06Z + description: Description of Custom Field + id: 7 + key: custom_field_1 + position: 9999 + raw_description: "{{dc.my_description}}" + raw_title: Custom Field 1 + regexp_for_validation: null + title: Custom Field 1 + type: text + updated_at: 2012-10-16T16:04:06Z + url: https://company.zendesk.com/api/v2/user_fields/7.json + allOf: + - $ref: '#/components/schemas/CustomFieldObject' + BrandResponse: type: object properties: - identities: + brand: + $ref: '#/components/schemas/BrandObject' + Errors: + type: object + properties: + errors: type: array items: - $ref: '#/components/schemas/UserIdentityObject' - UserIdentityObject: + $ref: '#/components/schemas/Error' + RenewSessionResponse: type: object properties: - created_at: + authenticity_token: type: string - format: date-time - description: The time the identity was created - readOnly: true - deliverable_state: + description: A token of authenticity for the request + x-ballerina-name: authenticityToken + DynamicContentVariantsResponse: + type: object + properties: + variants: + type: array + items: + $ref: '#/components/schemas/DynamicContentVariantObject' + RelationshipFilterDefinition: + type: object + properties: + conditions_any: + type: array + items: + $ref: '#/components/schemas/TriggerConditionDefinitionObjectAny' + x-ballerina-name: conditionsAny + conditions_all: + type: array + items: + $ref: '#/components/schemas/TriggerConditionDefinitionObjectAll' + x-ballerina-name: conditionsAll + TriggerRevisionsResponse: + type: object + properties: + trigger_revisions: + type: array + items: + $ref: '#/components/schemas/TriggerRevisionsResponseTriggerRevisions' + x-ballerina-name: triggerRevisions + before_url: type: string - description: Email identity type only. Indicates if Zendesk sends notifications to the email address. See [Deliverable state](#deliverable-state) - readOnly: true - id: - type: integer - description: Automatically assigned on creation - readOnly: true - primary: - type: boolean - description: If the identity is the primary identity. *Writable only when creating, not when updating. Use the [Make Identity Primary](#make-identity-primary) endpoint instead - type: + x-ballerina-name: beforeUrl + after_cursor: type: string - description: The type of this identity - enum: - - email - - twitter - - facebook - - google - - phone_number - - agent_forwarding - - any_channel - - foreign - - sdk - readOnly: true - undeliverable_count: + x-ballerina-name: afterCursor + count: type: integer - description: The number of times a soft-bounce response was received at that address - readOnly: true - updated_at: - type: string - format: date-time - description: The time the identity was updated - readOnly: true - url: + after_url: type: string - description: The API url of this identity - readOnly: true - user_id: - type: integer - description: The id of the user - readOnly: true - value: + x-ballerina-name: afterUrl + before_cursor: type: string - description: The identifier for this identity, such as an email address - readOnly: true - verified: - type: boolean - description: If the identity has been verified - example: - created_at: "2011-07-20T22:55:29Z" - deliverable_state: deliverable - id: 35436 - primary: true - type: email - updated_at: "2011-07-20T22:55:29Z" - url: https://company.zendesk.com/api/v2/users/135/identities/35436.json - user_id: 135 - value: someone@example.com - verified: true - required: - - user_id - - type - - value - UserIdentityResponse: + x-ballerina-name: beforeCursor + MacroAttachmentResponse: type: object properties: - identity: - $ref: '#/components/schemas/UserIdentityObject' - UserInput: - anyOf: - - $ref: '#/components/schemas/UserCreateInput' - - $ref: '#/components/schemas/UserMergePropertiesInput' - - $ref: '#/components/schemas/UserMergeByIdInput' - additionalProperties: true - UserMergeByIdInput: + macro_attachment: + allOf: + - $ref: '#/components/schemas/MacroAttachmentObject' + x-ballerina-name: macroAttachment + GroupSLAPolicyMetricObject: type: object properties: - id: + business_hours: + type: boolean + description: Whether the metric targets are being measured in business hours + or calendar hours + x-ballerina-name: businessHours + metric: + type: string + description: The definition of the time that is being measured + priority: + type: string + description: Priority that a ticket must match + target: type: integer - UserMergePropertiesInput: + description: The time within which the end-state for a metric should be + met + TicketChatCommentRedactionResponseChatEventValue: type: object properties: - email: + visitor_id: type: string - name: - type: string - organization_id: - type: integer - password: + description: Id assigned to the visitor + readOnly: true + x-ballerina-name: visitorId + history: + type: array + description: Chat events within the chat session + items: + type: object + additionalProperties: true + chat_id: type: string - UserObject: - anyOf: - - $ref: '#/components/schemas/UserForAdmin' - - $ref: '#/components/schemas/UserForEndUser' - additionalProperties: true - UserPasswordRequirementsResponse: + description: Id of the chat session + readOnly: true + x-ballerina-name: chatId + description: The value of the chat event object + readOnly: true + GroupSLAPolicyFilterDefinitionResponseDefinitions: type: object properties: - requirements: + all: type: array items: - type: string - UserRelatedObject: + $ref: '#/components/schemas/GroupSLAPolicyFilterDefinitionResponseDefinitionsAll' + CommentsAllOf1: type: object properties: - assigned_tickets: - type: integer - description: Count of assigned tickets - ccd_tickets: - type: integer - description: Count of collaborated tickets - organization_subscriptions: - type: integer - description: Count of organization subscriptions - requested_tickets: - type: integer - description: Count of requested tickets - UserRelatedResponse: + value: + type: string + description: The comment string value + TargetFailuresResponse: type: object properties: - user_related: - $ref: '#/components/schemas/UserRelatedObject' - UserRequest: + target_failures: + type: array + items: + $ref: '#/components/schemas/TargetFailureObject' + x-ballerina-name: targetFailures + TicketCommentsResponse: type: object properties: - user: - $ref: '#/components/schemas/UserInput' - required: - - user - UserResponse: + comments: + type: array + items: + $ref: '#/components/schemas/TicketCommentObject' + BrandsResponseAllOf2: type: object properties: - user: - $ref: '#/components/schemas/UserObject' - UsersRequest: + brands: + type: array + description: Array of brands + items: + $ref: '#/components/schemas/BrandObject' + AccountSettingsRuleObject: type: object properties: - users: + using_skill_based_routing: + type: boolean + x-ballerina-name: usingSkillBasedRouting + macro_order: + type: string + x-ballerina-name: macroOrder + skill_based_filtered_views: type: array items: - $ref: '#/components/schemas/UserInput' - required: - - users - UsersResponse: + type: object + additionalProperties: true + x-ballerina-name: skillBasedFilteredViews + macro_most_used: + type: boolean + x-ballerina-name: macroMostUsed + description: "Rules settings for triggers, macros, views, and automations. See\ + \ [Rules](#rules)" + BatchJobRequestJob: type: object properties: - users: + action: + type: string + enum: + - patch + items: + $ref: '#/components/schemas/BatchJobRequestJobItems' + ListDeletedTicketsResponseAllOf1: + type: object + properties: + deleted_tickets: type: array items: - $ref: '#/components/schemas/UserObject' - ViaObject: + $ref: '#/components/schemas/ListDeletedTicketsResponseDeletedTickets' + x-ballerina-name: deletedTickets + AssigneeFieldAssignableGroupsResponse: type: object - description: | - An object explaining how the ticket was created. See the [Via object reference](/documentation/ticketing/reference-guides/via-object-reference) properties: - channel: + next_page: type: string - description: | - This tells you how the ticket or event was created. Examples: "web", "mobile", "rule", "system" - source: - type: object - description: | - For some channels a source object gives more information about how or why the ticket or event was created - properties: - from: - type: object - properties: - address: - type: string - nullable: true - id: - type: integer - nullable: true - name: - type: string - nullable: true - title: - type: string - nullable: true - rel: - type: string - nullable: true - to: - type: object - properties: - address: - type: string - name: - type: string - additionalProperties: true + nullable: true + readOnly: true + x-ballerina-name: nextPage + count: + type: integer + description: Number of groups listed in `groups` property + groups: + type: array + items: + $ref: '#/components/schemas/AssigneeFieldAssignableGroupObject' + previous_page: + type: string + nullable: true + readOnly: true + x-ballerina-name: previousPage example: - channel: rule - source: - from: - id: 22472716 - title: Assign to first responder - rel: trigger - to: {} - readOnly: true - ViewCountObject: + count: 3 + groups: + - description: Engineering + id: 9182736455 + name: Group for Bugs for Engineering + - description: Product + id: 1928374655 + name: Group for feature requests + - description: Customer Support + id: 5519283746 + name: Group for customer inquiries + next_page: null + previous_page: null + WorkspacesReorderBody: + type: object + properties: + ids: + type: array + items: + type: number + CustomObjectRecordsCreateRequest: + type: object + properties: + custom_object_record: + allOf: + - $ref: '#/components/schemas/CustomObjectRecord' + x-ballerina-name: customObjectRecord + SearchExportResponseMeta: type: object properties: - active: - type: boolean - description: Only active views if true, inactive views if false, all views if null. + after_cursor: + type: string + description: The cursor id for the next object + nullable: true readOnly: true - fresh: + x-ballerina-name: afterCursor + before_cursor: + type: string + description: The cursor id for the previous object + nullable: true + readOnly: true + x-ballerina-name: beforeCursor + has_more: type: boolean - description: false if the cached data is stale and the system is still loading and caching new data + description: Whether there are more items yet to be returned by the cursor readOnly: true - pretty: + x-ballerina-name: hasMore + description: Metadata for the export query response + SuspendedTicketsResponse: + type: object + properties: + suspended_tickets: + type: array + items: + $ref: '#/components/schemas/SuspendedTicketObject' + x-ballerina-name: suspendedTickets + TicketUpdateInput: + type: object + properties: + safe_update: + type: boolean + description: Optional boolean. Prevents updates with outdated ticket data + (`updated_stamp` property required when true) + x-ballerina-name: safeUpdate + custom_fields: + type: array + description: "Custom fields for the ticket. See [Setting custom field values](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-custom-field-values)" + items: + $ref: '#/components/schemas/CustomFieldObject' + x-ballerina-name: customFields + subject: type: string - description: A pretty-printed text approximation of the view count - readOnly: true - url: + description: The value of the subject field for this ticket + custom_status_id: + type: integer + description: "The custom ticket status id of the ticket. See [custom ticket\ + \ statuses](#custom-ticket-statuses)" + x-ballerina-name: customStatusId + external_id: type: string - description: The API url of the count - readOnly: true - value: + description: An id you can use to link Zendesk Support tickets to local + records + x-ballerina-name: externalId + additional_collaborators: + type: array + description: "An array of numeric IDs, emails, or objects containing name\ + \ and email properties. See [Setting Collaborators](/api-reference/ticketing/tickets/tickets/#setting-collaborators).\ + \ An email notification is sent to them when the ticket is updated" + items: + $ref: '#/components/schemas/CollaboratorObject' + x-ballerina-name: additionalCollaborators + collaborator_ids: + type: array + description: The ids of users currently CC'ed on the ticket + items: + type: integer + x-ballerina-name: collaboratorIds + priority: + type: string + description: The urgency with which the ticket should be addressed + enum: + - urgent + - high + - normal + - low + type: + type: string + description: The type of this ticket + enum: + - problem + - incident + - question + - task + updated_stamp: + type: string + description: Datetime of last update received from API. See the safe_update + property + format: date-time + x-ballerina-name: updatedStamp + tags: + type: array + description: The array of tags applied to this ticket + items: + type: string + assignee_email: + type: string + description: The email address of the agent to assign the ticket to + format: email + x-ballerina-name: assigneeEmail + followers: + type: array + description: "An array of objects that represent agent followers to add\ + \ or delete from the ticket. See [Setting followers](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-followers)" + items: + $ref: '#/components/schemas/FollowerObject' + sharing_agreement_ids: + type: array + description: An array of the numeric IDs of sharing agreements. Note that + this replaces any existing agreements + items: + type: integer + x-ballerina-name: sharingAgreementIds + group_id: + type: integer + description: The group this ticket is assigned to + x-ballerina-name: groupId + problem_id: type: integer - description: The cached number of tickets in the view. Can also be null if the system is loading and caching new data. Not to be confused with 0 tickets + description: "For tickets of type \"incident\", the ID of the problem the\ + \ incident is linked to" + x-ballerina-name: problemId + email_ccs: + type: array + description: "An array of objects that represent agent or end users email\ + \ CCs to add or delete from the ticket. See [Setting email CCs](/documentation/ticketing/managing-tickets/creating-and-updating-tickets#setting-email-ccs)" + items: + $ref: '#/components/schemas/EmailCCObject' + x-ballerina-name: emailCcs + organization_id: + type: integer + description: "The organization of the requester. You can only specify the\ + \ ID of an organization associated with the requester. See [Organization\ + \ Memberships](/api-reference/ticketing/organizations/organization_memberships/)" + x-ballerina-name: organizationId + comment: + $ref: '#/components/schemas/TicketCommentObject' + due_at: + type: string + description: "If this is a ticket of type \"task\" it has a due date. Due\ + \ date format uses [ISO 8601](http://en.wikipedia.org/wiki/ISO_8601) format" + format: date-time nullable: true - readOnly: true - view_id: + x-ballerina-name: dueAt + attribute_value_ids: + type: array + description: An array of the IDs of attribute values to be associated with + the ticket + items: + type: integer + x-ballerina-name: attributeValueIds + assignee_id: type: integer - description: The id of the view - readOnly: true - ViewCountResponse: + description: The agent currently assigned to the ticket + x-ballerina-name: assigneeId + requester_id: + type: integer + description: The user who requested this ticket + x-ballerina-name: requesterId + status: + type: string + description: | + The state of the ticket. + + If your account has activated custom ticket statuses, this is the ticket's + status category. See [custom ticket statuses](#custom-ticket-statuses) + enum: + - new + - open + - pending + - hold + - solved + - closed + example: + comment: + body: The smoke is very colorful. + priority: urgent + subject: My printer is on fire! + TriggerRevisionResponse: type: object properties: - view_count: - $ref: '#/components/schemas/ViewCountObject' - ViewCountsResponse: + trigger_revision: + allOf: + - $ref: '#/components/schemas/TriggerRevisionResponseTriggerRevision' + x-ballerina-name: triggerRevision + AccountSettingsCdnObject: type: object properties: - view_counts: + cdn_provider: + type: string + x-ballerina-name: cdnProvider + hosts: type: array items: - $ref: '#/components/schemas/ViewCountObject' - ViewExportResponse: + $ref: '#/components/schemas/AccountSettingsCdnObjectHosts' + fallback_cdn_provider: + type: string + x-ballerina-name: fallbackCdnProvider + description: CDN settings + BatchErrorItem: type: object - properties: - export: - type: object - properties: - status: - type: string - readOnly: true - view_id: - type: integer - readOnly: true - ViewObject: + allOf: + - $ref: '#/components/schemas/Error' + - $ref: '#/components/schemas/BatchErrorItemAllOf2' + TicketSkipObject: type: object properties: - active: - type: boolean - description: Whether the view is active - conditions: + reason: + type: string + description: Reason for skipping the ticket + readOnly: true + ticket: type: object - description: Describes how the view is constructed. See [Conditions reference](/documentation/ticketing/reference-guides/conditions-reference) - additionalProperties: true - created_at: + description: "The skipped ticket. See the [Ticket object reference](/api-reference/ticketing/tickets/tickets/#json-format)" + allOf: + - $ref: '#/components/schemas/TicketObject' + updated_at: type: string + description: Time the skip was last updated format: date-time - description: The time the view was created readOnly: true - default: - type: boolean - description: If true, the view is a default view + x-ballerina-name: updatedAt + user_id: + type: integer + description: ID of the skipping agent readOnly: true - description: + x-ballerina-name: userId + created_at: type: string - description: The description of the view - execution: - type: object - description: Describes how the view should be executed. See [Execution](#execution) - additionalProperties: true + description: Time the skip was created + format: date-time + readOnly: true + x-ballerina-name: createdAt id: type: integer - description: Automatically assigned when created + description: Automatically assigned upon creation readOnly: true - position: + ticket_id: type: integer - description: The position of the view - restriction: - type: object - description: Who may access this account. Is null when everyone in the account can access it - additionalProperties: true - title: - type: string - description: The title of the view - updated_at: - type: string - format: date-time - description: The time the view was last updated + description: ID of the skipped ticket readOnly: true + x-ballerina-name: ticketId example: - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: [] - default: false - description: View for recent tickets - execution: - columns: - - id: status - title: Status - - id: updated - title: Updated - - id: 5 - title: Account - type: text - url: https://example.zendesk.com/api/v2/ticket_fields/5.json - group: - id: status - order: desc - title: Status - sort: - id: updated - order: desc - title: Updated - id: 25 - position: 8 - restriction: - id: 4 - type: User - title: Tickets updated <12 Hours - ViewResponse: + created_at: 2015-09-30T21:44:03Z + id: 1 + reason: I have no idea. + ticket: + assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + from_messaging_channel: false + group_id: 98738 + has_incidents: false + id: 123 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + ticket_id: 123 + updated_at: 2015-09-30T21:44:03Z + user_id: 456 + ViewCountsResponse: type: object properties: - columns: + view_counts: type: array items: - type: object - additionalProperties: true - groups: + $ref: '#/components/schemas/ViewCountObject' + x-ballerina-name: viewCounts + UrlObject: + type: object + properties: + url: + type: string + readOnly: true + BookmarksResponse: + title: Bookmarks + type: object + allOf: + - $ref: '#/components/schemas/OffsetPaginationObject' + - $ref: '#/components/schemas/BookmarksResponseAllOf2' + RecoverSuspendedTicketsResponse: + type: object + properties: + tickets: type: array items: - type: object - additionalProperties: true - rows: + $ref: '#/components/schemas/SuspendedTicketObject' + TriggerSnapshotObject: + type: object + properties: + active: + type: boolean + description: Whether the trigger is active + description: + type: string + description: The description of the trigger + nullable: true + conditions: + $ref: '#/components/schemas/TriggerConditionsObject' + title: + type: string + description: The title of the trigger + actions: type: array + description: "An array of [Actions](#actions) describing what the trigger\ + \ will do" items: - type: object - additionalProperties: true - view: - $ref: '#/components/schemas/ViewObject' - ViewsCountResponse: + $ref: '#/components/schemas/TriggerActionObject' + example: + actions: [] + active: true + conditions: {} + description: Notifies requester that a comment was updated + title: Notify requester of comment update + SatisfactionRatingsCountResponse: type: object properties: count: - type: object - properties: - refreshed_at: - type: string - format: date-time - value: - type: integer - ViewsResponse: + $ref: '#/components/schemas/ActivitiesCountResponseCount' + EssentialsCardResponse: type: object properties: - count: + object_layout: + allOf: + - $ref: '#/components/schemas/EssentialsCardObject' + x-ballerina-name: objectLayout + UsersUpdateManyBody: + additionalProperties: true + oneOf: + - $ref: '#/components/schemas/UserRequest' + - $ref: '#/components/schemas/UsersRequest' + CustomObjectRecordsJobsResponseJobStatus: + type: object + properties: + total: + type: integer + progress: type: integer - readOnly: true - next_page: - type: string nullable: true - readOnly: true - previous_page: + id: + type: string + message: type: string nullable: true - readOnly: true - views: + results: type: array + nullable: true items: - $ref: '#/components/schemas/ViewObject' - WorkspaceInput: - type: object - properties: - conditions: - $ref: '#/components/schemas/ConditionsObject' - description: + $ref: '#/components/schemas/CustomObjectRecord' + url: type: string - description: User-defined description of this workspace's purpose - macros: - type: array - items: - type: number - ticket_form_id: - type: number - title: + status: type: string - description: The title of the workspace - WorkspaceObject: + ChannelFrameworkResultStatusObject: type: object properties: - activated: - type: boolean - description: If true, this workspace is available for use - apps: - type: array - description: The apps associated to this workspace - items: - type: object - additionalProperties: true - conditions: - $ref: '#/components/schemas/ConditionsObject' - created_at: + code: type: string - format: date-time - description: The time the workspace was created + description: "A code indicating the status of the import of the resource,\ + \ as described in [status codes](#status-codes)" + readOnly: true description: type: string - description: User-defined description of this workspace's purpose - id: - type: integer - description: Automatically assigned upon creation - macro_ids: - type: array - description: The ids of the macros associated to this workspace - items: - type: integer - macros: - type: array - description: The ids of the macros associated to this workspace - items: - type: integer - position: + description: "In the case of an exception, a description of the exception.\ + \ Otherwise, not present" + readOnly: true + description: The status of the import for the indicated resource + BatchJobRequest: + type: object + properties: + job: + $ref: '#/components/schemas/BatchJobRequestJob' + CustomObjectFieldsCreateRequest: + type: object + properties: + custom_object_field: + allOf: + - $ref: '#/components/schemas/CustomObjectField' + x-ballerina-name: customObjectField + TicketCreateVoicemailTicketRequest: + type: object + properties: + ticket: + type: object + description: Ticket object that lists the values to set when the ticket + is created + allOf: + - $ref: '#/components/schemas/TicketCreateVoicemailTicketInput' + display_to_agent: type: integer - description: Ordering of the workspace relative to other workspaces - prefer_workspace_app_order: - type: boolean - description: If true, the order of apps within the workspace will be preserved - selected_macros: - type: array - description: An array of the macro objects that will be used in this workspace. See [Macros](/api-reference/ticketing/business-rules/macros/) - items: - $ref: '#/components/schemas/MacroObject' - ticket_form_id: + description: Optional value such as the ID of the agent that will see the + newly created ticket + x-ballerina-name: displayToAgent + ViewExportResponseExport: + type: object + properties: + view_id: type: integer - description: The id of the ticket web form associated to this workspace - title: - type: string - description: The title of the workspace - updated_at: - type: string - format: date-time - description: The time of the last update of the workspace - url: + readOnly: true + x-ballerina-name: viewId + status: type: string - description: The URL for this resource - WorkspaceResponse: + readOnly: true + CustomObjectRecordsBulkCreateRequest: type: object - allOf: - - type: object - properties: - workspaces: - type: array - items: - $ref: '#/components/schemas/WorkspaceObject' - - $ref: '#/components/schemas/OffsetPaginationObject' + properties: + job: + $ref: '#/components/schemas/CustomObjectRecordsBulkCreateRequestJob' + TriggerCategoriestriggerCategoryIdBody: + type: object + properties: + trigger_category: + allOf: + - $ref: '#/components/schemas/TriggerCategoryRequest' + x-ballerina-name: triggerCategory parameters: AcceptHeader: - name: Accept - in: header - required: false - schema: - type: string - default: application/json + name: Accept + in: header + required: false + style: simple + explode: false + schema: + type: string + default: application/json + x-ballerina-name: accept ActivityId: - name: activity_id + name: activityId in: path description: The activity ID required: true + style: simple + explode: false schema: type: integer example: 29183462 ActivitySince: name: since in: query - description: A UTC time in ISO 8601 format to return ticket activities since said date. + description: A UTC time in ISO 8601 format to return ticket activities since + said date + required: false + style: form + explode: true schema: type: string - example: "2013-04-03T16:02:46Z" + example: 2013-04-03T16:02:46Z AgentId: - name: agent_id + name: agentId in: path description: ID of an agent required: true + style: simple + explode: false schema: type: integer examples: @@ -23607,52 +25459,73 @@ components: ArchiveImmediately: name: archive_immediately in: query - description: If `true`, any ticket created with a `closed` status bypasses the normal ticket lifecycle and will be created directly in your ticket archive + description: "If `true`, any ticket created with a `closed` status bypasses\ + \ the normal ticket lifecycle and will be created directly in your ticket\ + \ archive" + required: false + style: form + explode: true schema: type: boolean + x-ballerina-name: archiveImmediately AssigneeFieldSearchValue: name: name in: query description: Query string used to search assignable groups & agents in the AssigneeField required: true + style: form + explode: true schema: type: string example: Johnny Agent AttachmentId: - name: attachment_id + name: attachmentId in: path description: The ID of the attachment required: true + style: simple + explode: false schema: type: integer example: 498483 AuditLogId: - name: audit_log_id + name: auditLogId in: path description: The ID of the audit log required: true + style: simple + explode: false schema: type: integer example: 498483 AutomationActive: name: active in: query - description: Filter by active automations if true or inactive automations if false + description: Filter by active automations if true or inactive automations if + false + required: false + style: form + explode: true schema: type: boolean example: true AutomationId: - name: automation_id + name: automationId in: path description: The ID of the automation required: true + style: simple + explode: false schema: type: integer example: 25 AutomationInclude: name: include in: query - description: A sideload to include in the response. See [Sideloads](#sideloads-2) + description: "A sideload to include in the response. See [Sideloads](#sideloads-2)" + required: false + style: form + explode: true schema: type: string example: usage_24h @@ -23661,44 +25534,62 @@ components: in: query description: Query string used to find all automations with matching title required: true + style: form + explode: true schema: type: string example: close AutomationSortBy: name: sort_by in: query - description: Possible values are "alphabetical", "created_at", "updated_at", and "position". If unspecified, the automations are sorted by relevance + description: "Possible values are \"alphabetical\", \"created_at\", \"updated_at\"\ + , and \"position\". If unspecified, the automations are sorted by relevance" + required: false + style: form + explode: true schema: type: string example: position + x-ballerina-name: sortBy AutomationSortOrder: name: sort_order in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true schema: type: string example: desc + x-ballerina-name: sortOrder BookmarkId: - name: bookmark_id + name: bookmarkId in: path description: The ID of the bookmark required: true + style: simple + explode: false schema: type: integer example: 900000001111 BrandId: - name: brand_id + name: brandId in: path description: The ID of the brand required: true + style: simple + explode: false schema: type: integer example: 360002783572 CommentId: - name: comment_id + name: commentId in: path description: The ID of the comment required: true + style: simple + explode: false schema: type: integer example: 654321 @@ -23709,21 +25600,28 @@ components: If true, displays the `creator_user_id` and `creator_app_name` properties. If the ticket field is created by an app, `creator_app_name` is the name of the app and `creator_user_id` is `-1`. If the ticket field is not created by an app, then `creator_app_name` is null + required: false + style: form + explode: true schema: type: boolean CustomObjectFieldKeyOrId: - name: custom_object_field_key_or_id + name: customObjectFieldKeyOrId in: path description: The key or id of a custom object field required: true + style: simple + explode: false schema: type: string example: make CustomObjectKey: - name: custom_object_key + name: customObjectKey in: path description: The key of a custom object required: true + style: simple + explode: false schema: type: string example: car @@ -23732,63 +25630,80 @@ components: in: query description: The external id of a custom object record required: true + style: form + explode: true schema: type: string example: X90001 + x-ballerina-name: externalId CustomObjectRecordId: - name: custom_object_record_id + name: customObjectRecordId in: path description: The id of a custom object record required: true + style: simple + explode: false schema: type: string example: 01GCSJW391QVSC80GYDH7E93Q6 CustomRoleId: - name: custom_role_id + name: customRoleId in: path description: The ID of the custom agent role required: true + style: simple + explode: false schema: type: integer example: 10127 CustomStatusId: - name: custom_status_id + name: customStatusId in: path description: The id of the custom status required: true + style: simple + explode: false schema: type: integer example: 1234567 DeletedUserId: - name: deleted_user_id + name: deletedUserId in: path description: The ID of the deleted user required: true + style: simple + explode: false schema: type: integer example: 35436 DynamicContentItemId: - name: dynamic_content_item_id + name: dynamicContentItemId in: path description: The ID of the dynamic content item required: true + style: simple + explode: false schema: type: integer example: 47 DynamicContentVariantId: - name: dynammic_content_variant_id + name: dynammicContentVariantId in: path description: The ID of the variant required: true + style: simple + explode: false schema: type: integer example: 23 EssentialsCardKey: - name: object_type + name: objectType in: path description: | Essentials card type. Example: `zen:user` refers user type required: true + style: simple + explode: false schema: type: string example: zen:user @@ -23796,65 +25711,92 @@ components: name: exclude_deleted in: query description: Whether to exclude deleted entities + required: false + style: form + explode: true schema: type: boolean example: false + x-ballerina-name: excludeDeleted GroupId: - name: group_id + name: groupId in: path description: The ID of the group required: true + style: simple + explode: false schema: type: integer example: 122 GroupMembershipId: - name: group_membership_id + name: groupMembershipId in: path description: The ID of the group membership required: true + style: simple + explode: false schema: type: integer example: 4 GroupSLAPolicyId: - name: group_sla_policy_id + name: groupSlaPolicyId in: path description: The id of the Group SLA policy required: true + style: simple + explode: false schema: type: integer example: 36 HostMapping: name: host_mapping in: query - description: The hostmapping to a brand, if any (only admins view this key) + description: "The hostmapping to a brand, if any (only admins view this key)" required: true + style: form + explode: true schema: type: string example: brand1.com + x-ballerina-name: hostMapping IncludeStandardFields: name: include_standard_fields in: query description: Include standard fields if true. Exclude them if false + required: false + style: form + explode: true schema: type: boolean example: true + x-ballerina-name: includeStandardFields IncrementalCursor: name: cursor in: query - description: The cursor pointer to work with for all subsequent exports after the initial request + description: The cursor pointer to work with for all subsequent exports after + the initial request + required: false + style: form + explode: true schema: type: string IncrementalPage: name: per_page in: query description: The number of records to return per page + required: false + style: form + explode: true schema: type: integer + x-ballerina-name: perPage IncrementalResource: - name: incremental_resource + name: incrementalResource in: path description: The resource requested for incremental sample export required: true + style: simple + explode: false schema: type: string example: tickets @@ -23862,31 +25804,42 @@ components: name: unix_time in: query description: A query start time for incremental exports + required: false + style: form + explode: true schema: type: integer example: 1383685952 IncrementalUnixTime: name: start_time in: query - description: The time to start the incremental export from. Must be at least one minute in the past. Data isn't provided for the most recent minute + description: The time to start the incremental export from. Must be at least + one minute in the past. Data isn't provided for the most recent minute required: true + style: form + explode: true schema: type: integer example: 1332034771 + x-ballerina-name: startTime JobStatusId: - name: job_status_id + name: jobStatusId in: path description: the Id of the Job status required: true + style: simple + explode: false schema: type: string example: 8b726e606741012ffc2d782bcb7848fe LocaleId: - name: locale_id + name: localeId in: path description: | The ID or the [BCP-47 code](https://en.wikipedia.org/wiki/IETF_language_tag) of the locale. Examples: es-419, en-us, pr-br required: true + style: simple + explode: false schema: type: string example: es-419 @@ -23896,14 +25849,21 @@ components: description: | The id of a lookup relationship field. The type of field is determined by the `source` param + required: false + style: form + explode: true schema: type: string + x-ballerina-name: fieldId LookupRelationshipAutocompleteSourceFragment: name: source in: query description: | If a `field_id` is provided, this specifies the type of the field. For example, if the field is on a "zen:user", it references a field on a user + required: false + style: form + explode: true schema: type: string examples: @@ -23919,7 +25879,12 @@ components: MacroAccess: name: access in: query - description: Filter macros by access. Possible values are "personal", "agents", "shared", or "account". The "agents" value returns all personal macros for the account's agents and is only available to admins. + description: "Filter macros by access. Possible values are \"personal\", \"\ + agents\", \"shared\", or \"account\". The \"agents\" value returns all personal\ + \ macros for the account's agents and is only available to admins" + required: false + style: form + explode: true schema: type: string example: personal @@ -23927,6 +25892,9 @@ components: name: active in: query description: Filter by active macros if true or inactive macros if false + required: false + style: form + explode: true schema: type: boolean example: true @@ -23934,6 +25902,9 @@ components: name: category in: query description: Filter macros by category + required: false + style: form + explode: true schema: type: integer example: 25 @@ -23941,14 +25912,20 @@ components: name: group_id in: query description: Filter macros by group + required: false + style: form + explode: true schema: type: integer example: 25 + x-ballerina-name: groupId MacroId: - name: macro_id + name: macroId in: path description: The ID of the macro required: true + style: simple + explode: false schema: type: integer example: 25 @@ -23957,50 +25934,76 @@ components: in: query description: The ID of the macro to replicate required: true + style: form + explode: true schema: type: integer example: 25 + x-ballerina-name: macroId MacroInclude: name: include in: query - description: A sideload to include in the response. See [Sideloads](#sideloads-2) + description: "A sideload to include in the response. See [Sideloads](#sideloads-2)" + required: false + style: form + explode: true schema: type: string example: usage_7d MacroOnlyViewable: name: only_viewable in: query - description: If true, returns only macros that can be applied to tickets. If false, returns all macros the current user can manage. Default is false + description: "If true, returns only macros that can be applied to tickets. If\ + \ false, returns all macros the current user can manage. Default is false" + required: false + style: form + explode: true schema: type: boolean example: false + x-ballerina-name: onlyViewable MacroQuery: name: query in: query description: Query string used to find macros with matching titles required: true + style: form + explode: true schema: type: string example: close MacroSortBy: name: sort_by in: query - description: Possible values are alphabetical, "created_at", "updated_at", "usage_1h", "usage_24h", "usage_7d", or "usage_30d". Defaults to alphabetical + description: "Possible values are alphabetical, \"created_at\", \"updated_at\"\ + , \"usage_1h\", \"usage_24h\", \"usage_7d\", or \"usage_30d\". Defaults to\ + \ alphabetical" + required: false + style: form + explode: true schema: type: string example: alphabetical + x-ballerina-name: sortBy MacroSortOrder: name: sort_order in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true schema: type: string example: asc + x-ballerina-name: sortOrder MonitoredTwitterHandleId: - name: monitored_twitter_handle_id + name: monitoredTwitterHandleId in: path description: The ID of the custom agent role required: true + style: simple + explode: false schema: type: integer example: 431 @@ -24011,14 +26014,18 @@ components: Custom object type. Example: `zen:custom_object:car` refers to a custom object type with the `car` key required: true + style: simple + explode: false schema: type: string example: zen:custom_object:car OcrQueueId: - name: queue_id + name: queueId in: path description: The id of the omnichannel routing queue required: true + style: simple + explode: false schema: type: string example: 01HG80ATNNZK1N7XRFVKX48XD6 @@ -24026,31 +26033,43 @@ components: name: external_id in: query description: The external id of an organization + required: false + style: form + explode: true schema: type: integer example: 1234 + x-ballerina-name: externalId OrganizationExternalIds: name: external_ids in: query description: A list of external ids + required: false + style: form + explode: true schema: type: string - example: 1764,42156 + example: "1764,42156" + x-ballerina-name: externalIds OrganizationFieldId: - name: organization_field_id + name: organizationFieldId in: path description: The ID or key of the organization field required: true + style: simple + explode: false schema: oneOf: - - type: integer - - type: string + - type: integer + - type: string example: my_text_field OrganizationId: - name: organization_id + name: organizationId in: path description: The ID of an organization required: true + style: simple + explode: false schema: type: integer example: 16 @@ -24058,14 +26077,19 @@ components: name: ids in: query description: A list of organization ids + required: false + style: form + explode: true schema: type: string - example: 35436,20057623 + example: "35436,20057623" OrganizationMembershipId: - name: organization_membership_id + name: organizationMembershipId in: path description: The ID of the organization membership required: true + style: simple + explode: false schema: type: integer example: 4 @@ -24073,6 +26097,9 @@ components: name: name in: query description: The name of an organization + required: false + style: form + explode: true schema: type: string example: ACME Incorporated @@ -24081,78 +26108,98 @@ components: in: query description: A substring of an organization to search for required: true + style: form + explode: true schema: type: string example: imp OrganizationSubscriptionId: - name: organization_subscription_id + name: organizationSubscriptionId in: path description: The ID of the organization subscription required: true + style: simple + explode: false schema: type: integer example: 35436 RequestId: - name: request_id + name: requestId in: path description: The ID of the request required: true + style: simple + explode: false schema: type: integer example: 33 ResourceCollectionId: - name: resource_collection_id + name: resourceCollectionId in: path description: The id of the resource collection required: true + style: simple + explode: false schema: type: integer example: 10002 SLAPolicyId: - name: sla_policy_id + name: slaPolicyId in: path description: The ID of the SLA Policy required: true + style: simple + explode: false schema: type: integer example: 36 SessionId: - name: session_id + name: sessionId in: path description: The ID of the session required: true + style: simple + explode: false schema: type: integer example: 14 SharingAgreementId: - name: sharing_agreement_id + name: sharingAgreementId in: path description: The ID of the sharing agreement required: true + style: simple + explode: false schema: type: integer example: 1 SkillBasedRoutingAttributeId: - name: attribute_id + name: attributeId in: path description: The ID of the skill-based routing attribute required: true + style: simple + explode: false schema: type: string example: 6e279587-e930-11e8-a292-09cfcdea1b75 SkillBasedRoutingAttributeValueId: - name: attribute_value_id + name: attributeValueId in: path description: The ID of the skill-based routing attribute value required: true + style: simple + explode: false schema: type: string example: b376b35a-e38b-11e8-a292-e3b6377c5575 SkipTicketUserId: - name: user_id + name: userId in: path description: User ID of an agent required: true + style: simple + explode: false schema: type: integer example: 35436 @@ -24161,14 +26208,18 @@ components: in: query description: Subdomain for a given Zendesk account address required: true + style: form + explode: true schema: type: string example: Brand1 SupportAddressId: - name: support_address_id + name: supportAddressId in: path description: The ID of the support address required: true + style: simple + explode: false schema: type: integer example: 33 @@ -24177,6 +26228,8 @@ components: in: path description: id of the suspended ticket required: true + style: simple + explode: false schema: type: number example: 35436 @@ -24184,107 +26237,143 @@ components: name: ids in: query description: A list of suspended ticket ids + required: false + style: form + explode: true schema: type: string - example: 3436,3437 + example: "3436,3437" SuspendedTicketsDeleteIds: name: ids in: query - description: A comma separated list of ids of suspended tickets to delete. + description: A comma separated list of ids of suspended tickets to delete required: true + style: form + explode: true schema: type: string - example: 94,141 + example: "94,141" SuspendedTicketsRecoverIds: name: ids in: query - description: A comma separated list of ids of suspended tickets to recover. + description: A comma separated list of ids of suspended tickets to recover required: true + style: form + explode: true schema: type: string - example: 14,77 + example: "14,77" SuspendedTicketsSortBy: name: sort_by in: query - description: The field to sort the ticket by, being one of `author_email`, `cause`, `created_at`, or `subject`. + description: "The field to sort the ticket by, being one of `author_email`,\ + \ `cause`, `created_at`, or `subject`" + required: false + style: form + explode: true schema: type: string example: author_email + x-ballerina-name: sortBy SuspendedTicketsSortOrder: name: sort_order in: query - description: The order in which to sort the suspended tickets. This can take value `asc` or `desc`. + description: The order in which to sort the suspended tickets. This can take + value `asc` or `desc` + required: false + style: form + explode: true schema: type: string example: asc + x-ballerina-name: sortOrder TagNameFragment: name: name in: query description: A substring of a tag to search for + required: false + style: form + explode: true schema: type: string example: att TargetFailureId: - name: target_failure_id + name: targetFailureId in: path description: The ID of the target failure required: true + style: simple + explode: false schema: type: integer example: 1 TargetId: - name: target_id + name: targetId in: path description: The ID of the target required: true + style: simple + explode: false schema: type: integer example: 211 TicketAuditId: - name: ticket_audit_id + name: ticketAuditId in: path description: The ID of the ticket audit required: true + style: simple + explode: false schema: type: integer example: 2127301143 TicketCommentId: - name: ticket_comment_id + name: ticketCommentId in: path description: The ID of the ticket comment required: true + style: simple + explode: false schema: type: integer example: 35436 TicketFieldId: - name: ticket_field_id + name: ticketFieldId in: path description: The ID of the ticket field required: true + style: simple + explode: false schema: type: integer example: 34 TicketFieldOptionId: - name: ticket_field_option_id + name: ticketFieldOptionId in: path description: The ID of the ticket field option required: true + style: simple + explode: false schema: type: integer example: 10001 TicketFormId: - name: ticket_form_id + name: ticketFormId in: path description: The ID of the ticket form required: true + style: simple + explode: false schema: type: integer example: 47 TicketId: - name: ticket_id + name: ticketId in: path description: The ID of the ticket required: true + style: simple + explode: false schema: type: integer example: 123456 @@ -24293,32 +26382,45 @@ components: in: query description: Comma-separated list of ticket ids required: true + style: form + explode: true schema: type: string - example: 35436,35437 + example: "35436,35437" TicketSortBy: name: sort_by in: query description: Sort by + required: false + style: form + explode: true schema: type: string enum: - - id - - subject - - deleted_at + - id + - subject + - deleted_at + x-ballerina-name: sortBy TicketSortOrder: name: sort_order in: query description: Sort order. Defaults to "asc" + required: false + style: form + explode: true schema: type: string enum: - - asc - - desc + - asc + - desc + x-ballerina-name: sortOrder TriggerActive: name: active in: query description: Filter by active triggers if true or inactive triggers if false + required: false + style: form + explode: true schema: type: boolean example: true @@ -24326,14 +26428,20 @@ components: name: category_id in: query description: Filter triggers by category ID + required: false + style: form + explode: true schema: type: string example: "10026" + x-ballerina-name: categoryId TriggerId: - name: trigger_id + name: triggerId in: path description: The ID of the trigger required: true + style: simple + explode: false schema: type: integer example: 198 @@ -24342,28 +26450,38 @@ components: in: query description: A comma separated list of trigger IDs required: true + style: form + explode: true schema: type: string - example: 131,178,938 + example: "131,178,938" TriggerInclude: name: include in: query - description: A sideload to include in the response. See [Sideloads](#sideloads-2) + description: "A sideload to include in the response. See [Sideloads](#sideloads-2)" + required: false + style: form + explode: true schema: type: string example: usage_24h TriggerRevisionId: - name: trigger_revision_id + name: triggerRevisionId in: path description: The ID of the revision for a particular trigger required: true + style: simple + explode: false schema: type: integer example: 1 TriggerSearchFilter: name: filter in: query - description: Trigger attribute filters for the search. See [Filter](#filter) + description: "Trigger attribute filters for the search. See [Filter](#filter)" + required: false + style: form + explode: true schema: type: object properties: @@ -24374,112 +26492,156 @@ components: in: query description: Query string used to find all triggers with matching title required: true + style: form + explode: true schema: type: string example: important_trigger TriggerSort: name: sort in: query - description: Cursor-based pagination only. Possible values are "alphabetical", "created_at", "updated_at", or "position". + description: "Cursor-based pagination only. Possible values are \"alphabetical\"\ + , \"created_at\", \"updated_at\", or \"position\"" + required: false + style: form + explode: true schema: type: string example: position TriggerSortBy: name: sort_by in: query - description: Offset pagination only. Possible values are "alphabetical", "created_at", "updated_at", "usage_1h", "usage_24h", or "usage_7d". Defaults to "position" + description: "Offset pagination only. Possible values are \"alphabetical\",\ + \ \"created_at\", \"updated_at\", \"usage_1h\", \"usage_24h\", or \"usage_7d\"\ + . Defaults to \"position\"" + required: false + style: form + explode: true schema: type: string example: position + x-ballerina-name: sortBy TriggerSortOrder: name: sort_order in: query - description: One of "asc" or "desc". Defaults to "asc" for alphabetical and position sort, "desc" for all others + description: "One of \"asc\" or \"desc\". Defaults to \"asc\" for alphabetical\ + \ and position sort, \"desc\" for all others" + required: false + style: form + explode: true schema: type: string example: desc + x-ballerina-name: sortOrder UserExternalIdFilter: name: external_id in: query - description: List users by external id. External id has to be unique for each user under the same account. + description: List users by external id. External id has to be unique for each + user under the same account + required: false + style: form + explode: true schema: type: string example: abc + x-ballerina-name: externalId UserFieldId: - name: user_field_id + name: userFieldId in: path description: The ID or key of the user field required: true + style: simple + explode: false schema: oneOf: - - type: integer - - type: string + - type: integer + - type: string example: my_text_field UserFieldOptionId: - name: user_field_option_id + name: userFieldOptionId in: path description: The ID of the user field option required: true + style: simple + explode: false schema: type: integer example: 10001 UserId: - name: user_id + name: userId in: path description: The id of the user required: true + style: simple + explode: false schema: type: integer example: 35436 UserIdentityId: - name: user_identity_id + name: userIdentityId in: path description: The ID of the user identity required: true + style: simple + explode: false schema: type: integer example: 77938 UserPermissionSetFilter: name: permission_set in: query - description: For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request + description: For custom roles which is available on the Enterprise plan and + above. You can only filter by one role ID per request + required: false + style: form + explode: true schema: type: integer example: 123 + x-ballerina-name: permissionSet UserRoleFilter: name: role in: query description: | Filters the results by role. Possible values are "end-user", "agent", or "admin" + required: false + style: form + explode: true schema: type: string enum: - - end-user - - agent - - admin + - end-user + - agent + - admin example: agent UserRolesFilter: name: roles in: query description: | Filters the results by more than one role using the format `role[]={role}&role[]={role}` + required: false + style: form explode: true schema: type: string example: agent ViewId: - name: view_id + name: viewId in: path description: The ID of the view required: true + style: simple + explode: false schema: type: integer example: 25 WorkspaceId: - name: workspace_id + name: workspaceId in: path description: The id of the workspace required: true + style: simple + explode: false schema: type: integer example: 3133 @@ -24561,10 +26723,10 @@ components: cdn_provider: default fallback_cdn_provider: cloudfront hosts: - - name: default - url: https://p18.zdassets.com - - name: cloudfront - url: https://d2y9oszrd3dhjh.cloudfront.net + - name: default + url: https://p18.zdassets.com + - name: cloudfront + url: https://d2y9oszrd3dhjh.cloudfront.net chat: available: true enabled: false @@ -24585,7 +26747,7 @@ components: attachment_size: 52428800 localization: locale_ids: - - 1042 + - 1042 lotus: pod_id: 999 prefer_lotus: true @@ -24621,7 +26783,7 @@ components: ticket_forms_instructions: Please choose your issue below ticket_sharing_partners: support_addresses: - - support@grokpetre.zendesk.com + - support@grokpetre.zendesk.com tickets: accepted_new_collaboration_tos: false agent_collision: true @@ -24674,137 +26836,15 @@ components: ActivitiesCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 ActivitiesResponseExample: value: activities: - - actor: - active: true - alias: "" - created_at: "2020-11-17T00:32:12Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: cgoddard+ted@zendesk.com - external_id: null - iana_time_zone: America/Juneau - id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Tedd - notes: "" - only_private_comments: false - organization_id: null - phone: null - photo: null - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: "" - suspended: false - tags: [] - ticket_restriction: null - time_zone: Alaska - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" - url: https://example.zendesk.com/api/v2/users/158488612.json - user_fields: - its_remember_september: null - skittles: null - user_field_1: null - verified: true - actor_id: 158488612 - created_at: "2020-11-17T00:34:40Z" - id: 29183462 - object: - ticket: - id: 1521 - subject: test - target: - ticket: - id: 1521 - subject: test - title: 'Tedd assigned ticket #1521 to you.' - updated_at: "2020-11-17T00:34:40Z" - url: https://example.zendesk.com/api/v2/activities/29183462.json - user: - active: true - alias: test - created_at: "2017-08-14T20:13:53Z" - custom_role_id: null - default_group_id: 1873 - details: "" - email: user@zendesk.com - external_id: oev7jj - iana_time_zone: Pacific/Pago_Pago - id: 3343 - last_login_at: "2020-11-16T22:57:45Z" - locale: en-gb - locale_id: 5 - moderator: true - name: Samwise Gamgee - notes: test - only_private_comments: false - organization_id: 1873 - phone: null - photo: - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - deleted: false - file_name: 1f84950b8d7949b3.gif - height: 80 - id: 8730791 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif - size: 4566 - thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 - url: https://example.zendesk.com/api/v2/attachments/8730791.json - width: 80 - report_csv: true - restricted_agent: false - role: admin - role_type: null - shared: false - shared_agent: false - shared_phone_number: null - signature: test - suspended: false - tags: - - "101" - ticket_restriction: null - time_zone: American Samoa - two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" - url: https://example.zendesk.com/api/v2/users/3343.json - user_fields: - its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" - user_field_1: "101" - verified: true - user_id: 3343 - verb: tickets.assignment - actors: - - active: true + - actor: + active: true alias: "" - created_at: "2020-11-17T00:32:12Z" + created_at: 2020-11-17T00:32:12Z custom_role_id: null default_group_id: 1873 details: "" @@ -24812,7 +26852,7 @@ components: external_id: null iana_time_zone: America/Juneau id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" + last_login_at: 2020-11-17T00:33:44Z locale: en-gb locale_id: 5 moderator: true @@ -24835,20 +26875,31 @@ components: ticket_restriction: null time_zone: Alaska two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" + updated_at: 2020-11-17T00:34:38Z url: https://example.zendesk.com/api/v2/users/158488612.json user_fields: its_remember_september: null skittles: null user_field_1: null verified: true - count: 1 - next_page: null - previous_page: null - users: - - active: true + actor_id: 158488612 + created_at: 2020-11-17T00:34:40Z + id: 29183462 + object: + ticket: + id: 1521 + subject: test + target: + ticket: + id: 1521 + subject: test + title: "Tedd assigned ticket #1521 to you." + updated_at: 2020-11-17T00:34:40Z + url: https://example.zendesk.com/api/v2/activities/29183462.json + user: + active: true alias: test - created_at: "2017-08-14T20:13:53Z" + created_at: 2017-08-14T20:13:53Z custom_role_id: null default_group_id: 1873 details: "" @@ -24856,7 +26907,7 @@ components: external_id: oev7jj iana_time_zone: Pacific/Pago_Pago id: 3343 - last_login_at: "2020-11-16T22:57:45Z" + last_login_at: 2020-11-16T22:57:45Z locale: en-gb locale_id: 5 moderator: true @@ -24876,17 +26927,17 @@ components: mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif size: 4566 thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 url: https://example.zendesk.com/api/v2/attachments/8730791.json width: 80 report_csv: true @@ -24899,24 +26950,135 @@ components: signature: test suspended: false tags: - - "101" + - "101" ticket_restriction: null time_zone: American Samoa two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" + updated_at: 2020-11-17T00:33:55Z url: https://example.zendesk.com/api/v2/users/3343.json user_fields: its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" + skittles: 2018-09-14T00:00:00+00:00 user_field_1: "101" verified: true + user_id: 3343 + verb: tickets.assignment + actors: + - active: true + alias: "" + created_at: 2020-11-17T00:32:12Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: cgoddard+ted@zendesk.com + external_id: null + iana_time_zone: America/Juneau + id: 158488612 + last_login_at: 2020-11-17T00:33:44Z + locale: en-gb + locale_id: 5 + moderator: true + name: Tedd + notes: "" + only_private_comments: false + organization_id: null + phone: null + photo: null + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: "" + suspended: false + tags: [] + ticket_restriction: null + time_zone: Alaska + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:34:38Z + url: https://example.zendesk.com/api/v2/users/158488612.json + user_fields: + its_remember_september: null + skittles: null + user_field_1: null + verified: true + count: 1 + next_page: null + previous_page: null + users: + - active: true + alias: test + created_at: 2017-08-14T20:13:53Z + custom_role_id: null + default_group_id: 1873 + details: "" + email: user@zendesk.com + external_id: oev7jj + iana_time_zone: Pacific/Pago_Pago + id: 3343 + last_login_at: 2020-11-16T22:57:45Z + locale: en-gb + locale_id: 5 + moderator: true + name: Samwise Gamgee + notes: test + only_private_comments: false + organization_id: 1873 + phone: null + photo: + content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + deleted: false + file_name: 1f84950b8d7949b3.gif + height: 80 + id: 8730791 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif + size: 4566 + thumbnails: + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 + url: https://example.zendesk.com/api/v2/attachments/8730791.json + width: 80 + report_csv: true + restricted_agent: false + role: admin + role_type: null + shared: false + shared_agent: false + shared_phone_number: null + signature: test + suspended: false + tags: + - "101" + ticket_restriction: null + time_zone: American Samoa + two_factor_auth_enabled: null + updated_at: 2020-11-17T00:33:55Z + url: https://example.zendesk.com/api/v2/users/3343.json + user_fields: + its_remember_september: null + skittles: 2018-09-14T00:00:00+00:00 + user_field_1: "101" + verified: true ActivityResponseExample: value: activity: actor: active: true alias: "" - created_at: "2020-11-17T00:32:12Z" + created_at: 2020-11-17T00:32:12Z custom_role_id: null default_group_id: 1873 details: "" @@ -24924,7 +27086,7 @@ components: external_id: null iana_time_zone: America/Juneau id: 158488612 - last_login_at: "2020-11-17T00:33:44Z" + last_login_at: 2020-11-17T00:33:44Z locale: en-gb locale_id: 5 moderator: true @@ -24947,7 +27109,7 @@ components: ticket_restriction: null time_zone: Alaska two_factor_auth_enabled: null - updated_at: "2020-11-17T00:34:38Z" + updated_at: 2020-11-17T00:34:38Z url: https://example.zendesk.com/api/v2/users/158488612.json user_fields: its_remember_september: null @@ -24955,7 +27117,7 @@ components: user_field_1: null verified: true actor_id: 158488612 - created_at: "2020-11-17T00:34:40Z" + created_at: 2020-11-17T00:34:40Z id: 29183462 object: ticket: @@ -24965,13 +27127,13 @@ components: ticket: id: 1521 subject: test - title: 'Tedd assigned ticket #1521 to you.' - updated_at: "2020-11-17T00:34:40Z" + title: "Tedd assigned ticket #1521 to you." + updated_at: 2020-11-17T00:34:40Z url: https://example.zendesk.com/api/v2/activities/29183462.json user: active: true alias: test - created_at: "2017-08-14T20:13:53Z" + created_at: 2017-08-14T20:13:53Z custom_role_id: null default_group_id: 1873 details: "" @@ -24979,7 +27141,7 @@ components: external_id: oev7jj iana_time_zone: Pacific/Pago_Pago id: 3343 - last_login_at: "2020-11-16T22:57:45Z" + last_login_at: 2020-11-16T22:57:45Z locale: en-gb locale_id: 5 moderator: true @@ -24999,17 +27161,17 @@ components: mapped_content_url: https://example.zendesk.com/system/photos/8730791/1f84950b8d7949b3.gif size: 4566 thumbnails: - - content_type: image/gif - content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - deleted: false - file_name: 1f84950b8d7949b3_thumb.gif - height: 32 - id: 8730801 - inline: false - mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif - size: 1517 - url: https://example.zendesk.com/api/v2/attachments/8730801.json - width: 32 + - content_type: image/gif + content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + deleted: false + file_name: 1f84950b8d7949b3_thumb.gif + height: 32 + id: 8730801 + inline: false + mapped_content_url: https://example.zendesk.com/system/photos/8730801/1f84950b8d7949b3_thumb.gif + size: 1517 + url: https://example.zendesk.com/api/v2/attachments/8730801.json + width: 32 url: https://example.zendesk.com/api/v2/attachments/8730791.json width: 80 report_csv: true @@ -25022,15 +27184,15 @@ components: signature: test suspended: false tags: - - "101" + - "101" ticket_restriction: null time_zone: American Samoa two_factor_auth_enabled: null - updated_at: "2020-11-17T00:33:55Z" + updated_at: 2020-11-17T00:33:55Z url: https://example.zendesk.com/api/v2/users/3343.json user_fields: its_remember_september: null - skittles: "2018-09-14T00:00:00+00:00" + skittles: 2018-09-14T00:00:00+00:00 user_field_1: "101" verified: true user_id: 3343 @@ -25038,50 +27200,50 @@ components: AddTagsByObjectIdResponseExample: value: tags: - - urgent - - printer - - fire - - paper + - urgent + - printer + - fire + - paper AssigneeFieldAssignableGroupAgentsResponseExample: value: agents: - - avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png - id: 6473829100 - name: Joe Smith - - avatar_url: https://z3n-example.zendesk.com/system/photos/412005192023/my_profile.png - id: 9182736400 - name: Jane Doe - - avatar_url: https://z3n-example.zendesk.com/system/photos/887005192023/my_profile.png - id: 1928373460 - name: Cookie Monster + - avatar_url: https://z3n-example.zendesk.com/system/photos/900005192023/my_profile.png + id: 6473829100 + name: Joe Smith + - avatar_url: https://z3n-example.zendesk.com/system/photos/412005192023/my_profile.png + id: 9182736400 + name: Jane Doe + - avatar_url: https://z3n-example.zendesk.com/system/photos/887005192023/my_profile.png + id: 1928373460 + name: Cookie Monster count: 3 next_page: null previous_page: null AssigneeFieldAssignableGroupsAndAgentsSearchResponseExample: value: agents: - - group: Tech - group_id: 6574839201 - id: 8392017465 - name: Sam Technologist - photo_url: https://z3n-example.zendesk.com/system/photos/410305192023/my_profile.png + - group: Tech + group_id: 6574839201 + id: 8392017465 + name: Sam Technologist + photo_url: https://z3n-example.zendesk.com/system/photos/410305192023/my_profile.png count: 2 groups: - - id: 6574839201 - name: Tech + - id: 6574839201 + name: Tech AssigneeFieldAssignableGroupsResponseExample: value: count: 3 groups: - - description: Engineering - id: 9182736455 - name: Group for Bugs for Engineering - - description: Product - id: 1928374655 - name: Group for feature requests - - description: Customer Support - id: 5519283746 - name: Group for customer inquiries + - description: Engineering + id: 9182736455 + name: Group for Bugs for Engineering + - description: Product + id: 1928374655 + name: Group for feature requests + - description: Customer Support + id: 5519283746 + name: Group for customer inquiries next_page: null previous_page: null AttachmentResponseExample: @@ -25115,18 +27277,18 @@ components: url: https://company.zendesk.com/api/v2/attachments/1503729607981.json width: "80" attachments: - - content_type: image/png - content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=crash.png - deleted: false - file_name: crash.png - height: "62" - id: 1503729607981 - inline: false - mapped_content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=crash.png - size: 5172 - thumbnails: [] - url: https://company.zendesk.com/api/v2/attachments/1503729607981.json - width: "80" + - content_type: image/png + content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=crash.png + deleted: false + file_name: crash.png + height: "62" + id: 1503729607981 + inline: false + mapped_content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=crash.png + size: 5172 + thumbnails: [] + url: https://company.zendesk.com/api/v2/attachments/1503729607981.json + width: "80" token: LXJdriewLBP8JrtzzkN7Ne4k6 AuditLogResponseExample: value: @@ -25135,7 +27297,7 @@ components: actor_id: 1234 actor_name: Sameer Patel change_description: Role changed from Administrator to End User - created_at: "2012-03-05T11:32:44Z" + created_at: 2012-03-05T11:32:44Z id: 498483 ip_address: 209.119.38.228 source_id: 3456 @@ -25145,77 +27307,77 @@ components: AuditLogsResponseExample: value: audit_logs: - - action: update - actor_id: 1234 - actor_name: Sameer Patel - change_description: Role changed from Administrator to End User - created_at: "2012-03-05T11:32:44Z" - id: 498483 - ip_address: 209.119.38.228 - source_id: 3456 - source_label: John Doe - source_type: user - url: https://company.zendesk.com/api/v2/audit_logs/498483.json + - action: update + actor_id: 1234 + actor_name: Sameer Patel + change_description: Role changed from Administrator to End User + created_at: 2012-03-05T11:32:44Z + id: 498483 + ip_address: 209.119.38.228 + source_id: 3456 + source_label: John Doe + source_type: user + url: https://company.zendesk.com/api/v2/audit_logs/498483.json AutocompleteOrganizationsResponseExample: value: count: 2 next_page: null organizations: - - created_at: "2018-11-14T00:14:52Z" - details: caterpillar =) - domain_names: - - remain.com - external_id: null - group_id: 1835962 - id: 35436 - name: Important Customers - notes: donkey - organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" - org_field_1: happy happy - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" - url: https://example.zendesk.com/api/v2/organizations/4112492.json - - created_at: "2017-08-14T20:13:52Z" - details: test - domain_names: - - test.com - external_id: null - group_id: null - id: 20057623 - name: Imperial College - notes: "" - organization_fields: - datepudding: "2018-11-02T00:00:00+00:00" - org_field_1: malarky - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - teapot_kettle - updated_at: "2019-05-16T01:27:46Z" - url: https://example.zendesk.com.com/api/v2/organizations/1873.json + - created_at: 2018-11-14T00:14:52Z + details: caterpillar =) + domain_names: + - remain.com + external_id: null + group_id: 1835962 + id: 35436 + name: Important Customers + notes: donkey + organization_fields: + datepudding: 2018-11-04T00:00:00+00:00 + org_field_1: happy happy + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z + url: https://example.zendesk.com/api/v2/organizations/4112492.json + - created_at: 2017-08-14T20:13:52Z + details: test + domain_names: + - test.com + external_id: null + group_id: null + id: 20057623 + name: Imperial College + notes: "" + organization_fields: + datepudding: 2018-11-02T00:00:00+00:00 + org_field_1: malarky + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - teapot_kettle + updated_at: 2019-05-16T01:27:46Z + url: https://example.zendesk.com.com/api/v2/organizations/1873.json previous_page: null AutomationCreateResponseExample: value: automation: actions: - - field: priority - value: high + - field: priority + value: high active: true conditions: all: - - field: status - operator: is - value: open - - field: priority - operator: less_than - value: high + - field: status + operator: is + value: open + - field: priority + operator: less_than + value: high any: [] id: 9873843 position: 8 @@ -25225,23 +27387,23 @@ components: value: automation: actions: - - field: status - value: open - - field: assignee_id - value: "296220096" + - field: status + value: open + - field: assignee_id + value: "296220096" active: true conditions: all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" any: - - field: current_tags - operator: includes - value: hello + - field: current_tags + operator: includes + value: hello id: 25 position: 8 raw_title: Close and Save @@ -25249,150 +27411,150 @@ components: AutomationsResponseExample: value: automations: - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 25 - position: 8 - raw_title: Close and Save - title: Close and Save - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: false - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 26 - position: 9 - raw_title: '{{dc.assign_priority_tag}}' - title: Assign priority tag + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 25 + position: 8 + raw_title: Close and Save + title: Close and Save + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: false + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 26 + position: 9 + raw_title: "{{dc.assign_priority_tag}}" + title: Assign priority tag count: 2 next_page: null previous_page: null AutomationsSearchResponseExample: value: automations: - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 25 - position: 9 - raw_title: Close and Save - title: Close and Save - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 28 - position: 9 - raw_title: '{{dc.close_and_redirect}}' - title: Close and redirect to topics + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 25 + position: 9 + raw_title: Close and Save + title: Close and Save + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 28 + position: 9 + raw_title: "{{dc.close_and_redirect}}" + title: Close and redirect to topics count: 2 next_page: null previous_page: null AutomationsUpdateManyResponseExample: value: automations: - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 25 - position: 15 - raw_title: Close and Save - title: Close and Save - - actions: - - field: status - value: open - - field: assignee_id - value: "296220096" - active: false - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: current_tags - operator: includes - value: hello - id: 26 - position: 8 - raw_title: '{{dc.assign_priority_tag}}' - title: Assign priority tag + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 25 + position: 15 + raw_title: Close and Save + title: Close and Save + - actions: + - field: status + value: open + - field: assignee_id + value: "296220096" + active: false + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: current_tags + operator: includes + value: hello + id: 26 + position: 8 + raw_title: "{{dc.assign_priority_tag}}" + title: Assign priority tag count: 2 next_page: null previous_page: null @@ -25403,7 +27565,7 @@ components: BookmarkResponse: value: bookmark: - created_at: "2020-10-01T08:33:45Z" + created_at: 2020-10-01T08:33:45Z id: 900000009567 ticket: id: 123 @@ -25411,31 +27573,31 @@ components: raw_subject: Chat with Visitor 19785128 requester_id: 156 subject: Chat with Visitor 19785128 - url: https://{subdomain}.zendesk.com/api/v2/tickets/123.json - url: https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001111.json + url: "https://{subdomain}.zendesk.com/api/v2/tickets/123.json" + url: "https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001111.json" BookmarksResponse: value: bookmarks: - - created_at: "2020-10-01T08:33:45Z" - id: 900000009567 - ticket: - id: 123 - priority: high - raw_subject: Chat with Visitor 19785128 - requester_id: 165 - subject: Chat with Visitor 19785128 - url: https://{subdomain}.zendesk.com/api/v2/tickets/123.json - url: https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001111.json - - created_at: "2020-09-11T10:22:45Z" - id: 900000009568 - ticket: - id: 123 - priority: high - raw_subject: Chat with Visitor 19785128 - requester_id: 156 - subject: Chat with Visitor 19785128 - url: https://{subdomain}.zendesk.com/api/v2/tickets/123.json - url: https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001112.json + - created_at: 2020-10-01T08:33:45Z + id: 900000009567 + ticket: + id: 123 + priority: high + raw_subject: Chat with Visitor 19785128 + requester_id: 165 + subject: Chat with Visitor 19785128 + url: "https://{subdomain}.zendesk.com/api/v2/tickets/123.json" + url: "https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001111.json" + - created_at: 2020-09-11T10:22:45Z + id: 900000009568 + ticket: + id: 123 + priority: high + raw_subject: Chat with Visitor 19785128 + requester_id: 156 + subject: Chat with Visitor 19785128 + url: "https://{subdomain}.zendesk.com/api/v2/tickets/123.json" + url: "https://{subdomain}.zendesk.com/api/v2/bookmarks/900000001112.json" count: 1 next_page: null previous_page: null @@ -25449,7 +27611,7 @@ components: brand: active: true brand_url: https://brand1.zendesk.com - created_at: "2019-08-06T02:43:39Z" + created_at: 2019-08-06T02:43:39Z default: true has_help_center: true help_center_state: enabled @@ -25464,27 +27626,27 @@ components: mapped_content_url: https://company.com/logos/brand1_logo.png size: 166144 thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png - file_name: brand1_logo_thumb.png - id: 928375 - mapped_content_url: https://company.com/photos/brand1_logo_thumb.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928375.json - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_small.png - file_name: brand1_logo_small.png - id: 928376 - mapped_content_url: https://company.com/photos/brand1_logo_small.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928376.json + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png + file_name: brand1_logo_thumb.png + id: 928375 + mapped_content_url: https://company.com/photos/brand1_logo_thumb.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928375.json + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_small.png + file_name: brand1_logo_small.png + id: 928376 + mapped_content_url: https://company.com/photos/brand1_logo_small.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928376.json url: https://company.zendesk.com/api/v2/attachments/928374.json name: Brand 1 - signature_template: '{{agent.signature}}' + signature_template: "{{agent.signature}}" subdomain: hello-world ticket_form_ids: - - 360000660811 - updated_at: "2019-08-06T02:43:40Z" + - 360000660811 + updated_at: 2019-08-06T02:43:40Z url: https://company.zendesk.com/api/v2/brands/360002783572.json BrandUpdateRequestExample: value: @@ -25496,105 +27658,105 @@ components: BrandsResponseExample: value: brands: - - active: true - brand_url: https://brand1.zendesk.com - created_at: "2019-08-06T02:43:39Z" - default: true - has_help_center: true - help_center_state: enabled - host_mapping: brand1.com - id: 360002783572 - is_deleted: false - logo: - content_type: image/png - content_url: https://company.zendesk.com/logos/brand1_logo.png - file_name: brand1_logo.png - id: 928374 - mapped_content_url: https://company.com/logos/brand1_logo.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png - file_name: brand1_logo_thumb.png - id: 928375 - mapped_content_url: https://company.com/photos/brand1_logo_thumb.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928375.json - - content_type: image/png - content_url: https://company.zendesk.com/photos/brand1_logo_small.png - file_name: brand1_logo_small.png - id: 928376 - mapped_content_url: https://company.com/photos/brand1_logo_small.png - size: 58298 - url: https://company.zendesk.com/api/v2/attachments/928376.json - url: https://company.zendesk.com/api/v2/attachments/928374.json - name: Brand 1 - signature_template: '{{agent.signature}}' - subdomain: hello-world - ticket_form_ids: - - 360000660811 - updated_at: "2019-08-06T02:43:40Z" - url: https://company.zendesk.com/api/v2/brands/360002783572.json + - active: true + brand_url: https://brand1.zendesk.com + created_at: 2019-08-06T02:43:39Z + default: true + has_help_center: true + help_center_state: enabled + host_mapping: brand1.com + id: 360002783572 + is_deleted: false + logo: + content_type: image/png + content_url: https://company.zendesk.com/logos/brand1_logo.png + file_name: brand1_logo.png + id: 928374 + mapped_content_url: https://company.com/logos/brand1_logo.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_thumb.png + file_name: brand1_logo_thumb.png + id: 928375 + mapped_content_url: https://company.com/photos/brand1_logo_thumb.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928375.json + - content_type: image/png + content_url: https://company.zendesk.com/photos/brand1_logo_small.png + file_name: brand1_logo_small.png + id: 928376 + mapped_content_url: https://company.com/photos/brand1_logo_small.png + size: 58298 + url: https://company.zendesk.com/api/v2/attachments/928376.json + url: https://company.zendesk.com/api/v2/attachments/928374.json + name: Brand 1 + signature_template: "{{agent.signature}}" + subdomain: hello-world + ticket_form_ids: + - 360000660811 + updated_at: 2019-08-06T02:43:40Z + url: https://company.zendesk.com/api/v2/brands/360002783572.json count: 1 next_page: null previous_page: null BulkUpdateDefaultCustomStatusRequestExample: value: - ids: 1234567,1234577 + ids: "1234567,1234577" BulkUpdateDefaultCustomStatusResponseExample: value: {} ChannelFrameworkPushResultsResponseExample: value: results: - - external_resource_id: "234" - status: - code: could_not_locate_parent_external_resource - description: "123" + - external_resource_id: "234" + status: + code: could_not_locate_parent_external_resource + description: "123" ComplianceDeletionStatusesResponseExample: value: compliance_deletion_statuses: - - account_subdomain: accountABC - action: request_deletion - application: all - created_at: "2009-07-20T22:55:23Z" - executer_id: 2000 - user_id: 1 - - account_subdomain: accountABC - action: started - application: support - created_at: "2009-07-20T22:55:29Z" - executer_id: null - user_id: 1 - - account_subdomain: accountABC - action: complete - application: support - created_at: "2009-07-20T22:57:02Z" - executer_id: null - user_id: 1 - - account_subdomain: accountABC - action: started - application: chat - created_at: "2009-07-21T02:51:18Z" - executer_id: null - user_id: 1 + - account_subdomain: accountABC + action: request_deletion + application: all + created_at: 2009-07-20T22:55:23Z + executer_id: 2000 + user_id: 1 + - account_subdomain: accountABC + action: started + application: support + created_at: 2009-07-20T22:55:29Z + executer_id: null + user_id: 1 + - account_subdomain: accountABC + action: complete + application: support + created_at: 2009-07-20T22:57:02Z + executer_id: null + user_id: 1 + - account_subdomain: accountABC + action: started + application: chat + created_at: 2009-07-21T02:51:18Z + executer_id: null + user_id: 1 CountOrganizationsResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 CreateMacroResponseExample: value: macro: actions: - - field: status - value: solved + - field: status + value: solved id: 25 restriction: {} title: Roger Wilco CreatedOrganizationResponseExample: value: organization: - created_at: "2020-09-30T01:50:12Z" + created_at: 2020-09-30T01:50:12Z details: null domain_names: [] external_id: null @@ -25606,7 +27768,7 @@ components: shared_comments: false shared_tickets: false tags: [] - updated_at: "2020-09-30T01:50:12Z" + updated_at: 2020-09-30T01:50:12Z url: https://example.zendesk.com/api/v2/organizations/23409462.json CurrentUserResponseExample: value: @@ -25617,110 +27779,110 @@ components: CursorBasedExportIncrementalTicketsResponseExample: value: after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 - after_url: https://{subdomain}.zendesk.com/api/v2/incremental/tickets/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8 + after_url: "https://{subdomain}.zendesk.com/api/v2/incremental/tickets/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8" before_cursor: null before_url: null end_of_stream: true tickets: - - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - from_messaging_channel: false - group_id: 98738 - has_incidents: false - id: 35436 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web + - assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + from_messaging_channel: false + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web CursorBasedExportIncrementalUsersResponseExample: value: after_cursor: MTU3NjYxMzUzOS4wfHw0Njd8 - after_url: https://{subdomain}.zendesk.com/api/v2/incremental/users/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8 + after_url: "https://{subdomain}.zendesk.com/api/v2/incremental/users/cursor.json?cursor=MTU3NjYxMzUzOS4wfHw0Njd8" before_cursor: null before_url: null end_of_stream: true users: - - active: true - alias: Mr. Johnny - created_at: "2009-07-20T22:55:29Z" - custom_role_id: 9373643 - details: "" - email: johnny@example.com - external_id: sai989sur98w9 - id: 35436 - last_login_at: "2011-05-05T10:38:52Z" - locale: en-US - locale_id: 1 - moderator: true - name: Johnny Agent - notes: Johnny is a nice guy! - only_private_comments: false - organization_id: 57542 - phone: "+15551234567" - photo: - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png - id: 928374 - name: my_funny_profile_pic.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png - id: 928375 - name: my_funny_profile_pic_thumb.png - size: 58298 - restricted_agent: true - role: agent - role_type: 0 - shared: false - shared_agent: false - signature: Have a nice day, Johnny - suspended: true - tags: - - enterprise - - other_tag - ticket_restriction: assigned - time_zone: Copenhagen - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/users/35436.json - user_fields: - user_date: "2012-07-23T00:00:00Z" - user_decimal: 5.1 - user_dropdown: option_1 - verified: true + - active: true + alias: Mr. Johnny + created_at: 2009-07-20T22:55:29Z + custom_role_id: 9373643 + details: "" + email: johnny@example.com + external_id: sai989sur98w9 + id: 35436 + last_login_at: 2011-05-05T10:38:52Z + locale: en-US + locale_id: 1 + moderator: true + name: Johnny Agent + notes: Johnny is a nice guy! + only_private_comments: false + organization_id: 57542 + phone: "+15551234567" + photo: + content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png + id: 928374 + name: my_funny_profile_pic.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png + id: 928375 + name: my_funny_profile_pic_thumb.png + size: 58298 + restricted_agent: true + role: agent + role_type: 0 + shared: false + shared_agent: false + signature: "Have a nice day, Johnny" + suspended: true + tags: + - enterprise + - other_tag + ticket_restriction: assigned + time_zone: Copenhagen + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/users/35436.json + user_fields: + user_date: 2012-07-23T00:00:00Z + user_decimal: 5.1 + user_dropdown: option_1 + verified: true CustomObjectFieldCreateResponseExample: value: custom_object_field: @@ -25737,7 +27899,7 @@ components: title: Make type: text updated_at: 2022-09-07T23:22:00Z - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842879 + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842879" CustomObjectFieldsCreateRequestExample: value: custom_object_field: @@ -25751,78 +27913,78 @@ components: CustomObjectFieldsResponseExample: value: custom_object_fields: - - active: true - created_at: 2022-09-07T23:21:59Z - description: Name - id: 4398096842877 - key: standard::name - position: 0 - raw_description: Name - raw_title: Name - regexp_for_validation: null - system: false - title: Name - type: text - updated_at: 2022-09-07T23:22:00Z - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842877 - - active: true - created_at: 2022-09-07T23:21:59Z - description: External ID - id: 4398096842878 - key: standard::external_id - position: 1 - raw_description: External ID - raw_title: External ID - regexp_for_validation: null - system: false - title: External ID - type: text - updated_at: 2022-09-07T23:22:00Z - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842878 - - active: true - created_at: 2022-09-07T23:22:14Z - description: Model - id: 4398096843007 - key: model - position: 2 - raw_description: Model - raw_title: Model - regexp_for_validation: null - system: false - title: Model - type: text - updated_at: 2022-09-07T23:22:14Z - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096843007 + - active: true + created_at: 2022-09-07T23:21:59Z + description: Name + id: 4398096842877 + key: standard::name + position: 0 + raw_description: Name + raw_title: Name + regexp_for_validation: null + system: false + title: Name + type: text + updated_at: 2022-09-07T23:22:00Z + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842877" + - active: true + created_at: 2022-09-07T23:21:59Z + description: External ID + id: 4398096842878 + key: standard::external_id + position: 1 + raw_description: External ID + raw_title: External ID + regexp_for_validation: null + system: false + title: External ID + type: text + updated_at: 2022-09-07T23:22:00Z + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096842878" + - active: true + created_at: 2022-09-07T23:22:14Z + description: Model + id: 4398096843007 + key: model + position: 2 + raw_description: Model + raw_title: Model + regexp_for_validation: null + system: false + title: Model + type: text + updated_at: 2022-09-07T23:22:14Z + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/fields.json?id=4398096843007" CustomObjectRecordsAutocompleteResponseExample: value: count: 100 custom_object_records: - - created_at: "2022-09-12T19:29:59Z" - created_by_user_id: "10001" - custom_object_fields: - make: Tesla - model: S - custom_object_key: car - external_id: Internal System Record 54848 - id: 01GCSJW391QVSC80GYDH7E93Q6 - name: My Tesla CO record - updated_at: "2022-09-15T21:07:03Z" - updated_by_user_id: "10001" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json - - created_at: "2022-09-26T22:24:15Z" - created_by_user_id: "123123" - custom_object_fields: - make: Honda - model: Civic - custom_object_key: car - external_id: null - id: 01GDXYD7ZTWYP542BA8MDDTE36 - name: My Tesla CO record2 - updated_at: "2022-09-26T22:24:15Z" - updated_by_user_id: "245159" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json + - created_at: 2022-09-12T19:29:59Z + created_by_user_id: "10001" + custom_object_fields: + make: Tesla + model: S + custom_object_key: car + external_id: Internal System Record 54848 + id: 01GCSJW391QVSC80GYDH7E93Q6 + name: My Tesla CO record + updated_at: 2022-09-15T21:07:03Z + updated_by_user_id: "10001" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json" + - created_at: 2022-09-26T22:24:15Z + created_by_user_id: "123123" + custom_object_fields: + make: Honda + model: Civic + custom_object_key: car + external_id: null + id: 01GDXYD7ZTWYP542BA8MDDTE36 + name: My Tesla CO record2 + updated_at: 2022-09-26T22:24:15Z + updated_by_user_id: "245159" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json" links: - next: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/autocomplete.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query= + next: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/autocomplete.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query=" prev: null meta: after_cursor: eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0= @@ -25833,20 +27995,20 @@ components: job: action: create items: - - custom_object_fields: - color: Red - year: 2020 - name: 2020 Tesla - - custom_object_fields: - color: Blue - external_id: ddd444 - year: 2012 - name: 2012 Toyota - - custom_object_fields: - color: Silver - external_id: ddd445 - year: 2017 - name: 2017 Ford + - custom_object_fields: + color: Red + year: 2020 + name: 2020 Tesla + - custom_object_fields: + color: Blue + external_id: ddd444 + year: 2012 + name: 2012 Toyota + - custom_object_fields: + color: Silver + external_id: ddd445 + year: 2017 + name: 2017 Ford CustomObjectRecordsCreateRequestExample: value: custom_object_record: @@ -25857,7 +28019,7 @@ components: CustomObjectRecordsCreateResponseExample: value: custom_object_record: - created_at: "2022-09-26T22:25:10Z" + created_at: 2022-09-26T22:25:10Z created_by_user_id: "10001" custom_object_fields: color: white @@ -25869,36 +28031,36 @@ components: name: My Tesla updated_at: 2022-09-26T22:25:10Z updated_by_user_id: "10001" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYEY1FQYN066VHF49YHJ21.json + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYEY1FQYN066VHF49YHJ21.json" CustomObjectRecordsIndexResponseExample: value: custom_object_records: - - created_at: "2022-09-12T19:29:59Z" - created_by_user_id: "10001" - custom_object_fields: - make: Tesla - model: S - custom_object_key: car - external_id: Internal System Record 54848 - id: 01GCSJW391QVSC80GYDH7E93Q6 - name: My Tesla CO record - updated_at: "2022-09-15T21:07:03Z" - updated_by_user_id: "10001" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json - - created_at: "2022-09-26T22:24:15Z" - created_by_user_id: "123123" - custom_object_fields: - make: Honda - model: Civic - custom_object_key: car - external_id: null - id: 01GDXYD7ZTWYP542BA8MDDTE36 - name: My Tesla CO record2 - updated_at: "2022-09-26T22:24:15Z" - updated_by_user_id: "245159" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json + - created_at: 2022-09-12T19:29:59Z + created_by_user_id: "10001" + custom_object_fields: + make: Tesla + model: S + custom_object_key: car + external_id: Internal System Record 54848 + id: 01GCSJW391QVSC80GYDH7E93Q6 + name: My Tesla CO record + updated_at: 2022-09-15T21:07:03Z + updated_by_user_id: "10001" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json" + - created_at: 2022-09-26T22:24:15Z + created_by_user_id: "123123" + custom_object_fields: + make: Honda + model: Civic + custom_object_key: car + external_id: null + id: 01GDXYD7ZTWYP542BA8MDDTE36 + name: My Tesla CO record2 + updated_at: 2022-09-26T22:24:15Z + updated_by_user_id: "245159" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json" links: - next: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query= + next: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query=" prev: null meta: after_cursor: eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0= @@ -25913,7 +28075,7 @@ components: results: null status: queued total: 2 - url: https://{subdomain}.zendesk.com/api/v2/job_statuses/V3-291e720c98aef4d953563ab090486213.json + url: "https://{subdomain}.zendesk.com/api/v2/job_statuses/V3-291e720c98aef4d953563ab090486213.json" CustomObjectRecordsLimitResponseExample: value: count: 10294 @@ -25922,32 +28084,32 @@ components: value: count: 100 custom_object_records: - - created_at: "2022-09-12T19:29:59Z" - created_by_user_id: "10001" - custom_object_fields: - make: Tesla - model: S - custom_object_key: car - external_id: Internal System Record 54848 - id: 01GCSJW391QVSC80GYDH7E93Q6 - name: My Tesla CO record - updated_at: "2022-09-15T21:07:03Z" - updated_by_user_id: "10001" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json - - created_at: "2022-09-26T22:24:15Z" - created_by_user_id: "123123" - custom_object_fields: - make: Honda - model: Civic - custom_object_key: car - external_id: null - id: 01GDXYD7ZTWYP542BA8MDDTE36 - name: My Tesla CO record2 - updated_at: "2022-09-26T22:24:15Z" - updated_by_user_id: "245159" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json + - created_at: 2022-09-12T19:29:59Z + created_by_user_id: "10001" + custom_object_fields: + make: Tesla + model: S + custom_object_key: car + external_id: Internal System Record 54848 + id: 01GCSJW391QVSC80GYDH7E93Q6 + name: My Tesla CO record + updated_at: 2022-09-15T21:07:03Z + updated_by_user_id: "10001" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GCSJW391QVSC80GYDH7E93Q6.json" + - created_at: 2022-09-26T22:24:15Z + created_by_user_id: "123123" + custom_object_fields: + make: Honda + model: Civic + custom_object_key: car + external_id: null + id: 01GDXYD7ZTWYP542BA8MDDTE36 + name: My Tesla CO record2 + updated_at: 2022-09-26T22:24:15Z + updated_by_user_id: "245159" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYD7ZTWYP542BA8MDDTE36.json" links: - next: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/search.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query= + next: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/search.json?page%5Bafter%5D=eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0%3D&page%5Bsize%5D=1&query=" prev: null meta: after_cursor: eyJmcm9tIjoxLCJzaXplIjoxLCJzZWFyY2hBZnRlciI6bnVsbCwic29ydCI6bnVsbH0= @@ -25963,7 +28125,7 @@ components: CustomObjectRecordsUpsertResponseExample: value: custom_object_record: - created_at: "2023-09-26T22:25:10Z" + created_at: 2023-09-26T22:25:10Z created_by_user_id: "10001" custom_object_fields: make: Oldsmobile @@ -25974,7 +28136,7 @@ components: name: 1997 Cutlass Supreme updated_at: 2023-09-26T22:25:10Z updated_by_user_id: "10001" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYEY1FQYN066VHF49YHJ21.json + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/car/records/01GDXYEY1FQYN066VHF49YHJ21.json" CustomObjectsCreateRequestExample: value: custom_object: @@ -25984,18 +28146,18 @@ components: CustomObjectsCreateResponseExample: value: custom_object: - created_at: "2022-09-02T22:44:35Z" + created_at: 2022-09-02T22:44:35Z created_by_user_id: "16485" description: The list of cars in our fleet key: car - raw_description: '{{dc.car_description}}' - raw_title: '{{dc.car_title}}' - raw_title_pluralized: '{{dc.car_title_plural}}' + raw_description: "{{dc.car_description}}" + raw_title: "{{dc.car_title}}" + raw_title_pluralized: "{{dc.car_title_plural}}" title: Car title_pluralized: Cars updated_at: 2022-09-02T22:44:35Z updated_by_user_id: "10234" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC0617DV48CAXK6WA4DW51HD.json + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC0617DV48CAXK6WA4DW51HD.json" CustomObjectsLimitResponseExample: value: count: 19 @@ -26003,30 +28165,30 @@ components: CustomObjectsResponseExample: value: custom_objects: - - created_at: "2022-09-02T22:44:35Z" - created_by_user_id: "16485" - description: The list of cars in our fleet - key: car - raw_description: '{{dc.car_description}}' - raw_title: '{{dc.car_title}}' - raw_title_pluralized: '{{dc.car_title_plural}}' - title: Car - title_pluralized: Cars - updated_at: 2022-09-02T22:44:35Z - updated_by_user_id: "10234" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC0617DV48CAXK6WA4DW51HD.json - - created_at: 2022-08-01T22:44:35Z - created_by_user_id: "123123" - description: The list of vessels in our fleet - key: vessel - raw_description: '{{dc.vessel_description}}' - raw_title: '{{dc.vessel_title}}' - raw_title_pluralized: '{{dc.vessel_title_plural}}' - title: Vessel - title_pluralized: Vessel - updated_at: 2022-09-02T22:44:35Z - updated_by_user_id: "251251" - url: https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC9TXVMNT6VHB5GBGAR09WPF.json + - created_at: 2022-09-02T22:44:35Z + created_by_user_id: "16485" + description: The list of cars in our fleet + key: car + raw_description: "{{dc.car_description}}" + raw_title: "{{dc.car_title}}" + raw_title_pluralized: "{{dc.car_title_plural}}" + title: Car + title_pluralized: Cars + updated_at: 2022-09-02T22:44:35Z + updated_by_user_id: "10234" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC0617DV48CAXK6WA4DW51HD.json" + - created_at: 2022-08-01T22:44:35Z + created_by_user_id: "123123" + description: The list of vessels in our fleet + key: vessel + raw_description: "{{dc.vessel_description}}" + raw_title: "{{dc.vessel_title}}" + raw_title_pluralized: "{{dc.vessel_title_plural}}" + title: Vessel + title_pluralized: Vessel + updated_at: 2022-09-02T22:44:35Z + updated_by_user_id: "251251" + url: "https://{subdomain}.zendesk.com/api/v2/custom_objects/01GC9TXVMNT6VHB5GBGAR09WPF.json" CustomRoleResponseExample: value: custom_role: @@ -26067,104 +28229,109 @@ components: view_deleted_tickets: false voice_access: true voice_dashboard_access: false - created_at: "2012-03-12T16:32:22Z" - description: sample description - id: 10127 - name: sample role + created_at: 2012-03-12T16:32:22Z + description: sample description + id: 10127 + name: sample role + role_type: 0 + team_member_count: 10 + updated_at: 2012-03-12T16:32:22Z + CustomRolesResponseExample: + value: + custom_roles: + - configuration: + assign_tickets_to_any_group: false + chat_access: true + end_user_list_access: full + end_user_profile_access: readonly + explore_access: edit + forum_access: readonly + forum_access_restricted_content: false + group_access: true + light_agent: false + macro_access: full + manage_business_rules: true + manage_contextual_workspaces: false + manage_dynamic_content: false + manage_extensions_and_channels: true + manage_facebook: false + manage_organization_fields: false + manage_ticket_fields: false + manage_ticket_forms: false + manage_user_fields: false + moderate_forums: false + organization_editing: false + organization_notes_editing: false + report_access: none + side_conversation_create: true + ticket_access: within-groups + ticket_comment_access: none + ticket_deletion: false + ticket_editing: true + ticket_merge: false + ticket_tag_editing: true + twitter_search_access: true + user_view_access: readonly + view_access: full + view_deleted_tickets: false + voice_access: true + voice_dashboard_access: false + created_at: 2012-03-12T16:32:22Z + description: "Advisors manage the workflow and configure the help desk.\ + \ They create or manage automations, macros, triggers, views, and SLA\ + \ targets. They also set up channels and extensions. Advisors don't solve\ + \ tickets, they can only make private comments." + id: 16 + name: Advisor + role_type: 0 + team_member_count: 10 + updated_at: 2012-03-12T16:32:22Z + - configuration: + assign_tickets_to_any_group: false + chat_access: true + end_user_list_access: full + end_user_profile_access: readonly + explore_access: edit + forum_access: readonly + forum_access_restricted_content: false + group_access: true + light_agent: false + macro_access: full + manage_business_rules: true + manage_contextual_workspaces: false + manage_dynamic_content: false + manage_extensions_and_channels: true + manage_facebook: false + manage_organization_fields: false + manage_ticket_fields: false + manage_ticket_forms: false + manage_user_fields: false + moderate_forums: false + organization_editing: false + organization_notes_editing: false + report_access: none + side_conversation_create: true + ticket_access: within-groups + ticket_comment_access: none + ticket_deletion: false + ticket_editing: true + ticket_merge: false + ticket_tag_editing: true + twitter_search_access: true + user_view_access: readonly + view_access: full + view_deleted_tickets: false + voice_access: true + voice_dashboard_access: false + created_at: 2011-07-20T04:31:29Z + description: "A Staff agent's primary role is to solve tickets. They can\ + \ edit tickets within their groups, view reports, and add or edit personal\ + \ views and macros." + id: 6 + name: Staff role_type: 0 team_member_count: 10 - updated_at: "2012-03-12T16:32:22Z" - CustomRolesResponseExample: - value: - custom_roles: - - configuration: - assign_tickets_to_any_group: false - chat_access: true - end_user_list_access: full - end_user_profile_access: readonly - explore_access: edit - forum_access: readonly - forum_access_restricted_content: false - group_access: true - light_agent: false - macro_access: full - manage_business_rules: true - manage_contextual_workspaces: false - manage_dynamic_content: false - manage_extensions_and_channels: true - manage_facebook: false - manage_organization_fields: false - manage_ticket_fields: false - manage_ticket_forms: false - manage_user_fields: false - moderate_forums: false - organization_editing: false - organization_notes_editing: false - report_access: none - side_conversation_create: true - ticket_access: within-groups - ticket_comment_access: none - ticket_deletion: false - ticket_editing: true - ticket_merge: false - ticket_tag_editing: true - twitter_search_access: true - user_view_access: readonly - view_access: full - view_deleted_tickets: false - voice_access: true - voice_dashboard_access: false - created_at: "2012-03-12T16:32:22Z" - description: Advisors manage the workflow and configure the help desk. They create or manage automations, macros, triggers, views, and SLA targets. They also set up channels and extensions. Advisors don't solve tickets, they can only make private comments. - id: 16 - name: Advisor - role_type: 0 - team_member_count: 10 - updated_at: "2012-03-12T16:32:22Z" - - configuration: - assign_tickets_to_any_group: false - chat_access: true - end_user_list_access: full - end_user_profile_access: readonly - explore_access: edit - forum_access: readonly - forum_access_restricted_content: false - group_access: true - light_agent: false - macro_access: full - manage_business_rules: true - manage_contextual_workspaces: false - manage_dynamic_content: false - manage_extensions_and_channels: true - manage_facebook: false - manage_organization_fields: false - manage_ticket_fields: false - manage_ticket_forms: false - manage_user_fields: false - moderate_forums: false - organization_editing: false - organization_notes_editing: false - report_access: none - side_conversation_create: true - ticket_access: within-groups - ticket_comment_access: none - ticket_deletion: false - ticket_editing: true - ticket_merge: false - ticket_tag_editing: true - twitter_search_access: true - user_view_access: readonly - view_access: full - view_deleted_tickets: false - voice_access: true - voice_dashboard_access: false - created_at: "2011-07-20T04:31:29Z" - description: A Staff agent's primary role is to solve tickets. They can edit tickets within their groups, view reports, and add or edit personal views and macros. - id: 6 - name: Staff - role_type: 0 - team_member_count: 10 - updated_at: "2012-02-02T10:32:59Z" + updated_at: 2012-02-02T10:32:59Z CustomStatusCreateRequestExample: value: custom_status: @@ -26202,20 +28369,20 @@ components: CustomStatusesResponseExample: value: custom_statuses: - - active: true - agent_label: Responding quickly - created_at: 2021-07-20T22:55:29Z - default: false - description: Customer needs a response quickly - end_user_description: Your ticket is being responded to - end_user_label: Urgent processing - id: 35436 - raw_agent_label: Responding quickly - raw_description: Customer needs a response quickly - raw_end_user_description: Your ticket is being responded to - raw_end_user_label: Urgent processing - status_category: open - updated_at: 2021-07-20T22:55:29Z + - active: true + agent_label: Responding quickly + created_at: 2021-07-20T22:55:29Z + default: false + description: Customer needs a response quickly + end_user_description: Your ticket is being responded to + end_user_label: Urgent processing + id: 35436 + raw_agent_label: Responding quickly + raw_description: Customer needs a response quickly + raw_end_user_description: Your ticket is being responded to + raw_end_user_label: Urgent processing + status_category: open + updated_at: 2021-07-20T22:55:29Z CustomTicketFieldOptionCreateResponseExample: value: custom_field_option: @@ -26223,7 +28390,7 @@ components: name: Grapes position: 2 raw_name: Grapes - url: http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10002.json + url: "http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10002.json" value: grape CustomTicketFieldOptionResponseExample: value: @@ -26232,7 +28399,7 @@ components: name: Bananas position: 1 raw_name: Bananas - url: http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10001.json + url: "http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10001.json" value: banana CustomTicketFieldOptionUpdateResponseExample: value: @@ -26241,24 +28408,24 @@ components: name: Pineapples position: 2 raw_name: Pineapples - url: http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10002.json + url: "http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10002.json" value: pineapple CustomTicketFieldOptionsResponseExample: value: count: 2 custom_field_options: - - id: 10000 - name: Apples - position: 0 - raw_name: Apples - url: http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10000.json - value: apple - - id: 10001 - name: Bananas - position: 1 - raw_name: Bananas - url: http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10001.json - value: banana + - id: 10000 + name: Apples + position: 0 + raw_name: Apples + url: "http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10000.json" + value: apple + - id: 10001 + name: Bananas + position: 1 + raw_name: Bananas + url: "http://{subdomain}.zendesk.com/api/v2/ticket_fields/1/options/10001.json" + value: banana next_page: null previous_page: null CustomUserFieldOptionCreateResponseExample: @@ -26268,7 +28435,7 @@ components: name: Grapes position: 2 raw_name: Grapes - url: http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10002.json + url: "http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10002.json" value: grape CustomUserFieldOptionResponseExample: value: @@ -26277,7 +28444,7 @@ components: name: Bananas position: 1 raw_name: Bananas - url: http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10001.json + url: "http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10001.json" value: banana CustomUserFieldOptionUpdateResponseExample: value: @@ -26286,59 +28453,59 @@ components: name: Pineapples position: 2 raw_name: Pineapples - url: http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10002.json + url: "http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10002.json" value: pineapple CustomUserFieldOptionsResponseExample: value: count: 2 custom_field_options: - - id: 10000 - name: Apples - position: 0 - raw_name: Apples - url: http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10000.json - value: apple - - id: 10001 - name: Bananas - position: 1 - raw_name: Bananas - url: http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10001.json - value: banana + - id: 10000 + name: Apples + position: 0 + raw_name: Apples + url: "http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10000.json" + value: apple + - id: 10001 + name: Bananas + position: 1 + raw_name: Bananas + url: "http://{subdomain}.zendesk.com/api/v2/user_fields/1/options/10001.json" + value: banana next_page: null previous_page: null DefinitionsResponseExample: value: definitions: conditions_all: - - group: ticket - nullable: false - operators: - - terminal: false - title: Is - value: is - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: false - title: Closed - value: closed + - group: ticket + nullable: false + operators: + - terminal: false + title: Is + value: is + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: false + title: Closed + value: closed conditions_any: - - group: ticket - nullable: false - operators: - - terminal: false - title: Is - value: is - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: false - title: Closed - value: closed + - group: ticket + nullable: false + operators: + - terminal: false + title: Is + value: is + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: false + title: Closed + value: closed DeleteUserResponseExample: value: user: @@ -26349,7 +28516,7 @@ components: value: deleted_user: active: false - created_at: "2019-08-26T02:10:24Z" + created_at: 2019-08-26T02:10:24Z email: david@email.com id: 189304711533 locale: en-US @@ -26361,254 +28528,254 @@ components: role: end-user shared_phone_number: null time_zone: Eastern Time (US & Canada) - updated_at: "2019-08-26T02:10:27Z" - url: https://{subdomain}.zendesk.com/api/v2/deleted_users/189304711533 + updated_at: 2019-08-26T02:10:27Z + url: "https://{subdomain}.zendesk.com/api/v2/deleted_users/189304711533" DeletedUsersCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 13 DeletedUsersResponseExample: value: deleted_users: - - active: false - created_at: "2019-08-26T02:10:24Z" - email: david@gmail.com - id: 189304711533 - locale: en-US - locale_id: 1 - name: David - organization_id: 12312312 - phone: null - photo: null - role: end-user - shared_phone_number: null - time_zone: Eastern Time (US & Canada) - updated_at: "2019-08-26T02:10:27Z" - url: https://{subdomain}.zendesk.com/api/v2/deleted_users/189304711533 - - active: false - created_at: "2019-08-26T02:10:28Z" - email: linda@gmail.com - id: 12204720593 - locale: en-US - locale_id: 1 - name: Linda - organization_id: 123123123 - phone: null - photo: null - role: end-user - shared_phone_number: null - time_zone: Eastern Time (US & Canada) - updated_at: "2019-08-26T02:10:29Z" - url: https://{subdomain}.zendesk.com/api/v2/deleted_users/12204720593 + - active: false + created_at: 2019-08-26T02:10:24Z + email: david@gmail.com + id: 189304711533 + locale: en-US + locale_id: 1 + name: David + organization_id: 12312312 + phone: null + photo: null + role: end-user + shared_phone_number: null + time_zone: Eastern Time (US & Canada) + updated_at: 2019-08-26T02:10:27Z + url: "https://{subdomain}.zendesk.com/api/v2/deleted_users/189304711533" + - active: false + created_at: 2019-08-26T02:10:28Z + email: linda@gmail.com + id: 12204720593 + locale: en-US + locale_id: 1 + name: Linda + organization_id: 123123123 + phone: null + photo: null + role: end-user + shared_phone_number: null + time_zone: Eastern Time (US & Canada) + updated_at: 2019-08-26T02:10:29Z + url: "https://{subdomain}.zendesk.com/api/v2/deleted_users/12204720593" DynamicContentResponseExample: value: item: - created_at: "2015-05-13T22:33:12Z" + created_at: 2015-05-13T22:33:12Z default_locale_id: 1 id: 47 name: Snowboard Problem outdated: false - placeholder: '{{dc.snowboard_problem}}' - updated_at: "2015-05-13T22:33:12Z" + placeholder: "{{dc.snowboard_problem}}" + updated_at: 2015-05-13T22:33:12Z url: https://company.zendesk.com/api/v2/dynamic_content/items/47.json variants: - - active: true - content: Voici mon contenu dynamique en français - created_at: "2015-05-13T22:33:12Z" - default: true - id: 47 - locale_id: 16 - outdated: false - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json - - active: true - content: Este es mi contenido dinámico en español - created_at: "2015-05-13T22:33:12Z" - default: false - id: 48 - locale_id: 2 - outdated: false - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/48.json + - active: true + content: Voici mon contenu dynamique en français + created_at: 2015-05-13T22:33:12Z + default: true + id: 47 + locale_id: 16 + outdated: false + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json + - active: true + content: Este es mi contenido dinámico en español + created_at: 2015-05-13T22:33:12Z + default: false + id: 48 + locale_id: 2 + outdated: false + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/48.json DynamicContentUpdateResponseExample: value: item: - created_at: "2015-05-13T22:33:12Z" + created_at: 2015-05-13T22:33:12Z default_locale_id: 1 id: 47 name: New name outdated: false - placeholder: '{{dc.snowboard_problem}}' - updated_at: "2015-05-13T22:33:12Z" + placeholder: "{{dc.snowboard_problem}}" + updated_at: 2015-05-13T22:33:12Z url: https://company.zendesk.com/api/v2/dynamic_content/items/47.json variants: - - active: true - content: Voici mon contenu dynamique en français - created_at: "2015-05-13T22:33:12Z" - default: true - id: 47 - locale_id: 16 - outdated: false - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json - - active: true - content: Este es mi contenido dinámico en español - created_at: "2015-05-13T22:33:12Z" - default: false - id: 48 - locale_id: 2 - outdated: false - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/48.json + - active: true + content: Voici mon contenu dynamique en français + created_at: 2015-05-13T22:33:12Z + default: true + id: 47 + locale_id: 16 + outdated: false + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json + - active: true + content: Este es mi contenido dinámico en español + created_at: 2015-05-13T22:33:12Z + default: false + id: 48 + locale_id: 2 + outdated: false + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/48.json DynamicContentVariantResponseExample: value: variant: active: true content: C'est mon contenu dynamique en français - created_at: "2014-04-09T19:53:23Z" + created_at: 2014-04-09T19:53:23Z default: false id: 23 locale_id: 127 outdated: false - updated_at: "2014-04-09T19:53:23Z" + updated_at: 2014-04-09T19:53:23Z url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json DynamicContentVariantUpdateResponseExample: value: variant: active: false content: C'est mon contenu dynamique en français - created_at: "2014-04-09T19:53:23Z" + created_at: 2014-04-09T19:53:23Z default: false id: 23 locale_id: 125 outdated: false - updated_at: "2014-04-09T19:53:23Z" + updated_at: 2014-04-09T19:53:23Z url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json DynamicContentVariantsCreateManyResponseExample: value: variants: - - active: true - content: C'est mon contenu dynamique en français - created_at: "2014-04-09T19:53:23Z" - default: false - id: 23 - locale_id: 127 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json - - active: true - content: Este es mi contenido dinámico en español - created_at: "2014-04-09T19:53:23Z" - default: false - id: 24 - locale_id: 126 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json + - active: true + content: C'est mon contenu dynamique en français + created_at: 2014-04-09T19:53:23Z + default: false + id: 23 + locale_id: 127 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json + - active: true + content: Este es mi contenido dinámico en español + created_at: 2014-04-09T19:53:23Z + default: false + id: 24 + locale_id: 126 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json DynamicContentVariantsResponseExample: value: variants: - - active: true - content: This is my dynamic content in English - created_at: "2014-04-09T19:53:23Z" - default: true - id: 23 - locale_id: 125 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json - - active: false - content: Este es mi contenido dinámico en español - created_at: "2014-04-09T19:53:23Z" - default: false - id: 24 - locale_id: 126 - outdated: true - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json + - active: true + content: This is my dynamic content in English + created_at: 2014-04-09T19:53:23Z + default: true + id: 23 + locale_id: 125 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json + - active: false + content: Este es mi contenido dinámico en español + created_at: 2014-04-09T19:53:23Z + default: false + id: 24 + locale_id: 126 + outdated: true + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json DynamicContentVariantsUpdateManyResponseExample: value: variants: - - active: true - content: C'est mon contenu dynamique en français - created_at: "2014-04-09T19:53:23Z" - default: false - id: 23 - locale_id: 16 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json - - active: true - content: Este es mi contenido dinámico en español - created_at: "2014-04-09T19:53:23Z" - default: false - id: 24 - locale_id: 2 - outdated: false - updated_at: "2014-04-09T19:53:23Z" - url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json + - active: true + content: C'est mon contenu dynamique en français + created_at: 2014-04-09T19:53:23Z + default: false + id: 23 + locale_id: 16 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/23.json + - active: true + content: Este es mi contenido dinámico en español + created_at: 2014-04-09T19:53:23Z + default: false + id: 24 + locale_id: 2 + outdated: false + updated_at: 2014-04-09T19:53:23Z + url: https://subdomain.zendesk.com/api/v2/dynamic_content/items/3/variants/24.json DynamicContentsResponseExample: value: items: - - created_at: "2015-05-13T22:33:12Z" - default_locale_id: 1 + - created_at: 2015-05-13T22:33:12Z + default_locale_id: 1 + id: 47 + name: Snowboard Problem + outdated: true + placeholder: "{{dc.snowboard_problem}}" + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47.json + variants: + - active: true + content: C'est mon contenu dynamique en français + created_at: 2015-05-13T22:33:12Z + default: true id: 47 - name: Snowboard Problem - outdated: true - placeholder: '{{dc.snowboard_problem}}' - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47.json - variants: - - active: true - content: C'est mon contenu dynamique en français - created_at: "2015-05-13T22:33:12Z" - default: true - id: 47 - locale_id: 1 - outdated: false - updated_at: "2015-05-13T22:33:12Z" - url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json + locale_id: 1 + outdated: false + updated_at: 2015-05-13T22:33:12Z + url: https://company.zendesk.com/api/v2/dynamic_content/items/47/variants/47.json EssentialsCardExample: value: object_layout: - created_at: "2022-04-02T22:55:29Z" + created_at: 2022-04-02T22:55:29Z default: true fields: - - id: null - zrn: zen:user:identity:email - - id: null - zrn: zen:user:field:standard:external_id - - id: null - zrn: zen:user:field:standard:iana_time_zone - - id: null - zrn: zen:user:field:standard:locale - - id: null - zrn: zen:user:field:standard:organization_id + - id: null + zrn: zen:user:identity:email + - id: null + zrn: zen:user:field:standard:external_id + - id: null + zrn: zen:user:field:standard:iana_time_zone + - id: null + zrn: zen:user:field:standard:locale + - id: null + zrn: zen:user:field:standard:organization_id id: null key: zen:user layout: essentials_card max_count: 20 - updated_at: "2022-04-02T22:55:29Z" + updated_at: 2022-04-02T22:55:29Z EssentialsCardsExample: value: object_layouts: - - created_at: "2022-04-02T22:55:29Z" - default: true - fields: [] - id: null - key: zen:user - layout: essentials_card - max_count: 20 - updated_at: "2022-04-02T22:55:29Z" - - created_at: "2022-05-02T22:55:29Z" - default: true - fields: [] - id: null - key: zen:custome_object:car - layout: essentials_card - max_count: 20 - updated_at: "2022-05-02T22:55:29Z" + - created_at: 2022-04-02T22:55:29Z + default: true + fields: [] + id: null + key: zen:user + layout: essentials_card + max_count: 20 + updated_at: 2022-04-02T22:55:29Z + - created_at: 2022-05-02T22:55:29Z + default: true + fields: [] + id: null + key: zen:custome_object:car + layout: essentials_card + max_count: 20 + updated_at: 2022-05-02T22:55:29Z ExportIncrementalOrganizationsResponseExample: value: count: 1 @@ -26616,26 +28783,26 @@ components: end_time: 1601357503 next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 organizations: - - created_at: "2018-11-14T00:14:52Z" - details: caterpillar =) - domain_names: - - remain.com - external_id: ABC198 - group_id: 1835962 - id: 4112492 - name: Groablet Enterprises - notes: donkey - organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" - org_field_1: happy happy - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" - url: https://example.zendesk.com/api/v2/organizations/4112492.json + - created_at: 2018-11-14T00:14:52Z + details: caterpillar =) + domain_names: + - remain.com + external_id: ABC198 + group_id: 1835962 + id: 4112492 + name: Groablet Enterprises + notes: donkey + organization_fields: + datepudding: 2018-11-04T00:00:00+00:00 + org_field_1: happy happy + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z + url: https://example.zendesk.com/api/v2/organizations/4112492.json ExportIncrementalTicketEventsResponseExample: value: count: 1 @@ -26643,183 +28810,187 @@ components: end_time: 1601357503 next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 ticket_events: - - id: 926256957613 - instance_id: 1 - metric: agent_work_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: measure + - id: 926256957613 + instance_id: 1 + metric: agent_work_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: measure GroupCreateResponseExample: value: group: - created_at: "2009-08-26T00:07:08Z" + created_at: 2009-08-26T00:07:08Z id: 122 is_public: true name: My Group - updated_at: "2010-05-13T00:07:08Z" + updated_at: 2010-05-13T00:07:08Z GroupMembershipResponseExample: value: group_membership: - created_at: "2012-04-03T12:34:01Z" + created_at: 2012-04-03T12:34:01Z default: true group_id: 88 id: 461 - updated_at: "2012-04-03T12:34:01Z" + updated_at: 2012-04-03T12:34:01Z user_id: 72 GroupMembershipsResponseExample: value: group_memberships: - - created_at: "2009-05-13T00:07:08Z" - default: true - group_id: 12 - id: 4 - updated_at: "2011-07-22T00:11:12Z" - user_id: 29 - - created_at: "2012-03-13T22:01:32Z" - default: false - group_id: 3 - id: 49 - updated_at: "2012-03-13T22:01:32Z" - user_id: 155 + - created_at: 2009-05-13T00:07:08Z + default: true + group_id: 12 + id: 4 + updated_at: 2011-07-22T00:11:12Z + user_id: 29 + - created_at: 2012-03-13T22:01:32Z + default: false + group_id: 3 + id: 49 + updated_at: 2012-03-13T22:01:32Z + user_id: 155 GroupResponseExample: value: group: - created_at: "2009-08-26T00:07:08Z" + created_at: 2009-08-26T00:07:08Z id: 122 is_public: true name: MCs - updated_at: "2010-05-13T00:07:08Z" + updated_at: 2010-05-13T00:07:08Z GroupSLAPoliciesResponseExample: value: count: 1 group_sla_policies: - - description: For low priority tickets, the Tier 1 group will solve or reassign the ticket in one hour. - filter: - all: - - field: group_ownership_time - operator: includes - value: - - 6 - id: 01H078CBDY28BZG7P6BONY09DN - policy_metrics: - - business_hours: false - metric: group_ownership_time - priority: low - target: 3600 - position: 3 - title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/group_sla/policies/01H078CBDY28BZG7P6BONY09DN.json + - description: "For low priority tickets, the Tier 1 group will solve or reassign\ + \ the ticket in one hour." + filter: + all: + - field: group_ownership_time + operator: includes + value: + - 6 + id: 01H078CBDY28BZG7P6BONY09DN + policy_metrics: + - business_hours: false + metric: group_ownership_time + priority: low + target: 3600 + position: 3 + title: Incidents + url: "https://{subdomain}.zendesk.com/api/v2/group_sla/policies/01H078CBDY28BZG7P6BONY09DN.json" next_page: null previous_page: null GroupSLAPolicyCreateResponse: value: group_sla_policy: - description: The group with id 6 will have to solve or reassign normal priority tickets in 30 minutes and urgent tickets in 10. + description: The group with id 6 will have to solve or reassign normal priority + tickets in 30 minutes and urgent tickets in 10. filter: all: - - field: group_ownership_time - operator: includes - value: - - 6 + - field: group_ownership_time + operator: includes + value: + - 6 id: 01H078CBDY28BZG7P6BONY09DN policy_metrics: - - business_hours: false - metric: group_ownership_time - priority: normal - target: 1800 - - business_hours: false - metric: group_ownership_time - priority: urgent - target: 600 + - business_hours: false + metric: group_ownership_time + priority: normal + target: 1800 + - business_hours: false + metric: group_ownership_time + priority: urgent + target: 600 position: 3 title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json + url: "https://{subdomain}.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json" GroupSLAPolicyFilterDefinitionResponseExample: value: definitions: all: - - group: ticket - operators: - - title: Contains at least one of the following - value: includes - - title: Contains at least none of the following - value: not_includes - title: Group ID - value: group_id - values: - list: - - title: Tier 1 - value: 6 - type: list + - group: ticket + operators: + - title: Contains at least one of the following + value: includes + - title: Contains at least none of the following + value: not_includes + title: Group ID + value: group_id + values: + list: + - title: Tier 1 + value: 6 + type: list GroupSLAPolicyResponseExample: value: group_sla_policy: - description: Low priority tickets assigned to the group with id 6 will be completed or reassigned in one hour. + description: Low priority tickets assigned to the group with id 6 will be + completed or reassigned in one hour. filter: all: - - field: group_id - operator: includes - value: - - 6 + - field: group_id + operator: includes + value: + - 6 id: 01H078CBDY28BZG7P6BONY09DN policy_metrics: - - business_hours: false - metric: group_ownership_time - priority: low - target: 3600 + - business_hours: false + metric: group_ownership_time + priority: low + target: 3600 position: 3 title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/group_sla/policies/01H078CBDY28BZG7P6BONY09DN.json + url: "https://{subdomain}.zendesk.com/api/v2/group_sla/policies/01H078CBDY28BZG7P6BONY09DN.json" GroupSLAPolicyUpdateResponse: value: group_sla_policy: - description: Normal priority tickets assigned to the groups 6 or 7 will be completed or reassigned in 30 minutes. + description: Normal priority tickets assigned to the groups 6 or 7 will + be completed or reassigned in 30 minutes. filter: all: - - field: group_id - operator: includes - value: - - 6 - - 7 + - field: group_id + operator: includes + value: + - 6 + - 7 id: 01H078CBDY28BZG7P6BONY09DN policy_metrics: - - business_hours: false - metric: group_ownership_time - priority: normal - target: 1800 + - business_hours: false + metric: group_ownership_time + priority: normal + target: 1800 position: 3 title: Urgent Incidents - url: https://{subdomain}.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json + url: "https://{subdomain}.zendesk.com/api/v2/group_slas/policies/01H078CBDY28BZG7P6BONY09DN.json" GroupUpdateResponseExample: value: group: - created_at: "2009-08-26T00:07:08Z" + created_at: 2009-08-26T00:07:08Z id: 123 is_public: false name: Interesting Group - updated_at: "2010-05-13T00:07:08Z" + updated_at: 2010-05-13T00:07:08Z GroupsCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 GroupsResponseExample: value: groups: - - created_at: "2009-05-13T00:07:08Z" - id: 211 - is_public: true - name: DJs - updated_at: "2011-07-22T00:11:12Z" - - created_at: "2009-08-26T00:07:08Z" - id: 122 - is_public: true - name: MCs - updated_at: "2010-05-13T00:07:08Z" + - created_at: 2009-05-13T00:07:08Z + id: 211 + is_public: true + name: DJs + updated_at: 2011-07-22T00:11:12Z + - created_at: 2009-08-26T00:07:08Z + id: 122 + is_public: true + name: MCs + updated_at: 2010-05-13T00:07:08Z HostMappingResponseInvalidCNAMEExample: value: expected_cnames: - - bar.zendesk.com + - bar.zendesk.com is_valid: false reason: not_a_cname HostMappingResponseValidExample: @@ -26830,51 +29001,51 @@ components: value: cname: bar.zendesk.com expected_cnames: - - bar.zendesk.com + - bar.zendesk.com is_valid: false reason: google.com IncrementalSkillBasedRoutingAttributeValuesExample: value: attribute_values: - - attribute_id: 15821cba-7326-11e8-b07e-950ba849aa27 - id: 19ed17fb-7326-11e8-b07e-9de44e7e7f20 - name: English - time: "2018-06-19T01:33:26Z" - type: create + - attribute_id: 15821cba-7326-11e8-b07e-950ba849aa27 + id: 19ed17fb-7326-11e8-b07e-9de44e7e7f20 + name: English + time: 2018-06-19T01:33:26Z + type: create count: 1200 end_time: 1533266020 - next_page: https://{subdomain}.zendesk.com/api/v2/incremental/routing/attribute_values.json?cursor=7d724c71-3911-11e8-9621-836b8c683dc6 + next_page: "https://{subdomain}.zendesk.com/api/v2/incremental/routing/attribute_values.json?cursor=7d724c71-3911-11e8-9621-836b8c683dc6" IncrementalSkillBasedRoutingAttributesExample: value: attributes: - - id: 15821cba-7326-11e8-b07e-950ba849aa27 - name: Languages - time: "2018-06-19T01:33:19Z" - type: create + - id: 15821cba-7326-11e8-b07e-950ba849aa27 + name: Languages + time: 2018-06-19T01:33:19Z + type: create count: 1200 end_time: 1533266020 - next_page: https://{subdomain}.zendesk.com/api/v2/incremental/routing/attributes.json?cursor=7d724c71-3911-11e8-9621-836b8c683dc6 + next_page: "https://{subdomain}.zendesk.com/api/v2/incremental/routing/attributes.json?cursor=7d724c71-3911-11e8-9621-836b8c683dc6" IncrementalSkillBasedRoutingInstanceValuesExample: value: count: 1200 end_time: 1533266020 instance_values: - - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 - id: 62055cad-7326-11e8-b07e-73653560136b - instance_id: "10001" - time: "2019-06-19T01:35:27Z" - type: associate_agent - - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 - id: 62055cad-7326-11e8-b07e-cf1082b7e6d4 - instance_id: "11375" - time: "2019-06-19T01:35:27Z" - type: associate_agent - - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 - id: 62055cad-7326-11e8-b07e-5b8483a47e24 - instance_id: "14187" - time: "2020-11-14T16:32:22Z" - type: unassociate_agent - next_page: https://{subdomain}.zendesk.com/api/v2/incremental/routing/instance_values.json?cursor=62055cad-7326-11e8-b07e-73653560136b + - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 + id: 62055cad-7326-11e8-b07e-73653560136b + instance_id: "10001" + time: 2019-06-19T01:35:27Z + type: associate_agent + - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 + id: 62055cad-7326-11e8-b07e-cf1082b7e6d4 + instance_id: "11375" + time: 2019-06-19T01:35:27Z + type: associate_agent + - attribute_value_id: 19ed17fb-7326-11e8-b07e-9ab44e7e7f28 + id: 62055cad-7326-11e8-b07e-5b8483a47e24 + instance_id: "14187" + time: 2020-11-14T16:32:22Z + type: unassociate_agent + next_page: "https://{subdomain}.zendesk.com/api/v2/incremental/routing/instance_values.json?cursor=62055cad-7326-11e8-b07e-73653560136b" JobStatusBulkDeleteResponseExample: value: job_status: @@ -26882,14 +29053,14 @@ components: message: Completed at 2018-03-08 10:07:04 +0000 progress: 2 results: - - action: delete - id: 244 - status: Deleted - success: true - - action: delete - id: 245 - status: Deleted - success: true + - action: delete + id: 244 + status: Deleted + success: true + - action: delete + id: 245 + status: Deleted + success: true status: completed total: 2 url: https://example.zendesk.com/api/v2/job_statuses/82de0b0467893ac9fe64f1a99.json @@ -26900,206 +29071,206 @@ components: message: Completed at 2018-03-08 10:07:04 +0000 progress: 2 results: - - action: update - id: 244 - status: Updated - success: true - - action: update - id: 245 - status: Updated - success: true + - action: update + id: 244 + status: Updated + success: true + - action: update + id: 245 + status: Updated + success: true status: completed total: 2 url: https://example.zendesk.com/api/v2/job_statuses/82de0b0467893ac9fe64f1a99.json JobStatusesResponseExample: value: job_statuses: - - id: 8b726e606741012ffc2d782bcb7848fe - status: completed - - id: e7665094164c498781ebe4c8db6d2af5 - status: completed + - id: 8b726e606741012ffc2d782bcb7848fe + status: completed + - id: e7665094164c498781ebe4c8db6d2af5 + status: completed ListDeletedTicketsResponseExample: value: count: 1 deleted_tickets: - - actor: - id: 3946 - name: Taz Wombat - deleted_at: 20140704T15:37:04Z - id: 581 - previous_state: open - subject: Wombat Party + - actor: + id: 3946 + name: Taz Wombat + deleted_at: 20140704T15:37:04Z + id: 581 + previous_state: open + subject: Wombat Party next_page: null previous_page: null ListTicketCollaboratorsResponseExample: value: users: - - id: 223443 - name: Johnny Agent - - id: 8678530 - name: Peter Admin + - id: 223443 + name: Johnny Agent + - id: 8678530 + name: Peter Admin ListTicketEmailCCsResponseExample: value: users: - - id: "223443" - name: Johnny Agent - - id: "8678530" - name: Peter Admin - - id: "6748530" - name: Jane End User + - id: "223443" + name: Johnny Agent + - id: "8678530" + name: Peter Admin + - id: "6748530" + name: Jane End User ListTicketFollowersResponseExample: value: users: - - id: 223443 - name: Johnny Agent - - id: 8678530 - name: Peter Admin + - id: 223443 + name: Johnny Agent + - id: 8678530 + name: Peter Admin ListTicketIncidentsResponseExample: value: tickets: - - description: The fire is very colorful. - id: 33 - status: open - subject: My printer is on fire - - description: The fire is very colorful as well! - id: 34 - status: pending - subject: The printer is on fire over here too + - description: The fire is very colorful. + id: 33 + status: open + subject: My printer is on fire + - description: The fire is very colorful as well! + id: 34 + status: pending + subject: The printer is on fire over here too ListTicketProblemsResponseExample: value: tickets: - - custom_status_id: 123 - description: The fire is very colorful. - id: 33 - status: open - subject: My printer is on fire - - custom_status_id: 231 - description: The fire is very colorful as well! - id: 34 - status: pending - subject: The printer is on fire over here too + - custom_status_id: 123 + description: The fire is very colorful. + id: 33 + status: open + subject: My printer is on fire + - custom_status_id: 231 + description: The fire is very colorful as well! + id: 34 + status: pending + subject: The printer is on fire over here too LocaleDetectBestLanguageResponseExample: value: locale: - created_at: "2010-12-23T12:45:22Z" + created_at: 2010-12-23T12:45:22Z id: 1 locale: en name: English - updated_at: "2012-04-01T10:44:12Z" + updated_at: 2012-04-01T10:44:12Z url: https://company.zendesk.com/api/v2/locales/en-US.json LocaleResponseExample: value: locale: - created_at: "2010-12-23T12:45:22Z" + created_at: 2010-12-23T12:45:22Z id: 8 locale: de name: Deutsch - updated_at: "2012-04-01T10:44:12Z" + updated_at: 2012-04-01T10:44:12Z url: https://company.zendesk.com/api/v2/locales/de.json LocalesResponseExample: value: locales: - - created_at: "2009-07-20T22:55:29Z" - id: 1 - locale: en-US - name: English - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/locales/en-US.json - - created_at: "2010-12-23T12:45:22Z" - id: 8 - locale: de - name: Deutsch - updated_at: "2012-04-01T10:44:12Z" - url: https://company.zendesk.com/api/v2/locales/de.json + - created_at: 2009-07-20T22:55:29Z + id: 1 + locale: en-US + name: English + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/locales/en-US.json + - created_at: 2010-12-23T12:45:22Z + id: 8 + locale: de + name: Deutsch + updated_at: 2012-04-01T10:44:12Z + url: https://company.zendesk.com/api/v2/locales/de.json MacroActionsResponseExample: value: actions: - - group: ticket - operators: - - title: Is - value: is - output_key: null - target: null - title: Set subject - title_for_field: Set subject - value: subject - values: - list: [] - type: text - - group: ticket - operators: - - title: Is - value: is - output_key: null - target: null - title: Status - title_for_field: Set subject - value: subject - values: - list: - - enabled: true - title: Open - value: open - - enabled: true - title: Pending - value: pending - - enabled: true - title: Solved - value: solved - type: list - - field: priority - group: ticket - operators: - - title: Is - value: is - output_key: null - title: Priority - title_for_field: Priority - value: priority - values: - list: - - enabled: false - title: Low - value: low - - enabled: true - title: Normal - value: normal - - enabled: true - title: High - value: high - - enabled: false - title: Urgent - value: urgent - type: list + - group: ticket + operators: + - title: Is + value: is + output_key: null + target: null + title: Set subject + title_for_field: Set subject + value: subject + values: + list: [] + type: text + - group: ticket + operators: + - title: Is + value: is + output_key: null + target: null + title: Status + title_for_field: Set subject + value: subject + values: + list: + - enabled: true + title: Open + value: open + - enabled: true + title: Pending + value: pending + - enabled: true + title: Solved + value: solved + type: list + - field: priority + group: ticket + operators: + - title: Is + value: is + output_key: null + title: Priority + title_for_field: Priority + value: priority + values: + list: + - enabled: false + title: Low + value: low + - enabled: true + title: Normal + value: normal + - enabled: true + title: High + value: high + - enabled: false + title: Urgent + value: urgent + type: list MacroAttachmentResponseExample: value: macro_attachment: content_type: image/jpeg content_url: https://company.zendesk.com/api/v2/macros/attachments/100/content - created_at: "2016-08-15T16:04:06Z" + created_at: 2016-08-15T16:04:06Z filename: foobar.jpg id: 100 size: 2532 MacroAttachmentsResponseExample: value: macro_attachments: - - content_type: image/jpeg - content_url: https://company.zendesk.com/api/v2/macros/attachments/100/content - created_at: "2016-08-15T16:04:06Z" - filename: foobar.jpg - id: 100 - size: 2532 - - content_type: image/jpeg - content_url: https://company.zendesk.com/api/v2/macros/attachments/342/content - created_at: "2016-08-16T12:42:25Z" - filename: bazbat.jpg - id: 342 - size: 5028 + - content_type: image/jpeg + content_url: https://company.zendesk.com/api/v2/macros/attachments/100/content + created_at: 2016-08-15T16:04:06Z + filename: foobar.jpg + id: 100 + size: 2532 + - content_type: image/jpeg + content_url: https://company.zendesk.com/api/v2/macros/attachments/342/content + created_at: 2016-08-16T12:42:25Z + filename: bazbat.jpg + id: 342 + size: 5028 MacroCategoriesResponseExample: value: categories: - - FAQ - - Triage + - FAQ + - Triage MacroChangesToTicketsResponseExample: value: result: @@ -27109,8 +29280,8 @@ components: body: Assigned to Agent Uno. public: false scoped_body: - - - channel:all - - Assigned to Agent Uno. + - - channel:all + - Assigned to Agent Uno. fields: id: 27642 value: "745" @@ -27129,19 +29300,19 @@ components: value: count: 2 macros: - - actions: [] - active: true - description: Sets the ticket status to `solved` - id: 25 - position: 42 - restriction: {} - title: Close and Save - - actions: [] - active: false - description: Adds a `priority` tag to the ticket - id: 26 - restriction: {} - title: Assign priority tag + - actions: [] + active: true + description: Sets the ticket status to `solved` + id: 25 + position: 42 + restriction: {} + title: Close and Save + - actions: [] + active: false + description: Adds a `priority` tag to the ticket + id: 26 + restriction: {} + title: Assign priority tag next_page: null previous_page: null MergeEndUsersRequestExample: @@ -27162,68 +29333,70 @@ components: value: organization_field: active: true - created_at: "2013-02-27T20:35:55Z" + created_at: 2013-02-27T20:35:55Z description: This field describes the support plan this organization has id: 75 key: support_description position: 0 - raw_description: This field describes the support plan this organization has + raw_description: This field describes the support plan this organization + has raw_title: Support description regexp_for_validation: null title: Support description type: text - updated_at: "2013-02-27T20:35:55Z" + updated_at: 2013-02-27T20:35:55Z url: https://company.zendesk.com/api/v2/organization_fields/75.json OrganizationFieldResponseExample: value: organization_field: active: true - created_at: "2012-10-16T16:04:06Z" + created_at: 2012-10-16T16:04:06Z description: Description of Custom Field id: 7 key: custom_field_1 position: 9999 - raw_description: '{{dc.my_description}}' + raw_description: "{{dc.my_description}}" raw_title: Custom Field 1 regexp_for_validation: null title: Custom Field 1 type: text - updated_at: "2012-10-16T16:04:06Z" + updated_at: 2012-10-16T16:04:06Z url: https://company.zendesk.com/api/v2/organization_fields/7.json OrganizationFieldUpdateResponseExample: value: organization_field: active: true - created_at: "2013-02-27T20:35:55Z" + created_at: 2013-02-27T20:35:55Z description: This field describes the support plan this organization has id: 75 key: support_description position: 0 - raw_description: This field describes the support plan this organization has + raw_description: This field describes the support plan this organization + has raw_title: Support description regexp_for_validation: null title: Support description type: text - updated_at: "2013-02-27T20:35:55Z" + updated_at: 2013-02-27T20:35:55Z url: https://company.zendesk.com/api/v2/organization_fields/75.json OrganizationFieldsResponseExample: value: count: 1 next_page: null organization_fields: - - active: true - created_at: "2012-10-16T16:04:06Z" - description: Description of Custom Field - id: 7 - key: custom_field_1 - position: 9999 - raw_description: '{{dc.my_description}}' - raw_title: Custom Field 1 - regexp_for_validation: null - title: Custom Field 1 - type: text - updated_at: "2012-10-16T16:04:06Z" - url: https://company.zendesk.com/api/v2/organization_fields/7.json + - active: true + created_at: 2012-10-16T16:04:06Z + description: Description of Custom Field + id: 7 + key: custom_field_1 + position: 9999 + raw_description: "{{dc.my_description}}" + raw_title: Custom Field 1 + regexp_for_validation: null + title: Custom Field 1 + type: text + updated_at: 2012-10-16T16:04:06Z + url: https://company.zendesk.com/api/v2/organization_fields/7.json previous_page: null OrganizationMembershipCreateManyResponseExample: value: @@ -27232,72 +29405,72 @@ components: message: Completed at Fri Apr 13 02:51:53 +0000 2012 progress: 2 results: - - action: create - id: 380 - status: Created - success: true + - action: create + id: 380 + status: Created + success: true status: completed total: 2 url: https://company.zendesk.com/api/v2/job_statuses/8b726e606741012ffc2d782bcb7848fe.json OrganizationMembershipCreateResponseExample: value: organization_membership: - created_at: "2012-04-03T12:34:01Z" + created_at: 2012-04-03T12:34:01Z default: true id: 461 organization_id: 88 - updated_at: "2012-04-03T12:34:01Z" + updated_at: 2012-04-03T12:34:01Z user_id: 72 OrganizationMembershipResponseExample: value: organization_membership: - created_at: "2009-05-13T00:07:08Z" + created_at: 2009-05-13T00:07:08Z default: true id: 4 organization_id: 12 - updated_at: "2011-07-22T00:11:12Z" + updated_at: 2011-07-22T00:11:12Z user_id: 29 OrganizationMembershipsResponseExample: value: organization_memberships: - - created_at: "2009-05-13T00:07:08Z" - default: true - id: 4 - organization_id: 12 - organization_name: first organization - updated_at: "2011-07-22T00:11:12Z" - user_id: 29 - view_tickets: true - - created_at: "2012-03-13T22:01:32Z" - default: null - id: 49 - organization_id: 3 - organization_name: second organization - updated_at: "2012-03-13T22:01:32Z" - user_id: 155 - view_tickets: true + - created_at: 2009-05-13T00:07:08Z + default: true + id: 4 + organization_id: 12 + organization_name: first organization + updated_at: 2011-07-22T00:11:12Z + user_id: 29 + view_tickets: true + - created_at: 2012-03-13T22:01:32Z + default: null + id: 49 + organization_id: 3 + organization_name: second organization + updated_at: 2012-03-13T22:01:32Z + user_id: 155 + view_tickets: true OrganizationResponseExample: value: organization: - created_at: "2018-11-14T00:14:52Z" + created_at: 2018-11-14T00:14:52Z details: caterpillar =) domain_names: - - remain.com + - remain.com external_id: null group_id: 1835962 id: 4112492 name: Groablet Enterprises notes: donkey organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" + datepudding: 2018-11-04T00:00:00+00:00 org_field_1: happy happy org_field_2: teapot_kettle shared_comments: false shared_tickets: false tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z url: https://example.zendesk.com/api/v2/organizations/4112492.json OrganizationSubscriptionCreateRequestExample: value: @@ -27307,21 +29480,21 @@ components: OrganizationSubscriptionResponseExample: value: organization_subscription: - created_at: "2009-07-20T22:55:29Z" + created_at: 2009-07-20T22:55:29Z id: 1234 organization_id: 32 user_id: 482 OrganizationSubscriptionsResponseExample: value: organization_subscriptions: - - created_at: "2009-07-20T22:55:29Z" - id: 1234 - organization_id: 32 - user_id: 482 - - created_at: "2011-08-22T21:12:09Z" - id: 43681 - organization_id: 334 - user_id: 49471 + - created_at: 2009-07-20T22:55:29Z + id: 1234 + organization_id: 32 + user_id: 482 + - created_at: 2011-08-22T21:12:09Z + id: 43681 + organization_id: 334 + user_id: 49471 OrganizationsRelatedResponse: value: organization_related: @@ -27332,45 +29505,45 @@ components: count: 2 next_page: null organizations: - - created_at: "2018-11-14T00:14:52Z" - details: caterpillar =) - domain_names: - - remain.com - external_id: ABC198 - group_id: 1835962 - id: 4112492 - name: Groablet Enterprises - notes: donkey - organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" - org_field_1: happy happy - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" - url: https://example.zendesk.com/api/v2/organizations/4112492.json - - created_at: "2017-08-14T20:13:52Z" - details: test - domain_names: - - test.com - external_id: TTV273 - group_id: null - id: 1873 - name: Willy Wonkas Chocolate Factory - notes: "" - organization_fields: - datepudding: "2018-11-02T00:00:00+00:00" - org_field_1: malarky - org_field_2: teapot_kettle - shared_comments: false - shared_tickets: false - tags: - - teapot_kettle - updated_at: "2019-05-16T01:27:46Z" - url: https://example.zendesk.com.com/api/v2/organizations/1873.json + - created_at: 2018-11-14T00:14:52Z + details: caterpillar =) + domain_names: + - remain.com + external_id: ABC198 + group_id: 1835962 + id: 4112492 + name: Groablet Enterprises + notes: donkey + organization_fields: + datepudding: 2018-11-04T00:00:00+00:00 + org_field_1: happy happy + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z + url: https://example.zendesk.com/api/v2/organizations/4112492.json + - created_at: 2017-08-14T20:13:52Z + details: test + domain_names: + - test.com + external_id: TTV273 + group_id: null + id: 1873 + name: Willy Wonkas Chocolate Factory + notes: "" + organization_fields: + datepudding: 2018-11-02T00:00:00+00:00 + org_field_1: malarky + org_field_2: teapot_kettle + shared_comments: false + shared_tickets: false + tags: + - teapot_kettle + updated_at: 2019-05-16T01:27:46Z + url: https://example.zendesk.com.com/api/v2/organizations/1873.json previous_page: null PermanentlyDeleteTicketJobStatusResponseExample: value: @@ -27385,17 +29558,17 @@ components: PushNotificationDevicesRequestExample: value: push_notification_devices: - - token1 - - token2 + - token1 + - token2 QueueCreateResponseExample: value: queue: - created_at: "2023-11-27T09:03:59Z" + created_at: 2023-11-27T09:03:59Z definition: all: - - field: priority - operator: is - value: urgent + - field: priority + operator: is + value: urgent any: [] description: Queue description id: 01HG80ATNNZK1N7XRFVKX48XD6 @@ -27404,25 +29577,25 @@ components: primary_groups: count: 2 groups: - - id: 6784729637757 - name: EW - - id: 5399674286077 - name: test + - id: 6784729637757 + name: EW + - id: 5399674286077 + name: test priority: 1 secondary_groups: count: 0 groups: [] - updated_at: "2023-11-27T09:03:59Z" + updated_at: 2023-11-27T09:03:59Z url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json QueueResponseExample: value: queue: - created_at: "2023-11-27T09:03:59Z" + created_at: 2023-11-27T09:03:59Z definition: all: - - field: priority - operator: is - value: urgent + - field: priority + operator: is + value: urgent any: [] description: Queue description id: 01HG80ATNNZK1N7XRFVKX48XD6 @@ -27431,52 +29604,52 @@ components: primary_groups: count: 2 groups: - - id: 6784729637757 - name: EW - - id: 5399674286077 - name: test + - id: 6784729637757 + name: EW + - id: 5399674286077 + name: test priority: 1 secondary_groups: count: 0 groups: [] - updated_at: "2023-11-27T09:03:59Z" + updated_at: 2023-11-27T09:03:59Z url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json QueuesResponseExample: value: queues: - - created_at: "2023-11-27T09:03:59Z" - definition: - all: - - field: priority - operator: is - value: urgent - any: [] - description: Queue description - id: 01HG80ATNNZK1N7XRFVKX48XD6 - name: New queue with valid definition - order: 1 - primary_groups: - count: 2 - groups: - - id: 6784729637757 - name: EW - - id: 5399674286077 - name: test - priority: 1 - secondary_groups: - count: 0 - groups: [] - updated_at: "2023-11-27T09:03:59Z" - url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json + - created_at: 2023-11-27T09:03:59Z + definition: + all: + - field: priority + operator: is + value: urgent + any: [] + description: Queue description + id: 01HG80ATNNZK1N7XRFVKX48XD6 + name: New queue with valid definition + order: 1 + primary_groups: + count: 2 + groups: + - id: 6784729637757 + name: EW + - id: 5399674286077 + name: test + priority: 1 + secondary_groups: + count: 0 + groups: [] + updated_at: 2023-11-27T09:03:59Z + url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json QueuesUpdateResponseExample: value: queue: - created_at: "2023-11-27T09:03:59Z" + created_at: 2023-11-27T09:03:59Z definition: all: - - field: priority - operator: is - value: urgent + - field: priority + operator: is + value: urgent any: [] description: Queue description id: 01HG80ATNNZK1N7XRFVKX48XD6 @@ -27485,185 +29658,186 @@ components: primary_groups: count: 2 groups: - - id: 6784729637757 - name: EW - - id: 5399674286077 - name: test + - id: 6784729637757 + name: EW + - id: 5399674286077 + name: test priority: 1 secondary_groups: count: 0 groups: [] - updated_at: "2023-11-27T09:03:59Z" + updated_at: 2023-11-27T09:03:59Z url: https://company.zendesk.com/api/v2/queues/01HG80ATNNZK1N7XRFVKX48XD6.json RecoverSuspendedTicketResponseExample: value: ticket: - - author: - email: spammer@example.com - id: 66 - name: Spammer - brand_id: 123 - cause: Detected as spam - cause_id: 0 - content: Visit http://casino.spam.com - created_at: "2009-07-20T22:55:29Z" - id: 3436 - recipient: support@example.support.com - subject: Free Casino Money! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/67321.json - via: - channel: web + - author: + email: spammer@example.com + id: 66 + name: Spammer + brand_id: 123 + cause: Detected as spam + cause_id: 0 + content: Visit http://casino.spam.com + created_at: 2009-07-20T22:55:29Z + id: 3436 + recipient: support@example.support.com + subject: Free Casino Money! + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/67321.json + via: + channel: web RecoverSuspendedTicketUnprocessableContentResponseExample: value: ticket: - - author: - email: help@example.com - id: 1 - name: Help - brand_id: 123 - cause: Received from support address - cause_id: 22 - content: Your request has been received and is being reviewed by our support staff. - created_at: "2023-04-06T20:51:31Z" - error_messages: null - id: 14668816692628 - message_id: - recipient: support@example.support.com - subject: Received from support address - ticket_id: 14668816692628 - updated_at: "2023-04-06T20:51:31Z" - url: https://example.zendesk.com/api/v2/tickets/14668816692628.json - via: - channel: email - source: - from: - address: help@example.com, - name: Help - rel: null - to: - address: support@example.zendesk.com - name: Support, + - author: + email: help@example.com + id: 1 + name: Help + brand_id: 123 + cause: Received from support address + cause_id: 22 + content: Your request has been received and is being reviewed by our support + staff. + created_at: 2023-04-06T20:51:31Z + error_messages: null + id: 14668816692628 + message_id: + recipient: support@example.support.com + subject: Received from support address + ticket_id: 14668816692628 + updated_at: 2023-04-06T20:51:31Z + url: https://example.zendesk.com/api/v2/tickets/14668816692628.json + via: + channel: email + source: + from: + address: "help@example.com," + name: Help + rel: null + to: + address: support@example.zendesk.com + name: "Support," RecoverSuspendedTicketsResponseExample: value: tickets: - - author: - email: styx@example.com - id: 1 - name: Mr. Roboto - brand_id: 123 - cause: Detected as spam - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - id: 3436 - recipient: john@example.com - subject: Help I need somebody! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - - author: - email: styx@example.com - id: 1 - name: Mr. Roboto - brand_id: 123 - cause: Detected as spam - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - id: 3437 - recipient: john@example.com - subject: Not just anybody! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: web + - author: + email: styx@example.com + id: 1 + name: Mr. Roboto + brand_id: 123 + cause: Detected as spam + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + id: 3436 + recipient: john@example.com + subject: Help I need somebody! + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + - author: + email: styx@example.com + id: 1 + name: Mr. Roboto + brand_id: 123 + cause: Detected as spam + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + id: 3437 + recipient: john@example.com + subject: Not just anybody! + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: web RelationshipFilterDefinitionExample: value: definitions: conditions_all: - - group: ticket - nullable: false - operators: - - terminal: false - title: Is - value: is - - terminal: false - title: Is not - value: is_not - - terminal: false - title: Less than - value: less_than - - terminal: false - title: Greater than - value: greater_than - - terminal: true - title: Changed - value: changed - - terminal: false - title: Changed to - value: value - - terminal: false - title: Changed from - value: value_previous - - terminal: true - title: Not changed - value: not_changed - - terminal: false - title: Not changed to - value: not_value - - terminal: false - title: Not changed from - value: not_value_previous - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: true - title: New - value: new - - enabled: true - title: Open - value: open - - enabled: true - title: Pending - value: pending - - enabled: true - title: Solved - value: solved - - enabled: true - title: Closed - value: closed + - group: ticket + nullable: false + operators: + - terminal: false + title: Is + value: is + - terminal: false + title: Is not + value: is_not + - terminal: false + title: Less than + value: less_than + - terminal: false + title: Greater than + value: greater_than + - terminal: true + title: Changed + value: changed + - terminal: false + title: Changed to + value: value + - terminal: false + title: Changed from + value: value_previous + - terminal: true + title: Not changed + value: not_changed + - terminal: false + title: Not changed to + value: not_value + - terminal: false + title: Not changed from + value: not_value_previous + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: true + title: New + value: new + - enabled: true + title: Open + value: open + - enabled: true + title: Pending + value: pending + - enabled: true + title: Solved + value: solved + - enabled: true + title: Closed + value: closed conditions_any: - - group: ticket - nullable: true - operators: - - terminal: true - title: Present - value: present - - terminal: true - title: Not present - value: not_present - repeatable: false - subject: custom_fields_20513432 - title: Happy Gilmore - type: list - - group: ticket - nullable: true - operators: - - terminal: true - title: Present - value: present - - terminal: true - title: Not present - value: not_present - repeatable: false - subject: custom_fields_86492341 - title: total_time_field - type: list + - group: ticket + nullable: true + operators: + - terminal: true + title: Present + value: present + - terminal: true + title: Not present + value: not_present + repeatable: false + subject: custom_fields_20513432 + title: Happy Gilmore + type: list + - group: ticket + nullable: true + operators: + - terminal: true + title: Present + value: present + - terminal: true + title: Not present + value: not_present + repeatable: false + subject: custom_fields_86492341 + title: total_time_field + type: list RenewSessionResponseExample: value: authenticity_token: huU19Z76zNC9Yvt+i9p7MviIOlOIg/JWqEdf6nGmnu9JInV04fksCIdtNDvoYAoV @@ -27683,8 +29857,8 @@ components: RequestListCommentsResponseExample: value: comments: - - body: Thanks for your help - id: 43 + - body: Thanks for your help + id: 43 RequestResponseExample: value: request: @@ -27701,16 +29875,16 @@ components: RequestsResponseExample: value: requests: - - custom_status_id: 123 - description: My printer is on fire! - id: 33 - status: open - subject: Help! - - custom_status_id: 234 - description: I can't find my keys - id: 34 - status: closed - subject: Help! + - custom_status_id: 123 + description: My printer is on fire! + id: 33 + status: open + subject: Help! + - custom_status_id: 234 + description: I can't find my keys + id: 34 + status: closed + subject: Help! ResourceCollectionCreateResponseExample: value: job_status: @@ -27734,18 +29908,18 @@ components: ResourceCollectionResponseExample: value: resource_collection: - created_at: "2015-09-09T01:57:24Z" + created_at: 2015-09-09T01:57:24Z id: 10002 resources: - - deleted: false - identifier: email_on_ticket_solved - resource_id: 10824486485524 - type: triggers - - deleted: false - identifier: support_description - resource_id: 10824486482580 - type: ticket_fields - updated_at: "2015-09-09T01:57:24Z" + - deleted: false + identifier: email_on_ticket_solved + resource_id: 10824486485524 + type: triggers + - deleted: false + identifier: support_description + resource_id: 10824486482580 + type: ticket_fields + updated_at: 2015-09-09T01:57:24Z ResourceCollectionUpdateResponseExample: value: job_status: @@ -27762,259 +29936,260 @@ components: next_page: null previous_page: null resource_collections: - - created_at: "2015-09-09T01:57:24Z" - id: 10002 - resources: - - deleted: false - identifier: email_on_ticket_solved - resource_id: 10824486485524 - type: triggers - - deleted: false - identifier: support_description - resource_id: 10824486482580 - type: ticket_fields - updated_at: "2015-09-09T01:57:24Z" - - created_at: "2015-09-10T02:01:03Z" - id: 10002 - resources: - - deleted: false - identifier: an_email_target - resource_id: 10827267902996 - type: targets - updated_at: "2015-09-10T02:02:15Z" + - created_at: 2015-09-09T01:57:24Z + id: 10002 + resources: + - deleted: false + identifier: email_on_ticket_solved + resource_id: 10824486485524 + type: triggers + - deleted: false + identifier: support_description + resource_id: 10824486482580 + type: ticket_fields + updated_at: 2015-09-09T01:57:24Z + - created_at: 2015-09-10T02:01:03Z + id: 10002 + resources: + - deleted: false + identifier: an_email_target + resource_id: 10827267902996 + type: targets + updated_at: 2015-09-10T02:02:15Z ReverseLookupUsersResponseExample: value: users: - - id: 223443 - name: Johnny Agent - - id: 8678530 - name: James A. Rosen + - id: 223443 + name: Johnny Agent + - id: 8678530 + name: James A. Rosen SLAPoliciesResponseExample: value: count: 1 next_page: null previous_page: null sla_policies: - - description: For urgent incidents, we will respond to tickets in 10 minutes - filter: - all: - - field: type - operator: is - value: incident - - field: via_id - operator: is - value: "4" - any: [] - id: 36 - policy_metrics: - - business_hours: false - metric: first_reply_time - priority: low - target: 60 - position: 3 - title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json + - description: "For urgent incidents, we will respond to tickets in 10 minutes" + filter: + all: + - field: type + operator: is + value: incident + - field: via_id + operator: is + value: "4" + any: [] + id: 36 + policy_metrics: + - business_hours: false + metric: first_reply_time + priority: low + target: 60 + position: 3 + title: Incidents + url: "https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json" SLAPolicyCreateResponse: value: sla_policy: - description: For urgent incidents, we will respond to tickets in 10 minutes + description: "For urgent incidents, we will respond to tickets in 10 minutes" filter: all: - - field: type - operator: is - value: incident + - field: type + operator: is + value: incident any: [] id: 36 policy_metrics: - - business_hours: false - metric: first_reply_time - priority: normal - target: 30 - - business_hours: false - metric: first_reply_time - priority: urgent - target: 10 - - business_hours: false - metric: requester_wait_time - priority: low - target: 180 - - business_hours: false - metric: requester_wait_time - priority: normal - target: 160 - - business_hours: false - metric: requester_wait_time - priority: high - target: 140 - - business_hours: false - metric: requester_wait_time - priority: urgent - target: 120 + - business_hours: false + metric: first_reply_time + priority: normal + target: 30 + - business_hours: false + metric: first_reply_time + priority: urgent + target: 10 + - business_hours: false + metric: requester_wait_time + priority: low + target: 180 + - business_hours: false + metric: requester_wait_time + priority: normal + target: 160 + - business_hours: false + metric: requester_wait_time + priority: high + target: 140 + - business_hours: false + metric: requester_wait_time + priority: urgent + target: 120 position: 3 title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json + url: "https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json" SLAPolicyFilterDefinitionResponseExample: value: definitions: all: - - group: ticket - operators: - - title: Is - value: is - - title: Is not - value: is_not - target: null - title: Brand - value: brand_id - values: - list: - - title: Support - value: "10001" - type: list + - group: ticket + operators: + - title: Is + value: is + - title: Is not + value: is_not + target: null + title: Brand + value: brand_id + values: + list: + - title: Support + value: "10001" + type: list any: - - group: ticket - operators: - - title: Is - value: is - - title: Is not - value: is_not - target: null - title: Brand - value: brand_id - values: - list: - - title: Support - value: "10001" - type: list + - group: ticket + operators: + - title: Is + value: is + - title: Is not + value: is_not + target: null + title: Brand + value: brand_id + values: + list: + - title: Support + value: "10001" + type: list SLAPolicyResponseExample: value: sla_policy: - description: For urgent incidents, we will respond to tickets in 10 minutes + description: "For urgent incidents, we will respond to tickets in 10 minutes" filter: all: - - field: type - operator: is - value: incident - - field: via_id - operator: is - value: "4" + - field: type + operator: is + value: incident + - field: via_id + operator: is + value: "4" any: [] id: 36 policy_metrics: - - business_hours: false - metric: first_reply_time - priority: low - target: 60 + - business_hours: false + metric: first_reply_time + priority: low + target: 60 position: 3 title: Incidents - url: https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json + url: "https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json" SLAPolicyUpdateResponse: value: sla_policy: - description: For urgent incidents, we will resolve the ticket within 2 hours + description: "For urgent incidents, we will resolve the ticket within 2\ + \ hours" filter: all: - - field: type - operator: is - value: incident + - field: type + operator: is + value: incident any: [] id: 36 policy_metrics: - - business_hours: false - metric: first_reply_time - priority: normal - target: 30 - - business_hours: false - metric: first_reply_time - priority: urgent - target: 10 - - business_hours: false - metric: requester_wait_time - priority: low - target: 180 - - business_hours: false - metric: requester_wait_time - priority: normal - target: 160 - - business_hours: false - metric: requester_wait_time - priority: high - target: 140 - - business_hours: false - metric: requester_wait_time - priority: urgent - target: 120 + - business_hours: false + metric: first_reply_time + priority: normal + target: 30 + - business_hours: false + metric: first_reply_time + priority: urgent + target: 10 + - business_hours: false + metric: requester_wait_time + priority: low + target: 180 + - business_hours: false + metric: requester_wait_time + priority: normal + target: 160 + - business_hours: false + metric: requester_wait_time + priority: high + target: 140 + - business_hours: false + metric: requester_wait_time + priority: urgent + target: 120 position: 3 title: Urgent Incidents - url: https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json + url: "https://{subdomain}.zendesk.com/api/v2/slas/policies/36.json" SatisfactionRatingResponseExample: value: satisfaction_rating: - - assignee_id: 135 - comment: Awesome support! - created_at: "2011-07-20T22:55:29Z" - group_id: 44 - id: 35436 - requester_id: 7881 - score: good - ticket_id: 208 - updated_at: "2011-07-20T22:55:29Z" - url: https://example.zendesk.com/api/v2/satisfaction_ratings/35436.json + - assignee_id: 135 + comment: Awesome support! + created_at: 2011-07-20T22:55:29Z + group_id: 44 + id: 35436 + requester_id: 7881 + score: good + ticket_id: 208 + updated_at: 2011-07-20T22:55:29Z + url: https://example.zendesk.com/api/v2/satisfaction_ratings/35436.json SatisfactionRatingsCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 SatisfactionRatingsResponseExample: value: satisfaction_ratings: - - assignee_id: 135 - comment: Awesome support! - created_at: "2011-07-20T22:55:29Z" - group_id: 44 - id: 35436 - requester_id: 7881 - score: good - ticket_id: 208 - updated_at: "2011-07-20T22:55:29Z" - url: https://example.zendesk.com/api/v2/satisfaction_ratings/35436.json - - assignee_id: 136 - comment: Awesome support! - created_at: "2012-02-01T04:31:29Z" - group_id: 44 - id: 120447 - requester_id: 7881 - score: good - ticket_id: 209 - updated_at: "2012-02-02T10:32:59Z" - url: https://example.zendesk.com/api/v2/satisfaction_ratings/120447.json + - assignee_id: 135 + comment: Awesome support! + created_at: 2011-07-20T22:55:29Z + group_id: 44 + id: 35436 + requester_id: 7881 + score: good + ticket_id: 208 + updated_at: 2011-07-20T22:55:29Z + url: https://example.zendesk.com/api/v2/satisfaction_ratings/35436.json + - assignee_id: 136 + comment: Awesome support! + created_at: 2012-02-01T04:31:29Z + group_id: 44 + id: 120447 + requester_id: 7881 + score: good + ticket_id: 209 + updated_at: 2012-02-02T10:32:59Z + url: https://example.zendesk.com/api/v2/satisfaction_ratings/120447.json SatisfactionReasonResponseExample: value: reason: - - created_at: "2011-07-20T22:55:29Z" - id: 35121 - raw_value: '{{dc.reason_code_1000}}' - reason_code: 1000 - updated_at: "2011-07-20T22:55:29Z" - url: https://company.zendesk.com/api/v2/satisfaction_reason/35121.json - value: Agent did not respond quickly. + - created_at: 2011-07-20T22:55:29Z + id: 35121 + raw_value: "{{dc.reason_code_1000}}" + reason_code: 1000 + updated_at: 2011-07-20T22:55:29Z + url: https://company.zendesk.com/api/v2/satisfaction_reason/35121.json + value: Agent did not respond quickly. SatisfactionReasonsResponseExample: value: reasons: - - created_at: "2011-07-20T22:55:29Z" - id: 35436 - raw_value: '{{dc.reason_code_1000}}' - reason_code: 1000 - updated_at: "2011-07-20T22:55:29Z" - url: https://company.zendesk.com/api/v2/satisfaction_reasons/35436.json - value: Agent did not respond quickly. - - created_at: "2011-07-20T22:55:29Z" - id: 120447 - raw_value: '{{dc.reason_code_1000}}' - reason_code: 1001 - updated_at: "2011-07-20T22:55:29Z" - url: https://company.zendesk.com/api/v2/satisfaction_reasons/120447.json - value: Issue is not resolved. + - created_at: 2011-07-20T22:55:29Z + id: 35436 + raw_value: "{{dc.reason_code_1000}}" + reason_code: 1000 + updated_at: 2011-07-20T22:55:29Z + url: https://company.zendesk.com/api/v2/satisfaction_reasons/35436.json + value: Agent did not respond quickly. + - created_at: 2011-07-20T22:55:29Z + id: 120447 + raw_value: "{{dc.reason_code_1000}}" + reason_code: 1001 + updated_at: 2011-07-20T22:55:29Z + url: https://company.zendesk.com/api/v2/satisfaction_reasons/120447.json + value: Issue is not resolved. SearchCountResponseExample: value: count: 6 @@ -28036,46 +30211,46 @@ components: next_page: https://foo.zendesk.com/api/v2/search.json?query="type:Group hello"&sort_by=created_at&sort_order=desc&page=2 previous_page: null results: - - created_at: "2009-05-13T00:07:08Z" - id: 211 - name: Hello DJs - result_type: group - updated_at: "2011-07-22T00:11:12Z" - url: https://foo.zendesk.com/api/v2/groups/211.json - - created_at: "2009-08-26T00:07:08Z" - id: 122 - name: Hello MCs - result_type: group - updated_at: "2010-05-13T00:07:08Z" - url: https://foo.zendesk.com/api/v2/groups/122.json + - created_at: 2009-05-13T00:07:08Z + id: 211 + name: Hello DJs + result_type: group + updated_at: 2011-07-22T00:11:12Z + url: https://foo.zendesk.com/api/v2/groups/211.json + - created_at: 2009-08-26T00:07:08Z + id: 122 + name: Hello MCs + result_type: group + updated_at: 2010-05-13T00:07:08Z + url: https://foo.zendesk.com/api/v2/groups/122.json SearchUsersResponseExample: value: users: - - id: 35436 - name: Robert Jones - notes: sigil issue - - id: 9873843 - name: Terry Gilliam + - id: 35436 + name: Robert Jones + notes: sigil issue + - id: 9873843 + name: Terry Gilliam SessionResponseExample: value: session: - - authenticated_at: "2014-11-18T17:24:29Z" - id: 3432 - last_seen_at: "2014-11-18T17:30:52Z" - url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json - user_id: 12345 + - authenticated_at: 2014-11-18T17:24:29Z + id: 3432 + last_seen_at: 2014-11-18T17:30:52Z + url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json + user_id: 12345 SessionsResponseExample: value: sessions: - - authenticated_at: "2014-11-18T17:24:29Z" - id: 3432 - last_seen_at: "2014-11-18T17:30:52Z" - url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json - user_id: 12345 + - authenticated_at: 2014-11-18T17:24:29Z + id: 3432 + last_seen_at: 2014-11-18T17:30:52Z + url: https://company.zendesk.com/api/v2/users/12345/sessions/3432.json + user_id: 12345 SharingAgreementCreateResponseExample: value: sharing_agreement: - created_at: "2012-02-20T22:55:29Z" + created_at: 2012-02-20T22:55:29Z id: 1 name: Foo @ Zendesk partner_name: null @@ -28086,7 +30261,7 @@ components: SharingAgreementResponseExample: value: sharing_agreement: - created_at: "2012-02-20T22:55:29Z" + created_at: 2012-02-20T22:55:29Z id: 1 name: Foo @ Zendesk partner_name: null @@ -28097,7 +30272,7 @@ components: SharingAgreementUpdateResponseExample: value: sharing_agreement: - created_at: "2012-02-20T22:55:29Z" + created_at: 2012-02-20T22:55:29Z id: 1 name: Foo @ Zendesk partner_name: null @@ -28108,36 +30283,36 @@ components: SharingAgreementsResponseExample: value: sharing_agreements: - - created_at: "2012-02-20T22:55:29Z" - id: 1 - name: Foo @ Zendesk - partner_name: jira - status: accepted - type: inbound - url: https://company.zendesk.com/api/v2/agreements/1.json + - created_at: 2012-02-20T22:55:29Z + id: 1 + name: Foo @ Zendesk + partner_name: jira + status: accepted + type: inbound + url: https://company.zendesk.com/api/v2/agreements/1.json ShowDerivedMacroResponseExample: value: definitions: actions: - - group: ticket - nullable: false - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: true - title: Open - value: "1" - - enabled: true - title: Pending - value: "2" - - enabled: true - title: Solved - value: "3" - - enabled: true - title: Closed - value: "4" + - group: ticket + nullable: false + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: true + title: Open + value: "1" + - enabled: true + title: Pending + value: "2" + - enabled: true + title: Solved + value: "3" + - enabled: true + title: Closed + value: "4" ShowJobStatusResponseExample: value: job_status: @@ -28145,200 +30320,200 @@ components: message: Completed at Fri Apr 13 02:51:53 +0000 2012 progress: 2 results: - - action: update - id: 380 - status: Updated - success: true + - action: update + id: 380 + status: Updated + success: true status: completed total: 2 url: https://company.zendesk.com/api/v2/job_statuses/8b726e606741012ffc2d782bcb7848fe.json ShowManyUsersResponseExample: value: users: - - id: 345678 - name: Johnny Appleseed - - id: 901234 - name: Rupert Root + - id: 345678 + name: Johnny Appleseed + - id: 901234 + name: Rupert Root SkillBasedRoutingAttributeCreateResponseExample: value: attribute: - created_at: "2018-11-15T23:44:45Z" + created_at: 2018-11-15T23:44:45Z id: 6e279587-e930-11e8-a292-09cfcdea1b75 name: Language - updated_at: "2018-11-15T23:44:45Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json + updated_at: 2018-11-15T23:44:45Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json" SkillBasedRoutingAttributeDefinitionsExample: value: definitions: conditions_all: - - subject: number_of_incidents - title: Number of incidents + - subject: number_of_incidents + title: Number of incidents conditions_any: - - subject: brand - title: Brand + - subject: brand + title: Brand SkillBasedRoutingAttributeResponseExample: value: attribute: - created_at: "2018-11-15T23:44:45Z" + created_at: 2018-11-15T23:44:45Z id: 6e279587-e930-11e8-a292-09cfcdea1b75 name: Language - updated_at: "2018-11-15T23:44:45Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json + updated_at: 2018-11-15T23:44:45Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json" SkillBasedRoutingAttributeUpdateResponseExample: value: attribute: - created_at: "2018-11-15T23:44:45Z" + created_at: 2018-11-15T23:44:45Z id: 6e279587-e930-11e8-a292-09cfcdea1b75 name: Lingua - updated_at: "2018-11-15T23:44:45Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json + updated_at: 2018-11-15T23:44:45Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/6e279587-e930-11e8-a292-09cfcdea1b75.json" SkillBasedRoutingAttributeValueCreateResponseExample: value: attribute_value: - created_at: "2018-11-08T19:22:58Z" + created_at: 2018-11-08T19:22:58Z id: 6ccddacf-e85e-11e8-a292-ad7686bdff67 name: Japanese - updated_at: "2018-11-08T19:22:58Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/6ccddacf-e85e-11e8-a292-ad7686bdff67.json + updated_at: 2018-11-08T19:22:58Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/6ccddacf-e85e-11e8-a292-ad7686bdff67.json" SkillBasedRoutingAttributeValueResponseExample: value: attribute_value: - created_at: "2018-11-08T19:22:58Z" + created_at: 2018-11-08T19:22:58Z id: b376b35a-e38b-11e8-a292-e3b6377c5575 name: French - updated_at: "2018-11-08T19:22:58Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json + updated_at: 2018-11-08T19:22:58Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json" SkillBasedRoutingAttributeValueUpdateResponseExample: value: attribute_value: - created_at: "2018-11-14T22:41:28Z" + created_at: 2018-11-14T22:41:28Z id: b376b35a-e38b-11e8-a292-e3b6377c5575 name: German (Advanced) - updated_at: "2018-11-14T22:45:01Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json + updated_at: 2018-11-14T22:45:01Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json" SkillBasedRoutingAttributeValuesResponseExample: value: attribute_values: - - created_at: "2018-11-08T19:22:58Z" - id: b376b35a-e38b-11e8-a292-e3b6377c5575 - name: French - updated_at: "2018-11-08T19:22:58Z" - url: https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json + - created_at: 2018-11-08T19:22:58Z + id: b376b35a-e38b-11e8-a292-e3b6377c5575 + name: French + updated_at: 2018-11-08T19:22:58Z + url: "https://{subdomain}.zendesk.com/api/v2/routing/attributes/afa31619-e38b-11e8-a292-5d17513d969b/values/b376b35a-e38b-11e8-a292-e3b6377c5575.json" SkillBasedRoutingAttributesResponseExample: value: attributes: - - created_at: "2017-12-01T19:29:31Z" - id: 15821cba-7326-11e8-b07e-950ba849aa27 - name: Color - updated_at: "2017-12-01T19:29:31Z" + - created_at: 2017-12-01T19:29:31Z + id: 15821cba-7326-11e8-b07e-950ba849aa27 + name: Color + updated_at: 2017-12-01T19:29:31Z count: 1 next_page: null previous_page: null SkillBasedRoutingTicketAttributesResponseExample: value: attribute_values: - - attribute_id: f4a604b1-d6cd-11e7-a492-657e7928664c - created_at: "2017-12-01T19:29:41Z" - id: fa1131e2-d6cd-11e7-a492-dbdd5500c7e3 - name: Ocean - updated_at: "2017-12-01T19:35:45Z" + - attribute_id: f4a604b1-d6cd-11e7-a492-657e7928664c + created_at: 2017-12-01T19:29:41Z + id: fa1131e2-d6cd-11e7-a492-dbdd5500c7e3 + name: Ocean + updated_at: 2017-12-01T19:35:45Z SkillBasedRoutingTicketFulfilledResponseExample: value: fulfilled_ticket_ids: - - 1 - - 17 + - 1 + - 17 SupportAddressCreateResponseExample: value: recipient_address: brand_id: 123 cname_status: verified - created_at: "2017-04-02T22:55:29Z" + created_at: 2017-04-02T22:55:29Z default: false email: help@example.zendesk.com forwarding_status: waiting id: 33 name: Sales spf_status: verified - updated_at: "2017-04-02T22:55:29Z" + updated_at: 2017-04-02T22:55:29Z SupportAddressResponseExample: value: recipient_address: brand_id: 123 cname_status: unknown - created_at: "2017-04-02T22:55:29Z" + created_at: 2017-04-02T22:55:29Z default: true email: help@example.zendesk.com forwarding_status: waiting id: 33 name: Sales spf_status: unknown - updated_at: "2017-04-02T22:55:29Z" + updated_at: 2017-04-02T22:55:29Z SupportAddressUpdateResponseExample: value: recipient_address: brand_id: 123 - created_at: "2017-04-02T22:55:29Z" + created_at: 2017-04-02T22:55:29Z default: true email: name2@example.com forwarding_status: verified id: 33 name: Sales - updated_at: "2017-05-02T22:55:29Z" + updated_at: 2017-05-02T22:55:29Z SupportAddressesResponseExample: value: recipient_addresses: - - brand_id: 123 - cname_status: verified - created_at: "2015-07-20T22:55:29Z" - default: true - domain_verification_status: verified - email: sales@example.zendesk.com - forwarding_status: unknown - id: 33 - name: Sales - spf_status: verified - updated_at: "2016-09-21T20:15:20Z" - - brand_id: 123 - cname_status: verified - created_at: "2015-07-20T22:55:29Z" - default: false - domain_verification_status: verified - email: marketing@example.zendesk.com - forwarding_status: unknown - id: 34 - name: Marketing - spf_status: verified - updated_at: "2016-09-21T20:15:20Z" + - brand_id: 123 + cname_status: verified + created_at: 2015-07-20T22:55:29Z + default: true + domain_verification_status: verified + email: sales@example.zendesk.com + forwarding_status: unknown + id: 33 + name: Sales + spf_status: verified + updated_at: 2016-09-21T20:15:20Z + - brand_id: 123 + cname_status: verified + created_at: 2015-07-20T22:55:29Z + default: false + domain_verification_status: verified + email: marketing@example.zendesk.com + forwarding_status: unknown + id: 34 + name: Marketing + spf_status: verified + updated_at: 2016-09-21T20:15:20Z SuspendedTicketResponseExample: value: suspended_ticket: - - author: - email: styx@example.com - id: 1 - name: Mr. Roboto - brand_id: 123 - cause: Detected as spam - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - id: 3436 - recipient: john@example.com - subject: Help I need somebody! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: web + - author: + email: styx@example.com + id: 1 + name: Mr. Roboto + brand_id: 123 + cause: Detected as spam + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + id: 3436 + recipient: john@example.com + subject: Help I need somebody! + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: web SuspendedTicketsAttachmentsResponseExample: value: upload: attachments: - - content_type: application/ics - content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=calendar.ics - file_name: calendar.ics - id: 367 - size: 1166 - thumbnails: [] - url: https://company.zendesk.com/api/v2/attachments/367.json + - content_type: application/ics + content_url: https://company.zendesk.com/attachments/token/tyBq1ms40dFaHefSIigxZpwGg/?name=calendar.ics + file_name: calendar.ics + id: 367 + size: 1166 + thumbnails: [] + url: https://company.zendesk.com/api/v2/attachments/367.json token: yrznqgjoa24iw2f SuspendedTicketsExportResponseExample: value: @@ -28348,91 +30523,91 @@ components: SuspendedTicketsResponseExample: value: suspended_tickets: - - attachments: [] - author: - email: styx@example.com - id: 1 - name: Mr. Roboto - brand_id: 123 - cause: Detected as spam - cause_id: 0 - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - error_messages: null - id: 435 - message_id: Spambot@spam.co.evil - recipient: john@example.com - subject: Help, my printer is on fire! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: email - source: - from: - address: totallylegit@emailaddress.com - name: TotallyLegit - rel: null - to: - address: support@example.zendesk.com - name: Example Account - - attachments: [] - author: - email: styx@example.com - id: 1 - name: Mr. Roboto - brand_id: 123 - cause: Automated response mail - cause_id: 0 - content: Out Of Office Reply - created_at: "2009-07-20T22:55:29Z" - error_messages: null - id: 207623 - message_id: Spambot@spam.co.evil - recipient: john@example.com - subject: Not just anybody! - ticket_id: 67321 - updated_at: "2011-05-05T10:38:52Z" - url: https://example.zendesk.com/api/v2/tickets/35436.json - via: - channel: email - source: - from: - address: totallylegit@emailaddress.com - name: TotallyLegit - rel: null - to: - address: support@example.zendesk.com - name: Example Account + - attachments: [] + author: + email: styx@example.com + id: 1 + name: Mr. Roboto + brand_id: 123 + cause: Detected as spam + cause_id: 0 + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + error_messages: null + id: 435 + message_id: Spambot@spam.co.evil + recipient: john@example.com + subject: "Help, my printer is on fire!" + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: email + source: + from: + address: totallylegit@emailaddress.com + name: TotallyLegit + rel: null + to: + address: support@example.zendesk.com + name: Example Account + - attachments: [] + author: + email: styx@example.com + id: 1 + name: Mr. Roboto + brand_id: 123 + cause: Automated response mail + cause_id: 0 + content: Out Of Office Reply + created_at: 2009-07-20T22:55:29Z + error_messages: null + id: 207623 + message_id: Spambot@spam.co.evil + recipient: john@example.com + subject: Not just anybody! + ticket_id: 67321 + updated_at: 2011-05-05T10:38:52Z + url: https://example.zendesk.com/api/v2/tickets/35436.json + via: + channel: email + source: + from: + address: totallylegit@emailaddress.com + name: TotallyLegit + rel: null + to: + address: support@example.zendesk.com + name: Example Account TagCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 TagsAutocompleteResponseExample: value: tags: - - attention - - attack + - attention + - attack TagsByObjectIdResponse: value: tags: - - urgent - - printer - - fire + - urgent + - printer + - fire TagsResponseExample: value: count: 1 next_page: null previous_page: null tags: - - count: 10 - name: Triage + - count: 10 + name: Triage TargetCreateResponseExample: value: target: active: true - created_at: "2009-05-13T00:07:08Z" + created_at: 2009-05-13T00:07:08Z email: hello@example.com subject: Test Target title: Test Email Target @@ -28441,24 +30616,25 @@ components: value: target_failure: id: 1 - raw_request: "GET /api/v2/tickets.json HTTP/1.1\r\nUser-Agent: Zendesk Target\r\n ..." + raw_request: "GET /api/v2/tickets.json HTTP/1.1\r\nUser-Agent: Zendesk Target\r\ + \n ..." raw_response: "HTTP/1.1 401 Unauthorized\r\nServer: nginx\r\n ..." status_code: 401 target_name: My URL Target TargetFailuresResponseExample: value: target_failures: - - id: 1 - status_code: 401 - target_name: My URL Target - - id: 2 - status_code: 401 - target_name: My URL Target + - id: 1 + status_code: 401 + target_name: My URL Target + - id: 2 + status_code: 401 + target_name: My URL Target TargetResponseExample: value: target: active: true - created_at: "2009-05-13T00:07:08Z" + created_at: 2009-05-13T00:07:08Z id: 211 title: Fancy box type: basecamp_target @@ -28466,7 +30642,7 @@ components: value: target: active: true - created_at: "2009-05-13T00:07:08Z" + created_at: 2009-05-13T00:07:08Z email: roger@example.com subject: Test Target title: Test Email Target @@ -28474,112 +30650,114 @@ components: TargetsResponseExample: value: targets: - - active: true - created_at: "2009-05-13T00:07:08Z" - id: 211 - title: Fancy box - type: basecamp_target + - active: true + created_at: 2009-05-13T00:07:08Z + id: 211 + title: Fancy box + type: basecamp_target TicketAuditResponseExample: value: audit: author_id: 5246746 - created_at: "2011-09-25T22:35:44Z" + created_at: 2011-09-25T22:35:44Z events: - - attachments: [] - body: This is a new private comment - html_body:

This is a new private comment

- id: 2127301148 - public: false - type: Comment - - field_name: status - id: 2127301163 - previous_value: new - type: Change - value: open - via: - channel: rule - source: - from: - id: 22472716 - title: Assign to first responder - rel: trigger - to: {} - - field_name: custom_status_id - id: 2127301164 - previous_value: 1 - type: Change - value: 123 - via: - channel: rule - source: - from: - id: 22472716 - title: Assign to first responder - rel: trigger - to: {} + - attachments: [] + body: This is a new private comment + html_body:

This is a new private comment

+ id: 2127301148 + public: false + type: Comment + - field_name: status + id: 2127301163 + previous_value: new + type: Change + value: open + via: + channel: rule + source: + from: + id: 22472716 + title: Assign to first responder + rel: trigger + to: {} + - field_name: custom_status_id + id: 2127301164 + previous_value: 1 + type: Change + value: 123 + via: + channel: rule + source: + from: + id: 22472716 + title: Assign to first responder + rel: trigger + to: {} id: 2127301143 metadata: custom: {} system: - client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1 + client: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/535.1\ + \ (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1" ip_address: 76.218.201.212 - location: San Francisco, CA, United States + location: "San Francisco, CA, United States" ticket_id: 666 via: channel: web TicketAuditsCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 18 TicketAuditsForTicketResponseExample: value: audits: - - author_id: 5246746 - created_at: "2011-09-25T22:35:44Z" - events: - - attachments: [] - body: This is a new private comment - html_body:

This is a new private comment

- id: 2127301148 - public: false - type: Comment - - field_name: status - id: 2127301163 - previous_value: new - type: Change - value: open - via: - channel: rule - source: - from: - id: 35079792 - title: Assign to first responder - rel: trigger - to: {} - - field_name: custom_status_id - id: 2127301164 - previous_value: 1 - type: Change - value: 123 - via: - channel: rule - source: - from: - id: 22472716 - title: Assign to first responder - rel: trigger - to: {} - id: 2127301143 - metadata: - custom: {} - system: - client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1 - ip_address: 76.218.201.212 - location: San Francisco, CA, United States - ticket_id: 666 + - author_id: 5246746 + created_at: 2011-09-25T22:35:44Z + events: + - attachments: [] + body: This is a new private comment + html_body:

This is a new private comment

+ id: 2127301148 + public: false + type: Comment + - field_name: status + id: 2127301163 + previous_value: new + type: Change + value: open via: - channel: web + channel: rule + source: + from: + id: 35079792 + title: Assign to first responder + rel: trigger + to: {} + - field_name: custom_status_id + id: 2127301164 + previous_value: 1 + type: Change + value: 123 + via: + channel: rule + source: + from: + id: 22472716 + title: Assign to first responder + rel: trigger + to: {} + id: 2127301143 + metadata: + custom: {} + system: + client: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/535.1\ + \ (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1" + ip_address: 76.218.201.212 + location: "San Francisco, CA, United States" + ticket_id: 666 + via: + channel: web count: 1 next_page: null previous_page: null @@ -28588,70 +30766,70 @@ components: after_cursor: MTUwMTYwNzUyMi4wfHwxMzQ3NTMxNjcxfA== after_url: https://subdomain.zendesk.com/api/v2/ticket_audits.json?cursor=MTUwMTYwNzUyMi4wfHwxMzQ3NTMxNjcxfA%3D%3D&limit=1000 audits: - - author_id: 35436 - created_at: "2011-09-25T22:35:44Z" - events: - - attachments: [] - body: Thanks for your help! - id: 1564245 - public: true - type: Comment - - body: 'Ticket #47 has been updated' - id: 1564246 - subject: Your ticket has been updated - type: Notification - - field_name: status - id: 1564247 - previous_value: new - type: Change - value: open - - field_name: custom_status_id - id: 1564248 - previous_value: 1 - type: Change - value: 123 - id: 2127301143 - metadata: - custom: - time_spent: 3m22s - system: - ip_address: 184.106.40.75 - ticket_id: 123 - via: - channel: web + - author_id: 35436 + created_at: 2011-09-25T22:35:44Z + events: + - attachments: [] + body: Thanks for your help! + id: 1564245 + public: true + type: Comment + - body: "Ticket #47 has been updated" + id: 1564246 + subject: Your ticket has been updated + type: Notification + - field_name: status + id: 1564247 + previous_value: new + type: Change + value: open + - field_name: custom_status_id + id: 1564248 + previous_value: 1 + type: Change + value: 123 + id: 2127301143 + metadata: + custom: + time_spent: 3m22s + system: + ip_address: 184.106.40.75 + ticket_id: 123 + via: + channel: web before_cursor: fDE1MDE1NzUxMjIuMHx8MTM0NzM0MzAxMQ== before_url: https://subdomain.zendesk.com/api/v2/ticket_audits.json?cursor=fDE1MDE1NzUxMjIuMHx8MTM0NzM0MzAxMQ%3D%3D&limit=1000 TicketBulkImportRequestExample: value: tickets: - - assignee_id: 19 - comments: - - author_id: 827 - created_at: "2009-06-25T10:15:18Z" - value: This is a comment - - author_id: 19 - public: false - value: This is a private comment - description: A description - requester_id: 827 - subject: Help - tags: - - foo - - bar - - assignee_id: 21 - comments: - - author_id: 830 - created_at: "2009-06-25T10:15:18Z" - value: This is a comment - - author_id: 21 - public: false - value: This is a private comment - description: A description - requester_id: 830 - subject: Missing Item - tags: - - foo - - bar + - assignee_id: 19 + comments: + - author_id: 827 + created_at: 2009-06-25T10:15:18Z + value: This is a comment + - author_id: 19 + public: false + value: This is a private comment + description: A description + requester_id: 827 + subject: Help + tags: + - foo + - bar + - assignee_id: 21 + comments: + - author_id: 830 + created_at: 2009-06-25T10:15:18Z + value: This is a comment + - author_id: 21 + public: false + value: This is a private comment + description: A description + requester_id: 830 + subject: Missing Item + tags: + - foo + - bar TicketChatCommentAttachmentRedactionResponseExample: value: chat_event: @@ -28660,12 +30838,12 @@ components: value: chat_id: 2109.10502823.Sjuj2YrBpXwei history: - - chat_index: 0 - filename: redacted.txt - type: ChatFileAttachment - - chat_index: 1 - filename: redacted.txt - type: ChatFileAttachment + - chat_index: 0 + filename: redacted.txt + type: ChatFileAttachment + - chat_index: 1 + filename: redacted.txt + type: ChatFileAttachment visitor_id: 10502823-16EkM3T6VNq7KMd TicketChatCommentRedactionResponseExample: value: @@ -28675,9 +30853,9 @@ components: value: chat_id: 2109.10502823.Sjuj2YrBpXwei history: - - chat_index: 0 - message: My ID number is ▇▇▇▇! - type: ChatMessage + - chat_index: 0 + message: My ID number is ▇▇▇▇! + type: ChatMessage visitor_id: 10502823-16EkM3T6VNq7KMd TicketCommentStringRedactResponseExample: value: @@ -28689,7 +30867,7 @@ components: TicketCommentsCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 12 TicketCommentsRedactionInAgentWorkspaceResponseExample: value: @@ -28703,33 +30881,34 @@ components: TicketCommentsResponseExample: value: comments: - - attachments: - - content_type: text/plain - content_url: https://company.zendesk.com/attachments/crash.log - file_name: crash.log - id: 498483 - size: 2532 - thumbnails: [] - audit_id: 432567 - author_id: 123123 - body: Thanks for your help! - created_at: "2009-07-20T22:55:29Z" - id: 1274 - metadata: - system: - client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36 - ip_address: 1.1.1.1 - latitude: -37.000000000001 - location: Melbourne, 07, Australia - longitude: 144.0000000000002 - via: - channel: web - source: - from: {} - rel: web_widget - to: {} - public: true - type: Comment + - attachments: + - content_type: text/plain + content_url: https://company.zendesk.com/attachments/crash.log + file_name: crash.log + id: 498483 + size: 2532 + thumbnails: [] + audit_id: 432567 + author_id: 123123 + body: Thanks for your help! + created_at: 2009-07-20T22:55:29Z + id: 1274 + metadata: + system: + client: "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36\ + \ (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36" + ip_address: 1.1.1.1 + latitude: -37.000000000001 + location: "Melbourne, 07, Australia" + longitude: 144.0000000000002 + via: + channel: web + source: + from: {} + rel: web_widget + to: {} + public: true + type: Comment TicketCreateRequestExample: value: ticket: @@ -28749,15 +30928,15 @@ components: answered_by_id: 28 call_duration: 40 from: "+16617480240" - location: Dublin, Ireland + location: "Dublin, Ireland" recording_url: http://yourdomain.com/recordings/1.mp3 - started_at: "2019-04-16T09:14:57Z" + started_at: 2019-04-16T09:14:57Z to: "+16617480123" transcription_text: The transcription of the call TicketFieldCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 TicketFieldResponseExample: value: @@ -28765,7 +30944,7 @@ components: active: true agent_description: Agent only description collapsed_for_agents: false - created_at: "2012-04-02T22:55:29Z" + created_at: 2012-04-02T22:55:29Z description: Age editable_in_portal: false id: 89 @@ -28780,7 +30959,7 @@ components: title: Age title_in_portal: Age type: text - updated_at: "2012-04-02T22:55:29Z" + updated_at: 2012-04-02T22:55:29Z url: https://company.zendesk.com/api/v2/ticket_fields/89.json visible_in_portal: false TicketFieldUpdateResponseExample: @@ -28789,7 +30968,7 @@ components: active: true agent_description: Agent only description collapsed_for_agents: false - created_at: "2012-04-02T22:55:29Z" + created_at: 2012-04-02T22:55:29Z description: Your age editable_in_portal: false id: 89 @@ -28804,81 +30983,81 @@ components: title: Your age title_in_portal: Your age type: text - updated_at: "2012-04-02T23:11:23Z" + updated_at: 2012-04-02T23:11:23Z url: https://company.zendesk.com/api/v2/ticket_fields/89.json visible_in_portal: false TicketFieldsResponseExample: value: ticket_fields: - - active: true - agent_description: Agent only description - collapsed_for_agents: false - created_at: "2009-07-20T22:55:29Z" - description: This is the subject field of a ticket - editable_in_portal: true - id: 34 - position: 21 - raw_description: This is the subject field of a ticket - raw_title: '{{dc.my_title}}' - raw_title_in_portal: '{{dc.my_title_in_portal}}' - regexp_for_validation: null - required: true - required_in_portal: true - tag: null - title: Subject - title_in_portal: Subject - type: subject - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/ticket_fields/34.json - visible_in_portal: true + - active: true + agent_description: Agent only description + collapsed_for_agents: false + created_at: 2009-07-20T22:55:29Z + description: This is the subject field of a ticket + editable_in_portal: true + id: 34 + position: 21 + raw_description: This is the subject field of a ticket + raw_title: "{{dc.my_title}}" + raw_title_in_portal: "{{dc.my_title_in_portal}}" + regexp_for_validation: null + required: true + required_in_portal: true + tag: null + title: Subject + title_in_portal: Subject + type: subject + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/ticket_fields/34.json + visible_in_portal: true TicketFormCreateResponseExample: value: ticket_form: active: true agent_conditions: - - child_fields: - - id: 44 - is_required: false - required_on_statuses: - statuses: - - new - - open - - pending - - hold - type: SOME_STATUSES - - id: 32 - is_required: true - required_on_statuses: - statuses: - - solved - type: SOME_STATUSES - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: true - required_on_statuses: - type: ALL_STATUSES - - id: 32 - is_required: false - required_on_statuses: - type: NO_STATUSES - parent_field_id: 32 - value: matching_value_2 - created_at: "2012-04-02T22:55:29Z" + - child_fields: + - id: 44 + is_required: false + required_on_statuses: + statuses: + - new + - open + - pending + - hold + type: SOME_STATUSES + - id: 32 + is_required: true + required_on_statuses: + statuses: + - solved + type: SOME_STATUSES + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: true + required_on_statuses: + type: ALL_STATUSES + - id: 32 + is_required: false + required_on_statuses: + type: NO_STATUSES + parent_field_id: 32 + value: matching_value_2 + created_at: 2012-04-02T22:55:29Z default: false display_name: Snowboard Damage end_user_conditions: - - child_fields: - - id: 32 - is_required: true - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: false - parent_field_id: 32 - value: matching_value_2 + - child_fields: + - id: 32 + is_required: true + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: false + parent_field_id: 32 + value: matching_value_2 end_user_visible: true id: 47 in_all_brands: false @@ -28887,345 +31066,345 @@ components: raw_display_name: Snowboard Damage raw_name: Snowboard Problem restricted_brand_ids: - - 1 - - 4 - - 6 - - 12 - - 34 + - 1 + - 4 + - 6 + - 12 + - 34 ticket_field_ids: - - 2 - - 4 - - 5 - - 32 - - 44 - updated_at: "2012-04-02T22:55:29Z" + - 2 + - 4 + - 5 + - 32 + - 44 + updated_at: 2012-04-02T22:55:29Z url: https://company.zendesk.com/api/v2/ticket_forms/47.json TicketFormResponseExample: value: ticket_form: active: true agent_conditions: - - child_fields: - - id: 44 - is_required: false - required_on_statuses: - statuses: - - new - - open - - pending - - hold - type: SOME_STATUSES - - id: 32 - is_required: true - required_on_statuses: - statuses: - - solved - type: SOME_STATUSES - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: true - required_on_statuses: - type: ALL_STATUSES - - id: 32 - is_required: false - required_on_statuses: - type: NO_STATUSES - parent_field_id: 32 - value: matching_value_2 - created_at: "2012-04-02T22:55:29Z" + - child_fields: + - id: 44 + is_required: false + required_on_statuses: + statuses: + - new + - open + - pending + - hold + type: SOME_STATUSES + - id: 32 + is_required: true + required_on_statuses: + statuses: + - solved + type: SOME_STATUSES + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: true + required_on_statuses: + type: ALL_STATUSES + - id: 32 + is_required: false + required_on_statuses: + type: NO_STATUSES + parent_field_id: 32 + value: matching_value_2 + created_at: 2012-04-02T22:55:29Z default: true display_name: Snowboard Damage end_user_conditions: - - child_fields: - - id: 32 - is_required: true - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: false - parent_field_id: 32 - value: matching_value_2 + - child_fields: + - id: 32 + is_required: true + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: false + parent_field_id: 32 + value: matching_value_2 end_user_visible: true id: 47 in_all_brands: false name: Snowboard Problem position: 9999 - raw_display_name: '{{dc.my_display_name}}' + raw_display_name: "{{dc.my_display_name}}" raw_name: Snowboard Problem restricted_brand_ids: - - 1 - - 4 - - 6 - - 12 - - 34 + - 1 + - 4 + - 6 + - 12 + - 34 ticket_field_ids: - - 2 - - 4 - - 5 - - 32 - - 44 - updated_at: "2012-04-02T22:55:29Z" + - 2 + - 4 + - 5 + - 32 + - 44 + updated_at: 2012-04-02T22:55:29Z url: https://company.zendesk.com/api/v2/ticket_forms/47.json TicketFormUpdateResponseExample: value: ticket_form: active: true agent_conditions: [] - created_at: "2012-04-02T22:55:29Z" + created_at: 2012-04-02T22:55:29Z default: true display_name: Snowboard has been fixed end_user_conditions: [] end_user_visible: true id: 47 - in_all_brands: true - name: Snowboard Fixed + in_all_brands: true + name: Snowboard Fixed + position: 9999 + raw_display_name: Snowboard has been fixed + raw_name: Snowboard Fixed + restricted_brand_ids: [] + ticket_field_ids: + - 2 + - 4 + - 5 + - 32 + - 44 + updated_at: 2012-04-02T22:55:29Z + url: https://company.zendesk.com/api/v2/ticket_forms/47.json + TicketFormsResponseExample: + value: + ticket_forms: + - active: true + agent_conditions: + - child_fields: + - id: 44 + is_required: false + required_on_statuses: + statuses: + - new + - open + - pending + - hold + type: SOME_STATUSES + - id: 32 + is_required: true + required_on_statuses: + statuses: + - solved + type: SOME_STATUSES + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: true + required_on_statuses: + type: ALL_STATUSES + - id: 32 + is_required: false + required_on_statuses: + type: NO_STATUSES + parent_field_id: 32 + value: matching_value_2 + created_at: 2012-04-02T22:55:29Z + default: true + display_name: Snowboard Damage + end_user_conditions: + - child_fields: + - id: 32 + is_required: true + parent_field_id: 5 + value: matching_value_1 + - child_fields: + - id: 44 + is_required: false + parent_field_id: 32 + value: matching_value_2 + end_user_visible: true + id: 47 + in_all_brands: false + name: Snowboard Problem position: 9999 - raw_display_name: Snowboard has been fixed - raw_name: Snowboard Fixed - restricted_brand_ids: [] + raw_display_name: "{{dc.my_display_name}}" + raw_name: Snowboard Problem + restricted_brand_ids: + - 1 + - 4 + - 6 + - 12 + - 34 ticket_field_ids: - - 2 - - 4 - - 5 - - 32 - - 44 - updated_at: "2012-04-02T22:55:29Z" + - 2 + - 4 + - 5 + - 32 + - 44 + updated_at: 2012-04-02T22:55:29Z url: https://company.zendesk.com/api/v2/ticket_forms/47.json - TicketFormsResponseExample: - value: - ticket_forms: - - active: true - agent_conditions: - - child_fields: - - id: 44 - is_required: false - required_on_statuses: - statuses: - - new - - open - - pending - - hold - type: SOME_STATUSES - - id: 32 - is_required: true - required_on_statuses: - statuses: - - solved - type: SOME_STATUSES - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: true - required_on_statuses: - type: ALL_STATUSES - - id: 32 - is_required: false - required_on_statuses: - type: NO_STATUSES - parent_field_id: 32 - value: matching_value_2 - created_at: "2012-04-02T22:55:29Z" - default: true - display_name: Snowboard Damage - end_user_conditions: - - child_fields: - - id: 32 - is_required: true - parent_field_id: 5 - value: matching_value_1 - - child_fields: - - id: 44 - is_required: false - parent_field_id: 32 - value: matching_value_2 - end_user_visible: true - id: 47 - in_all_brands: false - name: Snowboard Problem - position: 9999 - raw_display_name: '{{dc.my_display_name}}' - raw_name: Snowboard Problem - restricted_brand_ids: - - 1 - - 4 - - 6 - - 12 - - 34 - ticket_field_ids: - - 2 - - 4 - - 5 - - 32 - - 44 - updated_at: "2012-04-02T22:55:29Z" - url: https://company.zendesk.com/api/v2/ticket_forms/47.json TicketImportRequestExample: value: ticket: assignee_id: 19 comments: - - author_id: 827 - created_at: "2009-06-25T10:15:18Z" - value: This is a comment - - author_id: 19 - public: false - value: This is a private comment + - author_id: 827 + created_at: 2009-06-25T10:15:18Z + value: This is a comment + - author_id: 19 + public: false + value: This is a private comment description: A description requester_id: 827 subject: Help tags: - - foo - - bar + - foo + - bar TicketMergeInputExample: value: ids: - - 123 - - 456 - - 789 - source_comment: 'Closing in favor of #111' - target_comment: 'Combining with #123, #456, #789' + - 123 + - 456 + - 789 + source_comment: "Closing in favor of #111" + target_comment: "Combining with #123, #456, #789" TicketMetricEventsResponseExample: value: count: 3 end_time: 1603716792 next_page: https://company.zendesk.com/api/v2/incremental/ticket_metric_events.json?start_time=1603716792 ticket_metric_events: - - id: 926232157301 - instance_id: 0 - metric: agent_work_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: measure - - id: 926232757371 - instance_id: 1 - metric: agent_work_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: activate - - id: 926232927415 - instance_id: 0 - metric: pausable_update_time - ticket_id: 155 - time: "2020-10-26T12:53:12Z" - type: measure + - id: 926232157301 + instance_id: 0 + metric: agent_work_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: measure + - id: 926232757371 + instance_id: 1 + metric: agent_work_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: activate + - id: 926232927415 + instance_id: 0 + metric: pausable_update_time + ticket_id: 155 + time: 2020-10-26T12:53:12Z + type: measure TicketMetricResponseExample: value: ticket_metric: - - agent_wait_time_in_minutes: - business: 0 - calendar: 0 - assigned_at: "2020-07-20T06:21:26Z" - assignee_stations: 0 - assignee_updated_at: "2020-07-20T06:21:26Z" - created_at: "2020-07-21T01:01:42Z" - first_resolution_time_in_minutes: - business: 0 - calendar: 0 - full_resolution_time_in_minutes: - business: 0 - calendar: 0 - group_stations: 0 - id: 33 - initially_assigned_at: "2020-07-20T06:21:26Z" - latest_comment_added_at: "2020-07-21T01:17:16Z" - on_hold_time_in_minutes: - business: 0 - calendar: 0 - reopens: 0 - replies: 1 - reply_time_in_minutes: - business: 16 - calendar: 16 - reply_time_in_seconds: - calendar: 960 - requester_updated_at: "2020-07-21T01:17:16Z" - requester_wait_time_in_minutes: - business: 0 - calendar: 0 - solved_at: "2020-07-20T06:21:26Z" - status_updated_at: "2020-07-21T01:01:41Z" - ticket_id: 1517 - updated_at: "2020-07-21T01:17:16Z" - url: https://example.zendesk.com/api/v2/ticket_metrics/33.json + - agent_wait_time_in_minutes: + business: 0 + calendar: 0 + assigned_at: 2020-07-20T06:21:26Z + assignee_stations: 0 + assignee_updated_at: 2020-07-20T06:21:26Z + created_at: 2020-07-21T01:01:42Z + first_resolution_time_in_minutes: + business: 0 + calendar: 0 + full_resolution_time_in_minutes: + business: 0 + calendar: 0 + group_stations: 0 + id: 33 + initially_assigned_at: 2020-07-20T06:21:26Z + latest_comment_added_at: 2020-07-21T01:17:16Z + on_hold_time_in_minutes: + business: 0 + calendar: 0 + reopens: 0 + replies: 1 + reply_time_in_minutes: + business: 16 + calendar: 16 + reply_time_in_seconds: + calendar: 960 + requester_updated_at: 2020-07-21T01:17:16Z + requester_wait_time_in_minutes: + business: 0 + calendar: 0 + solved_at: 2020-07-20T06:21:26Z + status_updated_at: 2020-07-21T01:01:41Z + ticket_id: 1517 + updated_at: 2020-07-21T01:17:16Z + url: https://example.zendesk.com/api/v2/ticket_metrics/33.json TicketMetricsResponseExample: value: ticket_metrics: - - agent_wait_time_in_minutes: - business: 0 - calendar: 0 - assigned_at: "2020-07-20T06:21:26Z" - assignee_stations: 0 - assignee_updated_at: "2020-07-20T06:21:26Z" - created_at: "2020-07-21T01:01:42Z" - first_resolution_time_in_minutes: - business: 0 - calendar: 0 - full_resolution_time_in_minutes: - business: 0 - calendar: 0 - group_stations: 0 - id: 33 - initially_assigned_at: "2020-07-20T06:21:26Z" - latest_comment_added_at: "2020-07-21T01:17:16Z" - on_hold_time_in_minutes: - business: 0 - calendar: 0 - reopens: 0 - replies: 1 - reply_time_in_minutes: - business: 16 - calendar: 16 - reply_time_in_seconds: - calendar: 960 - requester_updated_at: "2020-07-21T01:17:16Z" - requester_wait_time_in_minutes: - business: 0 - calendar: 0 - solved_at: "2020-07-20T06:21:26Z" - status_updated_at: "2020-07-21T01:01:41Z" - ticket_id: 1517 - updated_at: "2020-07-21T01:17:16Z" - url: https://example.zendesk.com/api/v2/ticket_metrics/33.json - - agent_wait_time_in_minutes: - business: 0 - calendar: 0 - assigned_at: "2020-07-20T06:21:26Z" - assignee_stations: 0 - assignee_updated_at: "2020-07-20T06:21:26Z" - created_at: "2020-07-20T06:21:27Z" - first_resolution_time_in_minutes: - business: 0 - calendar: 0 - full_resolution_time_in_minutes: - business: 0 - calendar: 0 - group_stations: 0 - id: 34 - initially_assigned_at: "2020-07-20T06:21:26Z" - latest_comment_added_at: "2020-07-20T06:21:26Z" - on_hold_time_in_minutes: - business: 0 - calendar: 0 - reopens: 0 - replies: 0 - reply_time_in_minutes: - business: 0 - calendar: 0 - reply_time_in_seconds: - calendar: 0 - requester_updated_at: "2020-07-20T06:21:26Z" - requester_wait_time_in_minutes: - business: 0 - calendar: 0 - solved_at: "2020-07-20T06:21:26Z" - status_updated_at: "2020-07-20T06:21:26Z" - ticket_id: 1511 - updated_at: "2020-07-20T06:21:27Z" - url: https://example.zendesk.com/api/v2/ticket_metrics/34.json + - agent_wait_time_in_minutes: + business: 0 + calendar: 0 + assigned_at: 2020-07-20T06:21:26Z + assignee_stations: 0 + assignee_updated_at: 2020-07-20T06:21:26Z + created_at: 2020-07-21T01:01:42Z + first_resolution_time_in_minutes: + business: 0 + calendar: 0 + full_resolution_time_in_minutes: + business: 0 + calendar: 0 + group_stations: 0 + id: 33 + initially_assigned_at: 2020-07-20T06:21:26Z + latest_comment_added_at: 2020-07-21T01:17:16Z + on_hold_time_in_minutes: + business: 0 + calendar: 0 + reopens: 0 + replies: 1 + reply_time_in_minutes: + business: 16 + calendar: 16 + reply_time_in_seconds: + calendar: 960 + requester_updated_at: 2020-07-21T01:17:16Z + requester_wait_time_in_minutes: + business: 0 + calendar: 0 + solved_at: 2020-07-20T06:21:26Z + status_updated_at: 2020-07-21T01:01:41Z + ticket_id: 1517 + updated_at: 2020-07-21T01:17:16Z + url: https://example.zendesk.com/api/v2/ticket_metrics/33.json + - agent_wait_time_in_minutes: + business: 0 + calendar: 0 + assigned_at: 2020-07-20T06:21:26Z + assignee_stations: 0 + assignee_updated_at: 2020-07-20T06:21:26Z + created_at: 2020-07-20T06:21:27Z + first_resolution_time_in_minutes: + business: 0 + calendar: 0 + full_resolution_time_in_minutes: + business: 0 + calendar: 0 + group_stations: 0 + id: 34 + initially_assigned_at: 2020-07-20T06:21:26Z + latest_comment_added_at: 2020-07-20T06:21:26Z + on_hold_time_in_minutes: + business: 0 + calendar: 0 + reopens: 0 + replies: 0 + reply_time_in_minutes: + business: 0 + calendar: 0 + reply_time_in_seconds: + calendar: 0 + requester_updated_at: 2020-07-20T06:21:26Z + requester_wait_time_in_minutes: + business: 0 + calendar: 0 + solved_at: 2020-07-20T06:21:26Z + status_updated_at: 2020-07-20T06:21:26Z + ticket_id: 1511 + updated_at: 2020-07-20T06:21:27Z + url: https://example.zendesk.com/api/v2/ticket_metrics/34.json TicketRelatedInformationExample: value: followup_source_ids: [] @@ -29243,21 +31422,21 @@ components: ticket: assignee_id: 235323 collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" + - id: 27642 + value: "745" + - id: 27648 + value: "yes" custom_status_id: 123 description: The fire is very colorful. due_at: null external_id: ahg35h3jh follower_ids: - - 35334 - - 234 + - 35334 + - 234 from_messaging_channel: false group_id: 98738 has_incidents: false @@ -29265,7 +31444,7 @@ components: organization_id: 509974 priority: high problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' + raw_subject: "{{dc.printer_on_fire}}" recipient: support@company.com requester_id: 20978392 satisfaction_rating: @@ -29273,41 +31452,41 @@ components: id: 1234 score: good sharing_agreement_ids: - - 84432 + - 84432 status: open - subject: Help, my printer is on fire! + subject: "Help, my printer is on fire!" submitter_id: 76872 tags: - - enterprise - - other_tag + - enterprise + - other_tag type: incident - updated_at: "2011-05-05T10:38:52Z" + updated_at: 2011-05-05T10:38:52Z url: https://company.zendesk.com/api/v2/tickets/35436.json via: channel: web TicketSkipCreationExample: value: skip: - created_at: "2015-09-30T21:44:03Z" + created_at: 2015-09-30T21:44:03Z id: 1 reason: I have no idea. ticket: assignee_id: 235323 collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" + - id: 27642 + value: "745" + - id: 27648 + value: "yes" description: The fire is very colorful. due_at: null external_id: ahg35h3jh follower_ids: - - 35334 - - 234 + - 35334 + - 234 from_messaging_channel: false group_id: 98738 has_incidents: false @@ -29315,7 +31494,7 @@ components: organization_id: 509974 priority: high problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' + raw_subject: "{{dc.printer_on_fire}}" recipient: support@company.com requester_id: 20978392 satisfaction_rating: @@ -29323,196 +31502,52 @@ components: id: 1234 score: good sharing_agreement_ids: - - 84432 + - 84432 status: open - subject: Help, my printer is on fire! + subject: "Help, my printer is on fire!" submitter_id: 76872 tags: - - enterprise - - other_tag + - enterprise + - other_tag type: incident - updated_at: "2011-05-05T10:38:52Z" + updated_at: 2011-05-05T10:38:52Z url: https://company.zendesk.com/api/v2/tickets/35436.json via: channel: web ticket_id: 123 - updated_at: "2015-09-30T21:44:03Z" + updated_at: 2015-09-30T21:44:03Z user_id: 456 TicketSkipResponseExample: value: skips: - - created_at: "2015-09-30T21:44:03Z" - id: 1 - reason: I have no idea. - ticket: - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - from_messaging_channel: false - group_id: 98738 - has_incidents: false - id: 123 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - ticket_id: 123 - updated_at: "2015-09-30T21:44:03Z" - user_id: 456 - - created_at: "2015-10-01T21:44:03Z" - id: 2 - reason: I am lost. - ticket: - assignee_id: 235323 - collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" - custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - description: The fire is very colorful. - due_at: null - external_id: ahg35h3jh - follower_ids: - - 35334 - - 234 - from_messaging_channel: false - group_id: 98738 - has_incidents: false - id: 321 - organization_id: 509974 - priority: high - problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' - recipient: support@company.com - requester_id: 20978392 - satisfaction_rating: - comment: Great support! - id: 1234 - score: good - sharing_agreement_ids: - - 84432 - status: open - subject: Help, my printer is on fire! - submitter_id: 76872 - tags: - - enterprise - - other_tag - type: incident - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/tickets/35436.json - via: - channel: web - ticket_id: 321 - updated_at: "2015-10-01T21:44:03Z" - user_id: 654 - TicketUpdateRequestExample: - value: - ticket: - comment: - body: Thanks for choosing Acme Jet Motors. - public: true - custom_status_id: 321 - status: solved - TicketUpdateResponseExample: - value: - audit: - events: - - field_name: subject - id: 206091192546 - type: Create - value: My printer is on fire! - - body: The smoke is very colorful. - id: 206091192547 - type: Comment - - field_name: status - id: 206091192548 - type: Create - value: open - - field_name: custom_status_id - id: 206091192549 - type: Create - value: 123 - ticket: - custom_status_id: 123 - id: 35436 - requester_id: 123453 - status: open - subject: My printer is on fire! - TicketsCreateRequestExample: - value: - tickets: - - comment: - body: The smoke is very colorful. - priority: urgent - subject: My printer is on fire! - - comment: - body: This is a comment - priority: normal - subject: Help - TicketsResponseExample: - value: - tickets: - - assignee_id: 235323 + - created_at: 2015-09-30T21:44:03Z + id: 1 + reason: I have no idea. + ticket: + assignee_id: 235323 collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" - custom_status_id: 123 + - id: 27642 + value: "745" + - id: 27648 + value: "yes" description: The fire is very colorful. due_at: null external_id: ahg35h3jh follower_ids: - - 35334 - - 234 + - 35334 + - 234 from_messaging_channel: false group_id: 98738 has_incidents: false - id: 35436 + id: 123 organization_id: 509974 priority: high problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' + raw_subject: "{{dc.printer_on_fire}}" recipient: support@company.com requester_id: 20978392 satisfaction_rating: @@ -29520,49 +31555,49 @@ components: id: 1234 score: good sharing_agreement_ids: - - 84432 + - 84432 status: open - subject: Help, my printer is on fire! + subject: "Help, my printer is on fire!" submitter_id: 76872 tags: - - enterprise - - other_tag + - enterprise + - other_tag type: incident - updated_at: "2011-05-05T10:38:52Z" + updated_at: 2011-05-05T10:38:52Z url: https://company.zendesk.com/api/v2/tickets/35436.json via: channel: web - TimeBasedExportIncrementalTicketsResponseExample: - value: - count: 2 - end_of_stream: true - end_time: 1390362485 - next_page: https://{subdomain}.zendesk.com/api/v2/incremental/tickets.json?per_page=3&start_time=1390362485 - tickets: - - assignee_id: 235323 + ticket_id: 123 + updated_at: 2015-09-30T21:44:03Z + user_id: 456 + - created_at: 2015-10-01T21:44:03Z + id: 2 + reason: I am lost. + ticket: + assignee_id: 235323 collaborator_ids: - - 35334 - - 234 - created_at: "2009-07-20T22:55:29Z" + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z custom_fields: - - id: 27642 - value: "745" - - id: 27648 - value: "yes" + - id: 27642 + value: "745" + - id: 27648 + value: "yes" description: The fire is very colorful. due_at: null external_id: ahg35h3jh follower_ids: - - 35334 - - 234 + - 35334 + - 234 from_messaging_channel: false group_id: 98738 has_incidents: false - id: 35436 + id: 321 organization_id: 509974 priority: high problem_id: 9873764 - raw_subject: '{{dc.printer_on_fire}}' + raw_subject: "{{dc.printer_on_fire}}" recipient: support@company.com requester_id: 20978392 satisfaction_rating: @@ -29570,73 +31605,217 @@ components: id: 1234 score: good sharing_agreement_ids: - - 84432 + - 84432 status: open - subject: Help, my printer is on fire! + subject: "Help, my printer is on fire!" submitter_id: 76872 tags: - - enterprise - - other_tag + - enterprise + - other_tag type: incident - updated_at: "2011-05-05T10:38:52Z" + updated_at: 2011-05-05T10:38:52Z url: https://company.zendesk.com/api/v2/tickets/35436.json via: channel: web - TimeBasedExportIncrementalUsersResponseExample: + ticket_id: 321 + updated_at: 2015-10-01T21:44:03Z + user_id: 654 + TicketUpdateRequestExample: value: - count: 1 + ticket: + comment: + body: Thanks for choosing Acme Jet Motors. + public: true + custom_status_id: 321 + status: solved + TicketUpdateResponseExample: + value: + audit: + events: + - field_name: subject + id: 206091192546 + type: Create + value: My printer is on fire! + - body: The smoke is very colorful. + id: 206091192547 + type: Comment + - field_name: status + id: 206091192548 + type: Create + value: open + - field_name: custom_status_id + id: 206091192549 + type: Create + value: 123 + ticket: + custom_status_id: 123 + id: 35436 + requester_id: 123453 + status: open + subject: My printer is on fire! + TicketsCreateRequestExample: + value: + tickets: + - comment: + body: The smoke is very colorful. + priority: urgent + subject: My printer is on fire! + - comment: + body: This is a comment + priority: normal + subject: Help + TicketsResponseExample: + value: + tickets: + - assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + custom_status_id: 123 + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + from_messaging_channel: false + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + TimeBasedExportIncrementalTicketsResponseExample: + value: + count: 2 end_of_stream: true - end_time: 1601357503 - next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 - users: - - active: true - alias: Mr. Johnny - created_at: "2009-07-20T22:55:29Z" - custom_role_id: 9373643 - details: "" - email: johnny@example.com - external_id: sai989sur98w9 - id: 35436 - last_login_at: "2011-05-05T10:38:52Z" - locale: en-US - locale_id: 1 - moderator: true - name: Johnny Agent - notes: Johnny is a nice guy! - only_private_comments: false - organization_id: 57542 - phone: "+15551234567" - photo: - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png - id: 928374 - name: my_funny_profile_pic.png - size: 166144 - thumbnails: - - content_type: image/png - content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png - id: 928375 - name: my_funny_profile_pic_thumb.png - size: 58298 - restricted_agent: true - role: agent - role_type: 0 - shared: false - shared_agent: false - signature: Have a nice day, Johnny - suspended: true - tags: - - enterprise - - other_tag - ticket_restriction: assigned - time_zone: Copenhagen - updated_at: "2011-05-05T10:38:52Z" - url: https://company.zendesk.com/api/v2/users/35436.json - user_fields: - user_date: "2012-07-23T00:00:00Z" - user_decimal: 5.1 - user_dropdown: option_1 - verified: true + end_time: 1390362485 + next_page: "https://{subdomain}.zendesk.com/api/v2/incremental/tickets.json?per_page=3&start_time=1390362485" + tickets: + - assignee_id: 235323 + collaborator_ids: + - 35334 + - 234 + created_at: 2009-07-20T22:55:29Z + custom_fields: + - id: 27642 + value: "745" + - id: 27648 + value: "yes" + description: The fire is very colorful. + due_at: null + external_id: ahg35h3jh + follower_ids: + - 35334 + - 234 + from_messaging_channel: false + group_id: 98738 + has_incidents: false + id: 35436 + organization_id: 509974 + priority: high + problem_id: 9873764 + raw_subject: "{{dc.printer_on_fire}}" + recipient: support@company.com + requester_id: 20978392 + satisfaction_rating: + comment: Great support! + id: 1234 + score: good + sharing_agreement_ids: + - 84432 + status: open + subject: "Help, my printer is on fire!" + submitter_id: 76872 + tags: + - enterprise + - other_tag + type: incident + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/tickets/35436.json + via: + channel: web + TimeBasedExportIncrementalUsersResponseExample: + value: + count: 1 + end_of_stream: true + end_time: 1601357503 + next_page: https://example.zendesk.com/api/v2/incremental/ticket_events.json?start_time=1601357503 + users: + - active: true + alias: Mr. Johnny + created_at: 2009-07-20T22:55:29Z + custom_role_id: 9373643 + details: "" + email: johnny@example.com + external_id: sai989sur98w9 + id: 35436 + last_login_at: 2011-05-05T10:38:52Z + locale: en-US + locale_id: 1 + moderator: true + name: Johnny Agent + notes: Johnny is a nice guy! + only_private_comments: false + organization_id: 57542 + phone: "+15551234567" + photo: + content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic.png + id: 928374 + name: my_funny_profile_pic.png + size: 166144 + thumbnails: + - content_type: image/png + content_url: https://company.zendesk.com/photos/my_funny_profile_pic_thumb.png + id: 928375 + name: my_funny_profile_pic_thumb.png + size: 58298 + restricted_agent: true + role: agent + role_type: 0 + shared: false + shared_agent: false + signature: "Have a nice day, Johnny" + suspended: true + tags: + - enterprise + - other_tag + ticket_restriction: assigned + time_zone: Copenhagen + updated_at: 2011-05-05T10:38:52Z + url: https://company.zendesk.com/api/v2/users/35436.json + user_fields: + user_date: 2012-07-23T00:00:00Z + user_decimal: 5.1 + user_dropdown: option_1 + verified: true TrialAccountResponseExample: value: account: @@ -29646,116 +31825,116 @@ components: TriggerBulkUpdateRequestExample: value: triggers: - - id: 25 - position: 5 - - active: false - id: 26 - - category_id: "10027" - id: 27 + - id: 25 + position: 5 + - active: false + id: 26 + - category_id: "10027" + id: 27 TriggerDefinitionResponseExample: value: definitions: actions: - - group: ticket - nullable: false - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: true - title: Open - value: open - - enabled: true - title: Pending - value: pending - - enabled: true - title: Solved - value: solved - - enabled: true - title: Closed - value: closed + - group: ticket + nullable: false + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: true + title: Open + value: open + - enabled: true + title: Pending + value: pending + - enabled: true + title: Solved + value: solved + - enabled: true + title: Closed + value: closed conditions_all: - - group: ticket - nullable: false - operators: - - terminal: false - title: Is - value: is - - terminal: false - title: Is not - value: is_not - - terminal: false - title: Less than - value: less_than - - terminal: false - title: Greater than - value: greater_than - - terminal: true - title: Changed - value: changed - - terminal: false - title: Changed to - value: value - - terminal: false - title: Changed from - value: value_previous - - terminal: true - title: Not changed - value: not_changed - - terminal: false - title: Not changed to - value: not_value - - terminal: false - title: Not changed from - value: not_value_previous - repeatable: false - subject: status - title: Status - type: list - values: - - enabled: true - title: New - value: new - - enabled: true - title: Open - value: open - - enabled: true - title: Pending - value: pending - - enabled: true - title: Solved - value: solved - - enabled: true - title: Closed - value: closed + - group: ticket + nullable: false + operators: + - terminal: false + title: Is + value: is + - terminal: false + title: Is not + value: is_not + - terminal: false + title: Less than + value: less_than + - terminal: false + title: Greater than + value: greater_than + - terminal: true + title: Changed + value: changed + - terminal: false + title: Changed to + value: value + - terminal: false + title: Changed from + value: value_previous + - terminal: true + title: Not changed + value: not_changed + - terminal: false + title: Not changed to + value: not_value + - terminal: false + title: Not changed from + value: not_value_previous + repeatable: false + subject: status + title: Status + type: list + values: + - enabled: true + title: New + value: new + - enabled: true + title: Open + value: open + - enabled: true + title: Pending + value: pending + - enabled: true + title: Solved + value: solved + - enabled: true + title: Closed + value: closed conditions_any: - - group: ticket - nullable: true - operators: - - terminal: true - title: Present - value: present - - terminal: true - title: Not present - value: not_present - repeatable: false - subject: custom_fields_20513432 - title: Happy Gilmore - type: list - - group: ticket - nullable: true - operators: - - terminal: true - title: Present - value: present - - terminal: true - title: Not present - value: not_present - repeatable: false - subject: custom_fields_86492341 - title: total_time_field - type: list + - group: ticket + nullable: true + operators: + - terminal: true + title: Present + value: present + - terminal: true + title: Not present + value: not_present + repeatable: false + subject: custom_fields_20513432 + title: Happy Gilmore + type: list + - group: ticket + nullable: true + operators: + - terminal: true + title: Present + value: present + - terminal: true + title: Not present + value: not_present + repeatable: false + subject: custom_fields_86492341 + title: total_time_field + type: list TriggerResponseExample: value: trigger: @@ -29763,86 +31942,86 @@ components: active: true category_id: "10026" conditions: {} - created_at: "2012-09-25T22:50:26Z" + created_at: 2012-09-25T22:50:26Z description: Close and save a ticket id: 25 position: 8 raw_title: Close and Save title: Close and Save - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/25.json + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/25.json" TriggerRevisionResponseExample: value: trigger_revision: author_id: 3343 - created_at: "2020-05-28T06:41:43Z" + created_at: 2020-05-28T06:41:43Z id: 1 snapshot: actions: - - field: notification_target - value: - - "510312" - - '{}' + - field: notification_target + value: + - "510312" + - "{}" active: true conditions: all: [] any: - - field: current_tags - operator: includes - value: fire_bulk_1 + - field: current_tags + operator: includes + value: fire_bulk_1 description: null title: bulk_test_trigger_1 url: https://example.zendesk.com/api/v2/triggers/261303831/revisions/1.json TriggerRevisionsResponseExample: value: after_cursor: MTUwMTYwNzUyMi4wfHwxMzQ3NTMxNjcxfA== - after_url: https://{subdomain}.zendesk.com/api/v2/triggers/{trigger_id}/revisions.json?cursor=MTUwMTYwNzUyMi4wfHwxMzQ3NTMxNjcxfA%3D%3D&limit=20 + after_url: "https://{subdomain}.zendesk.com/api/v2/triggers/{trigger_id}/revisions.json?cursor=MTUwMTYwNzUyMi4wfHwxMzQ3NTMxNjcxfA%3D%3D&limit=20" before_cursor: fDE1MDE1NzUxMjIuMHx8MTM0NzM0MzAxMQ== - before_url: https://{subdomain}.zendesk.com/api/v2/triggers/{trigger_id}/revisions.json?cursor=fDE1MDE1NzUxMjIuMHx8MTM0NzM0MzAxMQ%3D%3D&limit=20 + before_url: "https://{subdomain}.zendesk.com/api/v2/triggers/{trigger_id}/revisions.json?cursor=fDE1MDE1NzUxMjIuMHx8MTM0NzM0MzAxMQ%3D%3D&limit=20" count: 1 trigger_revisions: - - author_id: 2 - created_at: "2016-08-15T16:04:06Z" - diff: - actions: [] - active: [] - conditions: {} - description: [] - source_id: 1 - target_id: 2 - title: [] - id: 100 - snapshot: - actions: - - field: notification_target - value: - - "510312" - - '{}' - active: true - conditions: - all: [] - any: - - field: current_tags - operator: includes - value: fire_bulk_1 - description: Notifies requester that a comment was updated - title: Notify requester of comment update - url: https://{subdomain}.zendesk.com/api/v2/trigger/123/revisions/100.json + - author_id: 2 + created_at: 2016-08-15T16:04:06Z + diff: + actions: [] + active: [] + conditions: {} + description: [] + source_id: 1 + target_id: 2 + title: [] + id: 100 + snapshot: + actions: + - field: notification_target + value: + - "510312" + - "{}" + active: true + conditions: + all: [] + any: + - field: current_tags + operator: includes + value: fire_bulk_1 + description: Notifies requester that a comment was updated + title: Notify requester of comment update + url: "https://{subdomain}.zendesk.com/api/v2/trigger/123/revisions/100.json" TriggerWithCategoryRequestExample: value: trigger: actions: - - field: group_id - value: "20455932" + - field: group_id + value: "20455932" category_id: "10026" conditions: all: - - field: status - operator: is - value: open - - field: priority - operator: less_than - value: high + - field: status + operator: is + value: open + - field: priority + operator: less_than + value: high title: Roger Wilco TriggersActiveResponseExample: value: @@ -29850,153 +32029,153 @@ components: next_page: null previous_page: null triggers: - - actions: [] - active: true - conditions: {} - created_at: "2012-09-25T22:50:26Z" - description: Close and save a ticket - id: 25 - position: 8 - raw_title: Close and Save - title: Close and Save - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/25.json - - actions: [] - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: status - operator: less_than - value: solved - created_at: "2012-09-25T22:50:26Z" - description: Assign a ticket with a priority tag - id: 26 - position: 9 - raw_title: '{{dc.assign_priority_tag}}' - title: Assign priority tag - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/26.json + - actions: [] + active: true + conditions: {} + created_at: 2012-09-25T22:50:26Z + description: Close and save a ticket + id: 25 + position: 8 + raw_title: Close and Save + title: Close and Save + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/25.json" + - actions: [] + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: status + operator: less_than + value: solved + created_at: 2012-09-25T22:50:26Z + description: Assign a ticket with a priority tag + id: 26 + position: 9 + raw_title: "{{dc.assign_priority_tag}}" + title: Assign priority tag + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/26.json" TriggersResponseExample: value: count: 2 next_page: null previous_page: null triggers: - - actions: [] - active: true - conditions: {} - created_at: "2012-09-25T22:50:26Z" - description: Close and save a ticket - id: 25 - position: 8 - raw_title: Close and Save - title: Close and Save - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/25.json - - actions: [] - active: false - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: status - operator: less_than - value: solved - - field: custom_status_id - operator: includes - value: - - "1" - - "2" - created_at: "2012-09-25T22:50:26Z" - description: Assign a ticket with a priority tag - id: 26 - position: 9 - raw_title: '{{dc.assign_priority_tag}}' - title: Assign priority tag - updated_at: "2012-09-25T22:50:26Z" - url: http://{subdomain}.zendesk.com/api/v2/triggers/26.json + - actions: [] + active: true + conditions: {} + created_at: 2012-09-25T22:50:26Z + description: Close and save a ticket + id: 25 + position: 8 + raw_title: Close and Save + title: Close and Save + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/25.json" + - actions: [] + active: false + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: status + operator: less_than + value: solved + - field: custom_status_id + operator: includes + value: + - "1" + - "2" + created_at: 2012-09-25T22:50:26Z + description: Assign a ticket with a priority tag + id: 26 + position: 9 + raw_title: "{{dc.assign_priority_tag}}" + title: Assign priority tag + updated_at: 2012-09-25T22:50:26Z + url: "http://{subdomain}.zendesk.com/api/v2/triggers/26.json" TriggersSearchResponseExample: value: count: 2 next_page: null previous_page: null triggers: - - actions: [] - active: true - conditions: - all: - - field: status - operator: less_than - value: solved - - field: assignee_id - operator: is - value: "296220096" - any: - - field: status - operator: less_than - value: solved - created_at: "2012-09-25T22:50:26Z" - description: Close and save a ticket - id: 25 - position: 9 - raw_title: Close and Save - title: Close and Save - updated_at: "2012-09-25T22:50:26Z" - - actions: [] - active: true - conditions: {} - created_at: "2012-09-25T22:50:26Z" - id: 28 - position: 9 - raw_title: '{{dc.close_and_redirect}}' - title: Close and redirect to topics - updated_at: "2012-09-25T22:50:26Z" + - actions: [] + active: true + conditions: + all: + - field: status + operator: less_than + value: solved + - field: assignee_id + operator: is + value: "296220096" + any: + - field: status + operator: less_than + value: solved + created_at: 2012-09-25T22:50:26Z + description: Close and save a ticket + id: 25 + position: 9 + raw_title: Close and Save + title: Close and Save + updated_at: 2012-09-25T22:50:26Z + - actions: [] + active: true + conditions: {} + created_at: 2012-09-25T22:50:26Z + id: 28 + position: 9 + raw_title: "{{dc.close_and_redirect}}" + title: Close and redirect to topics + updated_at: 2012-09-25T22:50:26Z TwitterChannelResponseExample: value: monitored_twitter_handle: - created_at: "2010-05-13T22:07:08Z" + created_at: 2010-05-13T22:07:08Z id: 431 screen_name: '@zendeskops' twitter_user_id: 67923318930 - updated_at: "2011-07-22T00:15:19Z" + updated_at: 2011-07-22T00:15:19Z TwitterChannelTwicketStatusResponseExample: value: statuses: - - favorited: true - id: 834 - retweeted: false - user_followed: true + - favorited: true + id: 834 + retweeted: false + user_followed: true TwitterChannelsResponseExample: value: monitored_twitter_handles: - - created_at: "2009-05-13T00:07:08Z" - id: 211 - screen_name: '@zendesk' - twitter_user_id: 67462376832 - updated_at: "2011-07-22T00:11:12Z" - - created_at: "2010-05-13T22:07:08Z" - id: 431 - screen_name: '@zendeskops' - twitter_user_id: 67923318930 - updated_at: "2011-07-22T00:15:19Z" + - created_at: 2009-05-13T00:07:08Z + id: 211 + screen_name: '@zendesk' + twitter_user_id: 67462376832 + updated_at: 2011-07-22T00:11:12Z + - created_at: 2010-05-13T22:07:08Z + id: 431 + screen_name: '@zendeskops' + twitter_user_id: 67923318930 + updated_at: 2011-07-22T00:15:19Z UpdateMacroResponseExample: value: macro: actions: - - field: status - value: solved + - field: status + value: solved active: true description: Sets the ticket status to `solved` id: 25 @@ -30010,25 +32189,25 @@ components: UpdateOrganizationResponseExample: value: organization: - created_at: "2018-11-14T00:14:52Z" + created_at: 2018-11-14T00:14:52Z details: caterpillar =) domain_names: - - remain.com + - remain.com external_id: null group_id: 1835962 id: 4112492 name: Groablet Enterprises notes: Something Interesting organization_fields: - datepudding: "2018-11-04T00:00:00+00:00" + datepudding: 2018-11-04T00:00:00+00:00 org_field_1: happy happy org_field_2: teapot_kettle shared_comments: false shared_tickets: false tags: - - smiley - - teapot_kettle - updated_at: "2018-11-14T00:54:22Z" + - smiley + - teapot_kettle + updated_at: 2018-11-14T00:54:22Z url: https://example.zendesk.com/api/v2/organizations/4112492.json UpdateUserRequestExample: value: @@ -30042,7 +32221,7 @@ components: UserCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 102 UserCreateResponseExample: value: @@ -30058,7 +32237,7 @@ components: value: user_field: active: true - created_at: "2013-02-27T20:35:55Z" + created_at: 2013-02-27T20:35:55Z description: This field describes the support plan this user has id: 75 key: support_description @@ -30068,29 +32247,29 @@ components: regexp_for_validation: null title: Support description type: text - updated_at: "2013-02-27T20:35:55Z" + updated_at: 2013-02-27T20:35:55Z url: https://company.zendesk.com/api/v2/user_fields/75.json UserFieldResponseExample: value: user_field: active: true - created_at: "2012-10-16T16:04:06Z" + created_at: 2012-10-16T16:04:06Z description: Description of Custom Field id: 7 key: custom_field_1 position: 9999 - raw_description: '{{dc.my_description}}' + raw_description: "{{dc.my_description}}" raw_title: Custom Field 1 regexp_for_validation: null title: Custom Field 1 type: text - updated_at: "2012-10-16T16:04:06Z" + updated_at: 2012-10-16T16:04:06Z url: https://company.zendesk.com/api/v2/user_fields/7.json UserFieldUpdateResponseExample: value: user_field: active: true - created_at: "2013-02-27T20:35:55Z" + created_at: 2013-02-27T20:35:55Z description: This field describes the support plan this user has id: 75 key: support_description @@ -30100,7 +32279,7 @@ components: regexp_for_validation: null title: Support description type: text - updated_at: "2013-02-27T20:35:55Z" + updated_at: 2013-02-27T20:35:55Z url: https://company.zendesk.com/api/v2/user_fields/75.json UserFieldsResponseExample: value: @@ -30108,85 +32287,85 @@ components: next_page: null previous_page: null user_fields: - - active: true - created_at: "2012-10-16T16:04:06Z" - description: Description of Custom Field - id: 7 - key: custom_field_1 - position: 9999 - raw_description: '{{dc.my_description}}' - raw_title: Custom Field 1 - regexp_for_validation: null - title: Custom Field 1 - type: text - updated_at: "2012-10-16T16:04:06Z" - url: https://company.zendesk.com/api/v2/user_fields/7.json + - active: true + created_at: 2012-10-16T16:04:06Z + description: Description of Custom Field + id: 7 + key: custom_field_1 + position: 9999 + raw_description: "{{dc.my_description}}" + raw_title: Custom Field 1 + regexp_for_validation: null + title: Custom Field 1 + type: text + updated_at: 2012-10-16T16:04:06Z + url: https://company.zendesk.com/api/v2/user_fields/7.json UserIdentitiesResponseExample: value: identities: - - created_at: "2011-07-20T22:55:29Z" - id: 35436 - primary: true - type: email - updated_at: "2011-07-20T22:55:29Z" - user_id: 135 - value: someone@example.com - verified: true - - created_at: "2012-02-12T14:25:21Z" - id: 77136 - primary: false - type: twitter - updated_at: "2012-02-12T14:25:21Z" - user_id: 135 - value: didgeridooboy - verified: true - - created_at: "2012-02-12T14:25:21Z" - id: 88136 - primary: true - type: phone_number - updated_at: "2012-02-12T14:25:21Z" - user_id: 135 - value: +1 555-123-4567 - verified: true + - created_at: 2011-07-20T22:55:29Z + id: 35436 + primary: true + type: email + updated_at: 2011-07-20T22:55:29Z + user_id: 135 + value: someone@example.com + verified: true + - created_at: 2012-02-12T14:25:21Z + id: 77136 + primary: false + type: twitter + updated_at: 2012-02-12T14:25:21Z + user_id: 135 + value: didgeridooboy + verified: true + - created_at: 2012-02-12T14:25:21Z + id: 88136 + primary: true + type: phone_number + updated_at: 2012-02-12T14:25:21Z + user_id: 135 + value: +1 555-123-4567 + verified: true UserIdentityCreateResponseExample: value: identity: - created_at: "2012-02-12T14:25:21Z" + created_at: 2012-02-12T14:25:21Z id: 77938 primary: false type: twitter - updated_at: "2012-02-12T14:25:21Z" + updated_at: 2012-02-12T14:25:21Z user_id: 13531 value: cabanaboy verified: false UserIdentityResponseExample: value: identity: - created_at: "2012-02-12T14:25:21Z" + created_at: 2012-02-12T14:25:21Z id: 77938 primary: false type: twitter - updated_at: "2012-02-12T14:25:21Z" + updated_at: 2012-02-12T14:25:21Z user_id: 13531 value: cabanaboy verified: false UserIdentityUpdateResponseExample: value: identity: - created_at: "2011-07-20T22:55:29Z" + created_at: 2011-07-20T22:55:29Z deliverable_state: deliverable id: 35436 primary: true type: email - updated_at: "2011-07-20T22:55:29Z" + updated_at: 2011-07-20T22:55:29Z user_id: 135 value: someone@example.com verified: true UserPasswordRequirementsResponseExample: value: requirements: - - must be at least 5 characters - - must be different from email address + - must be at least 5 characters + - must be different from email address UserRelatedResponseExample: value: user_related: @@ -30200,10 +32379,10 @@ components: custom_role_id: 123456 email: roge@example.org identities: - - type: email - value: test@user.com - - type: twitter - value: tester84 + - type: email + value: test@user.com + - type: twitter + value: tester84 name: Roger Wilco organization: name: VIP Customers @@ -30216,89 +32395,89 @@ components: UsersCreateManyRequestExample: value: users: - - email: roge@example.org - name: Roger Wilco - organization_id: 567812345 - role: agent - - email: woge@example.org - name: Woger Rilco - role: admin + - email: roge@example.org + name: Roger Wilco + organization_id: 567812345 + role: agent + - email: woge@example.org + name: Woger Rilco + role: admin UsersRequestExample: value: users: - - custom_role_id: 123456 - email: roge@example.org - identities: - - type: email - value: test@user.com - - type: twitter - value: tester84 - name: Roger Wilco - organization: - name: VIP Customers - role: agent - - email: woge@example.org - external_id: account_54321 - name: Woger Rilco - role: admin + - custom_role_id: 123456 + email: roge@example.org + identities: + - type: email + value: test@user.com + - type: twitter + value: tester84 + name: Roger Wilco + organization: + name: VIP Customers + role: agent + - email: woge@example.org + external_id: account_54321 + name: Woger Rilco + role: admin UsersResponseExample: value: users: - - id: 223443 - name: Johnny Agent - - id: 8678530 - name: James A. Rosen + - id: 223443 + name: Johnny Agent + - id: 8678530 + name: James A. Rosen ViewCountResponseExample: value: view_count: fresh: true - pretty: ~700 + pretty: "~700" url: https://company.zendesk.com/api/v2/views/25/count.json value: 719 view_id: 25 ViewCountsResponseExample: value: view_counts: - - fresh: true - pretty: ~700 - url: https://company.zendesk.com/api/v2/views/25/count.json - value: 719 - view_id: 25 - - fresh: false - pretty: '...' - url: https://company.zendesk.com/api/v2/views/78/count.json - value: null - view_id: 78 + - fresh: true + pretty: "~700" + url: https://company.zendesk.com/api/v2/views/25/count.json + value: 719 + view_id: 25 + - fresh: false + pretty: '...' + url: https://company.zendesk.com/api/v2/views/78/count.json + value: null + view_id: 78 ViewCreateResponseExample: value: view: active: true conditions: all: - - field: status - operator: is - value: open - - field: priority - operator: less_than - value: high + - field: status + operator: is + value: open + - field: priority + operator: less_than + value: high any: - - field: current_tags - operator: includes - value: hello + - field: current_tags + operator: includes + value: hello id: 9873843 title: Roger Wilco ViewExecuteResponseExample: value: columns: - - id: locale - title: Locale - - id: 5 - title: Account + - id: locale + title: Locale + - id: 5 + title: Account groups: [] rows: - - group: 1 - locale: en-US - ticket: {} + - group: 1 + locale: en-US + ticket: {} view: id: 25 ViewExportResponseExample: @@ -30309,20 +32488,20 @@ components: ViewListTicketsResponseEXample: value: tickets: - - id: 35436 - requester_id: 20978392 - subject: Help I need somebody! - - id: 20057623 - requester_id: 20978392 - subject: Not just anybody! + - id: 35436 + requester_id: 20978392 + subject: Help I need somebody! + - id: 20057623 + requester_id: 20978392 + subject: Not just anybody! ViewPreviewResponseExample: value: columns: - - id: subject - title: Subject + - id: subject + title: Subject rows: - - subject: en-US - ticket: {} + - subject: en-US + ticket: {} ViewResponseExample: value: view: @@ -30351,26 +32530,26 @@ components: next_page: null previous_page: null views: - - active: true - conditions: {} - description: View for recent tickets - execution: {} - id: 25 - position: 3 - restriction: {} - title: Tickets updated less than 12 Hours - - active: true - conditions: {} - description: View for tickets that are not assigned - execution: {} - id: 23 - position: 7 - restriction: {} - title: Unassigned tickets + - active: true + conditions: {} + description: View for recent tickets + execution: {} + id: 25 + position: 3 + restriction: {} + title: Tickets updated less than 12 Hours + - active: true + conditions: {} + description: View for tickets that are not assigned + execution: {} + id: 23 + position: 7 + restriction: {} + title: Unassigned tickets ViewsCountResponseExample: value: count: - refreshed_at: "2020-04-06T02:18:17Z" + refreshed_at: 2020-04-06T02:18:17Z value: 16 ViewsResponseExample: value: @@ -30378,36 +32557,34 @@ components: next_page: null previous_page: null views: - - active: true - conditions: {} - description: View for recent tickets - execution: {} - id: 25 - position: 3 - restriction: {} - title: Tickets updated less than 12 Hours - - active: false - conditions: {} - description: View for tickets that are not assigned - execution: {} - id: 23 - position: 7 - restriction: {} - title: Unassigned tickets + - active: true + conditions: {} + description: View for recent tickets + execution: {} + id: 25 + position: 3 + restriction: {} + title: Tickets updated less than 12 Hours + - active: false + conditions: {} + description: View for tickets that are not assigned + execution: {} + id: 23 + position: 7 + restriction: {} + title: Unassigned tickets ViewsUpdateManyResponseExample: value: views: - - active: true - conditions: {} - description: View for recent tickets - execution: {} - id: 123 - position: 8 - restriction: {} - title: Tickets updated less than 12 Hours + - active: true + conditions: {} + description: View for recent tickets + execution: {} + id: 123 + position: 8 + restriction: {} + title: Tickets updated less than 12 Hours securitySchemes: basicAuth: type: http scheme: basic -security: - - basicAuth: [] diff --git a/gradle.properties b/gradle.properties index aa82e25..376fc52 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,4 +10,4 @@ releasePluginVersion=2.8.0 testngVersion=7.6.1 eclipseLsp4jVersion=0.12.0 ballerinaGradlePluginVersion=2.2.4 -ballerinaLangVersion=2201.8.6 +ballerinaLangVersion=2201.12.2