Skip to main content

Claude Code implementation handoff

Reference the user and Expressly client manual and the interactive user API, then give Claude Code this instruction:

Implement Alwafi as Expressly's sole AI transport. Use https://alwafi-api.expressly.tools as ALWAFI_URL and read the current OpenAPI 3.1 contract before coding. Use public model aliases and Alwafi consumer tokens only. Implement discovery, connected calls, durable jobs, persisted idempotency, resumable SSE, polling recovery, authenticated artifacts, native usage, wallet settlement, and actionable HTTP errors. Do not call upstream providers directly and do not put credentials in URLs, source control, logs, fixtures, screenshots, or generated documentation.

Required implementation order

  1. Configuration and Keychain-backed consumer token.
  2. /v1/models, /v1/pricing, /v1/voices, and /v1/me/balance discovery.
  3. Connected chat, responses, embeddings, moderation, image, speech, and audio.
  4. Durable submit, job persistence, SSE replay, polling, cancellation, and artifact download.
  5. Native meter and settled-charge UI.
  6. Error-state mapping and recovery.
  7. Contract tests and restart/disconnection acceptance tests.

Completion gate

Do not report complete until every acceptance test in the user manual passes against Alwafi, and no production path calls OpenAI, ElevenLabs, DigitalOcean, or another AI provider directly.