Update the WireGuard Peer
PATCH/wireguard_peers/:id
Update the WireGuard peer.
Request
Path Parameters
id uuidrequired
Identifies the resource.
- application/json
Body
required
public_key string
The WireGuard PublicKey
.
If you do not provide a Public Key, a new Public and Private key pair will be generated for you.
Responses
200: Successful response
- application/json
422: Unprocessable entity. Check the 'detail' field in response for details.
- application/json
default: Unexpected error
- application/json
Request samples
curl -L -X PATCH 'https://api.telnyx.com/v2/wireguard_peers/:id' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"public_key": "qF4EqlZq+5JL2IKYY8ij49daYyfKVhevJrcDxdqC8GU="
}'
Response samples
{
"data": {
"id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"record_type": true,
"created_at": "2018-02-02T22:25:27.521Z",
"updated_at": "2018-02-02T22:25:27.521Z",
"public_key": "qF4EqlZq+5JL2IKYY8ij49daYyfKVhevJrcDxdqC8GU=",
"last_seen": "2018-02-02T22:25:27.521Z",
"wireguard_interface_id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"private_key": "qF4EqlZq+5JL2IKYY8ij49daYyfKVhevJrcDxdqC8GU="
}
}
{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}
{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}