Skip to main content
The mogenius REST API allows you to manage your mogenius workspaces and resources in scripts, automations, and third party tools.

Authentication

The mogenius REST API authenticates every request with a Bearer token in the Authorization header:
For scripts, automations, and third-party tools, use an API key — a stable token that starts with mo_pat:. (Interactive clients such as mocli and MCP clients sign in with OAuth and receive short-lived access tokens instead; for programmatic access an API key is the right choice.)

Creating an API key

An API key is always a personal key: it is tied to your user account and inherits your permissions. When you create it, you set its scope so the key is limited to exactly what the integration needs:
  • Scope — an organization, a cluster, or a workspace. The same personal key can be narrowed to a single cluster or workspace.
  • Role — a role from the pre-defined groups.
  • Name and expiration date — to identify and time-box the key.
Create and manage API keys in your mogenius profile settings, under API Keys. The requests below use a scoped key — YOUR_WORKSPACE_API_KEY or YOUR_CLUSTER_API_KEY — to match the level each endpoint requires.

Set Image

You can use the API to perform a set image for your deployments via the mogenius operator.

Helm Upgrade

You can use the API to perform a Helm upgrade on a Helm release via the mogenius operator. For this to work, the Helm repository must be installed on the cluster first. The variable REPO_NAME in the request below refers to this Helm repository. The Helm upgrade can be performed with an API key on workspace level, or cluster level.

Deploy a Blueprint

Blueprints are pre-configured Helm charts. Deploying one via the API is a two-step flow:
  1. Read the blueprint to get its chart coordinates and default values.
  2. Install that chart with the Helm install endpoint.
The target cluster is selected with the cluster-id header. Use a cluster-level API key (or a workspace-level key with editor permissions); installing requires editor/admin rights on the cluster.

1. List blueprints

Returns the catalog with each blueprint’s id, displayName, description, category, and tags.

2. Get a blueprint’s details

The response includes the blueprint’s Helm repository and chart (name and version) plus its default install target (namespace, release) and default values. Use these to build the install request.

3. Install the chart

Install the blueprint’s chart as a standard Helm release. For repository-based charts, the Helm repository must be added to the cluster first (the chart value has the form REPO_NAME/CHART_NAME).
For charts hosted in an OCI registry, use the OCI install endpoint instead:
Once installed, the blueprint becomes a standard Helm release that you can manage through the Helm upgrade endpoint or the Helm Charts interface.

Manage Ports & Hostnames

You can get, add, and delete ports and hostnames from deployments, just like from the UI. mogenius will automatically create or update the corresponding service and ingress resources. Here’s example requests with configuration options on each parameter. Make sure to remove the comments when copying the example.

GET Ports & Domains

Returns a JSON with all Service and Ingress configurations related to a Controller.

PATCH Ports & Domains

Adds or deletes Service and Ingress configurations.