@reyaxyz/risk-sdk 0.7.179 → 0.7.181
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.
|
@@ -48,7 +48,7 @@ var RiskClient = /** @class */ (function () {
|
|
|
48
48
|
enumerable: false,
|
|
49
49
|
configurable: true
|
|
50
50
|
});
|
|
51
|
-
RiskClient.config = (0, common_1.getApiClientConfig)('
|
|
51
|
+
RiskClient.config = (0, common_1.getApiClientConfig)('devnet');
|
|
52
52
|
return RiskClient;
|
|
53
53
|
}());
|
|
54
54
|
exports.RiskClient = RiskClient;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"risk-client.js","sourceRoot":"/","sources":["clients/risk-client.ts"],"names":[],"mappings":";;;;;;AAAA,0CAIyB;AACzB,oEAAoD;AACpD;;GAEG;AACH;IAME;QACE,IAAI,CAAC,iBAAiB,GAAG,IAAI,oBAAgB,CAAC,UAAU,CAAC,YAAY,CAAC,CAAC;IACzE,CAAC;IAEa,oBAAS,GAAvB,UACE,WAAyC,EACzC,YAAoB;QAEpB,UAAU,CAAC,MAAM,GAAG,IAAA,2BAAkB,EAAC,WAAW,CAAC,CAAC;QACpD,UAAU,CAAC,YAAY,GAAG,YAAY,CAAC;QACvC,UAAU,CAAC,QAAQ,GAAG,IAAI,UAAU,EAAE,CAAC;IACzC,CAAC;IAEc,sBAAW,GAA1B;QACE,IAAI,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;YACzB,MAAM,IAAI,KAAK,CACb,iEAAiE,CAClE,CAAC;QACJ,CAAC;QACD,OAAO,UAAU,CAAC,QAAQ,CAAC;IAC7B,CAAC;IAED,sBAAkB,qBAAO;aAAzB;YACE,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;gBAC7B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;YAClD,CAAC;YACD,OAAO,UAAU,CAAC,MAAM,CAAC,KAAK,CAAC;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AC;CAAA,AA7CD,IA6CC;AA7CY,gCAAU","sourcesContent":["import {\n getApiClientConfig,\n ReyaChainId,\n ServiceConfig,\n} from '@reyaxyz/common';\nimport GeofencingClient from './modules/geofencing';\n/**\n * @description Client for Risk\n */\nexport class RiskClient {\n private static instance: RiskClient;\n private static config: ServiceConfig = getApiClientConfig('devnet');\n private static ipInfoApiKey: string;\n private readonly _geofencingClient: GeofencingClient;\n\n private constructor() {\n this._geofencingClient = new GeofencingClient(RiskClient.ipInfoApiKey);\n }\n\n public static configure(\n environment: ServiceConfig['environment'],\n ipInfoApiKey: string,\n ): void {\n RiskClient.config = getApiClientConfig(environment);\n RiskClient.ipInfoApiKey = ipInfoApiKey;\n RiskClient.instance = new RiskClient();\n }\n\n private static getInstance(): RiskClient {\n if (!RiskClient.instance) {\n throw new Error(\n 'RiskClient is not configured. Please configure it before using.',\n );\n }\n return RiskClient.instance;\n }\n\n public static get network(): ReyaChainId {\n if (!RiskClient.config.chain) {\n throw new Error('RiskClient is not configured');\n }\n return RiskClient.config.chain;\n }\n\n /**\n * Provides access to the GeofencingClient instance.\n * This getter allows for interacting with GeofencingClient related API functionalities.\n *\n * @returns {GeofencingClient} An instance of GeofencingClient for account-related operations.\n * @memberof RiskClient\n */\n public static get geofencing(): GeofencingClient {\n return RiskClient.getInstance()._geofencingClient;\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"risk-client.d.ts","sourceRoot":"/","sources":["clients/risk-client.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,EACX,aAAa,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,gBAAgB,MAAM,sBAAsB,CAAC;AACpD;;GAEG;AACH,qBAAa,UAAU;IACrB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAa;IACpC,OAAO,CAAC,MAAM,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"risk-client.d.ts","sourceRoot":"/","sources":["clients/risk-client.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,EACX,aAAa,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,gBAAgB,MAAM,sBAAsB,CAAC;AACpD;;GAEG;AACH,qBAAa,UAAU;IACrB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAa;IACpC,OAAO,CAAC,MAAM,CAAC,MAAM,CAA+C;IACpE,OAAO,CAAC,MAAM,CAAC,YAAY,CAAS;IACpC,OAAO,CAAC,QAAQ,CAAC,iBAAiB,CAAmB;IAErD,OAAO;WAIO,SAAS,CACrB,WAAW,EAAE,aAAa,CAAC,aAAa,CAAC,EACzC,YAAY,EAAE,MAAM,GACnB,IAAI;IAMP,OAAO,CAAC,MAAM,CAAC,WAAW;IAS1B,WAAkB,OAAO,IAAI,WAAW,CAKvC;IAED;;;;;;OAMG;IACH,WAAkB,UAAU,IAAI,gBAAgB,CAE/C;CACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reyaxyz/risk-sdk",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.181",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"generate:coverage-badges": "npx istanbul-badges-readme --silent"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@reyaxyz/common": "0.
|
|
36
|
+
"@reyaxyz/common": "0.365.1"
|
|
37
37
|
},
|
|
38
38
|
"packageManager": "pnpm@8.3.1",
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "ff13ef71817cd76722adfd0d4e471e8a4c513344"
|
|
40
40
|
}
|
|
@@ -9,7 +9,7 @@ import GeofencingClient from './modules/geofencing';
|
|
|
9
9
|
*/
|
|
10
10
|
export class RiskClient {
|
|
11
11
|
private static instance: RiskClient;
|
|
12
|
-
private static config: ServiceConfig = getApiClientConfig('
|
|
12
|
+
private static config: ServiceConfig = getApiClientConfig('devnet');
|
|
13
13
|
private static ipInfoApiKey: string;
|
|
14
14
|
private readonly _geofencingClient: GeofencingClient;
|
|
15
15
|
|