Firebase Firestore icon

Firebase Firestore

Manage documents in Google Cloud Firestore

Overview

This node allows you to manage documents in Google Cloud Firestore, a NoSQL document database. Specifically, the Delete operation deletes a document at a specified path within your Firestore database.

Common scenarios for this node include:

  • Removing outdated or irrelevant documents from your Firestore collections.
  • Cleaning up data after certain workflows complete.
  • Automating deletion of user-generated content or logs based on workflow logic.

For example, if you have a collection named users and want to delete a specific user document by ID, you can specify the path as users/{userId} and run this node to remove that document.

Properties

Name Meaning
Path The path to the Firestore document to delete. This should be the full path including collection and document ID, e.g., collectionName/documentId.

Output

The output is a JSON array containing one object per input item processed. For the Delete operation, each output object has the following structure:

{
  "success": true,
  "operation": "delete",
  "path": "collectionName/documentId"
}
  • success: Indicates whether the deletion was successful (true).
  • operation: The operation performed, here always "delete".
  • path: The Firestore document path that was deleted.

No binary data is output by this node.

Dependencies

  • Requires a valid API key credential with access to Google Cloud Firestore.
  • The node uses the Firebase Admin SDK internally to connect and authenticate with Firestore.
  • You must configure the node with a service account JSON credential that has permissions to delete documents in your Firestore project.

Troubleshooting

  • Invalid Path: If the provided path does not point to an existing document, the node may throw an error or report failure. Ensure the path is correct and includes both collection and document ID.
  • Permission Denied: If the service account lacks delete permissions, the node will fail. Verify that the service account has appropriate Firestore roles.
  • Malformed Credential JSON: If the service account JSON is invalid or incorrectly formatted, the node will throw an error during initialization.
  • General Firestore Errors: Any other Firestore-related errors are caught and rethrown with a message prefixed by Firestore Error: to help identify issues.

Links and References

Discussion