Assembly: mindtouch.deki
Class: MindTouch.Deki.DekiChangeSubscriptionService
SID: sid://mindtouch.com/deki/2008/11/changesubscription
The DekiChangeSubscriptionService is responsible for the Page Alerts feature of Deki. By default it is started by Deki and located at:
@api/deki/pagesubservice/
| Verb:Suffix | Description |
| POST:pages/{pageid} | Subscribe authorized user to a page or page subtree |
| DELETE:pages/{pageid} | Remove a subscription for an authorized user |
| GET:subscriptions | Retrieve all subscriptions for the authorized user |
| POST:updateuser | Subscription end-point for user events |
| POST:notify | Subscription end-point for events subscribed to by users |
<subscriptions>
<subscription pageid="{pageid}" depth="0|*" />
...
</subscription-set>
Subscribe the current user to a specific page or page subtree
| Name | Type | Defaut | Description |
| depth | string? | 0 | 0 for direct page subscription, * for subscription of page and child pages |
It is assumed that the request contains Deki's authorization headers, as they are used to proxy a request to Deki to determine the requesting user
One special case of a Bad Request response is a user without an email, which is indicated by a reason of "no email for user". This means that the request was otherwise valid, but could not be completed, because the user has to email address to be used for the subscription.
| Response | Response Body | Description |
| Ok (200) | none | operation completed successfully and a new event was created |
| Bad Request (400) | none | request could not be completed, because of invalid data in the request |
| Unauthorized (401) | none | request could not be completed, because of invalid or missing authorization headers |
None
Deletes any existing direction subscription for the page (i.e. does not any subscription if the page is indirectly subscribed by being a child of a subscribed page
It is assumed that the request contains Deki's authorization headers, as they are used to proxy a request to Deki to determine the requesting user
| Response | Response Body | Description |
| Ok (200) | none | operation completed successfully and a new event was created |
| Bad Request (400) | none | request could not be completed, because of invalid data in the request |
| Unauthorized (401) | none | request could not be completed, because of invalid or missing authorization headers |
None
Retrieve subscriptions for all or a subset of pages for the current user. Only returns direct matches by pageId. To find out if a page is indirectly subscribed by a parent, all parent pageIds should be submitted as well in the request. The resulting document will list all subscriptions that match any of the pageIds.
If the page under consideration is page 10 with parent ids 9,8,7, and page is directly subscriped if one of the subscription elements has a pageid attribute of 10. If it has any other subscription elements (which can only be for pageid 9,8 and/or 7) the page is indirectly subscribed to.
| Name | Type | Defaut | Description |
| pages | string? | empty | Comma separated list of pageIds to check for a subscription. |
It is assumed that the request contains Deki's authorization headers, as they are used to proxy a request to Deki to determine the requesting user.
| Response | Response Body | Description |
| Ok (200) | text/xml | operation completed successfully and a new event was created |
| Bad Request (400) | none | request could not be completed, because of invalid data in the request |
| Unauthorized (401) | none | request could not be completed, because of invalid or missing authorization headers |
Any subscription matches are returned in an XML document following format described above.
This feature is used by the pubsub chain to post user events to the service.
User change doc
| Response | Response Body | Description |
| Ok (200) | none | operation completed successfully and a new event was created |
| Bad Request (400) | text/html | request could not be completed, because of invalid data in the request |
None
This feature is used by the pubsub chain to post page events to the service.
Page change doc
| Response | Response Body | Description |
| Ok (200) | none | operation completed successfully and a new event was created |
| Bad Request (400) | text/html | request could not be completed, because of invalid data in the request |
None
| Images 0 | ||
|---|---|---|
| No images to display in the gallery. |
Copyright © 2011 MindTouch, Inc. Powered by