Documentation ¶
Index ¶
- Variables
- func RegisterApiKeysServer(s *grpc.Server, srv ApiKeysServer)
- type AndroidApplication
- func (*AndroidApplication) Descriptor() ([]byte, []int)deprecated
- func (x *AndroidApplication) GetPackageName() string
- func (x *AndroidApplication) GetSha1Fingerprint() string
- func (*AndroidApplication) ProtoMessage()
- func (x *AndroidApplication) ProtoReflect() protoreflect.Message
- func (x *AndroidApplication) Reset()
- func (x *AndroidApplication) String() string
- type AndroidKeyRestrictions
- func (*AndroidKeyRestrictions) Descriptor() ([]byte, []int)deprecated
- func (x *AndroidKeyRestrictions) GetAllowedApplications() []*AndroidApplication
- func (*AndroidKeyRestrictions) ProtoMessage()
- func (x *AndroidKeyRestrictions) ProtoReflect() protoreflect.Message
- func (x *AndroidKeyRestrictions) Reset()
- func (x *AndroidKeyRestrictions) String() string
- type ApiKeysClient
- type ApiKeysServer
- type ApiTarget
- type BrowserKeyRestrictions
- func (*BrowserKeyRestrictions) Descriptor() ([]byte, []int)deprecated
- func (x *BrowserKeyRestrictions) GetAllowedReferrers() []string
- func (*BrowserKeyRestrictions) ProtoMessage()
- func (x *BrowserKeyRestrictions) ProtoReflect() protoreflect.Message
- func (x *BrowserKeyRestrictions) Reset()
- func (x *BrowserKeyRestrictions) String() string
- type CreateKeyRequest
- func (*CreateKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateKeyRequest) GetKey() *Key
- func (x *CreateKeyRequest) GetKeyId() string
- func (x *CreateKeyRequest) GetParent() string
- func (*CreateKeyRequest) ProtoMessage()
- func (x *CreateKeyRequest) ProtoReflect() protoreflect.Message
- func (x *CreateKeyRequest) Reset()
- func (x *CreateKeyRequest) String() string
- type DeleteKeyRequest
- func (*DeleteKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteKeyRequest) GetEtag() string
- func (x *DeleteKeyRequest) GetName() string
- func (*DeleteKeyRequest) ProtoMessage()
- func (x *DeleteKeyRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteKeyRequest) Reset()
- func (x *DeleteKeyRequest) String() string
- type GetKeyRequest
- type GetKeyStringRequest
- func (*GetKeyStringRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetKeyStringRequest) GetName() string
- func (*GetKeyStringRequest) ProtoMessage()
- func (x *GetKeyStringRequest) ProtoReflect() protoreflect.Message
- func (x *GetKeyStringRequest) Reset()
- func (x *GetKeyStringRequest) String() string
- type GetKeyStringResponse
- func (*GetKeyStringResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetKeyStringResponse) GetKeyString() string
- func (*GetKeyStringResponse) ProtoMessage()
- func (x *GetKeyStringResponse) ProtoReflect() protoreflect.Message
- func (x *GetKeyStringResponse) Reset()
- func (x *GetKeyStringResponse) String() string
- type IosKeyRestrictions
- func (*IosKeyRestrictions) Descriptor() ([]byte, []int)deprecated
- func (x *IosKeyRestrictions) GetAllowedBundleIds() []string
- func (*IosKeyRestrictions) ProtoMessage()
- func (x *IosKeyRestrictions) ProtoReflect() protoreflect.Message
- func (x *IosKeyRestrictions) Reset()
- func (x *IosKeyRestrictions) String() string
- type Key
- func (*Key) Descriptor() ([]byte, []int)deprecated
- func (x *Key) GetAnnotations() map[string]string
- func (x *Key) GetCreateTime() *timestamppb.Timestamp
- func (x *Key) GetDeleteTime() *timestamppb.Timestamp
- func (x *Key) GetDisplayName() string
- func (x *Key) GetEtag() string
- func (x *Key) GetKeyString() string
- func (x *Key) GetName() string
- func (x *Key) GetRestrictions() *Restrictions
- func (x *Key) GetUid() string
- func (x *Key) GetUpdateTime() *timestamppb.Timestamp
- func (*Key) ProtoMessage()
- func (x *Key) ProtoReflect() protoreflect.Message
- func (x *Key) Reset()
- func (x *Key) String() string
- type ListKeysRequest
- func (*ListKeysRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListKeysRequest) GetPageSize() int32
- func (x *ListKeysRequest) GetPageToken() string
- func (x *ListKeysRequest) GetParent() string
- func (x *ListKeysRequest) GetShowDeleted() bool
- func (*ListKeysRequest) ProtoMessage()
- func (x *ListKeysRequest) ProtoReflect() protoreflect.Message
- func (x *ListKeysRequest) Reset()
- func (x *ListKeysRequest) String() string
- type ListKeysResponse
- func (*ListKeysResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListKeysResponse) GetKeys() []*Key
- func (x *ListKeysResponse) GetNextPageToken() string
- func (*ListKeysResponse) ProtoMessage()
- func (x *ListKeysResponse) ProtoReflect() protoreflect.Message
- func (x *ListKeysResponse) Reset()
- func (x *ListKeysResponse) String() string
- type LookupKeyRequest
- type LookupKeyResponse
- func (*LookupKeyResponse) Descriptor() ([]byte, []int)deprecated
- func (x *LookupKeyResponse) GetName() string
- func (x *LookupKeyResponse) GetParent() string
- func (*LookupKeyResponse) ProtoMessage()
- func (x *LookupKeyResponse) ProtoReflect() protoreflect.Message
- func (x *LookupKeyResponse) Reset()
- func (x *LookupKeyResponse) String() string
- type Restrictions
- func (*Restrictions) Descriptor() ([]byte, []int)deprecated
- func (x *Restrictions) GetAndroidKeyRestrictions() *AndroidKeyRestrictions
- func (x *Restrictions) GetApiTargets() []*ApiTarget
- func (x *Restrictions) GetBrowserKeyRestrictions() *BrowserKeyRestrictions
- func (m *Restrictions) GetClientRestrictions() isRestrictions_ClientRestrictions
- func (x *Restrictions) GetIosKeyRestrictions() *IosKeyRestrictions
- func (x *Restrictions) GetServerKeyRestrictions() *ServerKeyRestrictions
- func (*Restrictions) ProtoMessage()
- func (x *Restrictions) ProtoReflect() protoreflect.Message
- func (x *Restrictions) Reset()
- func (x *Restrictions) String() string
- type Restrictions_AndroidKeyRestrictions
- type Restrictions_BrowserKeyRestrictions
- type Restrictions_IosKeyRestrictions
- type Restrictions_ServerKeyRestrictions
- type ServerKeyRestrictions
- func (*ServerKeyRestrictions) Descriptor() ([]byte, []int)deprecated
- func (x *ServerKeyRestrictions) GetAllowedIps() []string
- func (*ServerKeyRestrictions) ProtoMessage()
- func (x *ServerKeyRestrictions) ProtoReflect() protoreflect.Message
- func (x *ServerKeyRestrictions) Reset()
- func (x *ServerKeyRestrictions) String() string
- type UndeleteKeyRequest
- func (*UndeleteKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UndeleteKeyRequest) GetName() string
- func (*UndeleteKeyRequest) ProtoMessage()
- func (x *UndeleteKeyRequest) ProtoReflect() protoreflect.Message
- func (x *UndeleteKeyRequest) Reset()
- func (x *UndeleteKeyRequest) String() string
- type UnimplementedApiKeysServer
- func (*UnimplementedApiKeysServer) CreateKey(context.Context, *CreateKeyRequest) (*longrunningpb.Operation, error)
- func (*UnimplementedApiKeysServer) DeleteKey(context.Context, *DeleteKeyRequest) (*longrunningpb.Operation, error)
- func (*UnimplementedApiKeysServer) GetKey(context.Context, *GetKeyRequest) (*Key, error)
- func (*UnimplementedApiKeysServer) GetKeyString(context.Context, *GetKeyStringRequest) (*GetKeyStringResponse, error)
- func (*UnimplementedApiKeysServer) ListKeys(context.Context, *ListKeysRequest) (*ListKeysResponse, error)
- func (*UnimplementedApiKeysServer) LookupKey(context.Context, *LookupKeyRequest) (*LookupKeyResponse, error)
- func (*UnimplementedApiKeysServer) UndeleteKey(context.Context, *UndeleteKeyRequest) (*longrunningpb.Operation, error)
- func (*UnimplementedApiKeysServer) UpdateKey(context.Context, *UpdateKeyRequest) (*longrunningpb.Operation, error)
- type UpdateKeyRequest
- func (*UpdateKeyRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateKeyRequest) GetKey() *Key
- func (x *UpdateKeyRequest) GetUpdateMask() *fieldmaskpb.FieldMask
- func (*UpdateKeyRequest) ProtoMessage()
- func (x *UpdateKeyRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateKeyRequest) Reset()
- func (x *UpdateKeyRequest) String() string
Constants ¶
This section is empty.
Variables ¶
var File_google_api_apikeys_v2_apikeys_proto protoreflect.FileDescriptor
var File_google_api_apikeys_v2_resources_proto protoreflect.FileDescriptor
Functions ¶
func RegisterApiKeysServer ¶
func RegisterApiKeysServer(s *grpc.Server, srv ApiKeysServer)
Types ¶
type AndroidApplication ¶
type AndroidApplication struct { // The SHA1 fingerprint of the application. For example, both sha1 formats are // acceptable : DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09 or // DA39A3EE5E6B4B0D3255BFEF95601890AFD80709. // Output format is the latter. Sha1Fingerprint string `protobuf:"bytes,1,opt,name=sha1_fingerprint,json=sha1Fingerprint,proto3" json:"sha1_fingerprint,omitempty"` // The package name of the application. PackageName string `protobuf:"bytes,2,opt,name=package_name,json=packageName,proto3" json:"package_name,omitempty"` // contains filtered or unexported fields }
Identifier of an Android application for key use.
func (*AndroidApplication) Descriptor
deprecated
func (*AndroidApplication) Descriptor() ([]byte, []int)
Deprecated: Use AndroidApplication.ProtoReflect.Descriptor instead.
func (*AndroidApplication) GetPackageName ¶
func (x *AndroidApplication) GetPackageName() string
func (*AndroidApplication) GetSha1Fingerprint ¶
func (x *AndroidApplication) GetSha1Fingerprint() string
func (*AndroidApplication) ProtoMessage ¶
func (*AndroidApplication) ProtoMessage()
func (*AndroidApplication) ProtoReflect ¶
func (x *AndroidApplication) ProtoReflect() protoreflect.Message
func (*AndroidApplication) Reset ¶
func (x *AndroidApplication) Reset()
func (*AndroidApplication) String ¶
func (x *AndroidApplication) String() string
type AndroidKeyRestrictions ¶
type AndroidKeyRestrictions struct { // A list of Android applications that are allowed to make API calls with // this key. AllowedApplications []*AndroidApplication `protobuf:"bytes,1,rep,name=allowed_applications,json=allowedApplications,proto3" json:"allowed_applications,omitempty"` // contains filtered or unexported fields }
The Android apps that are allowed to use the key.
func (*AndroidKeyRestrictions) Descriptor
deprecated
func (*AndroidKeyRestrictions) Descriptor() ([]byte, []int)
Deprecated: Use AndroidKeyRestrictions.ProtoReflect.Descriptor instead.
func (*AndroidKeyRestrictions) GetAllowedApplications ¶
func (x *AndroidKeyRestrictions) GetAllowedApplications() []*AndroidApplication
func (*AndroidKeyRestrictions) ProtoMessage ¶
func (*AndroidKeyRestrictions) ProtoMessage()
func (*AndroidKeyRestrictions) ProtoReflect ¶
func (x *AndroidKeyRestrictions) ProtoReflect() protoreflect.Message
func (*AndroidKeyRestrictions) Reset ¶
func (x *AndroidKeyRestrictions) Reset()
func (*AndroidKeyRestrictions) String ¶
func (x *AndroidKeyRestrictions) String() string
type ApiKeysClient ¶
type ApiKeysClient interface { // Creates a new API key. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. CreateKey(ctx context.Context, in *CreateKeyRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) // Lists the API keys owned by a project. The key string of the API key // isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. ListKeys(ctx context.Context, in *ListKeysRequest, opts ...grpc.CallOption) (*ListKeysResponse, error) // Gets the metadata for an API key. The key string of the API key // isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. GetKey(ctx context.Context, in *GetKeyRequest, opts ...grpc.CallOption) (*Key, error) // Get the key string for an API key. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. GetKeyString(ctx context.Context, in *GetKeyStringRequest, opts ...grpc.CallOption) (*GetKeyStringResponse, error) // Patches the modifiable fields of an API key. // The key string of the API key isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. UpdateKey(ctx context.Context, in *UpdateKeyRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) // Deletes an API key. Deleted key can be retrieved within 30 days of // deletion. Afterward, key will be purged from the project. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. DeleteKey(ctx context.Context, in *DeleteKeyRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) // Undeletes an API key which was deleted within 30 days. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. UndeleteKey(ctx context.Context, in *UndeleteKeyRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) // Find the parent project and resource name of the API // key that matches the key string in the request. If the API key has been // purged, resource name will not be set. // The service account must have the `apikeys.keys.lookup` permission // on the parent project. LookupKey(ctx context.Context, in *LookupKeyRequest, opts ...grpc.CallOption) (*LookupKeyResponse, error) }
ApiKeysClient is the client API for ApiKeys service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewApiKeysClient ¶
func NewApiKeysClient(cc grpc.ClientConnInterface) ApiKeysClient
type ApiKeysServer ¶
type ApiKeysServer interface { // Creates a new API key. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. CreateKey(context.Context, *CreateKeyRequest) (*longrunningpb.Operation, error) // Lists the API keys owned by a project. The key string of the API key // isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. ListKeys(context.Context, *ListKeysRequest) (*ListKeysResponse, error) // Gets the metadata for an API key. The key string of the API key // isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. GetKey(context.Context, *GetKeyRequest) (*Key, error) // Get the key string for an API key. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. GetKeyString(context.Context, *GetKeyStringRequest) (*GetKeyStringResponse, error) // Patches the modifiable fields of an API key. // The key string of the API key isn't included in the response. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. UpdateKey(context.Context, *UpdateKeyRequest) (*longrunningpb.Operation, error) // Deletes an API key. Deleted key can be retrieved within 30 days of // deletion. Afterward, key will be purged from the project. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. DeleteKey(context.Context, *DeleteKeyRequest) (*longrunningpb.Operation, error) // Undeletes an API key which was deleted within 30 days. // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. UndeleteKey(context.Context, *UndeleteKeyRequest) (*longrunningpb.Operation, error) // Find the parent project and resource name of the API // key that matches the key string in the request. If the API key has been // purged, resource name will not be set. // The service account must have the `apikeys.keys.lookup` permission // on the parent project. LookupKey(context.Context, *LookupKeyRequest) (*LookupKeyResponse, error) }
ApiKeysServer is the server API for ApiKeys service.
type ApiTarget ¶
type ApiTarget struct { // The service for this restriction. It should be the canonical // service name, for example: `translate.googleapis.com`. // You can use [`gcloud services list`](/sdk/gcloud/reference/services/list) // to get a list of services that are enabled in the project. Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service,omitempty"` // Optional. List of one or more methods that can be called. // If empty, all methods for the service are allowed. A wildcard // (*) can be used as the last symbol. // Valid examples: // `google.cloud.translate.v2.TranslateService.GetSupportedLanguage` // `TranslateText` // `Get*` // `translate.googleapis.com.Get*` Methods []string `protobuf:"bytes,2,rep,name=methods,proto3" json:"methods,omitempty"` // contains filtered or unexported fields }
A restriction for a specific service and optionally one or multiple specific methods. Both fields are case insensitive.
func (*ApiTarget) Descriptor
deprecated
func (*ApiTarget) GetMethods ¶
func (*ApiTarget) GetService ¶
func (*ApiTarget) ProtoMessage ¶
func (*ApiTarget) ProtoMessage()
func (*ApiTarget) ProtoReflect ¶
func (x *ApiTarget) ProtoReflect() protoreflect.Message
type BrowserKeyRestrictions ¶
type BrowserKeyRestrictions struct { // A list of regular expressions for the referrer URLs that are allowed // to make API calls with this key. AllowedReferrers []string `protobuf:"bytes,1,rep,name=allowed_referrers,json=allowedReferrers,proto3" json:"allowed_referrers,omitempty"` // contains filtered or unexported fields }
The HTTP referrers (websites) that are allowed to use the key.
func (*BrowserKeyRestrictions) Descriptor
deprecated
func (*BrowserKeyRestrictions) Descriptor() ([]byte, []int)
Deprecated: Use BrowserKeyRestrictions.ProtoReflect.Descriptor instead.
func (*BrowserKeyRestrictions) GetAllowedReferrers ¶
func (x *BrowserKeyRestrictions) GetAllowedReferrers() []string
func (*BrowserKeyRestrictions) ProtoMessage ¶
func (*BrowserKeyRestrictions) ProtoMessage()
func (*BrowserKeyRestrictions) ProtoReflect ¶
func (x *BrowserKeyRestrictions) ProtoReflect() protoreflect.Message
func (*BrowserKeyRestrictions) Reset ¶
func (x *BrowserKeyRestrictions) Reset()
func (*BrowserKeyRestrictions) String ¶
func (x *BrowserKeyRestrictions) String() string
type CreateKeyRequest ¶
type CreateKeyRequest struct { // Required. The project in which the API key is created. Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // Required. The API key fields to set at creation time. // You can configure only the `display_name`, `restrictions`, and // `annotations` fields. Key *Key `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"` // User specified key id (optional). If specified, it will become the final // component of the key resource name. // // The id must be unique within the project, must conform with RFC-1034, // is restricted to lower-cased letters, and has a maximum length of 63 // characters. In another word, the id must match the regular // expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. // // The id must NOT be a UUID-like string. KeyId string `protobuf:"bytes,3,opt,name=key_id,json=keyId,proto3" json:"key_id,omitempty"` // contains filtered or unexported fields }
Request message for `CreateKey` method.
func (*CreateKeyRequest) Descriptor
deprecated
func (*CreateKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateKeyRequest.ProtoReflect.Descriptor instead.
func (*CreateKeyRequest) GetKey ¶
func (x *CreateKeyRequest) GetKey() *Key
func (*CreateKeyRequest) GetKeyId ¶
func (x *CreateKeyRequest) GetKeyId() string
func (*CreateKeyRequest) GetParent ¶
func (x *CreateKeyRequest) GetParent() string
func (*CreateKeyRequest) ProtoMessage ¶
func (*CreateKeyRequest) ProtoMessage()
func (*CreateKeyRequest) ProtoReflect ¶
func (x *CreateKeyRequest) ProtoReflect() protoreflect.Message
func (*CreateKeyRequest) Reset ¶
func (x *CreateKeyRequest) Reset()
func (*CreateKeyRequest) String ¶
func (x *CreateKeyRequest) String() string
type DeleteKeyRequest ¶
type DeleteKeyRequest struct { // Required. The resource name of the API key to be deleted. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Optional. The etag known to the client for the expected state of the key. // This is to be used for optimistic concurrency. Etag string `protobuf:"bytes,2,opt,name=etag,proto3" json:"etag,omitempty"` // contains filtered or unexported fields }
Request message for `DeleteKey` method.
func (*DeleteKeyRequest) Descriptor
deprecated
func (*DeleteKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteKeyRequest.ProtoReflect.Descriptor instead.
func (*DeleteKeyRequest) GetEtag ¶
func (x *DeleteKeyRequest) GetEtag() string
func (*DeleteKeyRequest) GetName ¶
func (x *DeleteKeyRequest) GetName() string
func (*DeleteKeyRequest) ProtoMessage ¶
func (*DeleteKeyRequest) ProtoMessage()
func (*DeleteKeyRequest) ProtoReflect ¶
func (x *DeleteKeyRequest) ProtoReflect() protoreflect.Message
func (*DeleteKeyRequest) Reset ¶
func (x *DeleteKeyRequest) Reset()
func (*DeleteKeyRequest) String ¶
func (x *DeleteKeyRequest) String() string
type GetKeyRequest ¶
type GetKeyRequest struct { // Required. The resource name of the API key to get. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
Request message for `GetKey` method.
func (*GetKeyRequest) Descriptor
deprecated
func (*GetKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetKeyRequest.ProtoReflect.Descriptor instead.
func (*GetKeyRequest) GetName ¶
func (x *GetKeyRequest) GetName() string
func (*GetKeyRequest) ProtoMessage ¶
func (*GetKeyRequest) ProtoMessage()
func (*GetKeyRequest) ProtoReflect ¶
func (x *GetKeyRequest) ProtoReflect() protoreflect.Message
func (*GetKeyRequest) Reset ¶
func (x *GetKeyRequest) Reset()
func (*GetKeyRequest) String ¶
func (x *GetKeyRequest) String() string
type GetKeyStringRequest ¶
type GetKeyStringRequest struct { // Required. The resource name of the API key to be retrieved. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
Request message for `GetKeyString` method.
func (*GetKeyStringRequest) Descriptor
deprecated
func (*GetKeyStringRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetKeyStringRequest.ProtoReflect.Descriptor instead.
func (*GetKeyStringRequest) GetName ¶
func (x *GetKeyStringRequest) GetName() string
func (*GetKeyStringRequest) ProtoMessage ¶
func (*GetKeyStringRequest) ProtoMessage()
func (*GetKeyStringRequest) ProtoReflect ¶
func (x *GetKeyStringRequest) ProtoReflect() protoreflect.Message
func (*GetKeyStringRequest) Reset ¶
func (x *GetKeyStringRequest) Reset()
func (*GetKeyStringRequest) String ¶
func (x *GetKeyStringRequest) String() string
type GetKeyStringResponse ¶
type GetKeyStringResponse struct { // An encrypted and signed value of the key. KeyString string `protobuf:"bytes,1,opt,name=key_string,json=keyString,proto3" json:"key_string,omitempty"` // contains filtered or unexported fields }
Response message for `GetKeyString` method.
func (*GetKeyStringResponse) Descriptor
deprecated
func (*GetKeyStringResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetKeyStringResponse.ProtoReflect.Descriptor instead.
func (*GetKeyStringResponse) GetKeyString ¶
func (x *GetKeyStringResponse) GetKeyString() string
func (*GetKeyStringResponse) ProtoMessage ¶
func (*GetKeyStringResponse) ProtoMessage()
func (*GetKeyStringResponse) ProtoReflect ¶
func (x *GetKeyStringResponse) ProtoReflect() protoreflect.Message
func (*GetKeyStringResponse) Reset ¶
func (x *GetKeyStringResponse) Reset()
func (*GetKeyStringResponse) String ¶
func (x *GetKeyStringResponse) String() string
type IosKeyRestrictions ¶
type IosKeyRestrictions struct { // A list of bundle IDs that are allowed when making API calls with this key. AllowedBundleIds []string `protobuf:"bytes,1,rep,name=allowed_bundle_ids,json=allowedBundleIds,proto3" json:"allowed_bundle_ids,omitempty"` // contains filtered or unexported fields }
The iOS apps that are allowed to use the key.
func (*IosKeyRestrictions) Descriptor
deprecated
func (*IosKeyRestrictions) Descriptor() ([]byte, []int)
Deprecated: Use IosKeyRestrictions.ProtoReflect.Descriptor instead.
func (*IosKeyRestrictions) GetAllowedBundleIds ¶
func (x *IosKeyRestrictions) GetAllowedBundleIds() []string
func (*IosKeyRestrictions) ProtoMessage ¶
func (*IosKeyRestrictions) ProtoMessage()
func (*IosKeyRestrictions) ProtoReflect ¶
func (x *IosKeyRestrictions) ProtoReflect() protoreflect.Message
func (*IosKeyRestrictions) Reset ¶
func (x *IosKeyRestrictions) Reset()
func (*IosKeyRestrictions) String ¶
func (x *IosKeyRestrictions) String() string
type Key ¶
type Key struct { // Output only. The resource name of the key. // The `name` has the form: // `projects/<PROJECT_NUMBER>/locations/global/keys/<KEY_ID>`. // For example: // `projects/123456867718/locations/global/keys/b7ff1f9f-8275-410a-94dd-3855ee9b5dd2` // // NOTE: Key is a global resource; hence the only supported value for // location is `global`. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Output only. Unique id in UUID4 format. Uid string `protobuf:"bytes,5,opt,name=uid,proto3" json:"uid,omitempty"` // Human-readable display name of this key that you can modify. // The maximum length is 63 characters. DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` // Output only. An encrypted and signed value held by this key. // This field can be accessed only through the `GetKeyString` method. KeyString string `protobuf:"bytes,3,opt,name=key_string,json=keyString,proto3" json:"key_string,omitempty"` // Output only. A timestamp identifying the time this key was originally // created. CreateTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` // Output only. A timestamp identifying the time this key was last // updated. UpdateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` // Output only. A timestamp when this key was deleted. If the resource is not deleted, // this must be empty. DeleteTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=delete_time,json=deleteTime,proto3" json:"delete_time,omitempty"` // Annotations is an unstructured key-value map stored with a policy that // may be set by external tools to store and retrieve arbitrary metadata. // They are not queryable and should be preserved when modifying objects. Annotations map[string]string `` /* 163-byte string literal not displayed */ // Key restrictions. Restrictions *Restrictions `protobuf:"bytes,9,opt,name=restrictions,proto3" json:"restrictions,omitempty"` // Output only. A checksum computed by the server based on the current value of the Key // resource. This may be sent on update and delete requests to ensure the // client has an up-to-date value before proceeding. // See https://google.aip.dev/154. Etag string `protobuf:"bytes,11,opt,name=etag,proto3" json:"etag,omitempty"` // contains filtered or unexported fields }
The representation of a key managed by the API Keys API.
func (*Key) Descriptor
deprecated
func (*Key) GetAnnotations ¶
func (*Key) GetCreateTime ¶
func (x *Key) GetCreateTime() *timestamppb.Timestamp
func (*Key) GetDeleteTime ¶
func (x *Key) GetDeleteTime() *timestamppb.Timestamp
func (*Key) GetDisplayName ¶
func (*Key) GetKeyString ¶
func (*Key) GetRestrictions ¶
func (x *Key) GetRestrictions() *Restrictions
func (*Key) GetUpdateTime ¶
func (x *Key) GetUpdateTime() *timestamppb.Timestamp
func (*Key) ProtoMessage ¶
func (*Key) ProtoMessage()
func (*Key) ProtoReflect ¶
func (x *Key) ProtoReflect() protoreflect.Message
type ListKeysRequest ¶
type ListKeysRequest struct { // Required. Lists all API keys associated with this project. Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // Optional. Specifies the maximum number of results to be returned at a time. PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` // Optional. Requests a specific page of results. PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` // Optional. Indicate that keys deleted in the past 30 days should also be // returned. ShowDeleted bool `protobuf:"varint,6,opt,name=show_deleted,json=showDeleted,proto3" json:"show_deleted,omitempty"` // contains filtered or unexported fields }
Request message for `ListKeys` method.
func (*ListKeysRequest) Descriptor
deprecated
func (*ListKeysRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListKeysRequest.ProtoReflect.Descriptor instead.
func (*ListKeysRequest) GetPageSize ¶
func (x *ListKeysRequest) GetPageSize() int32
func (*ListKeysRequest) GetPageToken ¶
func (x *ListKeysRequest) GetPageToken() string
func (*ListKeysRequest) GetParent ¶
func (x *ListKeysRequest) GetParent() string
func (*ListKeysRequest) GetShowDeleted ¶
func (x *ListKeysRequest) GetShowDeleted() bool
func (*ListKeysRequest) ProtoMessage ¶
func (*ListKeysRequest) ProtoMessage()
func (*ListKeysRequest) ProtoReflect ¶
func (x *ListKeysRequest) ProtoReflect() protoreflect.Message
func (*ListKeysRequest) Reset ¶
func (x *ListKeysRequest) Reset()
func (*ListKeysRequest) String ¶
func (x *ListKeysRequest) String() string
type ListKeysResponse ¶
type ListKeysResponse struct { // A list of API keys. Keys []*Key `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"` // The pagination token for the next page of results. NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` // contains filtered or unexported fields }
Response message for `ListKeys` method.
func (*ListKeysResponse) Descriptor
deprecated
func (*ListKeysResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListKeysResponse.ProtoReflect.Descriptor instead.
func (*ListKeysResponse) GetKeys ¶
func (x *ListKeysResponse) GetKeys() []*Key
func (*ListKeysResponse) GetNextPageToken ¶
func (x *ListKeysResponse) GetNextPageToken() string
func (*ListKeysResponse) ProtoMessage ¶
func (*ListKeysResponse) ProtoMessage()
func (*ListKeysResponse) ProtoReflect ¶
func (x *ListKeysResponse) ProtoReflect() protoreflect.Message
func (*ListKeysResponse) Reset ¶
func (x *ListKeysResponse) Reset()
func (*ListKeysResponse) String ¶
func (x *ListKeysResponse) String() string
type LookupKeyRequest ¶
type LookupKeyRequest struct { // Required. Finds the project that owns the key string value. KeyString string `protobuf:"bytes,1,opt,name=key_string,json=keyString,proto3" json:"key_string,omitempty"` // contains filtered or unexported fields }
Request message for `LookupKey` method.
func (*LookupKeyRequest) Descriptor
deprecated
func (*LookupKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use LookupKeyRequest.ProtoReflect.Descriptor instead.
func (*LookupKeyRequest) GetKeyString ¶
func (x *LookupKeyRequest) GetKeyString() string
func (*LookupKeyRequest) ProtoMessage ¶
func (*LookupKeyRequest) ProtoMessage()
func (*LookupKeyRequest) ProtoReflect ¶
func (x *LookupKeyRequest) ProtoReflect() protoreflect.Message
func (*LookupKeyRequest) Reset ¶
func (x *LookupKeyRequest) Reset()
func (*LookupKeyRequest) String ¶
func (x *LookupKeyRequest) String() string
type LookupKeyResponse ¶
type LookupKeyResponse struct { // The project that owns the key with the value specified in the request. Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // The resource name of the API key. If the API key has been purged, // resource name is empty. Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
Response message for `LookupKey` method.
func (*LookupKeyResponse) Descriptor
deprecated
func (*LookupKeyResponse) Descriptor() ([]byte, []int)
Deprecated: Use LookupKeyResponse.ProtoReflect.Descriptor instead.
func (*LookupKeyResponse) GetName ¶
func (x *LookupKeyResponse) GetName() string
func (*LookupKeyResponse) GetParent ¶
func (x *LookupKeyResponse) GetParent() string
func (*LookupKeyResponse) ProtoMessage ¶
func (*LookupKeyResponse) ProtoMessage()
func (*LookupKeyResponse) ProtoReflect ¶
func (x *LookupKeyResponse) ProtoReflect() protoreflect.Message
func (*LookupKeyResponse) Reset ¶
func (x *LookupKeyResponse) Reset()
func (*LookupKeyResponse) String ¶
func (x *LookupKeyResponse) String() string
type Restrictions ¶
type Restrictions struct { // The websites, IP addresses, Android apps, or iOS apps (the clients) that // are allowed to use the key. You can specify only one type of client // restrictions per key. // // Types that are assignable to ClientRestrictions: // *Restrictions_BrowserKeyRestrictions // *Restrictions_ServerKeyRestrictions // *Restrictions_AndroidKeyRestrictions // *Restrictions_IosKeyRestrictions ClientRestrictions isRestrictions_ClientRestrictions `protobuf_oneof:"client_restrictions"` // A restriction for a specific service and optionally one or // more specific methods. Requests are allowed if they // match any of these restrictions. If no restrictions are // specified, all targets are allowed. ApiTargets []*ApiTarget `protobuf:"bytes,5,rep,name=api_targets,json=apiTargets,proto3" json:"api_targets,omitempty"` // contains filtered or unexported fields }
Describes the restrictions on the key.
func (*Restrictions) Descriptor
deprecated
func (*Restrictions) Descriptor() ([]byte, []int)
Deprecated: Use Restrictions.ProtoReflect.Descriptor instead.
func (*Restrictions) GetAndroidKeyRestrictions ¶
func (x *Restrictions) GetAndroidKeyRestrictions() *AndroidKeyRestrictions
func (*Restrictions) GetApiTargets ¶
func (x *Restrictions) GetApiTargets() []*ApiTarget
func (*Restrictions) GetBrowserKeyRestrictions ¶
func (x *Restrictions) GetBrowserKeyRestrictions() *BrowserKeyRestrictions
func (*Restrictions) GetClientRestrictions ¶
func (m *Restrictions) GetClientRestrictions() isRestrictions_ClientRestrictions
func (*Restrictions) GetIosKeyRestrictions ¶
func (x *Restrictions) GetIosKeyRestrictions() *IosKeyRestrictions
func (*Restrictions) GetServerKeyRestrictions ¶
func (x *Restrictions) GetServerKeyRestrictions() *ServerKeyRestrictions
func (*Restrictions) ProtoMessage ¶
func (*Restrictions) ProtoMessage()
func (*Restrictions) ProtoReflect ¶
func (x *Restrictions) ProtoReflect() protoreflect.Message
func (*Restrictions) Reset ¶
func (x *Restrictions) Reset()
func (*Restrictions) String ¶
func (x *Restrictions) String() string
type Restrictions_AndroidKeyRestrictions ¶
type Restrictions_AndroidKeyRestrictions struct { // The Android apps that are allowed to use the key. AndroidKeyRestrictions *AndroidKeyRestrictions `protobuf:"bytes,3,opt,name=android_key_restrictions,json=androidKeyRestrictions,proto3,oneof"` }
type Restrictions_BrowserKeyRestrictions ¶
type Restrictions_BrowserKeyRestrictions struct { // The HTTP referrers (websites) that are allowed to use the key. BrowserKeyRestrictions *BrowserKeyRestrictions `protobuf:"bytes,1,opt,name=browser_key_restrictions,json=browserKeyRestrictions,proto3,oneof"` }
type Restrictions_IosKeyRestrictions ¶
type Restrictions_IosKeyRestrictions struct { // The iOS apps that are allowed to use the key. IosKeyRestrictions *IosKeyRestrictions `protobuf:"bytes,4,opt,name=ios_key_restrictions,json=iosKeyRestrictions,proto3,oneof"` }
type Restrictions_ServerKeyRestrictions ¶
type Restrictions_ServerKeyRestrictions struct { // The IP addresses of callers that are allowed to use the key. ServerKeyRestrictions *ServerKeyRestrictions `protobuf:"bytes,2,opt,name=server_key_restrictions,json=serverKeyRestrictions,proto3,oneof"` }
type ServerKeyRestrictions ¶
type ServerKeyRestrictions struct { // A list of the caller IP addresses that are allowed to make API calls // with this key. AllowedIps []string `protobuf:"bytes,1,rep,name=allowed_ips,json=allowedIps,proto3" json:"allowed_ips,omitempty"` // contains filtered or unexported fields }
The IP addresses of callers that are allowed to use the key.
func (*ServerKeyRestrictions) Descriptor
deprecated
func (*ServerKeyRestrictions) Descriptor() ([]byte, []int)
Deprecated: Use ServerKeyRestrictions.ProtoReflect.Descriptor instead.
func (*ServerKeyRestrictions) GetAllowedIps ¶
func (x *ServerKeyRestrictions) GetAllowedIps() []string
func (*ServerKeyRestrictions) ProtoMessage ¶
func (*ServerKeyRestrictions) ProtoMessage()
func (*ServerKeyRestrictions) ProtoReflect ¶
func (x *ServerKeyRestrictions) ProtoReflect() protoreflect.Message
func (*ServerKeyRestrictions) Reset ¶
func (x *ServerKeyRestrictions) Reset()
func (*ServerKeyRestrictions) String ¶
func (x *ServerKeyRestrictions) String() string
type UndeleteKeyRequest ¶
type UndeleteKeyRequest struct { // Required. The resource name of the API key to be undeleted. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
Request message for `UndeleteKey` method.
func (*UndeleteKeyRequest) Descriptor
deprecated
func (*UndeleteKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use UndeleteKeyRequest.ProtoReflect.Descriptor instead.
func (*UndeleteKeyRequest) GetName ¶
func (x *UndeleteKeyRequest) GetName() string
func (*UndeleteKeyRequest) ProtoMessage ¶
func (*UndeleteKeyRequest) ProtoMessage()
func (*UndeleteKeyRequest) ProtoReflect ¶
func (x *UndeleteKeyRequest) ProtoReflect() protoreflect.Message
func (*UndeleteKeyRequest) Reset ¶
func (x *UndeleteKeyRequest) Reset()
func (*UndeleteKeyRequest) String ¶
func (x *UndeleteKeyRequest) String() string
type UnimplementedApiKeysServer ¶
type UnimplementedApiKeysServer struct { }
UnimplementedApiKeysServer can be embedded to have forward compatible implementations.
func (*UnimplementedApiKeysServer) CreateKey ¶
func (*UnimplementedApiKeysServer) CreateKey(context.Context, *CreateKeyRequest) (*longrunningpb.Operation, error)
func (*UnimplementedApiKeysServer) DeleteKey ¶
func (*UnimplementedApiKeysServer) DeleteKey(context.Context, *DeleteKeyRequest) (*longrunningpb.Operation, error)
func (*UnimplementedApiKeysServer) GetKey ¶
func (*UnimplementedApiKeysServer) GetKey(context.Context, *GetKeyRequest) (*Key, error)
func (*UnimplementedApiKeysServer) GetKeyString ¶
func (*UnimplementedApiKeysServer) GetKeyString(context.Context, *GetKeyStringRequest) (*GetKeyStringResponse, error)
func (*UnimplementedApiKeysServer) ListKeys ¶
func (*UnimplementedApiKeysServer) ListKeys(context.Context, *ListKeysRequest) (*ListKeysResponse, error)
func (*UnimplementedApiKeysServer) LookupKey ¶
func (*UnimplementedApiKeysServer) LookupKey(context.Context, *LookupKeyRequest) (*LookupKeyResponse, error)
func (*UnimplementedApiKeysServer) UndeleteKey ¶
func (*UnimplementedApiKeysServer) UndeleteKey(context.Context, *UndeleteKeyRequest) (*longrunningpb.Operation, error)
func (*UnimplementedApiKeysServer) UpdateKey ¶
func (*UnimplementedApiKeysServer) UpdateKey(context.Context, *UpdateKeyRequest) (*longrunningpb.Operation, error)
type UpdateKeyRequest ¶
type UpdateKeyRequest struct { // Required. Set the `name` field to the resource name of the API key to be // updated. You can update only the `display_name`, `restrictions`, and // `annotations` fields. Key *Key `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // The field mask specifies which fields to be updated as part of this // request. All other fields are ignored. // Mutable fields are: `display_name`, `restrictions`, and `annotations`. // If an update mask is not provided, the service treats it as an implied mask // equivalent to all allowed fields that are set on the wire. If the field // mask has a special value "*", the service treats it equivalent to replace // all allowed mutable fields. UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"` // contains filtered or unexported fields }
Request message for `UpdateKey` method.
func (*UpdateKeyRequest) Descriptor
deprecated
func (*UpdateKeyRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateKeyRequest.ProtoReflect.Descriptor instead.
func (*UpdateKeyRequest) GetKey ¶
func (x *UpdateKeyRequest) GetKey() *Key
func (*UpdateKeyRequest) GetUpdateMask ¶
func (x *UpdateKeyRequest) GetUpdateMask() *fieldmaskpb.FieldMask
func (*UpdateKeyRequest) ProtoMessage ¶
func (*UpdateKeyRequest) ProtoMessage()
func (*UpdateKeyRequest) ProtoReflect ¶
func (x *UpdateKeyRequest) ProtoReflect() protoreflect.Message
func (*UpdateKeyRequest) Reset ¶
func (x *UpdateKeyRequest) Reset()
func (*UpdateKeyRequest) String ¶
func (x *UpdateKeyRequest) String() string