---
title: "Add an external reference"
method: POST
path: "/v1/workspaces/{workspace}/galleries/{galleryId}/external-references"
---

# Add an external reference

`POST /v1/workspaces/{workspace}/galleries/{galleryId}/external-references`

## Request

- Base URL: `https://api.uploads.sh`
- URL: `https://api.uploads.sh/v1/workspaces/{workspace}/galleries/{galleryId}/external-references`
- Auth: HTTP bearer

## Request body

- GalleryReferenceCreate
  - `expectedVersion` integer, required
  - `provider` string, required
  - `coordinate` string, required

## Response `200`

The reference already existed and is returned unchanged.

## Other responses

- `201`: The reference was created.
- `400`: Invalid request.
- `401`: Missing or invalid credential.
- `403`: The credential lacks the required scope or role.
- `404`: The resource was not found.
- `409`: The request conflicts with current resource state.
- `429`: The workspace rate limit or upload budget was exceeded.

---

[API](https://skmtc.dev/uploads/apis/uploads-sh-api.md) · [All operations](https://skmtc.dev/uploads/apis/uploads-sh-api/llms.txt) · [OpenAPI document](https://skmtc.dev/uploads/apis/uploads-sh-api/revisions/6df242babacd?raw)
