[server]:8000/api/get_country?country_code=[country code]
Get all services with a country code
| Status | Response |
|---|---|
| 200 | application/json List of JSON objects |
JSON Response
[
{
"Ref":"REFER1",
"Centre":"Centre Name",
"Service":"Service Name",
"Country":"cn"
}
]Add service to database
[server]:8000/api/add_service
Content-Type: application/json
{
"Ref":"REFREF1",
"Centre":"Centre Name",
"Service":"Service Name",
"Country":"cn"
}| Status | Responses |
|---|---|
| 200 | |
| 400 | String output "cannot add duplicate service" "missing parameters from POST request" PDOException |
| 500 | "cannot connect to server" |
Edit service in database
[server]:8000/api/update_service
Content-Type: application/json
{
"Ref":"REFREF1",
"Centre":"Centre Name",
"Service":"Service Name",
"Country":"cn"
}| Status | Responses |
|---|---|
| 200 | |
| 400 | "missing parameters from POST request" |
| 500 | PDOException |