@ercworldio/blockchain-shared 1.0.3-dev.3 → 1.0.3-dev.3-PROJ-1296.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/build/chains/networks_prod-dz.json +7 -7
- package/build/chains/networks_prod-sh.json +41 -5
- package/build/chains/networks_prod-yb.json +42 -6
- package/build/chains/networks_stg-yb.json +1 -1
- package/build/contracts/artifacts/Escrow.json +1831 -342
- package/build/contracts/typechain-types/@openzeppelin/contracts/interfaces/index.d.ts +0 -1
- package/build/contracts/typechain-types/@openzeppelin/contracts/interfaces/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/@openzeppelin/contracts/utils/index.d.ts +0 -6
- package/build/contracts/typechain-types/@openzeppelin/contracts/utils/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/contracts/escrow/Escrow.d.ts +761 -76
- package/build/contracts/typechain-types/contracts/escrow/Escrow.d.ts.map +1 -1
- package/build/contracts/typechain-types/contracts/escrow/EscrowAccessControl.d.ts +65 -17
- package/build/contracts/typechain-types/contracts/escrow/EscrowAccessControl.d.ts.map +1 -1
- package/build/contracts/typechain-types/contracts/index.d.ts +2 -0
- package/build/contracts/typechain-types/contracts/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/contracts/lib/Events.d.ts +386 -0
- package/build/contracts/typechain-types/contracts/lib/Events.d.ts.map +1 -0
- package/build/contracts/typechain-types/contracts/lib/Events.js +2 -0
- package/build/contracts/typechain-types/contracts/lib/MultisigLib.d.ts +21 -0
- package/build/contracts/typechain-types/contracts/lib/MultisigLib.d.ts.map +1 -0
- package/build/contracts/typechain-types/contracts/lib/MultisigLib.js +2 -0
- package/build/contracts/typechain-types/contracts/lib/index.d.ts +3 -0
- package/build/contracts/typechain-types/contracts/lib/index.d.ts.map +1 -0
- package/build/contracts/typechain-types/contracts/lib/index.js +2 -0
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/interfaces/index.d.ts +0 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/interfaces/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/interfaces/index.js +1 -3
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/token/ERC20/utils/SafeERC20__factory.d.ts +1 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/token/ERC20/utils/SafeERC20__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/token/ERC20/utils/SafeERC20__factory.js +1 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/utils/index.d.ts +0 -4
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/utils/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/@openzeppelin/contracts/utils/index.js +1 -7
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowAccessControl__factory.d.ts +286 -12
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowAccessControl__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowAccessControl__factory.js +374 -12
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowErrors__factory.d.ts +137 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowErrors__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowErrors__factory.js +182 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowSignature__factory.d.ts +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowSignature__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/EscrowSignature__factory.js +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/Escrow__factory.d.ts +1247 -98
- package/build/contracts/typechain-types/factories/contracts/escrow/Escrow__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/Escrow__factory.js +1736 -247
- package/build/contracts/typechain-types/factories/contracts/escrow/TokensWhitelist__factory.d.ts +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/TokensWhitelist__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/escrow/TokensWhitelist__factory.js +1 -1
- package/build/contracts/typechain-types/factories/contracts/index.d.ts +1 -0
- package/build/contracts/typechain-types/factories/contracts/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/index.js +2 -1
- package/build/contracts/typechain-types/factories/contracts/lib/Events__factory.d.ts +373 -0
- package/build/contracts/typechain-types/factories/contracts/lib/Events__factory.d.ts.map +1 -0
- package/build/contracts/typechain-types/factories/contracts/lib/Events__factory.js +473 -0
- package/build/contracts/typechain-types/factories/contracts/lib/MultisigLib__factory.d.ts +55 -0
- package/build/contracts/typechain-types/factories/contracts/lib/MultisigLib__factory.d.ts.map +1 -0
- package/build/contracts/typechain-types/factories/contracts/lib/MultisigLib__factory.js +82 -0
- package/build/contracts/typechain-types/factories/contracts/lib/index.d.ts +3 -0
- package/build/contracts/typechain-types/factories/contracts/lib/index.d.ts.map +1 -0
- package/build/contracts/typechain-types/factories/contracts/lib/index.js +10 -0
- package/build/contracts/typechain-types/factories/contracts/mock/erc20/ERC20Mock__factory.d.ts +1 -1
- package/build/contracts/typechain-types/factories/contracts/mock/erc20/ERC20Mock__factory.d.ts.map +1 -1
- package/build/contracts/typechain-types/factories/contracts/mock/erc20/ERC20Mock__factory.js +1 -1
- package/build/contracts/typechain-types/index.d.ts +4 -10
- package/build/contracts/typechain-types/index.d.ts.map +1 -1
- package/build/contracts/typechain-types/index.js +5 -11
- package/build/entities/AdminOperationThresholds.d.ts +12 -0
- package/build/entities/AdminOperationThresholds.d.ts.map +1 -0
- package/build/entities/AdminOperationThresholds.js +56 -0
- package/build/entities/EscrowRoles.d.ts +12 -0
- package/build/entities/EscrowRoles.d.ts.map +1 -0
- package/build/entities/EscrowRoles.js +57 -0
- package/build/entities/GlobalTimelock.d.ts +14 -0
- package/build/entities/GlobalTimelock.d.ts.map +1 -0
- package/build/entities/GlobalTimelock.js +64 -0
- package/build/entities/GranularTimelock .d.ts +12 -0
- package/build/entities/GranularTimelock .d.ts.map +1 -0
- package/build/entities/GranularTimelock .js +56 -0
- package/build/entities/OperationType.d.ts +18 -0
- package/build/entities/OperationType.d.ts.map +1 -0
- package/build/entities/OperationType.js +50 -0
- package/build/entities/RoleHash.d.ts +11 -0
- package/build/entities/RoleHash.d.ts.map +1 -0
- package/build/entities/RoleHash.js +52 -0
- package/build/entities/Signatures.d.ts +16 -0
- package/build/entities/Signatures.d.ts.map +1 -0
- package/build/entities/Signatures.js +72 -0
- package/build/entities/TokenExecutionThresholds.d.ts +16 -0
- package/build/entities/TokenExecutionThresholds.d.ts.map +1 -0
- package/build/entities/TokenExecutionThresholds.js +72 -0
- package/build/index.d.ts +1 -0
- package/build/index.d.ts.map +1 -1
- package/build/index.js +4 -2
- package/build/services/ChainManager.d.ts.map +1 -1
- package/build/services/db/roles/ContractRoles.d.ts +54 -0
- package/build/services/db/roles/ContractRoles.d.ts.map +1 -0
- package/build/services/db/roles/ContractRoles.js +81 -0
- package/package.json +1 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Signatures = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
let Signatures = class Signatures {
|
|
15
|
+
};
|
|
16
|
+
exports.Signatures = Signatures;
|
|
17
|
+
__decorate([
|
|
18
|
+
(0, typeorm_1.PrimaryGeneratedColumn)({ type: 'bigint' }),
|
|
19
|
+
__metadata("design:type", Number)
|
|
20
|
+
], Signatures.prototype, "id", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, typeorm_1.Column)({ type: 'int' }),
|
|
23
|
+
__metadata("design:type", Number)
|
|
24
|
+
], Signatures.prototype, "operation_type", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
|
|
27
|
+
__metadata("design:type", Object)
|
|
28
|
+
], Signatures.prototype, "commitment_hash", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, typeorm_1.Column)(),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], Signatures.prototype, "blockchain", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, typeorm_1.Column)({ type: 'varchar' }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], Signatures.prototype, "chain_id", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: false }),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], Signatures.prototype, "contract_address", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true, default: null }),
|
|
43
|
+
__metadata("design:type", Object)
|
|
44
|
+
], Signatures.prototype, "type_data_hash", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true, default: null }),
|
|
47
|
+
__metadata("design:type", Object)
|
|
48
|
+
], Signatures.prototype, "signer_address", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: true, default: null }),
|
|
51
|
+
__metadata("design:type", Object)
|
|
52
|
+
], Signatures.prototype, "v", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true, default: null }),
|
|
55
|
+
__metadata("design:type", Object)
|
|
56
|
+
], Signatures.prototype, "r", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true, default: null }),
|
|
59
|
+
__metadata("design:type", Object)
|
|
60
|
+
], Signatures.prototype, "s", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, typeorm_1.Column)({ type: 'timestamp', default: () => 'CURRENT_TIMESTAMP' }),
|
|
63
|
+
__metadata("design:type", Date)
|
|
64
|
+
], Signatures.prototype, "created_at", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, typeorm_1.Column)({ type: 'timestamp', default: () => 'CURRENT_TIMESTAMP' }),
|
|
67
|
+
__metadata("design:type", Date)
|
|
68
|
+
], Signatures.prototype, "updated_at", void 0);
|
|
69
|
+
exports.Signatures = Signatures = __decorate([
|
|
70
|
+
(0, typeorm_1.Entity)({ name: "crypto_signatures", schema: "" }),
|
|
71
|
+
(0, typeorm_1.Unique)(['blockchain', 'chain_id', 'contract_address', 'operation_type', 'reference_id', 'signer_address'])
|
|
72
|
+
], Signatures);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export declare class TokenExecutionThresholds {
|
|
2
|
+
id: number;
|
|
3
|
+
operation_type: number;
|
|
4
|
+
blockchain: string;
|
|
5
|
+
chain_id: string;
|
|
6
|
+
escrow_address: string;
|
|
7
|
+
token_address: string;
|
|
8
|
+
thresholdAmount: number;
|
|
9
|
+
sigsExecutiveBelow: number;
|
|
10
|
+
sigsExecutiveAbove: number;
|
|
11
|
+
sigsManagerBelow: number;
|
|
12
|
+
sigsManagerAbove: number;
|
|
13
|
+
created_at: Date;
|
|
14
|
+
updated_at: Date;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=TokenExecutionThresholds.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TokenExecutionThresholds.d.ts","sourceRoot":"","sources":["../../src/entities/TokenExecutionThresholds.ts"],"names":[],"mappings":"AAEA,qBAEa,wBAAwB;IAEjC,EAAE,EAAG,MAAM,CAAC;IAGZ,cAAc,EAAG,MAAM,CAAC;IAGxB,UAAU,EAAG,MAAM,CAAC;IAGpB,QAAQ,EAAG,MAAM,CAAC;IAGlB,cAAc,EAAG,MAAM,CAAC;IAGxB,aAAa,EAAG,MAAM,CAAC;IAGvB,eAAe,EAAG,MAAM,CAAC;IAGzB,kBAAkB,EAAG,MAAM,CAAC;IAG5B,kBAAkB,EAAG,MAAM,CAAC;IAG5B,gBAAgB,EAAG,MAAM,CAAC;IAG1B,gBAAgB,EAAG,MAAM,CAAC;IAG1B,UAAU,EAAG,IAAI,CAAC;IAGlB,UAAU,EAAG,IAAI,CAAC;CACrB"}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.TokenExecutionThresholds = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
let TokenExecutionThresholds = class TokenExecutionThresholds {
|
|
15
|
+
};
|
|
16
|
+
exports.TokenExecutionThresholds = TokenExecutionThresholds;
|
|
17
|
+
__decorate([
|
|
18
|
+
(0, typeorm_1.PrimaryGeneratedColumn)({ type: 'bigint' }),
|
|
19
|
+
__metadata("design:type", Number)
|
|
20
|
+
], TokenExecutionThresholds.prototype, "id", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, typeorm_1.Column)(),
|
|
23
|
+
__metadata("design:type", Number)
|
|
24
|
+
], TokenExecutionThresholds.prototype, "operation_type", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, typeorm_1.Column)(),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], TokenExecutionThresholds.prototype, "blockchain", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, typeorm_1.Column)({ type: 'varchar' }),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], TokenExecutionThresholds.prototype, "chain_id", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, typeorm_1.Column)({ type: 'varchar' }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], TokenExecutionThresholds.prototype, "escrow_address", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, typeorm_1.Column)({ type: 'varchar' }),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], TokenExecutionThresholds.prototype, "token_address", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, typeorm_1.Column)({ type: 'numeric' }),
|
|
43
|
+
__metadata("design:type", Number)
|
|
44
|
+
], TokenExecutionThresholds.prototype, "thresholdAmount", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, typeorm_1.Column)(),
|
|
47
|
+
__metadata("design:type", Number)
|
|
48
|
+
], TokenExecutionThresholds.prototype, "sigsExecutiveBelow", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, typeorm_1.Column)(),
|
|
51
|
+
__metadata("design:type", Number)
|
|
52
|
+
], TokenExecutionThresholds.prototype, "sigsExecutiveAbove", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, typeorm_1.Column)(),
|
|
55
|
+
__metadata("design:type", Number)
|
|
56
|
+
], TokenExecutionThresholds.prototype, "sigsManagerBelow", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, typeorm_1.Column)(),
|
|
59
|
+
__metadata("design:type", Number)
|
|
60
|
+
], TokenExecutionThresholds.prototype, "sigsManagerAbove", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, typeorm_1.Column)({ type: 'timestamp', default: () => 'CURRENT_TIMESTAMP' }),
|
|
63
|
+
__metadata("design:type", Date)
|
|
64
|
+
], TokenExecutionThresholds.prototype, "created_at", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, typeorm_1.Column)({ type: 'timestamp', default: () => 'CURRENT_TIMESTAMP' }),
|
|
67
|
+
__metadata("design:type", Date)
|
|
68
|
+
], TokenExecutionThresholds.prototype, "updated_at", void 0);
|
|
69
|
+
exports.TokenExecutionThresholds = TokenExecutionThresholds = __decorate([
|
|
70
|
+
(0, typeorm_1.Entity)({ name: "crypto_token_execution_thresholds", schema: "" }),
|
|
71
|
+
(0, typeorm_1.Unique)(['blockchain', 'chain_id', 'escrow_address', 'token_address'])
|
|
72
|
+
], TokenExecutionThresholds);
|
package/build/index.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ export { default as AlchemyWebhooks } from './services/AlchemyWebhooks';
|
|
|
8
8
|
export { default as AlchemyWebhookSignature } from './services/AlchemyWebhookSignature';
|
|
9
9
|
export { default as BalanceService } from './services/BalanceService';
|
|
10
10
|
export { default as ChainManager } from './services/ChainManager';
|
|
11
|
+
export { default as ContractRoles } from './services/db/roles/ContractRoles';
|
|
11
12
|
export { default as ClaimHistoryService } from './services/ClaimHistoryService';
|
|
12
13
|
export { default as ClaimJobService } from './services/ClaimJobService';
|
|
13
14
|
export { default as DepositAddressService } from './services/DepositAddressService';
|
package/build/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACvE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AAClF,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAC5E,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,EAAE,OAAO,IAAI,4BAA4B,EAAE,MAAM,yCAAyC,CAAC;AAClG,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAAE,OAAO,IAAI,uBAAuB,EAAE,MAAM,oCAAoC,CAAC;AACxF,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAChF,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAAE,OAAO,IAAI,qBAAqB,EAAE,MAAM,kCAAkC,CAAC;AACpF,OAAO,EAAE,OAAO,IAAI,4BAA4B,EAAE,MAAM,yCAAyC,CAAC;AAClG,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACpE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACpE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM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AAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,mCAAmC,CAAC;AACzE,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAC1E,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AACvE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,iDAAiD,CAAC;AACjG,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,0CAA0C,CAAC;AAEnF,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,0CAA0C,CAAC;AAChF,cAAc,uCAAuC,CAAC;AACtD,cAAc,yBAAyB,CAAC;AAIxC,cAAc,0BAA0B,CAAC;AAGzC,cAAc,6BAA6B,CAAC;AAC5C,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,eAAe,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,qDAAqD,CAAC;AAG/I,cAAc,yBAAyB,CAAC;AACxC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC;AAEvC,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAGtD,cAAc,cAAc,CAAC;AAG7B,cAAc,uBAAuB,CAAC;AACtC,cAAc,qBAAqB,CAAC"}
|
package/build/index.js
CHANGED
|
@@ -40,8 +40,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
40
40
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
41
41
|
};
|
|
42
42
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
43
|
-
exports.
|
|
44
|
-
exports.AppErrors = exports.EscrowIdl = exports.CoverageInfo = exports.EscrowEvents = exports.Erc20Events = exports.AccessControlEvents = exports.ERC20Abi = exports.ErrorAbi = exports.EscrowAbi = exports.ERC20MockAbi = exports.BaseErrors = exports.VoltageErrors = exports.AlchemyErrors = exports.WalletErrors = exports.DatabaseErrors = exports.BalanceErrors = exports.AdminErrors = void 0;
|
|
43
|
+
exports.EscrowInteraction = exports.QnWebhookAddressManager = exports.SetupNotifications = exports.QnNotificationsApi = exports.QuicknodeWebhookSignature = exports.Worker = exports.WithdrawalManager = exports.WalletManagerHelper = exports.WalletManager = exports.WalletIndexService = exports.SweepHistoryService = exports.SweepJobService = exports.StorageService = exports.ProviderManager = exports.Provider = exports.TronFundingWallet = exports.TronCustodialWallet = exports.TronHotWallet = exports.TronHelper = exports.TronTransaction = exports.TronSigner = exports.TimerManager = exports.RpcLimiter = exports.RedisPubSub = exports.RedisListQueue = exports.RedisQueue = exports.Redis = exports.MemoryMonitor = exports.Logger = exports.KeyVaultHandler = exports.InvoiceQueue = exports.EscrowService = exports.EventsService = exports.EventsHandler = exports.ElasticSearch = exports.DepositAddressArchiveService = exports.DepositAddressService = exports.ClaimJobService = exports.ClaimHistoryService = exports.ContractRoles = exports.ChainManager = exports.BalanceService = exports.AlchemyWebhookSignature = exports.AlchemyWebhooks = exports.AlchemyWebhookAddressManager = exports.AlchemyService = exports.AccountingService = exports.AzureEventHubHandler = exports.AsyncTTLCache = exports.AsyncRateLimiter = void 0;
|
|
44
|
+
exports.AppErrors = exports.EscrowIdl = exports.CoverageInfo = exports.EscrowEvents = exports.Erc20Events = exports.AccessControlEvents = exports.ERC20Abi = exports.ErrorAbi = exports.EscrowAbi = exports.ERC20MockAbi = exports.BaseErrors = exports.VoltageErrors = exports.AlchemyErrors = exports.WalletErrors = exports.DatabaseErrors = exports.BalanceErrors = exports.AdminErrors = exports.TransactionsErrors = void 0;
|
|
45
45
|
// Services
|
|
46
46
|
var AsyncRateLimiter_1 = require("./utils/AsyncRateLimiter");
|
|
47
47
|
Object.defineProperty(exports, "AsyncRateLimiter", { enumerable: true, get: function () { return __importDefault(AsyncRateLimiter_1).default; } });
|
|
@@ -63,6 +63,8 @@ var BalanceService_1 = require("./services/BalanceService");
|
|
|
63
63
|
Object.defineProperty(exports, "BalanceService", { enumerable: true, get: function () { return __importDefault(BalanceService_1).default; } });
|
|
64
64
|
var ChainManager_1 = require("./services/ChainManager");
|
|
65
65
|
Object.defineProperty(exports, "ChainManager", { enumerable: true, get: function () { return __importDefault(ChainManager_1).default; } });
|
|
66
|
+
var ContractRoles_1 = require("./services/db/roles/ContractRoles");
|
|
67
|
+
Object.defineProperty(exports, "ContractRoles", { enumerable: true, get: function () { return __importDefault(ContractRoles_1).default; } });
|
|
66
68
|
var ClaimHistoryService_1 = require("./services/ClaimHistoryService");
|
|
67
69
|
Object.defineProperty(exports, "ClaimHistoryService", { enumerable: true, get: function () { return __importDefault(ClaimHistoryService_1).default; } });
|
|
68
70
|
var ClaimJobService_1 = require("./services/ClaimJobService");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChainManager.d.ts","sourceRoot":"","sources":["../../src/services/ChainManager.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,OAAO,EAAc,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AACrI,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAIzD,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAE/C,OAAO,EAAE,cAAc,EAAE,6BAA6B,EAAE,0BAA0B,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"ChainManager.d.ts","sourceRoot":"","sources":["../../src/services/ChainManager.ts"],"names":[],"mappings":"AACA,OAAO,U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,EAAE,OAAO;IAKvD,kBAAkB,CAAC,QAAQ,EAAE,OAAO,EAAE,UAAU,EAAE,cAAc;IAUhE,oBAAoB,CAAC,UAAU,EAAE,cAAc;IAOzC,gBAAgB;IAehB,YAAY;IAyBZ,cAAc;IAad,wBAAwB;IAyBxB,oBAAoB;IAenB,oBAAoB,CAAC,QAAQ,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM;IAI7D,2BAA2B,CAAC,QAAQ,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM;IAMpE,kBAAkB,CAAC,QAAQ,EAAE,OAAO;IAOrC,mBAAmB;IA4BnB,mBAAmB;IAkBnB,WAAW;CAepB;AAGD,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { Pool } from "pg";
|
|
2
|
+
import { BlockchainType, ChainId } from "../../../interfaces";
|
|
3
|
+
export interface OperationType {
|
|
4
|
+
id: number;
|
|
5
|
+
name: string;
|
|
6
|
+
description: string;
|
|
7
|
+
createdAt: string;
|
|
8
|
+
}
|
|
9
|
+
export interface ContractRole {
|
|
10
|
+
id: number;
|
|
11
|
+
roleName: string;
|
|
12
|
+
roleAlias: string;
|
|
13
|
+
roleHash: string;
|
|
14
|
+
createdAt: string;
|
|
15
|
+
updatedAt: string;
|
|
16
|
+
}
|
|
17
|
+
export interface RoleOperationType {
|
|
18
|
+
id: number;
|
|
19
|
+
roleId: number;
|
|
20
|
+
operationTypeId: number;
|
|
21
|
+
operationName: string;
|
|
22
|
+
description: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Adapter class for interfacing the DB functions
|
|
26
|
+
* related to escrow contract roles
|
|
27
|
+
*/
|
|
28
|
+
declare class ContractRolesService {
|
|
29
|
+
/**
|
|
30
|
+
* Get the available roles and the associated role hash
|
|
31
|
+
* name and alias name
|
|
32
|
+
* @returns ContractRole[]
|
|
33
|
+
*/
|
|
34
|
+
static get_roles(pool: Pool): Promise<ContractRole[]>;
|
|
35
|
+
/**
|
|
36
|
+
* Gets the possible operation types for all available
|
|
37
|
+
* roles.
|
|
38
|
+
* @param pool The PG connection pool for the SQL execution
|
|
39
|
+
* @returns OperationType[]
|
|
40
|
+
*/
|
|
41
|
+
static get_all_operation_types(pool: Pool): Promise<OperationType[]>;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @param pool The PG connection pool for the SQL execution
|
|
45
|
+
* @param role_id id of the role to get the optypes for
|
|
46
|
+
*/
|
|
47
|
+
static get_role_operation_types(pool: Pool, role_id: number): Promise<RoleOperationType[]>;
|
|
48
|
+
/** Records an on-chain role grant for a wallet on an escrow contract. `confirmed` indicates whether the tx was finalised. */
|
|
49
|
+
static fn_grant_escrow_role(pool: Pool, blockchain: BlockchainType, chain_id: ChainId, contract_address: string, wallet_address: string, role_hash: string, confirmed: boolean, p_caller: string, p_sender: string, p_tx_hash: string, p_timestamp: number, p_block_number: number, gas_used: number): Promise<any[]>;
|
|
50
|
+
/** Records an on-chain role revocation for a wallet on an escrow contract. `confirmed` indicates whether the tx was finalised. */
|
|
51
|
+
static fn_revoke_escrow_role(pool: Pool, blockchain: BlockchainType, chain_id: ChainId, contract_address: string, wallet_address: string, role_hash: string, confirmed: boolean, p_caller: string, p_sender: string, p_tx_hash: string, p_timestamp: number, p_block_number: number, gas_used: number): Promise<any[]>;
|
|
52
|
+
}
|
|
53
|
+
export default ContractRolesService;
|
|
54
|
+
//# sourceMappingURL=ContractRoles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContractRoles.d.ts","sourceRoot":"","sources":["../../../../src/services/db/roles/ContractRoles.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,IAAI,EAAE,MAAM,IAAI,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9D,MAAM,WAAW,aAAa;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;I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E,OAAO,EAAE,gBAAgB,EAAE,MAAM,EAC3C,cAAc,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EACzC,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EACpC,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EACnC,WAAW,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,EAC3C,QAAQ,EAAE,MAAM;CAavB;AAED,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,81 @@
|
|
|
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
|
+
/**
|
|
13
|
+
* Adapter class for interfacing the DB functions
|
|
14
|
+
* related to escrow contract roles
|
|
15
|
+
*/
|
|
16
|
+
class ContractRolesService {
|
|
17
|
+
/**
|
|
18
|
+
* Get the available roles and the associated role hash
|
|
19
|
+
* name and alias name
|
|
20
|
+
* @returns ContractRole[]
|
|
21
|
+
*/
|
|
22
|
+
static get_roles(pool) {
|
|
23
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
+
const result = yield pool.query(`
|
|
25
|
+
SELECT multisig.fn_get_roles()
|
|
26
|
+
`);
|
|
27
|
+
if (!result)
|
|
28
|
+
throw new Error(`DB FN error: multisig.fn_get_roles()`);
|
|
29
|
+
return result.rows;
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Gets the possible operation types for all available
|
|
34
|
+
* roles.
|
|
35
|
+
* @param pool The PG connection pool for the SQL execution
|
|
36
|
+
* @returns OperationType[]
|
|
37
|
+
*/
|
|
38
|
+
static get_all_operation_types(pool) {
|
|
39
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
40
|
+
const result = yield pool.query(`
|
|
41
|
+
SELECT multisig.fn_get_all_operation_types()
|
|
42
|
+
`);
|
|
43
|
+
return result.rows;
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @param pool The PG connection pool for the SQL execution
|
|
49
|
+
* @param role_id id of the role to get the optypes for
|
|
50
|
+
*/
|
|
51
|
+
static get_role_operation_types(pool, role_id) {
|
|
52
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
53
|
+
const result = yield pool.query(`
|
|
54
|
+
SELECT multisig.fn_get_role_operation_types($1::bigint)
|
|
55
|
+
`, [role_id]);
|
|
56
|
+
if (!result)
|
|
57
|
+
throw new Error(`DB FN error: multisig.gn_get_role_operation_types()`);
|
|
58
|
+
return result.rows;
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
/** Records an on-chain role grant for a wallet on an escrow contract. `confirmed` indicates whether the tx was finalised. */
|
|
62
|
+
static fn_grant_escrow_role(pool, blockchain, chain_id, contract_address, wallet_address, role_hash, confirmed, p_caller, p_sender, p_tx_hash, p_timestamp, p_block_number, gas_used) {
|
|
63
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
64
|
+
const result = yield pool.query(`
|
|
65
|
+
SELECT multisig.fn_grant_escrow_role($1::text,$2::text,$3::text,$4::text,$5::text,$6::boolean,$7::text,$8::text,$9::text,$10::bigint,$11::bigint,$12::numeric)
|
|
66
|
+
`, [blockchain, chain_id, contract_address, wallet_address, role_hash, confirmed, p_caller, p_sender, p_tx_hash, p_timestamp, p_block_number, gas_used]);
|
|
67
|
+
return result.rows;
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
/** Records an on-chain role revocation for a wallet on an escrow contract. `confirmed` indicates whether the tx was finalised. */
|
|
71
|
+
static fn_revoke_escrow_role(pool, blockchain, chain_id, contract_address, wallet_address, role_hash, confirmed, p_caller, p_sender, p_tx_hash, p_timestamp, p_block_number, gas_used) {
|
|
72
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
73
|
+
const result = yield pool.query(`
|
|
74
|
+
SELECT multisig.fn_revoke_escrow_role($1::text,$2::text,$3::text,$4::text,$5::text,$6::boolean,$7::text,$8::text,$9::text,$10::bigint,$11::bigint,$12::numeric)
|
|
75
|
+
`, [blockchain, chain_id, contract_address, wallet_address, role_hash, confirmed, p_caller, p_sender, p_tx_hash, p_timestamp, p_block_number, gas_used]);
|
|
76
|
+
return result.rows;
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
exports.default = ContractRolesService;
|
|
81
|
+
const fn_get_role_op_types = [{ "id": 1, "roleId": 1, "operationTypeId": 5, "operationName": "CONFIG_TIMELOCK", "description": "Configure timelock operation" }];
|