Skip to content
Patiphan Srichai edited this page Oct 20, 2021 · 14 revisions

Suchon's Site API documentation

documentation for Suchon's Site API

Contents

1. Overview

Suchon’s Site API is a JSON-based API. All requests are made to endpoints beginning:

https://suchonsite-server.herokuapp.com/

All requests must be secure, i.e. https, not http.

2. Resource

The API is RESTful and arranged around resources.
All requests must be made with an integration token. All requests must be made using https.

2.1 people information by date

retrieve the information of peoples appointment by date Return full list of people's information that have vaccination appointment in that day

The API endpoint exposes this list of people's information as a collection.
A request to fetch a list of people's information looks like this:

GET https://suchonsite-server.herokuapp.com/people/by_date/{{date}}

Example response:

{
    "_id": "617042a299a86369e7ba81f5",
    "date": "20-10-2021",
    "people": [
        {
            "reservation_id": 1,
            "register_timestamp": "2021-10-20T15:19:56.609000",
            "name": "Jean",
            "surname": "string",
            "birth_date": "2021-10-20",
            "citizen_id": "1234567890123",
            "occupation": "string",
            "address": "string",
            "priority": "2"
        },
        {
            "reservation_id": 2,
            "register_timestamp": "2021-10-20T15:25:16.576000",
            "name": "panida",
            "surname": "ounnaitham",
            "birth_date": "2000-11-02",
            "citizen_id": "1129901628994",
            "occupation": "student",
            "address": "nonthaburi",
            "priority": "2"
        },
        {
            "reservation_id": 3,
            "register_timestamp": "2021-10-20T15:25:16.576000",
            "name": "panida",
            "surname": "ounnaitham",
            "birth_date": "2000-11-02",
            "citizen_id": "1129901628994",
            "occupation": "student",
            "address": "nonthaburi",
            "priority": "2"
        }
    ],
    "__v": 0
}
Field Type Description
date
reservation_id
register_timestamp
name
surname
birth_date
citizen_id
occupation
address
priority

Clone this wiki locally