Introduction
API Documentation of Funq
Base url : https://api-nft.funq.club/graphql/nft-middleware
Admin
All the APIs related to admin goes here
Login
This API is for login to admin account
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/admin | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
admin_login(email: "nftadmin@gmail.com", password: "nftadmin@123") {
message
token
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| string | email of the admin | ✔ | |
| password | string | password of the admin | ✔ |
Success
{
"data": {
"admin_login": {
"message": "Login success",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1lIjoiYWRtaW4iLCJhY2NvdW50VHlwZSI6ImFkbWluIiwiaWF0IjoxNjUyMzI4MjAyLCJleHAiOjE2NTIzNDk4MDJ9.qPBFexWB-bYK3P5o9SvoJIiUABnJJ80baKqfw8Uj6Hw"
}
}
}
Error
{
"errors": [
{
"message": "Incorrect email address",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["admin_login"]
}
],
"data": {
"admin_login": null
}
}
{
"errors": [
{
"message": "Incorrect password",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["admin_login"]
}
],
"data": {
"admin_login": null
}
}
Fetch All Creators
This API is for to get list of all creators
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/admin | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | admin token |
Request
{
list_all_creators(page_size: 10, page_number: 1) {
message
data {
_id
name
email
img
wallet_id {
_id
wallet_id
}
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
Success
{
"data": {
"list_all_creators": {
"message": "data listed",
"data": [
{
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com",
"img": null,
"wallet_id": {
"_id": "6229df0fcb68a946e41b8421",
"wallet_id": "EnbSFnpMCQz7NzmfuKpPF1u4B8htaA19iYVkkrJi1aPy"
}
},
{
"_id": "62469e32f63e08df6e01159f",
"name": "jimshad",
"email": "jimshaddb@gmail.com",
"img": null,
"wallet_id": {
"_id": "6246b6eef63e08baf90115b8",
"wallet_id": "HrVUNq8PyKwym8dTwdBe7gHmaV3UWBkxztmBttHKPQX3"
}
}
],
"hasMore": false
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_creators"]
}
],
"data": {
"list_all_creators": null
}
}
Fetch All NFTs
This API is for to get list of all NFts
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/admin | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | admin token |
Request
{
list_all_nfts(page_size: 10, page_number: 1, status: "all", creator: "") {
message
data {
_id
name
description
art_url
royalty_percentage
nft_id
status
is_sold
creator_id {
_id
name
email
}
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
| status | string | to filter data based on NFT status | ✘ |
| creator | string | _id of the creator to get NFTs created by the given creator | ✘ |
Success
{
"data": {
"list_all_nfts": {
"message": "data listed",
"data": [
{
"_id": "624fbdc6521415d06a5087cc",
"name": "Boy",
"description": "Cartoon character",
"art_url": "https://nft-store-assets.s3.amazonaws.com/4eb0dd60-597c-4291-b19e-75e6e378289d.png",
"royalty_percentage": 0,
"nft_id": "FWz7BCZvkJiib9K7NuNGaH12xa51ggZesoqENaM7We9L",
"status": "sold",
"is_sold": true,
"creator_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
}
},
{
"_id": "624fbf7a52141537ef508815",
"name": "Man with Glasses",
"description": "Man cartoon",
"art_url": "https://nft-store-assets.s3.amazonaws.com/2c408c83-0000-48fe-9ea5-d60c4251e360.png",
"royalty_percentage": 1,
"nft_id": "56QzcVEztAGFXr17ow3SBvmPvt7rKaQzMN8d4Ny3zzSo",
"status": "sold",
"is_sold": true,
"creator_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
}
}
],
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_nfts"]
}
],
"data": {
"list_all_nfts": null
}
}
Fetch All Wallets
This API is for to get list of all wallets
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/admin | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | admin token |
Request
{
list_all_wallets(page_size: 2, page_number: 1) {
message
data {
_id
wallet_id
is_linked
user_id {
_id
name
email
}
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
Success
{
"data": {
"list_all_wallets": {
"message": "data listed",
"data": [
{
"_id": "62579d28ba8a2b819c325d94",
"wallet_id": "4nWNM7zdy9gtgpiURL1e9e8SmEneUHGx3qnEnqWBF5Qr",
"is_linked": true,
"user_id": {
"_id": "624fcb2b521415c21a508ac5",
"name": "Nicky Jacob",
"email": "nickyjacob@gmail.com"
}
},
{
"_id": "6246b6eef63e08baf90115b8",
"wallet_id": "HrVUNq8PyKwym8dTwdBe7gHmaV3UWBkxztmBttHKPQX3",
"is_linked": true,
"user_id": {
"_id": "62469e32f63e08df6e01159f",
"name": "jimshad",
"email": "jimshaddb@gmail.com"
}
}
],
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_wallets"]
}
],
"data": {
"list_all_wallets": null
}
}
Fetch Ledger Wallet Details
This API is for to get details of the ledger wallet
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/admin | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | admin token |
Request
{
list_ledger_details {
wallet_address
wallet_balance
}
}
Success
{
"data": {
"list_ledger_details": {
"wallet_address": "HMo5HENvpN42pBoeXLG5kwHa4XTBdjxUmkPYTyQjNkft",
"wallet_balance": 23.3
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 2
}
],
"path": ["list_ledger_details"]
}
],
"data": {
"list_ledger_details": null
}
}
Dashboard
All the APIs related to dashboard goes here
Send OTP
This API is for to send an OTP to the email address for login
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | MUTATION | ||
| content-type | string | JSON | application/json |
Request
mutation {
send_otp(email: "sachinsuresh704@gmail.com") {
message
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| string | email of the user | ✔ |
Success
{
"data": {
"send_otp": {
"message": "OTP sent successfully"
}
}
}
Error
Login With OTP
This API is for logging into the user account
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
login_with_otp(email: "sachinsuresh704@gmail.com", otp: "12345") {
message
token
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| string | email of the user | ✔ | |
| otp | string | OTP received in the email | ✔ |
Success
{
"data": {
"login_with_otp": {
"message": "Login success",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMjk5YzkyNTRmNmMyYmNkNGIyZjA5YSIsIm5hbWUiOiJTYWNoaW4gVCBTIiwiYWNjb3VudFR5cGUiOiJjcmVhdG9yIiwiaWF0IjoxNjUyMzMxMjg1LCJleHAiOjE2NTIzNTI4ODV9.W3iuq0X7mSCQTC7c4D38rXIe5NgX0A6LgoIxoMwoJAo"
}
}
}
Error
{
"errors": [
{
"message": "Incorrect OTP",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["login_with_otp"]
}
],
"data": {
"login_with_otp": null
}
}
Fetch All NFTs
This API is for to get list of all NFTs
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | creator token |
Request
{
list_all_nfts(page_size: 2, page_number: 1, status: "all") {
message
data {
_id
name
description
art_url
nft_id
status
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
| status | string | to filter data based on NFT status | ✘ |
Success
{
"data": {
"list_all_nfts": {
"message": "data listed",
"data": [
{
"_id": "624fc253521415614f508933",
"name": "Old man",
"description": "Old man cartoon character",
"art_url": "https://nft-store-assets.s3.amazonaws.com/033d711b-5554-47c2-8c7f-41e935cab405.png",
"nft_id": "2iRD8A88h1SRkK1Hhra53jqnfEkhXx5mK58PvLb5YTRW",
"status": "sold"
},
{
"_id": "6253ec74fb9f6b511cf05fbf",
"name": "Boy",
"description": "cartoon boy",
"art_url": "https://nft-store-assets.s3.amazonaws.com/0c3a1492-d05a-4299-ac87-44a9a6c72950.png",
"nft_id": "J7jzYCEi3sFdiH8vs14Saabw3joB8rFzTuraMQecxNpg",
"status": "sold"
}
],
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_nfts"]
}
],
"data": {
"list_all_nfts": null
}
}
Fetch NFT Details
This API is for to get details of an NFT
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | creator token |
Request
{
list_nft_details(_id: "624fc253521415614f508933") {
message
data {
_id
name
description
update_authority
art_url
royalty_percentage
nft_id
is_for_sale
selling_price
status
creator_id {
_id
name
email
}
owner_id {
_id
name
email
}
}
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| _id | string | _id of the NFT | ✔ |
Success
{
"data": {
"list_nft_details": {
"message": "data listed",
"data": {
"_id": "624fc253521415614f508933",
"name": "Old man",
"description": "Old man cartoon character",
"update_authority": "62299c9254f6c2bcd4b2f09a",
"art_url": "https://nft-store-assets.s3.amazonaws.com/033d711b-5554-47c2-8c7f-41e935cab405.png",
"royalty_percentage": 0,
"nft_id": "2iRD8A88h1SRkK1Hhra53jqnfEkhXx5mK58PvLb5YTRW",
"is_for_sale": false,
"selling_price": 0,
"status": "sold",
"creator_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
},
"owner_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
}
}
}
}
}
Error
{
"errors": [
{
"message": "art not found",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_nft_details"]
}
],
"data": {
"list_nft_details": null
}
}
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_nft_details"]
}
],
"data": {
"list_nft_details": null
}
}
Fetch User Profile
This API is for to get profile details of a users
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | creator token |
Request
{
view_profile {
message
data {
_id
name
email
img
is_creator
acc_balance
funq_credits
wallet_address
}
}
}
Success
{
"data": {
"view_profile": {
"message": "data listed",
"data": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com",
"img": null,
"is_creator": true,
"acc_balance": 2125523918.95,
"funq_credits": 35,
"wallet_address": "EnbSFnpMCQz7NzmfuKpPF1u4B8htaA19iYVkkrJi1aPy"
}
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["view_profile"]
}
],
"data": {
"view_profile": null
}
}
Fetch All Transactions
This API is for to get list of all Transactions
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | creator token |
Request
{
list_all_transactions(page_size: 2, page_number: 1, tag: "nft") {
message
data {
_id
txn_id
type
tag
nft_id
status
amount
to
from
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
| tag | string | to filter data based on txn type | ✘ |
Success
{
"data": {
"list_all_transactions": {
"message": "data listed",
"data": [
{
"_id": "62789ef3c048d385d34dc603",
"txn_id": "7305e946-cca5-4904-9694-10474e66a364",
"type": "sold",
"tag": "nft",
"nft_id": "2iRD8A88h1SRkK1Hhra53jqnfEkhXx5mK58PvLb5YTRW",
"status": "success",
"amount": 0.04,
"to": "sachinsuresh704@gmail.com",
"from": "9b3RBztwiSM4DFvoHtr6nENRZxfQkmJcfxY4VSWVSBrH"
},
{
"_id": "627899c6c048d306984dc5ce",
"txn_id": "eb8c0491-8cea-4dce-8e7b-161c4682d641",
"type": "sold",
"tag": "nft",
"nft_id": "J7jzYCEi3sFdiH8vs14Saabw3joB8rFzTuraMQecxNpg",
"status": "success",
"amount": 0.03,
"to": "sachinsuresh704@gmail.com",
"from": "9b3RBztwiSM4DFvoHtr6nENRZxfQkmJcfxY4VSWVSBrH"
}
],
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 2
}
],
"path": ["list_all_transactions"]
}
],
"data": {
"list_all_transactions": null
}
}
Fetch Funq Credits
This API is for to get total funq credits available for the user
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/creators | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | creator token |
Request
{
show_funq_credits {
message
data {
credits
}
}
}
Success
{
"data": {
"show_funq_credits": {
"message": "data listed",
"data": {
"credits": 35
}
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["show_funq_credits"]
}
],
"data": {
"show_funq_credits": null
}
}
Marketplace
All the APIs related to marketplace goes here
Send OTP
This API is for to send an OTP to the email address for login
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | MUTATION | ||
| content-type | string | JSON | application/json |
Request
mutation {
send_otp(email: "sachinsuresh704@gmail.com") {
message
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| string | email of the user | ✔ |
Success
{
"data": {
"send_otp": {
"message": "OTP sent successfully"
}
}
}
Error
Login With OTP
This API is for logging into the user account
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
login_with_otp(email: "sachinsuresh704@gmail.com", otp: "12345") {
message
token
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| string | email of the user | ✔ | |
| otp | string | OTP received in the email | ✔ |
Success
{
"data": {
"login_with_otp": {
"message": "Login success",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjYyMjk5YzkyNTRmNmMyYmNkNGIyZjA5YSIsIm5hbWUiOiJTYWNoaW4gVCBTIiwiYWNjb3VudFR5cGUiOiJjcmVhdG9yIiwiaWF0IjoxNjUyMzMxMjg1LCJleHAiOjE2NTIzNTI4ODV9.W3iuq0X7mSCQTC7c4D38rXIe5NgX0A6LgoIxoMwoJAo"
}
}
}
Error
{
"errors": [
{
"message": "Incorrect OTP",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["login_with_otp"]
}
],
"data": {
"login_with_otp": null
}
}
Fetch All Creators
This API is for getting the list of all creators
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
list_all_creators(page_size: 2, page_number: 1) {
message
data {
_id
name
email
img
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
Success
{
"data": {
"list_all_creators": {
"message": "data listed",
"data": [
{
"_id": "6277405dc048d34ecb4dc58b",
"name": "xjtzli",
"email": "paysackhq@gmail.com",
"img": null
},
{
"_id": "6255282ac27cdd85d5cf36d1",
"name": "jimshad",
"email": "user1@gmail.com",
"img": null
}
],
"hasMore": true
}
}
}
Error
Fetch All Creator NFTs
This API is for getting the list of all NFTs created by a creator
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
list_all_creator_nfts(creator_id: "6277405dc048d34ecb4dc58b", page_size: 2, page_number: 1) {
message
data {
creator {
_id
name
email
img
}
arts {
_id
name
art_url
nft_id
}
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
| creator_id | string | _id of the creator | ✔ |
Success
{
"data": {
"list_all_creator_nfts": {
"message": "data listed",
"data": {
"creator": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com",
"img": null
},
"arts": [
{
"_id": "6257ac81ba8a2b3e71325ec0",
"name": "Boy",
"art_url": "https://nft-store-assets.s3.amazonaws.com/b6e367bc-612e-4388-a685-fdf7c0490df1.png",
"nft_id": "EsgkMutFq5xa58gGcb86M2uzAdDJbcegzwgGMuiCCMMN"
},
{
"_id": "6257ac1dba8a2bd3d0325e8b",
"name": "Man",
"art_url": "https://nft-store-assets.s3.amazonaws.com/e8621f14-fcc0-41ad-94a3-13d6297d24e8.png",
"nft_id": "ntQXvzKjCyretMDpvAd35Ya3wwzZtWkNRN5UujccsTa"
}
]
},
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "creator not found",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_creator_nfts"]
}
],
"data": {
"list_all_creator_nfts": null
}
}
Fetch All User NFTs
This API is for to get list of all NFTs by a user
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json | |
| x-access-token | string | session token with validity | token | user token |
Request
{
list_all_user_nfts(type: "all", page_size: 2, page_number: 1) {
message
data {
_id
name
art_url
nft_id
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
| type | string | to filter data based on NFT ownership | ✘ |
Success
{
"data": {
"list_all_user_nfts": {
"message": "data listed",
"data": [
{
"_id": "6257ac81ba8a2b3e71325ec0",
"name": "Boy",
"art_url": "https://nft-store-assets.s3.amazonaws.com/b6e367bc-612e-4388-a685-fdf7c0490df1.png",
"nft_id": "EsgkMutFq5xa58gGcb86M2uzAdDJbcegzwgGMuiCCMMN"
},
{
"_id": "6257ac1dba8a2bd3d0325e8b",
"name": "Man",
"art_url": "https://nft-store-assets.s3.amazonaws.com/e8621f14-fcc0-41ad-94a3-13d6297d24e8.png",
"nft_id": "ntQXvzKjCyretMDpvAd35Ya3wwzZtWkNRN5UujccsTa"
}
],
"hasMore": true
}
}
}
Error
{
"errors": [
{
"message": "Unauthorized",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_all_user_nfts"]
}
],
"data": {
"list_all_user_nfts": null
}
}
Fetch NFT Details
This API is for getting the details of an NFT
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
list_nft_details(nft_id: "2iRD8A88h1SRkK1Hhra53jqnfEkhXx5mK58PvLb5YTRW") {
message
data {
_id
name
description
update_authority
art_url
royalty_percentage
nft_id
maximum_supply
is_for_sale
selling_price
owner_id {
_id
name
email
}
creator_id {
_id
name
email
}
}
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| nft_id | string | public address of the NFT | ✔ |
Success
{
"data": {
"list_nft_details": {
"message": "data listed",
"data": {
"_id": "624fc253521415614f508933",
"name": "Old man",
"description": "Old man cartoon character",
"update_authority": "62299c9254f6c2bcd4b2f09a",
"art_url": "https://nft-store-assets.s3.amazonaws.com/033d711b-5554-47c2-8c7f-41e935cab405.png",
"royalty_percentage": 0,
"nft_id": "2iRD8A88h1SRkK1Hhra53jqnfEkhXx5mK58PvLb5YTRW",
"maximum_supply": null,
"is_for_sale": false,
"selling_price": 0,
"owner_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
},
"creator_id": {
"_id": "62299c9254f6c2bcd4b2f09a",
"name": "Sachin T S",
"email": "sachinsuresh704@gmail.com"
}
}
}
}
}
Error
{
"errors": [
{
"message": "art not found",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": ["list_nft_details"]
}
],
"data": {
"list_nft_details": null
}
}
Fetch All Listed NFTs
This API is for getting the list of all NFTs added for sales
GRAPHQL
Headers
| Fields | Type | Description | Example | Data Management |
|---|---|---|---|---|
| URL | string | {base_url}/users | ||
| GRAPHQL | string | QUERY | ||
| content-type | string | JSON | application/json |
Request
{
list_all_selling_nfts(page_size: 2, page_number: 1) {
message
data {
_id
amount
is_sold
seller_id
}
hasMore
}
}
Request Parameters
| Fields | Type | Description | Required |
|---|---|---|---|
| page_size | integer | total number of data to be displayed | ✘ |
| page_number | integer | page number to filter data | ✘ |
Success
{
"data": {
"list_all_selling_nfts": {
"message": "data listed",
"data": [
{
"_id": "62511d083b5ded111f2bf507",
"amount": 40000000,
"is_sold": false,
"seller_id": "62299c9254f6c2bcd4b2f09a"
}
],
"hasMore": false
}
}
}
Error