v3

latestOpenAPI 3.0.32026-07-31135300306.1 KB
issues

Create a new issue

Creates a new issue and its first message. Requires either an account_id or requester information.

The requester, first-message author, and delivery destination are independent:

  • requester_id or requester_email identifies the customer the issue is for.

  • user_id or contact_id controls who appears as the author of the first message. If neither is provided, the API token's user is the author.

  • destination_metadata controls whether and where the first message is delivered. If omitted, the first message is an internal note and no customer is contacted.

The requester and message author may differ because an issue can be created either on behalf of a customer or from a customer-authored message. For example, an agent may open an issue for a requester while authoring the first message themselves, or an integration may record an inbound message authored by the customer.

Account and requester resolution:

  • account_id alone creates an issue for that account without setting a requester.

  • requester_id uses an existing contact and, when account_id is omitted, uses the contact's primary account if available.

  • requester_email without account_id finds or creates a contact and associates an account when possible. requester_name is optional and is used when creating the contact.

  • account_id with requester_email finds or creates the contact in the specified account.

  • account_id with requester_id requires the contact to belong to the specified account.

  • If requester_id and requester_email are both provided, requester_id takes precedence.

Destination requirements:

  • If destination_metadata is omitted or destination is internal, the first message remains internal and no customer is contacted. contact_id cannot author an internal note.

  • For email, email is required and identifies the configured Pylon sender address, not a recipient. email_ccs and email_bccs are supported only for email.

  • For slack, the resolved account must be connected to a Slack channel; the first message is delivered to that channel.

  • For in_app_chat, chat_widget_app_id can select the chat widget app used for delivery.

  • For sms, from_sms_phone_number_id is required. Also provide requester_id or requester_email for a contact with a phone number.

  • For whatsapp, whatsapp_app_id, whatsapp_message_template_name, and whatsapp_message_template_language are required. Also provide requester_id or requester_email for a contact with a phone number.

Create an internal issue without contacting a customer:


{

"account_id": "acc_123",

"title": "Investigate usage spike",

"body_html": "<p>Check recent activity.</p>"

}

Create an issue and email an existing requester:


{

"requester_id": "contact_123",

"title": "Following up",

"body_html": "<p>Here is the requested update.</p>",

"destination_metadata": {

"destination": "email",

"email": "support@example.com"

}
}

Create an issue whose first message is attributed to a customer:


{

"requester_id": "contact_123",

"contact_id": "contact_123",

"title": "Unable to sign in",

"body_html": "<p>I cannot access my account.</p>",

"destination_metadata": {

"destination": "in_app_chat"

}
}

Rate limit: 10 requests per minute

post/issues

Request body

account_idstring

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.

assignee_idstring

The user the issue should be assigned to.

attachment_urlsstring[]

URLs of files to attach to the issue's first message.

author_unverifiedboolean

Whether the requester's identity has NOT been verified. Defaults to false (verified).

body_htmlstring required

The HTML content of the body of the issue.

contact_idstring

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.

created_atstring

Timestamp of when the issue was created. If not specified, the current time will be used. (RFC3339)

customer_portal_visibleboolean

Whether the issue should be visible in the customer portal.

prioritystring

The priority of the issue. Can be one of: urgent, high, medium, or low.

requester_avatar_urlstring

The URL of an avatar of the requester.

requester_emailstring

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.

requester_idstring

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.

requester_namestring

The optional full name of the requester. Used when creating a new contact via requester_email.

tagsstring[]

An array of strings to use as tags on this issue. If provided, the issue tags will be updated to the given tags.

team_idstring

The ID of the team this issue should be assigned to.

titlestring required

The title of the issue.

user_idstring

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.

Response

request_idstring

The request ID for tracking.