android_apps
Creates, updates, deletes, gets or lists an android_apps
resource.
Overview
Name | android_apps |
Type | Resource |
Id | firebase.firebase.android_apps |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The resource name of the AndroidApp, in the format: projects/ PROJECT_IDENTIFIER/androidApps/APP_ID * PROJECT_IDENTIFIER: the parent Project's ProjectNumber (recommended) or its ProjectId . Learn more about using project identifiers in Google's AIP 2510 standard. Note that the value for PROJECT_IDENTIFIER in any response body will be the ProjectId . * APP_ID: the globally unique, Firebase-assigned identifier for the App (see appId ). |
apiKeyId | string | The globally unique, Google-assigned identifier (UID) for the Firebase API key associated with the AndroidApp . Be aware that this value is the UID of the API key, not the keyString of the API key. The keyString is the value that can be found in the App's configuration artifact. If api_key_id is not set in requests to androidApps.Create , then Firebase automatically associates an api_key_id with the AndroidApp . This auto-associated key may be an existing valid key or, if no valid key exists, a new one will be provisioned. In patch requests, api_key_id cannot be set to an empty value, and the new UID must have no restrictions or only have restrictions that are valid for the associated AndroidApp . We recommend using the Google Cloud Console to manage API keys. |
appId | string | Output only. Immutable. The globally unique, Firebase-assigned identifier for the AndroidApp . This identifier should be treated as an opaque token, as the data format is not specified. |
displayName | string | The user-assigned display name for the AndroidApp . |
etag | string | This checksum is computed by the server based on the value of other fields, and it may be sent with update requests to ensure the client has an up-to-date value before proceeding. Learn more about etag in Google's AIP-154 standard. This etag is strongly validated. |
expireTime | string (google-datetime) | Output only. If the App has been removed from the Project, this is the timestamp of when the App is considered expired and will be permanently deleted. After this time, the App cannot be undeleted (that is, restored to the Project). This value is only provided if the App is in the DELETED state. |
packageName | string | Immutable. The canonical package name of the Android app as would appear in the Google Play Developer Console. |
projectId | string | Output only. Immutable. A user-assigned unique identifier of the parent FirebaseProject for the AndroidApp . |
sha1Hashes | array | The SHA1 certificate hashes for the AndroidApp. |
sha256Hashes | array | The SHA256 certificate hashes for the AndroidApp. |
state | string | Output only. The lifecycle state of the App. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The resource name of the AndroidApp, in the format: projects/ PROJECT_IDENTIFIER/androidApps/APP_ID * PROJECT_IDENTIFIER: the parent Project's ProjectNumber (recommended) or its ProjectId . Learn more about using project identifiers in Google's AIP 2510 standard. Note that the value for PROJECT_IDENTIFIER in any response body will be the ProjectId . * APP_ID: the globally unique, Firebase-assigned identifier for the App (see appId ). |
apiKeyId | string | The globally unique, Google-assigned identifier (UID) for the Firebase API key associated with the AndroidApp . Be aware that this value is the UID of the API key, not the keyString of the API key. The keyString is the value that can be found in the App's configuration artifact. If api_key_id is not set in requests to androidApps.Create , then Firebase automatically associates an api_key_id with the AndroidApp . This auto-associated key may be an existing valid key or, if no valid key exists, a new one will be provisioned. In patch requests, api_key_id cannot be set to an empty value, and the new UID must have no restrictions or only have restrictions that are valid for the associated AndroidApp . We recommend using the Google Cloud Console to manage API keys. |
appId | string | Output only. Immutable. The globally unique, Firebase-assigned identifier for the AndroidApp . This identifier should be treated as an opaque token, as the data format is not specified. |
displayName | string | The user-assigned display name for the AndroidApp . |
etag | string | This checksum is computed by the server based on the value of other fields, and it may be sent with update requests to ensure the client has an up-to-date value before proceeding. Learn more about etag in Google's AIP-154 standard. This etag is strongly validated. |
expireTime | string (google-datetime) | Output only. If the App has been removed from the Project, this is the timestamp of when the App is considered expired and will be permanently deleted. After this time, the App cannot be undeleted (that is, restored to the Project). This value is only provided if the App is in the DELETED state. |
packageName | string | Immutable. The canonical package name of the Android app as would appear in the Google Play Developer Console. |
projectId | string | Output only. Immutable. A user-assigned unique identifier of the parent FirebaseProject for the AndroidApp . |
sha1Hashes | array | The SHA1 certificate hashes for the AndroidApp. |
sha256Hashes | array | The SHA256 certificate hashes for the AndroidApp. |
state | string | Output only. The lifecycle state of the App. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , androidAppsId | Gets the specified AndroidApp. | |
list | select | projectsId | pageToken , pageSize , showDeleted | Lists each AndroidApp associated with the specified FirebaseProject. The elements are returned in no particular order, but will be a consistent view of the Apps when additional requests are made with a pageToken . |
create | insert | projectsId | Requests the creation of a new AndroidApp in the specified FirebaseProject. The result of this call is an Operation which can be used to track the provisioning process. The Operation is automatically deleted after completion, so there is no need to call DeleteOperation . | |
patch | update | projectsId , androidAppsId | updateMask | Updates the attributes of the specified AndroidApp. |
remove | delete | projectsId , androidAppsId | Removes the specified AndroidApp from the FirebaseProject. | |
undelete | exec | projectsId , androidAppsId | Restores the specified AndroidApp to the FirebaseProject. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
androidAppsId | string | |
projectsId | string | |
pageSize | integer (int32) | |
pageToken | string | |
showDeleted | boolean | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets the specified AndroidApp.
SELECT
name,
apiKeyId,
appId,
displayName,
etag,
expireTime,
packageName,
projectId,
sha1Hashes,
sha256Hashes,
state
FROM firebase.firebase.android_apps
WHERE projectsId = '{{ projectsId }}' -- required
AND androidAppsId = '{{ androidAppsId }}' -- required;
Lists each AndroidApp associated with the specified FirebaseProject. The elements are returned in no particular order, but will be a consistent view of the Apps when additional requests are made with a pageToken
.
SELECT
name,
apiKeyId,
appId,
displayName,
etag,
expireTime,
packageName,
projectId,
sha1Hashes,
sha256Hashes,
state
FROM firebase.firebase.android_apps
WHERE projectsId = '{{ projectsId }}' -- required
AND pageToken = '{{ pageToken }}'
AND pageSize = '{{ pageSize }}'
AND showDeleted = '{{ showDeleted }}';
INSERT
examples
- create
- Manifest
Requests the creation of a new AndroidApp in the specified FirebaseProject. The result of this call is an Operation
which can be used to track the provisioning process. The Operation
is automatically deleted after completion, so there is no need to call DeleteOperation
.
INSERT INTO firebase.firebase.android_apps (
data__name,
data__displayName,
data__packageName,
data__apiKeyId,
data__sha1Hashes,
data__sha256Hashes,
data__etag,
projectsId
)
SELECT
'{{ name }}',
'{{ displayName }}',
'{{ packageName }}',
'{{ apiKeyId }}',
'{{ sha1Hashes }}',
'{{ sha256Hashes }}',
'{{ etag }}',
'{{ projectsId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: android_apps
props:
- name: projectsId
value: string
description: Required parameter for the android_apps resource.
- name: name
value: string
description: >
The resource name of the AndroidApp, in the format: projects/ PROJECT_IDENTIFIER/androidApps/APP_ID * PROJECT_IDENTIFIER: the parent Project's [`ProjectNumber`](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects#FirebaseProject.FIELDS.project_number) ***(recommended)*** or its [`ProjectId`](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects#FirebaseProject.FIELDS.project_id). Learn more about using project identifiers in Google's [AIP 2510 standard](https://google.aip.dev/cloud/2510). Note that the value for PROJECT_IDENTIFIER in any response body will be the `ProjectId`. * APP_ID: the globally unique, Firebase-assigned identifier for the App (see [`appId`](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects.androidApps#resource:-androidapp)).
- name: displayName
value: string
description: >
The user-assigned display name for the `AndroidApp`.
- name: packageName
value: string
description: >
Immutable. The canonical package name of the Android app as would appear in the Google Play Developer Console.
- name: apiKeyId
value: string
description: >
The globally unique, Google-assigned identifier (UID) for the Firebase API key associated with the `AndroidApp`. Be aware that this value is the UID of the API key, _not_ the [`keyString`](https://cloud.google.com/api-keys/docs/reference/rest/v2/projects.locations.keys#Key.FIELDS.key_string) of the API key. The `keyString` is the value that can be found in the App's [configuration artifact](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects.androidApps/getConfig). If `api_key_id` is not set in requests to [`androidApps.Create`](https://firebase.google.com/docs/reference/firebase-management/rest/v1beta1/projects.androidApps/create), then Firebase automatically associates an `api_key_id` with the `AndroidApp`. This auto-associated key may be an existing valid key or, if no valid key exists, a new one will be provisioned. In patch requests, `api_key_id` cannot be set to an empty value, and the new UID must have no restrictions or only have restrictions that are valid for the associated `AndroidApp`. We recommend using the [Google Cloud Console](https://console.cloud.google.com/apis/credentials) to manage API keys.
- name: sha1Hashes
value: array
description: >
The SHA1 certificate hashes for the AndroidApp.
- name: sha256Hashes
value: array
description: >
The SHA256 certificate hashes for the AndroidApp.
- name: etag
value: string
description: >
This checksum is computed by the server based on the value of other fields, and it may be sent with update requests to ensure the client has an up-to-date value before proceeding. Learn more about `etag` in Google's [AIP-154 standard](https://google.aip.dev/154#declarative-friendly-resources). This etag is strongly validated.
UPDATE
examples
- patch
Updates the attributes of the specified AndroidApp.
UPDATE firebase.firebase.android_apps
SET
data__name = '{{ name }}',
data__displayName = '{{ displayName }}',
data__packageName = '{{ packageName }}',
data__apiKeyId = '{{ apiKeyId }}',
data__sha1Hashes = '{{ sha1Hashes }}',
data__sha256Hashes = '{{ sha256Hashes }}',
data__etag = '{{ etag }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND androidAppsId = '{{ androidAppsId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
apiKeyId,
appId,
displayName,
etag,
expireTime,
packageName,
projectId,
sha1Hashes,
sha256Hashes,
state;
DELETE
examples
- remove
Removes the specified AndroidApp from the FirebaseProject.
DELETE FROM firebase.firebase.android_apps
WHERE projectsId = '{{ projectsId }}' --required
AND androidAppsId = '{{ androidAppsId }}' --required;
Lifecycle Methods
- undelete
Restores the specified AndroidApp to the FirebaseProject.
EXEC firebase.firebase.android_apps.undelete
@projectsId='{{ projectsId }}' --required,
@androidAppsId='{{ androidAppsId }}' --required
@@json=
'{
"validateOnly": {{ validateOnly }},
"etag": "{{ etag }}"
}';