> For the complete documentation index, see [llms.txt](https://docs.usepylon.com/pylon-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.usepylon.com/pylon-docs/developer/api/api-reference/issues.md).

# Issues

## Get a list of issues

> Returns a paginated list of issues within a required time range (max 30 days).\
> \
> \*\*Rate limit:\*\* 10 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"GetIssuesResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetIssuesResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"GetIssuesResponseBody":{"properties":{"data":{"description":"The data payload of the response.","items":{"$ref":"#/components/schemas/Issue"},"type":"array"},"pagination":{"$ref":"#/components/schemas/Pagination"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"Pagination":{"properties":{"cursor":{"description":"The cursor for the next page of results.","type":"string"},"has_next_page":{"description":"Indicates if there is a next page of results.","type":"boolean"}},"required":["cursor","has_next_page"],"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issues":{"get":{"description":"Returns a paginated list of issues within a required time range (max 30 days).\n\n**Rate limit:** 10 requests per minute","operationId":"GetIssues","parameters":[{"description":"The start time (RFC3339) of the time range to get issues for. The duration between start_time and end_time must be less than or equal to 30 days.","in":"query","name":"start_time","required":true,"schema":{"type":"string"}},{"description":"The end time (RFC3339) of the time range to get issues for. The duration between start_time and end_time must be less than or equal to 30 days.","in":"query","name":"end_time","required":true,"schema":{"type":"string"}},{"description":"The cursor to use for pagination.","in":"query","name":"cursor","schema":{"type":"string"}},{"description":"The number of issues to fetch. Defaults to 20000. Set to 0 or omit to use the default. Must be between 0 and 20000.","in":"query","name":"limit","schema":{"format":"int64","type":"integer"}}],"responses":{"200":{"$ref":"#/components/responses/GetIssuesResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Get a list of issues","tags":["issues"]}}}}
```

## Create a new issue

> Creates a new issue and its first message. Requires either an account\_id or requester information.\
> \
> Requester fields identify the customer, user\_id or contact\_id identifies the first-message author, and destination\_metadata controls delivery. These choices are independent. If destination\_metadata is omitted, the first message is an internal note and no customer is contacted. See the request-field descriptions and examples for destination-specific requirements.\
> \
> \*\*Rate limit:\*\* 10 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"CreateIssueRequest":{"properties":{"account_id":{"description":"The account that this issue belongs to. If requester_id is also provided, the requester must belong to this account. If requester_email is provided, the contact is found or created in this account.","type":"string"},"assignee_id":{"description":"The user the issue should be assigned to.","type":"string"},"attachment_urls":{"description":"URLs of files to attach to the issue's first message.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether the requester's identity has NOT been verified. Defaults to false (verified).","type":"boolean"},"body_html":{"description":"The HTML content of the body of the issue.","type":"string"},"contact_id":{"description":"The contact to attribute the first message to. This controls the message author, not the issue requester. Makes the message appear as a customer message rather than an internal note. Only one of user_id or contact_id can be provided. Requires destination_metadata.","type":"string"},"created_at":{"description":"Timestamp of when the issue was created. If not specified, the current time will be used. (RFC3339)","type":"string"},"custom_fields":{"description":"An array of custom fields to be used on this issue.","items":{"$ref":"#/components/schemas/CustomFieldValue"},"type":"array"},"customer_portal_visible":{"description":"Whether the issue should be visible in the customer portal. When destination is \"customer_portal\", this is set to true and cannot be false.","type":"boolean"},"destination_metadata":{"$ref":"#/components/schemas/DestinationMetadata"},"priority":{"description":"The priority of the issue. Can be one of: urgent, high, medium, or low.","enum":["urgent","high","medium","low"],"type":"string"},"requester_avatar_url":{"description":"The URL of an avatar of the requester.","type":"string"},"requester_email":{"description":"The email of the customer this issue is for. Used when requester_id is omitted. If no matching contact exists, one will be created. When account_id is provided, the contact is found or created in that account. This does not control who authored the first message.","type":"string"},"requester_id":{"description":"The customer this issue is for. Sets the \"Requester\" shown in the issue sidebar but does not control who authored the first message. If account_id is omitted, the requester's primary account is used when available. If requester_email is also provided, requester_id takes precedence.","type":"string"},"requester_name":{"description":"The optional full name of the requester. Used when creating a new contact via requester_email.","type":"string"},"tags":{"description":"An array of strings to use as tags on this issue. If provided, the issue tags will be updated to the given tags.","items":{"type":"string"},"type":"array"},"team_id":{"description":"The ID of the team this issue should be assigned to.","type":"string"},"title":{"description":"The title of the issue.","type":"string"},"user_id":{"description":"The internal Pylon user to attribute the first message to. This does not assign the user as the requester. Only one of user_id or contact_id can be provided. If neither is set, the API token's user is used.","type":"string"}},"required":["title","body_html"],"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"DestinationMetadata":{"description":"Specifies if/how communication will be delivered to the customer.\nYou can configure the issue to contact the requester via email, Slack, in-app chat, SMS, WhatsApp, make it available only in the customer portal, or keep it internal.\nIf an external destination is specified, a message with the issue's BodyHTML will be delivered to the requester. The `customer_portal` destination requires Customer Portal to be enabled and creates a customer-visible message without external delivery.\nTo avoid contacting the requester, omit destination_metadata from the create-issue request or specify the `internal` destination.\nIf destination_metadata is provided, destination is required.","properties":{"chat_widget_app_id":{"description":"The ID of the chat widget app to use for in-app chat.","type":"string"},"destination":{"description":"The destination type of the issue. Can be \"email\", \"slack\", \"in_app_chat\", \"customer_portal\", \"sms\", \"whatsapp\", or \"internal\". Required when destination_metadata is provided. Use \"customer_portal\" for a customer-visible issue with no external delivery; Customer Portal must be enabled for the organization. To create an internal issue, omit destination_metadata or set this field to \"internal\".","enum":["slack","email","in_app_chat","customer_portal","internal","sms","whatsapp"],"type":"string"},"email":{"description":"The email that emails to the requester will be sent from. You must configure an email app in Pylon with this address.","type":"string"},"email_bccs":{"description":"Emails that will be BCCed on emails to the requester.","items":{"type":"string"},"type":"array"},"email_ccs":{"description":"Emails that will be CCed on emails to the requester.","items":{"type":"string"},"type":"array"},"from_sms_phone_number_id":{"description":"The ID of the Telnyx phone number to send SMS from. Required if destination is \"sms\".","type":"string"},"whatsapp_app_id":{"description":"The ID of the WhatsApp app to send messages from. Required if destination is \"whatsapp\".","type":"string"},"whatsapp_message_template_language":{"description":"The language of the WhatsApp message template to use. Required if destination is \"whatsapp\".","type":"string"},"whatsapp_message_template_name":{"description":"The name of the WhatsApp message template to use. Required if destination is \"whatsapp\".","type":"string"}},"required":["destination"],"title":"DestinationMetadata","type":"object"},"CreateIssueResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"CreateIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues":{"post":{"description":"Creates a new issue and its first message. Requires either an account_id or requester information.\n\nRequester fields identify the customer, user_id or contact_id identifies the first-message author, and destination_metadata controls delivery. These choices are independent. If destination_metadata is omitted, the first message is an internal note and no customer is contacted. See the request-field descriptions and examples for destination-specific requirements.\n\n**Rate limit:** 10 requests per minute","operationId":"CreateIssue","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueRequest"}}}},"responses":{"200":{"$ref":"#/components/responses/CreateIssueResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Create a new issue","tags":["issues"]}}}}
```

## POST /issue-groups

> Create an issue group\
> Creates an issue group and attaches its initial child issues atomically.\
> \
> \*\*Rate limit:\*\* 10 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"CreateIssueGroupRequestBody":{"properties":{"child_issue_ids":{"description":"The IDs of the issues to include in the group. At least one is required.","items":{"type":"string"},"type":"array"},"title":{"description":"The title of the issue group.","type":"string"}},"required":["title","child_issue_ids"],"type":"object"},"CreateIssueGroupResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"CreateIssueGroupResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueGroupResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issue-groups":{"post":{"description":"Create an issue group\nCreates an issue group and attaches its initial child issues atomically.\n\n**Rate limit:** 10 requests per minute","operationId":"CreateIssueGroup","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueGroupRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/CreateIssueGroupResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"409":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"tags":["issues"]}}}}
```

## POST /issue-groups/{issue\_group\_id}/children

> Add children to an issue group\
> Adds one or more child issues atomically. Issues already attached to this group are ignored.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"AddIssueGroupChildrenRequestBody":{"properties":{"child_issue_ids":{"description":"The IDs of the issues to add to the group. At least one is required.","items":{"type":"string"},"type":"array"}},"required":["child_issue_ids"],"type":"object"},"IssueGroupMutationResponseBody":{"properties":{"request_id":{"description":"The request ID for tracking.","type":"string"},"success":{"description":"Whether the mutation succeeded.","type":"boolean"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"IssueGroupMutationResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IssueGroupMutationResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issue-groups/{issue_group_id}/children":{"post":{"description":"Add children to an issue group\nAdds one or more child issues atomically. Issues already attached to this group are ignored.\n\n**Rate limit:** 20 requests per minute","operationId":"AddIssueGroupChildren","parameters":[{"description":"The ID of the issue group.","in":"path","name":"issue_group_id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddIssueGroupChildrenRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/IssueGroupMutationResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"409":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"tags":["issues"]}}}}
```

