Skip to main content
The hiddenlayer-apim CLI reads configuration from environment variables or a .env file.

Create a Configuration File

Run:
This creates .env in the current directory. If .env already exists, the command stops instead of overwriting it. Use hiddenlayer-apim init --force only when you intentionally want to replace the file.

Required Settings

Optional Settings

Region Configuration

For US SaaS, use:
For EU SaaS, use:
The APIM fragments build authentication and API URLs from this value:
  • https://auth.<HL_HOST>/oauth2/token
  • https://api.<HL_HOST>/detection/...

HiddenLayer Metadata Headers

The v2 packages can consume these request headers from clients or upstream APIM policy and then remove them before calling the backend: APIM also generates or forwards HL-Roundtrip-Id so request and response evaluations for the same LLM call can be linked.