Authentication
API Keys
Section titled “API Keys”Every endpoint except /api/json-escape requires a Bearer token in the Authorization header.
Authorization: Bearer sk_morso_...Example
Section titled “Example”curl -X POST https://morso.dev/api/hash \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{"algorithm": "sha256", "input": "hello world"}'Error Responses
Section titled “Error Responses”| Scenario | Status | Body |
|---|---|---|
Missing Authorization header | 401 Unauthorized | {"message": "missing api key"} |
| Invalid or revoked key | 401 Unauthorized | {"message": "invalid api key"} |
Managing Keys
Section titled “Managing Keys”Create and revoke keys from your Dashboard. Keys are prefixed with sk_morso_ and shown only once at creation — store them somewhere safe.
Unauthenticated Endpoint
Section titled “Unauthenticated Endpoint”/api/json-escape is free and requires no authentication.