Skip to content

feat(mwa-v2): add core type declarations and update .gitignore#3

Open
Zurcusa wants to merge 4 commits into
mainfrom
pr/3-mwa-v2-types
Open

feat(mwa-v2): add core type declarations and update .gitignore#3
Zurcusa wants to merge 4 commits into
mainfrom
pr/3-mwa-v2-types

Conversation

@Zurcusa
Copy link
Copy Markdown
Owner

@Zurcusa Zurcusa commented May 4, 2026

⚠️ NOTE: This is PR 1 of 3 in the MWA v2 stack. Pure additions — no existing code is modified.

Status Type ⚠️ Core Change Issue
Ready Feature No Partial for #272, #273

Problem

The MWA v2 protocol introduces per-account metadata, structured authorization caching, typed error codes, discriminated-union result types, and Sign-In With Solana (SIWS) payloads — none of which have type representations in the SDK today. The .gitignore is also missing Unity-generated file patterns.

Solution

Add 21 new C# files (+ Unity .meta files) declaring the v2 API surface. Update .gitignore with Unity-generated files, IDE exclusions, and sub-project patterns.

Domain types: AccountInfo, AuthorizationRecord, LogVerbosity, SendOptions, MobileWalletAdapterErrorCode, SignInPayload, SignInResult

Interfaces: IAuthorizationCache (addresses #272), IMobileWalletAdapterSession, ITransactionPayload

Result types (abstract class hierarchies):

  • DeauthorizeResult — FullyRevoked / LocalOnly / Failed
  • ReconnectResult — SilentSuccess / FreshAuthorized / NoCachedSession / Failed
  • SignAndSendTxResult — Success / UserDenied / InvalidPayloads / NotSubmitted / TooManyPayloads / ChainNotSupported / WalletUnreachable

Exceptions: InvalidAuthorizationException, JsonRpcException, TransportException, OperationInFlightException, CacheSchemaVersionMismatchException, ChainMismatchException

Other: LegacyTransactionPayload, AuthorizationHelpers (stub bodies filled in PR #4)

Other changes

  • Updated .gitignore with Unity-generated patterns and IDE exclusions

Deploy Notes

No new dependencies. All types are in the Solana.Unity.SolanaMobileStack namespace. Nothing references these types yet — the build stays green because this is purely additive.

Testing Matrix

Tested on Pixel 7 emulator and Solana Seeker (real device).

Wallets Tested

Wallet Networks
Seed Vault (Solana Phone) DevNet, MainNet
Phantom DevNet, MainNet
Solflare DevNet, MainNet
Backpack MainNet
Jupiter MainNet

Functionality Coverage

Feature Emulator (Pixel 7) Solana Seeker
Login Passed Passed
Disconnect Passed Passed
Reconnect Passed Passed
Deauthorize Passed Passed
Sign Transaction Passed Passed
Sign All Transactions Passed Passed
Sign Message Passed Passed
Sign and Send ⚠️ Backpack fails (see PR #5 Known Issue) ⚠️ Backpack fails (see PR #5 Known Issue)
Get Capabilities Passed Passed
Sign-In With Solana (SIWS) Passed Passed

@Zurcusa Zurcusa force-pushed the pr/3-mwa-v2-types branch from c7805ee to 745e98b Compare May 4, 2026 11:41
@Zurcusa Zurcusa force-pushed the pr/3-mwa-v2-types branch from 745e98b to 87ce578 Compare May 4, 2026 11:51
@Zurcusa Zurcusa force-pushed the pr/3-mwa-v2-types branch from 87ce578 to 44882b6 Compare May 4, 2026 12:09
@Zurcusa Zurcusa changed the base branch from pr/2-test-host to main May 4, 2026 12:12
@Zurcusa Zurcusa changed the title feat(mwa-v2): add core type declarations for MWA v2 protocol feat(mwa-v2): add core type declarations and update .gitignore May 4, 2026
@Zurcusa Zurcusa force-pushed the pr/3-mwa-v2-types branch from 2a6c921 to 74f57aa Compare May 7, 2026 11:26
@Zurcusa Zurcusa force-pushed the pr/3-mwa-v2-types branch from 74f57aa to 314f641 Compare May 11, 2026 13:51
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.

1 participant