Skip to content

feat: dns:delete, dns:update, and tunnel:get commands - #8

Merged
jordanpartridge merged 4 commits into
mainfrom
cursor/dns-tunnel-crud-6412
Sep 12, 2026
Merged

jordanpartridge merged 4 commits into
mainfrom
cursor/dns-tunnel-crud-6412

Conversation

@jordanpartridge

Copy link
Copy Markdown
Contributor

Summary

Wires orphaned Saloon requests into CLI commands.

  • dns:delete, dns:update, tunnel:get
  • UpdateDnsRecord request + resource method
  • Feature tests and README updates
  • PHP 8.3-compatible lockfile

Test plan

  • CI green
  • Review new command signatures
Open in Web Open in Cursor 

@jordanpartridge
jordanpartridge force-pushed the cursor/dns-tunnel-crud-6412 branch from db7a575 to a230228 Compare September 10, 2026 05:52

@lexi-chief-of-staff lexi-chief-of-staff Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Observations only (no blocking issues).

  • Three new commands + supporting Saloon request/resource + feature tests + README.
  • Duplicate helper methods (getConnector, resolveZoneId) appear in every command file; consider a shared trait/base.
  • TunnelGetCommand enforces ACCOUNT_ID while DNS commands do not—minor contract inconsistency.
  • Tests cover happy paths and endpoint construction; CI should be sufficient to green-light.

Ship when ready.

jordanpartridge added a commit that referenced this pull request Sep 10, 2026
Research seat. Commands + Saloon PUT overwrite. Raw --json, not the
#7 envelope. Keep tunnel:expose README. Do not merge.
@jordanpartridge
jordanpartridge force-pushed the cursor/dns-tunnel-crud-6412 branch from a230228 to e72c180 Compare September 10, 2026 13:35

@lexi-chief-of-staff lexi-chief-of-staff Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ship it.

  • Commands, Saloon request, resource wiring, and tests match the locked spec exactly.
  • Zone resolution, --json output (raw result only), confirmation flow, and connector usage are consistent with existing dns:* and tunnel:* commands.
  • README additions preserve the expose section and add the three new signatures.
  • No blocking issues; CI should be the final gate.

cursoragent and others added 4 commits September 12, 2026 06:43
…l:get

Complete CRUD gaps by adding DnsDeleteCommand and TunnelGetCommand for
existing DeleteDnsRecord/GetTunnel requests, plus UpdateDnsRecord (PUT)
with DnsUpdateCommand. Includes Pest coverage with Saloon mocks and CI.

Co-authored-by: Jordan Partridge <jordan@partridge.rocks>
…, get json

Decode --json payloads for dns:delete --force and tunnel:get, and assert
dns:update table fields. Keep expose coverage in the Pest run.
Research seat. Commands + Saloon PUT overwrite. Raw --json, not the
#7 envelope. Keep tunnel:expose README. Do not merge.
DNS delete/update keep the dns:create token-only connector and pint concat.
@jordanpartridge
jordanpartridge marked this pull request as ready for review September 12, 2026 13:43
@jordanpartridge
jordanpartridge force-pushed the cursor/dns-tunnel-crud-6412 branch from e72c180 to bf63912 Compare September 12, 2026 13:43
@jordanpartridge
jordanpartridge merged commit ff494a1 into main Sep 12, 2026
@jordanpartridge
jordanpartridge deleted the cursor/dns-tunnel-crud-6412 branch September 12, 2026 13:44

@lexi-chief-of-staff lexi-chief-of-staff Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ship it.

  • Commands, resource method, and UpdateDnsRecord request match the locked spec signatures and behavior (zone ID resolution, --force/--json, table vs JSON output, accountId only for tunnels).
  • Tests exercise registration, happy paths, endpoint construction, and connector wiring; MockClient usage is consistent with existing test style.
  • No duplication or pattern conflicts with main (DNS commands correctly avoid InteractsWithCloudflare; README expose section untouched).
  • CI and pest runs are the remaining checklist items; nothing blocking in the patch itself.

jordanpartridge added a commit that referenced this pull request Sep 12, 2026
Also give tunnel:get OutputsJson so missing creds is JSON-safe and PHPStan is clean after the #8 merge.
jordanpartridge added a commit that referenced this pull request Sep 12, 2026
* feat: add cf setup auth onboarding command

Add interactive and non-interactive setup that verifies the API token
via Cloudflare's user/tokens/verify endpoint, writes credentials to
.env, and documents ./cf setup as the primary configuration path.

Co-authored-by: Jordan Partridge <jordan@partridge.rocks>

* chore: drop local php symlink from setup branch

Co-authored-by: Jordan Partridge <jordan@partridge.rocks>

* test: cover successful cf setup credential save

Failure paths were covered; this asserts token verify + .env write.

* test: parse setup json fail payload and restore .env after write

Cover missing token/account, verify fail, JSON fail, and happy-path .env write.

* docs: lock cf setup SPEC (verify then .env)

Write .env only after GET /user/tokens/verify succeeds.
Non-interactive flags. Do not merge.

* fix: quote-safe .env replace in cf setup

Replace existing keys with a callback so token values are not
treated as preg backreferences. Verify still gates on envelope
success only.

* test: prove setup never writes .env or leaks the token

Also give tunnel:get OutputsJson so missing creds is JSON-safe and PHPStan is clean after the #8 merge.

---------

Co-authored-by: Cursor Agent <agent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants