Commands are functions that your app can dispatch to perform PubNub server operations and process the response. When you dispatch a command, the command returns an action that the process has begun. After the operation is performed on the PubNub server, the command dispatches an action that acknowledges either the success or failure of the operation. The reducer that responds to each action updates the application state in your store.
The commands for each feature fall into the following operational categories:
Fetch operations
Command Name | Description |
---|
fetchUserData | Returns the specified user object, optionally including the user's custom data object. |
fetchAllUserData | Returns a paginated list of user objects, optionally including each user's custom data object. |
fetchChannelData | Returns the specified channel object, optionally including the channel's custom data object. |
fetchAllChannelData | Returns a paginated list of channel objects, optionally including each channel's custom data object. |
fetchMemberships | Returns a list of channel memberships for a specified user. |
fetchChannelMembers | Returns a list of members in a specified channel. |
fetchMessageHistory | Fetch historical messages of a channel. |
fetchHereNow | Obtain information about the current state of a channel, including a list of unique userId s currently subscribed to the channel and the total occupancy count of the channel. |
fetchPresenceState | Get the current state information based on the current uuid for either specified channels or channelGroups . |
Set operations
Delete operations
Send operations
Command Name | Description |
---|
sendMessage | Send a message packaged in a request object. |
External References
For more details about the concepts discussed in the PubNub Redux framework documentation, you should review the following references: