---
title: "Link an image node to an existing image file."
method: POST
path: "/api/image/link"
tags: ["Images"]
---

# Link an image node to an existing image file.

`POST /api/image/link`

## Request

- Base URL: `https://passivelogic.com` (the document declares no server; this is the origin it was published from)
- URL: `https://passivelogic.com/api/image/link`
- Auth: one of:
  - API key in header `X-PL-AUTH`
  - API key in header `Authorization: PL-API-KEY`
  - API key in header `PL-API-KEY`
  - HTTP basic
- TypeScript: <https://skmtc.dev/passivelogic/apis/passivelogic-http-api/docs/api/image/link/post.ts> (a function with typed inputs; its response is checked against the schema)

Associates an existing `Image` node with an already-uploaded image file without re-uploading the file data. The user must have write access to the target image, and linking images across AuthGroups is not allowed.

## Request body

- LinkImageData: Data required to link an image node to an existing image file.
  - `targetID` string, uuid, required: UUID of the quantum image node to update.
  - `sourceID` string, uuid, required: UUID of a quantum image node already connected to the desired image file.

## Response `200`

OK

- ImageUploadResponse: Image response definition
  - `message` string, required: Informative message relating to image upload. Updated image url with cache bust.
  - `url` string, nullable

---

[API](https://skmtc.dev/passivelogic/apis/passivelogic-http-api.md) - [All operations](https://skmtc.dev/passivelogic/apis/passivelogic-http-api/llms.txt) - [OpenAPI document](https://skmtc.dev/passivelogic/apis/passivelogic-http-api/revisions/28fce63bcdbb?raw)
