REST API

Almost all LiveConfig functions can be accessed via a REST API. REST APIs can be used quickly, easily and securely by all modern programming languages.

Prerequisites

The REST API can be used from LiveConfig 3.0 in all license variants. “Normal” users (end customers) can also use the API if the corresponding authorization is set in the hosting account.

Authentication

To access the API, you must first generate an API key. To do this, log in to LiveConfig and then click on User settings in the top right-hand corner. In the API box, you can create a corresponding key using the Create key button. It is strongly recommended that you only allow access for individual IP addresses.

In later versions, LiveConfig will support an asymmetric key for JWT (JSON Web Token) instead of the symmetric API key. You should therefore outsource the authentication for API access to a separate function if possible so that you can maintain it more easily later.

You must send the API key for all REST-API accesses via the HTTP header Authorization: Bearer <API-Key>.

Example

  • adding a domain example.org to the account web77 of customer c0002:

    curl 'https://<server>:8443/liveconfig/api/v1/customers/c0002/domains' \
      -X POST
      -H 'Authorization: Bearer <API-Key>' \
      -H 'Accept: application/json' -H 'Accept-Language: en' \
      -H 'Content-Type: application/json' \
      --data-raw '{
        "domain": "example.org",
        "account": "web77",
        "www": true,
        "web": { "enabled": true, "type": "webspace", "target": "/" },
        "mail": { "enabled": true, "dkim": true }
      }'
    

API methods

A complete documentation of all available API methods can be found

  • in LiveConfig under the User settings (API box, API documentation button)

  • in the knowledge base

You can also test the functions directly from the documentation using an API key.