# Get Selfie

{% hint style="info" %}
**URL Base**:

* UAT: <mark style="color:blue;">`https://api.cadastro.uat.unico.app`</mark>.
* Production: <mark style="color:blue;">`https://api.cadastro.unico.app`</mark>.
  {% endhint %}

## GetSelfie

> Endpoint to retrieve the selfie from the Unico process.

```json
{"openapi":"3.0.0","info":{"title":"Get Selfie","version":"1.0.0"},"servers":[{"url":"https://api.cadastro.uat.unico.app"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}},"paths":{"/client/v1/process/{id}/selfie":{"get":{"summary":"GetSelfie","description":"Endpoint to retrieve the selfie from the Unico process.","parameters":[{"name":"id","in":"path","required":true,"description":"Process ID.","schema":{"type":"string"}}],"responses":{"200":{"description":"Selfie obtained successfully.","content":{"application/json":{"schema":{"type":"object","properties":{"fileContents":{"type":"string","description":"Content of the selfie encoded in base64."},"contentType":{"type":"string","description":"Type of the image content (jpeg or png)."}}}}}},"400":{"description":"When the process ID is invalid.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","description":"Error code."},"message":{"type":"string","description":"Error description."},"details":{}}}}}},"401":{"description":"Access-token error.","content":{"application/json":{"schema":{"type":"string","description":"Error description."}}}},"403":{"description":"When the service account does not have permission to obtain the selfie.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","description":"Error code."},"message":{"type":"string","description":"Error description."},"details":{}}}}}},"404":{"description":"When the process could not be found.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","description":"Error code."},"message":{"type":"string","description":"Error description."},"details":{}}}}}}}}}}}
```

{% hint style="warning" %}
**Important**:

* The permission to obtain the user's selfie will depend on Unico's internal evaluation. Understand with the person responsible for your project whether you will be able to consume this service;
* It is only possible to get the selfie with the watermark;
* If you use the Smart Revalidation capability (flow `idsmart`), we will not return the user's selfie.
  {% endhint %}

### Errors


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://devcenter.unico.io/unico-idcloud/by-unico-integration/by-unico-api/api-reference/get-selfie.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
