Withdraw a draft
Deletes one of your drafts that is not active yet: invited, claimed, expired or conflict. The claim link and any sign-in link stop working at once, and we send no more reminders. The email address is free again, so a later POST /partner/customers for it creates a new draft. A claimed draft may belong to a Joulo login the customer made. That login stays, without a link to you. An active draft is a customer linked to you: withdrawing it is refused. That customer turns off sharing in their Joulo account instead. Find the draft_id with GET /partner/drafts?external_ref=.
Partner API key, sent as Authorization: Bearer <key>. Production keys start with jpk_live_ and work only on https://api.joulo.nl. Sandbox keys start with jpk_test_ and work only on https://api-staging.joulo.nl. Sandbox keys minted before September 2026 also start with jpk_live_. A key used on the wrong host returns 401 with a detail. A key is bound to one partner and reaches only the Partner API routes. Any other route returns 404 when it does not exist. A route that needs a scope the key lacks, such as GET /sessions, returns 403 with error: Insufficient scope and a required_scope. Every other route returns 403 with error: partner_api_key_scope. Mint and revoke keys in the partner portal. A partner has one active key at a time.
In: header
The id of the draft, from GET /partner/drafts or from the response to POST /partner/customers.
uuidResponse Body
curl -X POST "https://api.joulo.nl/functions/v1/api/partner/drafts/withdraw" \
-H "Content-Type: application/json" \
-d '{
"draft_id": "8f2c1d4e-5b6a-4c3d-9e8f-0a1b2c3d4e5f"
}'{
"ok": true
}{
"error": "draft_id is required",
"code": "draft_id_required"
}{
"error": "Missing or invalid API token"
}{
"error": "Draft not found",
"code": "draft_not_found"
}{
"error": "Deze klant is al actief en aan jou gekoppeld; intrekken kan niet. Neem contact op met Joulo.",
"code": "draft_active"
}{
"error": "Too many requests",
"retry_after_seconds": 3
}{
"error": "Failed to withdraw draft"
}{
"error": "Authentication is temporarily unavailable, try again shortly"
}