Create and manage organization access tokens using Splunk Observability Cloud 🔗
Access tokens, also known as org tokens, are long-lived organization-level tokens. You can use access tokens in all API requests except those that require a token associated with a user who has administrative access. See Retrieve and manage user API access tokens using Splunk Observability Cloud for more information.
Use access tokens to:
Send data points to Splunk Observability Cloud with API calls.
Run scripts that call the API.
Manage your resource by tracking usage for different groups of users, services, teams, and so on. For example, you have users in the U.S. and Canada sending data to Splunk Observability Cloud. You can give each group its specific access token to compare the amount of data coming from each country.
Note
By default, only users who are administrators can search for and view all access tokens. You can change this default when you create or update an access token.
Power users who have access to tokens in an organization see a banner, but only admins will get an email saying that the tokens must be rotated.
Token expiry 🔗
You can view the expiration dates of your tokens through the access token page. To view this page, select Settings and select Access tokens. By default, access tokens expire 30 days after the creation date. You can rotate a token before it expires, or you can change the default expiration date during token creation. For details, see Rotate an access token and Configure an expiration date.
By default, every organization admin receives an email 30 days before a token in their org expires. The email includes a link to Splunk Observability Cloud that displays a list of expiring tokens. To change the expiration reminder date, see Configure an expiration date.
The default access token 🔗
By default, every organization has one organization-level access token. If you don’t create any additional tokens, every API request that sends data to Splunk Observability Cloud must use this access token.
Manage access tokens 🔗
To manage your access (org) tokens, follow these steps:
Open the Settings menu.
Select Access Tokens.
Find your token by using the Status and Scope filters or enter the token name in the search bar.
Select the expand icon next to the token name. This displays details about the token.
For information about the access token permissions allowed by the Authorization Scopes field value, see the permissions step in Create an access token.
(Optional) If you’re an organization administrator, the actions menu (⋮) appears to the right side of the token listing. You can select token actions from this menu.
See Change token permissions and Change token expiration date and expiration alerts to modify token permissions and token expiration settings, respectively.
Change token permissions 🔗
If you’re an organization administrator, you can change token permissions for other users and teams.
To change the token permissions, follow these steps:
Select the Access Token Permissions box. Choose from the following permission options:
: Only admin users can view or read the new token. The token isn’t visible to other users.
: Admin users and users or teams you select can view or read the new token. The token isn’t visible to anyone else.
: Every user and team in the organization can view and read the token.
To add permissions, select the left arrow below Access Token Permissions.
If you selected Admins and Select Users or Teams can Read, select the users or teams to whom you want to give access.
To remove a team or user, select the delete icon (X) next to the team or username.
To update the token, select Update.
Change token expiration date and expiration alerts 🔗
To change the token expiration date and expiration alerts, follow these steps:
In the token actions menu (â‹®), select Expiration date.
In the Expiration date box, select a new expiration date for the token.
To change the visibility of the expiration alert, select from the following options:
: Admins and anyone with token permissions receive an alert when the token is close to expiring.
: Only admins receive an alert when the token is close to expiring.
Configure the type of alert that your recipients receive.
Change the time at which recipients receive an alert. For example, a value of
7d
means recipients receive an alert 7 days before the token expires.Select Update.
View and copy access token secrets 🔗
To view the token secret, select the token name and then select Show Token.
To copy the token value, select Copy. You don’t need to be an administrator to view or copy an access token.
Create an access token 🔗
To get started with creating an access token, follow these steps:
Open the Splunk Observability Cloud main menu.
Select
and select .Select New Token.
Next, complete each step in the access token creation guided setup:
Note
You must be an organization administrator to create access tokens.
Determine who can view and use the token 🔗
Next, configure token permissions so your organization’s users and teams can use the token. Complete the following steps:
Edit the visibility permissions. To display the available permissions, select the Access Token Permissions box. The following permission options appear:
: Only admin users can view or read the new token. The token isn’t visible to other users.
: Admin users and users or teams you select can view or read the new token. The token isn’t visible to anyone else.
: Every user and team in the organization can view and read the token.
To add permissions, select the arrow below Access Token Permissions.
If you selected Admins and Select Users or Teams can Read, select the users or teams to whom you want to give access:
Select Add Team or User. Splunk Observability Cloud displays a list of teams and users in your organization.
To find the team or username in a large list, start entering the name in the search box. Splunk Observability Cloud returns matching results. Select the user or team.
To add more teams or users, select Add Team or User again.
Note
You might see the following message in the middle of the dialog:
You are currently giving permissions to a team with Restrict Access deactivated. This means any user can join this team and can access this Access Token.
This message means that all users are able to join the team and then view or read the access token.
To remove a team or user, select the delete icon (X) next to the team or username.
Select Next to continue to the final step.
Configure an expiration date 🔗
To finish creating the token, select an expiration date for the token.
In the Expiration date box, select a date at which the token will expire. The date can’t be over 18 years from the token creation date.
In the Expiration alert box, select from one of the following options:
: Only admins receive an alert when the token is close to its expiration date.
: Admins and any users with token permissions receive an alert when the token is close to its expiration date.
(Optional) Set a time for when Splunk Observability Cloud sends an expiration alert. For example, a value of 7 days means Splunk Observability Cloud will send an alert 7 days before the token expires.
Select Create to finish creating the new token.
Rotate an access token 🔗
You can rotate an access token using the access token menu or the Splunk Observability Cloud API. This creates a new secret for the token and deactivates the token’s previous secret. Optionally, you can provide a grace period before the previous token secret expires.
You can’t rotate tokens after they expire. If you don’t rotate a token before it expires, you must create a new token to replace it.
Note
You must be a Splunk Observability Cloud admin to rotate a token.
Rotate access tokens using the Splunk Observability Cloud API 🔗
To rotate an access token with the API, use the POST /token/{name}/rotate
endpoint in the Splunk Observability Cloud API. An API call to rotate a token looks like this:
curl -X POST "https://api.{realm}.signalfx.com/v2/token/{name}/rotate?graceful={gracePeriod}&secondsUntilExpiry={secondsUntilExpiry}" \
-H "Content-type: application/json" \
-H "X-SF-TOKEN: <your-user-session-api-token-value>"
Follow these steps:
Enter your Splunk realm in the
realm
field.Enter your API session token in the
your-user-session-api-token-value
field. To find or create an API session token, see Retrieve and manage user API access tokens using Splunk Observability Cloud.Provide the name of the token you want to rotate in the
name
field.Optionally, provide a grace period, in seconds, in the
gracePeriod
field.Optionally, provide the seconds until your token expires in the
secondsUntilExpiry
field. This can be any value between 0 second and 5,676,000,000 seconds (18 years), inclusive. If left unspecified, the token remains valid for 30 days.Call the API endpoint to rotate the token.
For example, the following API call rotates myToken
and sets a grace period of 604800 seconds (7 days) before the previous token secret expires.
curl -X POST "https://api.us0.signalfx.com/v2/token/myToken/rotate?graceful=6048000" \
-H "Content-type: application/json" \
-H "X-SF-TOKEN: <123456abcd>"
After you’re finished rotating the token, update any of your OpenTelemetry Collector configurations with the new token secret before the grace period ends.
To learn more about this endpoint and to see more examples of requests and responses, see the Splunk developer documentation .
Rename an access token 🔗
To rename a token:
Select
from the token’s actions menu (⋮).Enter a new name for the token.
Select OK.
Renaming a token does not affect the token’s secret.
Note
For Cloud integrations (AWS, GCP, or Azure), after renaming an access token you need to select a new token name using the API. For AWS, you can also set up a new token in the UI.
Deactivate or activate an access token 🔗
Note
You can’t delete tokens. You can only deactivate them.
To deactivate a token, select
from the token’s actions menu (⋮).To activate a deactivated token, select
from the deactivated token’s actions menu (⋮).You can search for activated or deactivated tokens using the Status filter in the access tokens page.
Manage token limits 🔗
To change limits for your access tokens, including host and container limits, follow these steps:
Select the token that you want to edit. This opens the token detail page.
Select the token actions menu (â‹®), and select Manage limits.
In the Manage limits menu, add the new token limits.
To learn more about token limits, see Manage data ingest using access tokens.