> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hightouch.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Destination

> Update an existing destination

Patch a destination based on its Hightouch ID



## OpenAPI

````yaml https://api.hightouch.io/api/swagger.json patch /destinations/{destinationId}
openapi: 3.0.0
info:
  title: Hightouch API
  version: 1.0.0
  description: Hightouch Public Rest API to access syncs, models, sources and destinations
  contact:
    name: Hightouch
    url: https://hightouch.com
servers:
  - url: https://api.hightouch.com/api/v1
security: []
paths:
  /destinations/{destinationId}:
    patch:
      summary: Update Destination
      description: |-
        Update an existing destination

        Patch a destination based on its Hightouch ID
      operationId: UpdateDestination
      parameters:
        - description: The destination's ID
          in: path
          name: destinationId
          required: true
          schema:
            type: number
            format: double
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DestinationUpdate'
            example:
              name: Webhook Website code 201
              configuration:
                url: http://httpstat.us/201
                methodKey: url
      responses:
        '200':
          description: Ok
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/Destination'
                  - $ref: '#/components/schemas/ValidateErrorJSON'
                  - $ref: '#/components/schemas/InternalServerError'
              examples:
                Example 1:
                  value:
                    id: 1
                    name: Webhook Website code 201
                    slug: webhookwebsite
                    workspaceId: 1
                    createdAt: '2022-11-09T18:39:24.957Z'
                    updatedAt: '2022-12-10T00:14:17.938Z'
                    type: webhook
                    syncs: []
                    configuration:
                      url: http://httpstat.us/201
                      methodKey: url
        '401':
          description: Unauthorized
        '404':
          description: Not found
        '422':
          description: Validation Failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidateErrorJSON'
        '500':
          description: Something went wrong
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InternalServerError'
      security:
        - bearerAuth: []
components:
  schemas:
    DestinationUpdate:
      description: The input for updating a Destination
      properties:
        name:
          type: string
          description: The destination's name
        configuration:
          properties: {}
          additionalProperties: {}
          type: object
          description: >-
            The destination's configuration. This specifies general metadata
            about destination, like hostname and username.

            Hightouch will be using this configuration to connect to
            destination.


            The schema depends on the destination type.


            Consumers should NOT make assumptions on the contents of the

            configuration. It may change as Hightouch updates its internal code.
      type: object
      additionalProperties: false
    Destination:
      description: >-
        The service receiving your data (e.g. Salesforce, Hubspot, Customer.io,
        or a

        SFTP server)
      properties:
        id:
          type: number
          format: double
          description: The destination's id
        name:
          type: string
          description: The destination's name
        slug:
          type: string
          description: The destination's slug
        workspaceId:
          type: number
          format: double
          description: The id of the workspace that the destination belongs to
        createdAt:
          type: string
          format: date-time
          description: The timestamp when the destination was created
        updatedAt:
          type: string
          format: date-time
          description: The timestamp when the destination was last updated
        type:
          type: string
          description: The destination's type (e.g. salesforce or hubspot).
        configuration:
          properties: {}
          additionalProperties: {}
          type: object
          description: >-
            The destination's configuration. This specifies general metadata
            about destination, like hostname and username.

            Hightouch will be using this configuration to connect to
            destination.


            The schema depends on the destination type.


            Consumers should NOT make assumptions on the contents of the

            configuration. It may change as Hightouch updates its internal code.
        syncs:
          items:
            type: number
            format: double
          type: array
          description: A list of syncs that sync to this destination.
      required:
        - id
        - name
        - slug
        - workspaceId
        - createdAt
        - updatedAt
        - type
        - configuration
        - syncs
      type: object
      additionalProperties: false
    ValidateErrorJSON:
      properties:
        message:
          type: string
          enum:
            - Validation failed
          nullable: false
        details:
          properties: {}
          additionalProperties: {}
          type: object
      required:
        - message
        - details
      type: object
      additionalProperties: false
    InternalServerError:
      type: string
      enum:
        - Internal Server Error
      nullable: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Bearer

````