View Source GoogleApi.APIKeys.V2.Api.Projects (google_api_api_keys v0.7.0)

API calls for all endpoints tagged Projects.

Summary

Functions

Creates a new API key. NOTE: Key is a global resource; hence the only supported value for location is global.

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.

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.

Get the key string for an API key. NOTE: Key is a global resource; hence the only supported value for location is global.

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.

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.

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.

Functions

Link to this function

apikeys_projects_locations_keys_create(connection, parent, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_create(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.Operation.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

Creates a new API key. NOTE: Key is a global resource; hence the only supported value for location is global.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • parent (type: String.t) - Required. The project in which the API key is created.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
    • :keyId (type: String.t) - 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.
    • :body (type: GoogleApi.APIKeys.V2.Model.V2Key.t) -
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.Operation{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_delete(connection, name, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_delete(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.Operation.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

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.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • name (type: String.t) - Required. The resource name of the API key to be deleted.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
    • :etag (type: String.t) - Optional. The etag known to the client for the expected state of the key. This is to be used for optimistic concurrency.
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.Operation{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_get(connection, name, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_get(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.V2Key.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

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.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • name (type: String.t) - Required. The resource name of the API key to get.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.V2Key{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_get_key_string(connection, name, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_get_key_string(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.V2GetKeyStringResponse.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

Get the key string for an API key. NOTE: Key is a global resource; hence the only supported value for location is global.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • name (type: String.t) - Required. The resource name of the API key to be retrieved.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.V2GetKeyStringResponse{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_list(connection, parent, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_list(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.V2ListKeysResponse.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

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.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • parent (type: String.t) - Required. Lists all API keys associated with this project.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
    • :pageSize (type: integer()) - Optional. Specifies the maximum number of results to be returned at a time.
    • :pageToken (type: String.t) - Optional. Requests a specific page of results.
    • :showDeleted (type: boolean()) - Optional. Indicate that keys deleted in the past 30 days should also be returned.
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.V2ListKeysResponse{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_patch(connection, name, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_patch(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.Operation.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

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.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • name (type: String.t) - Output only. The resource name of the key. The name has the form: projects//locations/global/keys/. 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.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
    • :updateMask (type: String.t) - 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.
    • :body (type: GoogleApi.APIKeys.V2.Model.V2Key.t) -
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.Operation{}} on success
  • {:error, info} on failure
Link to this function

apikeys_projects_locations_keys_undelete(connection, name, optional_params \\ [], opts \\ [])

View Source
@spec apikeys_projects_locations_keys_undelete(
  Tesla.Env.client(),
  String.t(),
  keyword(),
  keyword()
) ::
  {:ok, GoogleApi.APIKeys.V2.Model.Operation.t()}
  | {:ok, Tesla.Env.t()}
  | {:ok, list()}
  | {:error, any()}

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.

Parameters

  • connection (type: GoogleApi.APIKeys.V2.Connection.t) - Connection to server
  • name (type: String.t) - Required. The resource name of the API key to be undeleted.
  • optional_params (type: keyword()) - Optional parameters
    • :"$.xgafv" (type: String.t) - V1 error format.
    • :access_token (type: String.t) - OAuth access token.
    • :alt (type: String.t) - Data format for response.
    • :callback (type: String.t) - JSONP
    • :fields (type: String.t) - Selector specifying which fields to include in a partial response.
    • :key (type: String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (type: String.t) - OAuth 2.0 token for the current user.
    • :prettyPrint (type: boolean()) - Returns response with indentations and line breaks.
    • :quotaUser (type: String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
    • :uploadType (type: String.t) - Legacy upload protocol for media (e.g. "media", "multipart").
    • :upload_protocol (type: String.t) - Upload protocol for media (e.g. "raw", "multipart").
    • :body (type: GoogleApi.APIKeys.V2.Model.V2UndeleteKeyRequest.t) -
  • opts (type: keyword()) - Call options

Returns

  • {:ok, %GoogleApi.APIKeys.V2.Model.Operation{}} on success
  • {:error, info} on failure