@imtbl/minting-backend 2.0.0-alpha.9 → 2.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 +1 -1
- package/dist/types/index.d.ts +19 -0
- package/package.json +7 -6
package/README.md
CHANGED
package/dist/types/index.d.ts
CHANGED
|
@@ -16,12 +16,31 @@ export declare class MintingBackendModule {
|
|
|
16
16
|
private readonly blockchainDataClient;
|
|
17
17
|
private readonly logger;
|
|
18
18
|
constructor(config: MintingBackendModuleConfiguration);
|
|
19
|
+
/**
|
|
20
|
+
* Records a mint request in the persistence layer.
|
|
21
|
+
* @param {CreateMintRequest} mintRequest - The mint request to be recorded
|
|
22
|
+
* @returns {Promise<void>} A promise that resolves when the mint request is recorded
|
|
23
|
+
*/
|
|
19
24
|
recordMint(mintRequest: CreateMintRequest): Promise<void>;
|
|
25
|
+
/**
|
|
26
|
+
* Submits minting requests for processing.
|
|
27
|
+
* @param {Object} config - Configuration options for submitting minting requests
|
|
28
|
+
* @param {number} [config.defaultBatchSize] - The number of minting requests to process in a batch
|
|
29
|
+
* @param {string} [config.chainName] - The blockchain network to process mints for
|
|
30
|
+
* @param {number} [config.maxNumberOfTries] - Maximum number of retry attempts for failed requests
|
|
31
|
+
* @returns {Promise<void>} A promise that resolves when the minting requests are submitted
|
|
32
|
+
*/
|
|
20
33
|
submitMintingRequests(config: {
|
|
21
34
|
defaultBatchSize?: number;
|
|
22
35
|
chainName?: string;
|
|
23
36
|
maxNumberOfTries?: number;
|
|
24
37
|
}): Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* Processes a mint webhook event.
|
|
40
|
+
* @param {string | Record<string, unknown>} body - The webhook event payload
|
|
41
|
+
* @param {Object} [otherHandlers=noopHandlers] - Additional handlers for the webhook event
|
|
42
|
+
* @returns {Promise<void>} A promise that resolves when the mint is processed
|
|
43
|
+
*/
|
|
25
44
|
processMint(body: string | Record<string, unknown>, otherHandlers?: {
|
|
26
45
|
zkevmMintRequestUpdated: (event: ZkevmMintRequestUpdated) => Promise<void>;
|
|
27
46
|
}): Promise<void>;
|
package/package.json
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@imtbl/minting-backend",
|
|
3
3
|
"description": "minting backend utilising Immutable Minting API",
|
|
4
|
-
"version": "2.0.0
|
|
4
|
+
"version": "2.0.0",
|
|
5
5
|
"author": "Immutable",
|
|
6
6
|
"bugs": "https://github.com/immutable/ts-immutable-sdk/issues",
|
|
7
7
|
"dependencies": {
|
|
8
|
-
"@imtbl/blockchain-data": "2.0.0
|
|
9
|
-
"@imtbl/config": "2.0.0
|
|
10
|
-
"@imtbl/generated-clients": "2.0.0
|
|
11
|
-
"@imtbl/metrics": "2.0.0
|
|
12
|
-
"@imtbl/webhook": "2.0.0
|
|
8
|
+
"@imtbl/blockchain-data": "2.0.0",
|
|
9
|
+
"@imtbl/config": "2.0.0",
|
|
10
|
+
"@imtbl/generated-clients": "2.0.0",
|
|
11
|
+
"@imtbl/metrics": "2.0.0",
|
|
12
|
+
"@imtbl/webhook": "2.0.0",
|
|
13
13
|
"uuid": "^8.3.2"
|
|
14
14
|
},
|
|
15
15
|
"devDependencies": {
|
|
@@ -59,6 +59,7 @@
|
|
|
59
59
|
"build": "pnpm transpile && pnpm typegen",
|
|
60
60
|
"transpile": "tsup src/index.ts --config ./tsup.config.js",
|
|
61
61
|
"typegen": "tsc --customConditions default --emitDeclarationOnly --outDir dist/types",
|
|
62
|
+
"pack:root": "pnpm pack --pack-destination $(dirname $(pnpm root -w))",
|
|
62
63
|
"lint": "eslint ./src --ext .ts,.jsx,.tsx --max-warnings=0",
|
|
63
64
|
"test": "jest --passWithNoTests",
|
|
64
65
|
"test:watch": "jest --watch",
|