---
title: "Import a recipient photo from a public URL"
method: POST
path: "/artwork/import-photo"
tags: ["Artwork"]
---

# Import a recipient photo from a public URL

`POST /artwork/import-photo`

## Request

- Base URL: `https://gtmswag.com/api/v1`
- URL: `https://gtmswag.com/api/v1/artwork/import-photo`
- Auth: HTTP bearer

Fetches a direct public HTTPS image (PNG, JPEG or WebP, up to 5 MiB) the customer supplied with explicit permission to use it (`rightsConfirmed:true`), and returns a private portrait asset for `recipient.photo`. Profile pages such as LinkedIn cannot be imported; use `photo:{source:"linkedin"}` for staff sourcing.

## Request body

- object
  - `url` string, uri, required: Direct public HTTPS PNG/JPEG/WebP URL, up to 5 MiB.
  - `rightsConfirmed` true, required: True only with explicit photo-use permission.

## Response `201`

Success: `{"data": Asset}`.

- AssetResponse: The success body: `{"data": Asset}`.
  - `data` Asset, required: An uploaded private file; use its `asset_` ID in campaigns and gifts.
    - `id` string, required
    - `mime` string, required
    - `bytes` integer, required

## Other responses

- `400`: Bad request: `VALIDATION_ERROR`, `PHOTO_URL`, `PHOTO_DOWNLOAD`, `PORTRAIT_RESOLUTION`, `INVALID_JSON`. Each example says when.
- `401`: Not authenticated: `AUTH_REQUIRED`. no credentials, or an OAuth token on a route that only takes workspace keys; the key is malformed, unknown or revoked.
- `403`: Forbidden: `DEMO_LIMITED`. Each example says when.
- `413`: Request too large: `INVALID_REQUEST`. the body exceeds 1 MiB.
- `415`: Unsupported media type: `PHOTO_TYPE`, `INVALID_REQUEST`. Each example says when.
- `429`: Too many requests: `ARTWORK_QUOTA`, `RATE_LIMIT`. Each example says when.
- `default`: Any other refusal or failure, such as 403 CSRF (a cross-origin `Origin` header), 403 HTTPS_REQUIRED or 500 INTERNAL_ERROR, with what to do next.

---

[API](https://skmtc.dev/gtmswag/apis/gtm-swag-api.md) · [All operations](https://skmtc.dev/gtmswag/apis/gtm-swag-api/llms.txt) · [OpenAPI document](https://skmtc.dev/gtmswag/apis/gtm-swag-api/revisions/9ff86fa99afe?raw)
