metaplex-foundation / docs

docs.metaplex.com source code
https://docs.metaplex.com
44 stars 215 forks source link

Clarify wtf is "a mint" #244

Closed php4fan closed 2 years ago

php4fan commented 2 years ago

I'm reading the Metaplex docs and having a hard time understanding how the whole thing works.

When I get to here: https://docs.metaplex.com/architecture/contracts

for the first time I come across several sentences using the word "mint" as a noun:

All that you need to interact with [the Token Metadata contract] is your own mint for which you have the mint authority.

and

It allows you to decorate your mint

and

You can do this with any mint

and so on.

And I'm like "What the F is a mint"?

Yes I am new to Solana and Metaplex, but I have a fair understanding of how NFTs work in general in other blockchains, and in particular on Ethereum. I am used to the word "to mint" as a verb. To mint a token. But I've never heard of a mint.

So I get a sense that that is a concept that is built-in in Metaplex (or even in Solana? That seems unlikely, I don't see it at https://docs.solana.com/developing/programming-model/overview), but then I would expect it to be defined in Terminology, and it's not.

I really can't make sense of it. It doesn't seem to be (wrongly used as) a synonim of "token"; it doesn't seem to be "the act of minting"; sometimes it looks like it refers to "a bunch of tokens that you mint at some point"; at some point I thought it refers to a smart contract (i.e. program) that mints tokens.... but given how confusing and poorly structured the docs are in general, I am unable to even figure it out by exclusion from the context - because there are too many other concepts that are already on hold, waiting for more pieces of the puzzle to come together.

stegaBOB commented 2 years ago

Agreed. While clarifying what exactly a mint is would be helpful, I think the larger issues that you outlined is how all over the place and scattered our docs are, along with the fact that it sorta requires a lot of prior knowledge about stuff on Solana to even understand. We know its an issue and are working on making it a lot better.

As to what a mint is, it refers to the SPL token program, which is what the token metadata program works with. Each SPL token (be it USDC or each individual NFT), has a single mint account, which contains details about the token such as number of decimals and who can mint and stuff (and perhaps the total supply? I'd have to check the code for that). In addition, when a user actually holds a specific token, there's an additional token account that says what token its for (i.e., which mint address), who owns it, and how many of that token they actually own. Since each NFT is a unique token with a supply of 1, it each NFT has its own mint account (along with a token account for whoever is currently holding that token).

liang256 commented 2 years ago

Hi @php4fan, I'm also a newbie who is recently learning about Solana and its ecosystem and often feel confused about terms in this field. I recommend you go through this doc https://spl.solana.com/token which will give you the basic ideas of TOKEN in Solana.

ideas you will get:

Then you may feel better to back to the doc of Metaplex.

austbot commented 2 years ago

Thank you all, closing this for now.