@kynesyslabs/demosdk 2.3.14 → 2.3.15
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/demoswork/utils/createTestWorkScript.js +1 -2
- package/build/demoswork/utils/createTestWorkScript.js.map +1 -1
- package/build/demoswork/workstep.d.ts +2 -2
- package/build/demoswork/workstep.js +3 -4
- package/build/demoswork/workstep.js.map +1 -1
- package/build/types/index.d.ts +1 -1
- package/build/types/index.js +1 -2
- package/build/types/index.js.map +1 -1
- package/build/types/web2/index.d.ts +12 -16
- package/build/types/web2/index.js +1 -10
- package/build/types/web2/index.js.map +1 -1
- package/build/websdk/Web2Calls.d.ts +0 -5
- package/build/websdk/Web2Calls.js +43 -42
- package/build/websdk/Web2Calls.js.map +1 -1
- package/build/websdk/examples/tryWeb2.js +62 -16
- package/build/websdk/examples/tryWeb2.js.map +1 -1
- package/build/websdk/utils/skeletons.js +1 -1
- package/build/websdk/utils/skeletons.js.map +1 -1
- package/package.json +1 -1
|
@@ -11,7 +11,6 @@ const workstep_1 = require("../workstep");
|
|
|
11
11
|
const core_1 = require("../../multichain/core");
|
|
12
12
|
const steps_1 = require("../../types/demoswork/steps");
|
|
13
13
|
const websdk_1 = require("../../websdk");
|
|
14
|
-
const types_1 = require("../../types");
|
|
15
14
|
const conditional_1 = require("../operations/conditional");
|
|
16
15
|
const baseoperation_1 = require("../operations/baseoperation");
|
|
17
16
|
async function createTestWorkScript() {
|
|
@@ -40,7 +39,7 @@ async function createTestWorkScript() {
|
|
|
40
39
|
// WEB2 STEP
|
|
41
40
|
const sendHash = (0, workstep_1.prepareWeb2Step)({
|
|
42
41
|
url: "https://icanhazip.com",
|
|
43
|
-
method:
|
|
42
|
+
method: "GET",
|
|
44
43
|
});
|
|
45
44
|
sendHash.description = "Send xm hash to HTTP API";
|
|
46
45
|
const operation = new conditional_1.ConditionalOperation();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createTestWorkScript.js","sourceRoot":"","sources":["../../../../src/demoswork/utils/createTestWorkScript.ts"],"names":[],"mappings":";;;;;AAYA,uCA6DC;AAzED,uFAA8D;AAC9D,wBAA6B;AAC7B,kCAA4D;AAC5D,0CAA4D;AAE5D,4CAAuC;AACvC,mDAAsD;AACtD,qCAA8C;
|
|
1
|
+
{"version":3,"file":"createTestWorkScript.js","sourceRoot":"","sources":["../../../../src/demoswork/utils/createTestWorkScript.ts"],"names":[],"mappings":";;;;;AAYA,uCA6DC;AAzED,uFAA8D;AAC9D,wBAA6B;AAC7B,kCAA4D;AAC5D,0CAA4D;AAE5D,4CAAuC;AACvC,mDAAsD;AACtD,qCAA8C;AAE9C,2DAAgE;AAChE,+DAA2D;AAE5C,KAAK,UAAU,oBAAoB;IAC9C,MAAM,IAAI,GAAG,IAAI,gBAAS,EAAE,CAAA;IAE5B,MAAM,GAAG,GAAG,IAAA,YAAS,GAAE,CAAA;IACvB,MAAM,GAAG,GAAG,MAAM,UAAG,CAAC,MAAM,CAAC,wBAAc,CAAC,GAAG,CAAC,OAAO,CAAC,CAAA;IACxD,MAAM,GAAG,CAAC,aAAa,CACnB,kEAAkE,CACrE,CAAA;IACD,MAAM,OAAO,GAAG,MAAM,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC,UAAU,EAAE,EAAE,QAAQ,CAAC,CAAA;IAChE,MAAM,OAAO,GAAG,IAAA,wBAAa,EAAC;QAC1B,UAAU,EAAE;YACR,CAAC,GAAG,CAAC,EAAE;gBACH,KAAK,EAAE,KAAK;gBACZ,MAAM,EAAE,IAAI;gBACZ,GAAG,EAAE,IAAI;gBACT,QAAQ,EAAE,SAAS;gBACnB,IAAI,EAAE;oBACF,MAAM,EAAE,IAAI;oBACZ,cAAc,EAAE,CAAC,OAAO,CAAC;oBACzB,IAAI,EAAE,KAAK;iBACd;aACJ;SACJ;QACD,gBAAgB,EAAE,CAAC,GAAG,CAAC;KAC1B,CAAC,CAAA;IACF,OAAO,CAAC,WAAW,GAAG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MScript } from "../types";
|
|
2
2
|
import { INativePayload } from "../types/native";
|
|
3
3
|
import { StepOutputKey, WorkStepInput } from "../types/demoswork/steps";
|
|
4
4
|
export declare class WorkStep {
|
|
@@ -29,7 +29,7 @@ export declare class NativeWorkStep extends WorkStep {
|
|
|
29
29
|
}
|
|
30
30
|
export declare function prepareXMStep(xm_payload: XMScript): XmWorkStep;
|
|
31
31
|
export declare function prepareWeb2Step({ method, url, parameters, headers, }: {
|
|
32
|
-
method?:
|
|
32
|
+
method?: Web2Method;
|
|
33
33
|
url?: string;
|
|
34
34
|
parameters?: any[];
|
|
35
35
|
headers?: any;
|
|
@@ -6,9 +6,8 @@ exports.prepareWeb2Step = prepareWeb2Step;
|
|
|
6
6
|
exports.prepareNativeStep = prepareNativeStep;
|
|
7
7
|
const utils_1 = require("./utils");
|
|
8
8
|
const websdk_1 = require("../websdk");
|
|
9
|
-
const types_1 = require("../types");
|
|
10
9
|
const datatypes_1 = require("../types/demoswork/datatypes");
|
|
11
|
-
const
|
|
10
|
+
const types_1 = require("../types");
|
|
12
11
|
class WorkStep {
|
|
13
12
|
constructor(payload) {
|
|
14
13
|
this.timestamp = Date.now();
|
|
@@ -66,10 +65,10 @@ exports.NativeWorkStep = NativeWorkStep;
|
|
|
66
65
|
function prepareXMStep(xm_payload) {
|
|
67
66
|
return new XmWorkStep(xm_payload);
|
|
68
67
|
}
|
|
69
|
-
function prepareWeb2Step({ method =
|
|
68
|
+
function prepareWeb2Step({ method = "GET", url = "https://icanhazip.com", parameters = [], headers = null, }) {
|
|
70
69
|
// Generating an empty request and filling it
|
|
71
70
|
const web2_payload = structuredClone(websdk_1.skeletons.web2_request);
|
|
72
|
-
web2_payload.raw.action =
|
|
71
|
+
web2_payload.raw.action = types_1.EnumWeb2Actions.CREATE;
|
|
73
72
|
web2_payload.raw.method = method;
|
|
74
73
|
web2_payload.raw.url = url;
|
|
75
74
|
web2_payload.raw.parameters = parameters;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workstep.js","sourceRoot":"","sources":["../../../src/demoswork/workstep.ts"],"names":[],"mappings":";;;AA2EA,sCAEC;AAED,0CAqBC;AAED,8CAEC;AAxGD,mCAAmC;AAEnC,qCAAoC;
|
|
1
|
+
{"version":3,"file":"workstep.js","sourceRoot":"","sources":["../../../src/demoswork/workstep.ts"],"names":[],"mappings":";;;AA2EA,sCAEC;AAED,0CAqBC;AAED,8CAEC;AAxGD,mCAAmC;AAEnC,qCAAoC;AAGpC,2DAAuD;AAEvD,mCAAyC;AAEzC,MAAa,QAAQ;IASjB,YAAY,OAAsB;QAJlC,cAAS,GAAW,IAAI,CAAC,GAAG,EAAE,CAAA;QAC9B,aAAQ,GAAY,KAAK,CAAA;QACzB,eAAU,GAAa,EAAE,CAAA;QAGrB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;QACtB,IAAI,CAAC,EAAE,GAAG,OAAO,GAAG,IAAA,iBAAS,GAAE,CAAA;IACnC,CAAC;IAED,IAAI,MAAM;QACN,OAAO,IAAI,KAAK,CACZ;YACI,IAAI,EAAE,qBAAS,CAAC,IAAI;YACpB,GAAG,EAAE;gBACD,IAAI,EAAE,IAAI;gBACV,GAAG,EAAE,QAAQ;aAChB;SACG,EACR;YACI,GAAG,EAAE,CAAC,MAAM,EAAE,IAAqB,EAAE,EAAE;gBACnC,OAAO;oBACH,IAAI,EAAE,qBAAS,CAAC,IAAI;oBACpB,GAAG,EAAE;wBACD,IAAI,EAAE,IAAI;wBACV,GAAG,EAAE,UAAU,MAAM,CAAC,IAAI,CAAC,EAAE;qBAChC;iBACJ,CAAA;YACL,CAAC;SACJ,CACJ,CAAA;IACL,CAAC;IACD,IAAI,WAAW;QACX,OAAO,IAAI,CAAC,MAAkC,CAAA;IAClD,CAAC;CACJ;AAvCD,4BAuCC;AAED,MAAa,YAAa,SAAQ,QAAQ;IAGtC,YAAY,OAAqB;QAC7B,KAAK,CAAC,OAAO,CAAC,CAAA;QAHT,YAAO,GAAG,MAAM,C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,OAAO,IAAI,cAAc,CAAC,cAAc,CAAC,CAAA;AAC7C,CAAC"}
|
package/build/types/index.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ export { StateChange } from "./gls/StateChange";
|
|
|
18
18
|
export { ExecutionResult } from "./network/ExecutionResult";
|
|
19
19
|
export { ISecurityReport, SIComlink, SIResponseRegistry, } from "./network/SecurityTypes";
|
|
20
20
|
export { IPeerConfig, IPeer } from "./peers/Peer";
|
|
21
|
-
export { IParam, IRawWeb2Request, IWeb2Request, IWeb2Payload, IWeb2Result, ISendHTTPRequestParams, IAuthorizationException, IAuthorizationConfig, IWeb2RequestOptions, IStartProxyParams, IDAHRStartProxyParams,
|
|
21
|
+
export { IParam, IRawWeb2Request, IWeb2Request, IWeb2Payload, IWeb2Result, ISendHTTPRequestParams, IAuthorizationException, IAuthorizationConfig, IWeb2RequestOptions, IStartProxyParams, IDAHRStartProxyParams, Web2Method, EnumWeb2Actions, } from "./web2";
|
|
22
22
|
export { TweetSimplified, Tweet, TwitterTimelineResponse, TwitterProfile, TwitterFollowersResponse } from "./web2/twitter";
|
|
23
23
|
export { TelegramChallengeRequest, TelegramChallengeResponse, TelegramVerificationResponse, TelegramUser, TelegramVerificationRequest } from "./web2/telegram";
|
|
24
24
|
export { EthTransactionResponse, EthTransaction, SolanaTransactionResponse, SolTransaction } from "./xm/apiTools";
|
package/build/types/index.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.isTransactionDataType = exports.isTransactionType = exports.SupportedTokens = exports.SupportedChains = exports.ChainProviders = exports.RPCResponseSkeleton = exports.stepKeysEnum = exports.XmStepResult = exports.DataTypes = exports.EnumWeb2Actions = exports.
|
|
3
|
+
exports.isTransactionDataType = exports.isTransactionType = exports.SupportedTokens = exports.SupportedChains = exports.ChainProviders = exports.RPCResponseSkeleton = exports.stepKeysEnum = exports.XmStepResult = exports.DataTypes = exports.EnumWeb2Actions = exports.CValidityData = void 0;
|
|
4
4
|
var ValidityData_1 = require("./blockchain/ValidityData");
|
|
5
5
|
Object.defineProperty(exports, "CValidityData", { enumerable: true, get: function () { return ValidityData_1.CValidityData; } });
|
|
6
6
|
// web2
|
|
7
7
|
var web2_1 = require("./web2");
|
|
8
|
-
Object.defineProperty(exports, "EnumWeb2Methods", { enumerable: true, get: function () { return web2_1.EnumWeb2Methods; } });
|
|
9
8
|
Object.defineProperty(exports, "EnumWeb2Actions", { enumerable: true, get: function () { return web2_1.EnumWeb2Actions; } });
|
|
10
9
|
var datatypes_1 = require("./demoswork/datatypes");
|
|
11
10
|
Object.defineProperty(exports, "DataTypes", { enumerable: true, get: function () { return datatypes_1.DataTypes; } });
|
package/build/types/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;AAsCA,0DAAuE;AAA9D,6GAAA,aAAa,OAAA;AA+BtB,OAAO;AACP,+BAce;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;AAsCA,0DAAuE;AAA9D,6GAAA,aAAa,OAAA;AA+BtB,OAAO;AACP,+BAce;AADX,uGAAA,eAAe,OAAA;AAgBnB,mDAA4D;AAAnD,sGAAA,SAAS,OAAA;AAOlB,2CAQ0B;AAHtB,qGAAA,YAAY,OAAA;AAEZ,qGAAA,YAAY,OAAA;AAGhB,2CAU4B;AADxB,0GAAA,aAAa,OAAuB;AAgBxC,gDAI2B;AAHvB,2GAAA,cAAc,OAAA;AACd,4GAAA,eAAe,OAAA;AACf,4GAAA,eAAe,OAAA;AAanB,+BAA+B;AAC/B,gEAG+C;AAF3C,0GAAA,iBAAiB,OAAA;AACjB,8GAAA,qBAAqB,OAAA"}
|
|
@@ -10,6 +10,8 @@ export interface IWeb2Result {
|
|
|
10
10
|
statusText: string;
|
|
11
11
|
headers: IncomingHttpHeaders;
|
|
12
12
|
data: any;
|
|
13
|
+
dataHash: string;
|
|
14
|
+
headersHash: string;
|
|
13
15
|
}
|
|
14
16
|
export interface IWeb2Request {
|
|
15
17
|
raw: IRawWeb2Request;
|
|
@@ -28,22 +30,15 @@ export interface IWeb2Payload {
|
|
|
28
30
|
web2Request: IWeb2Request;
|
|
29
31
|
};
|
|
30
32
|
}
|
|
31
|
-
export
|
|
32
|
-
GET = "GET",
|
|
33
|
-
POST = "POST",
|
|
34
|
-
PUT = "PUT",
|
|
35
|
-
DELETE = "DELETE",
|
|
36
|
-
PATCH = "PATCH"
|
|
37
|
-
}
|
|
33
|
+
export type Web2Method = "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
|
|
38
34
|
export declare enum EnumWeb2Actions {
|
|
39
35
|
CREATE = "create",
|
|
40
|
-
START_PROXY = "startProxy"
|
|
41
|
-
STOP_PROXY = "stopProxy"
|
|
36
|
+
START_PROXY = "startProxy"
|
|
42
37
|
}
|
|
43
38
|
export interface IRawWeb2Request {
|
|
44
39
|
action: EnumWeb2Actions;
|
|
45
40
|
parameters: IParam[];
|
|
46
|
-
method:
|
|
41
|
+
method: Web2Method;
|
|
47
42
|
url: string;
|
|
48
43
|
headers?: OutgoingHttpHeaders;
|
|
49
44
|
stage: {
|
|
@@ -55,14 +50,14 @@ export interface IRawWeb2Request {
|
|
|
55
50
|
}
|
|
56
51
|
export interface ISendHTTPRequestParams {
|
|
57
52
|
web2Request: IWeb2Request;
|
|
58
|
-
targetMethod:
|
|
59
|
-
targetHeaders:
|
|
53
|
+
targetMethod: Web2Method;
|
|
54
|
+
targetHeaders: OutgoingHttpHeaders;
|
|
60
55
|
payload: unknown;
|
|
61
56
|
targetAuthorization: string;
|
|
62
57
|
}
|
|
63
58
|
export interface IAuthorizationException {
|
|
64
59
|
urlPattern: RegExp;
|
|
65
|
-
methods:
|
|
60
|
+
methods: Web2Method[];
|
|
66
61
|
}
|
|
67
62
|
export interface IAuthorizationConfig {
|
|
68
63
|
requireAuthForAll: boolean;
|
|
@@ -76,12 +71,13 @@ export interface IWeb2RequestOptions {
|
|
|
76
71
|
}
|
|
77
72
|
export interface IStartProxyParams {
|
|
78
73
|
url: string;
|
|
79
|
-
method:
|
|
74
|
+
method: Web2Method;
|
|
80
75
|
options?: IWeb2RequestOptions;
|
|
81
76
|
}
|
|
82
77
|
export interface IDAHRStartProxyParams {
|
|
83
|
-
|
|
84
|
-
|
|
78
|
+
url: string;
|
|
79
|
+
method: Web2Method;
|
|
80
|
+
headers: OutgoingHttpHeaders;
|
|
85
81
|
payload?: IWeb2RequestOptions["payload"];
|
|
86
82
|
authorization?: IWeb2RequestOptions["authorization"];
|
|
87
83
|
}
|
|
@@ -1,18 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EnumWeb2Actions =
|
|
4
|
-
var EnumWeb2Methods;
|
|
5
|
-
(function (EnumWeb2Methods) {
|
|
6
|
-
EnumWeb2Methods["GET"] = "GET";
|
|
7
|
-
EnumWeb2Methods["POST"] = "POST";
|
|
8
|
-
EnumWeb2Methods["PUT"] = "PUT";
|
|
9
|
-
EnumWeb2Methods["DELETE"] = "DELETE";
|
|
10
|
-
EnumWeb2Methods["PATCH"] = "PATCH";
|
|
11
|
-
})(EnumWeb2Methods || (exports.EnumWeb2Methods = EnumWeb2Methods = {}));
|
|
3
|
+
exports.EnumWeb2Actions = void 0;
|
|
12
4
|
var EnumWeb2Actions;
|
|
13
5
|
(function (EnumWeb2Actions) {
|
|
14
6
|
EnumWeb2Actions["CREATE"] = "create";
|
|
15
7
|
EnumWeb2Actions["START_PROXY"] = "startProxy";
|
|
16
|
-
EnumWeb2Actions["STOP_PROXY"] = "stopProxy";
|
|
17
8
|
})(EnumWeb2Actions || (exports.EnumWeb2Actions = EnumWeb2Actions = {}));
|
|
18
9
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/types/web2/index.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/types/web2/index.ts"],"names":[],"mappings":";;;AAuCA,IAAY,eAGX;AAHD,WAAY,eAAe;IACvB,oCAAiB,CAAA;IACjB,6CAA0B,CAAA;AAC9B,CAAC,EAHW,eAAe,+BAAf,eAAe,QAG1B"}
|
|
@@ -15,11 +15,6 @@ export declare class Web2Proxy {
|
|
|
15
15
|
* @returns {Promise<IWeb2Result>} The result of the proxy.
|
|
16
16
|
*/
|
|
17
17
|
startProxy({ url, method, options, }: IStartProxyParams): Promise<IWeb2Result>;
|
|
18
|
-
/**
|
|
19
|
-
* Stop the proxy.
|
|
20
|
-
* @returns {Promise<void>}
|
|
21
|
-
*/
|
|
22
|
-
stopProxy(): Promise<void>;
|
|
23
18
|
}
|
|
24
19
|
/**
|
|
25
20
|
* The Web2Calls object provides functions for creating and managing Web2 proxies.
|
|
@@ -4,7 +4,6 @@ exports.web2Calls = exports.Web2Proxy = void 0;
|
|
|
4
4
|
const types_1 = require("../types");
|
|
5
5
|
const skeletons_1 = require("./utils/skeletons");
|
|
6
6
|
const DemosTransactions_1 = require("./DemosTransactions");
|
|
7
|
-
const web2Request = { ...skeletons_1.web2_request };
|
|
8
7
|
class Web2Proxy {
|
|
9
8
|
constructor(sessionId, demos) {
|
|
10
9
|
this._sessionId = sessionId;
|
|
@@ -27,29 +26,51 @@ class Web2Proxy {
|
|
|
27
26
|
payload: {},
|
|
28
27
|
authorization: "",
|
|
29
28
|
}, }) {
|
|
30
|
-
web2Request
|
|
31
|
-
|
|
29
|
+
// Create a fresh copy of web2Request for each call
|
|
30
|
+
const freshWeb2Request = { ...skeletons_1.web2_request };
|
|
31
|
+
freshWeb2Request.raw = {
|
|
32
|
+
...freshWeb2Request.raw,
|
|
32
33
|
action: types_1.EnumWeb2Actions.START_PROXY,
|
|
33
34
|
method,
|
|
34
35
|
url,
|
|
35
36
|
headers: options?.headers,
|
|
36
37
|
};
|
|
37
|
-
|
|
38
|
-
web2Request,
|
|
38
|
+
const response = await this._demos.call("web2ProxyRequest", {
|
|
39
|
+
web2Request: freshWeb2Request,
|
|
39
40
|
sessionId: this._sessionId,
|
|
40
41
|
payload: options?.payload,
|
|
41
42
|
authorization: options?.authorization,
|
|
42
43
|
});
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
44
|
+
const web2Payload = {
|
|
45
|
+
message: {
|
|
46
|
+
sessionId: this._sessionId,
|
|
47
|
+
payload: "",
|
|
48
|
+
authorization: "",
|
|
49
|
+
web2Request: {
|
|
50
|
+
...freshWeb2Request,
|
|
51
|
+
result: {
|
|
52
|
+
sessionId: this._sessionId,
|
|
53
|
+
targetUrl: freshWeb2Request.raw.url,
|
|
54
|
+
timestamp: Date.now(),
|
|
55
|
+
status: response.response.status,
|
|
56
|
+
headers: response.response.headers,
|
|
57
|
+
dataHash: response.response.dataHash,
|
|
58
|
+
headersHash: response.response.headersHash,
|
|
59
|
+
statusText: response.response.statusText,
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
// Create a transaction to store the web2 payload in the blockchain.
|
|
65
|
+
const web2Tx = DemosTransactions_1.DemosTransactions.empty();
|
|
66
|
+
web2Tx.content.to = await this._demos.getEd25519Address();
|
|
67
|
+
web2Tx.content.type = "web2Request";
|
|
68
|
+
web2Tx.content.data = ["web2Request", web2Payload];
|
|
69
|
+
web2Tx.content.timestamp = Date.now();
|
|
70
|
+
const signedWeb2Tx = await this._demos.sign(web2Tx);
|
|
71
|
+
const validityData = await this._demos.confirm(signedWeb2Tx);
|
|
72
|
+
await this._demos.broadcast(validityData);
|
|
73
|
+
return response;
|
|
53
74
|
}
|
|
54
75
|
}
|
|
55
76
|
exports.Web2Proxy = Web2Proxy;
|
|
@@ -67,39 +88,19 @@ exports.web2Calls = {
|
|
|
67
88
|
if (!usedKeyPair) {
|
|
68
89
|
throw new Error("No keypair provided and no wallet connected");
|
|
69
90
|
}
|
|
91
|
+
// Create a fresh copy of web2Request for creation
|
|
92
|
+
const freshWeb2Request = { ...skeletons_1.web2_request };
|
|
93
|
+
freshWeb2Request.raw = {
|
|
94
|
+
...freshWeb2Request.raw,
|
|
95
|
+
action: types_1.EnumWeb2Actions.CREATE,
|
|
96
|
+
};
|
|
70
97
|
const response = await demos.call("web2ProxyRequest", {
|
|
71
|
-
web2Request:
|
|
72
|
-
...web2Request,
|
|
73
|
-
raw: {
|
|
74
|
-
...web2Request.raw,
|
|
75
|
-
action: types_1.EnumWeb2Actions.CREATE,
|
|
76
|
-
},
|
|
77
|
-
},
|
|
98
|
+
web2Request: freshWeb2Request,
|
|
78
99
|
});
|
|
79
100
|
const sessionId = response.response?.dahr?.sessionId;
|
|
80
101
|
if (!sessionId) {
|
|
81
102
|
throw new Error("Failed to create proxy session");
|
|
82
103
|
}
|
|
83
|
-
// Creating a web2 payload
|
|
84
|
-
const web2Payload = {
|
|
85
|
-
message: {
|
|
86
|
-
sessionId: sessionId,
|
|
87
|
-
payload: "",
|
|
88
|
-
authorization: "",
|
|
89
|
-
web2Request: web2Request,
|
|
90
|
-
},
|
|
91
|
-
};
|
|
92
|
-
const web2Tx = DemosTransactions_1.DemosTransactions.empty();
|
|
93
|
-
// From and To are the same in Web2 transactions
|
|
94
|
-
// From will be set during tx signing
|
|
95
|
-
web2Tx.content.to = await demos.getEd25519Address();
|
|
96
|
-
web2Tx.content.type = "web2Request";
|
|
97
|
-
web2Tx.content.data = ["web2Request", web2Payload];
|
|
98
|
-
web2Tx.content.timestamp = Date.now();
|
|
99
|
-
// Signing and broadcasting the transaction
|
|
100
|
-
const signedWeb2Tx = await demos.sign(web2Tx);
|
|
101
|
-
const validityData = await demos.confirm(signedWeb2Tx);
|
|
102
|
-
await demos.broadcast(validityData);
|
|
103
104
|
return new Web2Proxy(sessionId, demos);
|
|
104
105
|
},
|
|
105
106
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Web2Calls.js","sourceRoot":"","sources":["../../../src/websdk/Web2Calls.ts"],"names":[],"mappings":";;;AAAA,mCAAyC;AACzC,iDAAgD;AAChD,2DAAuD;AASvD,
|
|
1
|
+
{"version":3,"file":"Web2Calls.js","sourceRoot":"","sources":["../../../src/websdk/Web2Calls.ts"],"names":[],"mappings":";;;AAAA,mCAAyC;AACzC,iDAAgD;AAChD,2DAAuD;AASvD,MAAa,SAAS;IAIlB,YAAY,SAAiB,EAAE,KAAY;QACvC,IAAI,CAAC,UAAU,GAAG,SAAS,CAAA;QAC3B,IAAI,CAAC,MAAM,GAAG,KAAK,CAAA;IACvB,CAAC;IAED;;;OAGG;IACH,IAAI,SAAS;QACT,OAAO,IAAI,CAAC,UAAU,CAAA;IAC1B,CAAC;IAED;;;;OAIG;IACH,KAAK,CAAC,UAAU,CAAC,EACb,GAAG,EACH,MAAM,EACN,OAAO,GAAG;QACN,OAAO,EAAE,EAAE;QACX,OAAO,EAAE,EAAE;QACX,aAAa,EAAE,EAAE;KACpB,GACe;QAChB,mDAAmD;QACnD,MAAM,gBAAgB,GAAG,EAAE,GAAG,wBAAY,EAAE,CAAA;QAE5C,gBAAgB,CAAC,GAAG,GAAG;YACnB,GAAG,gBAAgB,CAAC,GAAG;YACvB,MAAM,EAAE,uBAAe,CAAC,WAAW;YACnC,MAAM;YACN,GAAG;YACH,OAAO,EAAE,OAAO,EAAE,OAAO;SAC5B,CAAA;QAED,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,kBAAkB,EAAE;YACxD,WAAW,EAAE,gBAAgB;YAC7B,SAAS,EAAE,IAAI,CAAC,UAAU;YAC1B,OAAO,EAAE,OAAO,EAAE,OAAO;YACzB,aAAa,EAAE,OAAO,EAAE,aAAa;SACx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CAAA;QAEzC,OAAO,QAAQ,CAAA;IACnB,CAAC;CACJ;AAnFD,8BAmFC;AAED;;GAEG;AACU,QAAA,SAAS,GAAG;IACrB;;;;OAIG;IACH,UAAU,EAAE,KAAK,EAAE,KAAY,EAAsB,EAAE;QACnD,MAAM,WAAW,GAAG,KAAK,CAAC,OAAO,CAAA;QAEjC,IAAI,CAAC,WAAW,EAAE,CAAC;YACf,MAAM,IAAI,KAAK,CAAC,6CAA6C,CAAC,CAAA;QAClE,CAAC;QAED,kDAAkD;QAClD,MAAM,gBAAgB,GAAG,EAAE,GAAG,wBAAY,EAAE,CAAA;QAC5C,gBAAgB,CAAC,GAAG,GAAG;YACnB,GAAG,gBAAgB,CAAC,GAAG;YACvB,MAAM,EAAE,uBAAe,CAAC,MAAM;SACjC,CAAA;QAED,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,IAAI,CAAC,kBAAkB,EAAE;YAClD,WAAW,EAAE,gBAAgB;SAChC,CAAC,CAAA;QAEF,MAAM,SAAS,GAAG,QAAQ,CAAC,QAAQ,EAAE,IAAI,EAAE,SAAS,CAAA;QACpD,IAAI,CAAC,SAAS,EAAE,CAAC;YACb,MAAM,IAAI,KAAK,CAAC,gCAAgC,CAAC,CAAA;QACrD,CAAC;QAED,OAAO,IAAI,SAAS,CAAC,SAAS,EAAE,KAAK,CAAC,CAAA;IAC1C,CAAC;CACJ,CAAA"}
|
|
@@ -1,35 +1,81 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const types_1 = require("../../types");
|
|
4
3
|
const DemosWebAuth_1 = require("../DemosWebAuth");
|
|
5
4
|
const demosclass_1 = require("../demosclass");
|
|
6
5
|
async function tryWeb2Proxy() {
|
|
7
6
|
try {
|
|
8
|
-
// Connect to demos
|
|
9
7
|
const demos = new demosclass_1.Demos();
|
|
10
8
|
await demos.connect("http://localhost:53550");
|
|
11
|
-
console.log("Connected to demos");
|
|
12
|
-
// Set up wallet
|
|
13
9
|
const identity = DemosWebAuth_1.DemosWebAuth.getInstance();
|
|
14
10
|
await identity.create();
|
|
15
11
|
await demos.connectWallet(identity.keypair.privateKey);
|
|
16
|
-
console.log("Wallet connected");
|
|
17
|
-
// Create proxy instance
|
|
18
12
|
const dahr = await demos.web2.createDahr();
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
13
|
+
// 1) GET with custom headers (including array header)
|
|
14
|
+
const resp1 = await dahr.startProxy({
|
|
15
|
+
url: "https://postman-echo.com/get?tags=dev&tags=api&test=1",
|
|
16
|
+
method: "GET",
|
|
17
|
+
options: {
|
|
18
|
+
headers: {
|
|
19
|
+
"X-Test": "sdk-get",
|
|
20
|
+
Accept: ["application/json", "text/plain"], // will be joined by proxy
|
|
21
|
+
Authorization: "Bearer test-token-1", // sent via headers unconditionally
|
|
22
|
+
},
|
|
23
|
+
authorization: "test-token-ignored-in-dev", // used only if server-side requires it
|
|
24
|
+
},
|
|
24
25
|
});
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
26
|
+
// 2) POST with JSON payload + headers
|
|
27
|
+
const resp2 = await dahr.startProxy({
|
|
28
|
+
url: "https://postman-echo.com/post",
|
|
29
|
+
method: "POST",
|
|
30
|
+
options: {
|
|
31
|
+
headers: {
|
|
32
|
+
"Content-Type": "application/json",
|
|
33
|
+
"X-Trace-Id": "abc123",
|
|
34
|
+
Authorization: "Bearer test-token-2",
|
|
35
|
+
},
|
|
36
|
+
payload: {
|
|
37
|
+
user: { id: 1, name: "alice" },
|
|
38
|
+
tags: ["web2", "sdk"],
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
});
|
|
42
|
+
// 3) PUT with payload
|
|
43
|
+
const resp3 = await dahr.startProxy({
|
|
44
|
+
url: "https://jsonplaceholder.typicode.com/posts/1",
|
|
45
|
+
method: "PUT",
|
|
46
|
+
options: {
|
|
47
|
+
headers: {
|
|
48
|
+
"Content-Type": "application/json",
|
|
49
|
+
"X-Op": "put",
|
|
50
|
+
},
|
|
51
|
+
payload: {
|
|
52
|
+
id: 1,
|
|
53
|
+
title: "foo",
|
|
54
|
+
body: "bar",
|
|
55
|
+
userId: 1,
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
});
|
|
59
|
+
// 4) PATCH with payload
|
|
60
|
+
const resp4 = await dahr.startProxy({
|
|
61
|
+
url: "https://dummyjson.com/products/1",
|
|
62
|
+
method: "PATCH",
|
|
63
|
+
options: {
|
|
64
|
+
headers: {
|
|
65
|
+
"Content-Type": "application/json",
|
|
66
|
+
"X-Op": "patch",
|
|
67
|
+
},
|
|
68
|
+
payload: { price: 199.99 },
|
|
69
|
+
},
|
|
70
|
+
});
|
|
71
|
+
console.log("GET resp:", resp1);
|
|
72
|
+
console.log("POST resp:", resp2);
|
|
73
|
+
console.log("PUT resp:", resp3);
|
|
74
|
+
console.log("PATCH resp:", resp4);
|
|
29
75
|
}
|
|
30
76
|
catch (error) {
|
|
31
77
|
console.error("Error:", error);
|
|
32
78
|
}
|
|
33
79
|
}
|
|
34
|
-
|
|
80
|
+
tryWeb2Proxy();
|
|
35
81
|
//# sourceMappingURL=tryWeb2.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tryWeb2.js","sourceRoot":"","sources":["../../../../src/websdk/examples/tryWeb2.ts"],"names":[],"mappings":";;AAAA,
|
|
1
|
+
{"version":3,"file":"tryWeb2.js","sourceRoot":"","sources":["../../../../src/websdk/examples/tryWeb2.ts"],"names":[],"mappings":";;AAAA,kDAA8C;AAC9C,8CAAqC;AAErC,KAAK,UAAU,YAAY;IACvB,IAAI,CAAC;QACD,MAAM,KAAK,GAAG,IAAI,kBAAK,EAAE,CAAA;QACzB,MAAM,KAAK,CAAC,OAAO,CAAC,wBAAwB,CAAC,CAAA;QAC7C,MAAM,QAAQ,GAAG,2BAAY,CAAC,WAAW,EAAE,CAAA;QAC3C,MAAM,QA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,KAAK;oBACZ,IAAI,EAAE,KAAK;oBACX,MAAM,EAAE,CAAC;iBACZ;aACJ;SACJ,CAAC,CAAA;QAEF,wBAAwB;QACxB,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC;YAChC,GAAG,EAAE,kCAAkC;YACvC,MAAM,EAAE,OAAO;YACf,OAAO,EAAE;gBACL,OAAO,EAAE;oBACL,cAAc,EAAE,kBAAkB;oBAClC,MAAM,EAAE,OAAO;iBAClB;gBACD,OAAO,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE;aAC7B;SACJ,CAAC,CAAA;QAEF,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,KAAK,CAAC,CAAA;QAC/B,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,KAAK,CAAC,CAAA;QAChC,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,KAAK,CAAC,CAAA;QAC/B,OAAO,CAAC,GAAG,CAAC,aAAa,EAAE,KAAK,CAAC,CAAA;IACrC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACb,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAA;IAClC,CAAC;AACL,CAAC;AAED,YAAY,EAAE,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skeletons.js","sourceRoot":"","sources":["../../../../src/websdk/utils/skeletons.ts"],"names":[],"mappings":";;;AACA,
|
|
1
|
+
{"version":3,"file":"skeletons.js","sourceRoot":"","sources":["../../../../src/websdk/utils/skeletons.ts"],"names":[],"mappings":";;;AACA,mCAAyC;AACzC,yEAAyE;AACzE,UAAU;AAEV,4BAA4B;AAC5B,MAAM,WAAW,GAAgB;IAC7B,OAAO,EAAE;QACL,mBAAmB;QACnB,IAAI,EAAE,EAAE,EAAE,SAAS;QACnB,IAAI,EAAE,EAAE,EAAE,iCAAiC;QAC3C,EAAE,EAAE,EAAE,EAAE,iCAAiC;QACzC,MAAM,EAAE,CAAC,EAAE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
|
|
2
2
|
"name": "@kynesyslabs/demosdk",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.15",
|
|
4
4
|
"description": "Demosdk is a JavaScript/TypeScript SDK that provides a unified interface for interacting with Demos network",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"types": "build/index.d.ts",
|