Skip to content
OpenClaw 不踩坑恶意 Skills ,企业需 Skills Registry:Nacos 3.2 发布Know more

Console API

Nacos provides Console APIs for the built-in Nacos console and custom console UI implementations. These APIs expose the data and interactions needed by console pages.

If you want to disable the default Nacos console UI and use a custom UI, read Console Manual first to confirm the console entry, port, and UI switch configurations.

0. Console API Notes

0.1. Scope

Console APIs are intended for the Nacos console and custom console UI. They serve page rendering, form submission, and console interaction flows.

Good FitNot a Good Fit
Custom Nacos console UI.Runtime access to configurations and services from business applications.
Integrating with page data and interaction flows already used by the default console.Building release platforms, audit platforms, or operations automation scripts.
Providing server-side data for a custom UI after disabling the default console UI.Replacing Admin API as a general management-plane integration.

Business applications should use SDKs or Client API. Operations platforms, release platforms, and automation scripts should prefer Admin API or Maintainer SDK.

0.2. Unified Path Format

Nacos Console APIs use a unified path format: [/$nacos.console.contextPath]/v3/console/[module]/[subPath]....

  • $nacos.console.contextPath: Root path of the console. The default value is empty, and it can be changed with the nacos.console.contextPath configuration item.
  • module: Console module name, such as server, cs, ns, or core.
  • subPath: Console subpath, such as state, namespace, or config. It may contain multiple path levels.

The Console APIs listed below use the default $nacos.console.contextPath. If the deployment changes $nacos.console.contextPath, update the request URL accordingly when calling the API.

The examples below also use the default Nacos Console port. If the deployment changes $nacos.console.port, update the request URL accordingly when calling the API.

0.3. Authentication

Nacos 3.X Console APIs enable authentication by default. Except for a small number of APIs marked as public, callers must provide valid identity information.

To disable Console API authentication, set nacos.core.auth.console.enabled=false and restart Nacos Console.

0.4. Swagger Documentation

Nacos 3.X Console APIs also provide Swagger-style documentation. You can view it at Nacos Swagger Console API.

1. Nacos Basic Console APIs

Basic Console APIs provide basic information about the Nacos cluster, such as cluster information and namespace information.

1.1. Get Cluster Status

Description

You can use this API to obtain basic status and switch information for the Nacos cluster, such as the version, startup mode, and whether authentication is enabled. This API does not return Nacos cluster node information.

Since

3.0.0

Request Method

GET

Authorization

Public API. No identity information is required.

Request URL

/v3/console/server/state

Request Parameters

None

Response Data

NameTypeDescription
versionstringVersion number of the Nacos cluster, for example 3.0.0
startup_modestringMode of the Nacos cluster, for example standalone, cluster
server_portintegerPrimary port of the Nacos cluster, for example 8848
function_modestringFunction mode of the Nacos cluster, for example config, naming, or all. If it is null, it is equivalent to all
datasource_platformstringData source type of the Nacos cluster, for example mysql or derby. If it is empty, the default data source type is used
console_ui_enabledbooleanWhether the Nacos console UI is enabled
auth_enabledbooleanWhether Nacos authentication is enabled
auth_admin_requestbooleanWhether Nacos needs to initialize the nacos admin user
auth_system_typestringAuthentication plugin type of Nacos, for example nacos. If it is empty, the default authentication system type is used
login_page_enabledbooleanWhether the Nacos console login page is enabled
plugin_datasource_log_enabledbooleanWhether Nacos enables Debug logs for data source access
config_retention_daysintegerConfiguration history retention days of the Nacos cluster
isManageCapacitybooleanWhether Nacos enables configuration capacity limit management. The default is true. When enabled, it only counts current configuration usage and does not reject requests after the limit is exceeded.
isCapacityLimitCheckbooleanWhether Nacos enables configuration capacity limit checking. The default is false. When enabled, configuration change requests are rejected if the configuration capacity exceeds the limit.
defaultMaxSizeintegerConfiguration file size limit of the Nacos cluster, in bytes. The default is 102400, which is 100 KB.
defaultGroupQuotaintegerConfiguration file count quota under a single group (GroupName) in the Nacos cluster. The default is 200.
defaultClusterQuotaintegerCluster-wide configuration file count quota of the Nacos cluster. The default is 100000.
isHealthCheckbooleanWhether Nacos enables health checks in the naming module. The default is true. When enabled, Nacos actively removes abnormal service instances registered with Nacos.
maxContentintegerDeprecated. Use defaultMaxSize.
defaultMaxAggrSizeintegerNot actually used. Deprecated.
defaultMaxAggrCountintegerNot actually used. Deprecated.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/server/state'
  • Response example
{
"defaultMaxSize": "102400",
"auth_system_type": "nacos",
"auth_enabled": "false",
"defaultMaxAggrSize": "1024",
"maxHealthCheckFailCount": "12",
"maxContent": "10485760",
"console_ui_enabled": "true",
"defaultMaxAggrCount": "10000",
"auth_admin_request": "false",
"defaultGroupQuota": "200",
"config_retention_days": "30",
"startup_mode": "standalone",
"isHealthCheck": "true",
"version": "3.0.0-SNAPSHOT",
"function_mode": null,
"isManageCapacity": "true",
"isCapacityLimitCheck": "false",
"datasource_platform": "",
"notifyConnectTimeout": "100",
"server_port": "8848",
"notifySocketTimeout": "200",
"defaultClusterQuota": "100000",
"login_page_enabled": "false",
"plugin_datasource_log_enabled": "false"
}

1.2. Get Console Announcement

Description

You can use this API to obtain the announcement that the Nacos console wants to display in the browser. The default Nacos console UI calls this API when authentication is not enabled, and the API returns a reminder that authentication is disabled for the cluster.

Since

3.0.0

Request Method

GET

Authorization

Public API. No identity information is required.

Request URL

/v3/console/server/announcement

Request Parameters

NameTypeRequiredDescription
languagestringNoLanguage i18n value for the request. The default is zh-CN; currently only zh-CN and en-US are supported.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringConsole announcement content

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/server/announcement?language=zh-CN'
  • Response example
{
"code": 0,
"message": "success",
"data": "Authentication is not enabled for the current cluster. See the <a href=\"https://nacos.io/en/docs/v2/guide/user/auth.html\">documentation</a> to enable authentication."
}

1.3. Get Console Guide Content

Description

You can use this API to obtain guide information for the Nacos console. The default Nacos console UI calls this API when the console UI is disabled to obtain guide information. For details, see Console Manual.

Since

3.0.0

Request Method

GET

Authorization

Public API. No identity information is required.

Request URL

/v3/console/server/guide

Request Parameters

None

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringConsole guide content

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/server/guide'
  • Response example
{
"code": 0,
"message": "success",
"data": "The Nacos open-source console is disabled on the current node. Set `nacos.console.ui.enabled=true` in `application.properties` to enable it. For details, see the console documentation."
}

1.4. Get Nacos Console Liveness Status

Description

You can use this API to obtain the liveness status of the Nacos console, that is, whether the Nacos console can normally accept and respond to requests.

Since

3.0.0

Request Method

GET

Authorization

Public API. No identity information is required.

Request URL

/v3/console/health/liveness

Request Parameters

None

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/health/liveness'
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

1.5. Get Nacos Console Readiness Status

Description

You can use this API to obtain whether the Nacos console is in a readable state, that is, whether the Nacos console can read data.

Since

3.0.0

Request Method

GET

Authorization

Public API. No identity information is required.

Request URL

/v3/console/health/readiness

Request Parameters

None

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when the console is readable; otherwise, the value is the unreadable module or corresponding reason information.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/health/readiness'
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

1.6. Get Nacos Node Runtime Information

Description

You can use this API to obtain Nacos node runtime information, including node IP, node runtime status, and node metadata.

Since

3.0.0

Request Method

GET

Authorization

Nacos administrator permission is required.

Request URL

/v3/console/core/cluster/nodes

Request Parameters

None.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/core/cluster/nodes'
  • Response example
{
"code": 0,
"message": "success",
"data": [
{
"ip": "127.0.0.1",
"port": 8848,
"state": "UP",
"extendInfo": {
"lastRefreshTime": 1733221062619,
"raftMetaData": {
"metaDataMap": {
"naming_instance_metadata": {
"leader": "127.0.0.1:7848",
"raftGroupMember": [
"127.0.0.1:7848"
],
"term": 1
},
"naming_persistent_service": {
"leader": "127.0.0.1:7848",
"raftGroupMember": [
"127.0.0.1:7848"
],
"term": 1
},
"naming_persistent_service_v2": {
"leader": "127.0.0.1:7848",
"raftGroupMember": [
"127.0.0.1:7848"
],
"term": 1
},
"naming_service_metadata": {
"leader": "127.0.0.1:7848",
"raftGroupMember": [
"127.0.0.1:7848"
],
"term": 1
}
}
},
"raftPort": "7848",
"readyToUpgrade": true,
"supportGrayModel": true,
"version": "3.0.0-SNAPSHOT"
},
"address": "127.0.0.1:8848",
"failAccessCnt": 0,
"abilities": {
"remoteAbility": {
"supportRemoteConnection": true,
"grpcReportEnabled": true
},
"configAbility": {
"supportRemoteMetrics": false
},
"namingAbility": {
"supportJraft": true
}
},
"grpcReportEnabled": true
}
]
}

1.7. Get Nacos Namespace List

Description

You can use this API to obtain the namespace list of the current Nacos cluster.

Since

3.0.0

Request Method

GET

Authorization

Any valid authentication identity is required.

Because namespace is the basic isolation concept in Nacos, most data query APIs must select a namespace before querying data. Therefore, any user with a valid identity should be able to access the namespace list.

Request URL

/v3/console/core/namespace/list

Request Parameters

None

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
namespacestringnamespace ID
namespaceShowNamestringnamespace name
namespaceDescstringnamespace description
configCountintegernumber of configurations in the namespace
quotaintegerconfiguration count quota of the namespace. It takes effect only after configuration quota is enabled. It is disabled by default and reserved only.
typeintegernamespace type. Reserved field. Currently, 0 indicates the default namespace, and 2 indicates a custom namespace.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/core/namespace/list'
  • Response example
{
"code": 0,
"message": "success",
"data": [
{
"namespace": "public",
"namespaceShowName": "public",
"namespaceDesc": "Default Namespace",
"quota": 200,
"configCount": 0,
"type": 0
}
]
}

1.8. Get Namespace Details

Description

You can use this API to obtain the details of a specified namespace.

Since

3.0.0

Request Method

GET

Authorization

Nacos administrator permission is required.

Request URL

/v3/console/core/namespace

Request Parameters

NameTypeRequiredDescription
namespaceIdstringYesnamespace ID.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
namespacestringnamespace ID
namespaceShowNamestringnamespace name
namespaceDescstringnamespace description
configCountintegernumber of configurations in the namespace
quotaintegerconfiguration count quota of the namespace. It takes effect only after configuration quota is enabled. It is disabled by default and reserved only.
typeintegernamespace type. Reserved field. Currently, 0 indicates the default namespace, and 2 indicates a custom namespace.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/core/namespace?namespaceId=public'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"namespace": "public",
"namespaceShowName": "public",
"namespaceDesc": "Default Namespace",
"quota": 200,
"configCount": 0,
"type": 0
}
}

1.9. Create Namespace

Description

You can use this API to create a namespace.

Since

3.0.0

Request Method

POST

Authorization

Nacos administrator permission is required.

Request URL

/v3/console/core/namespace

Request Parameters

NameTypeRequiredDescription
customNamespaceIdstringNoNamespace ID. If it is not specified, a UUID is used to generate the ID.
namespaceNamestringYesnamespace name.
namespaceDescstringNonamespace description.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether namespace creation succeeded.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/core/namespace' -d 'namespaceName=test&namespaceDesc=test'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

1.10. Update Namespace

Description

You can use this API to update namespace information. The namespace ID cannot be updated; only the name and description can be updated.

Since

3.0.0

Request Method

PUT

Authorization

Nacos administrator permission is required.

Request URL

/v3/console/core/namespace

Request Parameters

NameTypeRequiredDescription
namespaceIdstringYesnamespace ID
namespaceNamestringYesnamespace name.
namespaceDescstringNonamespace description.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether namespace update succeeded.

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/core/namespace' -d 'namespaceId=test&namespaceName=test&namespaceDesc=test'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

1.11. Delete Namespace

Description

You can use this API to delete a namespace. The default public namespace cannot be deleted.

Since

3.0.0

Request Method

DELETE

Authorization

Nacos administrator permission is required.

Request URL

/v3/console/core/namespace

Request Parameters

NameTypeRequiredDescription
namespaceIdstringYesnamespace ID.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether namespace deletion succeeded.

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/core/namespace?namespaceId=test'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

1.12. Check Whether a Namespace Exists

Description

You can use this API to check whether a namespace ID exists. The default console calls this API before creating a namespace to confirm whether the custom namespace ID already exists and avoid conflicts.

Since

3.0.0

Request Method

GET

Authorization

Any valid authentication identity is required.

Request URL

/v3/console/core/namespace/exist

Request Parameters

NameTypeRequiredDescription
customNamespaceIdstringYesNamespace ID. If an empty string is passed, a UUID is considered to need automatic generation.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanWhether the namespace exists. The value is true if it exists; otherwise, it is false.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/core/namespace/exist?customNamespaceId=test'
  • Response example
{
"code": 0,
"message": "success",
"data": false
}

1.13. Get Plugin Details

Description

You can use this API to obtain details about a specified plugin by type and name.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/plugin

Request Parameters

NameTypeRequiredDescription
pluginTypestringYesPlugin type, such as auth (authentication), control, or datasource.
pluginNamestringYesPlugin name, such as nacos-default-auth-plugin.

Response Data

NameTypeDescription
data.pluginIdstringplugin unique identifier.
data.pluginTypestringplugin type.
data.pluginNamestringplugin name.
data.enabledbooleanwhether it is currently enabled.
data.criticalbooleanwhether it is a critical plugin (critical plugins cannot be disabled).
data.configurablebooleanwhether dynamic configuration in the console is supported.
data.configobjectcurrent plugin configuration items.
data.configDefinitionsarrayplugin configuration item definition list, used to render the configuration form.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/plugin?pluginType=auth&pluginName=nacos-default-auth-plugin'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"name": "nacos-default-auth-plugin",
"type": "auth",
"enabled": true,
"config": {}
}
}

