---
title: "Update a custom External API."
method: PUT
path: "/api/v1/projects/{projectId}/actions/external-apis/{integrationId}"
tags: ["Agent Actions"]
---

# Update a custom External API.

`PUT /api/v1/projects/{projectId}/actions/external-apis/{integrationId}`

## Request

- Base URL: `https://app.customgpt.ai`
- URL: `https://app.customgpt.ai/api/v1/projects/{projectId}/actions/external-apis/{integrationId}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/poll-the-people/apis/customgpt-ai/docs/api/v1/projects/:projectId/actions/external-apis/:integrationId/put.ts> (a function with typed inputs; its response is checked against the schema)

Renames it, replaces its API key, or enables/disables it. At most 5 External APIs can be active at once.

## Path parameters

- `projectId` integer, required
- `integrationId` integer, required

## Request body

- object
  - `name` string: Display name, up to 120 characters.
  - `api_key` string: Replacement credential.
  - `is_enabled` boolean: Enable or disable the External API. At most 5 can be enabled at once.

## Response `200`

The External API.

- object
  - `status` 'error' | 'success': The status of the response
  - `data` object
    - `external_api` ExternalApi
      - `id` integer: External API identifier.
      - `name` string: Display name.
      - `is_enabled` boolean: Whether the agent can call this API.
      - `host` string: Host taken from the OpenAPI schema servers.
      - `base_url` string: Base URL the agent calls.
      - `auth_type` 'bearer' | 'header' | 'query', nullable: Authentication scheme detected in the OpenAPI schema.
      - `auth_key_name` string, nullable: Header or query parameter that carries the key.
      - `has_openapi` boolean: Whether an OpenAPI schema is stored.
      - `openapi_metadata` object, nullable: Summary of the stored OpenAPI schema.
        - `title` string, nullable
        - `version` string, nullable
        - `endpoint_count` integer
      - `last_used_at` string, date-time, nullable: Last time the agent called this API.
      - `created_at` string, date-time, nullable: Creation time.

## Other responses

- `400`: Bad Argument
- `401`: API Token is either missing or invalid
- `404`: External API not found
- `422`: Unsupported Argument
- `500`: Internal Server Error

## Changes

- **2026-11-03** `77aab4354382`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/poll-the-people/apis/customgpt-ai/changes/api/v1/projects/:projectId/actions/external-apis/:integrationId/put.md)

---

[API](https://skmtc.dev/poll-the-people/apis/customgpt-ai.md) - [All operations](https://skmtc.dev/poll-the-people/apis/customgpt-ai/llms.txt) - [OpenAPI document](https://skmtc.dev/poll-the-people/apis/customgpt-ai/revisions/77aab4354382?raw)
