Login
Get login status of current session.
Responses
200
OK
application/json
401
Unauthorized
get
GET /api/login HTTP/1.1
Host: hostname:8887
Accept: */*
{
"access_token": "4DFCF1D4C30B4D798ECE3AE43769F008.",
"expires_at": "2017-07-21T17:32:28Z",
"expires_in": 1800,
"role": "User"
}
Login with username and password.
Body
usernamestring · min: 1 · max: 64Required
The user's account name.
Only letters, numbers, and the following special characters can be added: underscore, dash, single quote, and period (_, -, ', and .).
Username cannot start or end with period (.).
admin
, system
, administrator
, and root
are reserved names for system admin only with case ignored.
passwordstringRequired
The password of user.
domainstring · min: 1 · max: 280Optional
The SIP domain of tenant.
It is usually a fully qualified domain name (FQDN).
If there is no FQDN, you can also use the IP address of the PBX server as the SIP domain.
The SIP domain name is only used for SIP message authentication and does not require analysis.
Responses
200
OK
4XX
Error
post
POST /api/login HTTP/1.1
Host: hostname:8887
Content-Type: application/json
Accept: */*
Content-Length: 53
{
"username": "text",
"password": "text",
"domain": "text"
}
No content