Skip to content

SDK 0.3.2: stable requestId for applyCode retries - #4

Merged
cursor[bot] merged 1 commit into
mainfrom
cursor/sdk-0-3-2-redeem-request-id-7c10
Oct 10, 2026
Merged

cursor[bot] merged 1 commit into
mainfrom
cursor/sdk-0-3-2-redeem-request-id-7c10

Conversation

@KennyYe

@KennyYe KennyYe commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Additive 0.3.2 fix so retrying applyCode after a timeout (or app restart) does not create a duplicate attribution.

  • Send requestId (UUID v4) in the /redeemCode JSON body
  • One id per normalised code (uppercase, strip non-alphanumerics, max 24), persisted with install-state storage
  • Reuse on retry / restart; clear on definitive responses (2xx, unknown, inactive, wrong-environment) or when the code changes
  • Network / timeout / other non-definitive errors keep the pending id
  • No public signature changes
  • Bump sdkVersion / X-TapAppLink-SDK-Version / pubspec / README to 0.3.2

Do not merge or tag yet. Release after the server-side requestId handling is in prod.

Test plan

  • Local flutter test (retry reuse, restart reuse, new code, definitive clear)
  • CI green on this PR
  • Hold merge/tag until server is live
Open in Web Open in Cursor 

Send a persisted UUID requestId with /redeemCode so timeouts and
app restarts reuse the same attempt. Clear it on definitive responses
or when the code changes. Bump sdkVersion and docs to 0.3.2.

Co-authored-by: Kenny Ye <KennyYe@users.noreply.github.com>
@KennyYe
KennyYe marked this pull request as ready for review October 10, 2026 01:36
@cursor
cursor Bot merged commit 3200b34 into main Oct 10, 2026
2 checks passed
@cursor
cursor Bot deleted the cursor/sdk-0-3-2-redeem-request-id-7c10 branch October 10, 2026 01:36
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.

2 participants