PanelAPI
PanelAPI calls use the panelAPI primary function along with the call parameter. These API calls only apply to Linux (Panelless).
API Access Tokens
listTokens
This function will list all access tokens on the server.
More Info
Parameters
Parameter name |
Type |
Description |
Possible values |
Example |
filter |
String |
Filter generated access tokens by description, IP, or username. |
|
filter=Description |
Returns
Parameter name |
Type |
Description |
Possible values |
Example |
items |
List [] |
Returns a list of access token items. |
To view the parameters returned by this function, click on Token Object. |
|
total |
Integer |
The total number of access token items. |
|
|
Example Call JETAPI
jetbackup5api -F panelAPI -D "call=listTokens"
success: 1
message:
system:
version: 5.3.3
version_panel: 5.3.3
tier: EDGE
type: Linux
retry_ms: 0
disableui:
dr:
agreement_panel:
agreement:
licenseIssue:
data:
tokens:
0:
_id: 650a11a2b7a6c72020078ae2
created: 2023-09-19T21:24:50+00:00
last_access:
last_access_ip:
expiry:
description: My New Description
ip: 127.1.1.1
username: example2
1:
_id: 650a1b3ed69d9443ac1eec62
created: 2023-09-19T22:05:50+00:00
last_access:
last_access_ip:
expiry:
description: My Description
ip: 127.0.0.1
username: example
total: 2
Example Call HTTP
https://HOST_NAME:3035/?api=1&function=panelAPI&call=listTokens
- To view available listing parameters, please visit List Parameters.
- API List calls have a default limit of 100 items.
getToken
This function will get the Access Token details by Token ID.
More Info
Parameters
Parameter name |
Type |
Description |
Possible Values |
Example |
_id |
String |
REQUIRED The Token ID. |
|
_id=5f890a19e55cf262863522f2 |
Example Call JETAPI
jetbackup5api -F panelAPI -D "call=getToken&_id={$TOKEN_ID}"
success: 1
message:
system:
version: 5.3.3
version_panel: 5.3.3
tier: EDGE
type: Linux
retry_ms: 0
disableui:
dr:
agreement_panel:
agreement:
licenseIssue:
data:
_id: 650a11a2b7a6c72020078ae2
created: 2023-09-19T21:24:50+00:00
last_access:
last_access_ip:
expiry:
description: My New Description
ip: 127.1.1.1
username: example2
Example Call HTTP
https://HOST_NAME:3035/?api=1&function=panelAPI&call=getToken&_id={$TOKEN_ID}
manageToken
This function allows you to create/modify an API Access Token.
More Info
Parameters
Parameter name |
Type |
Description |
Possible Values |
Example |
_id |
String |
REQUIRED on action modify. The ID of the Token |
|
_id=5f890a19e55cf262863522f2 |
action |
String |
REQUIRED The action you want to perform. |
|
action=create |
description |
String |
REQUIRED on action create. The description for the access token. |
|
description=My Description |
ip |
Integer |
The IP address that the token can be used from. |
|
ip=127.0.0.1 |
username |
String |
The account name that the token can be used for. Can be root. |
|
username=account123 |
Example Call JETAPI
jetbackup5api -F panelAPI -D "call=manageToken&action=create&description=My Description&ip=127.0.0.1&username={$ACCOUNT_NAME}"
jetbackup5api -F panelAPI -D "call=manageToken&action=modify&_id={$TOKEN_ID}&description=My Description&ip=127.0.0.1&username={$ACCOUNT_NAME}"
success: 1
message: Access Token Created/Updated Successfully
system:
version: 5.3.3
version_panel: 5.3.3
tier: EDGE
type: Linux
retry_ms: 0
disableui:
dr:
agreement_panel:
agreement:
licenseIssue:
data:
_id: 650a11a2b7a6c72020078ae2
created: 2023-09-19T21:24:50+00:00
last_access:
last_access_ip:
expiry:
description: My Description
ip: 127.0.0.1
username: example
token: gsDmPhATP5B52W6XkTCjXwHrNRxkL5ku
Example Call HTTP
https://HOST_NAME:3035/?api=1&function=panelAPI&call=manageToken&action=create&description=My Description&ip=127.0.0.1&username={$ACCOUNT_NAME}
https://HOST_NAME:3035/?api=1&function=panelAPI&call=manageToken&action=modify&_id={$TOKEN_ID}&description=My Description&ip=127.0.0.1&username={$ACCOUNT_NAME}
deleteToken
This function allows you to delete an Access Token by ID.
More Info
Parameters
Parameter name |
Type |
Description |
Possible Values |
Example |
_id |
String |
REQUIRED The Token ID. |
|
_id=61d49d24857d996e6e4e5912 |
Example Call JETAPI
jetbackup5api -F panelAPI -D "call=deleteToken&_id={$TOKEN_ID}"
success: 1
message: Access Token Deleted Successfully
system:
version: 5.3.3
version_panel: 5.3.3
tier: EDGE
type: Linux
retry_ms: 0
disableui:
dr:
agreement_panel:
agreement:
licenseIssue:
data:
Example Call HTTP
https://HOST_NAME:3035/?api=1&function=panelAPI&call=deleteToken&_id={$TOKEN_ID}
General
createUserSession
This function will generate a one-time login URL for the specified user.
More Info
Parameters
Parameter name |
Type |
Description |
Possible Values |
Example |
user |
String |
REQUIRED The user name to generate a login URL for. |
|
user=account123 |
Example Call JETAPI
jetbackup5api -F panelAPI -D "call=createUserSession&user={$ACCOUNT_NAME}"
success: 1
message: User session created successfully
system:
version: 5.3.3
version_panel: 5.3.3
tier: EDGE
type: Linux
retry_ms: 0
disableui:
dr:
agreement_panel:
agreement:
licenseIssue:
data:
user: test
expires: 2023-09-21T17:52:16+00:00
url: https://test.com:3035/?token=E9aqF0atkHz4gtCKtBA9LyYTHlPU88fk-098f6bcd4621d373cade4e832627b4f6
Example Call HTTP
https://HOST_NAME:3035/?api=1&function=panelAPI&call=createUserSession&user={$ACCOUNT_NAME}
Parameter Dictionary
Token Object
Parameter name |
Type |
Description |
Possible Values |
Examples |
_id |
String |
The Token ID. |
|
61d49d24857d996e6e4e5912 |
created |
String |
The date/time the token was created. |
|
2022-01-04T19:16:52+00:00 |
last_access |
String |
The date/time the token was last accessed. |
|
2021-12-31T18:06:51+00:00 |
expiry |
String |
The expiration date set for the token. |
|
|
description |
String |
The description for the token for your internal use. |
|
My Access Token |
token |
String |
The API Access Token for authenticating remote API calls. |
|
Y27fBG91Mjq9rOooVTrcEB68ykksDirF |
ip |
Integer |
The IP the access token can be used from. |
|
ip=10.10.10.10 |
username |
String |
The account the access token can be used for. Can be root. |
|
account123 |