Update a document
Last updated
Last updated
This action allows you to edit/update document in a Firestore collection, by running a firebase-admin instance on Bubble's backend.
You still don't need to have the collection or "table schema" pre-determined. You can create any fields you'd like during document updates.
The ID of the document you want to update.
The name or ID of the collection the document you want to update is stored in.
For each key/value pair you define and provide a value on the Fields list, you must provide the same key, but with the type of the value, on the Field Types input. That allows the plugin to turn the texts being fed into the plugin into corresponding values on the JSON structure sent to Firestore.
If the number of Fields and Field Types don't match, the action will result in an error.
This action returns no values, as the update operation on firebase-admin returns no information about the updated document.
The same way as on the you must inform which fields you want to update, in JSON format. This input allows you to set as many fields as you want.
For each field you must specify the "key" and the "value" that will be stored on it. For instance, you might want to invert the value of the "done" field in a task on our , when the check icon is clicked. You'd need to define the "key" = "done" and the "value" = "true" or "false".
See the to see which types are currently supported by the plugin and how to define them.