Add HOLD KYB/KYC status and FAILED internal account status#658
Add HOLD KYB/KYC status and FAILED internal account status#658wuvictor-95 wants to merge 1 commit into
Conversation
Adds a FAILED value to InternalAccountStatus for accounts whose provisioning failed, and a HOLD value to KybStatus/KycStatus. HOLD is a state where a customer's information can be updated but cannot be resubmitted for verification until Grid releases the hold. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
✱ Stainless preview builds for gridThis PR will update the cli csharp go kotlin openapi php python ruby typescript Edit this comment to update them. They will appear in their respective SDK's changelogs. ✅ grid-openapi studio · code · diff
✅ grid-ruby studio · code · diff
✅ grid-go studio · code · diff
✅ grid-kotlin studio · code · diff
✅ grid-typescript studio · code · diff
✅ grid-python studio · code · diff
✅ grid-csharp studio · code · diff
✅ grid-php studio · code · diff
✅ grid-cli studio · code · diff
This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push. |
Greptile SummaryThis PR extends three OpenAPI schemas to support new compliance and provisioning states:
Confidence Score: 4/5Straightforward additive enum changes with no breaking modifications to existing values; the bundled files match the source changes. All three source schemas are correctly updated, and the two bundled files faithfully reflect those updates. The only rough edge is that KycStatus and KybStatus describe HOLD inline without documenting the four pre-existing enum values, while InternalAccountStatus in this same PR sets the stronger pattern of per-value bullet descriptions for every enum member. openapi/components/schemas/customers/KycStatus.yaml and KybStatus.yaml — the description section could be expanded to cover all enum values, not just HOLD.
|
| Filename | Overview |
|---|---|
| openapi/components/schemas/customers/KycStatus.yaml | Adds HOLD enum value; description documents HOLD inline but doesn't enumerate UNVERIFIED/PENDING/APPROVED/REJECTED the way InternalAccountStatus does |
| openapi/components/schemas/customers/KybStatus.yaml | Adds HOLD enum value; same documentation pattern as KycStatus — HOLD described inline, other values not enumerated |
| openapi/components/schemas/customers/InternalAccountStatus.yaml | Adds FAILED enum value with a well-formed per-value bullet description, consistent with the existing documentation style for this schema |
| openapi.yaml | Generated bundle — reflects all three enum additions correctly; appears regenerated via make build rather than hand-edited |
| mintlify/openapi.yaml | Mintlify copy of the generated bundle — identical changes to openapi.yaml, correctly reflecting all three new enum values |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
subgraph KYC/KYB Status
KV[UNVERIFIED] --> KP[PENDING]
KP --> KH[HOLD 🆕]
KP --> KA[APPROVED]
KP --> KR[REJECTED]
KH --> KP
KH --> KA
KH --> KR
end
subgraph Internal Account Status
IP[PENDING] --> IA[ACTIVE]
IP --> IF[FAILED 🆕]
IA --> IC[CLOSED]
IA --> IFZ[FROZEN]
IFZ --> IA
end
%%{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
subgraph KYC/KYB Status
KV[UNVERIFIED] --> KP[PENDING]
KP --> KH[HOLD 🆕]
KP --> KA[APPROVED]
KP --> KR[REJECTED]
KH --> KP
KH --> KA
KH --> KR
end
subgraph Internal Account Status
IP[PENDING] --> IA[ACTIVE]
IP --> IF[FAILED 🆕]
IA --> IC[CLOSED]
IA --> IFZ[FROZEN]
IFZ --> IA
end
Prompt To Fix All With AI
Fix the following 2 code review issues. Work through them one at a time, proposing concise fixes.
---
### Issue 1 of 2
openapi/components/schemas/customers/KycStatus.yaml:8-11
The description explains `HOLD` inline but leaves `UNVERIFIED`, `PENDING`, `APPROVED`, and `REJECTED` undocumented. `InternalAccountStatus` in the same PR uses a per-value bullet list for all values — applying the same pattern here makes the schema equally self-contained for API consumers who read only the KYC/KYB status field docs.
```suggestion
description: >-
The current KYC status of a customer.
- `UNVERIFIED`: The customer has not yet started the KYC process.
- `PENDING`: The customer's identity is under review.
- `APPROVED`: The customer has successfully passed KYC verification.
- `REJECTED`: The customer's KYC application was rejected.
- `HOLD`: The customer is placed on hold and may be required to update or
provide more information.
example: APPROVED
```
### Issue 2 of 2
openapi/components/schemas/customers/KybStatus.yaml:8-11
Same documentation gap as `KycStatus.yaml` — only `HOLD` is described inline while `UNVERIFIED`, `PENDING`, `APPROVED`, and `REJECTED` remain undocumented. `InternalAccountStatus` in this same PR demonstrates the preferred pattern of enumerating every value.
```suggestion
description: >-
The current KYB status of a business customer.
- `UNVERIFIED`: The business has not yet started the KYB process.
- `PENDING`: The business's identity is under review.
- `APPROVED`: The business has successfully passed KYB verification.
- `REJECTED`: The business's KYB application was rejected.
- `HOLD`: The customer is placed on hold and may be required to update or
provide more information.
example: APPROVED
```
Reviews (1): Last reviewed commit: "Add HOLD KYB/KYC status and FAILED inter..." | Re-trigger Greptile
| description: >- | ||
| The current KYC status of a customer. `HOLD` means the customer is placed on | ||
| hold and may be required to update or provide more information. | ||
| example: APPROVED |
There was a problem hiding this comment.
The description explains
HOLD inline but leaves UNVERIFIED, PENDING, APPROVED, and REJECTED undocumented. InternalAccountStatus in the same PR uses a per-value bullet list for all values — applying the same pattern here makes the schema equally self-contained for API consumers who read only the KYC/KYB status field docs.
| description: >- | |
| The current KYC status of a customer. `HOLD` means the customer is placed on | |
| hold and may be required to update or provide more information. | |
| example: APPROVED | |
| description: >- | |
| The current KYC status of a customer. | |
| - `UNVERIFIED`: The customer has not yet started the KYC process. | |
| - `PENDING`: The customer's identity is under review. | |
| - `APPROVED`: The customer has successfully passed KYC verification. | |
| - `REJECTED`: The customer's KYC application was rejected. | |
| - `HOLD`: The customer is placed on hold and may be required to update or | |
| provide more information. | |
| example: APPROVED |
Prompt To Fix With AI
This is a comment left during a code review.
Path: openapi/components/schemas/customers/KycStatus.yaml
Line: 8-11
Comment:
The description explains `HOLD` inline but leaves `UNVERIFIED`, `PENDING`, `APPROVED`, and `REJECTED` undocumented. `InternalAccountStatus` in the same PR uses a per-value bullet list for all values — applying the same pattern here makes the schema equally self-contained for API consumers who read only the KYC/KYB status field docs.
```suggestion
description: >-
The current KYC status of a customer.
- `UNVERIFIED`: The customer has not yet started the KYC process.
- `PENDING`: The customer's identity is under review.
- `APPROVED`: The customer has successfully passed KYC verification.
- `REJECTED`: The customer's KYC application was rejected.
- `HOLD`: The customer is placed on hold and may be required to update or
provide more information.
example: APPROVED
```
How can I resolve this? If you propose a fix, please make it concise.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
| description: >- | ||
| The current KYB status of a business customer. `HOLD` means the customer is | ||
| placed on hold and may be required to update or provide more information. | ||
| example: APPROVED |
There was a problem hiding this comment.
Same documentation gap as
KycStatus.yaml — only HOLD is described inline while UNVERIFIED, PENDING, APPROVED, and REJECTED remain undocumented. InternalAccountStatus in this same PR demonstrates the preferred pattern of enumerating every value.
| description: >- | |
| The current KYB status of a business customer. `HOLD` means the customer is | |
| placed on hold and may be required to update or provide more information. | |
| example: APPROVED | |
| description: >- | |
| The current KYB status of a business customer. | |
| - `UNVERIFIED`: The business has not yet started the KYB process. | |
| - `PENDING`: The business's identity is under review. | |
| - `APPROVED`: The business has successfully passed KYB verification. | |
| - `REJECTED`: The business's KYB application was rejected. | |
| - `HOLD`: The customer is placed on hold and may be required to update or | |
| provide more information. | |
| example: APPROVED |
Prompt To Fix With AI
This is a comment left during a code review.
Path: openapi/components/schemas/customers/KybStatus.yaml
Line: 8-11
Comment:
Same documentation gap as `KycStatus.yaml` — only `HOLD` is described inline while `UNVERIFIED`, `PENDING`, `APPROVED`, and `REJECTED` remain undocumented. `InternalAccountStatus` in this same PR demonstrates the preferred pattern of enumerating every value.
```suggestion
description: >-
The current KYB status of a business customer.
- `UNVERIFIED`: The business has not yet started the KYB process.
- `PENDING`: The business's identity is under review.
- `APPROVED`: The business has successfully passed KYB verification.
- `REJECTED`: The business's KYB application was rejected.
- `HOLD`: The customer is placed on hold and may be required to update or
provide more information.
example: APPROVED
```
How can I resolve this? If you propose a fix, please make it concise.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
There was a problem hiding this comment.
I agree with greptile here. Just a bit weird to have HOLD explicitly called out on its own.
| account in response to compliance or fraud signals; payments are blocked | ||
| while the account remains frozen. | ||
|
|
||
| - `FAILED`: The account could not be provisioned. Grid was unable to create |
There was a problem hiding this comment.
Is it worth also adding a failureReason or errorMessage or something?
| description: >- | ||
| The current KYB status of a business customer. `HOLD` means the customer is | ||
| placed on hold and may be required to update or provide more information. | ||
| example: APPROVED |
There was a problem hiding this comment.
I agree with greptile here. Just a bit weird to have HOLD explicitly called out on its own.
Summary
FAILEDtoInternalAccountStatusfor internal accounts whose provisioning failed and require remediation.HOLDtoKybStatusandKycStatus.HOLDmeans the customer is placed on hold and may be required to update or provide more information.Notes
Consumed by webdev via
grid-api/update_schema.shto regenerate the vendored Python client. Supports two stacked webdev PRs: internal-account failure handling (FAILED) and the KYC/KYBHOLDflow.🤖 Generated with Claude Code