---
title: Get the selfie
description: GET /v1/processes/{id}/selfie — read the selfie captured for a process, how long it is available and the errors.
canonical: https://developer.unico.io/human-plugin/api-reference/get-selfie
locale: en
generated_by: markdown-export
---

# Get the selfie

Read the selfie captured for a process, by the id Human Plugin returned on create.

`GET /v1/processes/{id}/selfie`

`id` is the UUID from the create response. The request has no body and no query parameters.

```bash
curl http://human-plugin.internal:8080/v1/processes/17e4546e-6109-4240-8c0b-4ba98474a104/selfie
```

Human Plugin does not keep a copy of the selfie: each call fetches it again.

## Response

`200 OK`, with the image in base64 and its type:

```json
{
  "fileContents": "/9j/4AAQSkZJRgABAQAAAQABAAD…",
  "contentType": "image/jpeg"
}
```

To save it as a file:

```bash
curl -s http://human-plugin.internal:8080/v1/processes/17e4546e-6109-4240-8c0b-4ba98474a104/selfie \
  | jq -r .fileContents | base64 -d > selfie.jpg
```

## Availability

- There is a selfie only for a process that had one: sent in `imageBase64` or captured from the person.
- With a Journey flow, the selfie exists only after the person captures it. Until then the request is refused with `400` and a `message` that starts with `process state must be finished`. [Read the process](/human-plugin/api-reference/get-process) first, and get the selfie once it is `PROCESS_STATE_FINISHED`.
- The selfie is available for a limited time after the process finishes. If you need it later, store it from this response.

## Handling the image

The selfie is biometric data. Human Plugin never stores or logs it, and the response is sent with `Cache-Control: no-store`. Keep it out of your gateway and application logs too.

## Errors

| Status | `message` | Meaning |
| --- | --- | --- |
| 400 | `process state must be finished…` | A Journey process whose capture has not finished yet. Read the process first |
| 404 | `PROCESS_NOT_FOUND` | The id is not a UUID or is unknown |
| 404 | `SELFIE_NOT_FOUND` | The process has no selfie: it had no capture, it failed before it started, or the selfie is no longer available |
| 4xx | The refusal `message` | The request was refused. The reason is in `message` and `details` |
| 502 | `UPSTREAM_UNAVAILABLE` | The selfie could not be fetched in time. Retry later |
| 503 | `DATABASE_UNAVAILABLE` | The database failed. Retry later |

Reads are safe to retry. A `404` does not change on a retry.

## Next

[Process lifecycle](/human-plugin/api-reference/process-lifecycle)