...
- domain: cloudos
- type: subscriptionRequestPending
- attributes: eventChannel, namespace, relationship, channelName
Code Block | ||||
---|---|---|---|---|
| ||||
rule receive_subscriptionRequestAdded select when cloudos subscriptionRequestAdded namespace re/MyFriends" channelName re/Coworkers Bob+Ted/ relationship re/friend-friend/ |
Subscription Approval or Rejection
...
- domain: cloudos
- type: subscriptionRequestApproved
- attributes: eventChannel
Code Block | ||||
---|---|---|---|---|
| ||||
fired {
raise cloudos event subscriptionRequestApproved
with eventChannel = "3f15b820-af7f-012f-4c6e-00163ebcaaaa"
and _api = "sky";
} |
Once the subscription request is approved both Personal Clouds will receive a callback events raised within each respective Personal Cloud. These events are raised to enable the developer to take additional actions when the Personal Channels are actually created.
- domain: cloudos
- type: CloudOS_subscriptionAdded
- attributes: eventChannel, backChannel, namespace, relationship, channelName
Code Block | ||||
---|---|---|---|---|
| ||||
rule receive_subscriptionRequestAdded
select when cloudos subscriptionRequestAdded
namespace re/MyFriends"
channelName re/Coworkers Bob+Ted/
relationship re/friend-friend/ |
To reject the subscription request the following event should be raised:
- domain: cloudos
- type: subscriptionRequestRejected
- attributes: eventChannel
Code Block | ||||
---|---|---|---|---|
| ||||
fired {
raise cloudos event subscriptionRequestRejected
with eventChannel = "3f15b820-af7f-012f-4c6e-00163ebcaaaa"
and _api = "sky";
} |
When the subscription request is rejected the following event will be raised with the Personal Cloud:
- domain: cloudos
- type: subscriptionRejected
- attributes: eventChannel, namespace, relationship, channelName
And the following event will be raised in the Personal Cloud which made the subscription request:
- domain: cloudos
- type: subscriptionRejected
- attributes: backChannel, namespace, relationship, channelName
Code Block | ||||
---|---|---|---|---|
| ||||
fired { raise cloudos event subscribe with channelName = "Coworkers Bob+Ted" and namespace = "DocSample" and relationship = "friend-friend" and targetChannel = "3f15b820-af7f-012f-4c6e-00163ebczzzz" and _api = "sky"; } |
...