Skip to main content

Webhooks - Firestore

Firestore webhooks allows you to send data from the DrapCode database to the Firebase cloud.


Steps to Send Data through Webhook Using Firestore

DrapCode Builder Firestore
  • Step 2: Click the Create a Project button and follow three steps procedure to create a project as shown below:
DrapCode Builder Firestore
  • Step 3: Once you've created the project, you will land on the project dashboard. Click on the setting icon and go to project settings.
DrapCode Builder Firestore
  • Step 4: Scroll down to that page and you will see your apps. If you don’t have any app then create one by clicking on the Html icon.
DrapCode Builder Firestore
  • Step 5: Add app name and click the Register App button to create your app. While creating the app you will get the required key for Firestore, copy it and click the Continue to Console button.

In case you missed copying from there, the same you can get on your apps on the same project setting page.

DrapCode Builder Firestore
  • Step 6: In the sidebar, click on Build and choose Firestore Database from the dropdown list.DrapCode Builder Firestore

  • Step 7: Click on the Create Database button, then either choose Start in production mode or Start in test mode option to create a database. In the example below, Start in test mode is chosen to show a demo.

Then, select the Cloud Firestore location and click Enable. You will land on the Cloud Firestore database.

DrapCode Builder Firestore
  • Step 8: In the Cloud Firestore database page, click Start collection. Add a collection name in the Collection ID field and click Next. Then, click the Auto ID button to generate Document ID and click the Save button.

    Note: No need to add a field name, as you will be sending data from your DrapCode web app.

DrapCode Builder Firestore
  • Step 9: Go to the builder and create a collection.
DrapCode Builder Firestore
  • Step 10: Open Webhooks by clicking the settings icon in the bottom toolbar of the builder and click the Create button. Fill the required fields and save.

  • Step 11: Create an event for webhooks by opening the events panel. add event name and select Send Data to External API under Collections category as the event action. Choose the webhook previously created.
DrapCode Builder Firestore
  • Step 12: Bind the collection and the event created to a collection form.
DrapCode Builder Firestore