> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes. # getAllowedChannels > getAllowedChannels method for the PubSub.Client class. ### getAllowedChannels * **getAllowedChannels**(): `Promise` Returns the channels that the current token allows you to subscribe to. #### Returns `Promise` An object whose keys are the channel names, and whose values are the permissions. For example: ```js { "my-channel-1": { "read": true, "write": false }, "my-channel-2": { "read": true, "write": true }, } ``` #### Example ```js const pubSubClient = new PubSub.Client({ token: "", }); const channels = await pubSubClient.getAllowedChannels(); console.log(channels); ``` > getAllowedChannels method for the PubSub.Client class.