Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Implement Token 22 Extensions for Mint and Token Accounts #347

Conversation

sunguru98
Copy link
Contributor

@sunguru98 sunguru98 commented Apr 28, 2024

This PR adds the functionality for metaboss to support Token22 for creating both mint and token accounts, via a json config file.

create fungible-22 allows you to create mint accounts. The following extensions are available.

{
  "close_authority": "",
  "permanent_delegate": "",
  "non_transferrable": true,
  // cannot be used if non_transferrable is set to true
  "transfer_fee": {
    "transfer_fee_config_authority": "",
    "withdraw_withheld_authority": "",
    "fee_basis_points": 100,
    "max_fee": 10
  },
  // cannot be used if non_transferrable is set to true
  "transfer_hook": {
    "program_id": "",
    "authority": ""
  },
  "interest_bearing": {
    "rate_authority": "",
    "rate": 0
  },
  "metadata": {
    "name": "",
    "symbol": "",
    "uri": "",
    "additional_metadata": [["", ""]]
  }
}
Screenshot 2024-04-28 at 9 01 21 PM

create fungible-token-22 allows the creation of token accounts. The following extensions are available.

{
  "require_memo": true,
  "cpi_guard": true
}
Screenshot 2024-04-28 at 9 06 10 PM

The mint fungible command now supports Token22 program as well

Screenshot 2024-04-28 at 9 12 11 PM

@samuelvanderwaal
Copy link
Owner

This looks good! Thanks for the PR and sorry it took me so long to review it.

@samuelvanderwaal samuelvanderwaal merged commit d63d50f into samuelvanderwaal:main Jun 1, 2024
3 checks passed
@sunguru98 sunguru98 deleted the feat/token-extensions-commands branch June 1, 2024 06:21
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