Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/google-cloud-apiregistry/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ Samples are in the [`samples/`][homepage_samples] directory. Each sample's `READ

| Sample | Source Code |
| --------------------------- | --------------------------------- |
| get mcp server | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1/cloud_api_registry.get_mcp_server.js) |
| get mcp tool | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1/cloud_api_registry.get_mcp_tool.js) |
| list mcp servers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1/cloud_api_registry.list_mcp_servers.js) |
| list mcp tools | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1/cloud_api_registry.list_mcp_tools.js) |
| cloud | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1/snippet_metadata_google.cloud.apiregistry.v1.json) |
| get mcp server | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1beta/cloud_api_registry.get_mcp_server.js) |
| get mcp tool | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1beta/cloud_api_registry.get_mcp_tool.js) |
| list mcp servers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-apiregistry/samples/generated/v1beta/cloud_api_registry.list_mcp_servers.js) |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
// Copyright 2026 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

syntax = "proto3";

package google.cloud.apiregistry.v1;

option csharp_namespace = "Google.Cloud.ApiRegistry.V1";
option go_package = "cloud.google.com/go/apiregistry/apiv1/apiregistrypb;apiregistrypb";
option java_multiple_files = true;
option java_outer_classname = "CommonProto";
option java_package = "com.google.cloud.apiregistry.v1";
option php_namespace = "Google\\Cloud\\ApiRegistry\\V1";
option ruby_package = "Google::Cloud::ApiRegistry::V1";