1.14. Query Plugin Availability on Cluster Nodes

Description

You can use this API to obtain the availability of a specified plugin on each cluster node.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/plugin/availability

Request Parameters

NameTypeRequiredDescription
pluginTypestringYesPlugin type, such as auth, control, or datasource.
pluginNamestringYesplugin name.

Response Data

The returned data is a Map<node address, availability>. The key is the Nacos node address, such as 127.0.0.1:8848, and the value indicates whether the plugin is available on that node.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/plugin/availability?pluginType=auth&pluginName=nacos-default-auth-plugin'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"127.0.0.1:8848": true
}
}

1.15. Update Plugin Configuration

Description

You can use this API to update plugin configuration. You must provide the plugin type, name, and configuration content.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/plugin/config

Request Parameters

NameTypeRequiredDescription
pluginTypestringYesplugin type.
pluginNamestringYesplugin name.
configstringNoPlugin configuration content as a JSON object. Specific fields are defined by the plugin.

Response Data

NameTypeDescription
datastringOperation result description.

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/plugin/config' \
-d 'pluginType=auth' \
-d 'pluginName=nacos-default-auth-plugin' \
-d 'config={}'
  • Response example
{
"code": 0,
"message": "success",
"data": "Plugin configuration updated successfully"
}

1.16. Get Plugin List

Description

You can use this API to obtain the plugin list. You can filter the list by plugin type.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/plugin/list

Request Parameters

NameTypeRequiredDescription
pluginTypestringNoPlugin type. If not specified, plugins of all types are returned.

Response Data

The returned data is an array of plugin information. Each item contains the plugin name, type, enabled status, and other fields.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/plugin/list?pluginType=auth'
  • Response example
{
"code": 0,
"message": "success",
"data": [
{
"name": "nacos-default-auth-plugin",
"type": "auth",
"enabled": true
}
]
}

1.17. Enable or Disable a Plugin

Description

You can use this API to update whether a plugin is enabled or disabled.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/plugin/status

Request Parameters

NameTypeRequiredDescription
pluginTypestringYesplugin type.
pluginNamestringYesplugin name.
enabledbooleanYesWhether it is enabled. true means enabled, and false means disabled.
localOnlybooleanNowhether to update only the plugin status on the local node.

Response Data

NameTypeDescription
datastringOperation result description.

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/plugin/status' \
-d 'pluginType=auth' \
-d 'pluginName=nacos-default-auth-plugin' \
-d 'enabled=True'
  • Response example
{
"code": 0,
"message": "success",
"data": "Plugin status updated successfully"
}

2. Configuration Management

2.1. Get Configuration Details

Description

You can use this API to obtain the details of a specified configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config

Request Parameters

NameTypeRequiredDescription
dataIdstringYesconfiguration ID.
groupNamestringYesconfiguration group.
namespaceIdstringNoNamespace ID. The default is public

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
idstringConfiguration ID in the storage system, usually a string of the Long type.
dataIdstringconfiguration ID.
groupNamestringconfiguration group.
namespaceIdstringnamespace ID.
contentstringconfiguration content.
descstringconfiguration description.
md5stringMD5 value of the configuration content.
configTagsstringconfiguration tags.
encryptedDataKeystringkey used to encrypt configuration content. Exists when the configuration encryption plugin is used.
appNamestringapplication name to which the configuration belongs.
typestringconfiguration type.
createTimeintegerconfiguration creation time.
modifyTimeintegerconfiguration modification time.
createUserstringconfiguration creator.
createIpstringconfiguration creation IP.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/cs/config?dataId=test&groupName=test'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"appName": "",
"configTags": null,
"content": "test",
"createIp": "127.0.0.1",
"createTime": 1741681316620,
"createUser": "nacos",
"dataId": "test",
"desc": null,
"encryptedDataKey": "",
"groupName": "test",
"id": "873472517803610112",
"md5": "098f6bcd4621d373cade4e832627b4f6",
"modifyTime": 1741681316620,
"namespaceId": "public",
"type": "text"
}
}

2.2. Publish Configuration

Description

You can use this API to create a new configuration or update an existing configuration.

Since

3.0.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config

Request Parameters

NameTypeRequiredDescription
dataIdstringYesconfiguration ID.
groupNamestringYesconfiguration group.
namespaceIdstringNoNamespace ID. The default is public
contentstringYesconfiguration content.
descstringNoconfiguration description.
typestringNoConfiguration type. The default is text.
configTagsstringNoConfiguration tags. Multiple tags are separated by English commas.
appNamestringNoApplication name to which the configuration belongs. It is mainly used to mark the application that uses the configuration.
  • When the configuration already exists with the same dataId and groupName, calling this API again updates the configuration.
  • When publishing a configuration, if the request Header contains betaIps, the configuration is marked as a BETA configuration. Before the BETA release is stopped or fully published, the console UI must handle it specially.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether configuration creation succeeded.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/cs/config' -d 'dataId=test&groupName=test&namespaceId=public&content=test'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

2.3. Delete Configuration

Description

You can use this API to delete a specified configuration.

Since

3.0.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config

Request Parameters

NameTypeRequiredDescription
dataIdstringYesconfiguration ID.
groupNamestringYesconfiguration group.
namespaceIdstringNoNamespace ID. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether configuration deletion succeeded.

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/cs/config?dataId=test&groupName=test'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

2.4. Batch Delete Configurations

Description

You can use this API to batch delete specified configurations.

Since

3.0.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config/batchDelete

Request Parameters

NameTypeRequiredDescription
idsarrayYesConfiguration storage ID list, not a dataId list. Separate multiple IDs with commas.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
databooleanwhether configuration deletion succeeded.

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/cs/config/batchDelete?ids=838025461287096320,838025489170829312'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

2.5. Query Configuration List

Description

You can use this API to query the configuration list in a specified namespace.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYescurrent page number, starts from 1.
pageSizeintegerYesnumber of configurations displayed per page.
dataIdstringYesConfiguration ID. When search is blur, you can use * for fuzzy search, such as test*. When the value is empty or missing, all configurations that match the groupName condition are queried.
groupNamestringYesConfiguration group. When search is blur, you can use * for fuzzy search, such as test*. When the value is empty or missing, all configurations that match the dataId condition are queried.
searchstringNoblur or accurate
namespaceIdstringNoNamespace ID. The default is public.
appNamestringNoApplication name to which the configuration belongs. The default is empty. When specified, configurations belonging to this application are filtered; when empty, configurations for all applications are queried.
configTagsstringNoConfiguration tags separated by English commas. The default is empty. When specified, configurations with this tag are filtered; when empty, configurations for all tags are queried.
typestringNoConfiguration type. The default is empty. When specified, configurations of this type are filtered; when empty, configurations of all types are queried.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of configurations that match the rule.
pagesAvailableintegertotal number of available pages.
pageNumberintegercurrent page number.
pageItemsListlist of configurations that match the rule.
pageItems[i].idstringConfiguration ID in the storage system, usually a string of the Long type.
pageItems[i].dataIdstringconfiguration ID.
pageItems[i].groupNamestringconfiguration group.
pageItems[i].namespaceIdstringnamespace ID.
pageItems[i].md5stringMD5 value of the configuration content.
pageItems[i].appNamestringapplication name to which the configuration belongs.
pageItems[i].typestringconfiguration type.
pageItems[i].createTimeintegerconfiguration creation time.
pageItems[i].modifyTimeintegerconfiguration modification time.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/cs/config/list?dataId=&groupName=&appName=&configTags=&pageNo=1&pageSize=10&namespaceId=&type=&search=blur'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"pageItems": [
{
"appName": "",
"createTime": 0,
"dataId": "aaa",
"groupName": "DEFAULT_GROUP",
"id": "873471898128748544",
"md5": null,
"modifyTime": 0,
"namespaceId": "public",
"type": "text"
},
{
"appName": "",
"createTime": 0,
"dataId": "bbb",
"groupName": "DEFAULT_GROUP",
"id": "873473460813172736",
"md5": null,
"modifyTime": 0,
"namespaceId": "public",
"type": "text"
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 2
}
}

2.6. Query Configurations by Content

Description

You can use this API to query the list of configurations that match configuration content.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/searchDetail

Request Parameters

NameTypeRequiredDescription
pageNointegerYescurrent page number, starts from 1.
pageSizeintegerYesnumber of configurations displayed per page.
searchstringNoblur or accurate
namespaceIdstringNoNamespace ID. The default is public.
dataIdstringNoConfiguration ID. When search is blur, you can use * for fuzzy search, such as test*. When the value is empty or missing, all configurations that match the groupName condition are queried.
groupNamestringNoConfiguration group. When search is blur, you can use * for fuzzy search, such as test*. When the value is empty or missing, all configurations that match the dataId condition are queried.
appNamestringNoApplication name to which the configuration belongs. The default is empty. When specified, configurations belonging to this application are filtered; when empty, configurations for all applications are queried.
configTagsstringNoConfiguration tags separated by English commas. The default is empty. When specified, configurations with this tag are filtered; when empty, configurations for all tags are queried.
typestringNoConfiguration type. The default is empty. When specified, configurations of this type are filtered; when empty, configurations of all types are queried.
configDetailstringYesConfiguration content search condition, used to filter by configuration content. Fuzzy matching is supported, such as *11*.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of configurations that match the rule.
pagesAvailableintegertotal number of available pages.
pageNumberintegercurrent page number.
pageItemsListlist of configurations that match the rule.
pageItems[i].idstringConfiguration ID in the storage system, usually a string of the Long type.
pageItems[i].dataIdstringconfiguration ID.
pageItems[i].groupNamestringconfiguration group.
pageItems[i].namespaceIdstringnamespace ID.
pageItems[i].md5stringMD5 value of the configuration content.
pageItems[i].appNamestringapplication name to which the configuration belongs.
pageItems[i].typestringconfiguration type.
pageItems[i].createTimeintegerconfiguration creation time.
pageItems[i].modifyTimeintegerconfiguration modification time.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/cs/config/searchDetail?dataId=&groupName=&appName=&configTags=&pageNo=1&pageSize=10&namespaceId=&type=&search=blur&configDetail=*11*'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"pageItems": [
{
"appName": "",
"createTime": 0,
"dataId": "111",
"groupName": "DEFAULT_GROUP",
"id": "873475812546842624",
"md5": null,
"modifyTime": 0,
"namespaceId": "public",
"type": "text"
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 1
}
}

2.7. Query Configuration Listener List

Description

You can use this API to query the listener list of a specified configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/listener

Request Parameters

NameTypeRequiredDescription
dataIdstringYesconfiguration ID.
groupNamestringYesconfiguration group.
namespaceIdstringNoNamespace ID. The default is public.
aggregationbooleanNoWhether to query with aggregation.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
queryTypestringSubscriber query type. This API is config.
listenersStatusmap<string, string>Subscriber list. The key is the subscriber IP, and the value is the MD5 value of the current configuration subscribed to by the subscriber.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/cs/config/listener?dataId=test&groupName=test'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"listenersStatus": {
"127.0.0.1": "32cacc65accfdab47954de3fc781e938"
},
"queryType": "config"
}
}

2.8. Query Configurations Subscribed by a Subscriber IP

Description

You can use this API to query which configurations are subscribed to by a specified subscriber IP.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/listener/ip

Request Parameters

NameTypeRequiredDescription
ipstringYessubscriber IP.
allbooleanNoWhether to query all subscription data.
namespaceIdstringNoNamespace ID. The default is public.
aggregationbooleanNoWhether to query with aggregation.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
queryTypestringSubscriber query type. This API is ip.
listenersStatusmap<string, string>Subscriber list. The key is the subscribed configuration information in the format dataId + groupName + namespaceId, and the value is the MD5 value of the current configuration subscribed to by the subscriber.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/cs/config/listener/ip?ip=127.0.0.1'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"listenersStatus": {
"qtc-user.yaml+DEFAULT_GROUP+public": "32cacc65accfdab47954de3fc781e938"
},
"queryType": "ip"
}
}

2.9. Export Configurations

Description

You can use this API to export selected or queried configurations as a ZIP file for backup or import into another Nacos cluster.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/export2

Request Parameters

NameTypeRequiredDescription
dataIdstringNoPattern of configuration IDs to export, for example test*.
groupNamestringNoPattern of configuration groups to export, for example test*.
idsarrayNoConfiguration storage ID list. Separate multiple IDs with commas.
namespaceIdstringNoNamespace ID. The default is public.
appNamestringNoapplication name to which the configurations to export belong.

It is recommended to use either ids or the dataId + groupName combination. Choose only one method and pass an empty string for the other type. Otherwise, the exported file may be empty.

Response Data

When export succeeds, the response is a byte-array file. The file is returned in attachment mode. When export fails, the response body follows the Nacos Open API unified response format.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/cs/config/export2?dataId=&groupId=&ids=" --output ~/test.zip
  • Response example
Terminal window
unzip ~/test.zip
> Archive: /path/to/test.zip
> inflating: DEFAULT_GROUP/111
> inflating: DEFAULT_GROUP/qtc-user.yaml
> inflating: .metadata.yml

2.10. Import Configurations

Description

You can use this API to import a ZIP file exported from Nacos into a specified Nacos namespace.

Since

3.0.0

Request Method

POST

Request body type: multipart/form-data.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config/import

Request Parameters

NameTypeRequiredDescription
fileMultipartFileNoimported ZIP file.
namespaceIdstringNoNamespace ID to which the imported configurations belong. The default is public.
policystringNoImport policy used when imported configurations have the same dataId and groupName and conflict. Valid values are ABORT (abort import), SKIP (skip conflicting configurations), and OVERWRITE (overwrite conflicting configurations). The default is ABORT.
src_userstringNosource user identifier for the import operation.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
succCountintegernumber of configurations imported successfully.
skipCountintegernumber of configurations skipped during import.

Examples

  • Request example
Terminal window
curl -vX POST "http://127.0.0.1:8080/v3/console/cs/config/import" -F "file=@/path/to/test.zip" -F "namespaceId=test"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"succCount": 2,
"skipCount": 0
}
}

