Skip to content

Rename card status PENDING_ISSUEPROCESSING#588

Merged
AaryamanBhute merged 1 commit into
mainfrom
06-16-rename-card-status-pending-issue-to-processing
Jun 16, 2026
Merged

Rename card status PENDING_ISSUEPROCESSING#588
AaryamanBhute merged 1 commit into
mainfrom
06-16-rename-card-status-pending-issue-to-processing

Conversation

@AaryamanBhute

Copy link
Copy Markdown
Contributor

Summary

Renames the Grid API card lifecycle state PENDING_ISSUE to PROCESSING.

Per the Slack thread, the PENDING_* states should consistently mean waiting on user/platform action, while PROCESSING means Grid (or the issuer) is doing work — matching the convention already used by the quotes and transactions resources. PENDING_ISSUE (card being provisioned by the issuer) is Grid-side work, so it becomes PROCESSING. This also makes room for Dhruv's upcoming PENDING_AUTH (delegated-auth setup pending on user+platform).

PENDING_KYC is intentionally unchanged — it waits on the cardholder.

Changes

OpenAPI source (openapi/):

  • components/schemas/cards/CardState.yaml — enum value + description table
  • components/schemas/cards/CardStateReason.yamlISSUER_REJECTED description reference
  • paths/cards/cards.yamlPOST /cards description
  • webhooks/card-state-change.yaml — webhook description + example summary

Mintlify card doc snippets (mintlify/snippets/cards/): intro, quickstart, issuing-cards (incl. lifecycle diagram), implementation-overview, webhooks, sandbox-testing.

Regenerated bundles via make build: openapi.yaml, mintlify/openapi.yaml.

Note: breaking change & follow-ups

This is a breaking change to the public CardState enum (affects Card.state, the CARD.STATE_CHANGE webhook, and the GET /cards?state= filter). It's safe to land as a clean rename rather than a dual-value migration because the API surface is early-stage and no backend currently emits the PENDING_ISSUE string — sparkcore's internal CardStatus enum is ACTIVE/INACTIVE/SUSPENDED/CLOSED and the public CardState values aren't produced yet.

Follow-up (separate repo, not run here — needs the custom OpenAPI generator toolchain): regenerate the Python SDK in webdev/grid-api via update_schema.sh once this merges.

Verification

  • make build — bundles regenerate cleanly; bundle diff is exactly the 6 rename occurrences, no reformatting.
  • make lint0 errors (pre-existing warnings/infos on unrelated beneficiary schemas only).
  • grep -rn PENDING_ISSUE across the repo returns nothing.

