grant
Deprecated
This function is deprecated. Use the grantToken(ttl)
Replace with
grantToken(ttl)Content copied to clipboard
This function establishes access permissions for PubNub Access Manager (PAM) by setting the read or write attribute to true. A grant with read or write set to false (or not included) will revoke any previous grants with read or write set to true.
Permissions can be applied to any one of three levels:
Application level privileges are based on
subscribeKeyapplying to all associated channels.Channel level privileges are based on a combination of
subscribeKeyandchannelname.User level privileges are based on the combination of
subscribeKey,channel, andauth_key.