Put an existing service on dvmkit
You already run an API or an MCP server. How to sell it to agents per job, what you write, where it runs, and what stays the same.
If you already run an API or an MCP server, you don't rebuild it to sell it on dvmkit. You write a small DVM in front of it: a handler that takes the caller's input, calls your service, and returns the result. The SDK handles the quote, payment, job messages, and receipt. Your service, its users, and its keys stay as they are.
What you write
The handler is one file. This one sells a single call to an API you already run:
import { configureDVM } from "@dvmkit/sdk";
export default configureDVM({
name: "summarize",
description: "Summarize a public web page in five bullet points",
capability: "summarize",
tags: ["text"],
price: "$0.02",
async onJob(ctx) {
const url = typeof ctx.input === "string" ? ctx.input.trim() : "";
if (!url.startsWith("https://")) {
ctx.fail("Input must be an https URL");
return;
}
const response = await ctx.fetch("https://api.example.com/v1/summarize", {
method: "POST",
headers: {
authorization: `Bearer ${process.env.EXAMPLE_API_KEY}`,
"content-type": "application/json",
},
body: JSON.stringify({ url }),
});
if (!response.ok) {
ctx.fail(`Upstream returned ${response.status.toString()}`);
return;
}
ctx.complete(await response.text());
},
});Your API key stays on the DVM server. The caller, the agent paying to use your service, sees the capability's name, input, and price, pays per job, and gets a signed receipt. What happens to the caller's money when a job fails depends on how they paid, as Payments explains, so fail early on input you can't serve, before you spend anything upstream.
Your upstream call can cost you money even when the job fails. Capabilities covers pricing for that. Durable steps reuse a saved API result when a handler replays; use an upstream idempotency key where a repeat would cost you, because a step can still run more than once.
If the price depends on the input, quote it before the job starts with onQuote. If the work can need more money halfway through, ask for it with mid-job payment. Those two are what a plain per-request paywall can't do.
If you run an MCP server
Keep it. A DVM doesn't replace your MCP server or change how its current users connect. Each tool you want to sell to agents becomes a capability, and its handler calls the same backend your tool calls. Agents that use the dvm CLI then find, price, and pay for it per job with no account and no API key from you.
Start with the one tool people would pay for per call, not the whole server.
Where it runs
| Option | You run | You pay | Listed on /explore |
|---|---|---|---|
| dvmkit Cloud | Your existing backend; dvmctl deploy builds and runs the DVM container, with Postgres | Builder plan, $19 a month, $10 of hosting credit included each month. First DVM free for up to 30 days or until its $10 trial hosting credit runs out; places are limited | Yes, when deployed and publicly visible |
| Connect | The DVM process on your own server or GPU box; our router fronts it | $99 a month, no compute from us | Yes, when deployed and publicly visible |
| Self-host | Everything: compute, database, TLS, payment workers | Nothing to dvmkit | No. External registration can make it discoverable through the agent CLI instead |
On every option dvmkit takes 0% of what callers pay you. Pricing has the hosting rates; Deploying says what each option leaves to you.
Keep your API key out of the code. On Cloud, pass it at deploy time with dvmctl deploy --env-stdin (reference).
Start
Give your coding agent the builder quickstart and one sentence about the service: "Wrap our /v1/summarize endpoint as a DVM that charges $0.02 a call." Use the build-dvm skill to implement the wrapper and test a paid call locally before deploying.