> ## Documentation Index
> Fetch the complete documentation index at: https://docs.snipp.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# Add to Album

Add one or more files to an existing album post. Use this to grow a post's file list in place. The post's share code, privacy, title, and description stay the same.

## Headers

| Header             | Required | Description                                                                                                                                                    |
| ------------------ | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `relay-key`        | Yes      | Your Relay key                                                                                                                                                 |
| `post-code`        | Yes      | The share code of the post to append to                                                                                                                        |
| `include-metadata` | No       | `true` to keep file metadata. Omitted or `false` strips it (default).                                                                                          |
| `priority`         | No       | `false` to opt appended video files out of priority (adaptive) streaming. Omitted or `true` keeps it on (default), subject to your remaining priority minutes. |

## Behavior

* You must own the post.
* The post cannot be moderated. Moderated posts reject modifications.
* Albums cap at **9 files total**. Requests that would exceed the cap are rejected.
* Newly added files inherit the post's existing privacy. If the post is **private**, returned `url`s are signed with a 24-hour expiry.
* Video files (`.mp4`, `.mov`, `.mkv`) are remuxed to MP4 with `+faststart`. See [File Types](/concepts/file-types) for details.
* Metadata (EXIF on images, container metadata on videos) is stripped by default. Send `include-metadata: true` to keep it.
* Appended videos use priority (adaptive) streaming by default, spending [priority minutes](/concepts/plans). Send `priority: false` to add them in standard quality instead. The post's `priority` field is `true` when any file in the album is on adaptive streaming.
* Each new file is auto-moderated. If any file (or the post's title or description) is flagged, the entire post, including existing files, is quarantined and marked `moderated`.

## Examples

Add two images to an existing album:

```bash theme={null}
curl -X POST "https://relay.snipp.gg/appendUpload" \
  -H "relay-key: YOUR_RELAY_KEY" \
  -H "post-code: AbCd1234" \
  -F "file=@photo4.png" \
  -F "file=@photo5.png"
```

Convert a single-file post into an album by appending a second file:

```bash theme={null}
curl -X POST "https://relay.snipp.gg/appendUpload" \
  -H "relay-key: YOUR_RELAY_KEY" \
  -H "post-code: AbCd1234" \
  -F "file=@second.png"
```

## Responses

```json theme={null}
{
  "message": "Files added to album successfully.",
  "post": {
    "code": "AbCd1234",
    "url": "https://snipp.gg/p/AbCd1234",
    "postPrivacy": "public",
    "fileCount": 5,
    "priority": false
  },
  "files": [
    {
      "index": 3,
      "fileName": "a1b2c3d4e5f6789012345678abcdef01.png",
      "url": "https://i.snipp.gg/123456789012345678/a1b2c3d4e5f6789012345678abcdef01.png",
      "size": 2487312,
      "size_formatted": "2.37 MB",
      "mime_type": "image/png",
      "status": "success",
      "dimensions": { "width": 1920, "height": 1080 }
    }
  ]
}
```

If some files fail, a `failed` array is included alongside `files`:

```json theme={null}
{
  "failed": [
    {
      "index": 4,
      "error": "Album cap of 9 files exceeded",
      "status": "failed"
    }
  ]
}
```
