lib.rs 592 B

12345678910111213141516171819202122232425
  1. #![allow(clippy::result_large_err)]
  2. use anchor_lang::prelude::*;
  3. use instructions::*;
  4. pub mod instructions;
  5. declare_id!("3LFrPHqwk5jMrmiz48BFj6NV2k4NjobgTe1jChzx3JGD");
  6. #[program]
  7. pub mod token_minter {
  8. use super::*;
  9. pub fn create_token(
  10. ctx: Context<CreateToken>,
  11. token_name: String,
  12. token_symbol: String,
  13. token_uri: String,
  14. ) -> Result<()> {
  15. create::create_token(ctx, token_name, token_symbol, token_uri)
  16. }
  17. pub fn mint_token(ctx: Context<MintToken>, amount: u64) -> Result<()> {
  18. mint::mint_token(ctx, amount)
  19. }
  20. }