Imagine if we can go further by creating a genuine base organizing the data of Google Contacts.
JSON is the language we will use to make a link between Webhook and Google Contacts. We are going to explain how to convert a JSON format into a Javascript object. Let's try an example to see how we can use JSON language.
Matt is 35 years old and he is your bestfriend since highschool.
On Goole Contacts, his profile will explicit:
The Json database is organised this way:
[{name:..., age:...., phone number:...,email adress:....},...{...}]
We can use this for all contacts that we have.
Here are four variables (name/age/phone number/email adress) and then finally we are using
"$.get()" to make our request. Here is an accurate JSON program:
var myJSON='{"name":"Matt","age":35,"telephone number":"0652950052","email adresse":"matt.lowe@gmail.com"}';
var myObj=JSON.parse(myJson);
document.getElementByld("demo").innerHTML=myObj.name;