Gorgias Component
Gorgias is a customer support platform designed to help e-commerce businesses manage customer inquiries and support tickets efficiently.
Component key: gorgias
Description
Gorgias is a customer service platform that helps e-commerce businesses provide support for their online stores. It allows businesses to offer multichannel customer service from a single app, including email, voice, SMS, live chat, and social media. Gorgias is known for its deep integration with e-commerce platforms like Shopify, Magento, and Big Commerce. This integration allows customer service teams to review, edit, or refund customer orders directly from within the Gorgias ticket window.
Use the Gorgias component to create and manage tickets, customers, and associated events.
API Documentation
This component was built using the Gorgias REST API.
Connections
Gorgias API Key
Steps to generate and use an API key for Gorgias:
- Login to Gorgias: Start by logging into your Gorgias account.
- Navigate to Settings: After logging in, go to the Settings section of your Gorgias account. This is where you can manage various configurations for your account, including those related to the API.
- REST API Section: Within the Settings, locate the REST API section. Here, you can manage API keys, which are essential for authenticating and interacting with the Gorgias API.
- Generate Password (API Key): In the REST API section, you'll see an option to generate a new API key, referred to as "Password" in this context. Click Generate to create a new API key.
- Enter the API Key: Once the API key is generated, you need to enter it in the connection configuration.
Once completed, you can start performing requests directly from the API documentation.
| Input | Notes | Example |
|---|---|---|
| API Key | Your API Key for Gorgias. | |
| Domain | The domain of the Gorgias API, this is provided by the service provider. | green-garden |
| Username | Your username for Gorgias. e.g. john@example.com |
Gorgias OAuth 2.0
Steps to generate app credentials for OAuth 2.0 for Gorgias:
- Login to Gorgias: Start by logging into the Gorgias developer portal.
- Create a New App: Click the Create New App button.
- Fill out the app submission form:
- App Name: Shown whenever you app is mentioned.
- App Tagline: Shown underneath the app name in your integration details.
- App Icon: Shown as your app logo.
- Set App URL: The App URL is required to set up the OAuth flow. Enter your own app's URL.
- Configure Redirect URIs: Enter
https://oauth2.prismatic.io/callback
- Retrieve Client ID and Client Secret: After creating the app, edit it to retrieve the Client ID and Client Secret.
- Enter the Client ID and Client Secret: Enter the Client ID and Client Secret values into the connection configuration.
Once completed, you can start performing requests directly from the API documentation.
| Input | Notes | Example |
|---|---|---|
| Authorize URL | The URL to which the user will be redirected to authorize your application. This URL should be provided by the service provider. | https://<DOMAIN>.gorgias.com/oauth/authorize |
| Client ID | ||
| Client Secret | ||
| Domain | The domain of the Gorgias API, this is provided by the service provider. | green-garden |
| Scopes | A space-separated list of permissions or access levels that your application is requesting. Each scope is a string that represents a specific permission or set of permissions. | openid profile email write:all offline |
| Token URL | The URL used to obtain an access token from the service provider. This URL should be provided by the service provider. | https://<DOMAIN>.gorgias.com/oauth/token |
Data Sources
Select Customer
Allow a user to select one of their customers. | key: selectCustomer | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| View ID | ID of a view to filter customers by. |
{
"result": [
{
"key": "1",
"label": "John Doe"
},
{
"key": "2",
"label": "Jane Doe"
},
{
"key": "3",
"label": "Sarah Connor"
}
]
}
Select Event
Select a event from a list of events. | key: selectEvent | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Created Datetime | Comparators used to filter events on their creation date. See https://developers.gorgias.com/reference/list-events for more information. | |
| Object ID | ID of the object associated with the events to return. | 5190131059 |
| Object Type | Type of the object associated with the events to return. | Customer |
| Types | Types of the events to return. | account-created |
| User IDs | IDs of the users who triggered the events to return. | 5190131059 |
{
"result": [
{
"key": "1",
"label": "Event 1"
},
{
"key": "2",
"label": "Event 2"
},
{
"key": "3",
"label": "Event 3"
}
]
}
Select Message
Select a message from a list of messages. | key: selectMessage | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Ticket ID | The ID of the ticket the messages are associated with. | 353768814 |
{
"result": [
{
"key": "1",
"label": "Message 1"
},
{
"key": "2",
"label": "Message 2"
},
{
"key": "3",
"label": "Message 3"
}
]
}
Select Ticket
Select a ticket from a list of tickets. | key: selectTicket | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Customer ID | The ID of a customer used to select their tickets. | 4 |
| Rule ID | The ID of a rule used to select tickets matching the filters of this one. | 21 |
| View ID | The ID of a view used to select tickets matching the filters of this one. | 21 |
{
"result": [
{
"key": "1",
"label": "Ticket 1"
},
{
"key": "2",
"label": "Ticket 2"
},
{
"key": "3",
"label": "Ticket 3"
}
]
}
Actions
Create Customer
Create a customer. | key: createCustomer
| Input | Notes | Example |
|---|---|---|
| Channels | The customer's contact channels. See https://developers.gorgias.com/reference/create-customer for more information. | |
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
Primary email address of the customer. | john@example.com | |
| External ID | ID of the customer in a foreign system (Stripe, Aircall, etc...). This field is not used by Gorgias, feel free to set it as you wish. | customer-84203241 |
| Language | The customer's preferred language (format: ISO_639-1). | en |
| Name | Full name of the customer. | John Smith |
| Timezone | The customer's preferred timezone (format: IANA timezone name). | UTC |
{
"data": {
"id": 3924,
"created_datetime": "2019-04-13T03:27:56.973873",
"email": "john@example.com",
"external_id": "customer-84203241",
"firstname": "John",
"integrations": {
"6": {
"orders": [
{
"id": 772803526679,
"total_tax": "0.02",
"created_at": "2018-12-04T03:29:37-08:00",
"line_items": [
{
"id": 1760305053719,
"sku": "0987654321",
"name": "Acidulous candy",
"grams": 10,
"price": "0.10",
"title": "Acidulous candy",
"taxable": true,
"quantity": 1,
"price_set": {
"shop_money": {
"amount": "0.10",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.10",
"currency_code": "USD"
}
},
"tax_lines": [
{
"rate": 0.2,
"price": "0.02",
"title": "TVA",
"price_set": {
"shop_money": {
"amount": "0.02",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.02",
"currency_code": "USD"
}
}
}
],
"product_id": 8345093387,
"variant_id": 28442938955,
"total_discount": "0.00",
"requires_shipping": true,
"fulfillment_status": null,
"total_discount_set": {
"shop_money": {
"amount": "0.00",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.00",
"currency_code": "USD"
}
},
"fulfillment_service": "manual",
"fulfillable_quantity": 1
}
],
"contact_email": "marie@gorgias.io",
"billing_address": {
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"country_code": "US",
"province_code": "CA"
}
}
],
"customer": {
"id": 667928133655,
"note": "",
"tags": "",
"email": "marie@gorgias.io",
"firstname": "Marie",
"lastname": "Curie",
"orders_count": 1,
"default_address": {
"id": 707106144279,
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"default": true,
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"customer_id": 667928133655,
"country_code": "US",
"country_name": "United States",
"province_code": "CA"
}
},
"__integration_type__": "shopify"
}
},
"language": "fr",
"lastname": "Smith",
"name": "John Smith",
"note": "Our best customer.",
"timezone": "UTC",
"updated_datetime": "2019-09-25T06:18:22.839271"
}
}
Create Ticket
Create a new ticket. | key: createTicket
| Input | Notes | Example |
|---|---|---|
| Assignee Team | The team assigned to the ticket. | |
| Assignee User | The user assigned to the ticket. | |
| Assignee User ID | The team assigned to the ticket. | |
| Closed Datetime | When the ticket was closed. | 2020-01-27T10:42:21.468912 |
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Created Datetime | When the ticket was created. | 2020-01-27T10:42:21.468912 |
| Customer | The customer linked to the ticket. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| External ID | External ID of the ticket in a foreign system. This field is not used by Gorgias, feel free to set it as you wish. | RETURN#4213 |
| From Agent | Whether the first message of the ticket was sent by your company to a customer, or the opposite. | true |
| Language | The language primarily used in the ticket. The language is automatically detected on the first messages by Gorgias if not set explicitly.Once the language has been set, it won't be updated according to future messages. | en |
| Last Message Datetime | When the last message was sent. | 2020-01-27T10:42:21.468912 |
| Last Received Message Datetime | When the last customer's message was sent. | 2020-01-27T10:42:21.468912 |
| Messages | Messages of the ticket. | |
| Meta | Data associated with the ticket. You can use this field to store structured information (key-value data) about the ticket. | key1:value1 |
| Opened Datetime | When the ticket was opened for the first time by a user. | 2020-01-27T10:42:21.468912 |
| Snooze Datetime | When the ticket will be re-opened. | 2020-01-27T10:42:21.468912 |
| Spam | Whether the ticket is considered as spam or not. | false |
| Status | The status of the ticket. | open |
| Subject | The subject of the ticket. | Can I get a refund? |
| Tags | Tags linked to the ticket. | tag1 |
| Trashed Datetime | When the ticket was moved to the trash. | 2020-01-27T10:42:21.468912 |
| Updated Datetime | When the ticket was lastly updated. | 2020-01-27T10:42:21.468912 |
| Via | How the first message of the ticket has been received or sent from Gorgias. |
{
"data": {
"id": 1234,
"assignee_user": {
"id": 567,
"email": "assignee@example.com",
"name": "Alex Johnson",
"firstname": "Alex",
"lastname": "Johnson",
"meta": {
"sso": "sso-link",
"profile_picture_url": "https://www.example.com/images/profile.jpg"
}
},
"channel": "Email",
"closed_datetime": null,
"created_datetime": "2024-08-21T12:00:00Z",
"customer": {
"id": 789,
"channels": [
{
"id": 1
},
{
"id": 2
}
],
"email": "customer@example.com",
"external_id": "C123456",
"firstname": "Sam",
"integrations": {
"CRM": {
"customer_level": "Gold",
"points": 1200
}
},
"lastname": "Doe",
"name": "Sam Doe",
"note": "VIP Customer, handle with care."
},
"external_id": "EXT1234",
"from_agent": false,
"is_unread": true,
"language": "en",
"last_message_datetime": "2024-08-21T12:05:00Z",
"last_received_message_datetime": "2024-08-21T12:04:00Z",
"messages": [
{
"id": 2345,
"attachments": [
{
"url": "https://www.example.com/attachments/info.pdf",
"name": "Information.pdf",
"size": 1024,
"content_type": "application/pdf",
"public": true,
"extra": "User manual"
}
],
"body_html": "<p>Please see the attached user manual for more information.</p>",
"body_text": "Please see the attached user manual for more information.",
"channel": "Email",
"created_datetime": "2024-08-21T12:05:00Z",
"external_id": null,
"failed_datetime": null,
"from_agent": true,
"integration_id": 456,
"last_sending_error": null,
"message_id": "MSG4567",
"receiver": {
"id": 789,
"email": "customer@example.com",
"name": "Sam Doe",
"firstname": "Sam",
"lastname": "Doe",
"meta": null
},
"rule_id": 321,
"sender": {
"id": 567,
"email": "support@example.com",
"name": "Support Team",
"firstname": "Support",
"lastname": "Team",
"meta": null
},
"sent_datetime": "2024-08-21T12:05:00Z",
"source": {
"type": "email",
"to": [
{
"name": "Sam Doe",
"address": "customer@example.com"
}
],
"cc": [],
"bcc": [],
"from": {
"name": "Support Team",
"address": "support@example.com"
}
},
"stripped_html": "<p>Please see the attached user manual for more information.</p>",
"stripped_text": "Please see the attached user manual for more information.",
"subject": "User Manual",
"ticket_id": 1234,
"via": "Email",
"uri": "https://www.example.com/tickets/1234"
}
],
"meta": {
"issue_type": "technical",
"priority": "high"
},
"opened_datetime": "2024-08-21T12:00:00Z",
"reply_options": "Reply, Forward, Archive",
"satisfaction_survey": {
"id": 876,
"body_text": "Please rate our service.",
"created_datetime": "2024-08-21T12:30:00Z",
"customer_id": 789,
"meta": {
"survey_type": "email"
},
"score": null,
"scored_datetime": null,
"sent_datetime": null,
"should_send_datetime": "2024-08-22T12:30:00Z",
"ticket_id": 1234
},
"snoozed_datetime": null,
"spam": false,
"status": "open",
"subject": "Technical Support Inquiry",
"tags": [
{
"id": 1,
"name": "Technical",
"uri": "https://www.example.com/tags/technical",
"decoration": {
"color": "#FF5733"
}
},
{
"id": 2,
"name": "High Priority",
"uri": "https://www.example.com/tags/high_priority",
"decoration": {
"color": "#C70039"
}
}
],
"trashed_datetime": null,
"updated_datetime": "2024-08-21T12:10:00Z",
"via": "Email",
"uri": "https://www.example.com/tickets/1234"
}
}
Create Ticket Message
Create a message for a ticket. | key: createTicketMessage
| Input | Notes | Example |
|---|---|---|
| Action | Policy applied on external actions associated with the message if they failed. | force |
| Attachments | A list of files attached to the message. | |
| Body HTML | The full HTML version of the body of the message, if any. | Hello,<br><br> I can't place an order on your site, it says: I don't have enough credit.<br> How can I add some credits?<br><br> Cheers,<br> John Doe |
| Body Text | The full text version of the body of the message, if any. | Hello, I can't place an order on your site, it says: I don't have enough credit. How can I add some credits? Cheers, John Doe |
| Channel | The channel where the message was sent. | aircall |
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Created Date | When the message was created. | 2020-01-27T10:42:21.468912 |
| Debug Request | Enabling this flag will log out the current request. | false |
| External ID | ID of the message in a foreign system (Aircall, Zendesk, etc...). This field is not used by Gorgias, feel free to set it as you wish. | MSG-78545 |
| Failed Date | When the message failed to be sent. | 2020-01-27T10:42:21.468912 |
| From Agent | Whether the message was sent by your company to a customer, or the opposite. | true |
| Message ID | ID of the message on the service that send the message.It can be the ID of an email, a Messenger message, a Facebook comment, etc... | <123345676453.2445.234@web> |
| Receiver ID | The primary receiver of the message. It can be a user or a customer. Optional when the source type is 'internal-note'. | |
| Sender | The person who sent the message. It can be a user or a customer. | |
| Sent Date | When the message was sent. If omitted, the message will be sent by Gorgias. | 2020-01-27T10:42:21.468912 |
| Source | Information used to route the message. It contains the names and the addresses of the sender and receivers. https://developers.gorgias.com/reference/create-ticket-message | |
| Subject | The subject of the message. | Order issue |
| Ticket ID | The ID of the ticket associated with the message. | 353768814 |
| Via | How the message has been received, or sent from Gorgias. | aircall |
{
"data": {
"id": 3001,
"attachments": [
{
"url": "https://www.example.com/attachments/document.pdf",
"name": "Document.pdf",
"size": 1200,
"content_type": "application/pdf",
"public": true,
"extra": "Confidential Document"
},
{
"url": "https://www.example.com/attachments/image.png",
"name": "Image.png",
"size": 800,
"content_type": "image/png",
"public": false,
"extra": "Screenshot"
}
],
"body_html": "<p>Hello, please find the details attached.</p>",
"body_text": "Hello, please find the details attached.",
"channel": "Email",
"created_datetime": "2024-08-20T12:30:00Z",
"external_id": null,
"failed_datetime": null,
"from_agent": false,
"integration_id": 200,
"last_sending_error": null,
"message_id": "MSG123456789",
"receiver": {
"id": 5002,
"email": "receiver@example.com",
"name": "John Doe",
"firstname": "John",
"lastname": "Doe",
"meta": null
},
"rule_id": 101,
"sender": {
"id": 5001,
"email": "sender@example.com",
"name": "Jane Smith",
"firstname": "Jane",
"lastname": "Smith",
"meta": null
},
"sent_datetime": "2024-08-20T12:35:00Z",
"source": {
"type": "email",
"to": [
{
"name": "John Doe",
"address": "john.doe@example.com"
}
],
"cc": [
{
"name": "Sarah Connor",
"address": "sarah.connor@example.com"
}
],
"bcc": [],
"from": {
"name": "Jane Smith",
"address": "jane.smith@example.com"
}
},
"stripped_html": "<p>Hello, please find the details attached.</p>",
"stripped_text": "Hello, please find the details attached.",
"subject": "Details for Your Request",
"ticket_id": 4003,
"via": "support_portal",
"uri": "https://www.example.com/tickets/4003"
}
}
Delete Customer
Delete a customer. | key: deleteCustomer
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Customer ID | ID of the customer to delete. | 3924 |
{
"data": {
"message": "Success"
}
}
Delete Ticket
Delete a ticket. | key: deleteTicket
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Ticket ID | The ID of the ticket to delete. |
{
"data": {
"message": "Success"
}
}
Delete Ticket Custom Field
Delete a ticket's custom field value. | key: deleteTicketCustomField
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Custom Field ID | The ID of the custom field. | 1234567890 |
| Ticket ID | The ID of the ticket. | 1234567890 |
{
"data": {
"message": "Success"
}
}
Download File
Download a file. | key: downloadFile
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Domain Hash | The domain identifier of the account that owns the resource. | Hna8kldnmlal |
| File Type | The type of file to download. | attachment |
| Resource Name | The resource identifier of the attachment you are trying to retrieve. | image-test-c9f158fc-062d-4b00-a826-e29b36852c9b.png |
{
"data": "https://www.example.com/attachments/12345"
}
Get Account
Retrieve your account. | key: getAccount
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
{
"data": {
"created_datetime": "2017-11-23T15:59:41.966927",
"deactivated_datetime": null,
"domain": "company_name",
"settings": [
{
"id": 987,
"type": "business-hours",
"data": {
"timezone": "UTC",
"business_hours": {
"days": "1,2,3,4,5",
"from_time": "09:00",
"to_time": "22:00"
}
}
}
],
"status": {
"status": "active"
}
}
}
Get Customer
Retrieve a customer. | key: getCustomer
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Customer ID | ID of the customer you're looking for. | 3924 |
{
"data": {
"id": 3924,
"channels": [
{
"id": 49182
}
],
"created_datetime": "2019-04-13T03:27:56.973873",
"email": "john@example.com",
"external_id": "customer-84203241",
"firstname": "John",
"integrations": {
"6": {
"orders": [
{
"id": 772803526679,
"total_tax": "0.02",
"created_at": "2018-12-04T03:29:37-08:00",
"line_items": [
{
"id": 1760305053719,
"sku": "0987654321",
"name": "Acidulous candy",
"grams": 10,
"price": "0.10",
"title": "Acidulous candy",
"taxable": true,
"quantity": 1,
"price_set": {
"shop_money": {
"amount": "0.10",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.10",
"currency_code": "USD"
}
},
"tax_lines": [
{
"rate": 0.2,
"price": "0.02",
"title": "TVA",
"price_set": {
"shop_money": {
"amount": "0.02",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.02",
"currency_code": "USD"
}
}
}
],
"product_id": 8345093387,
"variant_id": 28442938955,
"total_discount": "0.00",
"requires_shipping": true,
"fulfillment_status": null,
"total_discount_set": {
"shop_money": {
"amount": "0.00",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.00",
"currency_code": "USD"
}
},
"fulfillment_service": "manual",
"fulfillable_quantity": 1
}
],
"contact_email": "marie@gorgias.io",
"billing_address": {
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"country_code": "US",
"province_code": "CA"
}
}
],
"customer": {
"id": 667928133655,
"note": "",
"tags": "",
"email": "marie@gorgias.io",
"firstname": "Marie",
"lastname": "Curie",
"orders_count": 1,
"default_address": {
"id": 707106144279,
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"default": true,
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"customer_id": 667928133655,
"country_code": "US",
"country_name": "United States",
"province_code": "CA"
}
},
"__integration_type__": "shopify"
}
},
"language": "fr",
"lastname": "Smith",
"name": "John Smith",
"note": "Our best customer.",
"timezone": "UTC",
"updated_datetime": "2019-09-25T06:18:22.839271",
"external_data": {
"my-awesome-3rd-party-app-ID": {
"badge": "Best customer",
"points": 22,
"__app_name__": "My awesome 3rd party app"
}
},
"ecommerce_data": {
"additionalProp": {
"store": {
"id": 123456,
"type": "woocommerce",
"helpdesk_integration_id": 123456,
"default_currency": "usd",
"url": "https://my-demo-store.com/",
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"currencies": [
"usd",
"eur"
],
"display_name": "My Demo Store",
"created_datetime": "2023-07-15T00:00:00.000000+00:00",
"name": "my-demo-store",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"uuid": "7736626b-0d5f-4e2c-86de-8b74e3401c26"
},
"shopper": {
"id": 123456,
"first_name": "Jean",
"helpdesk_customer_id": 123456,
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"phone_number": "+1 123 456 7890",
"middle_name": "Mary",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"birthdate": "2023-07-15",
"status": "tax_exempt",
"external_id": "example-id-123",
"email_address": "foo@bar.com",
"accepts_marketing_sms": true,
"accepts_marketing_email": true,
"last_name": "Doe",
"created_datetime": "2023-07-15T00:00:00.000000+00:00"
},
"orders": [
{
"external_status": "pending",
"total_amount": "20",
"number": 123456,
"billing_address": {
"id": 123456,
"first_name": "Jane",
"line_1": "123 Main Street",
"city": "Miami",
"zip_code": "123456",
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"preferred": true,
"phone_number": "+1 123 456 7890",
"shopper_external_id": "example-id-123",
"country": "USA",
"line_2": "Apt 123, Floor 2",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"last_name": "Doe",
"external_id": "example-id-123",
"state": "FL",
"created_datetime": "2023-07-15T00:00:00.000000+00:00"
},
"tax_amount": "20",
"discount_codes": [
"DISCOUNT_CODE_1",
"DISCOUNT_CODE_2"
],
"line_items": [
{
"id": 123456,
"unit_price": "123456",
"discount_reason": "Refurbished product",
"discount_type": "percentage",
"title": "My Awesome Product",
"total_amount": "5",
"fulfilled_quantity": 5,
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"taxable": true,
"discount_amount": "20",
"product_options": {
"size": 10
},
"quantity": 5,
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"requires_shipping": true,
"created_datetime": "2023-07-15T00:00:00.000000+00:00"
}
],
"status": "completed",
"external_fulfillment_status": "fulfilled",
"payment_status": "paid",
"shopper_external_id": "example-id-123",
"external_payment_status": "paid",
"name": "Order #123456",
"currency": "usd",
"created_datetime": "2023-07-15T00:00:00.000000+00:00",
"id": 123456,
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"subtotal_amount": "20",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"external_id": "example-id-123",
"shipping_address": {
"id": 123456,
"first_name": "Jane",
"line_1": "123 Main Street",
"city": "Miami",
"zip_code": "123456",
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"preferred": true,
"phone_number": "+1 123 456 7890",
"shopper_external_id": "example-id-123",
"country": "USA",
"line_2": "Apt 123, Floor 2",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"last_name": "Doe",
"external_id": "example-id-123",
"state": "FL",
"created_datetime": "2023-07-15T00:00:00.000000+00:00"
},
"discount_amount": "20",
"shipping_amount": "20"
}
],
"addresses": [
{
"id": 123456,
"first_name": "Jane",
"line_1": "123 Main Street",
"city": "Miami",
"zip_code": "123456",
"updated_datetime": "2023-07-15T00:00:00.000000+00:00",
"preferred": true,
"phone_number": "+1 123 456 7890",
"shopper_external_id": "example-id-123",
"country": "USA",
"line_2": "Apt 123, Floor 2",
"deleted_datetime": "2023-07-15T00:00:00.000000+00:00",
"last_name": "Doe",
"external_id": "example-id-123",
"state": "FL",
"created_datetime": "2023-07-15T00:00:00.000000+00:00"
}
]
}
}
}
}
Get Event
Retrieve an event. | key: getEvent
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Event ID | The ID of the event to retrieve. | 5190131059 |
{
"data": {
"id": 501,
"context": "User logged into the system from a new device.",
"created_datetime": "2024-08-20T19:15:00Z",
"data": {
"ipAddress": "192.168.1.100",
"deviceType": "Smartphone",
"os": "iOS"
},
"object_id": 12345,
"object_type": "UserSession",
"type": "LoginEvent",
"user_id": 7890,
"url": "https://www.example.com/login"
}
}
Get Ticket
Retrieve a ticket. | key: getTicket
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Ticket ID | The ID of the ticket. | |
| Relationships | Names of relations that should be included in returned data. | custom_fields |
{
"data": {
"id": 101,
"url": "https://www.example.com/tickets/101",
"external_id": "EXT1001",
"events": [
{
"idcreated_datetime": "2024-08-22T10:00:00Z",
"data": {
"action": "Ticket Created",
"details": "Initial creation of the ticket"
},
"type": "Creation",
"user": {
"id": 2001,
"firstname": "Alice",
"lastname": "Johnson",
"name": "Alice Johnson",
"email": "alice.johnson@example.com"
},
"uri": "https://www.example.com/events/1001"
}
],
"status": "Open",
"channel": "Email",
"via": "Web",
"from_agent": false,
"is_unread": true,
"spam": null,
"customer": {
"id": 501,
"channels": [
{
"id": 1,
"type": "Email",
"address": "customer501@example.com",
"preferred": true,
"created_datetime": "2024-01-01T12:00:00Z",
"updated_datetime": "2024-01-02T12:00:00Z",
"deleted_datetime": null,
"user": {
"id": 501,
"name": "John Doe"
},
"customer": {
"id": 501,
"name": "John Doe"
}
}
],
"email": "customer501@example.com",
"external_id": "CUST1001",
"firstname": "John",
"integrations": {
"CRM": {
"customer_level": "Gold"
}
},
"external_data": [
{
"loyalty_points": 1200
}
],
"ecommerce_data": {
"last_purchase": {
"date": "2024-01-10",
"amount": 300
}
},
"lastname": "Doe",
"meta": null,
"name": "John Doe",
"note": "High value customer"
},
"assignee_user": {
"id": 301,
"email": "agent301@example.com",
"name": "Sarah Parker",
"firstname": "Sarah",
"lastname": "Parker",
"meta": {
"sso": "sso-agent-link",
"profile_picture_url": "https://www.example.com/images/agent301.jpg"
}
},
"language": "en",
"subject": "Support Request",
"meta": {
"priority": "high",
"category": "technical"
},
"tags": [
{
"id": 1,
"name": "Urgent",
"uri": "https://www.example.com/tags/urgent",
"decoration": {
"color": "#FF0000"
}
}
],
"custom_fields": null,
"messages": [
{
"id": 201,
"attachments": [
{
"url": "https://www.example.com/attachments/guide.pdf",
"name": "UserGuide.pdf",
"size": 1024,
"content_type": "application/pdf",
"public": true,
"extra": "Attachment with additional details"
}
],
"body_html": "<p>Please see the attached user guide for more information.</p>",
"body_text": "Please see the attached user guide for more information.",
"channel": "Email",
"created_datetime": "2024-08-22T10:05:00Z",
"external_id": null,
"failed_datetime": null,
"from_agent": true,
"integration_id": 101,
"last_sending_error": null,
"message_id": "MSG2001",
"receiver": {
"id": 501,
"email": "customer501@example.com",
"name": "John Doe",
"firstname": "John",
"lastname": "Doe",
"meta": null
},
"rule_id": 101,
"sender": {
"id": 301,
"email": "agent301@example.com",
"name": "Sarah Parker",
"firstname": "Sarah",
"lastname": "Parker",
"meta": null
},
"sent_datetime": "2024-08-22T10:05:00Z",
"source": {
"type": "email",
"to": [
{
"name": "John Doe",
"address": "customer501@example.com"
}
],
"cc": [],
"bcc": [],
"from": {
"name": "Sarah Parker",
"address": "agent301@example.com"
}
},
"stripped_html": "<p>Please see the attached user guide for more information.</p>",
"stripped_text": "Please see the attached user guide for more information.",
"subject": "User Guide",
"ticket_id": 101,
"via": "Email",
"uri": "https://www.example.com/messages/201"
}
],
"created_datetime": "2024-08-22T10:00:00Z",
"opened_datetime": "2024-08-22T10:01:00Z",
"last_received_message_datetime": "2024-08-22T10:04:00Z",
"last_message_datetime": "2024-08-22T10:05:00Z",
"updated_datetime": "2024-08-22T10:06:00Z",
"closed_datetime": null,
"trashed_datetime": null,
"snooze_datetime": null,
"satisfaction_survey": {
"id": 401,
"body_text": "Please rate our service.",
"created_datetime": "2024-08-22T10:30:00Z",
"customer_id": 501,
"meta": null,
"score": null,
"scored_datetime": null,
"sent_datetime": null,
"should_send_datetime": "2024-08-23T10:30:00Z",
"ticket_id": 101
},
"reply_options": "Reply, Forward, Archive"
}
}
Get Ticket Message
Retrieve a message. | key: getTicketMessage
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Message ID | The ID of the message. | 353768814 |
| Ticket ID | The ID of the ticket associated with the message. | 353768814 |
{
"data": {
"id": 3005,
"attachments": [
{
"url": "https://www.example.com/attachments/report.pdf",
"name": "AnnualReport.pdf",
"size": 2500,
"content_type": "application/pdf",
"public": true,
"extra": "Annual financial report"
},
{
"url": "https://www.example.com/attachments/photo.jpeg",
"name": "EventPhoto.jpeg",
"size": 1500,
"content_type": "image/jpeg",
"public": false,
"extra": "Photo from the company event"
}
],
"body_html": "<p>Here is the information you requested.</p>",
"body_text": "Here is the information you requested.",
"channel": "Email",
"created_datetime": "2024-08-20T15:00:00Z",
"external_id": "EXT123456",
"failed_datetime": null,
"from_agent": true,
"integration_id": 123,
"last_sending_error": null,
"message_id": "MSG000456",
"receiver": {
"id": 2020,
"email": "customer@example.com",
"name": "Sam Doe",
"firstname": "Sam",
"lastname": "Doe",
"meta": null
},
"rule_id": 105,
"sender": {
"id": 1010,
"email": "support@company.com",
"name": "Support Team",
"firstname": "Support",
"lastname": "Team",
"meta": null
},
"sent_datetime": "2024-08-20T15:05:00Z",
"source": {
"type": "email",
"to": [
{
"name": "Sam Doe",
"address": "sam.doe@example.com"
}
],
"cc": [],
"bcc": [],
"from": {
"name": "Support Team",
"address": "support@company.com"
}
},
"stripped_html": "<p>Here is the information you requested.</p>",
"stripped_text": "Here is the information you requested.",
"subject": "Your Requested Information",
"ticket_id": 4005,
"via": "email",
"uri": "https://www.example.com/tickets/4005"
}
}
List Customers
List customers, paginated, and ordered by their name (alphabetical order). | key: listCustomers
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Cursor | Value indicating your position in the list of all customers. If omitted, the first customers of the list will be returned. | |
| Debug Request | Enabling this flag will log out the current request. | false |
Primary email address of the customer. | john@example.com | |
| External ID | ID of the customer in a foreign system (Stripe, Aircall, etc...). This field is not used by Gorgias, feel free to set it as you wish. | customer-84203241 |
| Fetch All | When enabled, all customers will be fetched. This can be slow if you have a lot of customers. Cursor and limit will be ignored. | false |
| Customer ID | ID of the customer you're looking for. | |
| Language | The customer's preferred language (format: ISO_639-1). | en |
| Limit | Maximum number of customers to return. The max number allowed is 100. | |
| Order By | Attribute used to order customers. | |
| Timezone | The customer's preferred timezone (format: IANA timezone name). | UTC |
| View ID | ID of a view to filter customers by. |
{
"data": {
"data": [
{
"id": 1,
"created_datetime": null,
"email": null,
"external_id": null,
"firstname": "Jane",
"language": null,
"lastname": "Doe",
"name": null,
"timezone": null,
"updated_datetime": "20190925T06:18:22.839271"
}
],
"object": "list",
"uri": "/customers",
"meta": {
"prev_cursor": null,
"next_cursor": null
}
}
}
List Events
List events, paginated, and ordered by their creation date, with the most recently created first. | key: listEvents
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Created Datetime | Comparators used to filter events on their creation date. See https://developers.gorgias.com/reference/list-events for more information. | |
| Cursor | Value indicating your position in the list of all events. If omitted, the first events of the list will be returned. | cHJldl9fNl9fMjAyMS0wMy0wMyAwNjowMDowMA== |
| Debug Request | Enabling this flag will log out the current request. | false |
| Fetch All | When enabled, all events will be fetched. This can be slow if you have a lot of events. Cursor and limit will be ignored. | false |
| Limit | Maximum number of customers to return. The max number allowed is 100. | 30 |
| Object ID | ID of the object associated with the events to return. | 5190131059 |
| Object Type | Type of the object associated with the events to return. | Customer |
| Order By | Attribute used to order events. | created_datetime:desc |
| Types | Types of the events to return. | account-created |
| User IDs | IDs of the users who triggered the events to return. | 5190131059 |
{
"data": {
"data": [
{
"id": 1024,
"context": "User updated account settings.",
"created_datetime": "2024-08-20T10:45:00Z",
"data": {
"settingsChanged": {
"emailNotifications": true,
"theme": "dark"
},
"actionPerformedBy": "Admin"
},
"object_id": 2048,
"object_type": "UserProfile",
"type": "UpdateSettings",
"user_id": 256,
"url": "https://www.example.com/settings"
}
],
"object": "list",
"uri": "/events",
"meta": {
"prev_cursor": null,
"next_cursor": null
}
}
}
List Messages
List messages matching the given parameters. | key: listMessages
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Cursor | Value indicating your position in the list of all messages. If omitted, the first messages of the list will be returned. | cHJldl9fNl9fMjAyMS0wMy0wMyAwNjowMDowMA== |
| Debug Request | Enabling this flag will log out the current request. | false |
| Fetch All | When enabled, all messages will be fetched. This can be slow if you have a lot of messages. Cursor and limit will be ignored. | false |
| Limit | Maximum number of messages to return. The max number allowed is 100. | 30 |
| Order By | Attribute used to order messages. | created_datetime:desc |
| Ticket ID | The ID of the ticket the messages are associated with. | 353768814 |
{
"data": {
"data": [
{
"id": 3005,
"attachments": [
{
"url": "https://www.example.com/attachments/report.pdf",
"name": "AnnualReport.pdf",
"size": 2500,
"content_type": "application/pdf",
"public": true,
"extra": "Annual financial report"
},
{
"url": "https://www.example.com/attachments/photo.jpeg",
"name": "EventPhoto.jpeg",
"size": 1500,
"content_type": "image/jpeg",
"public": false,
"extra": "Photo from the company event"
}
],
"body_html": "<p>Here is the information you requested.</p>",
"body_text": "Here is the information you requested.",
"channel": "Email",
"created_datetime": "2024-08-20T15:00:00Z",
"external_id": "EXT123456",
"failed_datetime": null,
"from_agent": true,
"integration_id": 123,
"last_sending_error": null,
"message_id": "MSG000456",
"receiver": {
"id": 2020,
"email": "customer@example.com",
"name": "Sam Doe",
"firstname": "Sam",
"lastname": "Doe",
"meta": null
},
"rule_id": 105,
"sender": {
"id": 1010,
"email": "support@company.com",
"name": "Support Team",
"firstname": "Support",
"lastname": "Team",
"meta": null
},
"sent_datetime": "2024-08-20T15:05:00Z",
"source": {
"type": "email",
"to": [
{
"name": "Sam Doe",
"address": "sam.doe@example.com"
}
],
"cc": [],
"bcc": [],
"from": {
"name": "Support Team",
"address": "support@company.com"
}
},
"stripped_html": "<p>Here is the information you requested.</p>",
"stripped_text": "Here is the information you requested.",
"subject": "Your Requested Information",
"ticket_id": 4005,
"via": "email",
"uri": "https://www.example.com/tickets/4005"
}
],
"object": "list",
"uri": "/messages",
"meta": {
"prev_cursor": null,
"next_cursor": null
}
}
}
List Ticket Custom Fields
List all custom fields for a ticket. | key: listTicketCustomFields
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Ticket ID | The ID of the ticket. | 1234567890 |
{
"data": [
{
"field": {
"id": 101,
"external_id": "EXT001",
"object_type": "ticket",
"label": "Customer Satisfaction Score",
"description": "A score representing customer satisfaction on a scale of 1 to 10.",
"priority": 10,
"required": true,
"managed_by": "system",
"definition": {
"input_settings": "DROPDOWN",
"data_type": "integer"
},
"created_datetime": "2024-08-21T12:00:00Z",
"updated_datetime": "2024-08-21T12:30:00Z",
"deactivated_datetime": null
},
"value": "8",
"prediction": {
"predicted": "7",
"confidence": 75,
"display": true,
"confirmed": false,
"modified": false
}
}
]
}
List Tickets
List tickets, paginated and ordered by the attribute of the given view. | key: listTickets
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Cursor | Value indicating your position in the list of all tickets. If omitted, the first tickets of the list will be returned. | cHJldl9fNl9fMjAyMS0wMy0wMyAwNjowMDowMA== |
| Customer ID | The ID of a customer used to select their tickets. | 4 |
| Debug Request | Enabling this flag will log out the current request. | false |
| External ID | ID of the ticket in a foreign system you're looking for. | ticket-ge432d |
| Fetch All | When enabled, all tickets will be fetched. This can be slow if you have a lot of tickets. Cursor and limit will be ignored. | true |
| Limit | Maximum number of tickets to return. The max number allowed is 100. | 30 |
| Order By | Attribute used to order tickets. | created_datetime:desc |
| Rule ID | The ID of a rule used to select tickets matching the filters of this one. | 21 |
| Ticket IDs | The IDs of tickets to select. | 1234567890 |
| View ID | The ID of a view used to select tickets matching the filters of this one. | 21 |
{
"data": {
"data": [
{
"id": 1001,
"assignee_user": {
"id": 201,
"email": "jane.doe@example.com",
"name": "Jane Doe",
"firstname": "Jane",
"lastname": "Doe",
"meta": {
"sso": "sso-link",
"profile_picture_url": "https://www.example.com/images/jane.jpg"
}
},
"channel": "Email",
"closed_datetime": "2024-08-21T19:00:00Z",
"created_datetime": "2024-08-21T08:30:00Z",
"customer": {
"id": 301,
"email": "customer301@example.com",
"name": "John Smith",
"firstname": "John",
"lastname": "Smith"
},
"excerpt": "Urgent issue regarding account access...",
"external_id": "EXT-1001",
"from_agent": false,
"integrations": {
"CRM": {
"customer_id": "1001",
"interaction_count": 5
}
},
"is_unread": true,
"language": "en",
"last_message_datetime": "2024-08-21T18:45:00Z",
"last_received_message_datetime": "2024-08-21T18:44:00Z",
"messages_count": 5,
"meta": {
"priority": "high",
"category": "account issue"
},
"opened_datetime": "2024-08-21T09:00:00Z",
"snoozed_datetime": null,
"status": "Closed",
"subject": "Account Access Problem",
"tags": [
{
"id": 101,
"name": "urgent",
"uri": "https://www.example.com/tags/urgent",
"decoration": {
"color": "#FF0000"
}
},
{
"id": 102,
"name": "account-issue",
"uri": "https://www.example.com/tags/account-issue",
"decoration": {
"color": "#0000FF"
}
}
],
"spam": false,
"trashed_datetime": null,
"updated_datetime": "2024-08-21T18:50:00Z",
"via": "web",
"uri": "https://www.example.com/tickets/1001"
},
{
"id": 1002,
"assignee_user": {
"id": 202,
"email": "tom.black@example.com",
"name": "Tom Black",
"firstname": "Tom",
"lastname": "Black",
"meta": {
"sso": null,
"profile_picture_url": null
}
},
"channel": "Phone",
"closed_datetime": null,
"created_datetime": "2024-08-21T10:00:00Z",
"customer": {
"id": 302,
"email": "customer302@example.com",
"name": "Alice Johnson",
"firstname": "Alice",
"lastname": "Johnson"
},
"excerpt": "Inquiry about billing adjustments...",
"external_id": "EXT-1002",
"from_agent": true,
"integrations": {
"BillingSystem": {
"account_id": "302",
"last_payment_date": "2024-08-15"
}
},
"is_unread": false,
"language": "es",
"last_message_datetime": "2024-08-21T15:30:00Z",
"last_received_message_datetime": "2024-08-21T15:29:00Z",
"messages_count": 3,
"meta": {
"priority": "medium",
"category": "billing"
},
"opened_datetime": "2024-08-21T10:15:00Z",
"snoozed_datetime": null,
"status": "Open",
"subject": "Billing Adjustment Request",
"tags": [
{
"id": 103,
"name": "billing",
"uri": "https://www.example.com/tags/billing",
"decoration": {
"color": "#00FF00"
}
}
],
"spam": null,
"trashed_datetime": null,
"updated_datetime": "2024-08-21T15:35:00Z",
"via": "phone",
"uri": "https://www.example.com/tickets/1002"
}
],
"object": "list",
"uri": "/tickets",
"meta": {
"prev_cursor": null,
"next_cursor": null
}
}
}
Raw Request
Send raw HTTP request to Gorgias API. | key: rawRequest
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Data | The HTTP body payload to send to the URL. | {"exampleKey": "Example Data"} |
| Debug Request | Enabling this flag will log out the current request. | false |
| File Data | File Data to be sent as a multipart form upload. | [{key: "example.txt", value: "My File Contents"}] |
| File Data File Names | File names to apply to the file data inputs. Keys must match the file data keys above. | |
| Form Data | The Form Data to be sent as a multipart form upload. | [{"key": "Example Key", "value": new Buffer("Hello World")}] |
| Header | A list of headers to send with the request. | User-Agent: curl/7.64.1 |
| Max Retry Count | The maximum number of retries to attempt. Specify 0 for no retries. | 0 |
| Method | The HTTP method to use. | |
| Query Parameter | A list of query parameters to send with the request. This is the portion at the end of the URL similar to ?key1=value1&key2=value2. | |
| Response Type | The type of data you expect in the response. You can request json, text, or binary data. | json |
| Retry On All Errors | If true, retries on all erroneous responses regardless of type. This is helpful when retrying after HTTP 429 or other 3xx or 4xx errors. Otherwise, only retries on HTTP 5xx and network errors. | false |
| Retry Delay (ms) | The delay in milliseconds between retries. This is used when 'Use Exponential Backoff' is disabled. | 0 |
| Timeout | The maximum time that a client will await a response to its request | 2000 |
| URL | Input the path only (/tickets), The base URL is already included (https://<YOUR_DOMAIN>.gorgias.com/api). For example, to connect to https://<YOUR_DOMAIN>.gorgias.com/api/tickets, only /tickets is entered in this field. | /tickets |
| Use Exponential Backoff | Specifies whether to use a pre-defined exponential backoff strategy for retries. When enabled, 'Retry Delay (ms)' is ignored. | false |
Search
Search for resources. | key: search
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Query | Text query used to search for resources. | user@example.com |
| Size | Maximum number of results returned. | 10 |
| Type | The type of object to search for. | agent |
{
"data": {}
}
Update Customer
Update a customer. | key: updateCustomer
| Input | Notes | Example |
|---|---|---|
| Channels | The customer's contact channels. See https://developers.gorgias.com/reference/update-customer for more information. | |
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
Primary email address of the customer. | john@example.com | |
| External ID | ID of the customer in a foreign system (Stripe, Aircall, etc...). This field is not used by Gorgias, feel free to set it as you wish. | customer-84203241 |
| Customer ID | ID of the customer to update. | 3924 |
| Language | The customer's preferred language (format: ISO_639-1). | en |
| Name | Full name of the customer. | John Smith |
| Timezone | The customer's preferred timezone (format: IANA timezone name). | UTC |
{
"data": {
"id": 3924,
"created_datetime": "2019-04-13T03:27:56.973873",
"email": "john@example.com",
"external_id": "customer-84203241",
"firstname": "John",
"integrations": {
"6": {
"orders": [
{
"id": 772803526679,
"total_tax": "0.02",
"created_at": "2018-12-04T03:29:37-08:00",
"line_items": [
{
"id": 1760305053719,
"sku": "0987654321",
"name": "Acidulous candy",
"grams": 10,
"price": "0.10",
"title": "Acidulous candy",
"taxable": true,
"quantity": 1,
"price_set": {
"shop_money": {
"amount": "0.10",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.10",
"currency_code": "USD"
}
},
"tax_lines": [
{
"rate": 0.2,
"price": "0.02",
"title": "TVA",
"price_set": {
"shop_money": {
"amount": "0.02",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.02",
"currency_code": "USD"
}
}
}
],
"product_id": 8345093387,
"variant_id": 28442938955,
"total_discount": "0.00",
"requires_shipping": true,
"fulfillment_status": null,
"total_discount_set": {
"shop_money": {
"amount": "0.00",
"currency_code": "USD"
},
"presentment_money": {
"amount": "0.00",
"currency_code": "USD"
}
},
"fulfillment_service": "manual",
"fulfillable_quantity": 1
}
],
"contact_email": "marie@gorgias.io",
"billing_address": {
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"country_code": "US",
"province_code": "CA"
}
}
],
"customer": {
"id": 667928133655,
"note": "",
"tags": "",
"email": "marie@gorgias.io",
"firstname": "Marie",
"lastname": "Curie",
"orders_count": 1,
"default_address": {
"id": 707106144279,
"zip": "94103",
"city": "SAN FRANCISCO",
"name": "Marie Curie",
"country": "United States",
"default": true,
"address1": "52 Washburn Street",
"address2": "",
"province": "California",
"last_name": "Curie",
"first_name": "Marie",
"customer_id": 667928133655,
"country_code": "US",
"country_name": "United States",
"province_code": "CA"
}
},
"__integration_type__": "shopify"
}
},
"language": "fr",
"lastname": "Smith",
"name": "John Smith",
"note": "Our best customer.",
"timezone": "UTC",
"updated_datetime": "2019-09-25T06:18:22.839271"
}
}
Update Customer Data
Set a customer's data. | key: updateCustomerData
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Data | The customer data. | Your customer data here |
| Debug Request | Enabling this flag will log out the current request. | false |
| Customer ID | ID of the customer to update. | 3924 |
| Version | The date of the customer data. If we already have a more recent version, the request will be ignored. | 2022-05-13T12:34:21.918927 |
{
"data": {
"message": "Success"
}
}
Update Ticket
Update a ticket. | key: updateTicket
| Input | Notes | Example |
|---|---|---|
| Assignee Team | The team assigned to the ticket. | |
| Assignee User | The user assigned to the ticket. | |
| Assignee User ID | The team assigned to the ticket. | |
| Closed Datetime | When the ticket was closed. | 2020-01-27T10:42:21.468912 |
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Customer | The customer linked to the ticket. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| External ID | External ID of the ticket in a foreign system. This field is not used by Gorgias, feel free to set it as you wish. | RETURN#4213 |
| From Agent | Whether the first message of the ticket was sent by your company to a customer, or the opposite. | true |
| Ticket ID | The ID of the ticket. | |
| Is Unread | Whether the ticket is unread for you. | true |
| Language | The language primarily used in the ticket. The language is automatically detected on the first messages by Gorgias if not set explicitly.Once the language has been set, it won't be updated according to future messages. | en |
| Last Message Datetime | When the last message was sent. | 2020-01-27T10:42:21.468912 |
| Last Received Message Datetime | When the last customer's message was sent. | 2020-01-27T10:42:21.468912 |
| Meta | Data associated with the ticket. You can use this field to store structured information (key-value data) about the ticket. | key1:value1 |
| Opened Datetime | When the ticket was opened for the first time by a user. | 2020-01-27T10:42:21.468912 |
| Snooze Datetime | When the ticket will be re-opened. | 2020-01-27T10:42:21.468912 |
| Spam | Whether the ticket is considered as spam or not. | false |
| Status | The status of the ticket. | open |
| Tags | Tags linked to the ticket. | tag1 |
| Trashed Datetime | When the ticket was moved to the trash. | 2020-01-27T10:42:21.468912 |
| Updated Datetime | When the ticket was lastly updated. | 2020-01-27T10:42:21.468912 |
| Via | How the first message of the ticket has been received or sent from Gorgias. |
{
"data": {
"id": 2201,
"assignee_user": {
"id": 450,
"email": "sara.jones@example.com",
"name": "Sara Jones",
"firstname": "Sara",
"lastname": "Jones",
"meta": {
"sso": "sso-jones-link",
"profile_picture_url": "https://www.example.com/images/sara.jpg"
}
},
"channel": "Web",
"closed_datetime": null,
"created_datetime": "2024-08-22T10:00:00Z",
"customer": {
"id": 550,
"channels": [
{
"id": 1
}
],
"email": "customer550@example.com",
"external_id": "550-external",
"firstname": "Michael",
"integrations": {
"CRM": {
"customer_level": "Silver",
"interaction_count": 10
}
},
"lastname": "Brown",
"name": "Michael Brown",
"note": "Needs follow-up on previous issue"
},
"external_id": "EXT-2201",
"from_agent": true,
"is_unread": true,
"language": "en",
"last_message_datetime": "2024-08-22T10:15:00Z",
"last_received_message_datetime": "2024-08-22T10:14:00Z",
"messages": [
{
"id": 3301,
"attachments": [
{
"url": "https://www.example.com/attachments/info.pdf",
"name": "Details.pdf",
"size": 2048,
"content_type": "application/pdf",
"public": true,
"extra": "Detailed document"
}
],
"body_html": "<p>Thank you for reaching out. Please see the attached document for more information.</p>",
"body_text": "Thank you for reaching out. Please see the attached document for more information.",
"channel": "Email",
"created_datetime": "2024-08-22T10:15:00Z",
"external_id": "MSG-3301",
"failed_datetime": null,
"from_agent": true,
"integration_id": 501,
"last_sending_error": null,
"message_id": "MSG-3301",
"receiver": {
"id": 550,
"email": "customer550@example.com",
"name": "Michael Brown",
"firstname": "Michael",
"lastname": "Brown",
"meta": null
},
"rule_id": 101,
"sender": {
"id": 450,
"email": "sara.jones@example.com",
"name": "Sara Jones",
"firstname": "Sara",
"lastname": "Jones",
"meta": null
},
"sent_datetime": "2024-08-22T10:15:00Z",
"source": {
"type": "Email",
"to": [
{
"name": "Michael Brown",
"address": "customer550@example.com"
}
],
"cc": [],
"bcc": [],
"from": {
"name": "Sara Jones",
"address": "sara.jones@example.com"
}
},
"stripped_html": "<p>Thank you for reaching out. Please see the attached document for more information.</p>",
"stripped_text": "Thank you for reaching out. Please see the attached document for more information.",
"subject": "Further Information Required",
"ticket_id": 2201,
"via": "Email",
"uri": "https://www.example.com/messages/3301"
}
],
"meta": {
"issue_type": "technical",
"priority": "high"
},
"opened_datetime": "2024-08-22T10:01:00Z",
"reply_options": "Reply, Forward, Archive",
"satisfaction_survey": {
"id": 402,
"body_text": "Please rate our service.",
"created_datetime": "2024-08-22T12:30:00Z",
"customer_id": 550,
"meta": {
"survey_type": "email"
},
"score": null,
"scored_datetime": null,
"sent_datetime": null,
"should_send_datetime": "2024-08-23T12:30:00Z",
"ticket_id": 2201
},
"snoozed_datetime": null,
"spam": false,
"status": "Open",
"subject": "Support Inquiry",
"tags": [
{
"id": 301,
"name": "Technical Support",
"uri": "https://www.example.com/tags/technical-support",
"decoration": {
"color": "#007BFF"
}
}
],
"trashed_datetime": null,
"updated_datetime": "2024-08-22T10:20:00Z",
"via": "Web",
"uri": "https://www.example.com/tickets/2201"
}
}
Update Ticket Custom Fields
Update a ticket's custom fields values. | key: updateTicketCustomFields
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Custom Fields | Custom fields to update. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| Ticket ID | The ID of the ticket. | 1234567890 |
{
"data": [
{
"field": {
"id": 101,
"external_id": "CF-101",
"object_type": "ticket",
"label": "Urgency Level",
"description": "A measure of how urgently the issue needs to be resolved.",
"priority": 5,
"required": true,
"managed_by": "system",
"definition": {
"input_settings": "DROPDOWN",
"data_type": "integer"
},
"created_datetime": "2024-01-01T12:00:00Z",
"updated_datetime": "2024-08-21T12:30:00Z",
"deactivated_datetime": null
},
"value": "High",
"prediction": {
"predicted": "Medium",
"confidence": 85,
"display": true,
"confirmed": false,
"modified": true
}
},
{
"field": {
"id": 102,
"external_id": "CF-102",
"object_type": "ticket",
"label": "Resolution Time",
"description": "Estimated time to resolve the ticket.",
"priority": 3,
"required": false,
"managed_by": "admin",
"definition": {
"input_settings": "INPUT_NUMBER",
"data_type": "integer"
},
"created_datetime": "2024-01-02T13:00:00Z",
"updated_datetime": "2024-08-21T14:00:00Z",
"deactivated_datetime": null
},
"value": "48",
"prediction": {
"predicted": "72",
"confidence": 70,
"display": true,
"confirmed": true,
"modified": false
}
},
{
"field": {
"id": 103,
"external_id": "CF-103",
"object_type": "ticket",
"label": "Customer Satisfaction",
"description": "Predicted customer satisfaction based on resolution.",
"priority": 2,
"required": true,
"managed_by": "system",
"definition": {
"input_settings": "INPUT",
"data_type": "integer"
},
"created_datetime": "2024-01-03T14:00:00Z",
"updated_datetime": "2024-08-21T15:00:00Z",
"deactivated_datetime": null
},
"value": "5",
"prediction": {
"predicted": "6",
"confidence": 65,
"display": true,
"confirmed": false,
"modified": true
}
}
]
}
Upload Files
Upload a file or several files. | key: uploadFiles
| Input | Notes | Example |
|---|---|---|
| Connection | Select the Gorgias connection type for this request: OAuth2 or API Key. | |
| Debug Request | Enabling this flag will log out the current request. | false |
| File | A file to upload, this should be a reference to binary data from a previous step. The name of this parameter can be replaced with the label of the file you want to have once uploaded. E.g: package-damaged.png. | SGVsbG8sIFdvcmxkIQ== |
| Type | The type of file to upload. If not specified, the file will be uploaded as a private attachment. | attachment |
{
"data": [
{
"content_type": "image/jpeg",
"size": 1500,
"name": "vacation_photo.jpg",
"url": "https://www.example.com/uploads/vacation_photo.jpg"
}
]
}