Windchill REST Services Domain Capabilities > Examples for Basic REST Operations > Examples for the PTC Event Management Domain > Subscribing to an Event of a Windchill Object Type in the Specified Folder
Subscribing to an Event of a Windchill Object Type in the Specified Folder
This example shows you how to subscribe to an event that occurs on the type of specified Windchill object in the specified folder. Use the following POST request.
URI
POST /Windchill/servlet/odata/EventMgmt/EventSubscriptions HTTP/1.1
Request Headers
Content-Type: application/json
CSRF_NONCE: <Use the value from Fetch NONCE example>
Request Body
{
"Name": "TestFolderSubscription",
"CallbackURL": "https://windchill.ptc.com/Windchill",
"SubscribedOnEntityType": "PTC.DocMgmt.Document",
"ExpirationDate": "2018-12-20T11:30:00Z",
"SubscribedEvent@odata.bind": "Events(' EDIT_ATTRIBUTES’)",
"SubscribedOnFolder@odata.bind": "Folders('OR:wt.folder.SubFolder:5012381')",
"@odata.type":"PTC.EventMgmt.EntityTypeInFolderEventSubscription" }