API integration
POST http://www.example.com/customers HTTP/1.1
Host: example.com
Authorization: Bearer AbCdEf123456
Content-Type: application/json// JSON object
// Create new employee
POST http://www.example.com/employees
{
"employee":
{
"id": 1,
"name": "John Smith",
"age": 35,
"hiredatetime": "2001-10-28T16:40:51.616Z",
"permanent": true,
"location": "South Africa"
}
}
// JSON array
// Create multiple employees at once
POST http://www.example.com/employees
{
"employees":
[
{
"id": 1,
"name": "John Smith",,
"age": 35,
"hiredatetime": "2001-10-28T16:40:51.616Z",
"permanent": true,
"location": "South Africa"
},
{
"id": 2,
"name": "Kim Anderson",
"age": 28,
"hiredatetime": "2001-10-28T16:40:51.616Z",
"permanent": true,
"location": "South Africa"
},
{
"id": 3,
"name": "Sarah Jones",
"age": 31,
"hiredatetime": "2001-10-28T16:40:51.616Z",
"permanent": true,
"location": "South Africa"
}
]
}Last updated