@bloque/sdk-compliance 0.0.15 → 0.0.16
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/dist/index.cjs +1 -82
- package/dist/index.js +1 -45
- package/package.json +3 -17
package/dist/index.cjs
CHANGED
|
@@ -1,82 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __webpack_require__ = {};
|
|
3
|
-
(()=>{
|
|
4
|
-
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
-
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
-
enumerable: true,
|
|
7
|
-
get: definition[key]
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
|
-
})();
|
|
11
|
-
(()=>{
|
|
12
|
-
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
-
})();
|
|
14
|
-
(()=>{
|
|
15
|
-
__webpack_require__.r = (exports1)=>{
|
|
16
|
-
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
-
value: 'Module'
|
|
18
|
-
});
|
|
19
|
-
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
-
value: true
|
|
21
|
-
});
|
|
22
|
-
};
|
|
23
|
-
})();
|
|
24
|
-
var __webpack_exports__ = {};
|
|
25
|
-
__webpack_require__.r(__webpack_exports__);
|
|
26
|
-
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
-
KycClient: ()=>KycClient,
|
|
28
|
-
ComplianceClient: ()=>ComplianceClient
|
|
29
|
-
});
|
|
30
|
-
class KycClient {
|
|
31
|
-
httpClient;
|
|
32
|
-
constructor(httpClient){
|
|
33
|
-
this.httpClient = httpClient;
|
|
34
|
-
}
|
|
35
|
-
async startVerification(params) {
|
|
36
|
-
const response = await this.httpClient.request({
|
|
37
|
-
method: 'POST',
|
|
38
|
-
path: '/api/compliance',
|
|
39
|
-
body: {
|
|
40
|
-
urn: params.urn,
|
|
41
|
-
type: 'kyc',
|
|
42
|
-
accompliceType: 'person',
|
|
43
|
-
...params.webhookUrl && {
|
|
44
|
-
webhookUrl: params.webhookUrl
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
return {
|
|
49
|
-
url: response.url,
|
|
50
|
-
status: response.status,
|
|
51
|
-
completedAt: null
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
async getVerification(params) {
|
|
55
|
-
const response = await this.httpClient.request({
|
|
56
|
-
method: 'GET',
|
|
57
|
-
path: `/api/compliance/${params.urn}`
|
|
58
|
-
});
|
|
59
|
-
return {
|
|
60
|
-
status: response.status,
|
|
61
|
-
url: response.verification_url,
|
|
62
|
-
completedAt: response.completed_at
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
class ComplianceClient {
|
|
67
|
-
httpClient;
|
|
68
|
-
kyc;
|
|
69
|
-
constructor(httpClient){
|
|
70
|
-
this.httpClient = httpClient;
|
|
71
|
-
this.kyc = new KycClient(this.httpClient);
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
exports.ComplianceClient = __webpack_exports__.ComplianceClient;
|
|
75
|
-
exports.KycClient = __webpack_exports__.KycClient;
|
|
76
|
-
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
77
|
-
"ComplianceClient",
|
|
78
|
-
"KycClient"
|
|
79
|
-
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
80
|
-
Object.defineProperty(exports, '__esModule', {
|
|
81
|
-
value: true
|
|
82
|
-
});
|
|
1
|
+
"use strict";const __rslib_import_meta_url__="u"<typeof document?new(require("url".replace("",""))).URL("file:"+__filename).href:document.currentScript&&document.currentScript.src||new URL("main.js",document.baseURI).href;var __webpack_require__={};__webpack_require__.d=(e,t)=>{for(var _ in t)__webpack_require__.o(t,_)&&!__webpack_require__.o(e,_)&&Object.defineProperty(e,_,{enumerable:!0,get:t[_]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{KycClient:()=>KycClient,ComplianceClient:()=>ComplianceClient});class KycClient{httpClient;constructor(e){this.httpClient=e}async startVerification(e){let t=await this.httpClient.request({method:"POST",path:"/api/compliance",body:{urn:e.urn,type:"kyc",accompliceType:"person",...e.webhookUrl&&{webhookUrl:e.webhookUrl}}});return{url:t.url,status:t.status,completedAt:null}}async getVerification(e){let t=await this.httpClient.request({method:"GET",path:`/api/compliance/${e.urn}`});return{status:t.status,url:t.verification_url,completedAt:t.completed_at}}}class ComplianceClient{httpClient;kyc;constructor(e){this.httpClient=e,this.kyc=new KycClient(this.httpClient)}}for(var __rspack_i in exports.ComplianceClient=__webpack_exports__.ComplianceClient,exports.KycClient=__webpack_exports__.KycClient,__webpack_exports__)-1===["ComplianceClient","KycClient"].indexOf(__rspack_i)&&(exports[__rspack_i]=__webpack_exports__[__rspack_i]);Object.defineProperty(exports,"__esModule",{value:!0});
|
package/dist/index.js
CHANGED
|
@@ -1,45 +1 @@
|
|
|
1
|
-
class
|
|
2
|
-
httpClient;
|
|
3
|
-
constructor(httpClient){
|
|
4
|
-
this.httpClient = httpClient;
|
|
5
|
-
}
|
|
6
|
-
async startVerification(params) {
|
|
7
|
-
const response = await this.httpClient.request({
|
|
8
|
-
method: 'POST',
|
|
9
|
-
path: '/api/compliance',
|
|
10
|
-
body: {
|
|
11
|
-
urn: params.urn,
|
|
12
|
-
type: 'kyc',
|
|
13
|
-
accompliceType: 'person',
|
|
14
|
-
...params.webhookUrl && {
|
|
15
|
-
webhookUrl: params.webhookUrl
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
return {
|
|
20
|
-
url: response.url,
|
|
21
|
-
status: response.status,
|
|
22
|
-
completedAt: null
|
|
23
|
-
};
|
|
24
|
-
}
|
|
25
|
-
async getVerification(params) {
|
|
26
|
-
const response = await this.httpClient.request({
|
|
27
|
-
method: 'GET',
|
|
28
|
-
path: `/api/compliance/${params.urn}`
|
|
29
|
-
});
|
|
30
|
-
return {
|
|
31
|
-
status: response.status,
|
|
32
|
-
url: response.verification_url,
|
|
33
|
-
completedAt: response.completed_at
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
class ComplianceClient {
|
|
38
|
-
httpClient;
|
|
39
|
-
kyc;
|
|
40
|
-
constructor(httpClient){
|
|
41
|
-
this.httpClient = httpClient;
|
|
42
|
-
this.kyc = new KycClient(this.httpClient);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
export { ComplianceClient, KycClient };
|
|
1
|
+
class t{httpClient;constructor(t){this.httpClient=t}async startVerification(t){let e=await this.httpClient.request({method:"POST",path:"/api/compliance",body:{urn:t.urn,type:"kyc",accompliceType:"person",...t.webhookUrl&&{webhookUrl:t.webhookUrl}}});return{url:e.url,status:e.status,completedAt:null}}async getVerification(t){let e=await this.httpClient.request({method:"GET",path:`/api/compliance/${t.urn}`});return{status:e.status,url:e.verification_url,completedAt:e.completed_at}}}class e{httpClient;kyc;constructor(e){this.httpClient=e,this.kyc=new t(this.httpClient)}}export{e as ComplianceClient,t as KycClient};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bloque/sdk-compliance",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"bloque",
|
|
@@ -33,21 +33,7 @@
|
|
|
33
33
|
"engines": {
|
|
34
34
|
"node": ">=22"
|
|
35
35
|
},
|
|
36
|
-
"scripts": {
|
|
37
|
-
"release": "bun publish --provenance",
|
|
38
|
-
"build": "rslib build",
|
|
39
|
-
"dev": "rslib build --watch",
|
|
40
|
-
"clean": "rm -rf node_modules && rm -rf dist",
|
|
41
|
-
"check": "biome check --write",
|
|
42
|
-
"typecheck": "tsgo --noEmit"
|
|
43
|
-
},
|
|
44
36
|
"dependencies": {
|
|
45
|
-
"@bloque/sdk-core": "0.0.
|
|
46
|
-
},
|
|
47
|
-
"devDependencies": {
|
|
48
|
-
"@rslib/core": "^0.18.4",
|
|
49
|
-
"@types/node": "^24.10.1",
|
|
50
|
-
"@typescript/native-preview": "latest",
|
|
51
|
-
"typescript": "^5.9.3"
|
|
37
|
+
"@bloque/sdk-core": "0.0.16"
|
|
52
38
|
}
|
|
53
|
-
}
|
|
39
|
+
}
|