List of APIs

Endpoints

Default endpoints: https://iot-api.chinhphucvn.com/api

For example, to call get user account API, url will be `http://iot-api.chinhphucvn.com/api/user`

Authorization

When calling the API, please include the headers with Authorization and App-Secret header.

Authorization: Bearer [Access Token]
App-Secret: [Your App Secret]

User

GET /user

Get current user information

{
    "status": true,
    "data": {
        "avatarUrl": "https://iot-socket.chinhphucvn.com/files/user_avatars/NhVlpGGMOrQgQbz92tpsjRp6ImJ2.jpg?t=1656356074.394",
        "created_at": 1565669029,
        "level": {
            "exp": 0,
            "level": 1
        },
        "lower_username": "clovers1254",
        "name": "Nguyễn Công Minh",
        "plan": 0,
        "publicInfo": {
            "birth-day": true,
            "birth-year": true,
            "school-province": true
        },
        "school": {
            "districtId": 706,
            "districtName": "Thành phố Bảo Lộc",
            "provinceId": 63,
            "provinceName": "Lâm Đồng",
            "schoolId": 29781,
            "schoolLevel": 3,
            "schoolName": "THPT Bảo Lộc"
        },
        "social": {
            "fbUrl": "https://www.facebook.com/congminhO18/",
            "webUrl": "https://github.com/congminh1254"
        },
        "talent": {
            "grade": 3,
            "point": 527,
            "rank": 0
        },
        "uid": "NhVlpGGMOrQgQbz92tpsjRp6ImJ2",
        "username": "clovers1254"
    }
}

Last updated

Was this helpful?