Arm AI Model Optimizer token management
Use the AI Portal to create and manage the tokens you use to log in to Arm AI Model Optimizer. After logging in, you can submit optimizations and access results using the command-line interface (CLI) or Python SDK.
Before you begin
You need an Arm ID to manage your tokens in the AI Portal. The installation instructions include both the np CLI and netspresso Python package. See Quick start or Python quick start for setup instructions.
Pass the complete token value generated by the AI Portal to np auth login or client.auth.login().
Keep the token private. Store it securely, and do not include it in source code, screenshots, logs, or support requests.
Open token management
- Open the AI Portal Tools section
- In the Arm AI Model Optimizer section, select Sign up
- Sign in with your Arm ID if prompted or follow the registration instructions to create one
Once signed in, the AI Model Optimizer token management page contains a form for creating tokens and a list of your existing tokens. If you have not created any, the list shows No tokens.
Create and copy a token
- Under Create a new access token, enter a Token name, such as
my-laptoporci-build. Use a descriptive name so you can identify its purpose later. - Select an Expiration: 7, 30, 60, 90, or 100 days. The default and maximum are 100 days.
- Select Create token.
- Under Your new token is ready, copy the token and store it securely before dismissing the message or leaving the page.
The token is shown only when it is created. You cannot retrieve it from the token list later. If you lose it, you would need to delete that token and create a replacement.
You can create up to five tokens. Expired and revoked tokens also count toward this limit; delete tokens you no longer need to make room for new ones.
Use the token
After completing the CLI setup, replace <token> below with the complete token value you copied:
np auth login '<token>'
np auth status
When using the Python package, use the same token:
from netspresso.api import NetsPresso
client = NetsPresso()
client.auth.login("<token>")
client.auth.status()
The CLI and Python SDK share the same local authentication state. You do not need to log in separately for each interface on the same machine.
When the portal token expires or is deleted or revoked, you would need to obtain a valid token and log in again. np auth status reads local state; it does not check whether the server still accepts the token.
Continue with Quick start: Initialize a workspace or Python quick start: Initialize a workspace. For token storage and authentication errors, see CLI reference: np auth.
Review existing tokens
The token list shows metadata about the tokens.
| Field | Meaning |
|---|---|
| Name | The name you entered when creating the token. |
| Created | The date the token was created. |
| Last used | The most recent use reported by the tool. |
| Expires | The date the token expires. |
| Status | active, expired, or revoked. |
Dates are displayed in UTC. A revoked token has been invalidated by an administrator; the portal provides a Delete action for removing tokens.
Replace or delete a token
To replace a token before it expires:
- Create a new token with a name that identifies its purpose. If you have reached the five-token limit, first delete a token you no longer need.
- Copy the new token and log in with it.
- Confirm that the replacement works by making a request, such as
np projects ls. - Delete the old token once you have switched its consumers to the replacement.
To delete a token, select Delete beside it in the list, check the name in the confirmation dialog, and select Delete token. Deletion cannot be undone.
Existing access tokens may continue working for up to approximately 30 minutes after deletion.
np auth logout removes tokens from your local machine. To invalidate the token for all consumers using it, you need to delete it in the portal.
Common problems
| Problem | What to do |
|---|---|
| You dismissed or lost the token | Delete the token you lost and create a replacement. Existing tokens cannot be displayed again. |
| You have five tokens and cannot create another | Delete a token you no longer need. Expired and revoked tokens also count toward the limit. |
| Creation reports that it may have succeeded | Select Refresh token list before trying again. If the new token appears but you did not receive the token value, delete it and create a replacement. |
| The token is expired or revoked | Create a replacement and log in again. |
| Login or session refresh fails | Check that you copied the complete token. Check the token's status and expiry in the portal. See authentication errors if the issue persists. |
For any other issues, follow Reporting an issue. Do not include the token in your report.