API Documentation V1
Public API documentation Version 1.
Last updated
Public API documentation Version 1.
Last updated
Making the requests described here exposes the system you are connecting to, so credentials and tokens must be stored securely.
POST
https://api.ohmautomation.io/control/v1/auth
This endpoint allows you to obtain the session token required to make all other requests.
Headers
Name | Type | Description |
---|---|---|
Request Body
Name | Type | Description |
---|---|---|
POST
https://api.ohmautomation.io/control/v1/logout
This endpoint allows you to delete the session, making the token unusable.
Headers
GET
https://api.ohmautomation.io/control/v1/shortcuts?token=abc
This endpoint retrieves a JSON with the user’s shortcut configuration corresponding to the token.
Query Parameters
It is possible to avoid using the token in the URL by attaching it to the Headers.
GET
https://api.ohmautomation.io/control/v1/shortcuts
As with the previous method, this also retrieves a JSON with the shortcut configuration, but the token is indicated in the Headers. We recommend this approach since it doesn't expose the token in the URL.
Headers
POST
https://api.ohmautomation.io/control/v1/shortcut
Headers
Request Body
GET
https://api.ohmautomation.io/control/v1/shortcut?token=abc&link=0&lang=it
This endpoint allows viewing and executing a shortcut.
Query Parameters
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Content-Type
string
application/json
username*
string
Username
password*
string
User password
X-Session-Token*
string
Session token to be deleted
token*
string
Session token
Content-Type
string
application/json
X-Session-Token*
string
Session token
Content-Type
string
application/json
X-Session-Token*
string
Session token
id*
string
Shortcut ID
command*
string
run
token*
string
Session token
id*
string
Shortcut ID
lang
string
Display language (en
by default)