2.11. Clone Configurations

Description

You can use this API to clone selected or queried configurations to another namespace.

Since

3.0.0

Request Method

POST

Request body type: application/json, with a configuration list array.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config/clone

Request Parameters

NameTypeRequiredDescription
srcUserstringNosource user identifier for the clone operation.
targetNamespaceIdstringYestarget namespace ID.
policystringNoClone policy used when configurations have the same dataId and groupName and conflict. Valid values are ABORT (abort cloning), SKIP (skip conflicting configurations), and OVERWRITE (overwrite conflicting configurations). The default is ABORT.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
succCountintegernumber of configurations cloned successfully.
skipCountintegernumber of configurations skipped during cloning.

Examples

  • Request example
Terminal window
curl -H "Content-Type: application/json" -X POST "http://127.0.0.1:8080/v3/console/cs/config/clone?targetNamespaceId=public&policy=ABORT" -d "[{\"cfgId\":838029534438625280,\"dataId\":\"111\",\"group\":\"DEFAULT_GROUP\"},{\"cfgId\":838033747294031872,\"dataId\":\"qtc-user.yaml\",\"group\":\"DEFAULT_GROUP\"}]"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"succCount": 2,
"skipCount": 0
}
}

2.12. Stop Configuration BETA Release

Description

You can use this API to stop a configuration from the BETA publishing state, that is, roll back the configuration BETA publishing state.

Since

3.0.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/cs/config/beta

Request Parameters

NameTypeRequiredDescription
dataIdstringYesConfiguration dataId.
groupNamestringYesConfiguration groupName.
namespaceIdstringNoNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription

Examples

  • Request example
Terminal window
curl -X DELETE "http://127.0.0.1:8080/v3/console/cs/config/beta?dataId=test&groupName=DEFAULT_GROUP"
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

2.13. Query Configuration BETA Release Status

Description

You can use this API to query the BETA publishing status of a configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/config/beta

Request Parameters

NameTypeRequiredDescription
dataIdstringYesConfiguration dataId.
groupNamestringYesConfiguration groupName.
namespaceIdstringNoNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
idstringbetaconfiguration storage ID.
dataIdstringConfiguration dataId.
groupNamestringConfiguration groupName.
namespaceIdstringnamespace to which the configuration belongs.
descstringconfiguration description.
md5stringMD5 value of the configuration content.
configTagsstringconfiguration tags.
encryptedDataKeystringkey used to encrypt configuration content. Exists when the configuration encryption plugin is used.
appNamestringapplication name to which the configuration belongs.
typestringconfiguration type.
createTimeintegerconfiguration creation time.
modifyTimeintegerconfiguration modification time.
createUserstringconfiguration creator.
createIpstringconfiguration creation IP.
grayNamestringGray release rule name. Fixed as beta.
grayRulestringGray release rule in JSON format. The expr field is the beta IP list.

Examples

  • Request example
Terminal window
curl "http://127.0.0.1:8080/v3/console/cs/config/beta?dataId=111&groupName=DEFAULT_GROUP"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"appName": "",
"configTags": null,
"content": "bbb11xxccc",
"createIp": null,
"createTime": 0,
"createUser": "nacos",
"dataId": "111",
"desc": null,
"encryptedDataKey": null,
"grayName": "beta",
"grayRule": "{\"type\":\"beta\",\"version\":\"1.0.0\",\"expr\":\"1.1.1.1\",\"priority\":2147483647}",
"groupName": "DEFAULT_GROUP",
"id": "873481464488923136",
"md5": "2f080e5e21ba12bb8ca6894ac0fc5862",
"modifyTime": 1741683449619,
"namespaceId": "public",
"type": null
}
}

2.14. Query Configuration Publishing History

Description

You can use this API to query the publishing history of a configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/history/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYescurrent page number, starts from 1
pageSizeintegerYesnumber of records displayed per page.
dataIdstringYesConfiguration dataId.
groupNamestringYesConfiguration groupName.
namespaceIdstringNoNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of history records.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListhistory record list.
pageItems[i].idstringhistory record ID.
pageItems[i].dataIdstringConfiguration dataId.
pageItems[i].groupNamestringConfiguration groupName.
pageItems[i].namespaceIdstringnamespace to which the configuration belongs.
pageItems[i].appNamestringappName to which the configuration belongs.
pageItems[i].opTypestringOperation type. I means insert, U means update, and D means delete.
pageItems[i].publishTypestringPublish type. formal means normal publish, and gray means beta publish.
pageItems[i].srcIpstringsource IP of the publish operation.
pageItems[i].srcUserstringPublishing user. This field exists only when authentication is enabled and the configuration is published after a user logs in.
pageItems[i].createTimeintegerconfiguration creation time.
pageItems[i].modifyTimeintegerconfiguration modification time.

Examples

  • Request example
Terminal window
curl "http://127.0.0.1:8080/v3/console/cs/history/list?pageNo=1&pageSize=10&dataId=111&groupName=DEFAULT_GROUP"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"pageItems": [
{
"appName": "",
"createTime": 1272988800000,
"dataId": "111",
"groupName": "DEFAULT_GROUP",
"id": "18",
"md5": null,
"modifyTime": 1741683760489,
"namespaceId": "public",
"opType": "D ",
"publishType": "gray",
"srcIp": "127.0.0.1",
"srcUser": "nacos",
"type": null
},
{
"appName": "",
"createTime": 1272988800000,
"dataId": "111",
"groupName": "DEFAULT_GROUP",
"id": "17",
"md5": null,
"modifyTime": 1741683449619,
"namespaceId": "public",
"opType": "I ",
"publishType": "gray",
"srcIp": "0:0:0:0:0:0:0:1",
"srcUser": "nacos",
"type": null
},
{
"appName": "",
"createTime": 1272988800000,
"dataId": "111",
"groupName": "DEFAULT_GROUP",
"id": "7",
"md5": null,
"modifyTime": 1741682102157,
"namespaceId": "public",
"opType": "I ",
"publishType": "formal",
"srcIp": "0:0:0:0:0:0:0:1",
"srcUser": "nacos",
"type": null
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 3
}
}

2.15. Query a Configuration History Change Record

Description

You can use this API to query a specific history change record of a configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/history

Request Parameters

NameTypeRequiredDescription
nidintegerYeshistory record ID.
dataIdstringYesConfiguration dataId.
groupNamestringYesConfiguration groupName.
namespaceIdstringNoNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
idstringhistory record ID.
dataIdstringConfiguration dataId.
groupNamestringConfiguration groupName.
namespaceIdstringnamespace to which the configuration belongs.
contentstring
appNamestringappName to which the configuration belongs.
opTypestringOperation type. I means insert, U means update, and D means delete.
publishTypestringPublish type. formal means normal publish, and gray means beta publish.
srcIpstringsource IP of the publish operation.
srcUserstringPublishing user. This field exists only when authentication is enabled and the configuration is published after a user logs in.
createTimeintegerconfiguration creation time.
modifyTimeintegerconfiguration modification time.
grayNamestringGray release rule name. Fixed as beta.
extInfoJsonStringExtended information. Currently includes src_user, type, and c_desc. If publishType is gray, it also includes grayRule.

Examples

  • Request example
Terminal window
curl "http://127.0.0.1:8080/v3/console/cs/history?dataId=111&groupName=DEFAULT_GROUP&nid=7"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"appName": "",
"content": "bbb11xx",
"createTime": 1272988800000,
"dataId": "111",
"encryptedDataKey": "",
"extInfo": "{\"src_user\":\"nacos\",\"type\":\"text\",\"c_desc\":\"111\"}",
"grayName": "",
"groupName": "DEFAULT_GROUP",
"id": "7",
"md5": "7d37afdb0b04d958d529bcb6de44fa71",
"modifyTime": 1741682102157,
"namespaceId": "public",
"opType": "I ",
"publishType": "formal",
"srcIp": "0:0:0:0:0:0:0:1",
"srcUser": "nacos",
"type": null
}
}

2.16. Query Previous Change History Before the Latest Configuration State

Description

You can use this API to query the previous change history before the latest state of a configuration.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/history/previous

Request Parameters

NameTypeRequiredDescription
idintegerYesconfiguration storage ID.
dataIdstringYesConfiguration dataId.
groupNamestringYesConfiguration groupName.
namespaceIdstringNoNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
idstringhistory record ID.
dataIdstringConfiguration dataId.
groupNamestringConfiguration groupName.
namespaceIdstringnamespace to which the configuration belongs.
contentstring
appNamestringappName to which the configuration belongs.
opTypestringOperation type. I means insert, U means update, and D means delete.
publishTypestringPublish type. formal means normal publish, and gray means beta publish.
srcIpstringsource IP of the publish operation.
srcUserstringPublishing user. This field exists only when authentication is enabled and the configuration is published after a user logs in.
createTimeintegerconfiguration creation time.
modifyTimeintegerconfiguration modification time.
grayNamestringGray release rule name. Fixed as beta.
extInfoJsonStringExtended information. Currently includes src_user, type, and c_desc. If publishType is gray, it also includes grayRule.

Examples

  • Request example
Terminal window
curl "http://127.0.0.1:8080/v3/console/cs/history/previous?id=838029534438625280&dataId=111&groupName=DEFAULT_GROUP"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"appName": "",
"content": "bbb11xx",
"createTime": 1272988800000,
"dataId": "111",
"encryptedDataKey": "",
"extInfo": "{\"src_user\":\"nacos\",\"type\":\"text\",\"c_desc\":\"111\"}",
"grayName": "",
"groupName": "DEFAULT_GROUP",
"id": "7",
"md5": "7d37afdb0b04d958d529bcb6de44fa71",
"modifyTime": 1741682102157,
"namespaceId": "public",
"opType": "I ",
"publishType": "formal",
"srcIp": "0:0:0:0:0:0:0:1",
"srcUser": "nacos",
"type": null
}
}

2.17. Query Configuration List in a Namespace

Description

You can use this API to query the configuration list in a namespace. It returns only dataId and groupName for the drop-down selection in the configuration history UI.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/cs/history/configs

Request Parameters

NameTypeRequiredDescription
namespaceIdstringYesNamespace ID to which the configuration belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
dataIdstringConfiguration dataId.
groupNamestringConfiguration groupName.

All other fields are unused.

Examples

  • Request example
Terminal window
curl "http://127.0.0.1:8080/v3/console/cs/history/configs?namespaceId=public"
  • Response example
{
"code": 0,
"message": "success",
"data": [
{
"appName": "",
"createTime": 0,
"dataId": "111",
"groupName": "DEFAULT_GROUP",
"id": "0",
"md5": null,
"modifyTime": 1741682102161,
"namespaceId": "public",
"type": "text"
},
{
"appName": "",
"createTime": 0,
"dataId": "qtc-user.yaml",
"groupName": "DEFAULT_GROUP",
"id": "0",
"md5": null,
"modifyTime": 1741682291519,
"namespaceId": "public",
"type": "text"
}
]
}

3. Service Management

3.1. Create Service

Description

You can use this API to create an empty service.

Since

3.0.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/service

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
protectThresholdnumberNoService protection threshold. The default is 0.0.
selectorstringNoService selector. The default is {"type":"none"}, which means no selector. Routing by label is also supported.
metadatastringNoService metadata. The default is {}.
ephemeralbooleanNoWhether the service is ephemeral. The default is false, meaning a persistent service.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when creation succeeds.

Examples

  • Request example
Terminal window
curl -X POST "http://127.0.0.1:8080/v3/console/ns/service" -d "serviceName=test&groupName=DEFAULT_GROUP&namespaceId=public"
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

3.2. Delete Service

Description

You can use this API to delete a service.

Since

3.0.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/service

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when deletion succeeds.

Examples

  • Request example
Terminal window
curl -X DELETE "http://127.0.0.1:8080/v3/console/ns/service?serviceName=test&groupName=DEFAULT_GROUP&namespaceId=public"
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

3.3. Update Service Metadata

Description

You can use this API to update service metadata. Only service metadata, such as metadata and selector, can be updated. The service serviceName, groupName, and namespaceId cannot be updated.

Since

3.0.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/service

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
protectThresholdnumberNoService protection threshold. The default is 0.0.
ephemeralbooleanNoWhether it is an ephemeral instance, such as true or false.
selectorstringNoService selector. The default is {"type":"none"}, which means no selector. Routing by label is also supported.
metadatastringNoService metadata. The default is {}.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when update succeeds.

Examples

  • Request example
Terminal window
curl -X PUT "http://127.0.0.1:8080/v3/console/ns/service" -d "serviceName=test&groupName=DEFAULT_GROUP&namespaceId=public&protectThreshold=0"
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

3.4. Get Supported Service Selector Type List

Description

You can use this API to obtain the list of supported service selector types. The console UI uses it to render the selector type drop-down when creating or updating services.

Since

3.0.0

Request Method

GET

Authorization

Any valid authentication identity is required.

Request URL

/v3/console/ns/service/selector/types

Request Parameters

None

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
labelstringFilter routing selection by label expression.
nonestringNo selector.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/ns/service/selector/types"
  • Response example
{
"code": 0,
"message": "success",
"data": [
"label",
"none"
]
}

3.5. Query Service List

Description

You can use this API to query the service list in a specified namespace.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ns/service/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYesPage number, starting from 1.
pageSizeintegerYesPage size.
serviceNameParamstringNoService name pattern. Queries all services when empty.
groupNameParamstringNoGroup name pattern of the service. Queries all services when empty.
namespaceIdstringNonamespace ID to which the service belongs.
ignoreEmptyServicebooleanNoWhether to return only services with instances. Defaults to false, meaning empty services are included.
withInstancesbooleanNoWhether to return service instance details. Defaults to false.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of services that match the condition.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListservice list.
pageItems[i].namestringservice name.
pageItems[i].groupNamestringgroup name of the service.
pageItems[i].clusterCountstringnumber of clusters under the service.
pageItems[i].ipCountstringnumber of instances under the service.
pageItems[i].healthyInstanceCountstringnumber of healthy instances under the service.
pageItems[i].triggerFlagstringwhether service protection is triggered.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/ns/service/list?pageNo=1&pageSize=10&namespaceId=public"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"pageItems": [
{
"clusterCount": 1,
"groupName": "DEFAULT_GROUP",
"healthyInstanceCount": 1,
"ipCount": 1,
"name": "com.test.SyncCallbackService",
"triggerFlag": "false"
},
{
"clusterCount": 1,
"groupName": "DEFAULT_GROUP",
"healthyInstanceCount": 0,
"ipCount": 1,
"name": "test",
"triggerFlag": "true"
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 2
}
}

