@autentikar/step 1.0.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.
- package/dist/index.d.ts +57 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/package.json +23 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
declare global {
|
|
2
|
+
class AccountPreference {
|
|
3
|
+
static get<VALUE = unknown>(name: string): Promise<VALUE | undefined>;
|
|
4
|
+
}
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
interface StepFile {
|
|
8
|
+
buffer: Buffer;
|
|
9
|
+
url?: string;
|
|
10
|
+
}
|
|
11
|
+
declare global {
|
|
12
|
+
class Assets {
|
|
13
|
+
static get(path: string, options?: {
|
|
14
|
+
url?: boolean;
|
|
15
|
+
}): Promise<StepFile | undefined>;
|
|
16
|
+
static save(name: string, content: Buffer | string, options?: {
|
|
17
|
+
meta?: undefined;
|
|
18
|
+
base?: string;
|
|
19
|
+
}): Promise<{
|
|
20
|
+
path: string;
|
|
21
|
+
}>;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
declare global {
|
|
26
|
+
class Preference {
|
|
27
|
+
static get<VALUE = unknown>(name: string): Promise<VALUE | undefined>;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
interface StepOutput {
|
|
32
|
+
[key: string]: string | undefined;
|
|
33
|
+
success?: string;
|
|
34
|
+
failure?: string;
|
|
35
|
+
}
|
|
36
|
+
interface MethodResult {
|
|
37
|
+
omitMethodRecord?: boolean;
|
|
38
|
+
nextStep?: {
|
|
39
|
+
id: string;
|
|
40
|
+
linkData?: unknown;
|
|
41
|
+
};
|
|
42
|
+
status: "SUCCESS" | "FAILURE";
|
|
43
|
+
result: {
|
|
44
|
+
output?: unknown;
|
|
45
|
+
[key: string]: unknown;
|
|
46
|
+
};
|
|
47
|
+
akAdmin?: unknown;
|
|
48
|
+
}
|
|
49
|
+
type Method<INIT_DATA = any, PARAMS = any, DATA = any> = (options: {
|
|
50
|
+
initData: INIT_DATA | undefined;
|
|
51
|
+
params: PARAMS | undefined;
|
|
52
|
+
data: DATA | undefined;
|
|
53
|
+
threads: string[] | undefined;
|
|
54
|
+
output: StepOutput;
|
|
55
|
+
}) => Promise<MethodResult>;
|
|
56
|
+
|
|
57
|
+
export type { Method, MethodResult, StepFile };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var o=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var a=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var d=(n,e,i,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of a(e))!u.call(n,t)&&t!==i&&o(n,t,{get:()=>e[t],enumerable:!(r=s(e,t))||r.enumerable});return n};var A=n=>d(o({},"__esModule",{value:!0}),n);var p={};module.exports=A(p);
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../index.ts"],"sourcesContent":["// export { Method } from \"@autentikar/step-types\";\n\ninterface StepOutput {\n [key: string]: string | undefined;\n success?: string;\n failure?: string;\n}\n\nexport interface MethodResult {\n omitMethodRecord?: boolean;\n nextStep?: {\n id: string;\n linkData?: unknown;\n };\n status: \"SUCCESS\" | \"FAILURE\";\n result: {\n output?: unknown;\n [key: string]: unknown;\n };\n akAdmin?: unknown;\n}\n\nexport type Method<INIT_DATA = any, PARAMS = any, DATA = any> = (options: {\n initData: INIT_DATA | undefined;\n params: PARAMS | undefined;\n data: DATA | undefined;\n threads: string[] | undefined;\n output: StepOutput;\n}) => Promise<MethodResult>;\n\nexport * from \"./src\";\n"],"mappings":"+WAAA,IAAAA,EAAA,kBAAAC,EAAAD","names":["step_exports","__toCommonJS"]}
|
package/package.json
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@autentikar/step",
|
|
3
|
+
"version": "1.0.4",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "./dist/index.js",
|
|
6
|
+
"module": "./dist/index.mjs",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"scripts": {
|
|
9
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
10
|
+
"dev": "pnpm run build -- --watch",
|
|
11
|
+
"build": "tsup",
|
|
12
|
+
"publish-packages": "turbo run build && changeset version && changeset publish"
|
|
13
|
+
},
|
|
14
|
+
"keywords": [],
|
|
15
|
+
"author": "",
|
|
16
|
+
"license": "ISC",
|
|
17
|
+
"devDependencies": {
|
|
18
|
+
"@changesets/cli": "^2.27.1",
|
|
19
|
+
"@types/node": "^20.11.5",
|
|
20
|
+
"tsup": "^8.0.1",
|
|
21
|
+
"typescript": "^5.2.2"
|
|
22
|
+
}
|
|
23
|
+
}
|