user1002: I have a use case where I want to issue NFTs to users along with metadata (in the general sense of the term). The point of these NFTs is literally to hold that metadata - the user's results from participating in a race - not to display pictures/art in any way.
I later want the user to be able to provide these NFTs into a smart contract in order to prove their credentials (e.g. they are entering a marathon, which involves a smart contract that requires them to both pay an Ada fee, plus prove ownership of an NFT showing they have completed a marathon previously).
Transaction metadata is the 'workaround' used to associate metadata with art-based NFTs - "With this workaround of attaching metadata, third-party platforms like pool.pm can easily trace back to the last minting transaction, read the metadata, and query images and attributes accordingly. " (https://developers.cardano.org/docs/native-tokens/minting-nfts).
Transaction metadata is not currently usable within Plutus, however I believe in the future it will be possible to use it when creating transactions. Whether it will ever be possible to refer to it in a validator, I am not sure.
I have considered whether it would be possible to store the metadata in the datum of a UTXO holding the NFT in the user's wallet (a so called "communication" datum). However this feels fragile as I imagine you can't guarantee that it won't get lost, particularly if the UTXO also holds Ada that ends up getting spent.
Is there anything else I should be considering for this general requirement of "NFTs with metadata to be used during validation"?

user2248: I surely hope there's a better answer than mine, but, as a workaround, I believe one option would be to use the NFT TokenName as a metadata. For example, you could have a minting policy that would verify the conditions you provided and, if they met, use the user's PubKeyHash as the token name.
In the script validator (which will accept or reject the NFT) you could ensure that the NFT symbol is the same as the one from your script policy (ensuring conditions are met) and the token name the same as the user's PubKeyHash (making sure it was minted by him).

1002: <p>I have a <a href="https://www.distributedby.design/post/nfts-on-cardano-what-else-can-they-do" rel="noreferrer">use case</a> where I want to issue NFTs to users along with metadata (in the general sense of the term). The point of these NFTs is literally to hold that metadata - the user's results from participating in a race - not to display pictures/art in any way.</p>
<p>I later want the user to be able to provide these NFTs into a smart contract in order to prove their credentials (e.g. they are entering a marathon, which involves a smart contract that requires them to both pay an Ada fee, plus prove ownership of an NFT showing they have completed a marathon previously).</p>
<p>Transaction metadata is the 'workaround' used to associate metadata with art-based NFTs - &quot;With this workaround of attaching metadata, third-party platforms like pool.pm can easily trace back to the last minting transaction, read the metadata, and query images and attributes accordingly. &quot; (<a href="https://developers.cardano.org/docs/native-tokens/minting-nfts" rel="noreferrer">https://developers.cardano.org/docs/native-tokens/minting-nfts</a>).</p>
<p>Transaction metadata is not currently usable within Plutus, however I believe in the future it will be possible to use it when creating transactions. Whether it will ever be possible to refer to it in a validator, I am not sure.</p>
<p>I have considered whether it would be possible to store the metadata in the datum of a UTXO holding the NFT in the user's wallet (a so called &quot;communication&quot; datum). However this feels fragile as I imagine you can't guarantee that it won't get lost, particularly if the UTXO also holds Ada that ends up getting spent.</p>
<p>Is there anything else I should be considering for this general requirement of &quot;NFTs with metadata to be used during validation&quot;?</p>
 2248: <p>I surely hope there's a better answer than mine, but, as a workaround, I believe one option would be to use the NFT <code>TokenName</code> as a metadata. For example, you could have a minting policy that would verify the conditions you provided and, if they met, use the user's <code>PubKeyHash</code> as the token name.</p>
<p>In the script validator (which will accept or reject the NFT) you could ensure that the NFT symbol is the same as the one from your script policy (ensuring conditions are met) and the token name the same as the user's <code>PubKeyHash</code> (making sure it was minted by him).</p>
