Go to console

Package google.firestore.admin.v1beta1

Index

FirestoreAdmin

The Cloud Firestore Admin API.

This API provides several administrative services for Cloud Firestore.

Concepts

Project, Database, Namespace, Collection, and Document are used as defined in the Google Cloud Firestore API.

Operation: An Operation represents work being performed in the background.

Services

Index

The index service manages Cloud Firestore indexes.

Index creation is performed asynchronously. An Operation resource is created for each such asynchronous operation. The state of the operation (including any errors encountered) may be queried via the Operation resource.

Metadata

Provides metadata and statistical information about data in Cloud Firestore. The data provided as part of this API may be stale.

Operation

The Operations collection provides a record of actions performed for the specified Project (including any Operations in progress). Operations are not created directly but through calls on other collections or resources.

An Operation that is not yet done may be cancelled. The request to cancel is asynchronous and the Operation may continue to run for some time after the request to cancel is made.

An Operation that is done may be deleted so that it is no longer listed as part of the Operation collection.

Operations are created by service FirestoreAdmin, but are accessed via service google.longrunning.Operations.

CreateIndex

rpc CreateIndex(CreateIndexRequest) returns (Operation)

Creates the specified index. A newly created index's initial state is CREATING. On completion of the returned google.longrunning.Operation, the state will be READY. If the index already exists, the call will return an ALREADY_EXISTS status.

During creation, the process could result in an error, in which case the index will move to the ERROR state. The process can be recovered by fixing the data that caused the error, removing the index with delete, then re-creating the index with create.

Indexes with a single field cannot be created.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DeleteIndex

rpc DeleteIndex(DeleteIndexRequest) returns (Empty)

Deletes an index.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ExportDocuments

rpc ExportDocuments(ExportDocumentsRequest) returns (Operation)

Exports a copy of all or a subset of documents from Google Cloud Firestore to another storage system, such as Google Cloud Storage. Recent updates to documents may not be reflected in the export. The export occurs in the background and its progress can be monitored and managed via the Operation resource that is created. The output of an export may only be used once the associated operation is done. If an export operation is cancelled before completion it may leave partial data behind in Google Cloud Storage.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

GetIndex

rpc GetIndex(GetIndexRequest) returns (Index)

Gets an index.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ImportDocuments

rpc ImportDocuments(ImportDocumentsRequest) returns (Operation)

Imports documents into Google Cloud Firestore. Existing documents with the same name are overwritten. The import occurs in the background and its progress can be monitored and managed via the Operation resource that is created. If an ImportDocuments operation is cancelled, it is possible that a subset of the data has already been imported to Cloud Firestore.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ListIndexes

rpc ListIndexes(ListIndexesRequest) returns (ListIndexesResponse)

Lists the indexes that match the specified filters.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/datastore
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

CreateIndexRequest

The request for FirestoreAdmin.CreateIndex.

Fields
parent

string

The name of the database this index will apply to. For example: projects/{project_id}/databases/{database_id}

index

Index

The index to create. The name and state fields are output only and will be ignored. Certain single field indexes cannot be created or deleted.

DeleteIndexRequest

The request for FirestoreAdmin.DeleteIndex.

Fields
name

string

The index name. For example: projects/{project_id}/databases/{database_id}/indexes/{index_id}

ExportDocumentsMetadata

Metadata for ExportDocuments operations.

Fields
start_time

Timestamp

The time that work began on the operation.

end_time

Timestamp

The time the operation ended, either successfully or otherwise. Unset if the operation is still active.

operation_state

OperationState

The state of the export operation.

progress_documents

Progress

An estimate of the number of documents processed.

progress_bytes

Progress

An estimate of the number of bytes processed.

collection_ids[]

string

Which collection ids are being exported.

output_uri_prefix

string

Where the entities are being exported to.

ExportDocumentsRequest

The request for FirestoreAdmin.ExportDocuments.

Fields
name

string

Database to export. Should be of the form: projects/{project_id}/databases/{database_id}.

collection_ids[]

string

Which collection ids to export. Unspecified means all collections.

output_uri_prefix

string

The output URI. Currently only supports Google Cloud Storage URIs of the form: gs://BUCKET_NAME[/NAMESPACE_PATH], where BUCKET_NAME is the name of the Google Cloud Storage bucket and NAMESPACE_PATH is an optional Google Cloud Storage namespace path. When choosing a name, be sure to consider Google Cloud Storage naming guidelines: https://cloud.google.com/storage/docs/naming. If the URI is a bucket (without a namespace path), a prefix will be generated based on the start time.

ExportDocumentsResponse

Returned in the