The plugin and the cloud
When your site talks to w-pencil.cloud, exactly what it sends, what comes back and what happens when the answer is no. Updates, and the routes on your site.
7 min read WordPress 6.6+ Updated 1 Dec 2026
In short
- Outbound only. Your server sends HTTPS requests to
https://w-pencil.cloud/api/v1/. Nothing on w-pencil.cloud ever calls your site. - Through WordPress's HTTP API, so WordPress's proxy constants apply. Each request gives up after 3 seconds and follows no redirects. Network and servers has the firewall and proxy details.
- Never during a save. A save spends from an allowance the site already holds, in the same database transaction, so editors never wait for the cloud.
- Counts, not content. No field values, titles, addresses of pages or names of editors are ever sent.
When the site talks to the cloud
- Connecting. Your browser goes to w-pencil.cloud's consent page. When you press Connect this site, it comes back to your site with a one-time code, and your server exchanges it once. With a site key instead, your server sends the key once, and no browser is involved.
- After a save, when a report or a new allowance is due. The editor's browser asks your site in the background (
admin-ajax.php?action=w_pencil_sync), and your site sends the cloud its usage, then asks for a new allowance if this one is low. - On WP-Cron, every hour, the same, in case no browser did.
- When a popup opens and the allowance is used up, the site asks for a new one first.
- On W-Pencil › Account and with
wp w-pencil status, to show fresh figures. - When you disconnect, unless you use
--localor On this site only. - On Tools › Site Health, which checks that the cloud answers (
GET /api/v1/health, unsigned). - For updates, at most every 6 hours, unsigned and anonymous: below.
Page views never cause a request, for visitors or for editors. The toolbar's count comes from your own database.
What's sent
Connecting sends the site's origin, like https://example.org, the address to come back to, a random state, a PKCE challenge and the W-Pencil and WordPress versions, in the browser's address. Your server's exchange then sends:
- the one-time code and the PKCE verifier;
- the origin;
- the public half of the site's new Ed25519 key, never the private half;
- the W-Pencil and WordPress versions.
The answer holds the site's ID, the account's name, its plan and the key's fingerprint, which the plugin checks.
Connecting with a site key sends POST /api/v1/connect/site-key from your server, with:
- the site key, like
WPK-7Q2M-K9TD-4XHB-R8WN, made on the Sites page of your dashboard; - the origin;
- the public half of the site's new Ed25519 key;
- the W-Pencil and WordPress versions.
The site has no ID yet, so the request is signed with the private half of that new key, and carries the host name header below. The answer is the same as the exchange's. w-pencil.cloud keeps only the key's SHA-256, and the key works once, for 30 minutes.
Every request after that is signed with the private key. The headers carry the site's ID, the time, a random nonce, the signature and the host name the site answered on, like www.example.org. W-Pencil uses the host name to spot copies of the site's database.
A usage report lists saves. Each one has:
- a random ID, so a report sent twice is only counted once;
- the allowance it was spent from;
- when it happened;
- a count, always 1;
- the kind:
text,link,imageorform, anddevon a local development host; - for an Undo, the reason it's free:
undo.
Saves that change nothing aren't reported at all, nor are saves on a copy of the site's database or the 50 trial edits of a site that isn't connected yet.
A request for an allowance sends the ID of the allowance the site holds and how much of it was used.
w-pencil.cloud sees your server's IP address, as any web service does. What the cloud keeps says what's stored and for how long.
What comes back
- An allowance, called a lease: up to 25 edits the site may spend before asking again. It lasts 24 hours at most, and ends with the month's edits. With it come the account's balance, the period's
grant, its plan and whether it's low. - For a usage report, how many saves were new and the balance.
- For the account: its name, plan, packs, balance,
grantand when the edits renew.
grant is what the current period gave the account: 100 on Free or 4,000 a pack, plus a prorated part for packs added during the period. W-Pencil › Account and wp w-pencil status show the balance out of it, like "3,970 of 4,000". Edits we add by hand aren't part of it.
Several web servers asking at the same moment get the same allowance, so a site never holds two.
When the answer is no
With WP_DEBUG on, W-Pencil writes each of these to PHP's error log (with WP_DEBUG_LOG, wp-content/debug.log), after "W-Pencil:".
- No edits left (
402 credits): popups open on "No edits left this month" until the renewal date. The site asks again at most once a minute, so a pack added in the meantime works at once. - The key no longer works (
401 disconnectedor401 signature): the site was disconnected, or another key replaced this one. The site forgets the connection and admins see Connect W-Pencil again. The log says "the cloud disconnected this site (disconnected). Connect it again under W-Pencil, Account." - A site key that doesn't work (
400withinvalid,expiredorused;409 elsewhere;429 rate_limitafter 10 failed tries in an hour from your server's address): the site isn't connected, and W-Pencil › Account or WP-CLI says why. Once a correctly signed request finds the key, the key is used up, whatever the outcome. Troubleshooting has each message. - The clock is off (
401 skew): your server's clock is more than 5 minutes from w-pencil.cloud's. The plugin learns the difference and tries once more. - A copy (
409 copy): the request came from another host than the one the site was connected from. No allowance is given, the site remembers it's a copy, and the log says "the cloud refused a lease: 409 copy". - No answer (a network error, a timeout or a
5xx): the site goes offline. Editing carries on for up to 50 edits, reported when the cloud is back. Admins see "Can't reach W-Pencil since 10:42. Editing continues: 32 offline edits left." and the log says "the cloud can't be reached: …".
Updates
W-Pencil isn't on wordpress.org, so it updates from w-pencil.cloud. When WordPress checks for plugin updates, W-Pencil asks:
$ curl -s https://w-pencil.cloud/api/v1/plugin/latest
{"ok":true,"manifest":{"version":"1.0.1","requires":"6.6","tested":"7.1","requires_php":"8.1","download_url":"https://w-pencil.cloud/download/w-pencil-1.0.1.zip","sha256":"9f2c…","last_updated":"2026-12-01T14:05:00Z","sections":{…}},"signature":"…"}- Unsigned and anonymous. The request carries no site ID, no address and no key, and its user agent is
W-Pencil/and the version. Every site gets the same answer, which caches may keep for an hour. - Signed by the release key.
signatureis an Ed25519 signature of the manifest, made on the W-Pencil team's own machine with a key that never reaches the server. The plugin ships the public half, and offers the update only when the signature checks out anddownload_urlis on w-pencil.cloud. - Checked before it installs. W-Pencil downloads the zip itself and installs it only when its SHA-256 is the manifest's
sha256. - Kept 6 hours, or 1 hour after a failure. Check again on Dashboard › Updates asks at once.
The zips are public: https://w-pencil.cloud/download/w-pencil.zip is always the newest, and /download/w-pencil-1.0.1.zip one release.
Routes on your site
Your editors' browsers use these. If a firewall or password protection sits in front of wp-admin, let logged-in editors through:
wp-admin/admin-ajax.php?action=w_pencil_load,w_pencil_save,w_pencil_upload,w_pencil_syncandw_pencil_undo-form:POST, with W-Pencil'sX-CSRF-Tokenheader (a WordPress nonce);…?action=w_pencil_images,w_pencil_pages,w_pencil_creditsandw_pencil_token:GET;wp-admin/admin.php?page=w-pencil-frame: WordPress's own editor and More fields…, inside the popup;wp-admin/admin-post.php?action=w_pencil_connect_start,w_pencil_connect,w_pencil_site_keyandw_pencil_disconnect: connecting and disconnecting, for admins only;wp-admin/admin.php?page=w-pencil: the settings page.
All of them need a logged-in user. The editor's requests also need Edit on the page, and the connect and settings routes the w_pencil_admin capability.