Difficulty: Intermediate
Type: Feature
Recommended labels (if available in this repo): enhancement, sdk, membership
Background
The SDK roadmap listed in docs/CAMPAIGN_TASKS.md under 'Planned (not yet open)' includes a client.membership.getHistory() method that has not been implemented yet. Consumers can currently check current membership status via the access/membership services, but there is no way to retrieve a wallet's historical membership changes (joins, renewals, expirations, role changes over time).
Problem
Downstream apps (e.g. guildpass-mobile's access history screen, guildpass-integrations' member dashboard) need a client-side method to fetch a wallet's membership history from the core API, but no such method exists on GuildPassClient.
Expected Outcome
client.membership.getHistory(walletAddress, options?) returns a typed, paginated list of historical membership events for a wallet, consistent with the existing service patterns in src/access/access.service.ts.
Suggested Implementation
Add a getHistory method to a new or existing membership service module following the same request/response typing conventions as access.service.ts. Reuse the existing HTTP client/adapter pattern (ethers/viem adapters are unrelated — this is a REST call to the access API). Add pagination options (cursor or offset-based, matching whatever guildpass-core's API contract uses) and expose typed response shapes.
Acceptance Criteria
client.membership.getHistory() is implemented and exported from the client
- Method accepts a wallet address and optional pagination/filter options
- Response is fully typed (no
any)
- Unit tests cover successful history fetch, empty history, and HTTP error handling
pnpm test:run and pnpm typecheck pass
Likely Affected Files/Directories
src/access/access.service.ts
src/access/access.types.ts
src/client/GuildPassClient.ts
src/client/GuildPassClientBuilder.ts
Difficulty: Intermediate
Type: Feature
Recommended labels (if available in this repo):
enhancement,sdk,membershipBackground
The SDK roadmap listed in
docs/CAMPAIGN_TASKS.mdunder 'Planned (not yet open)' includes aclient.membership.getHistory()method that has not been implemented yet. Consumers can currently check current membership status via the access/membership services, but there is no way to retrieve a wallet's historical membership changes (joins, renewals, expirations, role changes over time).Problem
Downstream apps (e.g. guildpass-mobile's access history screen, guildpass-integrations' member dashboard) need a client-side method to fetch a wallet's membership history from the core API, but no such method exists on
GuildPassClient.Expected Outcome
client.membership.getHistory(walletAddress, options?)returns a typed, paginated list of historical membership events for a wallet, consistent with the existing service patterns insrc/access/access.service.ts.Suggested Implementation
Add a
getHistorymethod to a new or existing membership service module following the same request/response typing conventions asaccess.service.ts. Reuse the existing HTTP client/adapter pattern (ethers/viem adapters are unrelated — this is a REST call to the access API). Add pagination options (cursor or offset-based, matching whateverguildpass-core's API contract uses) and expose typed response shapes.Acceptance Criteria
client.membership.getHistory()is implemented and exported from the clientany)pnpm test:runandpnpm typecheckpassLikely Affected Files/Directories
src/access/access.service.tssrc/access/access.types.tssrc/client/GuildPassClient.tssrc/client/GuildPassClientBuilder.ts