Skip to content

Comments

feat(ramps): surface transak errors for the consumer to read#8010

Merged
georgeweiler merged 4 commits intomainfrom
transak-service-errors
Feb 20, 2026
Merged

feat(ramps): surface transak errors for the consumer to read#8010
georgeweiler merged 4 commits intomainfrom
transak-service-errors

Conversation

@georgeweiler
Copy link
Contributor

@georgeweiler georgeweiler commented Feb 20, 2026

Explanation

Adds throwTransakApiError util which will better handle error surfacing so that consumers can display errors to the user related to their Transak user account.

References

Related mobile PR: MetaMask/metamask-mobile#26296

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

Low Risk
Scoped to error handling and test updates; behavior changes are limited to the shape/detail of thrown errors on failed Transak requests.

Overview
Surfaces richer Transak API failures by centralizing error handling into #throwTransakApiError, which reads the response body and (when possible) extracts Transak’s error.code into a thrown TransakApiError.

All Transak HTTP helpers (#transakGet/#transakPost/#transakPatch/#transakDelete) now use this unified error path instead of generic HttpError in some cases, and tests were added/updated to assert errorCode parsing and behavior when the error body isn’t JSON. Changelog updated to note improved TransakService error handling.

Written by Cursor Bugbot for commit c8bf1f9. This will update automatically on new commits. Configure here.

@georgeweiler georgeweiler requested a review from a team as a code owner February 20, 2026 20:35
@georgeweiler georgeweiler changed the title feat: surface transak errors for the consumer to read feat(ramps): surface transak errors for the consumer to read Feb 20, 2026
@georgeweiler georgeweiler requested a review from a team as a code owner February 20, 2026 20:43
@georgeweiler
Copy link
Contributor Author

@metamaskbot release-preview

AxelGes
AxelGes previously approved these changes Feb 20, 2026
@georgeweiler georgeweiler added this pull request to the merge queue Feb 20, 2026
Merged via the queue into main with commit 279eee0 Feb 20, 2026
310 checks passed
@georgeweiler georgeweiler deleted the transak-service-errors branch February 20, 2026 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants