> ## 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.

# Create vault link

## Overview

Allows the client to create a secure link to a vault item, for distribution. The client can set the number of times the link can be used, as well as an expiration time.

## HTTP request

`POST /Agent/Storage/CreateVaultLink`

## Authentication

Requires a valid JWT bearer token.

## Request (JSON)

```json theme={null}
{
	"vaultId": Required(Str(PVaultId)),
	"ttl": Optional(Int(PTtl > 0)),
	"useCount": Optional(Int(PUseCount > 0)),
	"masked": Optional(Bool(PMasked)),
	"keyId": Required(Str(PKeyId)),
	"nonce": Required(Str(PNonce)),
	"keySignature": Required(Str(PKeySignature)),
	"requestSignature": Required(Str(PRequestSignature))
}
```

## Input parameters

| Parameter         | Description                                                                                                                                |
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| PKeyId            | Identity of key to use for signing the link.                                                                                               |
| 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 request, using the account password.                                                                        |
| PVaultId          | Identifier of the vault item referenced from the link.                                                                                     |
| PTtl              | How many seconds the link is valid. If not provided, the link will be permanent.                                                           |
| PUseCount         | Number of times the link can be used. If not provided, the link can be used any number of times.                                           |
| PMasked           | If the link should return masked information.                                                                                              |

## Response (JSON)

```json theme={null}
{
	"url": Required(Str(PUrl))
}
```

## Response parameters

| Parameter | Description        |
| --------- | ------------------ |
| PUrl      | The generated URL. |

## Notes

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