twenty-sdk 0.0.2-alpha → 0.0.3-alpha
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/application/decorators/object-metadata.decorator.d.ts +12 -0
- package/dist/application/index.d.ts +4 -0
- package/dist/application/types/application-config.d.ts +14 -0
- package/dist/application/types/serverless-function-config.d.ts +24 -0
- package/dist/application/types/syncable-entity-options.type.d.ts +3 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.mjs +2 -3
- package/package.json +22 -2
- package/dist/decorators/index.d.ts +0 -1
- package/dist/decorators/object.decorator.d.ts +0 -11
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SyncableEntityOptions } from '../types/syncable-entity-options.type';
|
|
2
|
+
|
|
3
|
+
type ObjectMetadataOptions = SyncableEntityOptions & {
|
|
4
|
+
nameSingular: string;
|
|
5
|
+
namePlural: string;
|
|
6
|
+
labelSingular: string;
|
|
7
|
+
labelPlural: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
icon?: string;
|
|
10
|
+
};
|
|
11
|
+
export declare const ObjectMetadata: (_: ObjectMetadataOptions) => ClassDecorator;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { ObjectMetadata } from './decorators/object-metadata.decorator';
|
|
2
|
+
export type { ApplicationConfig } from './types/application-config';
|
|
3
|
+
export type { ServerlessFunctionConfig } from './types/serverless-function-config';
|
|
4
|
+
export type { SyncableEntityOptions } from './types/syncable-entity-options.type';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { SyncableEntityOptions } from './syncable-entity-options.type';
|
|
2
|
+
|
|
3
|
+
type ApplicationVariable = SyncableEntityOptions & {
|
|
4
|
+
value?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
isSecret?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export type ApplicationConfig = SyncableEntityOptions & {
|
|
9
|
+
displayName?: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
icon?: string;
|
|
12
|
+
applicationVariables: Record<string, ApplicationVariable>;
|
|
13
|
+
};
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { SyncableEntityOptions } from './syncable-entity-options.type';
|
|
2
|
+
|
|
3
|
+
type RouteTrigger = {
|
|
4
|
+
type: 'route';
|
|
5
|
+
path: string;
|
|
6
|
+
httpMethod: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
|
|
7
|
+
isAuthRequired: boolean;
|
|
8
|
+
};
|
|
9
|
+
type CronTrigger = {
|
|
10
|
+
type: 'cron';
|
|
11
|
+
pattern: string;
|
|
12
|
+
};
|
|
13
|
+
type DatabaseEventTrigger = {
|
|
14
|
+
type: 'databaseEvent';
|
|
15
|
+
eventName: string;
|
|
16
|
+
};
|
|
17
|
+
type ServerlessFunctionTrigger = SyncableEntityOptions & (RouteTrigger | CronTrigger | DatabaseEventTrigger);
|
|
18
|
+
export type ServerlessFunctionConfig = SyncableEntityOptions & {
|
|
19
|
+
name?: string;
|
|
20
|
+
description?: string;
|
|
21
|
+
timeoutSeconds?: number;
|
|
22
|
+
triggers?: ServerlessFunctionTrigger[];
|
|
23
|
+
};
|
|
24
|
+
export {};
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";const s={};module.exports=s;
|
package/dist/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
declare const _default: {};
|
|
2
|
+
export default _default;
|
package/dist/index.mjs
CHANGED
package/package.json
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "twenty-sdk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3-alpha",
|
|
4
4
|
"license": "AGPL-3.0",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
8
|
"files": [
|
|
9
|
-
"dist"
|
|
9
|
+
"dist",
|
|
10
|
+
"application"
|
|
10
11
|
],
|
|
11
12
|
"scripts": {
|
|
12
13
|
"build": "vite build"
|
|
@@ -15,5 +16,24 @@
|
|
|
15
16
|
"typescript": "5.9.2",
|
|
16
17
|
"vite": "^7.0.0",
|
|
17
18
|
"vite-plugin-dts": "3.8.1"
|
|
19
|
+
},
|
|
20
|
+
"exports": {
|
|
21
|
+
".": {
|
|
22
|
+
"types": "./dist/index.d.ts",
|
|
23
|
+
"import": "./dist/index.mjs",
|
|
24
|
+
"require": "./dist/index.cjs"
|
|
25
|
+
},
|
|
26
|
+
"./application": {
|
|
27
|
+
"types": "./dist/application/index.d.ts",
|
|
28
|
+
"import": "./dist/application.mjs",
|
|
29
|
+
"require": "./dist/application.cjs"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"typesVersions": {
|
|
33
|
+
"*": {
|
|
34
|
+
"application": [
|
|
35
|
+
"dist/application/index.d.ts"
|
|
36
|
+
]
|
|
37
|
+
}
|
|
18
38
|
}
|
|
19
39
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { Object } from './object.decorator';
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
type ObjectOptions = {
|
|
2
|
-
universalIdentifier: string;
|
|
3
|
-
nameSingular: string;
|
|
4
|
-
namePlural: string;
|
|
5
|
-
labelSingular: string;
|
|
6
|
-
labelPlural: string;
|
|
7
|
-
description?: string;
|
|
8
|
-
icon?: string;
|
|
9
|
-
};
|
|
10
|
-
export declare const Object: (_: ObjectOptions) => ClassDecorator;
|
|
11
|
-
export {};
|