การยืนยันตัวตน Account ของ มธ.

POST Authentication


Rate Limits


API Call
1,000 requests per hour per user/key

Request headers: Application-Key


Header HTTP request
Content-Type application/json
Application-Key Access token

Request Body


Property Type Value
UserName String Username create by admin thammasat
PassWord String Password create by admin thammasat

{"UserName" : "username","PassWord" : "password"}

Example Response


Example response (Student)


Property Type Value
status boolean true or false status
message string Message response
displayname_th string Display name Thai
displayname_en string Display name Eng
email string Email Thammasat
type string employee or student
department string Department name
faculty string Faculty from Thammasat

Example response (Employee)


Property Type Value
status boolean true or false status
message string Message response
displayname_th string Display name Thai
displayname_en string Display name Eng
email string Email Thammasat
type string employee or student
department string Department name
organization string Company from Thammasat

{
    "status": true,
    "message": "Success",
    "displayname_th": "ชื่อ นามสกุล",
    "displayname_en": "firstname  lastname",
    "email": "email@tu.ac.th",
    "type": "employee",
    "department": "งานวิเคราะห์และพัฒนาระบบ",
    "organization": "สำนักงานศูนย์เทคโนโลยีสารสนเทศและการสื่อสาร"
}

Status Codes


Codes Description
200 OK Success
400 Bad Request Problem with the request
401 Unauthorized Valid channel access token is not specified
403 Forbidden Not authorized to access the resource. Confirm that your account or plan is authorized to access the resource.

Status Message


Codes Status Message Description
200 OK TRUE Success Authorization Success
400 Bad Request FALSE Request body using a POST operation (HTTP method)!
400 Bad Request FALSE Body no data! Request body {user / pass}
403 Forbidden FALSE Application-Key Invalid!
401 Unauthorized FALSE Application-Key header required. Must follow the scheme, "Application-Key: ACCESS TOKEN"


Let's Go