Streams

Rotate the stream token: invalidate the current token and generate a new one. Any client using the old token must be updated.

Result. Always HTTP 200: check status (1 on success) and read the new token. An unknown stream ID returns 404.

Authentication: TextPeak API key in the Authorization header (see Authentication in the API Overview).

get/streams/{id}/token/reset

Request

  • Base URL
    https://api.commpeak.com/textpeak
  • URL
    https://api.commpeak.com/textpeak/streams/{id}/token/reset
  • Auth
    API key in header Authorization

Path parameters

idinteger required

Unique identifier of the resource.

Response

Successful Response

statusinteger required

1 the token was reset. Errors: 0 no API key, 2 no user, 3 no customer, 4 stream ID missing, 5 stream not found, 6 the reset failed.

messagestring required

OK, or the error text.

tokenstring nullable

The new stream token, on success only. The previous token stops being valid.

Example response

{
  "message": "OK",
  "status": 1,
  "token": "578f7b486a401391ccb41b660d969d92c320334d"
}

Changes

    • breaking

      added the new path request parameter id

    • breaking

      response property token list-of-types was widened by adding types null to media type application/json of response 200

    • info

      api operation id resetToken removed and replaced with reset_stream_token

    • info

      the endpoint scheme security APIKeyHeader was added to the API

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      the response property became required for the status

    • info

      the response property became required for the status