One Click Videos · Developers

Build an MCP adapter

A setup guide for connecting an MCP client to the existing REST API.

1. Choose the execution model

For personal development, a local adapter can read your JEMSU API key from its process environment. A shared remote server requires a separate authenticated account-linking design. Never embed one owner’s API key in a publicly shared server.

2. Define narrow tools

Use the OpenAPI contract for schemas. Start with credit balance and status lookup; add video creation only after validating the input and spending authorization.

3. Implement each handler

Tool you implement HTTP call Result
get_credits GET /api/v1/credits Available and used credits
create_video POST /api/v1/videos jobId and reserved credits
get_video_status GET /api/v1/videos/{jobId} Current state and result URL

4. Keep long-running work asynchronous

Return the job ID immediately. Use subsequent tool calls or a background worker to check completion. Persist jobs and avoid automatic POST retries.

5. Connect and test

Configure your MCP client using the command or deployed address of the adapter you actually run. Verify a credit lookup, test validation with local fixtures, then perform one authorized generation. Do not use https://jemsu.ai/mcp as the server address; it serves documentation only.

The protocol’s server guide describes the SDK and tool-registration process: Build an MCP server.

This guide does not install or operate an MCP server. The supported live service is the REST API at app.jemsu.ai/api/v1.