Jadpo is experimental and not ready for production. These docs follow the compiler's main branch as of 29 Nov 2026. What's built · Install 0.6.0
jadpo

The backend language for agents to write and people to trust.

Jadpo is an experimental programming language for web backends. Routes, stored data, the rules for who may read and change it, and background jobs are all part of the language. Its compiler checks the whole app each time your coding agent changes it. The agent fixes its own mistakes, and is told to ask you about anything that changes who can see your data.

You ask your agent to show partners their details. It sends back their API key too.

main.jadpothe whole file
type PartnerName = Text {    max_length: 100}/// What the partners page shows of a partner.type PartnerProfile = Output {    name: PartnerName    partner_key: ApiKeyadded by your agent}
jadpo checkcheck failed: 1 error, 1 file

error PartnerProfile.partner_key holds an ApiKey

reason
An ApiKey is a secret value: it is never sent, logged, stored or shown. A response is written out, logged by proxies and kept by browsers, and a client never needs a secret back.
next
Remove partner_key, and send what the client needs instead, such as whether one is set (agent)
rule
type.secret_exposed

Real code, and real output from jadpo check, the command that runs the compiler's checks. The request to your agent is made up. Output marks a type that a route sends back. The error's next step ends in (agent): your agent can make this fix, so it does, before you see the change.

How it works

A Jadpo app compiles to a program for your own server, or to WebAssembly for Cloudflare Workers. It stores its data in PostgreSQL.

Learn Jadpo step by step

  1. Your agent writes the app in Jadpo.

    Routes, the database, access rules, background jobs and calls to other services are all Jadpo code, in one project.

  2. It runs jadpo check after each edit,

    the way it runs tests. The check reads every file together, so it sees how a change in one place affects the rest.

  3. Each error says who decides the fix.

    An error ends with a next step. That step ends in (agent) when your agent can make the fix, and in (human) when the choice is yours, such as who may see data. Your agent fixes its own errors before it hands you the change.

    You ask your agent to make articles shareable. It lets anyone call the route, though not everyone may read articles.

    jadpo check1 error

    error GET /articles/{article_id} lets anyone call it, but not everyone may read Article

    next
    Add Access.public to Article's read:, or remove authentication: RouteAuthentication.none from the route (human)
    rule
    policy.public_grant_missing

    Your call: should anyone on the internet be able to read articles?

    Real output from jadpo check, for the rule policy.public_grant_missing. The request is an example.

Steps 2 and 3 repeat until the check passes.

Agents usually follow (human), but nothing forces them to. So a change that lets more people see or change data also fails jadpo check until it adds an acceptance: a short file in which a person gives their reason. Review shows how to make sure that person is you.

A change that breaks another part of the app fails the check

Your agent reads the files it's working on, and rarely the whole app. TypeScript checks every file too, but its types don't record which errors a function can throw or who may see a record, and an ID is a plain string unless you build a branded type for it. A change that gets one of those wrong somewhere else still compiles. You find out from a test, in review, or from a user.

In Jadpo, all of those are part of the types. When a change breaks something in another file, the check fails and names the place, and your agent fixes it before it hands the change to you.

You ask your agent to stop an order when a cake is out of stock. In Jadpo, an action is a function that can change stored data, and it lists the failures it can end with. So the agent adds one.

domains/shop/actions/reserve_stock.jadpothe whole file
use shop/types { Quantity, Reservation }use shop/failures { OutOfStock }/// Holds stock for an order.action reserve_stock(quantity: Quantity) fails OutOfStock -> Reservation {changed by your agent    if (quantity > 10) {        reject OutOfStock    }    return Reservation {        quantity: quantity    }}

another file, which the agent didn't open

domains/shop/actions/checkout.jadpothe whole file
use shop/types { Quantity, Reservation, OrderReceipt }use shop/actions { reserve_stock }/// Places an order for some cakes.action checkout(quantity: Quantity) -> OrderReceipt {    var held: Reservation = reserve_stock(quantity)    return OrderReceipt {        quantity: held.quantity    }}
jadpo checkcheck failed: 1 error, 14 files

