npm i
Create .env file, you can copy test credentials from the .env.example
npm run start
- Your NFT collection should be a “sub-collection” of Bored Ape NFT collection
- You should fetch the Bored Apes Yacht Club collection (BAYC) in an array
- Then filter it, to keep only the items having their index a multiple of 100 to form your collection (so you should end up with only 100 items, all indexes ending with '00’.)
- Clean the array from anything you won’t need for this exercise (metadata, etc..)
- At this stage you only need, for each item, an identifier, and its rarity traits
- Create an algorithm to rank your collection by rarity considering that :
- You can’t use any existing rarity ranking dataset, you need to write your own logic with what you have here.
- each rarity traits brings a certain value, and the more rare this trait is amongst the collection, the more value it brings. Figure out a way to give values to this, and appreciate each items value/rarity. Try to achieve this appreciation in the most logic way.
- You can only use js (node.js) or php.
- For the data handling, you can use native arrays and json format.
- The algorithm should then be able to accept any well formatted similar array of a collection, no matter the number or items.