3.6. Query Service Subscriber List

Description

You can use this API to query the subscriber list of a specified service.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ns/service/subscribers

Request Parameters

NameTypeRequiredDescription
pageNointegerYesPage number, starting from 1.
pageSizeintegerYesPage size.
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
aggregationbooleanNoWhether to aggregate the query.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of services that match the condition.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListservice list.
pageItems[i].ipstringsubscriber IP.
pageItems[i].portintegersubscriber port.
pageItems[i].addressstringSubscriber address, usually ip:port.
pageItems[i].agentstringsubscriber client version.
pageItems[i].appNamestringapplication to which the subscriber belongs.
pageItems[i].namespaceIdstringnamespace to which the subscriber belongs.
pageItems[i].groupNamestringsubscribed group name.
pageItems[i].serviceNamestringsubscribed service name.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/ns/service/subscribers?pageNo=1&pageSize=10&serviceName=test&groupName=DEFAULT_GROUP"
  • Response example
{
"code": 0,
"data": {
"pageItems": [
{
"address": "127.0.0.1:0",
"agent": "Nacos-Java-Client:v3.0.0-BETA",
"appName": "unknown",
"groupName": "DEFAULT_GROUP",
"ip": "127.0.0.1",
"namespaceId": "public",
"port": 0,
"serviceName": "test"
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 1
},
"message": "success"
}

3.7. Query Service Details

Description

You can use this API to query the details of a specified service.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ns/service

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
namespaceIdstringnamespace ID to which the service belongs.
groupNamestringgroupName to which the service belongs.
serviceNamestringservice name.
ephemeralbooleanService persistence attribute. true means an ephemeral service, and false means a persistent service.
protectThresholdnumberservice protection threshold.
selectorjsonObjectservice selector.
metadatajsonObjectservice metadata.
clusterMapjsonObjectService cluster list. The key is the cluster name, and the value is the cluster details.
clusterMap.$ClusterName.clusterNamestringcluster name.
clusterMap.$ClusterName.healthCheckerjsonObjecthealth checker.
clusterMap.$ClusterName.healthyCheckPortintegerhealth check port.
clusterMap.$ClusterName.useInstancePortForCheckbooleanWhether to use the registered instance IP:Port for health checks.
clusterMap.$ClusterName.metadatajsonObjectcluster metadata.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/ns/service?serviceName=test"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"clusterMap": {
"DEFAULT": {
"clusterName": "DEFAULT",
"healthChecker": {
"type": "TCP"
},
"healthyCheckPort": 80,
"hosts": null,
"metadata": {},
"useInstancePortForCheck": true
}
},
"ephemeral": false,
"groupName": "DEFAULT_GROUP",
"metadata": {},
"namespaceId": "public",
"protectThreshold": 0.0,
"selector": {
"contextType": "NONE",
"type": "none"
},
"serviceName": "test"
}
}

3.8. Update Service Cluster Metadata

Description

You can use this API to update metadata for a specified service cluster.

Since

3.0.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/service/cluster

Request Parameters

NameTypeRequiredDescription
clusterNamestringYescluster name.
serviceNamestringYesservice name.
checkPortintegerYesHealth check port.
useInstancePort4CheckbooleanYesWhether to use the registered instance IP:Port for health checks.
healthCheckerstringYeshealth checker.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
metadatastringNoservice metadata.

The healthChecker parameter is a JSON string for the health checker. Three health checkers are currently supported:

  1. None: no health check, {"type":"NONE"}
  2. TCP: TCP port check, {"type":"TCP"}
  3. HTTP: HTTP port check, {"type":"HTTP","path":"/liveness","headers":"health"}. path is the HTTP URI, and headers are HTTP request headers.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when update succeeds.

Examples

  • Request example
Terminal window
curl -X PUT "http://127.0.0.1:8080/v3/console/ns/service/cluster" -d "serviceName=test&clusterName=DEFAULT&checkPort=80&useInstancePort4Check=true&healthChecker={\"type\":\"none\"}"
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

3.9. Query Service Instance List

Description

You can use this API to query the instance list of a specified service.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ns/instance/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYesPage number, starts from 1.
pageSizeintegerYesnumber of records per page.
serviceNamestringYesservice name.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
clusterNamestringNoCluster name. If not specified, instances in all clusters are queried.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of instances that match the condition.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListinstance list.
pageItems[i].instanceIdstringinstance ID.
pageItems[i].ipstringinstance IP.
pageItems[i].portintegerinstance port.
pageItems[i].weightnumberinstance weight.
pageItems[i].healthybooleanwhether the instance is healthy.
pageItems[i].enabledbooleanwhether the instance is online.
pageItems[i].ephemeralbooleanwhether the instance is ephemeral.
pageItems[i].clusterNamestringcluster to which the instance belongs.
pageItems[i].serviceNamestringService to which the instance belongs, in the format groupName@@serviceName.
pageItems[i].metadatamap<string, string>instance metadata.

Examples

  • Request example
Terminal window
curl -X GET "http://127.0.0.1:8080/v3/console/ns/instance/list?&serviceName=test&clusterName=DEFAULT&groupName=DEFAULT_GROUP&pageSize=10&pageNo=1"
  • Response example
{
"code": 0,
"message": "success",
"data": {
"pageItems": [
{
"clusterName": "DEFAULT",
"enabled": true,
"ephemeral": false,
"healthy": false,
"instanceHeartBeatInterval": 5000,
"instanceHeartBeatTimeOut": 15000,
"instanceId": "1.1.1.1#3306#DEFAULT#DEFAULT_GROUP@@test",
"instanceIdGenerator": "simple",
"ip": "1.1.1.1",
"ipDeleteTimeout": 30000,
"metadata": {},
"port": 3306,
"serviceName": "DEFAULT_GROUP@@test",
"weight": 1.0
}
],
"pageNumber": 1,
"pagesAvailable": 1,
"totalCount": 1
}
}

3.10. Update Instance Metadata

Description

You can use this API to update metadata for instances of a specified service, including weight and online/offline status. You cannot update the service name, group name, namespace, IP address, or port of an instance.

Since

3.0.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/instance

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
ipstringYesinstance IP.
portintegerYesinstance port.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
clusterNamestringNoCluster to which the instance belongs. The default is DEFAULT.
ephemeralbooleanNoWhether the instance is ephemeral. The default is true.
weightnumberNoinstance weight.
healthybooleanNoinstance health status.
enabledbooleanNowhether the instance is online.
metadatastringNoinstance metadata.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when update succeeds.

Examples

  • Request example
Terminal window
curl -X PUT "http://127.0.0.1:8080/v3/console/ns/instance" -d 'serviceName=test&clusterName=DEFAULT&groupName=DEFAULT_GROUP&ip=1.1.1.1&port=3306&ephemeral=true&weight=100&enabled=false&metadata=%7B%22%E5%95%A6%E5%95%A6%E5%95%A6%26%E5%95%B5%E5%95%B5%E5%95%B5%22%3A%22xxx%22%7D'
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

3.11. Delete Persistent Instance

Description

You can use this API to delete a persistent instance under a specified service. This API supports deleting only instances with ephemeral=false; it does not support deleting ephemeral instances.

Since

3.2.2

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ns/instance

Request Parameters

NameTypeRequiredDescription
serviceNamestringYesservice name.
ipstringYesinstance IP.
portintegerYesinstance port.
groupNamestringNoGroup name to which the service belongs. The default is DEFAULT_GROUP.
namespaceIdstringNoNamespace ID to which the service belongs. The default is public.
clusterNamestringNoCluster to which the instance belongs. The default is DEFAULT.
ephemeralbooleanNoWhether the instance is ephemeral. Only false is supported. The default is false.
healthybooleanNoWhether the instance is healthy.
weightnumberNoInstance weight.
enabledbooleanNoWhether the instance is enabled.
metadatastringNoInstance metadata as a JSON object string.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringFixed as ok when deletion succeeds.

Examples

  • Request example
Terminal window
curl -X DELETE "http://127.0.0.1:8080/v3/console/ns/instance?serviceName=test&clusterName=DEFAULT&groupName=DEFAULT_GROUP&ip=1.1.1.1&port=3306&ephemeral=false"
  • Response example
{
"code": 0,
"message": "success",
"data": "ok"
}

4. MCP Management

4.1. Query MCP Service Details

Description

You can use this API to query the details of a specified MCP service hosted on Nacos.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/mcp

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace ID of the MCP service. The default is public
mcpIdstringOne of two requiredMCP service ID (usually UUID). One of mcpId and mcpName must be provided (OpenAPI cannot express this constraint; at least one is required in practice). Prefer mcpId.
mcpNamestringOne of two requiredMCP service name template. One of mcpId and mcpName must be provided; prefer mcpId.
versionstringNoversion of the MCP service. If not specified, the latest version is returned

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
idstringMCP service ID, usually a UUID.
namestringMCP service name.
namespaceIdstringnamespace ID to which the MCP service belongs.
protocolstringMCP protocol, such as stdio, sse, streamable, http, or dubbo.
frontProtocolstringFrontend exposure protocol of the MCP service. It is generally used by protocol converters, such as gateways. If there is no converter, it is the same as protocol, such as stdio, sse, streamable, http, or dubbo.
descriptionstringMCP service description.
repositorystringrepository of the MCP service.
versionDetailVersionDetailqueried version information of the MCP service.
localServerConfigMap<String, Object>When the MCP service type is stdio, this information exists and records startup information for the local MCP service.
remoteServerConfigRemoteServerConfigWhen the MCP service type is non-stdio, this information exists and records remote service information.
enabledbooleanwhether the MCP service is enabled.
capabilitiesListCapability types supported by the MCP service, such as TOOL, PROMPT, or RESOURCE.
backendEndpointsListWhen the MCP service type is non-stdio, this information exists and records specific address information for accessing the remote service.
toolSpecMap<String, Object>This information exists when the capability types supported by the MCP service include TOOL; it records detailed tool configuration information.
allVersionsList<VersionDetail>list of all version details of the MCP service.

The VersionDetail structure is as follows:

NameTypeDescription
versionstringversion number of the MCP service.
release_datestringrelease time of the MCP service version.
is_latestbooleanwhether the MCP service version is the latest version.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/mcp?namespaceId=public&mcpName=test&mcpId=d7a64724-a556-4fe4-82fa-e806d43e00dc'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"id": "",
"name": "test",
"protocol": "stdio",
"frontProtocol": "stdio",
"description": "ceshi",
"repository": null,
"versionDetail": {
"version": "1.0.0",
"release_date": "2025-05-22T06:40:37Z",
"is_latest": true
},
"remoteServerConfig": null,
"localServerConfig": {
"test": {}
},
"enabled": true,
"capabilities": [],
"backendEndpoints": null,
"toolSpec": null,
"allVersions": [
{
"version": "1.0.0",
"release_date": "2025-05-22T06:40:37Z",
"is_latest": true
}
],
"namespaceId": "public"
}
}

4.2. Update MCP Service

Description

You can use this API to update an MCP service hosted on Nacos.

Since

3.0.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/mcp

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace ID of the MCP service. The default is public
latestbooleanNoWhether to update by the latest version, such as true.
serverSpecificationstringYesMCP service description details
toolSpecificationstringNoMCP service tool description details
endpointSpecificationstringNoRemote service address details of the MCP service. Takes effect only for non-stdio protocols
overrideExistingbooleanNowhether to overwrite the original endpointSpecification when updating the MCP service. It is not overwritten by default and takes effect only for non-stdio protocols

The details of the serverSpecification, toolSpecification, and endpointSpecification parameters are as follows:

serverSpecification

NameTypeDescription
idstringMCP service ID, usually a UUID. It must be passed to locate the MCP service to update.
namestringMCP service name.
protocolstringMCP protocol, such as stdio, sse, streamable, http, or dubbo.
frontProtocolstringFrontend exposure protocol of the MCP service. It is generally used by protocol converters, such as gateways. If there is no converter, it is the same as protocol, such as stdio, sse, streamable, http, or dubbo.
descriptionstringMCP service description.
repositorystringrepository of the MCP service.
versionDetailVersionDetailversion information of the MCP service.
versionstringSimple version information of the MCP service, mainly used for compatibility. If versionDetail is set, this field is invalid.
localServerConfigMap<String, Object>When the MCP service type is stdio, this information exists and records startup information for the local MCP service.
remoteServerConfigRemoteServerConfigWhen the MCP service type is non-stdio, this information exists and records remote service information.
enabledbooleanwhether the MCP service is enabled.
capabilitiesListCapability types supported by the MCP service, such as TOOL, PROMPT, or RESOURCE.

The VersionDetail structure is as follows:

NameTypeDescription
versionstringversion number of the MCP service.
release_datestringrelease time of the MCP service version.
is_latestbooleanwhether the MCP service version is the latest version.

toolSpecification

NameTypeDescription
toolsList<McpTool>Tool list provided by this MCP Server. Refer to the standard MCP protocol definition of MCP Tool.
toolsMetaMap<String, McpToolMeta>Additional metadata information of tools provided by this MCP Server. It can extend information that is not defined in the standard MCP protocol but is required during use. The key is the name of McpTool, and the value is extended metadata.
securitySchemesList<SecurityScheme>Security schemes of the MCP tool. Refer to the standard MCP protocol.

The McpTool structure is as follows:

NameTypeDescription
namestringMCP tool name
descriptionstringMCP tool description
inputSchemaMap<String, Object>Input parameter description of the MCP tool. Refer to the standard MCP protocol. It mainly contains Type, whether the parameter is required, Description, and other fields.

The McpToolMeta structure is as follows:

NameTypeDescription
invokeContextmap<string, string>Context information when the MCP tool is called, such as the backend service Path.
enabledbooleanwhether the MCP tool is enabled.
templatesmap<string, string>Template information of the MCP tool. Used to map parameters during protocol conversion.

