POST/api/peers/{peerId}/temporary-access

Create a Temporary Access Peer

Creates a temporary access peer that can be used to access this peer and this peer only. The temporary access peer and its access policies will be automatically deleted after it disconnects.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 3 body fields
peerIdstringrequired
The unique identifier of a peer

Temporary Access Peer create request

namestringrequired
Peer's hostname
rulesarray<string>required
List of temporary access rules
wg_pub_keystringrequired
Peer's WireGuard public key

5 status codes
200Temporary Access Peer response
idstringrequired
Peer ID
namestringrequired
Peer's hostname
rulesarray<string>required
List of temporary access rules
400Bad Request
401Requires authentication
403Forbidden
500Internal Server Error

Error handling

A 400 is returned: Bad Request. A 401 is returned: Requires authentication. A 403 is returned: Forbidden. A 500 is returned: Internal Server Error.