Your AI assistant prepares the fax. You check the preview and pay in the browser. No account. No API key. No subscription. Nothing is sent and nothing is charged before you pay.
The PayPerFax API is the pay per fax API for an AI assistant that is helping one person send one fax. It is the same pay-per-fax service that lives at payperfax.com, opened up so that ChatGPT, Claude, Gemini, Claude Code, Codex or Cursor can prepare the fax instead of you.
How it works, in three steps
- The assistant prepares the fax. It takes the destination number, your email address and either the letter it wrote for you or a file you gave it. It makes one HTTP call to the PayPerFax API and gets back a link.
- You open the link and see the preview. The preview page shows the fax exactly as the receiving machine will see it, with the final guaranteed price. If a signed form is still missing, the link opens the fax form with everything your assistant filled in, ready for you to add the file.
- You pay and the fax goes. Payment is in the browser, by card or PayPal. The authorization is placed when you pay and the charge only lands when the fax is delivered. A failed fax is not charged.
The assistant never pays and never sends on your behalf. The link, the preview and the payment are yours.
Two ways in
If your assistant can make HTTP calls (fax API)
A coding agent with a shell (Claude Code, Codex, Cursor) or any script can post the fax directly. The whole call is one line:
curl -s https://fax.payperfax.com/api/fax \
-H "Content-Type: application/json" \
-d '{
"to": "+14155550101",
"email": "[email protected]",
"markdown": "# Change of address\n\nDear Landlord,\n\n..."
}'
The answer is JSON:
{
"id": "fax_01HV...",
"url": "https://fax.payperfax.com/preview/token...",
"status_url": "https://fax.payperfax.com/api/fax/fax_01HV.../status"
}
Open url to review the preview and pay. The assistant gives you url; it does not open it for you.
The markdown field takes a letter the assistant wrote (up to 100 KB). For a file the assistant has on disk, use multipart/form-data and documents[] with PDF, DOCX, JPG, PNG, TIFF or Markdown, up to 10 MB total.
For a signed paper the assistant does not have, set file_expected=true. The answer is a link to the fax form, pre-filled, with a notice that an AI assistant prepared it. You add the signed page yourself.
If your assistant has no PayPerFax tool
A chat app with no shell (plain ChatGPT, Claude or Gemini without an active tool) cannot call the API directly. It still helps, in the plainest way: it writes the letter for you and gives it to you as a PDF, a DOCX or a Markdown file. You open fax.payperfax.com and upload the file on the form. If the assistant can read web pages, it can also read the status from the tracking page after you pay.
What it is good for
Letters your assistant can write and your signed paperwork can go with.
- A letter to a landlord, a doctor, a court or a school. The assistant drafts it from your notes. You read the preview, pay, and the letter is sent.
- An IRS form. The assistant writes the cover letter and finds the right fax number. For the signed form (2848, 8821, SS-4, 3911 and others), add the scan yourself with
file_expected=true. See the IRS fax number directory for the number to use for each form. - A notice to a servicer or an agency. Change of address, benefit appeals, insurance replies, student loan paperwork.
- A one-off business fax from a coding agent. The agent sends a signed order, a termination letter or a redacted contract from the shell it is already in.
What this is not
The PayPerFax API is for an AI assistant helping one person send one fax. It is not a fax API to build faxing into a product.
- There are no accounts. There are no API keys. There is nothing to sign up for.
- There are no webhooks and no callbacks. If you need to know the status, read it with the status call.
- The assistant does not pay. A person pays, in the browser, every time.
- There is no sending without a payment step. “Pay per fax” is literal: one fax, one payment.
- There is no receiving a fax. The API sends only.
If you are building a system that embeds faxing (a healthcare platform that sends thousands of referral faxes a day, a loan servicer with its own fax workflow, an EHR), you need a different kind of service. We are not it.
Tracking a fax your assistant started
Every fax you pay for lands on a tracking page. The page shows the stage: queued, sending, delivered or failed. It also shows a short prompt you can copy and paste into your AI assistant, so the assistant can watch the status for you from its own session.
If your assistant can make HTTP calls, it can read the status directly from status_url in the answer, or at any time from:
curl -s https://fax.payperfax.com/api/fax/{id}/status
The response has status (pending, delivered, failed, expired) and, while pending, a stage of rendering, awaiting_payment or sending.
Price
The PayPerFax API uses the same pay-per-fax pricing as the website. There is no API tier.
- $2 covers the first three pages (one optional cover page plus two document pages).
- $0.75 covers each page after that.
- A fax that fails to transmit is not charged.
The preview link shows the final guaranteed price before you pay. Billing is in your local currency where supported: USD, EUR, GBP, JPY or KRW. The full destination list and the per-country rates are on the pricing page.
Documentation for assistants and developers
The reference lives on the PayPerFax documentation site. Two short pages for an agent, two for a developer:
- Guide for AI assistants: the plain-language page for an assistant that is about to prepare a fax. The rules it needs: ask for the email address, do not retype a signed form as text, take an agency’s fax number from the official site, keep the letter inside a sensible size.
- Send a fax: the fields of the create call, with examples.
- Check the status: the status values and the polling rules.
- Fax a form to the IRS with an AI assistant: a worked example with a signed form.
The documentation is in English only. The link pages that the fax recipient sees (preview, filled form, tracking) are in six languages: English, Spanish, German, Japanese, Korean and French.
Short FAQ
Does my assistant pay for the fax?
No. The assistant prepares the fax and gives you a link. You open the link, see the preview with the price, and pay in the browser. Payment is always a person at a browser, every time.
Do I need an account or an API key?
No. There is no sign-up on the website and no API key for the fax API. If an API ever requires an account to send one fax, it is not this one.
Which files can my assistant send?
PDF, DOC, DOCX, JPG, PNG, TIFF and Markdown (.md). Ten megabytes total for a single fax. A Markdown file can be up to 100 KB and is rendered as a plain black-on-white document when the fax is sent. If a page in your fax needs a signature, send the signed scan as a file. Do not let the assistant retype a signed form as text.
Is it safe to let an assistant start a fax for me?
The assistant only prepares the fax. It cannot pay. It cannot send without you. Every fax has a preview link that only you open, and the preview shows the exact document and the exact fax number before you pay. The connection to PayPerFax uses TLS, and documents are deleted after 30 days. The full policy is on the security page.
Which assistants work with this today?
A coding agent with a shell (Claude Code, Codex, Cursor) can make the API call directly. A chat app on its own (ChatGPT, Claude, Gemini) can draft the letter for you to upload at fax.payperfax.com, and can read the tracking prompt back if it has web access. More ways in will arrive as the ecosystem does.
