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

# Add ID attachment

> Allows the client to add an attachment to a Legal Identity application.

## Overview

Allows the client to add an attachment to a Legal Identity application.

## HTTP request

`POST /Agent/Legal/AddIdAttachment`

## Authentication

Requires a valid JWT bearer token.

## Request (JSON)

```json theme={null}
{
	"keyId": Required(Str(PKeyId)),
	"legalId": Required(Str(PLegalId)),
	"nonce": Required(Str(PNonce)),
	"keySignature": Required(Str(PKeySignature)),
	"requestSignature": Required(Str(PRequestSignature)),
	"attachmentBase64": Required(Str(PAttachmentBase64)),
	"attachmentFileName": Required(Str(PAttachmentFileName)),
	"attachmentContentType": Required(Str(PAttachmentContentType))
}
```

## Input parameters

| Parameter              | Description                                                                                                                                |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| PKeyId                 | Identity of key to use for signing the Identity application.                                                                               |
| PLegalId               | Identity of the Legal Identity Application.                                                                                                |
| PNonce                 | A unique random string, at least 32 characters long, with sufficient entropy to not be reused again. If reused, an error will be returned. |
| PKeySignature          | Cryptographic signature of the key ID, using the key password.                                                                             |
| PRequestSignature      | Cryptographic signature of the requesut, using the account password.                                                                       |
| PAttachmentBase64      | Base-64-encoding of attachment to add to the Identity application.                                                                         |
| PAttachmentFileName    | File name of attachment.                                                                                                                   |
| PAttachmentContentType | Content-Type of attachment.                                                                                                                |

## Response (JSON)

```json theme={null}
{
	"Identity": Required(PIdentity)
}
```

## Response parameters

| Parameter | Description                                      |
| --------- | ------------------------------------------------ |
| PIdentity | Updated Identity object generated by the server. |

## Notes

This endpoint uses the request schema notation described in [Pattern matching](/guides/pattern-matching).
