For AI agents: this page in Markdown: https://www.pubnub.com/docs/sdks/kotlin/entities/channel-metadata.md. Documentation index: https://www.pubnub.com/llms-full.txt.
ChannelMetadata SDK entity
As of version 9.0.0, the Kotlin software development kit (SDK) supports SDK entities. SDK entities are local objects that bundle operations for a specific resource type and simplify working with PubNub application programming interfaces (APIs).
Use SDK entities to perform common tasks without manually wiring requests. Some PubNub APIs are exposed via SDK entities. Other operations remain available on the pubnub object.
Create ChannelMetadata
Use this factory method to return a local ChannelMetadata SDK entity for a single channel metadata object. A ChannelMetadata SDK entity centralizes operations related to App Context channel metadata.
1pubnub.channelMetadata(id: String): ChannelMetadata
required
idrequired#- Identifier of the channel metadata for which to create the SDK entity.
Sample code
1
Available operations
The ChannelMetadata SDK entity provides operations for PubNub App Context channel metadata.
| Operation (click for more information) | Description |
|---|---|
subscription(subscriptionOptions) | Returns a local channel metadata subscription object with optional parameters. You can then subscribe to receive real-time updates for that channel metadata. |