Repository navigation
MSD-14650: Add an API version option, defaulting to 2026-10 - #149
Merged
PeterOcansey merged 5 commits intoNov 20, 2026
Merged
PeterOcansey merged 5 commits into
PeterOcansey merged 5 commits into
Conversation
…pin-an-api-version-in-the-sdks-cli-and-mcp # Conflicts: # src/test/java/com/mailersend/sdk/tests/EmailsTest.java
PeterOcansey
marked this pull request as ready for review
November 18, 2026 10:21
[High risk] The change moves every endpoint's default from v1 to 2026-10 for all SDK users, and the only support for that is the description's claim that 2026-10 returns the same responses as v1; the review read no changelog or upstream source for that version, so a field or behavior difference would break every caller silently on upgrade. The Account.java gap from the last review is closed by the diff, which now calls setApiVersion there, and the grep found no other MailerSendApi call site missing it. Risk … FindingsFixed since the last review (1)
SummaryAdds setApiVersion and defaults SDK requests to API version 2026-10
What's good
Review context · 1/5 commands
Reviews (4) · Last reviewed commit: "Request the account with the configured..." · claude-sonnet-5-5 |
JoaoFSCruz
approved these changes
Nov 20, 2026
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.
Summary
Adds
setApiVersionso requests can be pinned to a dated API version. Part of MSD-14650.Changes
2026-10by default, which returns the same responses asv1.ms.setApiVersion("v1")changes the version, andgetApiVersion()reads it back. It throwsIllegalArgumentExceptionfor anything that isn'tv1orYYYY-MM.MailerSendApi./v1/when it looks up recordings, so the existing fixtures still match.