# Firestore API load

**URL:** <https://talk.observablehq.com/t/firestore-api-load/2199>\
**Category:** Help\
**Created:** [July 24, 2019, 10:54am UTC](https://talk.observablehq.com/t/firestore-api-load/2199 "2019-07-24T10:54:37Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![rezpe](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/rezpe/32/1422_2.png) [@rezpe](https://talk.observablehq.com/u/rezpe)\
**Post date:** [July 24, 2019, 10:54am UTC](https://talk.observablehq.com/t/firestore-api-load/2199/1 "2019-07-24T10:54:37Z")

</div>

Hi,

I would like to use the firebase firestore database directly from an observable notebook. I have been looking notebooks but I see nothing to inspire myself.  
The libs for firebase web are:  
[https://www.gstatic.com/firebasejs/6.3.1/firebase-app.js](https://www.gstatic.com/firebasejs/6.3.1/firebase-app.js)  
[https://www.gstatic.com/firebasejs/6.3.1/firebase-firestore.js](https://www.gstatic.com/firebasejs/6.3.1/firebase-firestore.js)

I would like to execute a simple example like:  
firebase.initializeApp(firebaseConfig);  
var db = firebase.firestore();  
db.collection(“cities”).doc(“LA”).set({  
name: “Los Angeles”,  
state: “CA”,  
country: “USA”  
})

I have tried the import module debugger, but its solution does not work for me. Have anyone trying to do this and succeed ?

Thanks,  
Sebas

---

<div class="post-metadata">

**Author:** ![mbostock](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/mbostock/32/9_2.png) [@mbostock](https://talk.observablehq.com/u/mbostock)\
**Post date:** [July 24, 2019, 2:29pm UTC](https://talk.observablehq.com/t/firestore-api-load/2199/2 "2019-07-24T14:29:29Z")

</div>

This seems to work, but I don’t have a Firebase instance to test against to verify:

> **[Hello, Firebase](https://observablehq.com/@mbostock/hello-firebase)**
>
> An Observable notebook by Mike Bostock.

---

<div class="post-metadata">

**Author:** ![rezpe](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/rezpe/32/1422_2.png) [@rezpe](https://talk.observablehq.com/u/rezpe)\
**Post date:** [July 26, 2019, 10:44pm UTC](https://talk.observablehq.com/t/firestore-api-load/2199/3 "2019-07-26T22:44:48Z")

</div>

It works !!! I will publish the notebook with a complete example !!

---

<div class="post-metadata">

**Author:** ![solovevserg](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/solovevserg/32/4031_2.png) [@solovevserg](https://talk.observablehq.com/u/solovevserg)\
**Post date:** [December 16, 2020, 10:41pm UTC](https://talk.observablehq.com/t/firestore-api-load/2199/4 "2020-12-16T22:41:00Z")

</div>

Yeah, thank you so much!  
I’ll use this integration for teaching social data analysis students in Moscow, Russia

---

<div class="post-metadata">

**Author:** ![triptych](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/triptych/32/4001_2.png) [@triptych](https://talk.observablehq.com/u/triptych)\
**Post date:** [December 22, 2020, 2:46am UTC](https://talk.observablehq.com/t/firestore-api-load/2199/5 "2020-12-22T02:46:30Z")

</div>

Can you please link to the notebook?