🤖 inverted-obsidian(#1) | Feedback

Original PR: #587

Rename the Grid API card lifecycle state PENDING_ISSUE to PROCESSING so
that PENDING_* states consistently denote waiting on user/platform action
while PROCESSING denotes Grid/the issuer doing work — matching the
convention already used by the quotes and transactions resources.

PENDING_KYC is unchanged (it waits on the cardholder). Updates the
OpenAPI source under openapi/, the Mintlify card doc snippets, and the
regenerated openapi.yaml / mintlify/openapi.yaml bundles.

akanter commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions Bot added the breaking-change Introduces a breaking change to the OpenAPI spec label Jun 16, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Breaking OpenAPI changes detected

This PR introduces breaking changes to openapi.yaml:

API Changelog 2025-10-13 vs. 2025-10-13

API Changes

GET /cards

  • ⚠️ removed the enum value PENDING_ISSUE from the query request parameter state
  • ⚠️ added the new PROCESSING enum value to the data/items/state response property for the response status 200

POST /cards

  • ⚠️ added the new PROCESSING enum value to the state response property for the response status 201

GET /cards/{id}

  • ⚠️ added the new PROCESSING enum value to the state response property for the response status 200

PATCH /cards/{id}

  • ⚠️ added the new PROCESSING enum value to the state response property for the response status 200

POST webhook:card-funding-source-change

  • ⚠️ removed the enum value PENDING_ISSUE of the request property allOf[subschema #2]/data/state

POST webhook:card-state-change

  • ⚠️ removed the enum value PENDING_ISSUE of the request property allOf[subschema #2]/data/state

Detected by oasdiff. This PR will need approval from an API reviewer before merge.

@github-actions

github-actions Bot commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

✱ Stainless preview builds for grid

This PR will update the grid SDKs with the following commit messages.

cli

chore(internal): regenerate SDK with no functional changes

csharp

fix(types): rename PendingIssue to Processing in card state enums

go

fix(types): rename PENDING_ISSUE to PROCESSING in card state enum

kotlin

fix(types): rename PENDING_ISSUE to PROCESSING in Card state enum

openapi

fix(types): rename PENDING_ISSUE to PROCESSING in CardState enum

php

fix(types): rename PENDING_ISSUE to PROCESSING in Card state enum

python

fix(types): rename PENDING_ISSUE to PROCESSING in cards state enum

ruby

fix(types): rename PENDING_ISSUE to PROCESSING in card state enum

typescript

fix(types): rename PENDING_ISSUE to PROCESSING in cards state enum
grid-openapi studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅

grid-ruby studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅build ✅lint ✅test ✅

⚠️ grid-go studio · code

Your SDK build had a failure in the lint CI job, which is a regression from the base state.
generate ✅build ✅lint ❗test ❗

go get github.com/stainless-sdks/grid-go@961cdebca5c0a3a0b252f4c2ea36163ab9e0ca06
grid-kotlin studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅build ✅lint ✅test ✅

grid-typescript studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅build ✅lint ✅test ✅

npm install https://pkg.stainless.com/s/grid-typescript/a295fcabc28d49feae6cfa49c284219acf74f194/dist.tar.gz
⚠️ grid-python studio · code

Your SDK build had a failure in the lint CI job, which is a regression from the base state.
generate ✅build ✅lint ❗test ❗

pip install https://pkg.stainless.com/s/grid-python/52904b66fb4ed63b90dfcf5a723fb9887a84019b/grid-0.0.1-py3-none-any.whl
⚠️ grid-csharp studio · code

Your SDK build had a failure in the build CI job, which is a regression from the base state.
generate ⚠️build ❗lint ✅test ❗

grid-php studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅lint ✅test ✅

⚠️ grid-cli studio · code

Your SDK build had a failure in the test CI job, which is a regression from the base state.
generate ⚠️build ⏭️lint ⏭️test ❗


This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push.
If you push custom code to the preview branch, re-run this workflow to update the comment.
Last updated: 2026-06-16 21:40:35 UTC

@AaryamanBhute AaryamanBhute requested a review from shreyav June 16, 2026 21:11
@greptile-apps

greptile-apps Bot commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR renames the CardState enum value PENDING_ISSUEPROCESSING across the OpenAPI spec sources, their generated bundles, and all Mintlify documentation snippets, aligning cards with the convention already used by quotes and transactions (where PROCESSING = Grid/issuer is doing work, PENDING_* = waiting on user/platform action).

  • OpenAPI source (openapi/components/schemas/cards/CardState.yaml, CardStateReason.yaml, cards.yaml, card-state-change.yaml): enum value, description table, and all prose references updated; bundles regenerated via make build with exactly 6 occurrences changed in each bundle and no reformatting.
  • Mintlify docs (mintlify/snippets/cards/ — 6 files): every in-prose, in-table, and lifecycle-diagram reference to PENDING_ISSUE replaced with PROCESSING; text-art alignment in the lifecycle diagram preserved.

Confidence Score: 5/5

Safe to merge — this is a pure documentation and schema rename with no application logic, and grep confirms zero remaining PENDING_ISSUE references across the entire repo.

Every occurrence of PENDING_ISSUE has been replaced in both the source OpenAPI files and the regenerated bundles, and the Mintlify doc snippets are fully updated. The generated bundles match exactly what make build would produce, the lifecycle diagram alignment is preserved, and no pre-existing logic or backend code is affected since the string is not yet emitted by any backend.

No files require special attention. The SDK regeneration in webdev/grid-api is a noted follow-up in a separate repo.

Important Files Changed

Filename Overview
openapi/components/schemas/cards/CardState.yaml Enum value and description table row renamed from PENDING_ISSUE to PROCESSING; clean change.
openapi/components/schemas/cards/CardStateReason.yaml ISSUER_REJECTED description updated to reference PROCESSING instead of PENDING_ISSUE.
openapi/paths/cards/cards.yaml POST /cards description updated to reference state: "PROCESSING".
openapi/webhooks/card-state-change.yaml Webhook description and example summary updated to PROCESSING; consistent with schema change.
openapi.yaml Generated bundle — diff matches exactly the 6 expected rename occurrences from make build; no extra reformatting.
mintlify/openapi.yaml Generated Mintlify bundle — identical set of 6 renames, consistent with openapi.yaml bundle.
mintlify/snippets/cards/issuing-cards.mdx Text-art lifecycle diagram and prose table updated; character alignment preserved (PROCESSING + 4 spaces = 14 chars, same as PENDING_ISSUE + 1 space).
mintlify/snippets/cards/webhooks.mdx Webhook event table and handling branch documentation updated to PROCESSING.
mintlify/snippets/cards/intro.mdx State table row updated from PENDING_ISSUE to PROCESSING.
mintlify/snippets/cards/quickstart.mdx Prose reference to state: "PROCESSING" updated correctly.
mintlify/snippets/cards/sandbox-testing.mdx Sandbox suffix table row updated to reference PROCESSING for the 001 suffix behavior.
mintlify/snippets/cards/implementation-overview.mdx Issuance lifecycle prose updated from PENDING_ISSUE to PROCESSING.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A([POST /cards]) --> B[PROCESSING\nIssuer provisioning in progress]
    B -->|CARD.STATE_CHANGE - success| C[ACTIVE\nCard live, can transact]
    B -->|CARD.STATE_CHANGE - ISSUER_REJECTED| F[CLOSED\nTerminal]
    C -->|PATCH state: FROZEN| D[FROZEN\nAuthorizations declined]
    D -->|PATCH state: ACTIVE| C
    C -->|PATCH state: CLOSED| F
    D -->|PATCH state: CLOSED| F
Loading
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
    A([POST /cards]) --> B[PROCESSING\nIssuer provisioning in progress]
    B -->|CARD.STATE_CHANGE - success| C[ACTIVE\nCard live, can transact]
    B -->|CARD.STATE_CHANGE - ISSUER_REJECTED| F[CLOSED\nTerminal]
    C -->|PATCH state: FROZEN| D[FROZEN\nAuthorizations declined]
    D -->|PATCH state: ACTIVE| C
    C -->|PATCH state: CLOSED| F
    D -->|PATCH state: CLOSED| F
Loading

Reviews (1): Last reviewed commit: "rename card status PENDING_ISSUE to PROC..." | Re-trigger Greptile

@AaryamanBhute AaryamanBhute merged commit f5e1eee into main Jun 16, 2026
16 of 17 checks passed

Copy link
Copy Markdown
Contributor Author

Merge activity

@AaryamanBhute AaryamanBhute deleted the 06-16-rename-card-status-pending-issue-to-processing branch June 16, 2026 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bolt breaking-change Introduces a breaking change to the OpenAPI spec

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants