# NFT Ecosystem

We built out this feature on the API to answer one question...

### What if you could build your entire NFT ecosystem through an API?

Naturally, that would be really cool, we're not going to handle full blown image or media uploads by default, this is handled through [the tools provided by nft.storage](https://nft.storage/docs/quickstart/#uploading-files--directories-via-the-nftup-application), or [using NFTup](https://nft.storage/docs/quickstart/#uploading-files--directories-via-the-nftup-application) for directories.

But with that said, V2 of the API provided these additional features:

* NFT creation, with automatic royalty fees of 5%
* Simple NFT minting with batch built-in
* Metadata generation with strict validation based on the [HIP412 specification](https://hips.hedera.com/hip/hip-412)
* Mirrornode compatibility, with retryable logic, in case [nodes have throttled](https://docs.hedera.com/guides/mirrornet/hedera-mirror-node)
* NFT token transfers
* **Exclusive** NFT pass claiming functionality, for ensuring that community members that own a pass can always claim their project tokens with no off-chain storage requirements

All this of course as a simple REST API developer tool for any developer, at any skill level.

For interrogating NFT data during development we recommend using [Gomint's NFT explorer](https://gomint.me/explore/NFT/?tokenId=0.0.732556\&network=mainnet) or [Hashscan](https://hashscan.io/#/) before viewing assets in [Hashpack](https://www.hashpack.app/).

## Understanding the basic flow

Below is the flow to take to start creating NFTs through the API, we will go into more details in the corresponding pages:

{% hint style="warning" %}
Note, that by using these tools for creating NFTs, we will add **5%** to the current royalty structure for secondary sales we will receive.

As a developer or project owner, you may fork our repositories and remove this additional royalty, however, you probably will **not** receive any support from the team and it will make Matt sad...

Our royalty accounts are as follows:

\
Testnet: 0.0.34319163

Mainnet: 0.0.1119570
{% endhint %}

### Create an NFT

An NFT can be created, before minting, to be viewable on hashgraph ledger.

{% content-ref url="nft-ecosystem/create-an-nft-collection" %}
[create-an-nft-collection](https://docs.trust.enterprises/rest-api/nft-ecosystem/create-an-nft-collection)
{% endcontent-ref %}

### Generate Metadata

Metadata is what we refer to a structure [that conforms to HIP412](https://hips.hedera.com/hip/hip-412), to ensure that it is processable for down-stream clients such as wallets like [Hashpack](https://www.hashpack.app/). Upon successful validation you will be provided a **CID** as a unique reference to an IPFS pin for minting NFTs.

{% content-ref url="nft-ecosystem/generate-metadata" %}
[generate-metadata](https://docs.trust.enterprises/rest-api/nft-ecosystem/generate-metadata)
{% endcontent-ref %}

{% hint style="info" %}
Based on feedback we might add metadata helpers for dealing with the output from mass images uploads through the tools provided through NFT storage.
{% endhint %}

### Mint an NFT

Minting a token with an amount and a CID, see above, you may also **batch mint 10** at a time if the CID you have used is the same

{% content-ref url="nft-ecosystem/mint-an-nft" %}
[mint-an-nft](https://docs.trust.enterprises/rest-api/nft-ecosystem/mint-an-nft)
{% endcontent-ref %}

### Transfer an NFT to an account

Lastly, you may transfer NFTs to an expected account, this is an attempted transfer and will check. If the treasury can send the NFT and will provide an additional general error if an account hasn't been associated with a given token.

{% content-ref url="nft-ecosystem/transfer-an-nft" %}
[transfer-an-nft](https://docs.trust.enterprises/rest-api/nft-ecosystem/transfer-an-nft)
{% endcontent-ref %}

### Claimable NFTs through Gated NFT passes

This is **our exclusive functionality** that enables projects to create NFT passes for their community and then automatically assign child tokens to their pool of NFT passes, through a fair claiming flow.

{% content-ref url="nft-ecosystem/claiming-nfts-through-passes" %}
[claiming-nfts-through-passes](https://docs.trust.enterprises/rest-api/nft-ecosystem/claiming-nfts-through-passes)
{% endcontent-ref %}

## Postman Documentation&#x20;

As before see the documentation in your local postman

[![Run in Postman](https://run.pstmn.io/button.svg)](https://app.getpostman.com/run-collection/416758-2c026d8f-795d-48c7-8554-4bbc17f797ad?action=collection%2Ffork\&collection-url=entityId%3D416758-2c026d8f-795d-48c7-8554-4bbc17f797ad%26entityType%3Dcollection#?env%5BTrust%20Enterprises%5D=W3sia2V5IjoiZG9tYWluIiwidmFsdWUiOiJodHRwczovL2hlZGVyYS1zZXJ2ZXJsZXNzLWNvbnNlbnN1cy52ZXJjZWwuYXBwIiwiZW5hYmxlZCI6dHJ1ZX0seyJrZXkiOiJhcGlfc2VjcmV0X2tleSIsInZhbHVlIjoiMTIzNDU2NzhhYmMiLCJlbmFibGVkIjp0cnVlfV0=)