The SecurityScheme structure is as follows:

NameTypeDescription
idstringSecurity scheme ID, which is used and referenced by MCP tools.
typestringSecurity scheme type. Possible values include http, apiKey, localEnv, or other custom extensions.
schemestringSecurity scheme subtype. Used when type is http. Possible values include basic or bearer.
instringSecurity scheme location. Possible values include query and header.
namestringSecurity scheme name. Used when type is apiKey or localEnv. For example, the key name of apiKey or the environment name of localEnv.
defaultCredentialstringDefault credential used when no identity is entered in the configuration parameters. Optional.

endpointSpecification

NameTypeDescription
typestringBackend service type of the MCP endpoint. Valid values are REF and DIRECT.
datamap<string, string>Actual backend service data of the MCP endpoint. Different parameters are passed based on type. For example, REF passes namespaceId, groupName, and serviceName; DIRECT passes address and port.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringMCP service update result.

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/mcp' \
-d 'namespaceId=public' \
-d 'mcpName=test' \
-d 'serverSpecification={"protocol":"stdio","frontProtocol":"stdio","name":"test","id":"d7a64724-a556-4fe4-82fa-e806d43e00dc","description":"ceshi","versionDetail":{"version":"1.0.0"},"enabled":true,"localServerConfig":{"test":{}}}'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "ok"
}

4.3. Create MCP Service

Description

You can use this API to create an MCP service hosted on Nacos. It can be an MCP service converted from an existing API, or an MCP service from the MCP marketplace.

Since

3.0.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/mcp

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace ID of the MCP service. The default is public
serverSpecificationstringYesMCP service description details
toolSpecificationstringNoMCP service tool description details
endpointSpecificationstringNoRemote service address details of the MCP service. Takes effect only for non-stdio protocols

The details of the serverSpecification, toolSpecification, and endpointSpecification parameters are as follows:

serverSpecification

NameTypeDescription
idstringMCP service ID, usually a UUID. It does not need to be passed; the system generates it automatically.
namestringMCP service name.
protocolstringMCP protocol, such as stdio, sse, streamable, http, or dubbo.
frontProtocolstringFrontend exposure protocol of the MCP service. It is generally used by protocol converters, such as gateways. If there is no converter, it is the same as protocol, such as stdio, sse, streamable, http, or dubbo.
descriptionstringMCP service description.
repositorystringrepository of the MCP service.
versionDetailVersionDetailversion information of the MCP service.
versionstringSimple version information of the MCP service, mainly used for compatibility. If versionDetail is set, this field is invalid.
localServerConfigMap<String, Object>When the MCP service type is stdio, this information exists and records startup information for the local MCP service.
remoteServerConfigRemoteServerConfigWhen the MCP service type is non-stdio, this information exists and records remote service information.
enabledbooleanwhether the MCP service is enabled.
capabilitiesListCapability types supported by the MCP service, such as TOOL, PROMPT, or RESOURCE.

The VersionDetail structure is as follows:

NameTypeDescription
versionstringversion number of the MCP service.
release_datestringrelease time of the MCP service version.
is_latestbooleanwhether the MCP service version is the latest version.

toolSpecification

NameTypeDescription
toolsList<McpTool>Tool list provided by this MCP Server. Refer to the standard MCP protocol definition of MCP Tool.
toolsMetaMap<String, McpToolMeta>Additional metadata information of tools provided by this MCP Server. It can extend information that is not defined in the standard MCP protocol but is required during use. The key is the name of McpTool, and the value is extended metadata.
securitySchemesList<SecurityScheme>Security schemes of the MCP tool. Refer to the standard MCP protocol.

The McpTool structure is as follows:

NameTypeDescription
namestringMCP tool name
descriptionstringMCP tool description
inputSchemaMap<String, Object>Input parameter description of the MCP tool. Refer to the standard MCP protocol. It mainly contains Type, whether the parameter is required, Description, and other fields.

The McpToolMeta structure is as follows:

NameTypeDescription
invokeContextmap<string, string>Context information when the MCP tool is called, such as the backend service Path.
enabledbooleanwhether the MCP tool is enabled.
templatesmap<string, string>Template information of the MCP tool. Used to map parameters during protocol conversion.

The SecurityScheme structure is as follows:

NameTypeDescription
idstringSecurity scheme ID, which is used and referenced by MCP tools.
typestringSecurity scheme type. Possible values include http, apiKey, localEnv, or other custom extensions.
schemestringSecurity scheme subtype. Used when type is http. Possible values include basic or bearer.
instringSecurity scheme location. Possible values include query and header.
namestringSecurity scheme name. Used when type is apiKey or localEnv. For example, the key name of apiKey or the environment name of localEnv.
defaultCredentialstringDefault credential used when no identity is entered in the configuration parameters. Optional.

endpointSpecification

NameTypeDescription
typestringBackend service type of the MCP endpoint. Valid values are REF and DIRECT.
datamap<string, string>Actual backend service data of the MCP endpoint. Different parameters are passed based on type. For example, REF passes namespaceId, groupName, and serviceName; DIRECT passes address and port.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringID of the newly created MCP service.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/mcp' \
-d 'namespaceId=public' \
-d 'mcpName=test' \
-d 'serverSpecification={"protocol":"stdio","frontProtocol":"stdio","name":"test","id":"","description":"ceshi","versionDetail":{"version":"1.0.0"},"enabled":true,"localServerConfig":{"test":{}}}'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "58e5b430-b16d-4f28-9334-edb64303dc23"
}

4.4. Delete MCP Service

Description

You can use this API to delete an MCP service hosted on Nacos.

Since

3.0.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/mcp

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace ID of the MCP service. The default is public
mcpIdstringOne of two requiredMCP service ID (usually UUID). One of mcpId and mcpName must be provided (OpenAPI cannot express this constraint; at least one is required in practice). Prefer mcpId.
mcpNamestringOne of two requiredMCP service name template. One of mcpId and mcpName must be provided; prefer mcpId.
versionstringNoversion of the MCP service. If not specified, the latest version is used

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringMCP service deletion result.

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/mcp?namespaceId=public&mcpName=test&mcpId=d7a64724-a556-4fe4-82fa-e806d43e00dc'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "ok"
}

4.5. Query MCP Service List

Description

You can use this API to query the list of MCP services hosted on Nacos.

Since

3.0.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/mcp/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYescurrent page. The default is 1
pageSizeintegerYespage item count. The default is 20, and the maximum is 500
namespaceIdstringNoNamespace ID of the MCP service. The default is public
mcpNamestringNoMCP service name pattern. Queries all MCP services when empty. When search is blur, * can be used for fuzzy search
searchstringNoblur or accurate

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of services that match the condition.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListservice list.
pageItems[i].idstringMCP service ID, usually a UUID.
pageItems[i].namestringMCP service name.
pageItems[i].protocolstringMCP protocol, such as stdio, sse, streamable, http, or dubbo.
pageItems[i].frontProtocolstringFrontend exposure protocol of the MCP service. It is generally used by protocol converters, such as gateways. If there is no converter, it is the same as protocol, such as stdio, sse, streamable, http, or dubbo.
pageItems[i].descriptionstringMCP service description.
pageItems[i].repositorystringrepository of the MCP service.
pageItems[i].versionDetailVersionDetailcurrent latest version information of the MCP service.
pageItems[i].localServerConfigMap<String, Object>When the MCP service type is stdio, this information exists and records startup information for the local MCP service.
pageItems[i].remoteServerConfigRemoteServerConfigWhen the MCP service type is non-stdio, this information exists and records remote service information.
pageItems[i].latestPublishedVersionstringversion number of the latest MCP service version.
pageItems[i].versionDetailsList<VersionDetail>list of MCP service version details.
pageItems[i].capabilitiesListCapability types supported by the MCP service, such as TOOL, PROMPT, or RESOURCE.

The VersionDetail structure is as follows:

NameTypeDescription
versionstringversion number of the MCP service.
release_datestringrelease time of the MCP service version.
is_latestbooleanwhether the MCP service version is the latest version.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/mcp/list?pageNo=1&pageSize=100&namespaceId=public&search=blur'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"totalCount": 1,
"pageNumber": 1,
"pagesAvailable": 1,
"pageItems": [
{
"id": "d7a64724-a556-4fe4-82fa-e806d43e00dc",
"name": "test",
"protocol": "stdio",
"frontProtocol": "stdio",
"description": "ceshi",
"repository": null,
"versionDetail": {
"version": "1.0.0",
"release_date": "2025-05-22T06:40:37Z",
"is_latest": null
},
"remoteServerConfig": null,
"localServerConfig": null,
"enabled": true,
"capabilities": null,
"latestPublishedVersion": "1.0.0",
"versionDetails": [
{
"version": "1.0.0",
"release_date": "2025-05-22T06:40:37Z",
"is_latest": null
}
]
}
]
}
}

4.6. Import MCP Tools

Description

You can use this API to directly obtain and import MCP tools by specifying an MCP URL, avoiding manual entry one by one.

Since

3.0.3

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/mcp/importToolsFromMcp

Request Parameters

NameTypeRequiredDescription
transportTypestringYesTransport protocol type of the MCP service, mcp-sse or mcp-streamable
baseUrlstringYesbaseURL of the MCP service
endpointstringYesaccessible endpoint of the MCP service
authTokenstringNoidentity token used to access the MCP service

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
dataList<McpSchema.Tool>MCP tool metadata information that complies with the standard MCP tool metadata definition.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/mcp/importToolsFromMcp?transportType=mcp-sse&baseUrl=%2Fsse&endpoint=http%3A%2F%2Flocalhost'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : [ {
"name" : "getNacosInformation",
"description" : "Get nacos detail information by nacos cluster name, the information includes nacos hosts and accessToken, accessToken is optional.",
"inputSchema" : {
"type" : "object",
"properties" : {
"arg0" : {
"type" : "string",
"description" : "nacos cluster name"
}
},
"required" : [ "arg0" ],
"additionalProperties" : false
}
} ]
}

4.7. Validate MCP Services to Import

Description

You can use this API to validate whether the MCP service content to import complies with the rules. The response includes valid and invalid counts, and invalid services contain error information in the corresponding fields.

Since

3.1.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/mcp/import/validate

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNonamespace ID of the MCP service
importTypestringYesenum of file, json, url
datastringYescontent of the import data
cursorstringNoOptional start cursor for URL-based import pagination.
limitintegerNopage size for pagination
searchstringNoOptional fuzzy search keyword for registry import listing. Only used when importType is ‘url’.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
validbooleanwhether the imported services are valid.
totalCountintegertotal number of imported services.
validCountintegernumber of valid imported services.
invalidCountintegernumber of invalid imported services.
duplicateCountintegernumber of duplicate imported services.
serversList<McpServerValidationItem>imported service list.
errorsList<String>imported service error list.

The McpServerValidationItem description is as follows:

NameTypeDescription
serverNamestringservice name.
serverIdstringservice ID.
statusstringservice status.
selectedbooleanwhether the service is selected.
existsbooleanwhether the service already exists.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/mcp/import/validate' \
-d 'namespaceId=public' \
-d 'importType=url' \
-d 'data=' \
-d 'limit=10'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : {
"valid" : true,
"totalCount" : 3,
"validCount" : 3,
"invalidCount" : 0,
"duplicateCount" : 0,
"servers" : [ {
"serverName" : "server1",
"serverId" : "id1",
"status" : "valid",
"selected" : true,
"exists" : false
}, {
"serverName" : "server2",
"serverId" : "id2",
"status" : "valid",
"selected" : false,
"exists" : false
} ],
"errors" : [ ]
}
}

4.8. Import MCP Services

Description

You can use this API to directly import MCP services by using a file, JSON, or specified MCP URL, avoiding manual entry one by one.

Since

3.1.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/mcp/import/execute

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNonamespace ID of the MCP service
importTypestringYesenum of file, json, url
datastringYescontent of the import data
cursorstringNoOptional start cursor for URL-based import pagination.
limitintegerNopage size for pagination
searchstringNoOptional fuzzy search keyword for registry import listing. Only used when importType is ‘url’.
overrideExistingbooleanNoWhether to overwrite the service if it already exists during import. The default is false.
skipInvalidbooleanNoWhether to ignore invalid services with errors during import. The default is false.
selectedServersarrayNoSelected services to import. Empty means importing all services.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
successbooleanwhether service import succeeded.
totalCountintegertotal number of imported services.
successCountintegernumber of services imported successfully.
failedCountintegernumber of services that failed to import.
skippedCountintegernumber of services skipped during import.
resultsList<McpServerImportResult>imported service list.

The McpServerImportResult description is as follows:

NameTypeDescription
serverNamestringservice name.
serverIdstringservice ID.
statusstringservice import status.
errorMessagebooleanerror information for service import failure. Exists only when import fails.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/mcp/import/execute' \
-d 'namespaceId=public' \
-d 'importType=url' \
-d 'data=' \
-d 'overrideExisting=false' \
-d 'skipInvalid=false' \
-d 'selectedServers=[]' \
-d 'limit=10'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : {
"success" : true,
"totalCount" : 5,
"successCount" : 4,
"failedCount" : 1,
"skippedCount" : 0,
"results" : [ {
"serverName" : "server1",
"serverId" : "id1",
"status" : "success"
}, {
"serverName" : "server2",
"status" : "failed",
"errorMessage" : "Connection failed"
} ]
}
}

5. A2A Registry

5.1. Query AgentCard List

Description

You can use this API to query the list of AgentCards hosted on Nacos.

Since

3.1.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/a2a/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYescurrent page. The default is 1
pageSizeintegerYespage item count. The default is 100
namespaceIdstringNoNamespace ID of the AgentCard. The default is public
agentNamestringNoAgentCard name. Queries all AgentCards when empty
searchstringYesblur or accurate

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
totalCountintegertotal number of services that match the condition.
pageNumberintegercurrent page number, starts from 1.
pagesAvailableintegeravailable pages.
pageItemsListservice list.
pageItems[i].protocolVersionstringA2A protocol version of the AgentCard.
pageItems[i].namestringAgentCard name.
pageItems[i].descriptionstringAgentCard description.
pageItems[i].versionstringAgentCard version number.
pageItems[i].iconUrlstringAgentCard icon URL.
pageItems[i].capabilitiesAgentCapabilityAgentCard capabilities, matching A2A standard capabilities.
pageItems[i].skillsList<AgentSkill>AgentCard skill list, matching A2A standard skills.
pageItems[i].latestPublishedVersionstringlatest published version of the AgentCard.
pageItems[i].versionDetailsList<AgentVersionDetail>all version details of the AgentCard.
pageItems[i].registrationTypestringDefault registration type of the AgentCard. Valid values are URL and SERVICE.

