This topic describes how to manage authorization for API consumers to ensure that only authenticated and authorized requests can access service resources.
Authorize consumers
Log on to the AI Gateway console.
In the navigation pane on the left, choose Consumers. In the top menu bar, select a region.
On the Consumer page, click the target consumer to go to the product page, and then click the Consumer Authorization tab.
Two types of authorization are supported: Model API and MCP.
Authorize a Model API
Click the Model API tab, and then click Authorize.
In the authorization panel, configure the parameters, and click OK.
Parameter
Description
Effective For
Select the cloud-native gateway instance for which the authorization takes effect.
Select API
Select the Model API to be authorized.
Available APIs
The APIs that are published to the gateway and can be selected.
Selected APIs
The list of selected APIs. Click View to the right of the target API to view its details.
Authorize an MCP service
Click the MCP tab, and then click Authorize.
In the authorization panel, configure the parameters, and click OK.
Parameter
Description
Effective For
Select the cloud-native gateway instance for which the authorization takes effect.
Select MCP Service
Select the MCP service to be authorized.
Available
The MCP services that are published to the gateway and can be selected.
Selected
The list of selected MCP services. Click View to the right of the target MCP service to view its details.
Remove authorization
Log on to the AI Gateway console.
In the navigation pane on the left, choose Consumers. In the top menu bar, select a region.
On the Consumer page, click the target consumer to go to the product page, and then click the Consumer Authorization tab.
You can remove authorization from a Model API or an MCP service.
Remove authorization from a Model API
Click the Model API tab.
In the Actions column for the target API, click Revoke Authorization. In the dialog box that appears, click Remoke.
Remove authorization from an MCP service
Click the MCP tab.
In the Actions column for the target service, click Revoke Authorization. In the dialog box that appears, click Remoke.
References
For more information, see Consumer authentication and authorization.