error reserve_stock can fail, and nothing handles it

at
domains/shop/actions/checkout.jadpo:6:29
reason
A call that can fail says so where it is made: attempt passes its failures on to the caller's fails list, and match handles each one.
next
Start the statement with attempt, or match on reserve_stock(...) and handle OutOfStock (agent)
rule
failure.attempt_required

Real code, and real output from jadpo check, from a project started with jadpo new. attempt would pass the failure on to whatever calls checkout, and match would handle it there. The request to your agent is made up.

What else the check finds across files

  • An order's ID passed where a customer's belongs. Each kind of stored record has its own ID type. The error
  • Money in the wrong currency. An amount keeps its currency, so pounds can't be added to euros.
  • A database change with no migration. The check fails until a migration says how to get there from the last version.
  • A route that changed without its API file. Your app's API has a file listing its routes. The check fails until jadpo api update rewrites that file, so the change shows in your diff.

The rules your app states are checked every time

Most backends rely on each developer remembering the rules: this route needs sign-in, that query must only return the user's own records, and the key must never be sent back. An agent forgets them as easily as a new developer would, and it makes many more changes.

In Jadpo, the access rules are part of the program, and the compiler checks every one of them on every change.

What it can't check A rule nobody wrote down, such as a feature you'd say no to. Your agent has to ask you about those.

  • A secret, such as an API key, sent in a responseCompile error. A secret is never sent, logged or shown. The error
  • A field only some people may read, sent to everyoneCompile error, even when it goes out indirectly: through a variable, another field, an event, or an if that decides what to send. The error
  • Someone else's record, fetched by its IDThe compiler adds the record's access rules to the SQL of every query. A record you may not read looks the same as one that doesn't exist. Access rules
  • A route that forgets sign-inEvery route needs sign-in unless it says otherwise. Routes are signed in by default
  • A call to a service the app hasn't declaredThere's no general HTTP client. Each outside service comes in as a typed package, which you can make from the service's OpenAPI document. External services

Review starts with what needs you

jadpo approval writes a report for the person approving a change, with the parts that need them first:

  1. Each change that lets someone see or change data they couldn't before, in plain words.
  2. How it happens: who calls which route, and how the data gets to them.
  3. Code that didn't change but now runs from somewhere new, which a line diff doesn't show.
  4. Changes to the API, the database and the access rules.
  5. Then the code itself.
jadpo approval --before mainexcerpt
1 decision needs a person◆ CompanyRole.viewer can now read work.Project.budget     acceptance missing    CompanyRole.viewer → GET /projects/{id} → work.project_detail      → ProjectView.budget1 declaration newly reachable  budgets.convert_currency  now reached from GET /projects/{id}  before    main at 1a2b3c4  api       1 route added  schema    1 migration added  access    1 field's grants changed  source    6 declarations in 4 files✓ Wrote build/review/approval.md

Real output, from the docs' Reviewing a change. work and budgets are parts of the example app. A grant says who may read or change a field, and a declaration is anything the code names, such as a type, an action or a route.

A person accepts each one

A change that lets more people see or change data fails jadpo check until it adds an acceptance: a short file, in your project's acceptances folder, in which a person gives their reason. An agent could write that file too. On GitHub, make yourself the code owner of that folder and protect your main branch, and a change like this can't merge until you approve it.

Your diff shows it too

Jadpo keeps two kinds of file up to date, and both change in your diff: one lists the access rules for each kind of stored data, and one lists your API's routes.

How to review a change

The whole backend is one language

Your agent doesn't have to choose a framework, an ORM and a job queue and connect them, so there are fewer places for it to connect something wrongly. Raw SQL and TypeScript can't go inside a Jadpo app, so work that needs them goes in a separate service.

