* Support delegated approval for Link Pay Token spend requests
--approve now works with --execution-method link_pay_token as long as
--no-request-approval is also passed, so OAuth clients authorized for
spend_requests:approve can create already-approved LPT requests via
create_delegated without going through consumer approval.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
* Trim PR to just the delegated-approval guard change per review
Drop the README/CLAUDE.md docs and CLI help-text additions for
--approve/--request-approval — delegated LPT users already have their
own skill file, so the CLI's public docs and help text don't need to
cover this path.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
---------
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
* Send link-cli User-Agent on mpp pay merchant requests.
MPP probes and paid retries used global fetch, so merchants saw Node's default User-Agent and LINK_HTTP_PROXY was skipped. Route those calls through the CLI's configured fetch so User-Agent applies unless -H overrides it.
Co-authored-by: Cursor <cursoragent@cursor.com>
Committed-By-Agent: cursor
* Set mpp pay User-Agent in buildHeaders instead of wrapping fetch.
The fetchImpl wiring was more than this needed; default the header on merchant requests and leave -H User-Agent as an override.
Co-authored-by: Cursor <cursoragent@cursor.com>
Committed-By-Agent: cursor
---------
Co-authored-by: Cursor <cursoragent@cursor.com>
* Add changesets for PRs #255, #257, #258, #260, #261
Covers spend-request expires-at, SDK transport hardening, canonical
SDK resource adoption, response validation, and moving auth ownership
into the CLI — none of which shipped with a changeset, so CI had
nothing to version since @stripe/link-cli@0.13.1.
Committed-By-Agent: claude
* Version Packages
Release @stripe/link-cli@0.14.0 via changesets: consume pending changesets and update CHANGELOG.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
---------
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
* Add --expires-at support to spend-request create
Mirrors the mint PR (stripe-internal/mint#2484603) that lets allow-listed
OAuth clients request a spend request expiration up to 7 days out instead
of the default 12 hours, for extended/repeat-use agent scenarios.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
* Hide --expires-at from docs and CLI schema output
Most OAuth clients aren't allow-listed for the server-side flag; leaving
it documented in SKILL.md/README.md/schema descriptions would prompt
general agents to try it and hit a 400. The flag stays functional
(same as the existing `approve` field) but drops its description so it
no longer shows up meaningfully in --schema/--llms-full.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
* Note the unit for --expires-at in its schema description
Bare field with no description gave zero signal, but agents seeing an
undocumented integer field could just as easily guess wrong (e.g.
milliseconds). Clarifying the unit alone doesn't explain the gating or
bounds, so it stays unlikely to be tried speculatively.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
* Fix biome formatting on expiresAt schema field
CI was failing pnpm biome check on the line-length wrap for the
one-line describe() call added in 1b6021f.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Committed-By-Agent: claude
---------
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
* update table styling for balances and sources commands
* test
* fix: rename Account name column to Source name for consistency
Committed-By-Agent: claude
- Handle nested `{ error: { message } }` error shape in auth resources
(both CLI and SDK implementations) by replacing the cast-only
`err?.error` interpolation with `extractOAuthErrorMessage`, which
does a runtime typeof check before descending into the object
- Fix `switch (err.error)` in `pollDeviceAuth` to switch on
`extractOAuthErrorCode(err)` so polling continues correctly when a
non-string error arrives (object would never match a string case)
- Fix `error_description` truthy guard to a nullish check so an empty
string from the server is preserved rather than falling back to the
error code
- Replace inline cast-only error extraction in payment-methods,
shipping-address, user-info, and web-bot-auth resources with
`extractErrorMessage` from base.ts, which already handles both
string and nested-object error shapes
- Replace `String(err)` in `useAsyncAction` with `JSON.stringify(err)`
so thrown plain objects produce readable output instead of
[object Object]
- Add tests covering all of the above
Committed-By-Agent: claude
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
The link-api PR (mint#2412595, LINK_AI_WALLET-365) added top-level
`card_brand` and `card_last4` to the RetrieveSpendRequest response so
integrators can identify a card for debugging without expanding the full
`card` object via `include=card`.
Add both fields to the SDK `SpendRequest` type and display them in the
interactive `retrieve` view when the full card is not expanded. The SDK
already passed these through to `--format json` output via its
pass-through cast; this closes the typing and interactive-display gap.
Docs (README, SKILL.md, CLAUDE.md) updated to match.
Committed-By-Agent: claude
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add a postinstall script that copies the SKILL.md into
~/.claude/skills/ and ~/.codex/skills/ so the skill is
available globally without being inside the repo. Updated
prepack to bundle the skills directory into dist/.
Committed-By-Agent: claude
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>