getgems 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +68 -0
- package/dist/api-service/abstract-api.service.d.ts +9 -0
- package/dist/api-service/abstract-api.service.js +51 -0
- package/dist/api-service/abstract-api.types.d.ts +32 -0
- package/dist/api-service/abstract-api.types.js +16 -0
- package/dist/api-service/index.d.ts +2 -0
- package/dist/api-service/index.js +8 -0
- package/dist/cnft-api/cnft-api.service.d.ts +11 -0
- package/dist/cnft-api/cnft-api.service.js +68 -0
- package/dist/cnft-api/index.d.ts +1 -0
- package/dist/cnft-api/index.js +5 -0
- package/dist/gift-api/gift-api.service.d.ts +16 -0
- package/dist/gift-api/gift-api.service.js +64 -0
- package/dist/gift-api/index.d.ts +1 -0
- package/dist/gift-api/index.js +5 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +18 -0
- package/dist/minting-api/index.d.ts +1 -0
- package/dist/minting-api/index.js +5 -0
- package/dist/minting-api/minting-api.service.d.ts +36 -0
- package/dist/minting-api/minting-api.service.js +181 -0
- package/dist/read-api/index.d.ts +1 -0
- package/dist/read-api/index.js +5 -0
- package/dist/read-api/read-api.service.d.ts +100 -0
- package/dist/read-api/read-api.service.js +328 -0
- package/dist/schemas.d.ts +760 -0
- package/dist/schemas.js +130 -0
- package/dist/storage-api/index.d.ts +1 -0
- package/dist/storage-api/index.js +5 -0
- package/dist/storage-api/storage-api.service.d.ts +8 -0
- package/dist/storage-api/storage-api.service.js +44 -0
- package/package.json +39 -0
package/dist/schemas.js
ADDED
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EMintingListItemStatus = exports.EMintingListItemType = exports.ETonTxState = exports.ESignatureDataType = exports.ELang = exports.EReindexResponseStatus = exports.ECurrency = exports.EHistoryType = exports.ENftItemsUpdateResponseType = exports.EContractType = exports.ESaleType = exports.ENftItemWarning = exports.ENftItemKind = exports.EOwnershipChangeEventType = exports.EMintingStatus = exports.EUpdateDataStatus = void 0;
|
|
4
|
+
var EUpdateDataStatus;
|
|
5
|
+
(function (EUpdateDataStatus) {
|
|
6
|
+
EUpdateDataStatus["JustCreated"] = "just_created";
|
|
7
|
+
EUpdateDataStatus["InQueue"] = "in_queue";
|
|
8
|
+
EUpdateDataStatus["Updating"] = "updating";
|
|
9
|
+
EUpdateDataStatus["Ready"] = "ready";
|
|
10
|
+
EUpdateDataStatus["Problem"] = "problem";
|
|
11
|
+
})(EUpdateDataStatus || (exports.EUpdateDataStatus = EUpdateDataStatus = {}));
|
|
12
|
+
var EMintingStatus;
|
|
13
|
+
(function (EMintingStatus) {
|
|
14
|
+
EMintingStatus["JustCreated"] = "just_created";
|
|
15
|
+
EMintingStatus["InQueue"] = "in_queue";
|
|
16
|
+
EMintingStatus["Minting"] = "minting";
|
|
17
|
+
EMintingStatus["Ready"] = "ready";
|
|
18
|
+
EMintingStatus["Problem"] = "problem";
|
|
19
|
+
})(EMintingStatus || (exports.EMintingStatus = EMintingStatus = {}));
|
|
20
|
+
var EOwnershipChangeEventType;
|
|
21
|
+
(function (EOwnershipChangeEventType) {
|
|
22
|
+
EOwnershipChangeEventType["Transfer"] = "transfer";
|
|
23
|
+
EOwnershipChangeEventType["Sold"] = "sold";
|
|
24
|
+
EOwnershipChangeEventType["Burn"] = "burn";
|
|
25
|
+
})(EOwnershipChangeEventType || (exports.EOwnershipChangeEventType = EOwnershipChangeEventType = {}));
|
|
26
|
+
var ENftItemKind;
|
|
27
|
+
(function (ENftItemKind) {
|
|
28
|
+
ENftItemKind["Single"] = "Single";
|
|
29
|
+
ENftItemKind["CollectionItem"] = "CollectionItem";
|
|
30
|
+
ENftItemKind["DnsItem"] = "DnsItem";
|
|
31
|
+
ENftItemKind["SbtItem"] = "SbtItem";
|
|
32
|
+
ENftItemKind["SbtSingle"] = "SbtSingle";
|
|
33
|
+
ENftItemKind["SyntheticItem"] = "SyntheticItem";
|
|
34
|
+
ENftItemKind["SyntheticSbt"] = "SyntheticSbt";
|
|
35
|
+
ENftItemKind["OffchainNft"] = "OffchainNft";
|
|
36
|
+
ENftItemKind["OffchainSticker"] = "OffchainSticker";
|
|
37
|
+
})(ENftItemKind || (exports.ENftItemKind = ENftItemKind = {}));
|
|
38
|
+
var ENftItemWarning;
|
|
39
|
+
(function (ENftItemWarning) {
|
|
40
|
+
ENftItemWarning["NftBanFromFragment"] = "NftBanFromFragment";
|
|
41
|
+
})(ENftItemWarning || (exports.ENftItemWarning = ENftItemWarning = {}));
|
|
42
|
+
var ESaleType;
|
|
43
|
+
(function (ESaleType) {
|
|
44
|
+
ESaleType["FixPriceSale"] = "FixPriceSale";
|
|
45
|
+
ESaleType["Auction"] = "Auction";
|
|
46
|
+
})(ESaleType || (exports.ESaleType = ESaleType = {}));
|
|
47
|
+
var EContractType;
|
|
48
|
+
(function (EContractType) {
|
|
49
|
+
EContractType["Telemint"] = "telemint";
|
|
50
|
+
EContractType["Offchain"] = "offchain";
|
|
51
|
+
EContractType["SaleContract"] = "sale-contract";
|
|
52
|
+
})(EContractType || (exports.EContractType = EContractType = {}));
|
|
53
|
+
var ENftItemsUpdateResponseType;
|
|
54
|
+
(function (ENftItemsUpdateResponseType) {
|
|
55
|
+
ENftItemsUpdateResponseType["UPDATES"] = "UPDATES";
|
|
56
|
+
ENftItemsUpdateResponseType["NO_UPDATES"] = "NO_UPDATES";
|
|
57
|
+
})(ENftItemsUpdateResponseType || (exports.ENftItemsUpdateResponseType = ENftItemsUpdateResponseType = {}));
|
|
58
|
+
var EHistoryType;
|
|
59
|
+
(function (EHistoryType) {
|
|
60
|
+
EHistoryType["Mint"] = "mint";
|
|
61
|
+
EHistoryType["Transfer"] = "transfer";
|
|
62
|
+
EHistoryType["Sold"] = "sold";
|
|
63
|
+
EHistoryType["CancelSale"] = "cancelSale";
|
|
64
|
+
EHistoryType["PutUpForSale"] = "putUpForSale";
|
|
65
|
+
EHistoryType["PutUpForAuction"] = "putUpForAuction";
|
|
66
|
+
EHistoryType["CancelAuction"] = "cancelAuction";
|
|
67
|
+
EHistoryType["Burn"] = "burn";
|
|
68
|
+
})(EHistoryType || (exports.EHistoryType = EHistoryType = {}));
|
|
69
|
+
var ECurrency;
|
|
70
|
+
(function (ECurrency) {
|
|
71
|
+
ECurrency["TON"] = "TON";
|
|
72
|
+
ECurrency["USDT"] = "USDT";
|
|
73
|
+
ECurrency["NOT"] = "NOT";
|
|
74
|
+
ECurrency["SNT"] = "SNT";
|
|
75
|
+
ECurrency["DFC"] = "DFC";
|
|
76
|
+
ECurrency["FTON"] = "FTON";
|
|
77
|
+
ECurrency["PTONv1"] = "pTONv1";
|
|
78
|
+
ECurrency["GTON"] = "GTON";
|
|
79
|
+
ECurrency["WOOF"] = "WOOF";
|
|
80
|
+
ECurrency["DOGS"] = "DOGS";
|
|
81
|
+
ECurrency["CATS"] = "CATS";
|
|
82
|
+
ECurrency["PX"] = "PX";
|
|
83
|
+
ECurrency["MAJOR"] = "MAJOR";
|
|
84
|
+
ECurrency["PUNK"] = "PUNK";
|
|
85
|
+
ECurrency["UNIT_TEST"] = "UNIT_TEST";
|
|
86
|
+
ECurrency["NOTTEST"] = "NOTTEST";
|
|
87
|
+
ECurrency["VAT"] = "VAT";
|
|
88
|
+
ECurrency["HOLDER"] = "HOLDER";
|
|
89
|
+
ECurrency["STON"] = "STON";
|
|
90
|
+
ECurrency["CATI"] = "CATI";
|
|
91
|
+
ECurrency["XAUt0"] = "XAUt0";
|
|
92
|
+
ECurrency["TSLAx"] = "TSLAx";
|
|
93
|
+
ECurrency["AAPLx"] = "AAPLx";
|
|
94
|
+
ECurrency["NVDAx"] = "NVDAx";
|
|
95
|
+
ECurrency["GOOGLx"] = "GOOGLx";
|
|
96
|
+
ECurrency["NFLXx"] = "NFLXx";
|
|
97
|
+
})(ECurrency || (exports.ECurrency = ECurrency = {}));
|
|
98
|
+
var EReindexResponseStatus;
|
|
99
|
+
(function (EReindexResponseStatus) {
|
|
100
|
+
EReindexResponseStatus["Failed"] = "failed";
|
|
101
|
+
EReindexResponseStatus["Success"] = "success";
|
|
102
|
+
})(EReindexResponseStatus || (exports.EReindexResponseStatus = EReindexResponseStatus = {}));
|
|
103
|
+
var ELang;
|
|
104
|
+
(function (ELang) {
|
|
105
|
+
ELang["Ru"] = "ru";
|
|
106
|
+
ELang["En"] = "en";
|
|
107
|
+
})(ELang || (exports.ELang = ELang = {}));
|
|
108
|
+
var ESignatureDataType;
|
|
109
|
+
(function (ESignatureDataType) {
|
|
110
|
+
ESignatureDataType["Text"] = "text";
|
|
111
|
+
})(ESignatureDataType || (exports.ESignatureDataType = ESignatureDataType = {}));
|
|
112
|
+
var ETonTxState;
|
|
113
|
+
(function (ETonTxState) {
|
|
114
|
+
ETonTxState["NotReady"] = "NotReady";
|
|
115
|
+
ETonTxState["Ready"] = "Ready";
|
|
116
|
+
ETonTxState["Failed"] = "Failed";
|
|
117
|
+
})(ETonTxState || (exports.ETonTxState = ETonTxState = {}));
|
|
118
|
+
var EMintingListItemType;
|
|
119
|
+
(function (EMintingListItemType) {
|
|
120
|
+
EMintingListItemType["MintNft"] = "mintNft";
|
|
121
|
+
EMintingListItemType["UpdateNft"] = "updateNft";
|
|
122
|
+
EMintingListItemType["AddCollection"] = "addCollection";
|
|
123
|
+
EMintingListItemType["UpdateCollection"] = "updateCollection";
|
|
124
|
+
})(EMintingListItemType || (exports.EMintingListItemType = EMintingListItemType = {}));
|
|
125
|
+
var EMintingListItemStatus;
|
|
126
|
+
(function (EMintingListItemStatus) {
|
|
127
|
+
EMintingListItemStatus["InQueue"] = "in_queue";
|
|
128
|
+
EMintingListItemStatus["Ready"] = "ready";
|
|
129
|
+
EMintingListItemStatus["Problem"] = "problem";
|
|
130
|
+
})(EMintingListItemStatus || (exports.EMintingListItemStatus = EMintingListItemStatus = {}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { StorageApiService } from './storage-api.service';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StorageApiService = void 0;
|
|
4
|
+
var storage_api_service_1 = require("./storage-api.service");
|
|
5
|
+
Object.defineProperty(exports, "StorageApiService", { enumerable: true, get: function () { return storage_api_service_1.StorageApiService; } });
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ApiService } from "../api-service";
|
|
2
|
+
import { DefaultErrorObject, FailedResponse, SetStorageCollectionRequest, SetStorageCollectionResponse, StorageBoxIdResponse, StorageUploadCredentialsResponse } from "../schemas";
|
|
3
|
+
export declare class StorageApiService extends ApiService {
|
|
4
|
+
constructor(API_KEY: string);
|
|
5
|
+
createStorage(): Promise<DefaultErrorObject | FailedResponse | StorageBoxIdResponse>;
|
|
6
|
+
getStorageCredentials(boxId: number): Promise<DefaultErrorObject | FailedResponse | StorageUploadCredentialsResponse>;
|
|
7
|
+
setStorageCollection(boxId: number, body: SetStorageCollectionRequest): Promise<DefaultErrorObject | FailedResponse | SetStorageCollectionResponse>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.StorageApiService = void 0;
|
|
13
|
+
const api_service_1 = require("../api-service");
|
|
14
|
+
class StorageApiService extends api_service_1.ApiService {
|
|
15
|
+
constructor(API_KEY) {
|
|
16
|
+
super(API_KEY);
|
|
17
|
+
}
|
|
18
|
+
createStorage() {
|
|
19
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
20
|
+
return this.makeApiRequest({
|
|
21
|
+
method: api_service_1.EApiRequestMethod.POST,
|
|
22
|
+
path: `/v1/storage/upload-credentials`
|
|
23
|
+
});
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
getStorageCredentials(boxId) {
|
|
27
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
28
|
+
return this.makeApiRequest({
|
|
29
|
+
method: api_service_1.EApiRequestMethod.GET,
|
|
30
|
+
path: `/v1/storage/upload-credentials/${boxId}`
|
|
31
|
+
});
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
setStorageCollection(boxId, body) {
|
|
35
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
36
|
+
return this.makeApiRequest({
|
|
37
|
+
method: api_service_1.EApiRequestMethod.PATCH,
|
|
38
|
+
path: `/v1/storage/upload-credentials/${boxId}`,
|
|
39
|
+
body: JSON.stringify(body)
|
|
40
|
+
});
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
exports.StorageApiService = StorageApiService;
|
package/package.json
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "getgems",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "dist/index.js",
|
|
5
|
+
"types": "dist/index.d.ts",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist"
|
|
8
|
+
],
|
|
9
|
+
"scripts": {
|
|
10
|
+
"build": "tsc",
|
|
11
|
+
"start": "node dist/index.js",
|
|
12
|
+
"prepare": "npm run build"
|
|
13
|
+
},
|
|
14
|
+
"repository": {
|
|
15
|
+
"type": "git",
|
|
16
|
+
"url": "https://github.com/Yea-Nick/getgems"
|
|
17
|
+
},
|
|
18
|
+
"bugs": {
|
|
19
|
+
"url": "https://github.com/Yea-Nick/getgems/issues"
|
|
20
|
+
},
|
|
21
|
+
"homepage": "https://github.com/Yea-Nick/getgems#readme",
|
|
22
|
+
"keywords": [
|
|
23
|
+
"nft",
|
|
24
|
+
"ton",
|
|
25
|
+
"getgems",
|
|
26
|
+
"get-gems"
|
|
27
|
+
],
|
|
28
|
+
"author": "Yea-Nick",
|
|
29
|
+
"license": "ISC",
|
|
30
|
+
"type": "commonjs",
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@types/node": "^25.0.3",
|
|
33
|
+
"ts-node": "^10.9.2",
|
|
34
|
+
"typescript": "^5.9.3"
|
|
35
|
+
},
|
|
36
|
+
"dependencies": {
|
|
37
|
+
"node-fetch": "^3.3.2"
|
|
38
|
+
}
|
|
39
|
+
}
|