Just a few questions about the Algorand smart contracts/ecosystem.
For someone coming from a solidity space on eth, one can store almost anything on the eth blockchain e.g fruit names with their categories.
On the Algorand blockchain is this also feasible?
Having an ordinary marketplace where one can upload fruits, for example, a (fruits marketplace) on the Algorand Blockchain. Not NFTs.
Assets on Algorand are not smart contracts but ASA, which are directly backed in layer 1.
You have some fields you can specify in an ASA.
However, we strongly recommend to follow the standard ARC-3.
(ARC-69 is an alternative to ARC-3 in case you want an NFT but I understand you don’t want an NFT.)
What do you mean by “not NFTs”?
If you mean the token is fungible and can have a large supply, you just need to specify a high supply.
Oh no, let me use a different example, can one create a smart contract on Algorand to create a marketplace to upload the price, name, description, category etc of a fruit for example.
I have only seen nft marketplaces on Algorand.
I am asking for that because of storage, can those details (the example above) be done on Algorand?
This is a perfect example to what I’m asking
Is it possible to recreate this with teal/pyteal on algorand?
No, Teal is more assembly than HLL and supports fewer data types than Solidity or Vyper. To the best of my knowledge, although faster and uses less gas/tx fee it doesn’t support key → value pair data types to enable abstract data storage and retrieval read.
@obi is right: you cannot do it directly right now.
You can simulate it manually, e.g., by creating one account per asset and storing description/name/… in the account local storage. The account would need to be rekeyed to the application account using the same ideas as in [NFT marketplace] general smart contract architecture question - #2 by fabrice (second bullet point)
Future developments of AVM may make this easier.
If you have less than 60 or so assets and if you can make decription/name/… fit 127 bytes, you can also just directly use the global storage.
You can use the ABI serialization format to store tuples of values such as (description,name,…):