> For the complete documentation index, see [llms.txt](https://docs.caf.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.caf.io/caf-sdk/caf-sdk-pt-br/sdk-response.md).

# Resposta do SDK

### JWT e assinatura

Um JSON Web Token (JWT) é um padrão compacto e seguro para transmitir informações entre um cliente e um servidor como um objeto JSON.

### Parâmetros de resposta

O SDK retorna o resultado da verificação como um JWT. Para garantir a integridade dos dados, a Certta assina o JWT no backend usando uma chave privada segura. Seu backend deve validar essa assinatura antes de confiar no payload.

Para saber mais sobre segurança e chaves secretas, veja a página de Autenticação:

{% content-ref url="/pages/350b53d9674174220c34ca357260b91ef975ad64" %}
[Autenticação](/caf-sdk/caf-sdk-pt-br/authentication.md)
{% endcontent-ref %}

### Exemplo de payload do JWT

Um JWT tem três partes: cabeçalho, payload e assinatura. As declarações abaixo fazem parte do payload.

{% tabs %}
{% tab title="JWT" %}
{% code title="" %}

```json
{
  "header": {
    "alg": "HS256",
    "typ": "JWT"
  },
  "payload": {
    "sessionId": "01KVGG0CR3928MQERDX8NGA8AEQ",
    "personId": "user-id",
    "isAlive": false,
    "isMatch": false,
    "imageUrl": "https://mobile-prod-liveness-attempts.s3.us-east-1.amazonaws.com/...",
    "createdAt": "2026-06-19T17:49:15.432Z",
    "iat": 1781895533
  },
  "signature": "LNFjtTO27Z5GLR8NhhziX3nE8kftoemUOfkICkk5w8Q"
}
```

{% endcode %}
{% endtab %}

{% tab title="String bruta" %}
{% code title="resposta" %}

```
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzZXNzaW9uSWQiOiIwMUtWR0cwQ1IzOTI4TVFFUkRYOE5HQThaUSIsInBlcnNvbklkIjoidXNlci1pZCIsImlzQWxpdmUiOmZhbHNlLCJpbWFnZVVybCI6Imh0dHBzOi8vbW9iaWxlLXByb2QtbGl2ZW5lc3MtYXR0ZW1wdHMuczMudXMtZWFzdC0xLmFtYXpvbmF3cy5jb20vZTFjYWVkNDYtOGJlYS00ZDI0LWE4ZDQtNjVmOWMyOWI2NTcyL25vdF9pZGVudGlmaWVkL2xpdmVuZXNzL2F0dGVtcHRfMDFLVkdHME1GN1o4SzRHN1g3RzUyTVNDWkUucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNvbnRlbnQtU2hhMjU2PVVOU0lHTkVELVBBWUxPQUQmWC1BbXotQ3JlZGVudGlhbD1BS0lBUzZGMlhQQTdTRE5aQUVESyUyRjIwMjYwNjE5JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI2MDYxOVQxNzQ5MTVaJlgtQW16LUV4cGlyZXM9MjU5MjAwJlgtQW16LVNpZ25hdHVyZT1lNWU1M2UyZTdiMmU0Y2Q5MTUxM2I4ZjFkZTc3YzIzYjYzN2NhMzcyNjQ1YjllNmE2ODVhNGVjNzA4ZmJhZGQxJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZ4LWFtei1jaGVja3N1bS1tb2RlPUVOQUJMRUQmeC1pZD1HZXRPYmplY3QiLCJjcmVhdGVkQXQiOiIyMDI2LTA2LTE5VDE3OjQ5OjE1LjQzMloiLCJzaWduYWxzIjp7fSwiaWF0IjoxNzgxODkxMzU1fQ.LNFjtTO27Z5GLR8NhhziX3nE8kftoemUOfkICkk5w8Q
```

{% endcode %}
{% endtab %}
{% endtabs %}

| Campo     | Descrição                                                                                                   |
| --------- | ----------------------------------------------------------------------------------------------------------- |
| sessionId | Identificador da solicitação.                                                                               |
| personId  | Identificador do usuário fornecido para o SDK.                                                              |
| isAlive   | Indica se o SDK verificou com sucesso uma pessoa viva.                                                      |
| isMatch   | Indica se a correspondência facial foi bem-sucedida. Presente quando a correspondência facial está ativada. |
| imageUrl  | URL temporária da imagem gerada pela API.                                                                   |
| createdAt | Momento em que o token foi criado.                                                                          |
| iat       | Momento em que o token foi emitido.                                                                         |
| message   | Mensagem de resultado retornada pelo serviço. Pode estar presente dependendo do fluxo.                      |

{% hint style="warning" %}
O fluxo de validação depende dos `isAlive` e `isMatch` parâmetros ao usar correspondência facial. Ambos os valores devem ser `true` true `false`, o usuário é inválido e o processo deve ser encerrado.
{% endhint %}


---

# 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://docs.caf.io/caf-sdk/caf-sdk-pt-br/sdk-response.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.