The AgentVersionDetail structure contains the following fields:

NameTypeDescription
versionstringAgentCard version number.
createdAtstringcreation time of this version.
updatedAtstringlast update time of this version.
latestbooleanwhether this version is marked as the latest published version.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/a2a/list?pageNo=1&pageSize=100&namespaceId=public&search=blur'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : {
"totalCount" : 1,
"pageNumber" : 1,
"pagesAvailable" : 1,
"pageItems" : [ {
"protocolVersion" : "0.2.9",
"name" : "GeoSpatial Route Planner Agent",
"description" : "Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.",
"version" : "1.2.0",
"iconUrl" : "https://georoute-agent.example.com/icon.png",
"capabilities" : {
"streaming" : true,
"pushNotifications" : true,
"stateTransitionHistory" : false,
"extensions" : null
},
"skills" : [ {
"id" : "route-optimizer-traffic",
"name" : "Traffic-Aware Route Optimizer",
"description" : "Calculates the optimal driving route between two or more locations, taking into account real-time traffic conditions, road closures, and user preferences (e.g., avoid tolls, prefer highways).",
"tags" : [ "maps", "routing", "navigation", "directions", "traffic" ],
"examples" : [ "Plan a route from '1600 Amphitheatre Parkway, Mountain View, CA' to 'San Francisco International Airport' avoiding tolls.", "{\"origin\": {\"lat\": 37.422, \"lng\": -122.084}, \"destination\": {\"lat\": 37.7749, \"lng\": -122.4194}, \"preferences\": [\"avoid_ferries\"]}" ],
"inputModes" : [ "application/json", "text/plain" ],
"outputModes" : [ "application/json", "application/vnd.geo+json", "text/html" ]
}, {
"id" : "custom-map-generator",
"name" : "Personalized Map Generator",
"description" : "Creates custom map images or interactive map views based on user-defined points of interest, routes, and style preferences. Can overlay data layers.",
"tags" : [ "maps", "customization", "visualization", "cartography" ],
"examples" : [ "Generate a map of my upcoming road trip with all planned stops highlighted.", "Show me a map visualizing all coffee shops within a 1-mile radius of my current location." ],
"inputModes" : [ "application/json" ],
"outputModes" : [ "image/png", "image/jpeg", "application/json", "text/html" ]
} ],
"latestPublishedVersion" : "1.2.0",
"versionDetails" : [ {
"version" : "1.2.0",
"createdAt" : "2025-09-12T03:33:51Z",
"updatedAt" : "2025-09-12T07:21:49Z",
"latest" : true
} ],
"registrationType" : "URL"
} ]
}
}

5.2. Query Version List of a Specified AgentCard

Description

You can use this API to query the version list of a specified AgentCard hosted on Nacos.

Since

3.1.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/a2a/version/list

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace to which the AgentCard belongs. The default is public
agentNamestringYesAgentCard name

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
data[i].versionstringAgentCard version number.
data[i].createdAtstringcreation time of this version.
data[i].updatedAtstringlast update time of this version.
data[i].latestbooleanwhether this version is marked as the latest published version.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/a2a/version/list?namespaceId=public&agentName=GeoSpatial+Route+Planner+Agent'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : [ {
"version" : "1.2.0",
"createdAt" : "2025-09-12T03:33:51Z",
"updatedAt" : "2025-09-12T07:21:49Z",
"latest" : true
} ]
}

5.3. Query AgentCard Details

Description

You can use this API to query details of a specified AgentCard hosted on Nacos.

Since

3.1.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/a2a

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace to which the AgentCard belongs. The default is public
agentNamestringYesAgentCard name
versionstringNoAgentCard version number. Returns the latest version details when empty
registrationTypestringNoDefault registration type of the AgentCard. Valid values are URL and SERVICE. If not specified, the url is generated based on the default registrationType of this AgentCard.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
protocolVersionstringA2A protocol version of the AgentCard.
namestringAgentCard name.
descriptionstringAgentCard description.
versionstringAgentCard version number.
iconUrlstringAgentCard icon URL.
capabilitiesAgentCapabilityAgentCard capabilities, matching A2A standard capabilities.
skillsList<AgentSkill>AgentCard skill list, matching A2A standard skills.
urlstringdefault access URL of the AgentCard.
preferredTransportstringtransport protocol of the default access URL of the AgentCard. It should be JSONRPC, GRPC, or HTTP+JSON.
additionalInterfacesList<AgentInterface>List of all accessible AgentCard interfaces, matching the A2A standard.
providerAgentProviderAgentCard provider information, matching the A2A standard.
documentationUrlstringAgentCard documentation URL.
securitySchemesMap<String, SecurityScheme>AgentCard security configuration definition, matching the A2A standard.
securityList<Map<String, List<String>>>list of all security requirement objects of the AgentCard.
defaultInputModesList<String>all default input modes of the AgentCard.
defaultOutputModesList<String>all default output modes of the AgentCard.
supportsAuthenticatedExtendedCardstringwhether the AgentCard supports authenticated extended cards.
registrationTypestringDefault registration type of the AgentCard. Valid values are URL and SERVICE.
latestVersionstringwhether the current AgentCard version is the latest version.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/a2a?namespaceId=public&agentName=GeoSpatial+Route+Planner+Agent&version=1.0.0&registrationType=SERVICE'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : {
"protocolVersion" : "0.2.9",
"name" : "GeoSpatial Route Planner Agent",
"description" : "Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.",
"version" : "1.2.0",
"iconUrl" : "https://georoute-agent.example.com/icon.png",
"capabilities" : {
"streaming" : true,
"pushNotifications" : true,
"stateTransitionHistory" : false,
"extensions" : null
},
"skills" : [ {
"id" : "route-optimizer-traffic",
"name" : "Traffic-Aware Route Optimizer",
"description" : "Calculates the optimal driving route between two or more locations, taking into account real-time traffic conditions, road closures, and user preferences (e.g., avoid tolls, prefer highways).",
"tags" : [ "maps", "routing", "navigation", "directions", "traffic" ],
"examples" : [ "Plan a route from '1600 Amphitheatre Parkway, Mountain View, CA' to 'San Francisco International Airport' avoiding tolls.", "{\"origin\": {\"lat\": 37.422, \"lng\": -122.084}, \"destination\": {\"lat\": 37.7749, \"lng\": -122.4194}, \"preferences\": [\"avoid_ferries\"]}" ],
"inputModes" : [ "application/json", "text/plain" ],
"outputModes" : [ "application/json", "application/vnd.geo+json", "text/html" ]
}, {
"id" : "custom-map-generator",
"name" : "Personalized Map Generator",
"description" : "Creates custom map images or interactive map views based on user-defined points of interest, routes, and style preferences. Can overlay data layers.",
"tags" : [ "maps", "customization", "visualization", "cartography" ],
"examples" : [ "Generate a map of my upcoming road trip with all planned stops highlighted.", "Show me a map visualizing all coffee shops within a 1-mile radius of my current location." ],
"inputModes" : [ "application/json" ],
"outputModes" : [ "image/png", "image/jpeg", "application/json", "text/html" ]
} ],
"url" : "https://georoute-agent.example.com/a2a/v1",
"preferredTransport" : "JSONRPC",
"additionalInterfaces" : [ {
"url" : "https://georoute-agent.example.com/a2a/v1",
"transport" : "JSONRPC"
}, {
"url" : "https://georoute-agent.example.com/a2a/grpc",
"transport" : "GRPC"
}, {
"url" : "https://georoute-agent.example.com/a2a/json",
"transport" : "HTTP+JSON"
} ],
"provider" : {
"organization" : "Example Geo Services Inc.",
"url" : "https://www.examplegeoservices.com"
},
"documentationUrl" : "https://docs.examplegeoservices.com/georoute-agent/api",
"securitySchemes" : {
"google" : {
"type" : "openIdConnect",
"openIdConnectUrl" : "https://accounts.google.com/.well-known/openid-configuration"
}
},
"security" : [ {
"google" : [ "openid", "profile", "email" ]
} ],
"defaultInputModes" : [ "application/json", "text/plain" ],
"defaultOutputModes" : [ "application/json", "image/png" ],
"supportsAuthenticatedExtendedCard" : true,
"registrationType" : "URL",
"latestVersion" : true
}
}

5.4. Update AgentCard

Description

You can use this API to update an AgentCard hosted on Nacos.

Since

3.1.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/a2a

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace to which the AgentCard belongs. The default is public
agentCardstringYesComplete AgentCard object. For details, see the standard AgentCard.
registrationTypestringNoDefault registration type of the AgentCard. Valid values are URL and SERVICE. If not specified, the url is generated based on the default registrationType of this AgentCard.
setAsLatestbooleanNoWhether to set this version as the latest published version. The default is false.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringAgentCard service update result.

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/a2a' \
-d 'namespaceId=public' \
-d 'agentCard={"protocolVersion":"0.2.9","name":"GeoSpatial Route Planner Agent","description":"Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.","url":"https://georoute-agent.example.com/a2a/v1","preferredTransport":"JSONRPC","additionalInterfaces":[{"url":"https://georoute-agent.example.com/a2a/v1","transport":"JSONRPC"},{"url":"https://georoute-agent.example.com/a2a/grpc","transport":"GRPC"},{"url":"https://georoute-agent.example.com/a2a/json","transport":"HTTP+JSON"}],"provider":{"organization":"Example Geo Services Inc.","url":"https://www.examplegeoservices.com"},"iconUrl":"https://georoute-agent.example.com/icon.png","version":"1.2.0","documentationUrl":"https://docs.examplegeoservices.com/georoute-agent/api","capabilities":{"streaming":true,"pushNotifications":true,"stateTransitionHistory":false},"securitySchemes":{"google":{"type":"openIdConnect","openIdConnectUrl":"https://accounts.google.com/.well-known/openid-configuration"}},"security":[{"google":["openid","profile","email"]}],"defaultInputModes":["application/json","text/plain"],"defaultOutputModes":["application/json","image/png"],"skills":[{"id":"route-optimizer-traffic","name":"Traffic-Aware Route Optimizer","description":"Calculates the optimal driving route between two or more locations, taking into account real-time traffic conditions, road closures, and user preferences (e.g., avoid tolls, prefer highways).","tags":["maps","routing","navigation","directions","traffic"],"examples":["Plan a route from '1600 Amphitheatre Parkway, Mountain View, CA' to 'San Francisco International Airport' avoiding tolls.","{\"origin\": {\"lat\": 37.422, \"lng\": -122.084}, \"destination\": {\"lat\": 37.7749, \"lng\": -122.4194}, \"preferences\": [\"avoid_ferries\"]}"],"inputModes":["application/json","text/plain"],"outputModes":["application/json","application/vnd.geo+json","text/html"]},{"id":"custom-map-generator","name":"Personalized Map Generator","description":"Creates custom map images or interactive map views based on user-defined points of interest, routes, and style preferences. Can overlay data layers.","tags":["maps","customization","visualization","cartography"],"examples":["Generate a map of my upcoming road trip with all planned stops highlighted.","Show me a map visualizing all coffee shops within a 1-mile radius of my current location."],"inputModes":["application/json"],"outputModes":["image/png","image/jpeg","application/json","text/html"]}],"supportsAuthenticatedExtendedCard":true,"signatures":[{"protected":"eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdSI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0","signature":"QFdkNLNszlGj3z3u0YQGt_T9LixY3qtdQpZmsTdDHDe3fXV9y9-B3m2-XgCpzuhiLt8E0tV6HXoZKHv4GtHgKQ"}]}' \
-d 'registrationType=SERVICE' \
-d 'setAsLatest=true'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "ok"
}

5.5. Create AgentCard

Description

You can use this API to create an AgentCard hosted on Nacos.

Since

3.1.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/a2a

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace to which the AgentCard belongs. The default is public
agentCardstringYesComplete AgentCard object. For details, see the standard AgentCard.
registrationTypestringNoDefault registration type of the AgentCard. Valid values are URL and SERVICE. If not specified, the url is generated based on the default registrationType of this AgentCard. The default is URL.

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringAgentCard publishing result.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/a2a' \
-d 'namespaceId=public' \
-d 'agentCard={"protocolVersion":"0.2.9","name":"GeoSpatial Route Planner Agent","description":"Provides advanced route planning, traffic analysis, and custom map generation services. This agent can calculate optimal routes, estimate travel times considering real-time traffic, and create personalized maps with points of interest.","url":"https://georoute-agent.example.com/a2a/v1","preferredTransport":"JSONRPC","additionalInterfaces":[{"url":"https://georoute-agent.example.com/a2a/v1","transport":"JSONRPC"},{"url":"https://georoute-agent.example.com/a2a/grpc","transport":"GRPC"},{"url":"https://georoute-agent.example.com/a2a/json","transport":"HTTP+JSON"}],"provider":{"organization":"Example Geo Services Inc.","url":"https://www.examplegeoservices.com"},"iconUrl":"https://georoute-agent.example.com/icon.png","version":"1.2.0","documentationUrl":"https://docs.examplegeoservices.com/georoute-agent/api","capabilities":{"streaming":true,"pushNotifications":true,"stateTransitionHistory":false},"securitySchemes":{"google":{"type":"openIdConnect","openIdConnectUrl":"https://accounts.google.com/.well-known/openid-configuration"}},"security":[{"google":["openid","profile","email"]}],"defaultInputModes":["application/json","text/plain"],"defaultOutputModes":["application/json","image/png"],"skills":[{"id":"route-optimizer-traffic","name":"Traffic-Aware Route Optimizer","description":"Calculates the optimal driving route between two or more locations, taking into account real-time traffic conditions, road closures, and user preferences (e.g., avoid tolls, prefer highways).","tags":["maps","routing","navigation","directions","traffic"],"examples":["Plan a route from '1600 Amphitheatre Parkway, Mountain View, CA' to 'San Francisco International Airport' avoiding tolls.","{\"origin\": {\"lat\": 37.422, \"lng\": -122.084}, \"destination\": {\"lat\": 37.7749, \"lng\": -122.4194}, \"preferences\": [\"avoid_ferries\"]}"],"inputModes":["application/json","text/plain"],"outputModes":["application/json","application/vnd.geo+json","text/html"]},{"id":"custom-map-generator","name":"Personalized Map Generator","description":"Creates custom map images or interactive map views based on user-defined points of interest, routes, and style preferences. Can overlay data layers.","tags":["maps","customization","visualization","cartography"],"examples":["Generate a map of my upcoming road trip with all planned stops highlighted.","Show me a map visualizing all coffee shops within a 1-mile radius of my current location."],"inputModes":["application/json"],"outputModes":["image/png","image/jpeg","application/json","text/html"]}],"supportsAuthenticatedExtendedCard":true,"signatures":[{"protected":"eyJhbGciOiJFUzI1NiIsInR5cCI6IkpPU0UiLCJraWQiOiJrZXktMSIsImprdSI6Imh0dHBzOi8vZXhhbXBsZS5jb20vYWdlbnQvandrcy5qc29uIn0","signature":"QFdkNLNszlGj3z3u0YQGt_T9LixY3qtdQpZmsTdDHDe3fXV9y9-B3m2-XgCpzuhiLt8E0tV6HXoZKHv4GtHgKQ"}]}' \
-d 'registrationType=SERVICE'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "ok"
}

