Cernion Authentication API
OIDC/SAML session bootstrap and verification
OIDC/SAML session bootstrap and verification
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/cernion-de:cernion-de-authentication-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Cernion Energy Tools Authentication API
version: 0.99.22
description: 'MicroService Agent System for Energy Markets - REST API with AI integration.
CERNION_TOKEN: request at https://cernion.de/ or by email: dev@stromdao.com.
For the public instance at https://api.cernion.de/, create your token at https://cernion.de/cet-token/.'
servers:
- url: https://api.cernion.de
description: API Server
tags:
- name: Authentication
description: OIDC/SAML session bootstrap and verification
paths:
/api/auth/oidc/login:
get:
summary: Start OIDC login (foundation)
tags:
- Authentication
operationId: auth_oidcLogin
parameters:
- name: state
in: query
schema:
type: string
example: state-123
- name: nonce
in: query
schema:
type: string
example: nonce-123
- name: scope
in: query
schema:
type: string
example: openid profile email groups
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
/api/auth/oidc/callback:
get:
summary: OIDC callback (foundation mode — disabled by default)
tags:
- Authentication
operationId: auth_oidcCallback
parameters:
- name: code
in: query
schema:
type: string
example: oidc-code-abc
- name: state
in: query
schema:
type: string
example: state-123
- name: claims
in: query
schema:
type: string
description: Foundation mode claim payload as JSON string.
example: '{"sub":"user-1","groups":["cernion-approver"]}'
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
description: ⚠️ Builds a session directly from the caller-supplied `claims` payload — no authorization-code exchange, no ID-token signature validation. This is a full authentication bypass if reachable with a real OIDC provider configured, so it is disabled unless `AUTH_FOUNDATION_MODE=true` is explicitly set (local development/demos only). Returns 501 otherwise.
/api/auth/saml/acs:
post:
summary: SAML ACS callback (foundation mode — disabled by default)
tags:
- Authentication
operationId: auth_samlAcs
parameters:
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
description: ⚠️ Builds a session directly from the caller-supplied `payload` — no SAML assertion signature validation against `settings.saml.cert`. This is a full authentication bypass if reachable with a real SAML IdP configured, so it is disabled unless `AUTH_FOUNDATION_MODE=true` is explicitly set (local development/demos only). Returns 501 otherwise.
requestBody:
required: false
content:
application/json:
schema:
type: object
properties:
payload:
type: object
example:
nameID: user@example.com
token:
type: string
description: Optional Cernion MCP token for this request. Overrides CERNION_TOKEN when provided.
examples:
default:
value:
payload:
nameID: user@example.com
groups:
- cernion-approver
/api/auth/refresh:
post:
summary: Refresh csess_ session
tags:
- Authentication
operationId: auth_refresh
parameters:
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
requestBody:
required: false
content:
application/json:
schema:
type: object
properties:
token:
type: string
example: csess_...
examples:
default:
value:
token: csess_demo_token
/api/auth/logout:
post:
summary: Logout csess_ session
tags:
- Authentication
operationId: auth_logout
parameters:
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
requestBody:
required: false
content:
application/json:
schema:
type: object
properties:
token:
type: string
example: csess_...
examples:
default:
value:
token: csess_demo_token
/api/auth/verify:
post:
summary: Verify csess_ session
tags:
- Authentication
operationId: auth_verify
parameters:
- $ref: '#/components/parameters/TokenQuery'
responses:
'200':
description: Successful response
content:
application/json:
schema:
type: object
requestBody:
required: false
content:
application/json:
schema:
type: object
properties:
token:
type: string
example: csess_...
trackUsage:
type: boolean
default: false
examples:
default:
value:
token: csess_demo_token
trackUsage: true
components:
parameters:
TokenQuery:
name: token
in: query
required: false
schema:
type: string
description: Optional Cernion MCP token as URL query parameter. If provided, it overrides CERNION_TOKEN for this request. Prefer Authorization Bearer header in production to reduce token exposure in URLs/logs.
securitySchemes:
ApiKeyAuth:
type: apiKey
in: header
name: X-API-Key
BearerAuth:
type: http
scheme: bearer
bearerFormat: JWT
description: 'Optional Cernion MCP token. If not provided, falls back to CERNION_TOKEN from environment. Request token at https://cernion.de/ or by email: dev@stromdao.com.'