## DELETE /issue-groups/{issue\_group\_id}/children/{child\_issue\_id}

> Remove a child from an issue group\
> Removes one child issue. An issue group must retain at least one child.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"IssueGroupMutationResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IssueGroupMutationResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"IssueGroupMutationResponseBody":{"properties":{"request_id":{"description":"The request ID for tracking.","type":"string"},"success":{"description":"Whether the mutation succeeded.","type":"boolean"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issue-groups/{issue_group_id}/children/{child_issue_id}":{"delete":{"description":"Remove a child from an issue group\nRemoves one child issue. An issue group must retain at least one child.\n\n**Rate limit:** 20 requests per minute","operationId":"RemoveIssueGroupChild","parameters":[{"description":"The ID of the issue group.","in":"path","name":"issue_group_id","required":true,"schema":{"type":"string"}},{"description":"The ID of the child issue to remove.","in":"path","name":"child_issue_id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"$ref":"#/components/responses/IssueGroupMutationResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"409":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"tags":["issues"]}}}}
```

## Create an AI response for an issue

> Generates an AI response for the specified issue using the given agent.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"CreateIssueAIResponseRequestBody":{"properties":{"ai_agent_id":{"description":"The ID of the AI agent to use to create the AI response.","type":"string"},"post_as_internal_note":{"description":"Whether to post the AI response as an internal note on the issue.","type":"boolean"}},"required":["ai_agent_id"],"type":"object"},"CreateIssueAIResponseResponseBody":{"properties":{"request_id":{"description":"The request ID for tracking.","type":"string"},"response_html":{"description":"The HTML content of the AI response.","type":"string"},"response_valid":{"description":"Whether the AI was able to answer the question.","type":"boolean"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"CreateIssueAIResponseResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueAIResponseResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/{id}/ai-response":{"post":{"description":"Generates an AI response for the specified issue using the given agent.\n\n**Rate limit:** 20 requests per minute","operationId":"CreateIssueAIResponse","parameters":[{"description":"The ID or number of the issue to create an AI response for.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateIssueAIResponseRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/CreateIssueAIResponseResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Create an AI response for an issue","tags":["issues"]}}}}
```

## Get all issue statuses

> Returns all issue statuses for the organization.\
> \
> \*\*Rate limit:\*\* 10 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"GetIssueStatusesResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetIssueStatusesResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"GetIssueStatusesResponseBody":{"properties":{"data":{"description":"The data payload of the response.","items":{"$ref":"#/components/schemas/IssueStatus"},"type":"array"},"pagination":{"$ref":"#/components/schemas/Pagination"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"IssueStatus":{"properties":{"category":{"description":"The category of the issue status.","type":"string"},"is_archived":{"description":"Indicates if the issue status is archived.","type":"boolean"},"is_default_status":{"description":"Indicates if the issue status is a default status.","type":"boolean"},"label":{"description":"The label of the issue status.","type":"string"},"slug":{"description":"The slug of the issue status.","type":"string"}},"type":"object"},"Pagination":{"properties":{"cursor":{"description":"The cursor for the next page of results.","type":"string"},"has_next_page":{"description":"Indicates if there is a next page of results.","type":"boolean"}},"required":["cursor","has_next_page"],"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issue-statuses":{"get":{"description":"Returns all issue statuses for the organization.\n\n**Rate limit:** 10 requests per minute","operationId":"GetIssueStatuses","responses":{"200":{"$ref":"#/components/responses/GetIssueStatusesResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Get all issue statuses","tags":["issue-statuses"]}}}}
```

## Get voice calls (with recordings and transcripts) for an issue.

> Returns voice call records for the specified phone issue. Each call includes its recordings, with parsed transcript segments and a presigned download URL for the audio file. Recordings whose transcript has not yet completed are omitted; refetch later to see them.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"GetIssueVoiceCallsResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetIssueVoiceCallsResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"GetIssueVoiceCallsResponseBody":{"properties":{"data":{"description":"The voice calls associated with the issue, including recordings and transcripts.","items":{"$ref":"#/components/schemas/VoiceCall"},"type":"array"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"VoiceCall":{"properties":{"created_at":{"description":"RFC3339 timestamp of when the call record was created.","type":"string"},"duration_sec":{"description":"The duration of the call in seconds.","format":"int64","type":"integer"},"from_phone_number":{"description":"The phone number that originated the call.","type":"string"},"id":{"description":"The ID of the voice call.","type":"string"},"recordings":{"description":"Recordings produced for this call.","items":{"$ref":"#/components/schemas/VoiceCallRecording"},"type":"array"},"to_phone_number":{"description":"The phone number that was dialed.","type":"string"}},"type":"object"},"VoiceCallRecording":{"properties":{"download_url":{"description":"A presigned URL to download the audio file. Expires 1 hour after this response is generated; refetch the voice call to get a new URL.","type":"string"},"id":{"description":"The ID of the recording.","type":"string"},"transcript_segments":{"description":"Parsed transcript with one entry per spoken segment.","items":{"$ref":"#/components/schemas/VoiceCallTranscriptSegment"},"type":"array"}},"type":"object"},"VoiceCallTranscriptSegment":{"properties":{"speaker":{"description":"The speaker label for this segment.","type":"string"},"text":{"description":"The text spoken in this segment.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issues/{id}/voice-calls":{"get":{"description":"Returns voice call records for the specified phone issue. Each call includes its recordings, with parsed transcript segments and a presigned download URL for the audio file. Recordings whose transcript has not yet completed are omitted; refetch later to see them.\n\n**Rate limit:** 20 requests per minute","operationId":"GetIssueVoiceCalls","parameters":[{"description":"The ID of the issue to fetch voice calls for.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"$ref":"#/components/responses/GetIssueVoiceCallsResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Get voice calls (with recordings and transcripts) for an issue.","tags":["voice_calls"]}}}}
```

## Get an issue by its ID/number

> Returns a single issue by ID or issue number.\
> \
> \*\*Rate limit:\*\* 60 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"GetIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetIssueResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"GetIssueResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issues/{id}":{"get":{"description":"Returns a single issue by ID or issue number.\n\n**Rate limit:** 60 requests per minute","operationId":"GetIssue","parameters":[{"description":"The ID or number of the issue to fetch.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"$ref":"#/components/responses/GetIssueResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Get an issue by its ID/number","tags":["issues"]}}}}
```

## Update an existing issue

> Updates an existing issue. Only provided fields are modified.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"UpdateIssueRequestBody":{"properties":{"account_id":{"description":"The ID of the account that this issue belongs to. To remove the account, pass an empty string and also provide requester_id. The requester can be cleared with an empty string or retained if it has no account memberships. Account removal is supported only for manual, form, and email issues.","type":"string"},"assignee_id":{"description":"The ID of the user who should be assigned to this issue. If empty string is passed in, the issue assignee will be removed.","type":"string"},"custom_fields":{"description":"An array of custom fields to be used on this issue. Only passed in fields will be modified.","items":{"$ref":"#/components/schemas/CustomFieldValue"},"type":"array"},"customer_portal_visible":{"description":"Whether the issue should be visible in the customer portal.","type":"boolean"},"requester_id":{"description":"The ID of the requester that this issue is on behalf of. If an empty string is passed, the requester will be removed. This field must be provided when removing the issue's account, and a retained requester must not belong to any account.","type":"string"},"requestor_id":{"description":"Deprecated: Use requester_id instead.","type":"string"},"state":{"description":"The state this issue should be moved to. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"An array of strings to use as tags on this issue. If provided, the issue tags will be updated to be exactly the given tags.","items":{"type":"string"},"type":"array"},"team_id":{"description":"The ID of the team this issue should be assigned to. If empty string is passed in, any assigned team will be removed.","type":"string"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue. Set to \"ticket\" to upgrade a conversation to a support ticket. Cannot be downgraded from \"ticket\" to \"conversation\".","enum":["conversation","ticket"],"type":"string"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"UpdateIssueResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"UpdateIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateIssueResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/{id}":{"patch":{"description":"Updates an existing issue. Only provided fields are modified.\n\n**Rate limit:** 20 requests per minute","operationId":"UpdateIssue","parameters":[{"description":"The ID of the issue to update.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateIssueRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/UpdateIssueResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Update an existing issue","tags":["issues"]}}}}
```

