Skip to content

[S4] Add donate() function to API client #726

Description

@Akshola00

Description

Add the typed API function for donating to a pool.

Deliverables

  • donate(poolId: number, amount: number, tokenAddress: string): Promise<{ unsignedXdr: string }>
  • Calls POST /pools/:id/donate with JWT auth header
  • Throws typed error on 400 (pool closed, invalid amount) or 401 (not authenticated)
  • Exported from lib/api-client.ts
  • npm run build passes

Notes

Depends on #58 (JWT interceptor). Requires Stage 3 POST /pools/:id/donate.

Metadata

Metadata

Assignees

Labels

EasyFrontendStellar WaveIssues in the Stellar wave programstage-4Frontend-Backend integration

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions