A HTTP POST to /api/edge/auth.json
will create a session on the device, however this method is designed to be used internally (and is used internally by the login form), so it does not expose any session ID headers useful for validating login status but does pass it to the internal code.
A HTTP POST to https://host-or-ip/
with the username and password encoded as a simple application/x-www-form-urlencoded
form.
Name | Type | Values | Description |
---|---|---|---|
|
String |
String |
The username of a user. |
|
String |
String |
The password of a user. |
Name | Type | Values | Description |
---|---|---|---|
|
String |
A boolean encapsulated in a string (e.g. |
Whether the API request was successful. |
|
String |
An error message (e.g. |
The error that occurred while trying to process this authentication request. |
|
String |
|
A value that represents the role / privilege level of the authenticated user. |
|
String |
A number encapsulated in a string (e.g. |
Device uptime in seconds. |
|
String |
A boolean encapsulated in a string (e.g. |
Whether the device is running the factory default configuration. |
|
Object |
|
Contains information about the current device capabilities. |
Name | Type | Values | Description |
---|---|---|---|
|
String |
A model name (e.g. |
A string that represents a device model from |
|
Dictionary |
|
A dictionary that represents the device Power over Ethernet (PoE) capabilities. |
username=USERNAME&password=PASSWORD
{"success": "1", "level": "admin", "started": "1513", "default-config": "false", "platform": {"model": "ER-4", "poe_cap": {"eth0": "0", "eth1": "0", "eth2": "0", "eth3": "0", "eth4": "-1"}}}