// The state of McpServer resource.
enum State {
// The McpServer state is unspecified.
STATE_UNSPECIFIED = 0;

// The McpServer is enabled.
ENABLED = 1;

// The McpServer is disabled.
DISABLED = 2;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
// Copyright 2026 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

syntax = "proto3";

package google.cloud.apiregistry.v1;

import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/cloud/apiregistry/v1/common.proto";
import "google/protobuf/struct.proto";

option csharp_namespace = "Google.Cloud.ApiRegistry.V1";
option go_package = "cloud.google.com/go/apiregistry/apiv1/apiregistrypb;apiregistrypb";
option java_multiple_files = true;
option java_outer_classname = "ResourcesProto";
option java_package = "com.google.cloud.apiregistry.v1";
option php_namespace = "Google\\Cloud\\ApiRegistry\\V1";
option ruby_package = "Google::Cloud::ApiRegistry::V1";

// Represents an MCP Server. MCP Servers act as endpoints that expose a
// collection of tools that can be invoked by agents.
message McpServer {
option (google.api.resource) = {
type: "cloudapiregistry.googleapis.com/McpServer"
pattern: "projects/{project}/locations/{location}/apiNamespaces/{api_namespace}/mcpServers/{mcp_server}"
pattern: "projects/{project}/locations/{location}/mcpServers/{mcp_server}"
plural: "mcpServers"
singular: "mcpServer"
};

// Identifier. The resource name of the MCP Server.
// Format:
// `projects/{project}/locations/{location}/mcpServers/{mcp_server}`.
// Example:
// projects/12345/locations/us-central1/mcpServers/google:bigquery.googleapis.com:mcp
// for 1p
// projects/12345/locations/us-central1/mcpServers/apphub:starbucks for
// 2p
string name = 1 [(google.api.field_behavior) = IDENTIFIER];

// Optional. A human readable name for the MCP server.
string display_name = 2 [(google.api.field_behavior) = OPTIONAL];

// Optional. A human-readable description of the MCP Server's functionality.
string description = 3 [(google.api.field_behavior) = OPTIONAL];

// The base URL of the MCP server. Example: [geolocation.googleapis.com/mcp].
repeated string urls = 4;

// The capabilities that a server may support. Known capabilities defined in
// https://modelcontextprotocol.io/specification/2025-06-18/schema#servercapabilities
// and additional capabilities defined by the servers.
google.protobuf.Struct capabilities = 6;

// Output only. The state of the MCP Server.
State state = 7 [(google.api.field_behavior) = OUTPUT_ONLY];
}

// Message describing McpTool object
message McpTool {
option (google.api.resource) = {
type: "cloudapiregistry.googleapis.com/McpTool"
pattern: "projects/{project}/locations/{location}/apiNamespaces/{api_namespace}/mcpServers/{mcp_server}/mcpTools/{mcp_tool}"
pattern: "projects/{project}/locations/{location}/mcpServers/{mcp_server}/mcpTools/{mcp_tool}"
plural: "mcpTools"
singular: "mcpTool"
};

// Identifier. The resource name of the McpTool.
// Format:
// `projects/{project}/locations/{location}/mcpServers/{mcp_server}/mcpTools/{mcp_tool}`.
// Example:
// projects/12345/locations/us-central1/mcpServers/google:bigquery.googleapis.com:mcp/mcpTools/insert_job
// for 1p
// projects/12345/locations/us-central1/mcpServers/apphub:starbucks/mcpTools/order_pizza
// for 2p
string name = 1 [(google.api.field_behavior) = IDENTIFIER];

// Optional. A human-readable name for the tool, suitable for display.
string display_name = 2 [(google.api.field_behavior) = OPTIONAL];

// A human-readable description of the tool's functionality.
string description = 3;

// Automatically populated reference to MCP Server. Helpful when multiple
// tools are requested across different MCP Servers.
repeated string mcp_server_urls = 4;

// A JSON Schema object defining the expected parameters for invoking the
// tool.
google.protobuf.Struct input_schema = 5;

// Optional. A JSON Schema object defining the expected structure of the
// tool's output.
google.protobuf.Struct output_schema = 6;

// Optional key-value object that allows developers to provide additional
// information regarding tool properties, behavior, and usage best practices.
// Annotations or tags to facilitate semantic search across tools ("semantic
// tags") are not in the MVP scope. When implemented, the first set of
// supported annotations will likely be the standard, predefined annotations
// from the open-source MCP spec. These include:
// - title: A human-readable title for the tool, useful for UI display.
// - readOnlyHint: If true, indicates the tool does not modify its
// environment.
// - destructiveHint: If true, the tool may perform destructive updates
// (only meaningful when readOnlyHint is false).
// - idempotentHint: If true, calling the tool repeatedly with the same
// arguments has no additional effect (only meaningful when readOnlyHint is
// false).
// - openWorldHint: If true, the tool may interact with an "open world" of
// external entities.
google.protobuf.Struct annotations = 7;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,182 @@
// Copyright 2026 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

syntax = "proto3";

package google.cloud.apiregistry.v1;

import "google/api/annotations.proto";
import "google/api/client.proto";
import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/cloud/apiregistry/v1/resources.proto";

option csharp_namespace = "Google.Cloud.ApiRegistry.V1";
option go_package = "cloud.google.com/go/apiregistry/apiv1/apiregistrypb;apiregistrypb";
option java_multiple_files = true;
option java_outer_classname = "ServiceProto";
option java_package = "com.google.cloud.apiregistry.v1";
option php_namespace = "Google\\Cloud\\ApiRegistry\\V1";
option ruby_package = "Google::Cloud::ApiRegistry::V1";
option (google.api.resource_definition) = {
type: "cloudapiregistry.googleapis.com/ApiNamespace"
pattern: "projects/{project}/locations/{location}/apiNamespaces/{api_namespace}"
};

// The Cloud API Registry service provides a central registry for managing API
// Data.
service CloudApiRegistry {
option (google.api.default_host) = "cloudapiregistry.googleapis.com";
option (google.api.oauth_scopes) =
"https://www.googleapis.com/auth/cloud-platform";

// Gets a single McpServer.
rpc GetMcpServer(GetMcpServerRequest) returns (McpServer) {
option (google.api.http) = {
get: "/v1/{name=projects/*/locations/*/mcpServers/*}"
};
option (google.api.method_signature) = "name";
}

// Lists McpServers in a given Project.
rpc ListMcpServers(ListMcpServersRequest) returns (ListMcpServersResponse) {
option (google.api.http) = {
get: "/v1/{parent=projects/*/locations/*}/mcpServers"
};
option (google.api.method_signature) = "parent";
}

// Gets a single McpTool.
rpc GetMcpTool(GetMcpToolRequest) returns (McpTool) {
option (google.api.http) = {
get: "/v1/{name=projects/*/locations/*/mcpServers/*/mcpTools/*}"
};
option (google.api.method_signature) = "name";
}

// Lists McpTools in a given McpServer.
rpc ListMcpTools(ListMcpToolsRequest) returns (ListMcpToolsResponse) {
option (google.api.http) = {
get: "/v1/{parent=projects/*/locations/*/mcpServers/*}/mcpTools"
};
option (google.api.method_signature) = "parent";
}
}

// Message for getting a McpServer
message GetMcpServerRequest {
// Required. Name of the resource
// Format: projects/{project}/locations/{location}/mcpServers/{mcp_server}
string name = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "cloudapiregistry.googleapis.com/McpServer"
}
];
}

