Update cards, accounts and users documentation - #253
Open
ricardobcl wants to merge 3 commits into
Open
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the API reference documentation for Cards, Accounts, and Users to match current API behavior (as verified against uphold/backend master), removing outdated statements and aligning examples/parameter descriptions with what the endpoints actually return/accept.
Changes:
- Updated Cards docs to reflect on-demand address creation, expanded filtering/sorting docs, clarified
:idresolution, and documented tag-based networks andsettings.positiondeprecation behavior. - Updated Accounts docs to reflect current account types/filters and response fields, and corrected table/content typos.
- Updated Users docs to correct
/meand/me/phonesresponse examples/behavior (including OAuth vs email/password shapes) and removed obsolete guidance.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
_cards.md |
Aligns Cards endpoint descriptions, parameters, and examples with current address creation, filtering/sorting, and response behavior. |
_accounts.md |
Updates account type narrative/filters and response examples to match current API output; fixes table/typos. |
_users.md |
Corrects /me and /me/phones documentation and examples, including auth-dependent response shapes and removed fields. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes drift between the Cards, Accounts and Users pages and the current API behavior, verified against
uphold/backendmaster._cards.mdinterledger): valid values are the networks of the cryptocurrencies available to the user; current examples given instead of a fixed list.tagproperty applies to all tag-based networks —stellar,tonandxrp-ledger— not just the XRP Ledger.settings.positionis a deprecated no-op: it is silently ignored on update and always returned as0; examples and the Update Card table now reflect this.:idresolves by card ID or any of the card's crypto addresses (any network), not just "its bitcoin address".currencyas required andlabelas optional (with the default label behavior), and documentssettings.starred.id:filter and thesort/direction/normalizedCurrencyquery parameters.wrappedSegWit/nativeSegWitformats (legacypubkeyhashentries are filtered out for bitcoin/litecoin).\continuation)._accounts.mdtype(fps,swiftandwirecan appear alongsideach/sepa), andexchangeaccounts exist; the deposits/withdrawals table is scoped to the common types. The card row's "Withdrawals: No" now carries a footnote pointing at OCT push-to-card settlement, resolving an internal contradiction with the Approved cards table.status: expired/failed/ok/pending — withokas the unstated default;type: bank/card/exchange plus deprecated ach/fps/sepa) and that swift/wire appear in responses but are not filterable.providerand the type-specific fields (bic/ibanfor sepa, masked numbers for ach,cardNumberMasked/expiryDatefor card)._users.mdGET /me/phones: the example paired a Bearer request with the response shape that is only returned for email/password authentication. OAuth requests actually receive unmasked{country, e164, id}items — both shapes are now documented, and thephones:readscope aside was added.GET /meexample: added missing private-response fields (id,fullName,identityCountry,type,balances.available/pending, per-currencyavailable).cardsproperty "will be removed" → has been removed; dropped the obsolete large-payload warning.Notes for reviewers
DELETE /v0/me/accounts/:id,PATCH /v0/me/accounts/:id(label),PATCH /v0/me,GET /v0/me/features,POST /v0/me/cards/:card/addresses/:address/sign(feature-gated),DELETE /v0/me/phones/:phone.Related issues
Follow-up to #250 (documentation audit against
uphold/backendmaster).Impacted areas
Cards, Accounts and Users pages of the API reference.
Steps to reproduce or test
Development
Every claim was traced to the enforcing code in
uphold/backendmaster (card/account/user-phone controllers, managers, model masks and their tests).QA
Render the three pages; optionally verify
GET /me/phoneswith a Bearer token returns unmasked numbers and that creating a card address on an unsupported network is rejected.Checklist
Breaking Changeif it applies.package.json.Deploy notes
N/A — no files added or removed, so no slate index changes are needed.
🤖 Generated with Claude Code