> For the complete documentation index, see [llms.txt](https://legacy-docs.usesmileid.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://legacy-docs.usesmileid.com/further-reading/faqs/what-are-the-image-types-i-can-upload-to-smile-id.md).

# What are the image types I can upload to Smile ID?

There are four image types Smile ID uses to process a job, depending on your product of choice:

* **Selfie** - We strongly recommend using our mobile SDKs to capture these images.
* **Document / ID Card Photo** - Including front and back images.
* **Liveness Images** - For active liveness detection. We strongly recommend using our mobile SDKs to capture these images.
* **Portrait** - Specific to SmartSelfie Comparison. It is a high-quality image of the user from a trusted source (e.g., a passport photo).

## Parameters

| Parameter       | Required | Data Type | Description                                                                      |
| --------------- | -------- | --------- | -------------------------------------------------------------------------------- |
| image\_type\_id | yes      | Integer   | It can be 0-12. The description of each Integer can be found in the table below. |
| image           | optional | String    | A base64 encoded image. Only for types 2/3/6/7.                                  |
| file\_name      | optional | String    | The name of the file being uploaded. Required for image types 0/1/4/5.           |

## Image Types

Use the following chart to declare the `image_type_id` and understand their usage in different job types:

| image\_type\_id | **Indicates**                                    | **Job Type**            | **Image Format** | **Notes**                           |
| --------------- | ------------------------------------------------ | ----------------------- | ---------------- | ----------------------------------- |
| 0               | Selfie image in .jpg file format only            | All                     | File             |                                     |
| 1               | ID card image in .jpg file format only           | All                     | File             |                                     |
| 2               | Base64 encoded selfie image (.jpg only)          | All                     | Base64           |                                     |
| 3               | Base64 encoded ID card image (.jpg only)         | All                     | Base64           |                                     |
| 4               | Liveness image in .jpg file format only          | All                     | File             |                                     |
| 5               | Back of ID card image in .jpg file format only   | All                     | File             |                                     |
| 6               | Base64 encoded liveness image (.jpg only)        | All                     | Base64           |                                     |
| 7               | Base64 encoded back of ID card image (.jpg only) | All                     | Base64           |                                     |
| 12              | Portrait                                         | JT3 (Comparison photos) | File             | Only available via synchronous API. |

**Note:** Selfie images are required for all job types unless the user has previously been enrolled with a selfie image and `use_enrolled_image` is set to `true`. `use_enrolled_image` must be set in the initial request.

## Examples

Here are a few example schemas for different types of images:

### Example 1: Base64 Encoded Selfie Image

```json
{
  "images": [
    {
      "image": "base64_encoded_string",
      "image_type_id": 2
    }
  ]
}
```

### Example 2: File Image of ID Card

Note: For this job to pass, a selfie must have been previously enrolled for the given `user_id` and `use_enrolled_image` must be set to `true` in the initial request.

```json
{
  "images": [
    {
      "file_name": "id_card_front.jpg",
      "image_type_id": 1
    }
  ]
}
```

### Example 3: Mixed Image Types with ID Info

```json
{
  "id_info": {
    "country": "NG",
    "entered": "true",
    "id_number": "123456789",
    "id_type": "PASSPORT"
  },
  "images": [
    {
      "image": "base64_encoded_string",
      "image_type_id": 2
    },
    {
      "file_name": "id_card_front.jpg",
      "image_type_id": 1
    },
    {
      "file_name": "id_card_back.jpg",
      "image_type_id": 5
    }
  ]
}
```

For more detailed information, please refer to the Smile ID documentation: [What are the image types I can upload to Smile ID?](https://docs.usesmileid.com/further-reading/faqs/what-are-the-image-types-i-can-upload-to-smile-id)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://legacy-docs.usesmileid.com/further-reading/faqs/what-are-the-image-types-i-can-upload-to-smile-id.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