The docs are written for agents as well as people, with a copy for each version of Jadpo, and your project tells your agent which version it uses.

  • Types

    Ranges and lengths a value must stay within, a separate ID type for each record, units and money. Types

  • HTTP APIs

    Typed routes, an OpenAPI document for each API, and time limits on every route. HTTP

  • Data

    PostgreSQL, checked migrations, search, caches and file storage. Data

  • Sign-in and access

    Sessions, passkeys, magic links, roles, and each customer's data kept apart. Identity

  • Outside services

    Typed packages, webhooks in and out, and fakes for tests. Integrations

  • Background work

    Events saved in the same transaction as the data, retries and schedules. Jobs and events

  • Testing

    A real database for each test and a clock you control. Testing

  • Tooling

    A formatter, editor support, OpenTelemetry, and jadpo fix for errors with only one right fix. Tooling

  • AI in your app

    Prompts kept in files the compiler checks, typed answers and similarity search. AI

  • Runs on

    PostgreSQL, with Redis if you want it for caches and shared rate limits.

See a whole feature in Jadpo: a customer orders a cake

This is one whole feature: a customer orders a cake. It's written as an action: a function that can change stored data and call outside services. This one charges the card, stores the order and announces it with an event, a message other parts of the app can react to.

  • Money keeps its currency. Goods, postage and VAT (sales tax) are all Sterling, so another currency can't be added to them.
  • Every failure is declared. One the action forgets to list is a compile error.
  • The order and its event are saved together, or not at all, so no event announces an order that wasn't saved.
domains/shop/actions/place_order.jadpoaction
/// What placing an order takes; a quantity outside 1 to 12 never gets in.type PlaceOrder = Input {    cake_id: Cake.id    quantity: Quantity}/// Charges the card, records the order and announces it.action place_order(    input: PlaceOrder,    customer: Principal.user) fails CakeNotFound, CardDeclined -> OrderReceipt {    var cake: Cake = attempt orderable_cake(input.cake_id)    // Cakes in grams, box in kilograms, packing in pounds: one `Mass`.    var weight: Mass = cake.weight * input.quantity + 1.2kg + 3lb    // Dividing a `Mass` by 1kg gives a plain number: how many kilograms.    var kilograms: Decimal = weight / 1kg    var per_kilo: Sterling = Sterling(money.from_minor(200, Currency.gbp))    var goods: Sterling = Sterling(cake.price * input.quantity)    var postage: Sterling = Sterling(per_kilo * kilograms)    // `* 120%` adds 20% VAT to the goods and the postage.    var total: Sterling = Sterling((goods + postage) * 120%)    // The provider's decline becomes this app's own failure.    attempt pay.charges.create(        AcmePay.ChargeRequest {            amount_minor: money.minor(total)        }    ) {        declined_card: CardDeclined    }    // The order and the event commit together, or not at all.    var order: Order = Order.create {        set: {            customer_id: customer.id            cake_id: cake.id            quantity: input.quantity            total: total        }    }    emit OrderPlaced {        order_id: order.id    }    return OrderReceipt {        id: order.id        total: order.total    }}

attempt runs a call that can fail and passes any failure on, and pay is the app's connection to AcmePay, a payment provider's package. Principal.user is the signed-in person. Real files from a small shop example, checked with the rest of its project. Only their imports are left out.

The route passes the signed-in customer, never a customer ID from the request. An entity is a kind of stored record, like a database table with types. The order entity's policy says only the customer named in customer_id may create or read an order, and the compiler adds that rule to every query on Order. The route's failures are listed in api/main.jadpo_record, the generated file listing the API's routes. A quantity outside 1 to 12 is refused before any of the shop's code runs.

domains/shop/routes/orders.jadporoutes
routes Orders {    prefix: /orders    // The action's failures become HTTP errors by their kind (404, 422) and    // are listed in api/main.jadpo_record. One it left undeclared wouldn't compile.    /// Places an order.    POST / {        input: PlaceOrder        output: OrderReceipt        status: SuccessStatus.created        run: place_order(input, current_principal.user)    }}
domains/shop/entities/order.jadpoentity
entity Order {    id: Uuid    customer_id: Customer.id {        on_delete: OnDelete.restricted    }    cake_id: Cake.id {        on_delete: OnDelete.restricted    }    quantity: Quantity    total: Sterling    policy: {        create: [customer_id]        read: [customer_id]    }}
domains/shop/types/quantity.jadpotype
/// How many cakes one order is for: the oven holds twelve.type Quantity = Int {    min: 1    max: 12}
domains/shop/types/sterling.jadpotype
/// An amount in pounds, held as whole pence.type Sterling = Money {    currency: Currency.gbp    rounding: Rounding.half_even}

Where Jadpo is now

Jadpo is early. One person builds it, working with coding agents, as a research project to find out whether a language like this beats a strong TypeScript setup.

Coding agents

The test used one small support-desk app, built twice, in Jadpo and in TypeScript, with written rules such as "companies never see each other's data". Three AI models made the same 10 changes to each copy, three times over: 90 changes in each language. Tests the agents never saw judged every change.

Changes that broke one of the app's rules, of 90: TypeScript 12 Jadpo 1

The one in Jadpo was a feature the app's owner would have refused. The agent built it without asking. No compiler can check a rule nobody wrote into the app, so Jadpo's docs, and the steps its errors suggest, tell agents to ask first. On every other change that needed the owner's decision, the agents in Jadpo asked first. With every model, agents asked before acting more often in Jadpo.

See the results

Cost

Agents cost more to run in Jadpo. Each change that came out right cost 2 to 3 times as much in AI model charges.

AI models have seen almost no Jadpo code in training, so agents learn it from the docs as they work. The cost should come down as more Jadpo code is published and models learn from it.

Speed

TypeScript on Bun or Node used 1.7 to 3.3 times as much CPU per request as Jadpo. Jadpo built for Cloudflare Workers handled background work more slowly than TypeScript on Bun. Everything ran on one laptop, with Workers' open-source runtime standing in for Cloudflare.

How fast it is

What it doesn't do

  • You can't write raw SQL or TypeScript inside a Jadpo app. Keep that work in a separate service.
  • It can't check that your requirements, or the access rules a person approved, are right.
  • It can't check that your business logic says what you meant.
  • It can't keep outside services and infrastructure up and uncompromised.
  • Jadpo's own compiler and runtime may have bugs.

Try it with your agent

Jadpo is new, so your agent learns it from these docs. The prompt has your agent install the CLI and start a project, so read it before you paste it.

Paste into your agent
Help me try Jadpo, an experimental language for AI-written backends. It's new and changes between versions, so don't rely on what you remember about it. Start at https://jadpo.dev/llms.txt and read https://jadpo.dev/docs/primer.md before writing any Jadpo.

Install the Jadpo CLI as https://jadpo.dev/install.md describes, start a project with jadpo new my-app, then run jadpo check and jadpo test in my-app.

When an error's next step ends in (human), stop and ask me before changing anything, putting everything I need to decide in one question. Fix other errors yourself, reading the error's page when its next step isn't enough, and tell me what the compiler caught.
  • llms.txt is the one starting point for agents: what Jadpo is, where the primer is, and how to find any page by topic or error.
  • These docs follow Jadpo's main branch. Each release has its own copy of the docs, and llms.txt says how to find the one for your version.

Try it yourself

  • Learn Jadpo

    Build a todo app with sign-in in 14 pages, from an empty folder to a deployed server. Start here.

  • Install the CLI

    With npm, as here, or Homebrew, an install script or a prebuilt binary.

    $ npm install -g @jadpo/jadpo
    $ jadpo new my-app
  • Keep the primer beside you

    The whole language on one page, once you've started.