> For the complete documentation index, see [llms.txt](https://docs.blockz.fi/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.blockz.fi/api/submit-intent/approvals.md).

# Approvals

After an intent is created, it must be approved before execution.

This endpoint attaches a signed approval to an existing intent. The approval confirms that the user has authorized the swap under the previously defined parameters.

```http
POST /affiliate/v1/intents/{intent_id}/approvals
```

#### **Request Body**

The request body depends on the approval mechanism used during intent creation.

It must include:

* The approval `type`
* The corresponding `signed_data` generated by the user

**Permit2 (EVM)**

```json
{
  "type": "permit2",
  "signed_data": "0x..."
}
```

* `signed_data` is the Permit2 signature.
* To generate this signature, refer to [Signing an Intent for EVM](/api/submit-intent/approvals/signing-an-intent-for-evm.md) section for details.

**Possible errors**

If the backend returns [error code](/api/errors.md) **25**, the user has not approved Permit2 yet for selected token. The user must approve Permit2 on-chain before continuing. See [Approve for Permit2](/on-chain-helpers/approve-for-permit2.md) for details.

***

**PSBT (Bitcoin)**

```json
{
  "type": "psbt",
  "signed_data": "cHNid..."
}
```

* `signed_data` is a signed PSBT.
* Refer to the [Signing an intent for Bitcoin](/api/submit-intent/approvals/signing-an-intent-for-bitcoin.md) section for details.

***

**Cosign (Solana)**

```json
{
    "type" : "cosign",
    "signed_data" : {
        "transaction" : "02000...", // transaction in hex
        "user_address" : "F8ZRdxvWEczGyxEBPiYraWCcMjv2sQZxuhh7BGETTDFg"
    }
}
```

* `signed_data.transaction` is a signed versioned transaction.
* Refer to the [Signing an intent for Solana](/api/submit-intent/approvals/signing-an-intent-for-solana.md) section for details.
