Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

Notable changes to `@wirecat/wordpress-cli`. One section per version, newest first.

## 0.3.0 — 21.11.2026

### Added

- **WireCat Desktop signs in to WordPress in its own window, also for a tool added from its describe.**
`--wcat-describe` now lists the application password sign-in with its `--site` and `--login` flags, so Desktop asks
for the site, the user name and the password, and sends the password on stdin.

### Fixed

- **`posts publish` and `posts unpublish` ask one question**, not `posts.update` a second time.
- **`--help` names WordPress's own sign-in and spec**: the `session` group says application password, and `api` says
its index at `/wp-json`.

## 0.2.0 — 21.11.2026

### Added
Expand Down
17 changes: 16 additions & 1 deletion contracts/wirecat.json
Original file line number Diff line number Diff line change
Expand Up @@ -2385,7 +2385,22 @@
],
"signIn": {
"gives": "Lets your agent read your WordPress posts and pages, write drafts, and publish when you allow it.",
"asks": "Your site's address, your user name and an application password: in WordPress, Users → Profile → Application Passwords. WordPress 5.7 or later, over https."
"asks": "Your site's address, your user name and an application password: in WordPress, Users → Profile → Application Passwords. WordPress 5.7 or later, over https.",
"methods": [
{
"id": "app-password",
"label": "WordPress application password",
"words": [
"{profile}",
"session",
"start",
"--json"
],
"stdin": true,
"site": "--site",
"login": "--login"
}
]
},
"skill": {
"status": [
Expand Down
4 changes: 2 additions & 2 deletions docs/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ wordpress commands info [path]

## `wordpress session`

keep this profile's WordPress token in the OS keyring
keep this profile's WordPress application password in the OS keyring

### `wordpress session start`

Expand Down Expand Up @@ -111,7 +111,7 @@ wordpress session list

## `wordpress api`

the raw WordPress API, one command per operation of its OpenAPI document
the raw WordPress API, one command per operation of its index at /wp-json

### `wordpress api list`

Expand Down
1 change: 1 addition & 0 deletions docs/dev/live-checks.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
0.1.2 b25ff9d21928bf217c74ccd75f37174eb427ee4b 2026-11-21 scripts/live.sh v2:e4564e7d90c5a1ca41d2c157edf28ad61603970d622e423d6b70a1a67b9a2e73
0.1.2 60cde46dde8ddaa5c5d446d2054c12f34145e4e4 2026-11-21 scripts/live.sh v2:f167775a6dccda03576b9ac30fa10529f36b23b6842405c3eb1fa4979c789e79
0.2.0 4cf6ffa58bd61cd90446614ba43d85ad2e92a45d 2026-11-21 scripts/live.sh v2:30ebf419a2f8e4419a89449dcca80f5c2cd2d9cdf197db155a1bd206f26de10f
0.3.0 076dcef22c4bf86ab1a7ebc92b5d7b01c111c91b 2026-11-21 scripts/live.sh v2:2da9440c675421351c7467fa4a4fef3e79b421c5eb8cddd8a1dfe827fd8f7a37
3 changes: 1 addition & 2 deletions docs/permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ run it yourself in a terminal.
A write to a page goes through the pages routes, so it also checks their keys: `pages.publish` when it publishes or
schedules the page, or updates a page that is published or scheduled; `pages.delete` when it deletes the page, to the
trash or for good; and `pages.delete.force` with `--allow-delete`. Each asks by default. After a yes to the `posts`
key, the same action on the page is not asked again. `posts publish` and `posts unpublish` still ask `posts.update`
a second time, for a post and a page, until the next cli-core release.
key, the same action on the page is not asked again.

## The api group

Expand Down
10 changes: 1 addition & 9 deletions lint/audit-differences.json
Original file line number Diff line number Diff line change
@@ -1,9 +1 @@
[
{
"group": "wordpress",
"rule": "same-error-reason",
"target": "reason account-remove.unknown-profile=account-rename.unknown-profile",
"reason": "one failure under two names, from cli-core 0.716.0, that every CLI of the family prints (FIND-2855)",
"review_after": "2026-12-05"
}
]
[]
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@wirecat/wordpress-cli",
"version": "0.2.0",
"version": "0.3.0",
"description": "WordPress posts and pages: sync, search and write drafts from your agent",
"license": "Apache-2.0",
"author": "Viacheslav Ptsarev",
Expand Down Expand Up @@ -61,8 +61,8 @@
"source:check": "node --experimental-strip-types scripts/source-check.ts"
},
"dependencies": {
"@wirecat/cli-base": "0.125.3",
"@wirecat/cli-core": "0.716.0",
"@wirecat/cli-base": "0.126.1",
"@wirecat/cli-core": "0.718.0",
"commander": "15.0.0",
"valibot": "1.5.0"
},
Expand Down
22 changes: 11 additions & 11 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ export const API = {
}),
},
service: "WordPress",
spec: "its index at /wp-json",
}

const api = serviceApiPermissions(API)
Expand Down
10 changes: 10 additions & 0 deletions src/identity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,16 @@ export const DESKTOP = {
asks:
"Your site's address, your user name and an application password: in WordPress, Users → Profile → " +
"Application Passwords. WordPress 5.7 or later, over https.",
methods: [
{
id: "app-password",
label: "WordPress application password",
words: ["{profile}", "session", "start", "--json"],
stdin: true,
site: "--site",
login: "--login",
},
],
},
} satisfies ManifestIdentity

Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = "0.2.0"
export const VERSION = "0.3.0"
21 changes: 21 additions & 0 deletions src/wcat.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,25 @@ describe("WCAT", () => {
expect(v.safeParse(manifestSchema, manifest).issues).toBeUndefined()
expect(manifest.desktop.tagline).toBe(WCAT.tagline)
})

// WireCat Desktop's catalog entry signs in with these words and flags (wirecat-desktop #459); a tool added from its
// describe gets the same window sign-in only when the manifest says so.
it("offers Desktop the sign-in with the site, the user name and the password on stdin", () => {
const manifest = buildManifest({
identity: WCAT,
commands: describeProgram(createProgram()),
pkg: { name: "@wirecat/wordpress-cli", bin: { "wcat-wordpress": "dist/bin/wordpress.js" } },
skills: true,
})
expect(manifest.desktop.signIn?.methods).toEqual([
{
id: "app-password",
label: "WordPress application password",
words: ["{profile}", "session", "start", "--json"],
stdin: true,
site: "--site",
login: "--login",
},
])
})
})
Loading