Skip to content

Authentication

Levno authenticates REST API requests with an API key tied to a Levno partner and a nominated Levno for Partners user.

Send the key in the API-KEY header on every request:

GET /api/partner/public/v1/auth/me HTTP/1.1
Host: api.milk.levno.com
API-KEY: your-api-key
Accept: application/json

Call GET /auth/me to check that the key is valid and that its user can access the partner account.

Terminal window
curl --fail-with-body \
--header "API-KEY: $LEVNO_API_KEY" \
--header "Accept: application/json" \
"https://api.milk.levno.com/api/partner/public/v1/auth/me"

The API returns 401 Unauthorized if the key is missing, invalid, or no longer has access.

See the ApiKeyAuth scheme in the Milk reference or Fuel reference for the generated contract view.