sharetribe-flex-build-sdk 1.15.0
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/README.md +222 -0
- package/build.js +49 -0
- package/package.json +54 -0
- package/src/api/client.ts +218 -0
- package/src/api/http-client.ts +135 -0
- package/src/api/multipart.ts +78 -0
- package/src/api/transit.ts +96 -0
- package/src/assets.ts +116 -0
- package/src/auth-storage.ts +77 -0
- package/src/deploy.ts +96 -0
- package/src/edn-process.ts +126 -0
- package/src/events.ts +203 -0
- package/src/index.ts +101 -0
- package/src/listing-approval.ts +59 -0
- package/src/notifications.ts +89 -0
- package/src/processes.ts +320 -0
- package/src/sdk-exports.md +25 -0
- package/src/search.ts +273 -0
- package/src/stripe.ts +39 -0
- package/src/types/jsedn.d.ts +9 -0
- package/src/types/transit-js.d.ts +10 -0
- package/src/types.ts +38 -0
- package/tsconfig.json +19 -0
- package/vitest.config.ts +8 -0
package/src/types.ts
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Type definitions for Sharetribe Flex Build SDK
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
export interface ProcessState {
|
|
6
|
+
name: string;
|
|
7
|
+
in: string[];
|
|
8
|
+
out: string[];
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export interface ProcessAction {
|
|
12
|
+
name: string;
|
|
13
|
+
config?: unknown;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export interface ProcessTransition {
|
|
17
|
+
name: string;
|
|
18
|
+
from: string;
|
|
19
|
+
to: string;
|
|
20
|
+
actor: string;
|
|
21
|
+
privileged?: boolean;
|
|
22
|
+
actions?: ProcessAction[];
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export interface ProcessNotification {
|
|
26
|
+
name: string;
|
|
27
|
+
on: string;
|
|
28
|
+
to: string;
|
|
29
|
+
template: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface ProcessDefinition {
|
|
33
|
+
name: string;
|
|
34
|
+
version?: number;
|
|
35
|
+
states: ProcessState[];
|
|
36
|
+
transitions: ProcessTransition[];
|
|
37
|
+
notifications: ProcessNotification[];
|
|
38
|
+
}
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2022",
|
|
4
|
+
"lib": ["ES2022"],
|
|
5
|
+
"module": "NodeNext",
|
|
6
|
+
"moduleResolution": "NodeNext",
|
|
7
|
+
"outDir": "./dist",
|
|
8
|
+
"rootDir": "./src",
|
|
9
|
+
"declaration": true,
|
|
10
|
+
"declarationMap": true,
|
|
11
|
+
"sourceMap": true,
|
|
12
|
+
"esModuleInterop": true,
|
|
13
|
+
"forceConsistentCasingInFileNames": true,
|
|
14
|
+
"strict": true,
|
|
15
|
+
"skipLibCheck": true
|
|
16
|
+
},
|
|
17
|
+
"include": ["src/**/*"],
|
|
18
|
+
"exclude": ["node_modules", "dist", "test"]
|
|
19
|
+
}
|