Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@mojito-inc/core-service

Package Overview
Dependencies
Maintainers
0
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mojito-inc/core-service - npm Package Compare versions

Comparing version 1.0.8-beta.32 to 1.0.8-beta.33

NFT/NFTData/TraitsData.d.ts

2

NFT/index.js
import useNFT from './useNFT.js';
export { TokenStatus } from './NFTData/AllRegistryTokenData.js';
export { ActivityNameEnum, OrderStatusEnum } from './NFTData/BuyNowData.js';
export { OrderType, RegistryTokenColumnType, RegistryTokenFilterInput } from './NFTParam/AllRegistryTokenParam.js';
export { OrderType, RegistryCurrency, RegistryTokenColumnType, RegistryTokenFilterInput, RegistryTokenStatus } from './NFTParam/AllRegistryTokenParam.js';
export { SavedNFTFilterInput } from './NFTParam/FavoriteParam.js';

@@ -6,0 +6,0 @@ export { NFTTxEventType } from './NFTParam/NFTDetailsParam.js';

@@ -129,2 +129,12 @@ export interface NFTPrice {

}
export interface GetAllRegistryTokensV2Data {
getAllRegistryTokensV2?: {
data: AllRegistryTokens[];
totalCount: number;
user: User | null;
latestSoldPrice?: NFTPrice[];
highestSoldPrice?: NFTPrice[];
lowestSoldPrice?: NFTPrice[];
};
}
export {};

@@ -8,1 +8,2 @@ export * from './AllRegistryTokenData';

export * from './FileSignedUrlData';
export * from './TraitsData';

@@ -38,1 +38,38 @@ export declare enum RegistryTokenFilterInput {

}
export declare enum RegistryTokenStatus {
NEW = "NEW",
ENQUIRY_PENDING = "ENQUIRY_PENDING",
OPEN_FOR_SALE = "OPEN_FOR_SALE",
SALE_PENDING = "SALE_PENDING",
STALE_OWNERSHIP = "STALE_OWNERSHIP"
}
export interface RegistryFilterMetadata {
traitType: string;
traitValue: string[];
}
export declare enum RegistryCurrency {
USD = "USD",
EUR = "EUR"
}
export interface GetAllRegistryTokensV2Params {
orgID: string;
marketplaceID?: string;
owner?: string;
offset?: number;
limit?: number;
searchKey?: string;
categoryID?: string;
artistID?: string;
artistSlug?: string;
categorySlug?: string;
contractAddress?: string;
status?: RegistryTokenStatus;
registryID?: string;
filters?: RegistryTokenFilterInput;
filterByMetadata?: RegistryFilterMetadata[];
sort?: RegistryTokenSortInput;
buyerAddress?: string;
chainID?: number;
offerPriceSorting?: boolean;
currency?: RegistryCurrency;
}

@@ -21,3 +21,16 @@ var RegistryTokenFilterInput;

})(OrderType || (OrderType = {}));
var RegistryTokenStatus;
(function (RegistryTokenStatus) {
RegistryTokenStatus["NEW"] = "NEW";
RegistryTokenStatus["ENQUIRY_PENDING"] = "ENQUIRY_PENDING";
RegistryTokenStatus["OPEN_FOR_SALE"] = "OPEN_FOR_SALE";
RegistryTokenStatus["SALE_PENDING"] = "SALE_PENDING";
RegistryTokenStatus["STALE_OWNERSHIP"] = "STALE_OWNERSHIP";
})(RegistryTokenStatus || (RegistryTokenStatus = {}));
var RegistryCurrency;
(function (RegistryCurrency) {
RegistryCurrency["USD"] = "USD";
RegistryCurrency["EUR"] = "EUR";
})(RegistryCurrency || (RegistryCurrency = {}));
export { OrderType, RegistryTokenColumnType, RegistryTokenFilterInput };
export { OrderType, RegistryCurrency, RegistryTokenColumnType, RegistryTokenFilterInput, RegistryTokenStatus };

@@ -8,1 +8,2 @@ export * from './AllRegistryTokenParam';

