Skip to content

feat: Add MPToken API support for dApps#441

Open
RomThpt wants to merge 1 commit intoGemWallet:masterfrom
XRPL-Commons:pr/mptoken-api
Open

feat: Add MPToken API support for dApps#441
RomThpt wants to merge 1 commit intoGemWallet:masterfrom
XRPL-Commons:pr/mptoken-api

Conversation

@RomThpt
Copy link

@RomThpt RomThpt commented Jan 12, 2026

Summary

  • Add MPToken API functions for dApps to interact with Multi-Purpose Tokens
  • Provides complete API coverage for all MPToken transaction types

New API Functions

authorizeMPToken

Allows users to authorize holding a specific MPToken.

createMPTokenIssuance

Allows issuers to create new MPToken issuances with configurable properties:

  • Asset scale (decimal places)
  • Maximum amount (supply cap)
  • Transfer fee
  • Metadata (XLS-89 compliant)
  • Capability flags (lock, auth, escrow, trade, transfer, clawback)

destroyMPTokenIssuance

Allows issuers to permanently destroy an MPToken issuance (when supply is zero).

setMPTokenIssuance

Allows issuers to modify issuance settings, specifically to lock/unlock tokens for specific holders.

Type Definitions

All request/response types follow the existing patterns:

  • AuthorizeMPTokenRequest/Response
  • CreateMPTokenIssuanceRequest/Response
  • DestroyMPTokenIssuanceRequest/Response
  • SetMPTokenIssuanceRequest/Response

Message Types

Added V3 message types for all operations:

  • REQUEST_AUTHORIZE_MPTOKEN/V3
  • REQUEST_CREATE_MPTOKEN_ISSUANCE/V3
  • REQUEST_DESTROY_MPTOKEN_ISSUANCE/V3
  • REQUEST_SET_MPTOKEN_ISSUANCE/V3

Test plan

  • Verify authorizeMPToken API works correctly
  • Verify createMPTokenIssuance API works correctly
  • Verify destroyMPTokenIssuance API works correctly
  • Verify setMPTokenIssuance API works correctly
  • Verify TypeScript types are correctly exported

- Add authorizeMPToken API function for token authorization
- Add createMPTokenIssuance API function to create token issuances
- Add destroyMPTokenIssuance API function to destroy issuances
- Add setMPTokenIssuance API function to lock/unlock holder tokens

Added types:
- AuthorizeMPTokenRequest/Response
- CreateMPTokenIssuanceRequest/Response
- DestroyMPTokenIssuanceRequest/Response
- SetMPTokenIssuanceRequest/Response

Message types updated for all MPToken operations.
@FlorianBouron FlorianBouron self-requested a review February 11, 2026 05:05
@FlorianBouron FlorianBouron self-assigned this Feb 11, 2026
@FlorianBouron FlorianBouron added the enhancement New feature or request label Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants