Skip to content

Commit

Permalink
Merge pull request #1765 from ably/wildcard-capability
Browse files Browse the repository at this point in the history
types/capability: allow wildcard capability when presented in object form, add privileged-headers capability
  • Loading branch information
AndyTWF authored May 17, 2024
2 parents c6e18fe + f19c8da commit bc4f3ac
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ably.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,9 @@ export type capabilityOp =
| 'stats'
| 'channel-metadata'
| 'push-subscribe'
| 'push-admin';
| 'push-admin'
| 'privileged-headers';

/**
* Capabilities which are available for use within {@link TokenParams}.
*/
Expand All @@ -698,7 +700,7 @@ export interface TokenParams {
*
* @defaultValue `'{"*":["*"]}'`
*/
capability?: { [key: string]: capabilityOp[] } | string;
capability?: { [key: string]: capabilityOp[] | ['*'] } | string;
/**
* A client ID, used for identifying this client when publishing messages or for presence purposes. The `clientId` can be any non-empty string, except it cannot contain a `*`. This option is primarily intended to be used in situations where the library is instantiated with a key. Note that a `clientId` may also be implicit in a token used to instantiate the library. An error is raised if a `clientId` specified here conflicts with the `clientId` implicit in the token. Find out more about [identified clients](https://ably.com/docs/core-features/authentication#identified-clients).
*/
Expand Down

0 comments on commit bc4f3ac

Please sign in to comment.