5.6. Delete AgentCard

Description

You can use this API to delete an AgentCard hosted on Nacos.

Since

3.1.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/a2a

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNoNamespace to which the AgentCard belongs. The default is public
agentNamestringYesAgentCard name
versionstringNoAgentCard version number. Returns the latest version details when empty

Response Data

The response body follows the Nacos Open API unified response format. The table below describes only the response parameters in the data field.

NameTypeDescription
datastringAgentCard deletion result.

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/a2a?namespaceId=public&agentName=GeoSpatial+Route+Planner+Agent&version=1.0.0'
  • Response example
{
"code" : 0,
"message" : "success",
"data" : "ok"
}

6. Prompt Management

Prompt Management APIs provide draft, publish, online/offline, governance query, version query, and download capabilities for Prompts.

6.1. Delete Prompt

Description

This interface allows deleting a specific Prompt.

Since

3.2.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.databoolean-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/prompt?namespaceId=public&promptKey=my-prompt'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.2. Update Prompt Biz Tags

Description

This interface updates Prompt biz tags.

Since

3.2.1

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/biz-tags

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
bizTagsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/prompt/biz-tags' -d "namespaceId=namespaceId&promptKey=promptKey&bizTags=bizTags"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.3. Update Prompt Description

Description

This interface updates the Prompt description.

Since

3.2.1

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/description

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
descriptionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/prompt/description' -d "namespaceId=namespaceId&promptKey=promptKey&description=description"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.4. Create Prompt Draft

Description

This interface creates a Prompt draft version or forks a draft from an existing version.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
basedOnVersionstringNo-
targetVersionstringNo-
templatestringNo-
variablesstringNo-
commitMsgstringNo-
descriptionstringNo-
bizTagsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/draft' -d "namespaceId=namespaceId&promptKey=promptKey&basedOnVersion=basedOnVersion&targetVersion=targetVersion&template=template&variables=variables&commitMsg=commitMsg&description=description&bizTags=bizTags"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.5. Update Prompt Draft

Description

This interface updates the current Prompt draft content.

Since

3.2.1

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
templatestringYes-
variablesstringNo-
commitMsgstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/prompt/draft' -d "namespaceId=namespaceId&promptKey=promptKey&template=template&variables=variables&commitMsg=commitMsg"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.6. Delete Prompt Draft

Description

This interface deletes the current Prompt draft version.

Since

3.2.1

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/prompt/draft?namespaceId=public&promptKey=my-prompt'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.7. Force Publish Prompt Version

Description

This interface force-publishes a Prompt version by bypassing pipeline validation.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/force-publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/force-publish' -d "namespaceId=namespaceId&promptKey=promptKey&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.8. Get Prompt Governance Detail

Description

This interface retrieves Prompt metadata, version governance information, and version summaries.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/prompt/governance

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.schemaVersioninteger-
data.data.promptKeystring-
data.data.descriptionstring-
data.data.bizTagsarray-
data.data.bizTagsStrstring-
data.data.latestVersionstring-
data.data.gmtModifiedinteger-
data.data.editingVersionstring-
data.data.reviewingVersionstring-
data.data.onlineCntinteger-
data.data.labelsobject-
data.data.downloadCountinteger-
data.data.versionsarray-
data.data.versionDetailsarray-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/prompt/governance?namespaceId=public&promptKey=my-prompt'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.9. Update Prompt Labels

Description

This interface updates runtime routing labels of a Prompt.

Since

3.2.1

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/labels

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
labelsstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/prompt/labels' -d "namespaceId=namespaceId&promptKey=promptKey&labels=labels"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.10. List Prompts

Description

This interface allows listing Prompts with pagination.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/prompt/list

Request Parameters

NameTypeRequiredDescription
pageNointegerYes-
pageSizeintegerYes-
namespaceIdstringNo-
promptKeystringNo-
searchstringNoblur or accurate
bizTagsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/prompt/list?pageNo=1&pageSize=10&namespaceId=public&promptKey=my-prompt&search=blur&bizTags=tag-a'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.11. Offline Prompt Version

Description

This interface takes a specified Prompt version offline.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/offline

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/offline' -d "namespaceId=namespaceId&promptKey=promptKey&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.12. Online Prompt Version

Description

This interface brings a specified Prompt version online.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/online

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/online' -d "namespaceId=namespaceId&promptKey=promptKey&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.13. Publish Prompt Version

Description

This interface publishes an approved Prompt version.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/publish' -d "namespaceId=namespaceId&promptKey=promptKey&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.14. Redraft Prompt Version

Description

This interface transitions a reviewed Prompt version back to draft.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/redraft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/redraft' -d "namespaceId=namespaceId&promptKey=promptKey&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.15. Submit Prompt Version

Description

This interface submits a Prompt version for pipeline review.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/prompt/submit

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/prompt/submit' -d "namespaceId=namespaceId&promptKey=promptKey&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.16. Get Prompt Version Detail

Description

This interface retrieves details of a specified Prompt version.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/prompt/version

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.promptKeystring-
data.data.versionstring-
data.data.statusstring-
data.data.commitMsgstring-
data.data.srcUserstring-
data.data.gmtModifiedinteger-
data.data.publishPipelineInfostring-
data.data.downloadCountinteger-
data.data.templatestring-
data.data.md5string-
data.data.variablesarray-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/prompt/version?namespaceId=public&promptKey=my-prompt&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.17. Download Prompt Version

Description

This interface downloads a specified Prompt version as a Markdown file.

Since

3.2.2

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/prompt/version/download

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
versionstringNo-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/prompt/version/download?namespaceId=public&promptKey=my-prompt&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

6.18. List Prompt Versions

Description

This interface allows listing versions of a specific Prompt with pagination.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/prompt/versions

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
promptKeystringYes-
pageNointegerYes-
pageSizeintegerYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/prompt/versions?namespaceId=public&promptKey=my-prompt&pageNo=1&pageSize=10'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7. Skills Management

Skills Management APIs provide query, draft, publish, online/offline, version management, and ZIP upload capabilities for Skills.

7.1. Get Skill Details

Description

This interface allows retrieving detailed information of a specific Skill hosted on Nacos.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/skills

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.namespaceIdstring-
data.data.namestring-
data.data.descriptionstring-
data.data.updateTimeinteger-
data.data.ownerstring-
data.data.enableboolean-
data.data.bizTagsstring-
data.data.fromstring-
data.data.scopestring-
data.data.labelsobject-
data.data.editingVersionstring-
data.data.reviewingVersionstring-
data.data.onlineCntinteger-
data.data.downloadCountinteger-
data.data.versionsarray-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/skills?namespaceId=public&skillName=my-skill&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.2. Delete Skill

Description

This interface allows deleting a Skill hosted on Nacos.

Since

3.2.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/skills?namespaceId=public&skillName=my-skill&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.3. Update Skill Business Tags

Description

This interface allows updating the business tag list of a skill without changing version status.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/biz-tags

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
bizTagsstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/skills/biz-tags' -d "namespaceId=public&skillName=my-skill&bizTags=bizTags"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.4. Create Skill Draft Version

Description

This interface allows creating a draft version based on an existing version or a brand-new SkillCard.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringNo-
basedOnVersionstringNo-
targetVersionstringNo-
skillCardstringNoSkill card JSON; required if basedOnVersion is not set

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/draft' -d "namespaceId=public&skillName=my-skill&basedOnVersion=basedOnVersion&targetVersion=targetVersion&skillCard=skillCard"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.5. Update Skill Draft Content

Description

This interface allows updating the SkillCard content of the current draft version.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
skillCardstringYesSkill card JSON string containing complete Skill information

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/skills/draft' -d "namespaceId=public&skillName=my-skill&skillCard=skillCard"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.6. Delete Skill Draft Version

Description

This interface allows deleting the current draft version of a specified skill.

Since

3.2.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/skills/draft?namespaceId=public&skillName=my-skill'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.7. Force Publish Skill Version

Description

This interface force-publishes a Skill version by bypassing pipeline validation.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/force-publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/force-publish' -d "namespaceId=public&skillName=my-skill&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.8. Update Skill Version Labels

Description

This interface allows updating skill version routing labels (e.g. latest label) without changing version status.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/labels

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
labelsstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/skills/labels' -d "namespaceId=public&skillName=my-skill&labels=labels"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.9. List Skills

Description

This interface allows querying the list of Skills hosted on Nacos.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/skills/list

Request Parameters

NameTypeRequiredDescription
filterableFormstringYes-
pageNointegerYes-
pageSizeintegerYes-
namespaceIdstringNo-
skillNamestringNo-
searchstringNoblur or accurate

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/skills/list?filterableForm=true&pageNo=1&pageSize=10&namespaceId=public&skillName=my-skill&search=blur'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.10. Offline Skill

Description

This interface allows executing an offline operation on a specific version or the entire skill, making it not callable.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/offline

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
scopestringNoUse ‘skill’ for skill-level offline; otherwise version-level
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/offline' -d "namespaceId=public&skillName=my-skill&scope=scope&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.11. Online Skill

Description

This interface allows executing an online operation on a specific version or the entire skill, making it callable.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/online

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
scopestringNoUse ‘skill’ for skill-level online; otherwise version-level
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/online' -d "namespaceId=public&skillName=my-skill&scope=scope&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.12. Publish Skill Version

Description

This interface allows publishing an approved skill version.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/publish' -d "namespaceId=public&skillName=my-skill&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.13. Redraft Skill Version

Description

This interface transitions a reviewed Skill version back to draft.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/redraft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/redraft' -d "namespaceId=public&skillName=my-skill&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.14. Update Skill Visibility Scope

Description

This interface allows setting the visibility scope of a skill to PUBLIC or PRIVATE.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/scope

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
scopestringYesPUBLIC or PRIVATE

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/skills/scope' -d "namespaceId=public&skillName=my-skill&scope=scope"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.15. Submit Skill Version for Review

Description

This interface allows submitting a skill draft version to the pipeline for review.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/submit

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/submit' -d "namespaceId=public&skillName=my-skill&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.16. Upload Skill (ZIP)

Description

This interface allows uploading a Skill from a ZIP file.

Since

3.2.2

Request Method

POST

Request body type: multipart/form-data (for example, file upload). Use -F or -H 'Content-Type: multipart/form-data' in request examples.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/upload

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
overwritebooleanNo-
targetVersionstringNo-
commitMsgstringNo-
NameTypeRequiredDescription
filefileNoZIP file containing skill
overwritebooleanNo-
namespaceIdstringNo-
targetVersionstringNo-
commitMsgstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/upload?namespaceId=public&overwrite=false&targetVersion=1.0.0&commitMsg=init' -F "file=@/path/to/skill.zip" -F "overwrite=false" -F "namespaceId=public" -F "targetVersion=1.0.0" -F "commitMsg=init"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.17. Batch Upload Skills

Description

This interface uploads multiple Skills from a ZIP file that contains one-level Skill subdirectories.

Since

3.2.2

Request Method

POST

Request body type: multipart/form-data (for example, file upload). Use -F or -H 'Content-Type: multipart/form-data' in request examples.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/skills/upload/batch

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
overwritebooleanNo-
NameTypeRequiredDescription
namespaceIdstringNo-
overwritebooleanNo-
filefileNoZIP file containing skill directories

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.succeededarray-
data.data.failedarray-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/skills/upload/batch?namespaceId=public&overwrite=false' -F "namespaceId=public" -F "overwrite=false" -F "file=@/path/to/skills.zip"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.18. Get Skill Version Detail

Description

This interface allows querying the detail of a specific Skill version by namespace, skill name, and version number.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/skills/version

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.namespaceIdstring-
data.data.namestring-
data.data.descriptionstring-
data.data.skillMdstring-
data.data.resourceobject-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/skills/version?namespaceId=public&skillName=my-skill&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

7.19. Download Skill Version ZIP

Description

This interface allows downloading the ZIP package of a specific Skill version.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/skills/version/download

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
skillNamestringYes-
versionstringNo-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/skills/version/download?namespaceId=public&skillName=my-skill&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8. AgentSpec Management

AgentSpec Management APIs provide query, draft, publish, online/offline, version management, and ZIP upload capabilities for AgentSpecs.

8.1. Get AgentSpec

Description

This interface allows getting the latest published version of an AgentSpec by namespace and name.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/agentspecs

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.namespaceIdstring-
data.data.namestring-
data.data.descriptionstring-
data.data.updateTimeinteger-
data.data.enableboolean-
data.data.bizTagsstring-
data.data.fromstring-
data.data.scopestring-
data.data.labelsobject-
data.data.editingVersionstring-
data.data.reviewingVersionstring-
data.data.onlineCntinteger-
data.data.downloadCountinteger-
data.data.versionsarray-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/agentspecs?namespaceId=public&agentSpecName=my-agent&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.2. Delete AgentSpec

