Get/add/remove channels from channel groups

This endpoint supports several operations:

Operation Required attributes
Listing all channels for a channel group sub_key, group, uuid
Adding channels to a channel group / Creating a new channel group sub_key, group, uuid, add
Removing channels from a channel group sub_key, group, uuid, remove

Path Parameters
sub_key string REQUIRED

Your app's subscribe key from Admin Portal.

Example: sub-c-50264475-1902-558x-d213-7p19052012n2

group string REQUIRED

The group for which we need the list of channels.

Example: group1

Query Parameters
auth string

String which is either the auth key (Access Manager legacy) or a valid token (Access Manager) used to authorize the operation if access control is enabled.

Example: authKey / p0thisAkFl043rhDdHRsCkNyZXisRGNoYW6hanNlY3JldAFDZ3Jwsample3KgQ3NwY6BDcGF0pERjaGFuoENnctokenVzcqBDc3BjoERtZXRhoENzaWdYIGOAeTyWGJI

uuid string REQUIRED

A UTF-8 encoded string of up to 92 characters used to identify the client.

Example: myUniqueUserId

add string

Name of a channel to be added to the channel group. You may add mulitple channels using a comma seperator (ch1,ch2,ch3).

Required to add channel to a channel group.

Example: ch1

remove string

Name of a channel to be removed from the channel group. You may add mulitple channels using a comma seperator (ch1,ch2,ch3).

Required to remove channel from a channel group.

Example: ch1

signature string

Signature used to verify that the request was signed with the secret key associated with the subscriber key.

If Access Manager is enabled, either a valid authorization token or a signature are required.

See Access Manager documentation for details on how to compute the signature.

timestamp integer

Unix epoch timestamp used as a nonce for signature computation. Must have no more than ± 60 second offset from NTP.

Required if signature parameter is supplied.

Responses
200

OK

Schema OPTIONAL
service string OPTIONAL
status integer OPTIONAL
error boolean OPTIONAL
payload object OPTIONAL
group string OPTIONAL
channels string[] OPTIONAL
400

Bad Request

Schema OPTIONAL
undefined
403

Channel Groups Multiplexing Flag Disabled Error

Schema OPTIONAL
message string OPTIONAL
error boolean OPTIONAL
service string OPTIONAL
status integer OPTIONAL
500

Channel Groups Storage Error

Schema OPTIONAL
message string OPTIONAL
error boolean OPTIONAL
service string OPTIONAL
status integer OPTIONAL
503

Channel Groups Account Configuration Error

Schema OPTIONAL
message string OPTIONAL
error boolean OPTIONAL
service string OPTIONAL
status integer OPTIONAL
* required
sub_key*
Type: string
Your app's subscribe key from Admin Portal.
group*
Type: string
The group for which we need the list of channels.
* required
auth
Type: string
String which is either the auth key (Access Manager legacy) or a valid token (Access Manager) used to authorize the operation if access control is enabled.
uuid*
Type: string
A UTF-8 encoded string of up to 92 characters used to identify the client.
add
Type: string
Name of a channel to be added to the channel group. You may add mulitple channels using a comma seperator (ch1,ch2,ch3).

Required to add channel to a channel group.
remove
Type: string
Name of a channel to be removed from the channel group. You may add mulitple channels using a comma seperator (ch1,ch2,ch3).

Required to remove channel from a channel group.
signature
Type: string
Signature used to verify that the request was signed with the secret key associated with the subscriber key.

If Access Manager is enabled, either a valid authorization token or a signature are required.

See Access Manager documentation for details on how to compute the signature.
timestamp
Type: integer
Unix epoch timestamp used as a nonce for signature computation. Must have no more than ± 60 second offset from NTP.

Required if signature parameter is supplied.
service
Type: string
Example: "channel-registry"
status
Type: integer
Example: 200
error
Type: boolean
Example: false
payload
Type: object
message
Type: string
Example: "Channel Groups: Invalid Arguments"
error
Type: boolean
Example: true
service
Type: string
Example: "channel-registry"
status
Type: integer
Example: 400
message
Type: string
Example: "Use of the channel groups API requires the Stream Controller which is not enabled for this subscribe key. Login to your PubNub Dashboard Account and enable Stream Controller. Contact support@pubnub.com if you require further assistance."
error
Type: boolean
Example: true
service
Type: string
Example: "channel-registry"
status
Type: integer
Example: 403
message
Type: string
Example: "Channel Group: Storage Error"
error
Type: boolean
Example: true
service
Type: string
Example: "channel-registry"
status
Type: integer
Example: 500
message
Type: string
Example: "Failed to retrieve account configuration"
error
Type: boolean
Example: true
service
Type: string
Example: "channel-registry"
status
Type: integer
Example: 503