export * from './FileSignedUrlParam';
export * from './TraitsParam';
import { Response } from '../data';
import { GetNFTFavoriteListByUserData, AddNFTToFavoriteData, RemoveNFTFromFavoriteData, GetAllRegistryTokensData, GetNFTAttributesRarityData, GetNFTDetailsData, GetNFTHistoryData, InitiateBuyNFTData, UpdateTransactionHashData, GenerateSecondaryInvoiceData, UserOrderActivityData, TransferNFTData, GetAllInvoicesData, GetMyInvoicesData, GeneratePrimaryInvoiceData, FileSignedUrlData, CompleteOnchainBuyData, SaveUserWalletSessionData } from './NFTData';
import { GetNFTFavoriteListByUserData, AddNFTToFavoriteData, RemoveNFTFromFavoriteData, GetAllRegistryTokensData, GetNFTAttributesRarityData, GetNFTDetailsData, GetNFTHistoryData, InitiateBuyNFTData, UpdateTransactionHashData, GenerateSecondaryInvoiceData, UserOrderActivityData, TransferNFTData, GetAllInvoicesData, GetMyInvoicesData, GeneratePrimaryInvoiceData, FileSignedUrlData, CompleteOnchainBuyData, SaveUserWalletSessionData, TraitsData, GetAllRegistryTokensV2Data } from './NFTData';
import { QueryOptions } from '../domain';
import { FavoriteListByUserParam, FavoriteParam, GetAllRegistryTokensParam, GetNFTAttributesRarityParam, GetNFTDetailsParam, GetNFTHistoryParam, InitiateBuyNFTParam, UpdateTransactionHashParam, GenerateSecondaryInvoiceParam, GetUserOrderActivityParam, TransferNFTParam, GetAllInvoicesParam, GetMyInvoicesParam, GeneratePrimaryInvoiceParam, FileSignedUrlParam, CompleteOnchainBuyParam, SaveUserWalletSessionParam } from './NFTParam';
import { FavoriteListByUserParam, FavoriteParam, GetAllRegistryTokensParam, GetNFTAttributesRarityParam, GetNFTDetailsParam, GetNFTHistoryParam, InitiateBuyNFTParam, UpdateTransactionHashParam, GenerateSecondaryInvoiceParam, GetUserOrderActivityParam, TransferNFTParam, GetAllInvoicesParam, GetMyInvoicesParam, GeneratePrimaryInvoiceParam, FileSignedUrlParam, CompleteOnchainBuyParam, SaveUserWalletSessionParam, GetCollectionTraitParam, GetAllRegistryTokensV2Params } from './NFTParam';
export interface NFTService {

@@ -115,2 +115,26 @@ /**

/**
* Returns NFT list
*
* @remarks
* This method is part of NFT service
*
* @param param - NFT list param {@link GetAllRegistryTokensV2Params}
* @param options - graphql fetch query options {@link QueryOptions}
* @returns {@link GetAllRegistryTokensV2Data} NFT list
*
*/
getAllRegistryTokensV2: (param: GetAllRegistryTokensV2Params, options?: QueryOptions) => Promise<Response<GetAllRegistryTokensV2Data>>;
/**
* Returns Traits for the marketplace or organization
*
* @remarks
* This method is part of NFT service
*
* @param param - collection traits query param {@link GetCollectionTraitParam}
* @param options - graphql fetch query options {@link QueryOptions}
* @returns {@link TraitsData} Traits data
*
*/
getCollectionTraits: (param: GetCollectionTraitParam, options?: QueryOptions) => Promise<Response<TraitsData>>;
/**
* Returns NFT details

@@ -117,0 +141,0 @@ *

export declare const getAllRegistryTokensQueries: import("@apollo/client").DocumentNode;
export declare const getAllRegistryTokensV2Query: import("@apollo/client").DocumentNode;

@@ -183,3 +183,197 @@ import { gql } from '@apollo/client';

`;
const getAllRegistryTokensV2Query = gql `
query (
$orgID: UUID1!
$marketplaceID: UUID1
$owner: String
$offset: Int
$limit: Int
$searchKey: String
$categoryID: UUID1
$artistID: UUID1
$artistSlug: String
$categorySlug: String
$contractAddress: String
$status: TokenStatus
$registryID: UUID1
$filters: RegistryTokenFilterInput
$filterByMetadata: [CollectionListingSlugFilterInput]
$sort: RegistryTokenSortInput
$buyerAddress: String
$chainID: BigInt
$offerPriceSorting: Boolean
$currency: CurrencyCodeFiat
) {
getAllRegistryTokensV2(
orgID: $orgID
marketplaceID: $marketplaceID
owner: $owner
offset: $offset
limit: $limit
searchKey: $searchKey
categoryID: $categoryID
artistID: $artistID
artistSlug: $artistSlug
categorySlug: $categorySlug
contractAddress: $contractAddress
status: $status
registryID: $registryID
filters: $filters
filterByMetadata: $filterByMetadata
sort: $sort
buyerAddress: $buyerAddress
chainID: $chainID
offerPriceSorting: $offerPriceSorting
currency: $currency
) {
data {
ID
TokenName
TokenID
Status
TokenURI
NFTTokenID
mediaSourceExtension
mediaSourceURL
Price {
buyNowPrice {
value
unit
type
}
lastPurchasedPrice {
value
unit
type
}
makeOfferHighestPrice {
value
unit
type
}
makeOfferLatestPrice {
value
unit
type
}
}
MetaData {
name
image
description
animationURL
openSeaImageURL
}
networkID
latestOffer {
price {
value
unit
type
}
}
listedOrderInfo {
id
listedCurrency {
contractAddress
}
price {
value
unit
type
}
}
isBuyNowEnabled
isMakeOfferEnabled
editionNumber
TokenType
ListingStatus
OwnersList
Owners
RegistryId
MintedAt
TokenOwnerAddress
nftContractName
networkName
Registry {
ID
NetworkID
Network {
name
}
OrganizationID
CollectionName
ContractAddress
IsAllTokensApproved
MarketplaceID
TotalApproved
CollectionTotal
ArtistID
Artist {
id
description
artistName
artistLocation
artistContactEmail
artistContactNumber
artistWebsite
}
CategoryID
CreatedByUserID
CreatedAt
UpdatedAt
}
Artist {
id
description
artistName
artistLocation
artistContactEmail
artistContactNumber
artistWebsite
}
isOfferExist
offerOrderId
CreatedBy
CreatedAt
UpdatedAt
offerOrder {
id
nftTokenId
fixedPrice
offerExpiryDate
price {
value
unit
type
}
}
}
totalCount
user {
id
username
name
email
avatar
}
lowestSoldPrice {
value
unit
type
}
highestSoldPrice {
value
unit
type
}
latestSoldPrice {
value
unit
type
}
}
}
`;
export { getAllRegistryTokensQueries };
export { getAllRegistryTokensQueries, getAllRegistryTokensV2Query };

@@ -8,1 +8,2 @@ export * from './AllRegistryTokenQueries';

export * from './FileSignedUrlQueries';
export * from './TraitsQueries';
import { __awaiter } from '../_virtual/_tslib.js';
import { useCallback, useMemo } from 'react';
import { useApolloClient } from '@apollo/client';
import { getAllRegistryTokensQueries } from './Queries/AllRegistryTokenQueries.js';
import { getAllRegistryTokensQueries, getAllRegistryTokensV2Query } from './Queries/AllRegistryTokenQueries.js';
import { initiateBuyNFTMutation, updateTransactionHashMutation, generateSecondaryInvoiceQueries, generatePrimaryInvoiceQueries, getUserOrderActivityQueries, completeOnchainBuyQueries, saveUserWalletSessionQueries } from './Queries/BuyNowQueries.js';

@@ -11,2 +11,3 @@ import { addNFTToFavoriteMutation, removeNFTFromFavoriteMutation, getNFTFavoriteListByUserQueries } from './Queries/FavoriteQueries.js';

import { getFileSignedURLQuery } from './Queries/FileSignedUrlQueries.js';
import { getCollectionTraitsForSMPQuery } from './Queries/TraitsQueries.js';

@@ -44,2 +45,12 @@ /**

}), [client]);
const getAllRegistryTokensV2 = useCallback((param, options) => __awaiter(void 0, void 0, void 0, function* () {
const response = yield client.query(Object.assign(Object.assign({}, options), { query: getAllRegistryTokensV2Query, variables: param }));
const responseData = response.data;
return { data: responseData };
}), [client]);
const getCollectionTraits = useCallback((param, options) => __awaiter(void 0, void 0, void 0, function* () {
const response = yield client.query(Object.assign(Object.assign({}, options), { query: getCollectionTraitsForSMPQuery, variables: param }));
const responseData = response.data;
return { data: responseData };
}), [client]);
const getNFTDetails = useCallback((param, options) => __awaiter(void 0, void 0, void 0, function* () {

@@ -135,2 +146,4 @@ const response = yield client.query(Object.assign(Object.assign({}, options), { query: getNFTDetailsQueries, variables: param }));

saveUserWalletSession,
getCollectionTraits,
getAllRegistryTokensV2,
};

@@ -156,2 +169,4 @@ }, [

saveUserWalletSession,
getCollectionTraits,
getAllRegistryTokensV2,
]);

@@ -158,0 +173,0 @@ };

{
"name": "@mojito-inc/core-service",
"version": "1.0.8-beta.32",
"version": "1.0.8-beta.33",
"description": "Mojito Core API service for auction, payment, token",

@@ -5,0 +5,0 @@ "main": "./index.cjs",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc