# Package google.cloud.servicedirectory.v1beta1

## Index

- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.LookupService` (interface)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService` (interface)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateEndpointRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateNamespaceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateServiceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteEndpointRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteNamespaceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteServiceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetEndpointRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetNamespaceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetServiceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListEndpointsRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListEndpointsResponse` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListNamespacesRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListNamespacesResponse` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListServicesRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListServicesResponse` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ResolveServiceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ResolveServiceResponse` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateEndpointRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateNamespaceRequest` (message)
- `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateServiceRequest` (message)

## LookupService

Service Directory API for looking up service data at runtime.

| ResolveService ||
|---|---|
| `` rpc ResolveService(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ResolveServiceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ResolveServiceResponse`) `` Returns a `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` and its associated endpoints. Resolving a service is not considered an active developer method. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

## RegistrationService

Service Directory API for registering services. It defines the following resource model:

- The API has a collection of `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace` resources, named `projects/*/locations/*/namespaces/*`.

- Each Namespace has a collection of `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` resources, named `projects/*/locations/*/namespaces/*/services/*`.

- Each Service has a collection of `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` resources, named `projects/*/locations/*/namespaces/*/services/*/endpoints/*`.

| CreateEndpoint ||
|---|---|
| `` rpc CreateEndpoint(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateEndpointRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint`) `` Creates an endpoint, and returns the new endpoint. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| CreateNamespace ||
|---|---|
| `` rpc CreateNamespace(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateNamespaceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace`) `` Creates a namespace, and returns the new namespace. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| CreateService ||
|---|---|
| `` rpc CreateService(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.CreateServiceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service`) `` Creates a service, and returns the new service. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| DeleteEndpoint ||
|---|---|
| `` rpc DeleteEndpoint(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteEndpointRequest`) returns (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Empty`) `` Deletes an endpoint. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| DeleteNamespace ||
|---|---|
| `` rpc DeleteNamespace(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteNamespaceRequest`) returns (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Empty`) `` Deletes a namespace. This also deletes all services and endpoints in the namespace. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| DeleteService ||
|---|---|
| `` rpc DeleteService(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.DeleteServiceRequest`) returns (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Empty`) `` Deletes a service. This also deletes all endpoints associated with the service. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| GetEndpoint ||
|---|---|
| `` rpc GetEndpoint(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetEndpointRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint`) `` Gets an endpoint. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| GetIamPolicy ||
|---|---|
| `` rpc GetIamPolicy(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.GetIamPolicyRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.Policy`) `` Gets the IAM Policy for a resource (namespace or service only). Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| GetNamespace ||
|---|---|
| `` rpc GetNamespace(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetNamespaceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace`) `` Gets a namespace. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| GetService ||
|---|---|
| `` rpc GetService(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.GetServiceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service`) `` Gets a service. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| ListEndpoints ||
|---|---|
| `` rpc ListEndpoints(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListEndpointsRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListEndpointsResponse`) `` Lists all endpoints. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| ListNamespaces ||
|---|---|
| `` rpc ListNamespaces(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListNamespacesRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListNamespacesResponse`) `` Lists all namespaces. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| ListServices ||
|---|---|
| `` rpc ListServices(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListServicesRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.ListServicesResponse`) `` Lists all services belonging to a namespace. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| SetIamPolicy ||
|---|---|
| `` rpc SetIamPolicy(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.SetIamPolicyRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.Policy`) `` Sets the IAM Policy for a resource (namespace or service only). Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| TestIamPermissions ||
|---|---|
| `` rpc TestIamPermissions(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.TestIamPermissionsRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.iam.v1#google.iam.v1.TestIamPermissionsResponse`) `` Tests IAM permissions for a resource (namespace or service only). Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| UpdateEndpoint ||
|---|---|
| `` rpc UpdateEndpoint(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateEndpointRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint`) `` Updates an endpoint. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| UpdateNamespace ||
|---|---|
| `` rpc UpdateNamespace(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateNamespaceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace`) `` Updates a namespace. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

| UpdateService ||
|---|---|
| `` rpc UpdateService(`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.UpdateServiceRequest`) returns (`https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service`) `` Updates a service. Authorization Scopes :   Requires the following OAuth scope: - `https://www.googleapis.com/auth/cloud-platform` For more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/). |

## CreateEndpointRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.CreateEndpoint`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the service that this endpoint provides. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.endpoints.create` |
| `endpoint_id` | `string` Required. The Resource ID must be 1-63 characters long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. |
| `endpoint` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` `` Required. A endpoint with initial fields set. |

## CreateNamespaceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.CreateNamespace`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the project and location the namespace will be created in. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.namespaces.create` |
| `namespace_id` | `string` Required. The Resource ID must be 1-63 characters long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. |
| `namespace` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace` `` Required. A namespace with initial fields set. |

## CreateServiceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.CreateService`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the namespace this service will belong to. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.services.create` |
| `service_id` | `string` Required. The Resource ID must be 1-63 characters long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. |
| `service` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` `` Required. A service with initial fields set. |

## DeleteEndpointRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.DeleteEndpoint`.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the endpoint to delete. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.endpoints.delete` |

## DeleteNamespaceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.DeleteNamespace`.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the namespace to delete. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.namespaces.delete` |

## DeleteServiceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.DeleteService`.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the service to delete. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.services.delete` |

## Endpoint

An individual endpoint that provides a `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service`. The service must already exist to create an endpoint.

| Fields ||
|---|---|
| `name` | `string` Immutable. The resource name for the endpoint in the format `projects/*/locations/*/namespaces/*/services/*/endpoints/*`. |
| `address` | `string` Optional. An IPv4 or IPv6 address. Service Directory rejects bad addresses like: - `8.8.8` - `8.8.8.8:53` - `test:bad:address` - `[::1]` - `[::1]:8080` Limited to 45 characters. |
| `port` | `int32` Optional. Service Directory rejects values outside of `[0, 65535]`. |
| `metadata` | `map<string, string>` Optional. Metadata for the endpoint. This data can be consumed by service clients. Restrictions: - The entire metadata dictionary may contain up to 512 characters, spread accoss all key-value pairs. Metadata that goes beyond this limit are rejected - Valid metadata keys have two segments: an optional prefix and name, separated by a slash (/). The name segment is required and must be 63 characters or less, beginning and ending with an alphanumeric character (\[a-z0-9A-Z\]) with dashes (-), underscores (_), dots (.), and alphanumerics between. The prefix is optional. If specified, the prefix must be a DNS subdomain: a series of DNS labels separated by dots (.), not longer than 253 characters in total, followed by a slash (/). Metadata that fails to meet these requirements are rejected Note: This field is equivalent to the `annotations` field in the v1 API. They have the same syntax and read/write to the same location in Service Directory. |
| `network` | `string` Immutable. The Google Compute Engine network (VPC) of the endpoint in the format `projects/<project number>/locations/global/networks/*`. The project must be specified by project number (project id is rejected). Incorrectly formatted networks are rejected, but no other validation is performed on this field (ex. network or project existence, reachability, or permissions). |
| `create_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the endpoint was created. |
| `update_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the endpoint was last updated. |

## GetEndpointRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.GetEndpoint`. This should not be used to lookup endpoints at runtime. Instead, use the `resolve` method.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the endpoint to get. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.endpoints.get` |

## GetNamespaceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.GetNamespace`.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the namespace to retrieve. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.namespaces.get` |

## GetServiceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.GetService`. This should not be used for looking up a service. Insead, use the `resolve` method as it contains all endpoints and associated metadata.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the service to get. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.services.get` |

## ListEndpointsRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the service whose endpoints you'd like to list. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.endpoints.list` |
| `page_size` | `int32` Optional. The maximum number of items to return. |
| `page_token` | `string` Optional. The next_page_token value returned from a previous List request, if any. |
| `filter` | `string` Optional. The filter to list results by. General `filter` string syntax: `<field> <operator> <value> (<logical connector>)` - `<field>` can be `name`, `address`, `port`, or `metadata.<key>` for map field - `<operator>` can be `<`, `>`, `<=`, `>=`, `!=`, `=`, `:`. Of which `:` means `HAS`, and is roughly the same as `=` - `<value>` must be the same data type as field - `<logical connector>` can be `AND`, `OR`, `NOT` Examples of valid filters: - `metadata.owner` returns endpoints that have a metadata with the key `owner`, this is the same as `metadata:owner` - `metadata.protocol=gRPC` returns endpoints that have key/value `protocol=gRPC` - `address=192.108.1.105` returns endpoints that have this address - `port>8080` returns endpoints that have port number larger than 8080 \* `name>projects/my-project/locations/us-east1/namespaces/my-namespace/services/my-service/endpoints/endpoint-c` returns endpoints that have name that is alphabetically later than the string, so "endpoint-e" is returned but "endpoint-a" is not - `metadata.owner!=sd AND metadata.foo=bar` returns endpoints that have `owner` in metadata key but value is not `sd` AND have key/value `foo=bar` - `doesnotexist.foo=bar` returns an empty list. Note that endpoint doesn't have a field called "doesnotexist". Since the filter does not match any endpoints, it returns no results For more information about filtering, see [API Filtering](https://aip.dev/160). |
| `order_by` | `string` Optional. The order to list results by. General `order_by` string syntax: `<field> (<asc|desc>) (,)` - `<field>` allows values: `name`, `address`, `port` - `<asc|desc>` ascending or descending order by `<field>`. If this is left blank, `asc` is used Note that an empty `order_by` string results in default order, which is order by `name` in ascending order. |

## ListEndpointsResponse

The response message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints`.

| Fields ||
|---|---|
| `endpoints[]` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` `` The list of endpoints. |
| `next_page_token` | `string` Token to retrieve the next page of results, or empty if there are no more results in the list. |

## ListNamespacesRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListNamespaces`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the project and location whose namespaces you'd like to list. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.namespaces.list` |
| `page_size` | `int32` Optional. The maximum number of items to return. |
| `page_token` | `string` Optional. The next_page_token value returned from a previous List request, if any. |
| `filter` | `string` Optional. The filter to list results by. General `filter` string syntax: `<field> <operator> <value> (<logical connector>)` - `<field>` can be `name` or `labels.<key>` for map field - `<operator>` can be `<`, `>`, `<=`, `>=`, `!=`, `=`, `:`. Of which `:` means `HAS`, and is roughly the same as `=` - `<value>` must be the same data type as field - `<logical connector>` can be `AND`, `OR`, `NOT` Examples of valid filters: - `labels.owner` returns namespaces that have a label with the key `owner`, this is the same as `labels:owner` - `labels.owner=sd` returns namespaces that have key/value `owner=sd` - `name>projects/my-project/locations/us-east1/namespaces/namespace-c` returns namespaces that have name that is alphabetically later than the string, so "namespace-e" is returned but "namespace-a" is not - `labels.owner!=sd AND labels.foo=bar` returns namespaces that have `owner` in label key but value is not `sd` AND have key/value `foo=bar` - `doesnotexist.foo=bar` returns an empty list. Note that namespace doesn't have a field called "doesnotexist". Since the filter does not match any namespaces, it returns no results For more information about filtering, see [API Filtering](https://aip.dev/160). |
| `order_by` | `string` Optional. The order to list results by. General `order_by` string syntax: `<field> (<asc|desc>) (,)` - `<field>` allows value: `name` - `<asc|desc>` ascending or descending order by `<field>`. If this is left blank, `asc` is used Note that an empty `order_by` string results in default order, which is order by `name` in ascending order. |

## ListNamespacesResponse

The response message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListNamespaces`.

| Fields ||
|---|---|
| `namespaces[]` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace` `` The list of namespaces. |
| `next_page_token` | `string` Token to retrieve the next page of results, or empty if there are no more results in the list. |

## ListServicesRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListServices`.

| Fields ||
|---|---|
| `parent` | `string` Required. The resource name of the namespace whose services you'd like to list. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `parent`: - `servicedirectory.services.list` |
| `page_size` | `int32` Optional. The maximum number of items to return. |
| `page_token` | `string` Optional. The next_page_token value returned from a previous List request, if any. |
| `filter` | `string` Optional. The filter to list results by. General `filter` string syntax: `<field> <operator> <value> (<logical connector>)` - `<field>` can be `name` or `metadata.<key>` for map field - `<operator>` can be `<`, `>`, `<=`, `>=`, `!=`, `=`, `:`. Of which `:` means `HAS`, and is roughly the same as `=` - `<value>` must be the same data type as field - `<logical connector>` can be `AND`, `OR`, `NOT` Examples of valid filters: - `metadata.owner` returns services that have a metadata with the key `owner`, this is the same as `metadata:owner` - `metadata.protocol=gRPC` returns services that have key/value `protocol=gRPC` \* `name>projects/my-project/locations/us-east1/namespaces/my-namespace/services/service-c` returns services that have name that is alphabetically later than the string, so "service-e" is returned but "service-a" is not - `metadata.owner!=sd AND metadata.foo=bar` returns services that have `owner` in metadata key but value is not `sd` AND have key/value `foo=bar` - `doesnotexist.foo=bar` returns an empty list. Note that service doesn't have a field called "doesnotexist". Since the filter does not match any services, it returns no results For more information about filtering, see [API Filtering](https://aip.dev/160). |
| `order_by` | `string` Optional. The order to list results by. General `order_by` string syntax: `<field> (<asc|desc>) (,)` - `<field>` allows value: `name` - `<asc|desc>` ascending or descending order by `<field>`. If this is left blank, `asc` is used Note that an empty `order_by` string results in default order, which is order by `name` in ascending order. |

## ListServicesResponse

The response message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListServices`.

| Fields ||
|---|---|
| `services[]` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` `` The list of services. |
| `next_page_token` | `string` Token to retrieve the next page of results, or empty if there are no more results in the list. |

## Namespace

A container for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service`. Namespaces allow administrators to group services together and define permissions for a collection of services.

| Fields ||
|---|---|
| `name` | `string` Immutable. The resource name for the namespace in the format `projects/*/locations/*/namespaces/*`. |
| `labels` | `map<string, string>` Optional. Resource labels associated with this namespace. No more than 64 user labels can be associated with a given resource. Label keys and values can be no longer than 63 characters. |
| `create_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the namespace was created. |
| `update_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the namespace was last updated. |

## ResolveServiceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.LookupService.ResolveService`. Looks up a service by its name, returns the service and its endpoints.

| Fields ||
|---|---|
| `name` | `string` Required. The name of the service to resolve. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `servicedirectory.services.resolve` |
| `max_endpoints` | `int32` Optional. The maximum number of endpoints to return. Defaults to 25. Maximum is 100. If a value less than one is specified, the Default is used. If a value greater than the Maximum is specified, the Maximum is used. |
| `endpoint_filter` | `string` Optional. The filter applied to the endpoints of the resolved service. General `filter` string syntax: `<field> <operator> <value> (<logical connector>)` - `<field>` can be `name`, `address`, `port`, or `metadata.<key>` for map field - `<operator>` can be `<`, `>`, `<=`, `>=`, `!=`, `=`, `:`. Of which `:` means `HAS`, and is roughly the same as `=` - `<value>` must be the same data type as field - `<logical connector>` can be `AND`, `OR`, `NOT` Examples of valid filters: - `metadata.owner` returns endpoints that have a annotation with the key `owner`, this is the same as `metadata:owner` - `metadata.protocol=gRPC` returns endpoints that have key/value `protocol=gRPC` - `address=192.108.1.105` returns endpoints that have this address - `port>8080` returns endpoints that have port number larger than 8080 \* `name>projects/my-project/locations/us-east1/namespaces/my-namespace/services/my-service/endpoints/endpoint-c` returns endpoints that have name that is alphabetically later than the string, so "endpoint-e" is returned but "endpoint-a" is not - `metadata.owner!=sd AND metadata.foo=bar` returns endpoints that have `owner` in annotation key but value is not `sd` AND have key/value `foo=bar` - `doesnotexist.foo=bar` returns an empty list. Note that endpoint doesn't have a field called "doesnotexist". Since the filter does not match any endpoint, it returns no results For more information about filtering, see [API Filtering](https://aip.dev/160). |

## ResolveServiceResponse

The response message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.LookupService.ResolveService`.

| Fields ||
|---|---|
| `service` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` `` |

## Service

An individual service. A service contains a name and optional metadata. A service must exist before `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` can be added to it.

| Fields ||
|---|---|
| `name` | `string` Immutable. The resource name for the service in the format `projects/*/locations/*/namespaces/*/services/*`. |
| `metadata` | `map<string, string>` Optional. Metadata for the service. This data can be consumed by service clients. Restrictions: - The entire metadata dictionary may contain up to 2000 characters, spread accoss all key-value pairs. Metadata that goes beyond this limit are rejected - Valid metadata keys have two segments: an optional prefix and name, separated by a slash (/). The name segment is required and must be 63 characters or less, beginning and ending with an alphanumeric character (\[a-z0-9A-Z\]) with dashes (-), underscores (_), dots (.), and alphanumerics between. The prefix is optional. If specified, the prefix must be a DNS subdomain: a series of DNS labels separated by dots (.), not longer than 253 characters in total, followed by a slash (/). Metadata that fails to meet these requirements are rejected Note: This field is equivalent to the `annotations` field in the v1 API. They have the same syntax and read/write to the same location in Service Directory. |
| `endpoints[]` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` `` Output only. Endpoints associated with this service. Returned on `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.LookupService.ResolveService`. Control plane clients should use `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints`. |
| `create_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the service was created. |
| `update_time` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` `` Output only. The timestamp when the service was last updated. Note: endpoints being created/deleted/updated within the service are not considered service updates for the purpose of this timestamp. |

## UpdateEndpointRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.UpdateEndpoint`.

| Fields ||
|---|---|
| `endpoint` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Endpoint` `` Required. The updated endpoint. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `endpoint`: - `servicedirectory.endpoints.update` |
| `update_mask` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.FieldMask` `` Required. List of fields to be updated in this request. |

## UpdateNamespaceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.UpdateNamespace`.

| Fields ||
|---|---|
| `namespace` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Namespace` `` Required. The updated namespace. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `namespace`: - `servicedirectory.namespaces.update` |
| `update_mask` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.FieldMask` `` Required. List of fields to be updated in this request. |

## UpdateServiceRequest

The request message for `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.RegistrationService.UpdateService`.

| Fields ||
|---|---|
| `service` | `` `https://docs.cloud.google.com/service-directory/docs/reference/rpc/google.cloud.servicedirectory.v1beta1#google.cloud.servicedirectory.v1beta1.Service` `` Required. The updated service. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `service`: - `servicedirectory.services.update` |
| `update_mask` | `` `https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.FieldMask` `` Required. List of fields to be updated in this request. |