All Products
Search
Document Center

Alibaba Cloud Model Studio:Get an API key

Last Updated:Feb 13, 2026

Before using models or applications in Alibaba Cloud Model Studio, get an API key for authentication.

Get an API key

Important

Use your Alibaba Cloud account, or a RAM user with administrator or API-Key page permissions.

  1. Go to the API Key (Singapore), API Key (US (Virginia)), or API Key (China (Beijing)) page. Click Create API Key.

  2. In the dialog box, configure the following settings and click OK:

    • Owner Account: Select the Alibaba Cloud account (digit-only ID in the Account column).

    • Workspace: Select the default workspace.

  3. Click image next to the API key to copy it.

    The Alibaba Cloud account can view all API keys. RAM users can only view API keys they created.

    2026-02-11_11-56-27

When should you choose a different account or workspace?

If you need team collaboration or cost allocation:

  • Owner Account: To bind an API key to a specific member for easier permission management during personnel changes, select the corresponding RAM user. If that RAM user is removed from the workspace, the API key becomes invalid and loses calling permissions.

  • Workspace: Use workspaces to isolate resources and permissions for different projects or teams. To control which models certain users can call or to split billing for model usage, create a sub-workspace and select from the list.

For more information, see Permission management and Bill query and cost management.

Use an API key

Never share your API key publicly. Unauthorized use can lead to security risks or financial loss.

Permissions

An API key’s permissions are fully determined by its workspace. All API keys in the same workspace have identical permissions. You do not need separate API keys for different models (such as text-to-text, text-to-image, or speech synthesis).

  • API keys in the default workspace: Can call all models and applications in the default workspace.

  • API keys in a sub-workspace: Can call models that the sub-workspace has been granted access to, along with applications within that sub-workspace.

Validity

API keys remain valid permanently unless you mannually delete them.

To grant temporary access to third-party applications or users, or require strict control over high-risk operations such as accessing or deleting sensitive data, generate a temporary API key (valid for 60 seconds). This avoids exposing long-term valid API keys and reduces the risk of leakage.

FAQ

Q: How many API keys can I create under one Alibaba Cloud account?

A: Each Alibaba Cloud account can have up to 10 workspaces (including the default workspace), and each workspace can have up to 20 API keys.

Q: If a RAM user is deleted, are the API keys they created still usable?

A: After you disable or delete a RAM user in the RAM console, all API keys created by that RAM user become invalid and can no longer be used to call models.