---
title: "Update an integration"
method: PUT
path: "/api/integrations/{id}"
tags: ["Integrations"]
---

# Update an integration

`PUT /api/integrations/{id}`

## Path parameters

- `id` integer, required

## Request body

- object
  - `deactivated_datetime` string, date-time, nullable — When the integration was deactivated.
  - `description` string, nullable — Description about the integration.
  - `http` object — Only available for HTTP integrations, defines the configuration of the integration.
    - `form` unknown
    - `headers` unknown
    - `hmac_secret` string — The HMAC secret to use to sign HTTP calls to the external service.
    - `method` 'GET' | 'POST' | 'PUT' | 'DELETE' | 'HEAD' | 'PATCH' — HTTP method expected by the external service.
    - `request_content_type` 'application/json' | 'application/x-www-form-urlencoded' — Content type of the outgoing request to the external service.
    - `response_content_type` 'application/json' — Content type of the incoming response from the external service.
    - `triggers` object — Events that will trigger the request to the external service.
      - `ticket-created` boolean — Whether to trigger the HTTP integration when a ticket is created.
      - `ticket-updated` boolean — Whether to trigger the HTTP integration when a ticket is updated.
      - `ticket-message-created` boolean — Whether to trigger the HTTP integration when a new message is created in a ticket.
      - `ticket-self-unsnoozed` boolean — Whether to trigger the HTTP integration when the snooze delay ends.
      - `ticket-message-failed` boolean — Whether to trigger the HTTP integration when the message fails to send.
      - `ticket-assignment-updated` boolean — Whether to trigger the HTTP integration when the ticket assignee is changed.
      - `ticket-status-updated` boolean — Whether to trigger the HTTP integration when the ticket status is updated.
      - `ticket-handed-over` boolean — Whether to trigger the HTTP integration when a ticket is handed over to another user. Further configuration is required.
    - `url` string, required — URL of the external service. You can use variables like {{ticket.customer.email}} to pass customer data to the integration. Check all properties from a [customer](#the-customer-object), or review the list of [Gorgias variables](https://docs.gorgias.com/macros/macro-variables#gorgias_variables) for inspiration.
  - `name` string, required — Name of the integration. Usually the email address, Facebook page name, etc.

## Response `202`

The updated integration.

- Integration — Integrations connect Gorgias with external services (e.g. Gmail, Shopify, chat systems). There are official Gorgias integrations that can be found in the Integrations page in the helpdesk and there are custom HTTP integrations. Most integrations use HTTP APIs.
  - `id` integer — ID of the integration.
  - `created_datetime` string, date-time, nullable — When the integration was created.
  - `deactivated_datetime` string, date-time, nullable — When the integration was deactivated.
  - `description` string, nullable — Description about the integration.
  - `http` object — Only available for HTTP integrations, defines the configuration of the integration.
    - `form` unknown
    - `method` 'GET' | 'POST' | 'PUT' | 'DELETE' | 'HEAD' | 'PATCH' — HTTP method expected by the external service.
    - `request_content_type` 'application/json' | 'application/x-www-form-urlencoded' — Content type of the outgoing request to the external service.
    - `response_content_type` 'application/json' — Content type of the incoming response from the external service.
    - `triggers` object — Events that will trigger the request to the external service.
      - `ticket-created` boolean — Whether to trigger the HTTP integration when a ticket is created.
      - `ticket-updated` boolean — Whether to trigger the HTTP integration when a ticket is updated.
      - `ticket-message-created` boolean — Whether to trigger the HTTP integration when a new message is created in a ticket.
      - `ticket-self-unsnoozed` boolean — Whether to trigger the HTTP integration when the snooze delay ends.
      - `ticket-message-failed` boolean — Whether to trigger the HTTP integration when the message fails to send.
      - `ticket-assignment-updated` boolean — Whether to trigger the HTTP integration when the ticket assignee is changed.
      - `ticket-status-updated` boolean — Whether to trigger the HTTP integration when the ticket status is updated.
      - `ticket-handed-over` boolean — Whether to trigger the HTTP integration when a ticket is handed over to another user. Further configuration is required.
    - `url` string, required — URL of the external service. You can use variables like {{ticket.customer.email}} to pass customer data to the integration. Check all properties from a [customer](#the-customer-object), or review the list of [Gorgias variables](https://docs.gorgias.com/macros/macro-variables#gorgias_variables) for inspiration.
    - `oauth2` unknown
  - `name` string, required — Name of the integration. Usually the email address, Facebook page name, etc.
  - `type` 'http' — Type of integration.
  - `updated_datetime` string, date-time, nullable — When the integration was last updated.
  - `user` object — User which created this integration.
    - `id` integer — ID of the object
  - `uri` string — URI of the integration.
  - `application_id` string, nullable — ID of the related application.
  - `managed` boolean — Whether integration is managed by Gorgias.
  - `business_hours_id` integer, nullable — The ID of the business hour the phone integration is associated with. If null, the integration will use the default business hours.

---

[API](https://skmtc.net/gorgias/apis/gorgias-rest-api.md) · [All operations](https://skmtc.net/gorgias/apis/gorgias-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/gorgias/gorgias-rest-api/versions/36f2e31f4e81/schema)