// Message for requesting list of McpServers
message ListMcpServersRequest {
// Required. Parent value for ListMcpServersRequest
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "locations.googleapis.com/Location"
}
];

// Optional. Requested page size. Server may return fewer items than
// requested. If unspecified, at most 50 items will be returned. The maximum
// value is 100; values above 100 will be coerced to 100.
int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL];

// Optional. A token identifying a page of results the server should return.
string page_token = 3 [(google.api.field_behavior) = OPTIONAL];

// Optional. An expression that filters the results.
// For syntax, see https://google.aip.dev/160.
string filter = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. A comma-separated list of fields to order by, sorted in ascending
// order. Use "desc" after a field name for descending. For syntax, see
// https://google.aip.dev/132#ordering.
string order_by = 5 [(google.api.field_behavior) = OPTIONAL];
}

// Message for response to listing McpServers
message ListMcpServersResponse {
// The list of McpServer
repeated McpServer mcp_servers = 1;

// A token identifying a page of results the server should return.
string next_page_token = 2;

// Unordered list. Locations that could not be reached.
repeated string unreachable = 3
[(google.api.field_behavior) = UNORDERED_LIST];
}

// Message for getting a McpTool
message GetMcpToolRequest {
// Required. Name of the resource
// Format:
// projects/{project}/locations/{location}/mcpServers/{mcp_server}/mcpTools/{mcp_tool}
string name = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "cloudapiregistry.googleapis.com/McpTool"
}
];
}

// Message for requesting list of McpTools
message ListMcpToolsRequest {
// Required. Parent value for ListMcpToolsRequest
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
child_type: "cloudapiregistry.googleapis.com/McpTool"
}
];

// Optional. Requested page size. Server may return fewer items than
// requested. If unspecified, at most 50 items will be returned. The maximum
// value is 100; values above 100 will be coerced to 100.
int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL];

// Optional. A token identifying a page of results the server should return.
string page_token = 3 [(google.api.field_behavior) = OPTIONAL];

// Optional. An expression that filters the results.
// For syntax, see https://google.aip.dev/160.
string filter = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. A comma-separated list of fields to order by, sorted in ascending
// order. Use "desc" after a field name for descending. For syntax, see
// https://google.aip.dev/132#ordering.
string order_by = 5 [(google.api.field_behavior) = OPTIONAL];
}

// Message for response to listing McpTools
message ListMcpToolsResponse {
// The list of McpTool
repeated McpTool mcp_tools = 1;

// A token identifying a page of results the server should return.
string next_page_token = 2;

// Unordered list. Locations that could not be reached.
repeated string unreachable = 3
[(google.api.field_behavior) = UNORDERED_LIST];
}
Loading