# symbol-nft-decoder

> SDK to decode On-Chain-NFT data from Symbol Blockchain

Latest version **0.2.2** (published 2022-02-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install symbol-nft-decoder
pnpm add symbol-nft-decoder
yarn add symbol-nft-decoder
bun add symbol-nft-decoder
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.2 |
| Published | 2022-02-07 |
| First published | 2022-02-05 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 3 |
| Unpacked size | 122 KB |
| Known vulnerabilities | 0 (+23 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | next-web-technology |
| Maintainers | next-web-technology |
| Keywords | blockchain, symbol, nft, sdk |

## Links

- npm: https://www.npmjs.com/package/symbol-nft-decoder
- Repository: https://github.com/next-web-technology/symbol-nft-decoder
- Homepage: https://github.com/next-web-technology/symbol-nft-decoder#readme
- Issues: https://github.com/next-web-technology/symbol-nft-decoder/issues
- npm.io page: https://npm.io/package/symbol-nft-decoder

## Dependencies (3)

- [rxjs](https://npm.io/package/rxjs.md) ^7.5.2
- [axios](https://npm.io/package/axios.md) ^0.25.0
- [symbol-sdk](https://npm.io/package/symbol-sdk.md) ^1.0.3

## Recent versions

- 0.2.2 (latest) — 2022-02-07
- 0.2.1 — 2022-02-07
- 0.2.0 — 2022-02-07
- 0.1.6 — 2022-02-05
- 0.1.5 — 2022-02-05
- 0.1.4 — 2022-02-05
- 0.1.3 — 2022-02-05
- 0.1.2 — 2022-02-05
- 0.1.1 — 2022-02-05

## README

# symbol-nft-decoder

[![CI Jest](https://github.com/next-web-technology/symbol-nft-decoder/actions/workflows/ci-jest.yml/badge.svg)](https://github.com/next-web-technology/symbol-nft-decoder/actions/workflows/ci-jest.yml)
[![CD npm publish](https://github.com/next-web-technology/symbol-nft-decoder/actions/workflows/cd-npm-publish.yml/badge.svg)](https://github.com/next-web-technology/symbol-nft-decoder/actions/workflows/cd-npm-publish.yml)

SDK to decode NFT data from Symbol Blockchain

## Note

The quality of this implementation is very experimental level at this time, so there is a high possibility that it will not work properly.

## Install

```shell
npm i symbol-nft-decoder

```

## Usage

### COMSA

```ts
import { comsa } from "symbol-nft-decoder";

(async () => {
  const mosaicIdHex: string = "YOUR_COMSA_NFT_MOSAIC_ID";
  const comsaNft = await comsa.resolve(mosaicIdHex);
  if (comsaNft === undefined) {
    console.error("Some error!");
    return;
  }
  if (comsaNft.dataUrl === undefined) {
    console.error("The mosaic is not COMSA NFT!");
    return;
  }
  const dataUrl = comsaNft.dataUrl; // Now, you can use this data for NFT viewer.
})();
```

### NEMber Art

```ts
import { nemberArt } from "symbol-nft-decoder";

(async () => {
  const mosaicIdHex: string = "YOUR_NEMber_Art_NFT_MOSAIC_ID";
  const nemberArtNft = await nemberArt.resolve(mosaicIdHex);
  if (nemberArtNft === undefined) {
    console.error("Some error!");
    return;
  }
  if (nemberArtNft.ipfsUrl === undefined) {
    console.error("The mosaic is not NEMber Art NFT!");
    return;
  }
  const ipfsUrl = nemberArtNft.dataUrl; // Now, you can use this URL for NFT viewer.
})();
```

### NFT Drive

```ts
import { nftDrive } from "symbol-nft-decoder";

(async () => {
  const mosaicIdHex: string = "YOUR_NFT_DRIVE_MOSAIC_ID";
  const nftDrive = await nftDrive.resolve(mosaicIdHex);
  if (nftDrive === undefined) {
    console.error("Some error!");
    return;
  }
  if (nftDrive.ipfsUrl === undefined) {
    console.error("The mosaic is not NFT Drive NFT!");
    return;
  }
  const dataUrl = nftDrive.dataUrl; // Now, you can use this data for NFT viewer.
})();
```

## Reference

The following article is very helpful. Thank you very much.

[https://qiita.com/nem_takanobu/items/67567eff96da6daf7456](https://qiita.com/nem_takanobu/items/67567eff96da6daf7456)

---
_Source: https://npm.io/package/symbol-nft-decoder · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