## Delete an existing issue

> Permanently deletes an issue by ID.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"DeleteIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteIssueResponseBody"}}},"description":""}},"schemas":{"DeleteIssueResponseBody":{"properties":{"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issues/{id}":{"delete":{"description":"Permanently deletes an issue by ID.\n\n**Rate limit:** 20 requests per minute","operationId":"DeleteIssue","parameters":[{"description":"The ID of the issue to delete.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"$ref":"#/components/responses/DeleteIssueResponse"}},"summary":"Delete an existing issue","tags":["issues"]}}}}
```

## Search for issues by a given filter

> Filterable fields and their allowed operators:\
> \
> &#x20;Field | Allowed operators |\
> &#x20;\--- | --- |\
> &#x20;\`created\_at\` | \`time\_is\_after\`, \`time\_is\_before\`, \`time\_range\` |\
> &#x20;\`account\_id\` | \`equals\`, \`in\`, \`not\_in\`, \`is\_set\`, \`is\_unset\` |\
> &#x20;\`ticket\_form\_id\` | \`equals\`, \`in\`, \`not\_in\`, \`is\_set\`, \`is\_unset\` |\
> &#x20;\`requester\_id\` | \`equals\`, \`in\`, \`not\_in\`, \`is\_set\`, \`is\_unset\` |\
> &#x20;\`follower\_user\_id\` | \`equals\`, \`in\`, \`not\_in\` |\
> &#x20;\`follower\_contact\_id\` | \`equals\`, \`in\`, \`not\_in\` |\
> &#x20;\`state\` | \`equals\`, \`in\`, \`not\_in\` |\
> &#x20;\`tags\` | \`contains\`, \`does\_not\_contain\`, \`in\`, \`not\_in\` |\
> &#x20;\`title\` | \`string\_contains\`, \`string\_does\_not\_contain\` |\
> &#x20;\`body\_html\` | \`string\_contains\`, \`string\_does\_not\_contain\` |\
> &#x20;\`assignee\_id\` | \`equals\`, \`in\`, \`not\_in\`, \`is\_set\`, \`is\_unset\` |\
> &#x20;\`team\_id\` | \`equals\`, \`in\`, \`not\_in\` |\
> &#x20;\`issue\_type\` | \`equals\`, \`in\`, \`not\_in\`, \`is\_set\`, \`is\_unset\` |\
> &#x20;\`issue\_is\_issue\_group\` | \`equals\`, \`in\`, \`not\_in\` |\
> &#x20;\`resolved\_at\` | \`time\_is\_after\`, \`time\_is\_before\`, \`time\_range\` |\
> &#x20;\`latest\_message\_activity\_at\` | \`time\_is\_after\`, \`time\_is\_before\`, \`time\_range\` |\
> &#x20;\`updated\_at\` | \`time\_is\_after\`, \`time\_is\_before\`, \`time\_range\` |\
> &#x20;\`slack\_channel\_id\` | \`equals\`, \`in\`, \`not\_in\` |\
> \
> Timestamp values use RFC3339 format. Standard \`state\` values are \`new\`, \`waiting\_on\_you\`, \`waiting\_on\_customer\`, \`on\_hold\`, and \`closed\`; custom status slugs are also supported. \`issue\_type\` values are \`conversation\` and \`ticket\`.\
> \
> For tag filters, pass the tag name. For custom fields, pass the field slug as \`field\`. \`slack\_channel\_id\` identifies the Slack channel where the issue was created.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"SearchIssuesRequest":{"properties":{"cursor":{"description":"The cursor to use for pagination.","type":"string"},"filter":{"$ref":"#/components/schemas/Filter"},"limit":{"description":"The number of issues to fetch. Defaults to 100. Must be greater than 0 and less than 1000.","format":"int64","type":"integer"},"search_text":{"description":"Fuzzy text search. Results are intersected with any provided filter.","type":"string"}},"type":"object"},"Filter":{"properties":{"field":{"description":"The field for this filter.  For allowed fields, see the documentation for\nthe specific endpoint you are using.\nFor non-compound filters (any operators other than \"and\" or \"or\"),\nfield must be set, along with either value or values, depending on the operator.","type":"string"},"operator":{"description":"The operator for this filter.","enum":["equals","not_equals","contains","does_not_contain","in","not_in","and","or","time_is_after","time_is_before","time_range","string_contains","string_does_not_contain","is_set","is_unset","greater_than","less_than","greater_than_or_equals","less_than_or_equals"],"type":"string"},"subfilters":{"description":"Sub-filters for this filter.  Valid only when operator is \"and\" or \"or\".\nThe maximum allowed depth for a tree of filters is 3.","items":{"$ref":"#/components/schemas/Filter"},"type":"array"},"value":{"description":"The value for this filter. Only used for single-valued operators\n(\"equals\", \"not_equals\", \"contains\", \"does_not_contain\")","type":"string"},"values":{"description":"The values for this filter. Only used for multi-valued operators (\"in\", \"not_in\").","items":{"type":"string"},"type":"array"}},"required":["operator"],"type":"object"},"SearchIssuesResponseBody":{"properties":{"data":{"items":{"$ref":"#/components/schemas/Issue"},"type":"array"},"pagination":{"$ref":"#/components/schemas/Pagination"},"request_id":{"type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"Pagination":{"properties":{"cursor":{"description":"The cursor for the next page of results.","type":"string"},"has_next_page":{"description":"Indicates if there is a next page of results.","type":"boolean"}},"required":["cursor","has_next_page"],"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"SearchIssuesResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchIssuesResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/search":{"post":{"description":"Filterable fields and their allowed operators:\n\n Field | Allowed operators |\n --- | --- |\n `created_at` | `time_is_after`, `time_is_before`, `time_range` |\n `account_id` | `equals`, `in`, `not_in`, `is_set`, `is_unset` |\n `ticket_form_id` | `equals`, `in`, `not_in`, `is_set`, `is_unset` |\n `requester_id` | `equals`, `in`, `not_in`, `is_set`, `is_unset` |\n `follower_user_id` | `equals`, `in`, `not_in` |\n `follower_contact_id` | `equals`, `in`, `not_in` |\n `state` | `equals`, `in`, `not_in` |\n `tags` | `contains`, `does_not_contain`, `in`, `not_in` |\n `title` | `string_contains`, `string_does_not_contain` |\n `body_html` | `string_contains`, `string_does_not_contain` |\n `assignee_id` | `equals`, `in`, `not_in`, `is_set`, `is_unset` |\n `team_id` | `equals`, `in`, `not_in` |\n `issue_type` | `equals`, `in`, `not_in`, `is_set`, `is_unset` |\n `issue_is_issue_group` | `equals`, `in`, `not_in` |\n `resolved_at` | `time_is_after`, `time_is_before`, `time_range` |\n `latest_message_activity_at` | `time_is_after`, `time_is_before`, `time_range` |\n `updated_at` | `time_is_after`, `time_is_before`, `time_range` |\n `slack_channel_id` | `equals`, `in`, `not_in` |\n\nTimestamp values use RFC3339 format. Standard `state` values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported. `issue_type` values are `conversation` and `ticket`.\n\nFor tag filters, pass the tag name. For custom fields, pass the field slug as `field`. `slack_channel_id` identifies the Slack channel where the issue was created.\n\n**Rate limit:** 20 requests per minute","operationId":"SearchIssues","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchIssuesRequest"}}}},"responses":{"200":{"$ref":"#/components/responses/SearchIssuesResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Search for issues by a given filter","tags":["issues"]}}}}
```

## Snooze an issue

> Snoozes an issue until the specified date and time.\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"SnoozeIssueRequestBody":{"properties":{"snooze_until":{"description":"The date and time to snooze the issue until. (RFC3339)","type":"string"}},"required":["snooze_until"],"type":"object"},"SnoozeIssueResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"SnoozeIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SnoozeIssueResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/{id}/snooze":{"post":{"description":"Snoozes an issue until the specified date and time.\n\n**Rate limit:** 20 requests per minute","operationId":"SnoozeIssue","parameters":[{"description":"The ID or number of the issue to snooze.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SnoozeIssueRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/SnoozeIssueResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Snooze an issue","tags":["issues"]}}}}
```

## Get followers of an issue

> Returns the list of followers for the specified issue.\
> \
> \*\*Rate limit:\*\* 60 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"responses":{"GetIssueFollowersResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetIssueFollowersResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}},"schemas":{"GetIssueFollowersResponseBody":{"properties":{"data":{"description":"The data payload of the response.","items":{"$ref":"#/components/schemas/Follower"},"type":"array"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Follower":{"properties":{"id":{"description":"The ID of the follower. Either a user or contact ID.","type":"string"},"type":{"description":"The type of follower. Either \"user\" or \"contact\".","enum":["user","contact"],"type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}}},"paths":{"/issues/{id}/followers":{"get":{"description":"Returns the list of followers for the specified issue.\n\n**Rate limit:** 60 requests per minute","operationId":"GetIssueFollowers","parameters":[{"description":"The ID or number of the issue to get followers for.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"$ref":"#/components/responses/GetIssueFollowersResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Get followers of an issue","tags":["issues"]}}}}
```

## Add or remove followers to/from an issue

> By default, adds followers. To remove followers, set the operation field to "remove".\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"AddIssueFollowersRequestBody":{"properties":{"contact_ids":{"description":"The IDs of contacts to add as followers.","items":{"type":"string"},"type":"array"},"operation":{"description":"Operation to perform. Use \"add\" to add followers (default) or \"remove\" to remove followers.","type":"string"},"user_ids":{"description":"The IDs of users to add as followers.","items":{"type":"string"},"type":"array"}},"type":"object"},"AddIssueFollowersResponseBody":{"properties":{"data":{"description":"The data payload of the response.","items":{"$ref":"#/components/schemas/Follower"},"type":"array"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Follower":{"properties":{"id":{"description":"The ID of the follower. Either a user or contact ID.","type":"string"},"type":{"description":"The type of follower. Either \"user\" or \"contact\".","enum":["user","contact"],"type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"AddIssueFollowersResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddIssueFollowersResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/{id}/followers":{"post":{"description":"By default, adds followers. To remove followers, set the operation field to \"remove\".\n\n**Rate limit:** 20 requests per minute","operationId":"AddIssueFollowers","parameters":[{"description":"The ID or number of the issue to add followers to.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddIssueFollowersRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/AddIssueFollowersResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Add or remove followers to/from an issue","tags":["issues"]}}}}
```

## Link or unlink external issues to/from an issue

> By default, links external issues. To unlink issues, set the operation field to "unlink".\
> \
> \*\*Rate limit:\*\* 20 requests per minute

```json
{"openapi":"3.0.3","info":{"title":"Pylon API.","version":"1.0.0"},"servers":[{"url":"https://api.usepylon.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"description":"Authorization: Bearer <token>","scheme":"bearer","type":"http"}},"schemas":{"LinkExternalIssueRequestBody":{"properties":{"external_issue_id":{"description":"The ID of the external issue in the source system.","type":"string"},"operation":{"description":"Operation to perform. Use \"link\" to link issues (default) or \"unlink\" to unlink issues.","type":"string"},"source":{"description":"The source system of the external issue (e.g., \"linear\", \"asana\", \"jira\", \"github\", \"shortcut\").","type":"string"}},"required":["source","external_issue_id"],"type":"object"},"LinkExternalIssueResponseBody":{"properties":{"data":{"$ref":"#/components/schemas/Issue"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"},"Issue":{"properties":{"account":{"$ref":"#/components/schemas/MiniAccount"},"active_time_by_user":{"description":"Active time spent on the issue broken down per user, if any.","items":{"$ref":"#/components/schemas/ActiveTimeByUser"},"type":"array"},"active_time_seconds":{"description":"The total active time spent on the issue in seconds, if any. Equals the sum of the per-user active time.","format":"int64","type":"integer"},"assignee":{"$ref":"#/components/schemas/MiniUser"},"attachment_urls":{"description":"The attachment URLs attached to this issue, if any.","items":{"type":"string"},"type":"array"},"author_unverified":{"description":"Whether any message on the issue has an unverified author identity. True if any message author's identity has NOT been verified (e.g., from public forms).","type":"boolean"},"body_html":{"description":"The body of the issue in HTML format.","type":"string"},"business_hours_active_time_seconds":{"description":"The total business-hours active time spent on the issue in seconds, if any. Equals the sum of the per-user business-hours active time.","format":"int64","type":"integer"},"business_hours_first_response_seconds":{"description":"The business hours time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"business_hours_resolution_seconds":{"description":"The business hours time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"business_hours_time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the business hours time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"chat_widget_info":{"$ref":"#/components/schemas/IssueChatWidgetInfo"},"child_issues":{"description":"The child issues in this group, if this issue is an issue group.","items":{"$ref":"#/components/schemas/MiniIssue"},"type":"array"},"created_at":{"description":"The time the issue was created.","type":"string"},"csat_responses":{"description":"The CSAT responses of the issue, if any.","items":{"$ref":"#/components/schemas/CSATResponse"},"type":"array"},"custom_fields":{"additionalProperties":{"$ref":"#/components/schemas/CustomFieldValue"},"description":"Custom field values associated with the issue.","type":"object"},"customer_portal_visible":{"description":"Whether the issue is visible in the customer portal.","type":"boolean"},"external_issues":{"description":"The external issues associated with the issue, if any.","items":{"$ref":"#/components/schemas/ExternalIssue"},"type":"array"},"first_response_breach_time":{"description":"The time by which the issue's first response SLA will breach, if any. Only present for issues with an active first response SLA.","type":"string"},"first_response_seconds":{"description":"The time in seconds it took for the first response to the issue, if any.","format":"int64","type":"integer"},"first_response_time":{"description":"The time of the first response to the issue, if any.","type":"string"},"id":{"description":"The ID of the issue.","type":"string"},"is_issue_group":{"description":"Whether this issue is an issue group.","type":"boolean"},"latest_message_time":{"description":"The time of the latest message in the issue.","type":"string"},"link":{"description":"The link to the issue in Pylon.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"number_of_touches":{"description":"The number of times the issue has been touched.","format":"int64","type":"integer"},"parent_issue_group":{"$ref":"#/components/schemas/MiniIssue"},"requester":{"$ref":"#/components/schemas/MiniContact"},"resolution_breach_time":{"description":"The time by which the issue's resolution SLA will breach, if any. Only present for open issues with an active resolution SLA.","type":"string"},"resolution_seconds":{"description":"The time in seconds it took for the issue to be resolved, if any.","format":"int64","type":"integer"},"resolution_time":{"description":"The time of the resolution of the issue, if any.","type":"string"},"slack":{"$ref":"#/components/schemas/SlackInfo"},"snoozed_until_time":{"description":"The time the issue was snoozed until in RFC3339 format, if any.","type":"string"},"source":{"description":"The source of the issue.","enum":["slack","microsoft_teams","microsoft_teams_chat","chat_widget","customer_portal","email","manual","form","discord","whatsapp","sms","telegram","phone"],"type":"string"},"state":{"description":"The state of the issue. Standard values are `new`, `waiting_on_you`, `waiting_on_customer`, `on_hold`, and `closed`; custom status slugs are also supported.","type":"string"},"tags":{"description":"Tags associated with the issue.","items":{"type":"string"},"type":"array"},"team":{"$ref":"#/components/schemas/MiniTeam"},"team_slas":{"description":"The team-scoped SLAs on the issue, if any. One entry per team, mirroring the issue-level first response and resolution SLA fields.","items":{"$ref":"#/components/schemas/TeamSLA"},"type":"array"},"time_in_status_seconds":{"additionalProperties":{"format":"int64","type":"integer"},"description":"A map of status slug to the time in seconds the issue has spent in that status. Includes both base statuses (e.g. \"new\", \"waiting_on_you\") and custom statuses.","type":"object"},"title":{"description":"The title of the issue.","type":"string"},"type":{"description":"The type of the issue.","enum":["conversation","ticket"],"type":"string"},"updated_at":{"description":"The time the issue was last updated.","type":"string"}},"type":"object"},"MiniAccount":{"properties":{"external_ids":{"description":"External IDs associated with the account.","items":{"$ref":"#/components/schemas/ExternalID"},"type":"array"},"id":{"description":"The ID of the account.","type":"string"}},"type":"object"},"ExternalID":{"properties":{"external_id":{"description":"The external ID. Must be unique per object type (ex. account).","type":"string"},"label":{"description":"The label of the external ID. Must be unique per object.","type":"string"}},"type":"object"},"ActiveTimeByUser":{"properties":{"active_time_seconds":{"description":"The user's active time on the issue in seconds.","format":"int64","type":"integer"},"business_hours_active_time_seconds":{"description":"The user's business-hours active time on the issue in seconds.","format":"int64","type":"integer"},"user_id":{"description":"The ID of the user who spent the time.","type":"string"}},"type":"object"},"MiniUser":{"properties":{"email":{"description":"The email of the user.","type":"string"},"id":{"description":"The ID of the user.","type":"string"}},"type":"object"},"IssueChatWidgetInfo":{"properties":{"page_url":{"description":"The URL of the page that the user was on when they started the chat widget issue.","type":"string"}},"type":"object"},"MiniIssue":{"properties":{"id":{"description":"The ID of the issue.","type":"string"},"number":{"description":"The number of the issue.","format":"int64","type":"integer"},"title":{"description":"The title of the issue.","type":"string"}},"type":"object"},"CSATResponse":{"properties":{"comment":{"description":"The comment of the CSAT response.","type":"string"},"score":{"description":"The score of the CSAT response.","format":"int64","type":"integer"}},"type":"object"},"CustomFieldValue":{"properties":{"slug":{"description":"The slug of the custom field.","type":"string"},"value":{"description":"The value of the custom field. Only to be used for single-valued custom fields. If unset, the custom field will be unset. If the custom field is a select field, the value must be the select option slug, which you can find from the GET /custom-fields endpoint. If the custom field is a relationship field, the value must be the related object ID.","type":"string"},"values":{"description":"The values of the custom field. Only to be used for multi-valued custom fields (ex. multiselect). If unset, the custom field will be unset. If the custom field is a multiselect field, the values must be the select option slugs which you can find from the GET /custom-fields endpoint.","items":{"type":"string"},"type":"array"}},"type":"object"},"ExternalIssue":{"properties":{"external_id":{"description":"The external ID of the external issue.\nJira: ID of the issue (autoincrementing number from 10000).\nGitHub: Owner/Repo/IssueID.\nLinear: ID of the issue (UUID).\nAsana: ID of the task (Long number).","type":"string"},"link":{"description":"Link to the product issue.","type":"string"},"source":{"description":"The source of the external issue.","type":"string"}},"type":"object"},"MiniContact":{"properties":{"email":{"description":"The email of the contact.","type":"string"},"id":{"description":"The ID of the contact.","type":"string"}},"type":"object"},"SlackInfo":{"properties":{"channel_id":{"description":"The Slack channel ID associated with the issue.","type":"string"},"message_ts":{"description":"The root message ID of slack message that started issue.","type":"string"},"workspace_id":{"description":"The Slack workspace ID associated with the issue.","type":"string"}},"type":"object"},"MiniTeam":{"properties":{"id":{"description":"The ID of the team.","type":"string"}},"type":"object"},"TeamSLA":{"properties":{"first_response":{"$ref":"#/components/schemas/SLATimes"},"resolution":{"$ref":"#/components/schemas/SLATimes"},"team_id":{"description":"The ID of the team these are scoped to.","type":"string"}},"type":"object"},"SLATimes":{"properties":{"breach_time":{"description":"The time at which it breaches (or has breached), if any.","type":"string"},"business_hours_seconds":{"description":"The elapsed business-hours time in seconds, if any.","format":"int64","type":"integer"},"seconds":{"description":"The elapsed time in seconds, if any.","format":"int64","type":"integer"},"time":{"description":"The time it was reached, if any.","type":"string"}},"type":"object"},"ErrorApiResponseBody":{"properties":{"errors":{"description":"The list of errors.","items":{"type":"string"},"type":"array"},"exists_id":{"description":"The ID of the object that already exists if this is a duplicate object error.","type":"string"},"request_id":{"description":"The request ID for tracking.","type":"string"}},"type":"object"}},"responses":{"LinkExternalIssueResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkExternalIssueResponseBody"}}},"description":""},"BadRequestApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"The request was invalid or could not be completed."},"ErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":""},"InternalServerErrorApiResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorApiResponseBody"}}},"description":"An unexpected internal error occurred."}}},"paths":{"/issues/{id}/external-issues":{"post":{"description":"By default, links external issues. To unlink issues, set the operation field to \"unlink\".\n\n**Rate limit:** 20 requests per minute","operationId":"LinkExternalIssue","parameters":[{"description":"The ID or number of the issue to link external issues to.","in":"path","name":"id","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkExternalIssueRequestBody"}}}},"responses":{"200":{"$ref":"#/components/responses/LinkExternalIssueResponse"},"400":{"$ref":"#/components/responses/BadRequestApiResponse"},"404":{"$ref":"#/components/responses/ErrorApiResponse"},"500":{"$ref":"#/components/responses/InternalServerErrorApiResponse"}},"summary":"Link or unlink external issues to/from an issue","tags":["issues"]}}}}
```

{% hint style="info" %}
Note: Utilizing external issues endpoint will update the ticket status to whatever is set in the apps directory page, if the "automatically change issue status when linked" setting is enabled. Please see screenshot below.
{% endhint %}

<figure><img src="/files/G5ZwLm6QS8q8Qp4w1JVR" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.usepylon.com/pylon-docs/developer/api/api-reference/issues.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
