@nangohq/types 0.42.21 → 0.43.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/dist/deploy/api.d.ts +3 -2
- package/dist/deploy/index.d.ts +16 -0
- package/dist/index.d.ts +1 -0
- package/dist/logs/api.d.ts +2 -1
- package/dist/logs/messages.d.ts +1 -1
- package/dist/nangoYaml/index.d.ts +8 -2
- package/dist/providers/provider.d.ts +3 -1
- package/dist/utils.d.ts +3 -0
- package/package.json +1 -1
package/dist/deploy/api.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { JSONSchema7 } from 'json-schema';
|
|
2
2
|
import type { Endpoint, ApiError } from '../api.js';
|
|
3
3
|
import type { IncomingFlowConfig, PostConnectionScriptByProvider } from './incomingFlow.js';
|
|
4
|
+
import type { SyncDeploymentResult } from './index.js';
|
|
4
5
|
export type PostDeployConfirmation = Endpoint<{
|
|
5
6
|
Method: 'POST';
|
|
6
7
|
Path: '/sync/deploy/confirmation';
|
|
@@ -26,7 +27,7 @@ export type PostDeploy = Endpoint<{
|
|
|
26
27
|
singleDeployMode?: boolean;
|
|
27
28
|
jsonSchema?: JSONSchema7 | undefined;
|
|
28
29
|
};
|
|
29
|
-
Success:
|
|
30
|
+
Success: SyncDeploymentResult[];
|
|
30
31
|
}>;
|
|
31
32
|
export type PostDeployInternal = Endpoint<{
|
|
32
33
|
Method: 'POST';
|
|
@@ -44,7 +45,7 @@ export type PostDeployInternal = Endpoint<{
|
|
|
44
45
|
jsonSchema?: JSONSchema7 | undefined;
|
|
45
46
|
};
|
|
46
47
|
Error: ApiError<'forbidden'> | ApiError<'environment_creation_error'>;
|
|
47
|
-
Success:
|
|
48
|
+
Success: SyncDeploymentResult[];
|
|
48
49
|
}>;
|
|
49
50
|
export interface SlimSync {
|
|
50
51
|
id?: number;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ScriptTypeLiteral } from '../nangoYaml';
|
|
2
|
+
import type { LegacySyncModelSchema } from './incomingFlow';
|
|
3
|
+
export interface SyncDeploymentResult {
|
|
4
|
+
name: string;
|
|
5
|
+
version?: string;
|
|
6
|
+
providerConfigKey: string;
|
|
7
|
+
type: ScriptTypeLiteral;
|
|
8
|
+
last_deployed?: Date;
|
|
9
|
+
input?: string | LegacySyncModelSchema | undefined;
|
|
10
|
+
models: string | string[];
|
|
11
|
+
id?: number | undefined;
|
|
12
|
+
/** @deprecated legacy **/
|
|
13
|
+
sync_name?: string;
|
|
14
|
+
/** @deprecated legacy **/
|
|
15
|
+
syncName?: string;
|
|
16
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export type * from './auth/api.js';
|
|
|
34
34
|
export type * from './auth/db.js';
|
|
35
35
|
export type * from './auth/http.api.js';
|
|
36
36
|
export type * from './deploy/api.js';
|
|
37
|
+
export type * from './deploy/index.js';
|
|
37
38
|
export type * from './deploy/incomingFlow.js';
|
|
38
39
|
export type * from './connect/api.js';
|
|
39
40
|
export type * from './connect/session.js';
|
package/dist/logs/api.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Endpoint } from '../api';
|
|
2
|
+
import type { PickFromUnion } from '../utils';
|
|
2
3
|
import type { MessageRow, MessageState, OperationList, OperationRow } from './messages';
|
|
3
4
|
type Concat<T extends OperationList> = T extends {
|
|
4
5
|
action: string;
|
|
@@ -101,7 +102,7 @@ export type PostInsights = Endpoint<{
|
|
|
101
102
|
env: string;
|
|
102
103
|
};
|
|
103
104
|
Body: {
|
|
104
|
-
type: 'action' | 'sync' | 'proxy' | '
|
|
105
|
+
type: PickFromUnion<ConcatOperationListWithGroup, 'action' | 'sync' | 'proxy' | 'webhook:incoming'>;
|
|
105
106
|
};
|
|
106
107
|
Success: {
|
|
107
108
|
data: {
|
package/dist/logs/messages.d.ts
CHANGED
|
@@ -19,6 +19,11 @@ export interface NangoYamlV2 {
|
|
|
19
19
|
integrations: Record<string, NangoYamlV2Integration>;
|
|
20
20
|
models: NangoYamlModel;
|
|
21
21
|
}
|
|
22
|
+
export interface NangoYamlV2Endpoint {
|
|
23
|
+
method?: HTTP_METHOD;
|
|
24
|
+
path: string;
|
|
25
|
+
entity?: string | undefined;
|
|
26
|
+
}
|
|
22
27
|
export interface NangoYamlV2Integration {
|
|
23
28
|
provider?: string;
|
|
24
29
|
syncs?: Record<string, NangoYamlV2IntegrationSync>;
|
|
@@ -26,7 +31,7 @@ export interface NangoYamlV2Integration {
|
|
|
26
31
|
'post-connection-scripts'?: string[];
|
|
27
32
|
}
|
|
28
33
|
export interface NangoYamlV2IntegrationSync {
|
|
29
|
-
endpoint: string | string[] |
|
|
34
|
+
endpoint: string | string[] | NangoYamlV2Endpoint | NangoYamlV2Endpoint[];
|
|
30
35
|
output: string | string[];
|
|
31
36
|
description?: string;
|
|
32
37
|
sync_type?: SyncTypeLiteral;
|
|
@@ -39,7 +44,7 @@ export interface NangoYamlV2IntegrationSync {
|
|
|
39
44
|
version?: string;
|
|
40
45
|
}
|
|
41
46
|
export interface NangoYamlV2IntegrationAction {
|
|
42
|
-
endpoint: string;
|
|
47
|
+
endpoint: string | NangoYamlV2Endpoint;
|
|
43
48
|
output?: string | string[];
|
|
44
49
|
description?: string;
|
|
45
50
|
scopes?: string | string[];
|
|
@@ -114,4 +119,5 @@ export type NangoSyncEndpointOld = {
|
|
|
114
119
|
export interface NangoSyncEndpointV2 {
|
|
115
120
|
method: HTTP_METHOD;
|
|
116
121
|
path: string;
|
|
122
|
+
entity?: string | undefined;
|
|
117
123
|
}
|
|
@@ -25,12 +25,14 @@ export interface SimplifiedJSONSchema {
|
|
|
25
25
|
example?: string;
|
|
26
26
|
pattern?: string;
|
|
27
27
|
optional?: boolean;
|
|
28
|
-
format?:
|
|
28
|
+
format?: 'hostname' | 'uri' | 'uuid' | 'email';
|
|
29
29
|
order: number;
|
|
30
30
|
default_value?: string;
|
|
31
31
|
hidden?: string;
|
|
32
|
+
prefix?: string;
|
|
32
33
|
suffix?: string;
|
|
33
34
|
doc_section?: string;
|
|
35
|
+
secret?: string;
|
|
34
36
|
}
|
|
35
37
|
export interface BaseProvider {
|
|
36
38
|
display_name: string;
|
package/dist/utils.d.ts
CHANGED