HTTP server bootstrap (aiohttp app + middleware stack) #8

Open
opened 2026-08-03 16:55:28 -07:00 by kalmiya · 0 comments
Owner

Kanban ticket: t_1b3032aa
Board: hermes-anthropic-api


Task t_1b3032aa: HTTP server bootstrap (aiohttp app + middleware stack)
status: ready
assignee: -
workspace: scratch
max-retries: 2 (default)
created: 2026-08-03 16:53 by kalmiya

Body:
Bootstrap the aiohttp web.Application and middleware stack.

Reuse from api_server.py:

  • aiohttp CORS middleware (cors_middleware)
  • body_limit_middleware (default 10 MB, configurable)
  • security_headers_middleware
  • profile_prefix_middleware for /p/<profile>/... URL prefixing under gateway.multiplex_profiles.

Add: an Anthropic-shaped auth middleware (separate from the OpenAI one, but the same Bearer-token pattern).

Config keys under gateway.platforms.anthropic_api.extra:

  • host (default 127.0.0.1)
  • port (default 8643 to avoid collision with api_server's 8642)
  • api_key_env (default ANTHROPIC_API_KEY)
  • cors_origins
  • max_request_body_mb

Events (1):
[2026-08-03 16:53] created {'assignee': None, 'status': 'ready', 'parents': [], 'tenant': None, 'workspace_kind': 'scratch', 'workspace_path': None, 'branch_name': None, 'project_id': None, 'skills': None, 'goal_mode': None, 'model_override': None, 'provider_override': None}

**Kanban ticket:** `t_1b3032aa` **Board:** `hermes-anthropic-api` --- Task t_1b3032aa: HTTP server bootstrap (aiohttp app + middleware stack) status: ready assignee: - workspace: scratch max-retries: 2 (default) created: 2026-08-03 16:53 by kalmiya Body: Bootstrap the aiohttp web.Application and middleware stack. Reuse from api_server.py: - aiohttp CORS middleware (`cors_middleware`) - body_limit_middleware (default 10 MB, configurable) - security_headers_middleware - profile_prefix_middleware for `/p/<profile>/...` URL prefixing under `gateway.multiplex_profiles`. Add: an Anthropic-shaped auth middleware (separate from the OpenAI one, but the same Bearer-token pattern). Config keys under `gateway.platforms.anthropic_api.extra`: - `host` (default `127.0.0.1`) - `port` (default `8643` to avoid collision with api_server's 8642) - `api_key_env` (default `ANTHROPIC_API_KEY`) - `cors_origins` - `max_request_body_mb` Events (1): [2026-08-03 16:53] created {'assignee': None, 'status': 'ready', 'parents': [], 'tenant': None, 'workspace_kind': 'scratch', 'workspace_path': None, 'branch_name': None, 'project_id': None, 'skills': None, 'goal_mode': None, 'model_override': None, 'provider_override': None}
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
kalmiya/hermes-anthropic-api#8
No description provided.