11.1. The JSON API for the Contact App
Previous11. Working with APIs and JSONNext11.2. App11: Getting All the Contact Names (getall endpoint)
Last updated
Last updated
{
"contacts": [
{
"name": "Alice Smith"
},
{
"name": "Bob Smith"
},
{
"name": "David B"
},
{
"name": "Alex C"
},
{
"name": "Mark W"
},
{
"name": "Bob P"
},
{
"name": "Adam F"
}
]
} {
"email": "[email protected]",
"name": "Alice Smith",
"phone": 9801234567
} {
"error": "Error: Contact Alice Smith not found!"
} {
"info": "Contact Alice Smith is deleted!"
} {
"error": "Error: Contact not found!"
} {
"info": "Contact created: Alice Smith, [email protected], 6781234567"
} {
"error": "Error: Contact Alice Smith already exists!"
}