Hanzo
OpenapiIngress

Creates or replaces one edge transform and hot-applies it. — POST /v1/ingress/middlewares

Creates or replaces one edge transform and hot-applies it.

POST /v1/ingress/middlewares

Addresshttps://api.hanzo.ai/v1/ingress/middlewares
MethodPOST
Operationpost_ingress_middlewares
AuthAuthorization: Bearer $HANZO_API_KEY

Creates or replaces one edge transform and hot-applies it. POST mints an id when the body omits one; PUT takes the id from the URL, which wins over any id in the body. type must be one of redirectScheme, stripPrefix, addPrefix or headers, and stripPrefix/addPrefix each require their config key.

Request

4 fields, body application/json (required).

FieldInTypeRequiredDescription
configbodyobjectConfig is the transform's parameters: redirectScheme takes scheme (default https) and permanent ("true" ⇒ 301, else 302); stripPrefix REQUIRES prefixes…
config.*bodystring
idbodystringID identifies the transform within the org: [A-Za-z0-9-_.], at most 128 chars.
typebodystringType is the transform: redirectScheme, stripPrefix, addPrefix or headers.

Response

StatusBodyMeaning
200Middlewareok

200 body — 4 fields.

FieldInTypeAlwaysDescription
configbodyobjectConfig is the transform's parameters: redirectScheme takes scheme (default https) and permanent ("true" ⇒ 301, else 302); stripPrefix REQUIRES prefixes…
config.*bodystring
idbodystringID identifies the transform within the org: [A-Za-z0-9-_.], at most 128 chars.
typebodystringType is the transform: redirectScheme, stripPrefix, addPrefix or headers.

Failure carries the platform error shape — see Errors.

Examples

hanzo ingress middlewares create

Ingress API · All Hanzo APIs · Interactive reference

How is this guide?

On this page