Add an existing Sitejet API token.

This function adds an existing Sitejet API token to a cPanel user.

Note:

You can create a Sitejet API token with the Sitejet:create_account function.

SecurityBasicAuth
Request
query Parameters
api_token
required
string <hexadecimal>

The Sitejet API token to add.

Example: api_token=d35d8ea651007ccd25f96486cdcdXXXX
Responses
200

HTTP Request was successful.

Response Schema: application/json
apiversion
integer

The version of the API.

func
string

The name of the method called.

module
string

The name of the module called.

object
get/Sitejet/add_api_token
Request samples
uapi --output=jsonpretty \
  --user=username \
  Sitejet \
  add_api_token \
  api_token='d35d8ea651007ccd25f96486cdcdXXXX'
Response samples
application/json
{
  • "apiversion": 3,
  • "func": "add_api_token",
  • "module": "Sitejet",
  • "result": {
    • "data": { },
    • "errors": null,
    • "messages": null,
    • "metadata": {
      • "transformed": 1
      },
    • "status": 1,
    • "warnings": null
    }
}