Repository navigation
fix(issuing): map mid_limit and complete card control and card create responses - #622
Conversation
🔴 Risk Classification: MAJORApproval route: AI Review + Human Approval Required Classification reasons
Operational gates
Files analysed: 19 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟢 Advisory review: Looks good to meThis PR still needs a human approval — wall-e cannot auto-approve it. For what it's worth, I read the diff and found nothing I'd block on. This PR fixes the mid_limit mapping bug in both control response hierarchies, adds amount_remaining to VelocityLimit, fixes the CardControlsResponseConverter discriminator to read control_type first, promotes AbstractCardControlResponse to extend Resource, and adds Scheme to AbstractCardCreateResponse — all with new roundtrip serialization tests covering each subtype. The changes are internally consistent and match the stated intent. What I checked
This is not an approval. wall-e cannot auto-approve this PR — it is an opinion to help whoever does. Advisory review · us.anthropic.claude-sonnet-4-6 · wall-e 2026.06.19-02 |
…onses MidCardControlResponse now exposes MidLimit mapped to mid_limit; the old VelocityLimit property is obsolete and forwards to MidLimit. VelocityLimit gains AmountRemaining (response only, null on requests). Complete doc comments on the control response types and add serialization tests.
…l links MidCardControlsResponse now exposes MidLimit mapped to mid_limit; the old VelocityLimit property is obsolete and forwards to MidLimit. Card control responses extend Resource so the create operation returns _links. Complete doc comments and add serialization tests.
The converter for the controls returned when a card is created looked for a type field, which the API does not send for controls, so any card created with controls failed to deserialize. It now reads control_type and falls back to type.
Add scheme to the card create response, complete its doc comments, and deprecate target_id, created_date and last_modified_date on the controls returned with a created card, since the API does not return them there. Serialization tests cover every property for virtual and physical cards.
2df8540 to
edf1e4a
Compare
🔴 Risk Classification: MAJORApproval route: AI Review + Human Approval Required Classification reasons
Operational gates
Files analysed: 19 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
|




Summary
Fixes and completes the issuing card control and card create responses against the API reference.
mid_limitwas never read (the property was mapped tovelocity_limit), card create responses carrying controls failed to deserialize, and several properties were missing.Changes
MidCardControlResponse: addsMidLimitmapped tomid_limitVelocityLimit: addsAmountRemaining(long?), null on requests and never sentVelocityLimit,MccLimit,MidLimit,VelocityWindow: doc comments completedControlsSerializationTest(new): each subtype from the API reference example, roundtrip, list response,_linkson create, deprecated alias,amount_remainingabsent on requestsAlso fixed while here
AbstractCardControlResponsenow extendsResource, like the rest of the SDK's responses, so the create control response exposes_linksCardControlsResponseConverterread the subtype fromtype, but card create controls carrycontrol_type; any card create response with controls threwNotImplementedException. It now readscontrol_typeand falls back totypeMidCardControlsResponse(card create controls): addsMidLimitmapped tomid_limit, same bug as aboveAbstractCardCreateResponse: addsScheme; doc comments on the card create response classes andCredentialsrewritten with the API reference constraintsCardCreateResponseSerializationTest(new): virtual and physical card create examples, full roundtrips, controls with all three typesDeprecated
MidCardControlResponse.VelocityLimitandMidCardControlsResponse.VelocityLimit: useMidLimit. They now forward toMidLimit, so existing callers start getting the valueAbstractCardControlsResponse.TargetId,CreatedDate,LastModifiedDate: not returned by the API in the card create responseAll of them will be removed in the next major version.
API Reference
PUT /issuing/controls/{controlId},GET /issuing/controls/{controlId},GET /issuing/controls,POST /issuing/controlsPOST /issuing/cards(add-card-response, add-virtual-card-response, add-physical-card-response)Breaking changes
None. Deprecated members keep working until the next major version.
README
No change needed.