---
title: "Update a widget token"
method: PUT
path: "/v2/webrtc/tokens/{id}"
tags: ["Wavix Embeddable"]
---

# Update a widget token

`PUT /v2/webrtc/tokens/{id}`

## Request

- Base URL: `https://api.wavix.com`
- URL: `https://api.wavix.com/v2/webrtc/tokens/{id}`
- Auth: HTTP bearer

Updates the `payload` carried by the Wavix Embeddable widget token identified by `id`.

## Path parameters

- `id` string, uuid, required

## Request body

- WebRTCTokenUpdateRequest
  - `payload` object, required: Arbitrary client-defined data to associate with the token, replacing the existing payload.

## Response `200`

Returns the updated widget token.

- WebRTCToken: Represents a WebRTC token that authorizes the Wavix embeddable widget to register against a SIP trunk.
  - `uuid` string, required: Unique identifier of the WebRTC token.
  - `sip_trunk` string, required: Name of the SIP trunk the token authenticates against.
  - `payload` object, nullable: Arbitrary client-defined data associated with the token.
  - `ttl` integer, nullable: Time to live, in seconds. `null` means no expiration.

## Other responses

- `400`: Request failed. Missing or invalid parameter <param_name>
- `401`: Unauthorized
- `403`: Request failed. The feature is disabled for your account.
- `404`: Request failed. An object with the specified ID is not found.

---

[API](https://skmtc.dev/wavix/apis/wavix-apis.md) - [All operations](https://skmtc.dev/wavix/apis/wavix-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/wavix/apis/wavix-apis/revisions/f2dde79f05ab?raw)
