@kynesyslabs/demosdk 1.1.2 → 1.1.4

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.
@@ -7,6 +7,7 @@ export type XMPayload = ["crosschainOperation", XMScript];
7
7
  export type Web2Payload = ["web2Request", IWeb2Request];
8
8
  export type NativePayload = ["native", any];
9
9
  export type StringifiedPayload = [string, string];
10
+ import { demosWork } from '../communication/demosWork';
10
11
  export interface TransactionContent {
11
12
  type: string;
12
13
  from: forge.pki.ed25519.BinaryBuffer | forge.pki.PublicKey | ISignature;
@@ -17,6 +18,16 @@ export interface TransactionContent {
17
18
  timestamp: number;
18
19
  transaction_fee: TxFee;
19
20
  }
21
+ export interface _TransactionContent {
22
+ type: string;
23
+ from: forge.pki.ed25519.BinaryBuffer | forge.pki.PublicKey | ISignature;
24
+ to: forge.pki.ed25519.BinaryBuffer | forge.pki.PrivateKey | ISignature;
25
+ amount: number;
26
+ data: demosWork;
27
+ nonce: number;
28
+ timestamp: number;
29
+ transaction_fee: TxFee;
30
+ }
20
31
  export interface Transaction {
21
32
  content: TransactionContent;
22
33
  signature: ISignature | null;
@@ -0,0 +1,33 @@
1
+ import * as forge from "node-forge";
2
+ import { XMPayload } from "../blockchain/Transaction";
3
+ import { Web2Payload } from "../blockchain/Transaction";
4
+ export type XMStep = {
5
+ context: "xm";
6
+ payload: XMPayload;
7
+ };
8
+ export type Web2Step = {
9
+ context: "web2";
10
+ payload: Web2Payload;
11
+ };
12
+ export type NativeStep = {
13
+ context: "native";
14
+ payload: any;
15
+ };
16
+ export type demosStepType = XMStep | Web2Step | NativeStep;
17
+ export interface demosStepContent {
18
+ workUID: string;
19
+ type: demosStepType;
20
+ }
21
+ export interface demosStep {
22
+ content: demosStepContent;
23
+ signature: forge.pki.ed25519.BinaryBuffer;
24
+ }
25
+ export interface demosWork {
26
+ workUID: string;
27
+ steps: demosStep[];
28
+ }
29
+ export interface demosResult {
30
+ workUID: string;
31
+ results: any[];
32
+ signature: forge.pki.ed25519.BinaryBuffer;
33
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=demosWork.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"demosWork.js","sourceRoot":"","sources":["../../../../src/types/communication/demosWork.ts"],"names":[],"mappings":""}
@@ -1,3 +1,5 @@
1
+ export { XMStep, Web2Step, NativeStep, demosStepType } from './communication/demosWork';
2
+ export { demosStep, demosStepContent, demosWork } from './communication/demosWork';
1
3
  export { GenesisArtifact, GenesisImmutableProperties, GenesisMutableProperties, StandardGenesis, forkGenesis, } from './blockchain/genesisTypes';
2
4
  export { ISignature } from './blockchain/ISignature';
3
5
  export { TxFee } from './blockchain/TxFee';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;AAaA,0DAAuE;AAA9D,6GAAA,aAAa,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;AAkBA,0DAAuE;AAA9D,6GAAA,aAAa,OAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kynesyslabs/demosdk",
3
- "version": "1.1.2",
3
+ "version": "1.1.4",
4
4
  "main": "build/index.js",
5
5
  "types": "build/index.d.ts",
6
6
  "author": "Kynesys Labs",