1. Packages
  2. Packages
  3. Google Cloud (GCP) Classic
  4. API Docs
  5. agentregistry
  6. Service
Viewing docs for Google Cloud v9.32.1
published on Wednesday, Jul 29, 2026 by Pulumi
gcp logo
Viewing docs for Google Cloud v9.32.1
published on Wednesday, Jul 29, 2026 by Pulumi

    Service manages a service in a management boundary

    Example Usage

    Agent Registry Service Basic

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const _default = new gcp.agentregistry.Service("default", {
        location: "us-central1",
        serviceId: "service",
        description: "My basic agent registry service",
        displayName: "My Service",
        interfaces: [{
            url: "https://www.google.com/service",
            protocolBinding: "GRPC",
        }],
        agentSpec: {
            type: "NO_SPEC",
        },
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default = gcp.agentregistry.Service("default",
        location="us-central1",
        service_id="service",
        description="My basic agent registry service",
        display_name="My Service",
        interfaces=[{
            "url": "https://www.google.com/service",
            "protocol_binding": "GRPC",
        }],
        agent_spec={
            "type": "NO_SPEC",
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/agentregistry"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := agentregistry.NewService(ctx, "default", &agentregistry.ServiceArgs{
    			Location:    pulumi.String("us-central1"),
    			ServiceId:   pulumi.String("service"),
    			Description: pulumi.String("My basic agent registry service"),
    			DisplayName: pulumi.String("My Service"),
    			Interfaces: agentregistry.ServiceInterfaceArray{
    				&agentregistry.ServiceInterfaceArgs{
    					Url:             pulumi.String("https://www.google.com/service"),
    					ProtocolBinding: pulumi.String("GRPC"),
    				},
    			},
    			AgentSpec: &agentregistry.ServiceAgentSpecArgs{
    				Type: pulumi.String("NO_SPEC"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = new Gcp.AgentRegistry.Service("default", new()
        {
            Location = "us-central1",
            ServiceId = "service",
            Description = "My basic agent registry service",
            DisplayName = "My Service",
            Interfaces = new[]
            {
                new Gcp.AgentRegistry.Inputs.ServiceInterfaceArgs
                {
                    Url = "https://www.google.com/service",
                    ProtocolBinding = "GRPC",
                },
            },
            AgentSpec = new Gcp.AgentRegistry.Inputs.ServiceAgentSpecArgs
            {
                Type = "NO_SPEC",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.agentregistry.Service;
    import com.pulumi.gcp.agentregistry.ServiceArgs;
    import com.pulumi.gcp.agentregistry.inputs.ServiceInterfaceArgs;
    import com.pulumi.gcp.agentregistry.inputs.ServiceAgentSpecArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var default_ = new Service("default", ServiceArgs.builder()
                .location("us-central1")
                .serviceId("service")
                .description("My basic agent registry service")
                .displayName("My Service")
                .interfaces(ServiceInterfaceArgs.builder()
                    .url("https://www.google.com/service")
                    .protocolBinding("GRPC")
                    .build())
                .agentSpec(ServiceAgentSpecArgs.builder()
                    .type("NO_SPEC")
                    .build())
                .build());
    
        }
    }
    
    resources:
      default:
        type: gcp:agentregistry:Service
        properties:
          location: us-central1
          serviceId: service
          description: My basic agent registry service
          displayName: My Service
          interfaces:
            - url: https://www.google.com/service
              protocolBinding: GRPC
          agentSpec:
            type: NO_SPEC
    
    pulumi {
      required_providers {
        gcp = {
          source = "pulumi/gcp"
        }
      }
    }
    
    resource "gcp_agentregistry_service" "default" {
      location     = "us-central1"
      service_id   = "service"
      description  = "My basic agent registry service"
      display_name = "My Service"
      interfaces {
        url              = "https://www.google.com/service"
        protocol_binding = "GRPC"
      }
      agent_spec = {
        type = "NO_SPEC"
      }
    }
    

    Agent Registry Service Mcp Server

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const _default = new gcp.agentregistry.Service("default", {
        location: "us-central1",
        serviceId: "service",
        description: "My MCP agent registry service",
        displayName: "My Service",
        interfaces: [{
            url: "https://example.com",
            protocolBinding: "JSONRPC",
        }],
        mcpServerSpec: {
            type: "TOOL_SPEC",
            content: "{\"tools\":[]}",
        },
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default = gcp.agentregistry.Service("default",
        location="us-central1",
        service_id="service",
        description="My MCP agent registry service",
        display_name="My Service",
        interfaces=[{
            "url": "https://example.com",
            "protocol_binding": "JSONRPC",
        }],
        mcp_server_spec={
            "type": "TOOL_SPEC",
            "content": "{\"tools\":[]}",
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/agentregistry"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := agentregistry.NewService(ctx, "default", &agentregistry.ServiceArgs{
    			Location:    pulumi.String("us-central1"),
    			ServiceId:   pulumi.String("service"),
    			Description: pulumi.String("My MCP agent registry service"),
    			DisplayName: pulumi.String("My Service"),
    			Interfaces: agentregistry.ServiceInterfaceArray{
    				&agentregistry.ServiceInterfaceArgs{
    					Url:             pulumi.String("https://example.com"),
    					ProtocolBinding: pulumi.String("JSONRPC"),
    				},
    			},
    			McpServerSpec: &agentregistry.ServiceMcpServerSpecArgs{
    				Type:    pulumi.String("TOOL_SPEC"),
    				Content: pulumi.String("{\"tools\":[]}"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = new Gcp.AgentRegistry.Service("default", new()
        {
            Location = "us-central1",
            ServiceId = "service",
            Description = "My MCP agent registry service",
            DisplayName = "My Service",
            Interfaces = new[]
            {
                new Gcp.AgentRegistry.Inputs.ServiceInterfaceArgs
                {
                    Url = "https://example.com",
                    ProtocolBinding = "JSONRPC",
                },
            },
            McpServerSpec = new Gcp.AgentRegistry.Inputs.ServiceMcpServerSpecArgs
            {
                Type = "TOOL_SPEC",
                Content = "{\"tools\":[]}",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.agentregistry.Service;
    import com.pulumi.gcp.agentregistry.ServiceArgs;
    import com.pulumi.gcp.agentregistry.inputs.ServiceInterfaceArgs;
    import com.pulumi.gcp.agentregistry.inputs.ServiceMcpServerSpecArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var default_ = new Service("default", ServiceArgs.builder()
                .location("us-central1")
                .serviceId("service")
                .description("My MCP agent registry service")
                .displayName("My Service")
                .interfaces(ServiceInterfaceArgs.builder()
                    .url("https://example.com")
                    .protocolBinding("JSONRPC")
                    .build())
                .mcpServerSpec(ServiceMcpServerSpecArgs.builder()
                    .type("TOOL_SPEC")
                    .content("{\"tools\":[]}")
                    .build())
                .build());
    
        }
    }
    
    resources:
      default:
        type: gcp:agentregistry:Service
        properties:
          location: us-central1
          serviceId: service
          description: My MCP agent registry service
          displayName: My Service
          interfaces:
            - url: https://example.com
              protocolBinding: JSONRPC
          mcpServerSpec:
            type: TOOL_SPEC
            content: '{"tools":[]}'
    
    pulumi {
      required_providers {
        gcp = {
          source = "pulumi/gcp"
        }
      }
    }
    
    resource "gcp_agentregistry_service" "default" {
      location     = "us-central1"
      service_id   = "service"
      description  = "My MCP agent registry service"
      display_name = "My Service"
      interfaces {
        url              = "https://example.com"
        protocol_binding = "JSONRPC"
      }
      mcp_server_spec = {
        type    = "TOOL_SPEC"
        content = "{\"tools\":[]}"
      }
    }
    

    Create Service Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Service(name: string, args: ServiceArgs, opts?: CustomResourceOptions);
    @overload
    def Service(resource_name: str,
                args: ServiceArgs,
                opts: Optional[ResourceOptions] = None)
    
    @overload
    def Service(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                location: Optional[str] = None,
                service_id: Optional[str] = None,
                agent_spec: Optional[ServiceAgentSpecArgs] = None,
                deletion_policy: Optional[str] = None,
                description: Optional[str] = None,
                display_name: Optional[str] = None,
                endpoint_spec: Optional[ServiceEndpointSpecArgs] = None,
                interfaces: Optional[Sequence[ServiceInterfaceArgs]] = None,
                mcp_server_spec: Optional[ServiceMcpServerSpecArgs] = None,
                project: Optional[str] = None)
    func NewService(ctx *Context, name string, args ServiceArgs, opts ...ResourceOption) (*Service, error)
    public Service(string name, ServiceArgs args, CustomResourceOptions? opts = null)
    public Service(String name, ServiceArgs args)
    public Service(String name, ServiceArgs args, CustomResourceOptions options)
    
    type: gcp:agentregistry:Service
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "gcp_agentregistry_service" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args ServiceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ServiceArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ServiceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ServiceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ServiceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var serviceResource = new Gcp.AgentRegistry.Service("serviceResource", new()
    {
        Location = "string",
        ServiceId = "string",
        AgentSpec = new Gcp.AgentRegistry.Inputs.ServiceAgentSpecArgs
        {
            Type = "string",
            Content = "string",
        },
        DeletionPolicy = "string",
        Description = "string",
        DisplayName = "string",
        EndpointSpec = new Gcp.AgentRegistry.Inputs.ServiceEndpointSpecArgs
        {
            Type = "string",
        },
        Interfaces = new[]
        {
            new Gcp.AgentRegistry.Inputs.ServiceInterfaceArgs
            {
                ProtocolBinding = "string",
                Url = "string",
            },
        },
        McpServerSpec = new Gcp.AgentRegistry.Inputs.ServiceMcpServerSpecArgs
        {
            Type = "string",
            Content = "string",
        },
        Project = "string",
    });
    
    example, err := agentregistry.NewService(ctx, "serviceResource", &agentregistry.ServiceArgs{
    	Location:  pulumi.String("string"),
    	ServiceId: pulumi.String("string"),
    	AgentSpec: &agentregistry.ServiceAgentSpecArgs{
    		Type:    pulumi.String("string"),
    		Content: pulumi.String("string"),
    	},
    	DeletionPolicy: pulumi.String("string"),
    	Description:    pulumi.String("string"),
    	DisplayName:    pulumi.String("string"),
    	EndpointSpec: &agentregistry.ServiceEndpointSpecArgs{
    		Type: pulumi.String("string"),
    	},
    	Interfaces: agentregistry.ServiceInterfaceArray{
    		&agentregistry.ServiceInterfaceArgs{
    			ProtocolBinding: pulumi.String("string"),
    			Url:             pulumi.String("string"),
    		},
    	},
    	McpServerSpec: &agentregistry.ServiceMcpServerSpecArgs{
    		Type:    pulumi.String("string"),
    		Content: pulumi.String("string"),
    	},
    	Project: pulumi.String("string"),
    })
    
    resource "gcp_agentregistry_service" "serviceResource" {
      lifecycle {
        create_before_destroy = true
      }
      location   = "string"
      service_id = "string"
      agent_spec = {
        type    = "string"
        content = "string"
      }
      deletion_policy = "string"
      description     = "string"
      display_name    = "string"
      endpoint_spec = {
        type = "string"
      }
      interfaces {
        protocol_binding = "string"
        url              = "string"
      }
      mcp_server_spec = {
        type    = "string"
        content = "string"
      }
      project = "string"
    }
    
    var serviceResource = new com.pulumi.gcp.agentregistry.Service("serviceResource", com.pulumi.gcp.agentregistry.ServiceArgs.builder()
        .location("string")
        .serviceId("string")
        .agentSpec(ServiceAgentSpecArgs.builder()
            .type("string")
            .content("string")
            .build())
        .deletionPolicy("string")
        .description("string")
        .displayName("string")
        .endpointSpec(ServiceEndpointSpecArgs.builder()
            .type("string")
            .build())
        .interfaces(ServiceInterfaceArgs.builder()
            .protocolBinding("string")
            .url("string")
            .build())
        .mcpServerSpec(ServiceMcpServerSpecArgs.builder()
            .type("string")
            .content("string")
            .build())
        .project("string")
        .build());
    
    service_resource = gcp.agentregistry.Service("serviceResource",
        location="string",
        service_id="string",
        agent_spec={
            "type": "string",
            "content": "string",
        },
        deletion_policy="string",
        description="string",
        display_name="string",
        endpoint_spec={
            "type": "string",
        },
        interfaces=[{
            "protocol_binding": "string",
            "url": "string",
        }],
        mcp_server_spec={
            "type": "string",
            "content": "string",
        },
        project="string")
    
    const serviceResource = new gcp.agentregistry.Service("serviceResource", {
        location: "string",
        serviceId: "string",
        agentSpec: {
            type: "string",
            content: "string",
        },
        deletionPolicy: "string",
        description: "string",
        displayName: "string",
        endpointSpec: {
            type: "string",
        },
        interfaces: [{
            protocolBinding: "string",
            url: "string",
        }],
        mcpServerSpec: {
            type: "string",
            content: "string",
        },
        project: "string",
    });
    
    type: gcp:agentregistry:Service
    properties:
        agentSpec:
            content: string
            type: string
        deletionPolicy: string
        description: string
        displayName: string
        endpointSpec:
            type: string
        interfaces:
            - protocolBinding: string
              url: string
        location: string
        mcpServerSpec:
            content: string
            type: string
        project: string
        serviceId: string
    

    Service Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Service resource accepts the following input properties:

    Location string
    The location of the resource.
    ServiceId string
    The name of the Service.
    AgentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    DeletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    Description string
    The description of the Service.
    DisplayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    EndpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    Interfaces List<ServiceInterface>
    The connection details for the Service. Structure is documented below.
    McpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    Location string
    The location of the resource.
    ServiceId string
    The name of the Service.
    AgentSpec ServiceAgentSpecArgs
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    DeletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    Description string
    The description of the Service.
    DisplayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    EndpointSpec ServiceEndpointSpecArgs
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    Interfaces []ServiceInterfaceArgs
    The connection details for the Service. Structure is documented below.
    McpServerSpec ServiceMcpServerSpecArgs
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    location string
    The location of the resource.
    service_id string
    The name of the Service.
    agent_spec object
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    deletion_policy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description string
    The description of the Service.
    display_name string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpoint_spec object
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces list(object)
    The connection details for the Service. Structure is documented below.
    mcp_server_spec object
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    location String
    The location of the resource.
    serviceId String
    The name of the Service.
    agentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    deletionPolicy String
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description String
    The description of the Service.
    displayName String
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces List<ServiceInterface>
    The connection details for the Service. Structure is documented below.
    mcpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    location string
    The location of the resource.
    serviceId string
    The name of the Service.
    agentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    deletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description string
    The description of the Service.
    displayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces ServiceInterface[]
    The connection details for the Service. Structure is documented below.
    mcpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    location str
    The location of the resource.
    service_id str
    The name of the Service.
    agent_spec ServiceAgentSpecArgs
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    deletion_policy str
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description str
    The description of the Service.
    display_name str
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpoint_spec ServiceEndpointSpecArgs
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces Sequence[ServiceInterfaceArgs]
    The connection details for the Service. Structure is documented below.
    mcp_server_spec ServiceMcpServerSpecArgs
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    location String
    The location of the resource.
    serviceId String
    The name of the Service.
    agentSpec Property Map
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    deletionPolicy String
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description String
    The description of the Service.
    displayName String
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec Property Map
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces List<Property Map>
    The connection details for the Service. Structure is documented below.
    mcpServerSpec Property Map
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Service resource produces the following output properties:

    CreateTime string
    The timestamp when the resource was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    The resource name of the Service.
    RegistryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    UpdateTime string
    The timestamp when the resource was updated.
    CreateTime string
    The timestamp when the resource was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    The resource name of the Service.
    RegistryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    UpdateTime string
    The timestamp when the resource was updated.
    create_time string
    The timestamp when the resource was created.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    The resource name of the Service.
    registry_resource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    update_time string
    The timestamp when the resource was updated.
    createTime String
    The timestamp when the resource was created.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    The resource name of the Service.
    registryResource String
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    updateTime String
    The timestamp when the resource was updated.
    createTime string
    The timestamp when the resource was created.
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    The resource name of the Service.
    registryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    updateTime string
    The timestamp when the resource was updated.
    create_time str
    The timestamp when the resource was created.
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    The resource name of the Service.
    registry_resource str
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    update_time str
    The timestamp when the resource was updated.
    createTime String
    The timestamp when the resource was created.
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    The resource name of the Service.
    registryResource String
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    updateTime String
    The timestamp when the resource was updated.

    Look up Existing Service Resource

    Get an existing Service resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: ServiceState, opts?: CustomResourceOptions): Service
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            agent_spec: Optional[ServiceAgentSpecArgs] = None,
            create_time: Optional[str] = None,
            deletion_policy: Optional[str] = None,
            description: Optional[str] = None,
            display_name: Optional[str] = None,
            endpoint_spec: Optional[ServiceEndpointSpecArgs] = None,
            interfaces: Optional[Sequence[ServiceInterfaceArgs]] = None,
            location: Optional[str] = None,
            mcp_server_spec: Optional[ServiceMcpServerSpecArgs] = None,
            name: Optional[str] = None,
            project: Optional[str] = None,
            registry_resource: Optional[str] = None,
            service_id: Optional[str] = None,
            update_time: Optional[str] = None) -> Service
    func GetService(ctx *Context, name string, id IDInput, state *ServiceState, opts ...ResourceOption) (*Service, error)
    public static Service Get(string name, Input<string> id, ServiceState? state, CustomResourceOptions? opts = null)
    public static Service get(String name, Output<String> id, ServiceState state, CustomResourceOptions options)
    resources:  _:    type: gcp:agentregistry:Service    get:      id: ${id}
    import {
      to = gcp_agentregistry_service.example
      id = "${id}"
    }
    
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AgentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    CreateTime string
    The timestamp when the resource was created.
    DeletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    Description string
    The description of the Service.
    DisplayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    EndpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    Interfaces List<ServiceInterface>
    The connection details for the Service. Structure is documented below.
    Location string
    The location of the resource.
    McpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    Name string
    The resource name of the Service.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RegistryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    ServiceId string
    The name of the Service.
    UpdateTime string
    The timestamp when the resource was updated.
    AgentSpec ServiceAgentSpecArgs
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    CreateTime string
    The timestamp when the resource was created.
    DeletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    Description string
    The description of the Service.
    DisplayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    EndpointSpec ServiceEndpointSpecArgs
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    Interfaces []ServiceInterfaceArgs
    The connection details for the Service. Structure is documented below.
    Location string
    The location of the resource.
    McpServerSpec ServiceMcpServerSpecArgs
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    Name string
    The resource name of the Service.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RegistryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    ServiceId string
    The name of the Service.
    UpdateTime string
    The timestamp when the resource was updated.
    agent_spec object
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    create_time string
    The timestamp when the resource was created.
    deletion_policy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description string
    The description of the Service.
    display_name string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpoint_spec object
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces list(object)
    The connection details for the Service. Structure is documented below.
    location string
    The location of the resource.
    mcp_server_spec object
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    name string
    The resource name of the Service.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    registry_resource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    service_id string
    The name of the Service.
    update_time string
    The timestamp when the resource was updated.
    agentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    createTime String
    The timestamp when the resource was created.
    deletionPolicy String
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description String
    The description of the Service.
    displayName String
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces List<ServiceInterface>
    The connection details for the Service. Structure is documented below.
    location String
    The location of the resource.
    mcpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    name String
    The resource name of the Service.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    registryResource String
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    serviceId String
    The name of the Service.
    updateTime String
    The timestamp when the resource was updated.
    agentSpec ServiceAgentSpec
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    createTime string
    The timestamp when the resource was created.
    deletionPolicy string
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description string
    The description of the Service.
    displayName string
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec ServiceEndpointSpec
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces ServiceInterface[]
    The connection details for the Service. Structure is documented below.
    location string
    The location of the resource.
    mcpServerSpec ServiceMcpServerSpec
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    name string
    The resource name of the Service.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    registryResource string
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    serviceId string
    The name of the Service.
    updateTime string
    The timestamp when the resource was updated.
    agent_spec ServiceAgentSpecArgs
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    create_time str
    The timestamp when the resource was created.
    deletion_policy str
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description str
    The description of the Service.
    display_name str
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpoint_spec ServiceEndpointSpecArgs
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces Sequence[ServiceInterfaceArgs]
    The connection details for the Service. Structure is documented below.
    location str
    The location of the resource.
    mcp_server_spec ServiceMcpServerSpecArgs
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    name str
    The resource name of the Service.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    registry_resource str
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    service_id str
    The name of the Service.
    update_time str
    The timestamp when the resource was updated.
    agentSpec Property Map
    The spec of the Agent. When set, the type of the Service is Agent. Structure is documented below.
    createTime String
    The timestamp when the resource was created.
    deletionPolicy String
    Whether Terraform will be prevented from destroying the resource. Defaults to DELETE. When a 'terraform destroy' or 'pulumi up' would delete the resource, the command will fail if this field is set to "PREVENT" in Terraform state. When set to "ABANDON", the command will remove the resource from Terraform management without updating or deleting the resource in the API. When set to "DELETE", deleting the resource is allowed.
    description String
    The description of the Service.
    displayName String
    User-defined display name for the Service. Can have a maximum length of 63 characters.
    endpointSpec Property Map
    The spec of the Endpoint. When set, the type of the Service is Endpoint. Structure is documented below.
    interfaces List<Property Map>
    The connection details for the Service. Structure is documented below.
    location String
    The location of the resource.
    mcpServerSpec Property Map
    The spec of the MCP Server. When set, the type of the Service is MCP Server. Structure is documented below.
    name String
    The resource name of the Service.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    registryResource String
    The resource name of the resulting Agent, MCP Server, or Endpoint.
    serviceId String
    The name of the Service.
    updateTime String
    The timestamp when the resource was updated.

    Supporting Types

    ServiceAgentSpec, ServiceAgentSpecArgs

    Type string
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    Content string
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    Type string
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    Content string
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    type string
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    content string
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    type String
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    content String
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    type string
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    content string
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    type str
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    content str
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.
    type String
    The type of the Agent spec content. Possible values are: NO_SPEC, A2A_AGENT_CARD.
    content String
    The content of the Agent spec in the JSON format. This payload is validated against the schema for the specified type.

    ServiceEndpointSpec, ServiceEndpointSpecArgs

    Type string
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    Type string
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    type string
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    type String
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    type string
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    type str
    The type of the Endpoint spec content. Possible values are: NO_SPEC.
    type String
    The type of the Endpoint spec content. Possible values are: NO_SPEC.

    ServiceInterface, ServiceInterfaceArgs

    ProtocolBinding string
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    Url string
    The destination URL.
    ProtocolBinding string
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    Url string
    The destination URL.
    protocol_binding string
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    url string
    The destination URL.
    protocolBinding String
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    url String
    The destination URL.
    protocolBinding string
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    url string
    The destination URL.
    protocol_binding str
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    url str
    The destination URL.
    protocolBinding String
    The protocol binding of the interface. Possible values are: JSONRPC, GRPC, HTTP_JSON.
    url String
    The destination URL.

    ServiceMcpServerSpec, ServiceMcpServerSpecArgs

    Type string
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    Content string
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    Type string
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    Content string
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    type string
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    content string
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    type String
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    content String
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    type string
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    content string
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    type str
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    content str
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.
    type String
    The type of the MCP Server spec content. Possible values are: NO_SPEC, TOOL_SPEC.
    content String
    The content of the MCP Server spec. This payload is validated against the schema for the specified type.

    Import

    Service can be imported using any of these accepted formats:

    • projects/{{project}}/locations/{{location}}/services/{{service_id}}
    • {{project}}/{{location}}/{{service_id}}
    • {{location}}/{{service_id}}

    When using the pulumi import command, Service can be imported using one of the formats above. For example:

    $ pulumi import gcp:agentregistry/service:Service default projects/{{project}}/locations/{{location}}/services/{{service_id}}
    $ pulumi import gcp:agentregistry/service:Service default {{project}}/{{location}}/{{service_id}}
    $ pulumi import gcp:agentregistry/service:Service default {{location}}/{{service_id}}
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Viewing docs for Google Cloud v9.32.1
    published on Wednesday, Jul 29, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial