Skip to main content

Gcp/firestore

@swamp/gcp/firestorev2026.06.03.1· 1d agoMODELS
01README

Google Cloud firestore infrastructure models

02Release Notes
  • Updated: databases_collectiongroups_fields, databases_collectiongroups_indexes
03Models8
@swamp/gcp/firestore/backupsv2026.05.25.1backups.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn get(identifier: string)
Get a backups
ArgumentTypeDescription
identifierstringThe name of the backups
fn delete(identifier: string)
Delete the backups
ArgumentTypeDescription
identifierstringThe name of the backups
fn sync()
Sync backups state from GCP
fn list(filter?: string, maxPages?: number)
List backups resources
ArgumentTypeDescription
filter?stringAn expression that filters the list of returned backups. A filter expression consists of a field name, a comparison operator, and a value for filtering. The value must be a string, a number, or a boolean. The comparison operator must be one of: `<`, `>`, `<=`, `>=`, `!=`, `=`, or `:`. Colon `:` is the contains operator. Filter rules are not case sensitive. The following fields in the Backup are eligible for filtering: * `database_uid` (supports `=` only)
maxPages?numberMaximum number of pages to fetch (default: 10)

Resources

state(infinite)— A Backup of a Cloud Firestore Database. The backup contains all documents and...
@swamp/gcp/firestore/databasesv2026.05.26.1databases.ts

Global Arguments

ArgumentTypeDescription
appEngineIntegrationMode?enumThe App Engine integration mode to use for this database.
cmekConfig?objectThe CMEK (Customer Managed Encryption Key) configuration for a Firestore database. If not present, the database is secured by the default Google encryption key.
concurrencyMode?enumThe default concurrency control mode to use for this database. If unspecified in a CreateDatabase request, this will default based on the database edition: Optimistic for Enterprise and Pessimistic for all other databases. While transactions can explicitly specify their own concurrency mode, this setting defines the default behavior when left unspecified. Important: This database-level setting is not respected for Firestore with MongoDB compatibility. All transactions through the MongoDB compati
databaseEdition?enumImmutable. The edition of the database.
deleteProtectionState?enumState of delete protection for the database.
firestoreDataAccessMode?enumOptional. The Firestore API data access mode to use for this database. If not set on write: - the default value is DATA_ACCESS_MODE_DISABLED for Enterprise Edition. - the default value is DATA_ACCESS_MODE_ENABLED for Standard Edition.
locationId?stringRequired. The location of the database. Available locations are listed at https://cloud.google.com/firestore/docs/locations.
mongodbCompatibleDataAccessMode?enumOptional. The MongoDB compatible API data access mode to use for this database. If not set on write, the default value is DATA_ACCESS_MODE_ENABLED for Enterprise Edition. The value is always DATA_ACCESS_MODE_DISABLED for Standard Edition.
name?stringThe resource name of the Database. Format: `projects/{project}/databases/{database}`
pointInTimeRecoveryEnablement?enumWhether to enable the PITR feature on this database.
realtimeUpdatesMode?enumImmutable. The default Realtime Updates mode to use for this database.
sourceInfo?objectInformation about the provenance of this database.
tags?recordOptional. Input only. Immutable. Tag keys/values directly bound to this resource. For example: "123/environment": "production", "123/costCenter": "marketing"
type?enumRequired. The type of the database. See https://cloud.google.com/datastore/docs/firestore-or-datastore for information about how to choose.
databaseId?stringRequired. The ID to use for the database, which will become the final component of the database\
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn create()
Create a databases
fn get(identifier: string)
Get a databases
ArgumentTypeDescription
identifierstringThe name of the databases
fn update()
Update databases attributes
fn delete(identifier: string)
Delete the databases
ArgumentTypeDescription
identifierstringThe name of the databases
fn sync()
Sync databases state from GCP
fn list(showDeleted?: boolean, maxPages?: number)
List databases resources
ArgumentTypeDescription
showDeleted?booleanIf true, also returns deleted resources.
maxPages?numberMaximum number of pages to fetch (default: 10)
fn bulk_delete_documents(collectionIds?: any, namespaceIds?: any)
bulk delete documents
ArgumentTypeDescription
collectionIds?any
namespaceIds?any
fn clone(databaseId?: any, encryptionConfig?: any, pitrSnapshot?: any, tags?: any)
clone
ArgumentTypeDescription
databaseId?any
encryptionConfig?any
pitrSnapshot?any
tags?any
fn export_documents(collectionIds?: any, namespaceIds?: any, outputUriPrefix?: any, snapshotTime?: any)
export documents
ArgumentTypeDescription
collectionIds?any
namespaceIds?any
outputUriPrefix?any
snapshotTime?any
fn import_documents(collectionIds?: any, inputUriPrefix?: any, namespaceIds?: any)
import documents
ArgumentTypeDescription
collectionIds?any
inputUriPrefix?any
namespaceIds?any
fn restore(backup?: any, databaseId?: any, encryptionConfig?: any, tags?: any)
restore
ArgumentTypeDescription
backup?any
databaseId?any
encryptionConfig?any
tags?any

Resources

state(infinite)— A Cloud Firestore Database.
@swamp/gcp/firestore/databases-backupschedulesv2026.05.25.2databases_backupschedules.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
dailyRecurrence?objectRepresents a recurring schedule that runs every day. The time zone is UTC.
retention?stringAt what relative time in the future, compared to its creation time, the backup should be deleted, e.g. keep backups for 7 days. The maximum supported retention period is 14 weeks.
weeklyRecurrence?objectRepresents a recurring schedule that runs on a specified day of the week. The time zone is UTC.
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn create()
Create a backupSchedules
fn get(identifier: string)
Get a backupSchedules
ArgumentTypeDescription
identifierstringThe name of the backupSchedules
fn update()
Update backupSchedules attributes
fn delete(identifier: string)
Delete the backupSchedules
ArgumentTypeDescription
identifierstringThe name of the backupSchedules
fn sync()
Sync backupSchedules state from GCP
fn list(maxPages?: number)
List backupSchedules resources
ArgumentTypeDescription
maxPages?numberMaximum number of pages to fetch (default: 10)

Resources

state(infinite)— A backup schedule for a Cloud Firestore Database. This resource is owned by t...
@swamp/gcp/firestore/databases-collectiongroups-fieldsv2026.06.03.1databases_collectiongroups_fields.ts

Global Arguments

ArgumentTypeDescription
indexConfig?objectThe index configuration for this field.
name?stringRequired. A field name of the form: `projects/{project_id}/databases/{database_id}/collectionGroups/{collection_id}/fields/{field_path}` A field path can be a simple field name, e.g. `address` or a path to fields within `map_value`, e.g. `address.city`, or a special field path. The only valid special field is `*`, which represents any field. Field paths can be quoted using `` ` `` (backtick). The only character that must be escaped within a quoted field path is the backtick character itself, esc
ttlConfig?objectThe TTL (time-to-live) configuration for documents that have this `Field` set. A timestamp stored in a TTL-enabled field will be used to determine the expiration time of the document. The expiration time is the sum of the timestamp value and the `expiration_offset`. For Enterprise edition databases, the timestamp value may alternatively be stored in an array value in the TTL-enabled field. An expiration time in the past indicates that the document is eligible for immediate expiration. Using any
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn get(identifier: string)
Get a fields
ArgumentTypeDescription
identifierstringThe name of the fields
fn update()
Update fields attributes
fn sync()
Sync fields state from GCP
fn list(filter?: string, pageSize?: number, maxPages?: number)
List fields resources
ArgumentTypeDescription
filter?stringThe filter to apply to list results. Currently, FirestoreAdmin.ListFields only supports listing fields that have been explicitly overridden. To issue this query, call FirestoreAdmin.ListFields with a filter that includes `indexConfig.usesAncestorConfig:false` or `ttlConfig:*`.
pageSize?numberThe number of results to return.
maxPages?numberMaximum number of pages to fetch (default: 10)

Resources

state(infinite)— Represents a single field in the database. Fields are grouped by their "Colle...
@swamp/gcp/firestore/databases-collectiongroups-indexesv2026.06.03.1databases_collectiongroups_indexes.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
apiScope?enumThe API scope supported by this index.
density?enumImmutable. The density configuration of the index.
fields?arrayThe fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this wil
multikey?booleanOptional. Whether the index is multikey. By default, the index is not multikey. For non-multikey indexes, none of the paths in the index definition reach or traverse an array, except via an explicit array index. For multikey indexes, at most one of the paths in the index definition reach or traverse an array, except via an explicit array index. Violations will result in errors. Note this field only applies to index with MONGODB_COMPATIBLE_API ApiScope.
queryScope?enumIndexes with a collection query scope specified allow queries against a collection that is the child of a specific document, specified at query time, and that has the same collection ID. Indexes with a collection group query scope specified allow queries against all collections descended from a specific document, specified at query time, and that have the same collection ID as this index.
searchIndexOptions?objectOptions for search indexes at the definition level.
shardCount?numberOptional. The number of shards for the index.
unique?booleanOptional. Whether it is an unique index. Unique index ensures all values for the indexed field(s) are unique across documents.
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn create(waitForReady?: boolean)
Create a indexes
ArgumentTypeDescription
waitForReady?booleanWait for the resource to reach a ready state after creation (default: true)
fn get(identifier: string)
Get a indexes
ArgumentTypeDescription
identifierstringThe name of the indexes
fn delete(identifier: string)
Delete the indexes
ArgumentTypeDescription
identifierstringThe name of the indexes
fn sync()
Sync indexes state from GCP
fn list(filter?: string, pageSize?: number, maxPages?: number)
List indexes resources
ArgumentTypeDescription
filter?stringThe filter to apply to list results.
pageSize?numberThe number of results to return.
maxPages?numberMaximum number of pages to fetch (default: 10)

Resources

state(infinite)— Cloud Firestore indexes enable simple and complex queries against documents i...
@swamp/gcp/firestore/databases-documentsv2026.05.27.1databases_documents.ts

Global Arguments

ArgumentTypeDescription
createTime?stringOutput only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
fields?recordThe document\
name?stringThe resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
updateTime?stringOutput only. The time at which the document was last changed. This value is initially set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn get(identifier: string)
Get a documents
ArgumentTypeDescription
identifierstringThe name of the documents
fn update()
Update documents attributes
fn delete(identifier: string)
Delete the documents
ArgumentTypeDescription
identifierstringThe name of the documents
fn sync()
Sync documents state from GCP
fn list(mask_fieldPaths?: string, orderBy?: string, pageSize?: number, readTime?: string, showMissing?: boolean, transaction?: string, maxPages?: number)
List documents resources
ArgumentTypeDescription
mask_fieldPaths?stringThe list of field paths in the mask. See Document.fields for a field path syntax reference.
orderBy?stringOptional. The optional ordering of the documents to return. For example: `priority desc, __name__ desc`. This mirrors the `ORDER BY` used in Firestore queries but in a string representation. When absent, documents are ordered based on `__name__ ASC`.
pageSize?numberOptional. The maximum number of documents to return in a single response. Firestore may return fewer than this value.
readTime?stringPerform the read at the provided time. This must be a microsecond precision timestamp within the past one hour, or if Point-in-Time Recovery is enabled, can additionally be a whole minute timestamp within the past 7 days.
showMissing?booleanIf the list should show missing documents. A document is missing if it does not exist, but there are sub-documents nested underneath it. When true, such missing documents will be returned with a key but will not have fields, `create_time`, or `update_time` set. Requests with `show_missing` may not specify `where` or `order_by`.
transaction?stringPerform the read as part of an already active transaction.
maxPages?numberMaximum number of pages to fetch (default: 10)
fn batch_get(documents?: any, mask?: any, newTransaction?: any, readTime?: any, transaction?: any)
batch get
ArgumentTypeDescription
documents?any
mask?any
newTransaction?any
readTime?any
transaction?any
fn batch_write(labels?: any, writes?: any)
batch write
ArgumentTypeDescription
labels?any
writes?any
fn begin_transaction(options?: any)
begin transaction
ArgumentTypeDescription
options?any
fn commit(transaction?: any, writes?: any)
commit
ArgumentTypeDescription
transaction?any
writes?any
fn create_document(createTime?: any, fields?: any, name?: any, updateTime?: any)
create document
ArgumentTypeDescription
createTime?any
fields?any
name?any
updateTime?any
fn execute_pipeline(newTransaction?: any, readTime?: any, structuredPipeline?: any, transaction?: any)
execute pipeline
ArgumentTypeDescription
newTransaction?any
readTime?any
structuredPipeline?any
transaction?any
fn list_collection_ids(pageSize?: any, pageToken?: any, readTime?: any)
list collection ids
ArgumentTypeDescription
pageSize?any
pageToken?any
readTime?any
fn list_documents()
list documents
fn listen(addTarget?: any, labels?: any, removeTarget?: any)
listen
ArgumentTypeDescription
addTarget?any
labels?any
removeTarget?any
fn partition_query(pageSize?: any, pageToken?: any, partitionCount?: any, readTime?: any, structuredQuery?: any)
partition query
ArgumentTypeDescription
pageSize?any
pageToken?any
partitionCount?any
readTime?any
structuredQuery?any
fn rollback(transaction?: any)
rollback
ArgumentTypeDescription
transaction?any
fn run_aggregation_query(explainOptions?: any, newTransaction?: any, readTime?: any, structuredAggregationQuery?: any, transaction?: any)
run aggregation query
ArgumentTypeDescription
explainOptions?any
newTransaction?any
readTime?any
structuredAggregationQuery?any
transaction?any
fn run_query(explainOptions?: any, newTransaction?: any, readTime?: any, structuredQuery?: any, transaction?: any)
run query
ArgumentTypeDescription
explainOptions?any
newTransaction?any
readTime?any
structuredQuery?any
transaction?any
fn write(labels?: any, writes?: any)
write
ArgumentTypeDescription
labels?any
writes?any

Resources

state(infinite)— A Firestore document. Must not exceed 1 MiB - 4 bytes.
@swamp/gcp/firestore/databases-usercredsv2026.05.25.2databases_usercreds.ts

Global Arguments

ArgumentTypeDescription
name?stringIdentifier. The resource name of the UserCreds. Format: `projects/{project}/databases/{database}/userCreds/{user_creds}`
resourceIdentity?objectDescribes a Resource Identity principal.
userCredsId?stringRequired. The ID to use for the user creds, which will become the final component of the user creds's resource name. This value should be 4-63 characters. Valid characters are /a-z-/ with first character a letter and the last a letter or a number. Must not be UUID-like /[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}/.
location?stringThe location for this resource (e.g., 'us', 'us-central1', 'europe-west1')
fn create(waitForReady?: boolean)
Create a userCreds
ArgumentTypeDescription
waitForReady?booleanWait for the resource to reach a ready state after creation (default: true)
fn get(identifier: string)
Get a userCreds
ArgumentTypeDescription
identifierstringThe name of the userCreds
fn delete(identifier: string)
Delete the userCreds
ArgumentTypeDescription
identifierstringThe name of the userCreds
fn sync()
Sync userCreds state from GCP
fn list(maxPages?: number)
List userCreds resources
ArgumentTypeDescription
maxPages?numberMaximum number of pages to fetch (default: 10)
fn disable()
disable
fn enable()
enable
fn reset_password()
reset password

Resources

state(infinite)— A Cloud Firestore User Creds.
@swamp/gcp/firestore/locationsv2026.05.26.1locations.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
fn get(identifier: string)
Get a locations
ArgumentTypeDescription
identifierstringThe name of the locations
fn sync()
Sync locations state from GCP
fn list(extraLocationTypes?: string, filter?: string, pageSize?: number, maxPages?: number)
List locations resources
ArgumentTypeDescription
extraLocationTypes?stringOptional. Do not use this field unless explicitly documented otherwise. This is primarily for internal usage.
filter?stringA filter to narrow down results to a preferred subset. The filtering language accepts strings like `"displayName=tokyo"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160).
pageSize?numberThe maximum number of results to return. If not set, the service selects a default.
maxPages?numberMaximum number of pages to fetch (default: 10)

Resources

state(infinite)— A resource that represents a Google Cloud location.
04Previous Versions19
2026.05.27.1May 27, 2026
  • Updated: databases_documents
2026.05.26.1May 26, 2026
  • Updated: databases, databases_collectiongroups_fields, databases_collectiongroups_indexes, locations
2026.05.25.2May 25, 2026
  • Updated: databases_backupschedules, databases_usercreds

Modified 8 models

2026.05.24.1May 24, 2026
  • Updated: databases, databases_backupschedules, databases_collectiongroups_fields, databases_collectiongroups_indexes, databases_documents, databases_usercreds, locations, backups
2026.05.21.2May 21, 2026
  • Updated: databases, databases_backupschedules, databases_collectiongroups_fields, databases_collectiongroups_indexes, databases_documents, databases_usercreds, locations, backups
2026.05.21.1May 21, 2026
2026.05.20.1May 20, 2026
  • Updated: databases, databases_collectiongroups_fields, databases_collectiongroups_indexes
2026.05.19.2May 19, 2026
2026.05.19.1May 19, 2026
2026.05.18.2May 18, 2026
2026.05.14.1May 14, 2026
  • Updated: databases, databases_collectiongroups_fields, databases_collectiongroups_indexes
2026.05.09.1May 10, 2026
  • Updated: databases
2026.05.05.1May 5, 2026
  • Updated: databases
2026.05.04.1May 4, 2026
  • Updated: databases
2026.05.02.1May 2, 2026
  • Updated: databases
2026.04.23.1Apr 23, 2026
2026.04.09.1Apr 9, 2026
  • Updated: databases_collectiongroups_fields, databases_collectiongroups_indexes
2026.04.04.1Apr 4, 2026
  • Updated: databases_collectiongroups_fields, databases_collectiongroups_indexes, databases_documents
2026.04.03.3Apr 3, 2026
  • Updated: databases, databases_backupschedules, databases_collectiongroups_fields, databases_collectiongroups_indexes, databases_documents, databases_usercreds, locations, backups
05Stats
A
100 / 100
Downloads
0
Archive size
94.3 KB
Verified by Swamp
  • Has README or module doc2/2earned
  • README has a code example1/1earned
  • README is substantive1/1earned
  • Most symbols documented1/1earned
  • No slow types1/1earned
  • Dependencies pass trust audit2/2earned
  • Has description1/1earned
  • Platform support declared (or universal)2/2earned
  • License declared1/1earned
  • Verified public repository2/2earned
06Platforms
07Labels