Updating an event action with a subscription
You can use the Content Event Webhook feature to update an event action.
This example updates an event action using changeMode:ADD/UPDATE or
deletions:
mutation
{
eevUpdateExternalEventAction
(repositoryIdentifier:"<objectStoreSymName>"
identifier: "<eventActionId>" #event action id
externalEventActionProperties: #optionally update event action properties
{
type:WEBHOOK
name:"<eventActionNewName>"
isEnabled: true
cmTransactionTimeout: 120
}
subscriptions: #update subscriptions
{
changes: [
{
type: INSTANCE #INSTANCE or CLASS
changeMode:ADD #add new subscription
name: "Additional Subscription" #name required for changeMode ADD
descriptiveText: " Additional Subscription Description"
subscriptionTarget:
{
classIdentifier:"Document/Folder"
identifier:"<docId>/<folderId>/<folderPath>"
}
subscribedEventClassIdentifiers:
[
"UpdateEvent" #event of interest
]
},
{
type: INSTANCE #INSTANCE or CLASS accordingly
changeMode: UPDATE #update an existing subscription
id: "<eventSubscriptionIdtoUpdate>" #id is required
isEnabled: false
subscribedEventClassIdentifiers:
[
"UpdateEvent", "DeletionEvent"
]
}
],
deletions: [ #deletion by subscription id
"<eventSubscriptionIdtoDelete>"
]
}
)
{
id
name
owner
progId
eevExternalEventReceiverURL
isEnabled
cmTransactionTimeout
}
}