Description

This interface allows deleting an AgentSpec and all its versions by namespace and name.

Since

3.2.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/agentspecs?namespaceId=public&agentSpecName=my-agent'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.3. Update AgentSpec Business Tags

Description

This interface allows updating the business tag list of an AgentSpec without changing version status.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/biz-tags

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
bizTagsstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/agentspecs/biz-tags' -d "namespaceId=public&agentSpecName=my-agent&bizTags=bizTags"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.4. Create AgentSpec Draft Version

Description

This interface allows creating an AgentSpec draft version based on an existing version.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
basedOnVersionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/draft' -d "namespaceId=public&agentSpecName=my-agent&basedOnVersion=basedOnVersion"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.5. Update AgentSpec Draft Content

Description

This interface allows updating the card content of the current AgentSpec draft version.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringNo-
agentSpecCardstringYesAgentSpec card JSON string containing complete AgentSpec information

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/agentspecs/draft' -d "namespaceId=public&agentSpecName=my-agent&agentSpecCard=agentSpecCard"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.6. Delete AgentSpec Draft Version

Description

This interface allows deleting the current draft version of a specified AgentSpec.

Since

3.2.0

Request Method

DELETE

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/draft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X DELETE 'http://127.0.0.1:8080/v3/console/ai/agentspecs/draft?namespaceId=public&agentSpecName=my-agent'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.7. Force Publish AgentSpec Version

Description

This interface force-publishes an AgentSpec version by bypassing pipeline validation.

Since

3.2.1

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/force-publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/force-publish' -d "namespaceId=public&agentSpecName=my-agent&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.8. Update AgentSpec Version Labels

Description

This interface allows updating AgentSpec version routing labels (e.g. latest label) without changing version status.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/labels

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
labelsstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/agentspecs/labels' -d "namespaceId=public&agentSpecName=my-agent&labels=labels"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.9. List AgentSpecs

Description

This interface allows paginated listing of AgentSpecs by namespace and name.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/agentspecs/list

Request Parameters

NameTypeRequiredDescription
filterableFormstringYes-
pageNointegerYes-
pageSizeintegerYes-
namespaceIdstringNo-
agentSpecNamestringNo-
searchstringNoSearch mode: accurate or blur

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/agentspecs/list?filterableForm=true&pageNo=1&pageSize=10&namespaceId=public&agentSpecName=my-agent&search=blur'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.10. Offline AgentSpec

Description

This interface allows executing an offline operation on a specific version or the entire AgentSpec, making it not callable.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/offline

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
scopestringNoUse ‘agentspec’ for agentspec-level offline; otherwise version-level
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/offline' -d "namespaceId=public&agentSpecName=my-agent&scope=scope&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.11. Online AgentSpec

Description

This interface allows executing an online operation on a specific version or the entire AgentSpec, making it callable.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/online

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
scopestringNoUse ‘agentspec’ for agentspec-level online; otherwise version-level
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/online' -d "namespaceId=public&agentSpecName=my-agent&scope=scope&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.12. Publish AgentSpec Version

Description

This interface allows publishing an approved AgentSpec version.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/publish

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringYes-
updateLatestLabelbooleanNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/publish' -d "namespaceId=public&agentSpecName=my-agent&version=version&updateLatestLabel=updateLatestLabel"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.13. Redraft AgentSpec Version

Description

This interface transitions a reviewed AgentSpec version back to draft.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/redraft

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/redraft' -d "namespaceId=public&agentSpecName=my-agent&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.14. Update AgentSpec Visibility Scope

Description

This interface allows setting the visibility scope of an AgentSpec to PUBLIC or PRIVATE.

Since

3.2.0

Request Method

PUT

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/scope

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
scopestringYesPUBLIC or PRIVATE

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X PUT 'http://127.0.0.1:8080/v3/console/ai/agentspecs/scope' -d "namespaceId=public&agentSpecName=my-agent&scope=scope"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.15. Submit AgentSpec Version for Review

Description

This interface allows submitting an AgentSpec draft version to the pipeline for review.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/submit

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/submit' -d "namespaceId=public&agentSpecName=my-agent&version=version"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.16. Upload AgentSpec

Description

This interface allows uploading a ZIP-packaged AgentSpec; the package is parsed and the AgentSpec is created or updated.

Since

3.2.0

Request Method

POST

Request body type: multipart/form-data (for example, file upload). Use -F or -H 'Content-Type: multipart/form-data' in request examples.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/agentspecs/upload

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
overwritebooleanNo-
NameTypeRequiredDescription
namespaceIdstringNo-
overwritebooleanNo-
filefileNoZIP file containing agentspec package

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/agentspecs/upload?namespaceId=public&overwrite=false' -F "namespaceId=public" -F "overwrite=false" -F "file=@/path/to/skills.zip"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

8.17. Get AgentSpec Version

Description

This interface allows getting a specific version of an AgentSpec by namespace, name, and version.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/agentspecs/version

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
agentSpecNamestringYes-
versionstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.namespaceIdstring-
data.data.namestring-
data.data.descriptionstring-
data.data.bizTagsstring-
data.data.contentstring-
data.data.resourceobject-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/agentspecs/version?namespaceId=public&agentSpecName=my-agent&version=1.0.0'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

9. Pipeline Management

Pipeline Management APIs provide capabilities to query Pipeline execution record lists, details, and instances.

9.1. List Pipeline Executions

Description

This interface allows paginated listing of Pipeline execution records by resource type, name, namespace, and version.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/pipelines

Request Parameters

NameTypeRequiredDescription
resourceTypestringYes-
resourceNamestringNo-
namespaceIdstringNo-
versionstringNo-
pageNointegerYes-
pageSizeintegerYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/pipelines?resourceType=skill&resourceName=my-skill&namespaceId=public&version=1.0.0&pageNo=1&pageSize=10'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

9.2. Get Pipeline Execution

Description

This interface allows retrieving a Pipeline execution record by pipeline ID.

Since

3.2.1

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/pipelines/detail

Request Parameters

NameTypeRequiredDescription
pipelineIdstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.executionIdstring-
data.data.resourceTypestring-
data.data.resourceNamestring-
data.data.namespaceIdstring-
data.data.versionstring-
data.data.statusstring-
data.data.pipelinearray-
data.data.createTimeinteger-
data.data.updateTimeinteger-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/pipelines/detail?pipelineId=pipeline-001'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

9.3. List Pipeline Executions

Description

This interface allows paginated listing of Pipeline execution records by resource type, name, namespace, and version.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/pipelines/list

Request Parameters

NameTypeRequiredDescription
resourceTypestringYes-
resourceNamestringNo-
namespaceIdstringNo-
versionstringNo-
pageNointegerYes-
pageSizeintegerYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.datastring-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/pipelines/list?resourceType=skill&resourceName=my-skill&namespaceId=public&version=1.0.0&pageNo=1&pageSize=10'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

9.4. Get Pipeline Execution

Description

This interface allows retrieving a Pipeline execution record by pipeline ID.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/pipelines/{pipelineId}

Request Parameters

NameTypeRequiredDescription
pipelineIdstringYes-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.executionIdstring-
data.data.resourceTypestring-
data.data.resourceNamestring-
data.data.namespaceIdstring-
data.data.versionstring-
data.data.statusstring-
data.data.pipelinearray-
data.data.createTimeinteger-
data.data.updateTimeinteger-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/pipelines/{pipelineId}'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

10. AI Resource Import

AI Resource Import APIs provide query, search, validation, and execution capabilities for external AI resource import sources.

10.1. Execute AI Resource Import

Description

This interface imports selected external AI resources.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/import/execute

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
resourceTypestringYes-
sourceIdstringYes-
selectedItemsstringYes-
overwriteExistingbooleanNo-
skipInvalidbooleanNo-
validationTokenstringNo-
optionsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.successboolean-
data.data.totalCountinteger-
data.data.successCountinteger-
data.data.failedCountinteger-
data.data.skippedCountinteger-
data.data.resultsarray-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/import/execute' -d "namespaceId=namespaceId&resourceType=resourceType&sourceId=sourceId&selectedItems=selectedItems&overwriteExisting=overwriteExisting&skipInvalid=skipInvalid&validationToken=validationToken&options=options"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

10.2. Search External AI Resources

Description

This interface searches importable external AI resources from a specified source.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/import/search

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
resourceTypestringYes-
sourceIdstringYes-
querystringNo-
cursorstringNo-
limitintegerNo-
optionsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.sourceIdstring-
data.data.resourceTypestring-
data.data.nextCursorstring-
data.data.hasMoreboolean-
data.data.itemsarray-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/import/search' -d "namespaceId=namespaceId&resourceType=resourceType&sourceId=sourceId&query=query&cursor=cursor&limit=limit&options=options"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

10.3. List AI Resource Import Sources

Description

This interface lists configured AI resource import sources.

Since

3.2.2

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/ai/import/sources

Request Parameters

NameTypeRequiredDescription
resourceTypestringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.dataarray-

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/ai/import/sources?resourceType=skill'
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

10.4. Validate AI Resource Import Items

Description

This interface validates selected external AI resources before import.

Since

3.2.2

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/ai/import/validate

Request Parameters

NameTypeRequiredDescription
namespaceIdstringNo-
resourceTypestringYes-
sourceIdstringYes-
selectedItemsstringYes-
overwriteExistingbooleanNo-
optionsstringNo-

Response Data

NameTypeDescription
data.codeinteger-
data.messagestring-
data.data.sourceIdstring-
data.data.resourceTypestring-
data.data.validationTokenstring-
data.data.itemsarray-

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/ai/import/validate' -d "namespaceId=namespaceId&resourceType=resourceType&sourceId=sourceId&selectedItems=selectedItems&overwriteExisting=overwriteExisting&options=options"
  • Response example
{
"code": 0,
"message": "success",
"data": {}
}

11. Copilot

Copilot-related APIs provide configuration retrieval and saving, Prompt debugging and optimization, Skill generation and optimization, and other capabilities. Some APIs return SSE streams.

11.1. Get Copilot Configuration

Description

Get the current Copilot configuration. Only apiKey, model, studioUrl, and studioProject are returned.

Since

3.2.0

Request Method

GET

Authorization

A user identity with the corresponding namespace read permission is required.

Request URL

/v3/console/copilot/config

Request Parameters

None

Response Data

NameTypeDescription
data.enabledbooleanwhether the Copilot feature is enabled.
data.defaultNamespacestringdefault namespace ID.
data.apiKeystringAPI key used to call external services such as large models. Whether it is masked or returned as raw text depends on the implementation.
data.modelstringdefault model identifier.
data.studioUrlstringassociated Studio service address.
data.studioProjectstringassociated Studio project identifier.

Examples

  • Request example
Terminal window
curl -X GET 'http://127.0.0.1:8080/v3/console/copilot/config'
  • Response example
{
"code": 0,
"message": "success",
"data": {
"apiKey": "",
"model": "",
"studioUrl": "",
"studioProject": ""
}
}

11.2. Save Copilot Configuration

Description

Create or update the Copilot configuration. Only apiKey, model, studioUrl, and studioProject are accepted. Other fields use Default.

Since

3.2.0

Request Method

POST

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/copilot/config

Request Parameters

None. The request body can contain fields such as apiKey, model, studioUrl, and studioProject; use the actual API behavior as the source of truth.

Response Data

NameTypeDescription
databooleanwhether saving succeeded.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/copilot/config'
  • Response example
{
"code": 0,
"message": "success",
"data": true
}

11.3. Stream Prompt Debugging

Description

You can use this API to stream-debug a Prompt with user input and return model responses as an SSE stream.

Since

3.2.0

Request Method

POST

Request body type: application/json.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/copilot/prompt/debug

Request Parameters

NameTypeRequiredDescription
userInputstringNouser input content.
promptstringNoPrompt to debug.

Response Data

None. The response is returned as an SSE stream.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/copilot/prompt/debug' -H 'Content-Type: application/json' -d '{"userInput":"","prompt":""}'
  • Response example
{}

11.4. Stream Prompt Optimization

Description

You can use this API to stream-optimize a Prompt and return an SSE stream.

Since

3.2.0

Request Method

POST

Request body type: application/json.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/copilot/prompt/optimize

Request Parameters

NameTypeRequiredDescription
optimizationGoalstringNooptimization goal.
promptstringNoPrompt to optimize.

Response Data

None. The response is returned as an SSE stream.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/copilot/prompt/optimize' -H 'Content-Type: application/json' -d '{"optimizationGoal":"","prompt":""}'
  • Response example
{}

11.5. Stream Skill Generation

Description

You can use this API to stream-generate a Skill based on background information and return an SSE stream.

Since

3.2.0

Request Method

POST

Request body type: application/json.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/copilot/skill/generate

Request Parameters

NameTypeRequiredDescription
backgroundInfostringNobackground information.
selectedMcpToolsarrayNoselected MCP tools.
conversationHistoryobjectNoconversation history.

Response Data

None. The response is returned as an SSE stream.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/copilot/skill/generate' -H 'Content-Type: application/json' -d '{"backgroundInfo":"","selectedMcpTools":"","conversationHistory":""}'
  • Response example
{}

11.6. Stream Skill Optimization

Description

You can use this API to stream-optimize a Skill based on a target and conversation history, and return an SSE stream.

Since

3.2.0

Request Method

POST

Request body type: application/json.

Authorization

A user identity with the corresponding namespace write permission is required.

Request URL

/v3/console/copilot/skill/optimize

Request Parameters

NameTypeRequiredDescription
conversationHistoryobjectNoconversation history.
targetFileNamestringNotarget file name.
optimizationGoalstringNooptimization goal.
skillstringNoSkill content to optimize.
selectedMcpToolsarrayNoselected MCP tools.

Response Data

None. The response is returned as an SSE stream.

Examples

  • Request example
Terminal window
curl -X POST 'http://127.0.0.1:8080/v3/console/copilot/skill/optimize' -H 'Content-Type: application/json' -d '{"conversationHistory":"","targetFileName":"","optimizationGoal":"","skill":"","selectedMcpTools":""}'
  • Response example
{}