# Getting Started with Event Triggers

One method developers use to watch for changes/updates to a system involves polling certain REST endpoints periodically and looking at the response for new or updated content. This method is slow, requires custom logic to look for updates, and can exhaust rate limits for an API. Event Triggers provide real-time updates to changes in the IdentityNow with all the information you need to act on. The mechanisms for interacting with SailPoint event triggers are outlined in this guide.

# Creating API Credentials

NOTE: To use SailPoint APIs and Event Triggers, you must have admin access to an IdentityNow tenant, or be able to request API credentials from your tenant's admin.

To get started, you will need an API client to generate access tokens that can be used to subscribe/unsubscribe to event triggers:

  • As an admin, browse to your API Management Admin Page at https://{tenant}.identitynow.com/ui/admin/#admin:global:security:apimanagementpanel and create an API client with the Client Credentials grant type. If you are not an admin of your tenant, you can ask an admin to create this for you.

  • Save the Client Secret somewhere safe, as you won't be able to view or change it later.

  • To create an access token, use the following cURL command, replacing {tenant} with your IdentityNow tenant:

    curl --location --request POST 'https://{tenant}.api.identitynow.com/oauth/token?grant_type=client_credentials&client_id={client_id}&client_secret={client_secret}'
    
  • The response body will contain an access_token, which will look like a long string of random characters.

  • To test your token, execute the following cURL command, replacing {tenant} with your IdentityNow tenant and {access_token} with the token you generated in the last step:

    curl --request GET --url 'https://{tenant}.api.identitynow.com/beta/triggers' --header 'authorization: Bearer {access_token}'
    
  • If successful, you should get a JSON representation of all of the triggers that are available to your tenant.

For more information about SailPoint Platform authentication, see API Authentication

# Using Event Triggers

To use SailPoint Event Triggers:

  1. Choose an Event Trigger.
  2. Choose an invocation response mode.
  3. Subscribe to a trigger.
  4. Initiate a trigger invocation.