NEW ACTION1 PLATFORM: NOW WITH MAC OS SUPPORT

This Thursday | 12 PM EDT / 6 PM CEST

Homepage 5 API Documentation 5 Authentication

Authentication

NOTE: We recommend using PSAction1 PowerShell module for substantially simplified API scripting experience.

Before you can start making API calls to Action1 resources, you must authenticate yourself with API credentials you’ve generated in the Action1 console.

Note: the examples below were adopted for cURL. You can use any API tool and platform of your choice.

To authenticate yourself in the system:

1. From a command  prompt, run the following command, replacing:

    • CLIENT-ID with the Client ID you generated on the API Credentials page
    • CLIENT-SECRET with the Client Secret, you generated on the API Credentials page

curl -XPOST -H "Content-Type:application/x-www-form-urlencoded" -d "client_id=CLIENT-ID&client_secret=CLIENT-SECRET" https://app.action1.com/api/3.0/oauth2/token

This command returns an API response:

{
  "access_token": "JWT-TOKEN",
  "refresh_token": "TOKEN",
  "expires_in": 3600,
  "token_type": "bearer"
}

2. Copy the JWT-TOKEN token and pass it as a header (Authorization: Bearer JWT-TOKEN) in every subsequent API call.

For example:

curl -XGET -H "Authorization: Bearer JWT-TOKEN" https://app.action1.com/api/3.0/organizations