---
title: "Update Connection"
method: PUT
path: "/connections/{projectId}/{connectionId}"
tags: ["Connections"]
---

# Update Connection

`PUT /connections/{projectId}/{connectionId}`

## Request

- Base URL: `https://partner.peaka.studio/api/v1`
- URL: `https://partner.peaka.studio/api/v1/connections/{projectId}/{connectionId}`
- Auth: HTTP bearer

Updates the specified Connection. You can modify the name, credentials, or other parameters. The request body follows the same structure as the Create Connection endpoint.

## Path parameters

- `projectId` string, required
- `connectionId` string, required

## Request body

- ConnectionRequest
  - `name` string: Name of the connection given by the user
  - `type` string: Type of the connection: the `connectionType` value /connections/config returns for it, e.g. `stripe`, `airtable`, `ORACLE`. `connectionType` is accepted as another name for this field.
  - `credential` object: Credential object for the connection. Its structure is dependent on the connection type and can be fetched by following url: /connections/config
  - `connectionCallback` string: The url to redirect to after an oauth connection is established.

## Response `200`

Connection updated successfully

- Connection
  - `id` string: Connection ID
  - `name` string: Name of the connection
  - `type` string: Type of connection. Example: airtable for AirTable, stripe for Stripe, hubspot_access_token for HubSpot (with Access Token), etc. Exact list can be fetched by following url: /connections/config
  - `url` string: Oauth callback url if the connection is Oauth based.

---

[API](https://skmtc.dev/peaka/apis/peaka-gateway-api.md) · [All operations](https://skmtc.dev/peaka/apis/peaka-gateway-api/llms.txt) · [OpenAPI document](https://skmtc.dev/peaka/apis/peaka-gateway-api/revisions/e68b033a22d5?raw)
