Besides the action methods you can configure in the Hub Services Custom Notification wizard, you can configure additional action methods when you use the Notification Services API to create notifications.
To see code examples for these action notifications, go to the documentation tab on the Workspace ONE Notifications Service API page, https://code.vmware.com/apis/402#/Notifications.
- “action_key”:”OPEN_IN”. Make an API call to open a specific URL in the system’s default browser. For example, create a change password notification that includes the change password action with a link to the password change URL.
- “action_key”:”DIRECT”. Make an API call to the specific URL where the type value is the HTTP method, and the request value contains hard coded fields that are sent as payload when the API call runs. For example, create a survey question that requires a Yes or No answer. When a user clicks to answer the questions, the response, either Yes or NO, is sent to the URL listed.
- “action_key”:”USER_INPUT”. Make an API call to a specific URL where the type value is the HTTP method where the user enters some input that is sent with the payload. For example, create an Accept or Deny notification where the recipient is required to add a comment when denying the request. This response is sent as the payload of the API call to the specified URL.
When using DIRECT or USER_INPUT as the action type, make sure that the URL you use does not require authentication to access. If an authorization token is required, the API call fails. See the Notification Service API documentation for examples of the API code to use.