Overview

The McKube API can be used to manage various items in McKube. It can be considered REST-ish, speaks in JSON, and requires valid authentication for all endpoints.

It exposes an OpenAPI/Swagger definition for open consumption by any and all consumers:

Authentication

To authenticate against the API, you will need an API key. These can either be created through the McKube web app or through the API using an existing key.

The API key must then be used as a bearer token in the Authorization header for all calls:

curl -H "Authorization: Bearer [YOUR_TOKEN]" https://api.mckube.dev/account

Errors

The API returns all errors in the format dictated by the application/problem+json standard, along with an appropriate HTTP status code.

  • 2xx codes indicate success

  • 4xx codes indicate an invalid or unresolvable request

  • 5xx codes indicate an error with McKube internally

All errors will include at least the following fields:

{
    "detail": "A message with some detail about the problem",
    "status": 400,
    "title": "A short summary, usually the standard HTTP reason phrase"
}

Last updated

Was this helpful?