---
title: "Attach Tool Registry External ID"
method: POST
path: "/api/public/v2/tool-registry/{tool_id}/external-ids"
tags: ["external-ids"]
---

# Attach Tool Registry External ID

`POST /api/public/v2/tool-registry/{tool_id}/external-ids`

## Path parameters

- `tool_id` integer, required

## Request body

- AttachExternalIdRequest — External ID mapping to attach to an entity.
  - `source` string, required — The external system or namespace that owns the ID.
  - `external_id` string, required — The identifier for this entity in the external system.

## Response `201`

External ID attached

- ExternalIdAttachResponse
  - `success` true, required
  - `external_id` ExternalId, required — Customer-defined mapping between a PromptLayer entity and an external system identifier.
    - `source` string, required — The external system or namespace that owns the ID.
    - `external_id` string, required — The identifier for this entity in the external system.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `404` — Entity Not Found
- `409` — Conflict
- `422` — Validation Error

---

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