powersync 0.1.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 +339 -0
- package/bin/dev.cmd +3 -0
- package/bin/dev.js +9 -0
- package/bin/run.cmd +3 -0
- package/bin/run.js +8 -0
- package/dist/commands/init.d.ts +7 -0
- package/dist/commands/init.js +49 -0
- package/dist/commands/instance/config.d.ts +6 -0
- package/dist/commands/instance/config.js +23 -0
- package/dist/commands/instance/create.d.ts +16 -0
- package/dist/commands/instance/create.js +163 -0
- package/dist/commands/instance/deploy.d.ts +15 -0
- package/dist/commands/instance/deploy.js +142 -0
- package/dist/commands/instance/destroy.d.ts +9 -0
- package/dist/commands/instance/destroy.js +42 -0
- package/dist/commands/instance/schema.d.ts +6 -0
- package/dist/commands/instance/schema.js +20 -0
- package/dist/commands/instance/set.d.ts +9 -0
- package/dist/commands/instance/set.js +31 -0
- package/dist/commands/instance/status.d.ts +6 -0
- package/dist/commands/instance/status.js +21 -0
- package/dist/commands/instance/stop.d.ts +9 -0
- package/dist/commands/instance/stop.js +42 -0
- package/dist/commands/instance/sync-rules/deploy.d.ts +10 -0
- package/dist/commands/instance/sync-rules/deploy.js +49 -0
- package/dist/commands/instance/sync-rules/generate-schema.d.ts +10 -0
- package/dist/commands/instance/sync-rules/generate-schema.js +55 -0
- package/dist/commands/instance/sync-rules/validate.d.ts +9 -0
- package/dist/commands/instance/sync-rules/validate.js +29 -0
- package/dist/commands/instances.d.ts +6 -0
- package/dist/commands/instances.js +20 -0
- package/dist/constants.d.ts +11 -0
- package/dist/constants.js +8 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/powersync-sdk/accounts/api.d.ts +717 -0
- package/dist/powersync-sdk/accounts/api.js +182 -0
- package/dist/powersync-sdk/accounts/client.d.ts +1096 -0
- package/dist/powersync-sdk/accounts/client.js +124 -0
- package/dist/powersync-sdk/accounts/codecs.d.ts +32 -0
- package/dist/powersync-sdk/accounts/codecs.js +93 -0
- package/dist/powersync-sdk/accounts/index.d.ts +4 -0
- package/dist/powersync-sdk/accounts/index.js +4 -0
- package/dist/powersync-sdk/accounts/models.d.ts +260 -0
- package/dist/powersync-sdk/accounts/models.js +96 -0
- package/dist/powersync-sdk/accounts/routes.d.ts +44 -0
- package/dist/powersync-sdk/accounts/routes.js +45 -0
- package/dist/powersync-sdk/accounts/source.d.ts +76 -0
- package/dist/powersync-sdk/accounts/source.js +32 -0
- package/dist/powersync-sdk/errors/errors.d.ts +62 -0
- package/dist/powersync-sdk/errors/errors.js +115 -0
- package/dist/powersync-sdk/errors/index.d.ts +2 -0
- package/dist/powersync-sdk/errors/index.js +2 -0
- package/dist/powersync-sdk/errors/utils.d.ts +4 -0
- package/dist/powersync-sdk/errors/utils.js +18 -0
- package/dist/powersync-sdk/fetch-clients/codecs.d.ts +4 -0
- package/dist/powersync-sdk/fetch-clients/codecs.js +34 -0
- package/dist/powersync-sdk/fetch-clients/decoders.d.ts +3 -0
- package/dist/powersync-sdk/fetch-clients/decoders.js +35 -0
- package/dist/powersync-sdk/fetch-clients/definitions.d.ts +97 -0
- package/dist/powersync-sdk/fetch-clients/definitions.js +22 -0
- package/dist/powersync-sdk/fetch-clients/errors.d.ts +7 -0
- package/dist/powersync-sdk/fetch-clients/errors.js +19 -0
- package/dist/powersync-sdk/fetch-clients/index.d.ts +5 -0
- package/dist/powersync-sdk/fetch-clients/index.js +5 -0
- package/dist/powersync-sdk/fetch-clients/node-client.d.ts +9 -0
- package/dist/powersync-sdk/fetch-clients/node-client.js +107 -0
- package/dist/powersync-sdk/fetch-clients/request.d.ts +11 -0
- package/dist/powersync-sdk/fetch-clients/request.js +138 -0
- package/dist/powersync-sdk/fetch-clients/streaming.d.ts +65 -0
- package/dist/powersync-sdk/fetch-clients/streaming.js +99 -0
- package/dist/powersync-sdk/fetch-clients/utils.d.ts +13 -0
- package/dist/powersync-sdk/fetch-clients/utils.js +43 -0
- package/dist/powersync-sdk/fetch-clients/web-client.d.ts +14 -0
- package/dist/powersync-sdk/fetch-clients/web-client.js +56 -0
- package/dist/powersync-sdk/json/index.d.ts +4 -0
- package/dist/powersync-sdk/json/index.js +3 -0
- package/dist/powersync-sdk/json/json.d.ts +5 -0
- package/dist/powersync-sdk/json/json.js +35 -0
- package/dist/powersync-sdk/json/json_container.d.ts +18 -0
- package/dist/powersync-sdk/json/json_container.js +28 -0
- package/dist/powersync-sdk/json/json_stringify.d.ts +36 -0
- package/dist/powersync-sdk/json/json_stringify.js +162 -0
- package/dist/powersync-sdk/powersync/client.d.ts +449 -0
- package/dist/powersync-sdk/powersync/client.js +53 -0
- package/dist/powersync-sdk/powersync/config/HostedConfig.d.ts +327 -0
- package/dist/powersync-sdk/powersync/config/HostedConfig.js +92 -0
- package/dist/powersync-sdk/powersync/config/PowerSyncConfig.d.ts +211 -0
- package/dist/powersync-sdk/powersync/config/PowerSyncConfig.js +97 -0
- package/dist/powersync-sdk/powersync/config/normalize.d.ts +32 -0
- package/dist/powersync-sdk/powersync/config/normalize.js +85 -0
- package/dist/powersync-sdk/powersync/definitions.d.ts +149 -0
- package/dist/powersync-sdk/powersync/definitions.js +97 -0
- package/dist/powersync-sdk/powersync/index.d.ts +8 -0
- package/dist/powersync-sdk/powersync/index.js +8 -0
- package/dist/powersync-sdk/powersync/internal_routes.d.ts +247 -0
- package/dist/powersync-sdk/powersync/internal_routes.js +69 -0
- package/dist/powersync-sdk/powersync/routes.d.ts +779 -0
- package/dist/powersync-sdk/powersync/routes.js +191 -0
- package/dist/powersync-sdk/sdk-clients/endpoints.d.ts +31 -0
- package/dist/powersync-sdk/sdk-clients/endpoints.js +48 -0
- package/dist/powersync-sdk/sdk-clients/index.d.ts +3 -0
- package/dist/powersync-sdk/sdk-clients/index.js +3 -0
- package/dist/powersync-sdk/sdk-clients/pagination.d.ts +14 -0
- package/dist/powersync-sdk/sdk-clients/pagination.js +21 -0
- package/dist/powersync-sdk/sdk-clients/sdk-client.d.ts +17 -0
- package/dist/powersync-sdk/sdk-clients/sdk-client.js +30 -0
- package/dist/powersync-sdk/streaming/bson/buffer-array.d.ts +31 -0
- package/dist/powersync-sdk/streaming/bson/buffer-array.js +79 -0
- package/dist/powersync-sdk/streaming/bson/constants.d.ts +2 -0
- package/dist/powersync-sdk/streaming/bson/constants.js +1 -0
- package/dist/powersync-sdk/streaming/bson/decoder.d.ts +10 -0
- package/dist/powersync-sdk/streaming/bson/decoder.js +62 -0
- package/dist/powersync-sdk/streaming/bson/encoder.d.ts +10 -0
- package/dist/powersync-sdk/streaming/bson/encoder.js +23 -0
- package/dist/powersync-sdk/streaming/bson/header.d.ts +11 -0
- package/dist/powersync-sdk/streaming/bson/header.js +52 -0
- package/dist/powersync-sdk/streaming/bson/index.d.ts +5 -0
- package/dist/powersync-sdk/streaming/bson/index.js +5 -0
- package/dist/powersync-sdk/streaming/core/backpressure.d.ts +15 -0
- package/dist/powersync-sdk/streaming/core/backpressure.js +34 -0
- package/dist/powersync-sdk/streaming/core/cross-stream.d.ts +6 -0
- package/dist/powersync-sdk/streaming/core/cross-stream.js +17 -0
- package/dist/powersync-sdk/streaming/core/index.d.ts +4 -0
- package/dist/powersync-sdk/streaming/core/index.js +4 -0
- package/dist/powersync-sdk/streaming/core/node-utils.d.ts +7 -0
- package/dist/powersync-sdk/streaming/core/node-utils.js +11 -0
- package/dist/powersync-sdk/streaming/core/transformers.d.ts +41 -0
- package/dist/powersync-sdk/streaming/core/transformers.js +70 -0
- package/dist/powersync-sdk/streaming/core/utils.d.ts +36 -0
- package/dist/powersync-sdk/streaming/core/utils.js +66 -0
- package/dist/powersync-sdk/streaming/index.d.ts +3 -0
- package/dist/powersync-sdk/streaming/index.js +3 -0
- package/dist/powersync-sdk/streaming/web.d.ts +4 -0
- package/dist/powersync-sdk/streaming/web.js +4 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binaryreader.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binaryreader.js +36 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binarywriter.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binarywriter.js +58 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometry.d.ts +18 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometry.js +348 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometrycollection.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometrycollection.js +118 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/linestring.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/linestring.js +131 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multilinestring.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multilinestring.js +134 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipoint.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipoint.js +122 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipolygon.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipolygon.js +158 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/point.d.ts +14 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/point.js +165 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/polygon.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/polygon.js +207 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/types.d.ts +30 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/types.js +29 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wktparser.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wktparser.js +111 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wkx.d.ts +9 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wkx.js +9 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/zigzag.d.ts +5 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/zigzag.js +9 -0
- package/dist/powersync-sdk/sync-rules/DartSchemaGenerator.d.ts +12 -0
- package/dist/powersync-sdk/sync-rules/DartSchemaGenerator.js +35 -0
- package/dist/powersync-sdk/sync-rules/ExpressionType.d.ts +33 -0
- package/dist/powersync-sdk/sync-rules/ExpressionType.js +62 -0
- package/dist/powersync-sdk/sync-rules/IdSequence.d.ts +4 -0
- package/dist/powersync-sdk/sync-rules/IdSequence.js +7 -0
- package/dist/powersync-sdk/sync-rules/JsSchemaGenerator.d.ts +12 -0
- package/dist/powersync-sdk/sync-rules/JsSchemaGenerator.js +38 -0
- package/dist/powersync-sdk/sync-rules/SchemaGenerator.d.ts +14 -0
- package/dist/powersync-sdk/sync-rules/SchemaGenerator.js +24 -0
- package/dist/powersync-sdk/sync-rules/SourceTableInterface.d.ts +5 -0
- package/dist/powersync-sdk/sync-rules/SourceTableInterface.js +1 -0
- package/dist/powersync-sdk/sync-rules/SqlBucketDescriptor.d.ts +37 -0
- package/dist/powersync-sdk/sync-rules/SqlBucketDescriptor.js +116 -0
- package/dist/powersync-sdk/sync-rules/SqlDataQuery.d.ts +39 -0
- package/dist/powersync-sdk/sync-rules/SqlDataQuery.js +245 -0
- package/dist/powersync-sdk/sync-rules/SqlParameterQuery.d.ts +43 -0
- package/dist/powersync-sdk/sync-rules/SqlParameterQuery.js +254 -0
- package/dist/powersync-sdk/sync-rules/SqlSyncRules.d.ts +52 -0
- package/dist/powersync-sdk/sync-rules/SqlSyncRules.js +252 -0
- package/dist/powersync-sdk/sync-rules/StaticSchema.d.ts +26 -0
- package/dist/powersync-sdk/sync-rules/StaticSchema.js +71 -0
- package/dist/powersync-sdk/sync-rules/StaticSqlParameterQuery.d.ts +24 -0
- package/dist/powersync-sdk/sync-rules/StaticSqlParameterQuery.js +71 -0
- package/dist/powersync-sdk/sync-rules/TablePattern.d.ts +17 -0
- package/dist/powersync-sdk/sync-rules/TablePattern.js +56 -0
- package/dist/powersync-sdk/sync-rules/TableQuerySchema.d.ts +9 -0
- package/dist/powersync-sdk/sync-rules/TableQuerySchema.js +41 -0
- package/dist/powersync-sdk/sync-rules/errors.d.ts +22 -0
- package/dist/powersync-sdk/sync-rules/errors.js +60 -0
- package/dist/powersync-sdk/sync-rules/generators.d.ts +6 -0
- package/dist/powersync-sdk/sync-rules/generators.js +6 -0
- package/dist/powersync-sdk/sync-rules/index.d.ts +17 -0
- package/dist/powersync-sdk/sync-rules/index.js +17 -0
- package/dist/powersync-sdk/sync-rules/json_schema.d.ts +3 -0
- package/dist/powersync-sdk/sync-rules/json_schema.js +50 -0
- package/dist/powersync-sdk/sync-rules/sql_filters.d.ts +91 -0
- package/dist/powersync-sdk/sync-rules/sql_filters.js +491 -0
- package/dist/powersync-sdk/sync-rules/sql_functions.d.ts +53 -0
- package/dist/powersync-sdk/sync-rules/sql_functions.js +755 -0
- package/dist/powersync-sdk/sync-rules/sql_support.d.ts +22 -0
- package/dist/powersync-sdk/sync-rules/sql_support.js +208 -0
- package/dist/powersync-sdk/sync-rules/types.d.ts +174 -0
- package/dist/powersync-sdk/sync-rules/types.js +9 -0
- package/dist/powersync-sdk/sync-rules/utils.d.ts +45 -0
- package/dist/powersync-sdk/sync-rules/utils.js +163 -0
- package/dist/service/accounts.client.d.ts +26 -0
- package/dist/service/accounts.client.js +26 -0
- package/dist/service/powersync.client.d.ts +269 -0
- package/dist/service/powersync.client.js +135 -0
- package/dist/service/types.d.ts +69 -0
- package/dist/service/types.js +1 -0
- package/dist/service/utils.d.ts +5 -0
- package/dist/service/utils.js +7 -0
- package/dist/utils.d.ts +6 -0
- package/dist/utils.js +52 -0
- package/oclif.manifest.json +514 -0
- package/package.json +81 -0
|
@@ -0,0 +1,779 @@
|
|
|
1
|
+
import * as t from 'ts-codec';
|
|
2
|
+
import * as internal_routes from './internal_routes.js';
|
|
3
|
+
export declare enum GENERAL_ROUTES {
|
|
4
|
+
/** GET */
|
|
5
|
+
LIST_REGIONS = "/api/v1/regions"
|
|
6
|
+
}
|
|
7
|
+
export declare enum MANAGE_ROUTES {
|
|
8
|
+
CONFIG = "/api/v1/instances/config",
|
|
9
|
+
CREATE = "/api/v1/instances/create",
|
|
10
|
+
DEACTIVATE = "/api/v1/instances/deactivate",
|
|
11
|
+
DEPLOY = "/api/v1/instances/deploy",
|
|
12
|
+
DESTROY = "/api/v1/instances/destroy",
|
|
13
|
+
DIAGNOSTICS = "/api/v1/instances/diagnostics",
|
|
14
|
+
LIST = "/api/v1/instances/list",
|
|
15
|
+
STATUS = "/api/v1/instances/status"
|
|
16
|
+
}
|
|
17
|
+
export declare const ListInstancesRequest: t.ObjectCodec<{
|
|
18
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
19
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
20
|
+
}>;
|
|
21
|
+
export type ListInstancesRequest = t.Encoded<typeof ListInstancesRequest>;
|
|
22
|
+
export declare const ListInstancesResponse: t.ObjectCodec<{
|
|
23
|
+
instances: t.ArrayCodec<t.ObjectCodec<{
|
|
24
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
25
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
26
|
+
}>>;
|
|
27
|
+
}>;
|
|
28
|
+
export type ListInstancesResponse = t.Encoded<typeof ListInstancesResponse>;
|
|
29
|
+
export declare const CreateInstanceRequest: t.ObjectCodec<{
|
|
30
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
31
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
32
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
33
|
+
}>;
|
|
34
|
+
export type CreateInstanceRequest = t.Encoded<typeof CreateInstanceRequest>;
|
|
35
|
+
export declare const CreateInstanceResponse: t.ObjectCodec<{
|
|
36
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
37
|
+
}>;
|
|
38
|
+
export type CreateInstanceResponse = t.Encoded<typeof CreateInstanceResponse>;
|
|
39
|
+
export declare const DeployInstanceRequest: t.Intersection<t.Codec<{
|
|
40
|
+
id: string;
|
|
41
|
+
app_id: string;
|
|
42
|
+
org_id: string;
|
|
43
|
+
}, {
|
|
44
|
+
id: string;
|
|
45
|
+
app_id: string;
|
|
46
|
+
org_id: string;
|
|
47
|
+
}, string, t.CodecProps>, t.ObjectCodec<{
|
|
48
|
+
config: t.ObjectCodec<{
|
|
49
|
+
api: t.OptionalCodec<t.Codec<{
|
|
50
|
+
tokens?: ({
|
|
51
|
+
secret: string;
|
|
52
|
+
} | {
|
|
53
|
+
secret_ref: string;
|
|
54
|
+
})[] | undefined;
|
|
55
|
+
}, {
|
|
56
|
+
tokens?: ({
|
|
57
|
+
secret: string;
|
|
58
|
+
} | {
|
|
59
|
+
secret_ref: string;
|
|
60
|
+
})[] | undefined;
|
|
61
|
+
}, string, t.CodecProps>>;
|
|
62
|
+
client_auth: t.OptionalCodec<t.Codec<{
|
|
63
|
+
additional_audiences?: string[] | undefined;
|
|
64
|
+
allow_temporary_tokens?: boolean | undefined;
|
|
65
|
+
jwks?: {
|
|
66
|
+
keys: ({
|
|
67
|
+
e: string;
|
|
68
|
+
kty: "RSA";
|
|
69
|
+
n: string;
|
|
70
|
+
kid: string;
|
|
71
|
+
alg?: "RS256" | "RS384" | "RS512" | undefined;
|
|
72
|
+
use?: string | undefined;
|
|
73
|
+
} | {
|
|
74
|
+
k: {
|
|
75
|
+
secret: string;
|
|
76
|
+
} | {
|
|
77
|
+
secret_ref: string;
|
|
78
|
+
};
|
|
79
|
+
kty: "oct";
|
|
80
|
+
alg: "HS256" | "HS384" | "HS512";
|
|
81
|
+
kid: string;
|
|
82
|
+
use?: string | undefined;
|
|
83
|
+
})[];
|
|
84
|
+
} | undefined;
|
|
85
|
+
jwks_uri?: string | undefined;
|
|
86
|
+
supabase?: boolean | undefined;
|
|
87
|
+
}, {
|
|
88
|
+
additional_audiences?: string[] | undefined;
|
|
89
|
+
allow_temporary_tokens?: boolean | undefined;
|
|
90
|
+
jwks?: {
|
|
91
|
+
keys: ({
|
|
92
|
+
e: string;
|
|
93
|
+
kty: "RSA";
|
|
94
|
+
n: string;
|
|
95
|
+
kid: string;
|
|
96
|
+
alg?: "RS256" | "RS384" | "RS512" | undefined;
|
|
97
|
+
use?: string | undefined;
|
|
98
|
+
} | {
|
|
99
|
+
k: {
|
|
100
|
+
secret: string;
|
|
101
|
+
} | {
|
|
102
|
+
secret_ref: string;
|
|
103
|
+
};
|
|
104
|
+
kty: "oct";
|
|
105
|
+
alg: "HS256" | "HS384" | "HS512";
|
|
106
|
+
kid: string;
|
|
107
|
+
use?: string | undefined;
|
|
108
|
+
})[];
|
|
109
|
+
} | undefined;
|
|
110
|
+
jwks_uri?: string | undefined;
|
|
111
|
+
supabase?: boolean | undefined;
|
|
112
|
+
}, string, t.CodecProps>>;
|
|
113
|
+
dev: t.OptionalCodec<t.Codec<{
|
|
114
|
+
crud_api?: boolean | undefined;
|
|
115
|
+
demo_auth?: boolean | undefined;
|
|
116
|
+
demo_client?: boolean | undefined;
|
|
117
|
+
demo_password?: {
|
|
118
|
+
secret: string;
|
|
119
|
+
} | {
|
|
120
|
+
secret_ref: string;
|
|
121
|
+
} | undefined;
|
|
122
|
+
}, {
|
|
123
|
+
crud_api?: boolean | undefined;
|
|
124
|
+
demo_auth?: boolean | undefined;
|
|
125
|
+
demo_client?: boolean | undefined;
|
|
126
|
+
demo_password?: {
|
|
127
|
+
secret: string;
|
|
128
|
+
} | {
|
|
129
|
+
secret_ref: string;
|
|
130
|
+
} | undefined;
|
|
131
|
+
}, string, t.CodecProps>>;
|
|
132
|
+
region: t.IdentityCodec<t.CodecType.String>;
|
|
133
|
+
replication: t.OptionalCodec<t.Codec<{
|
|
134
|
+
connections?: ({
|
|
135
|
+
type: "postgresql";
|
|
136
|
+
uri?: string | undefined;
|
|
137
|
+
hostname?: string | undefined;
|
|
138
|
+
port?: number | undefined;
|
|
139
|
+
name?: string | undefined;
|
|
140
|
+
id?: string | undefined;
|
|
141
|
+
cacert?: string | undefined;
|
|
142
|
+
client_certificate?: string | undefined;
|
|
143
|
+
client_private_key?: {
|
|
144
|
+
secret: string;
|
|
145
|
+
} | {
|
|
146
|
+
secret_ref: string;
|
|
147
|
+
} | undefined;
|
|
148
|
+
database?: string | undefined;
|
|
149
|
+
debug_api?: boolean | undefined;
|
|
150
|
+
password?: {
|
|
151
|
+
secret: string;
|
|
152
|
+
} | {
|
|
153
|
+
secret_ref: string;
|
|
154
|
+
} | undefined;
|
|
155
|
+
sslmode?: "verify-full" | "verify-ca" | undefined;
|
|
156
|
+
tag?: string | undefined;
|
|
157
|
+
username?: string | undefined;
|
|
158
|
+
} | {
|
|
159
|
+
type: "postgresql-demo";
|
|
160
|
+
tag?: string | undefined;
|
|
161
|
+
})[] | undefined;
|
|
162
|
+
}, {
|
|
163
|
+
connections?: ({
|
|
164
|
+
type: "postgresql";
|
|
165
|
+
uri?: string | undefined;
|
|
166
|
+
hostname?: string | undefined;
|
|
167
|
+
port?: number | undefined;
|
|
168
|
+
name?: string | undefined;
|
|
169
|
+
id?: string | undefined;
|
|
170
|
+
cacert?: string | undefined;
|
|
171
|
+
client_certificate?: string | undefined;
|
|
172
|
+
client_private_key?: {
|
|
173
|
+
secret: string;
|
|
174
|
+
} | {
|
|
175
|
+
secret_ref: string;
|
|
176
|
+
} | undefined;
|
|
177
|
+
database?: string | undefined;
|
|
178
|
+
debug_api?: boolean | undefined;
|
|
179
|
+
password?: {
|
|
180
|
+
secret: string;
|
|
181
|
+
} | {
|
|
182
|
+
secret_ref: string;
|
|
183
|
+
} | undefined;
|
|
184
|
+
sslmode?: "verify-full" | "verify-ca" | undefined;
|
|
185
|
+
tag?: string | undefined;
|
|
186
|
+
username?: string | undefined;
|
|
187
|
+
} | {
|
|
188
|
+
type: "postgresql-demo";
|
|
189
|
+
tag?: string | undefined;
|
|
190
|
+
})[] | undefined;
|
|
191
|
+
}, string, t.CodecProps>>;
|
|
192
|
+
}>;
|
|
193
|
+
name: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
194
|
+
sync_rules: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
195
|
+
}>>;
|
|
196
|
+
export type DeployInstanceRequest = t.Encoded<typeof DeployInstanceRequest>;
|
|
197
|
+
export declare const DeployInstanceResponse: t.ObjectCodec<{
|
|
198
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
199
|
+
operation_id: t.IdentityCodec<t.CodecType.String>;
|
|
200
|
+
}>;
|
|
201
|
+
export type DeployInstanceResponse = t.Encoded<typeof DeployInstanceResponse>;
|
|
202
|
+
export declare const InstanceConfigRequest: t.ObjectCodec<{
|
|
203
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
204
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
205
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
206
|
+
}>;
|
|
207
|
+
export type InstanceConfigRequest = t.Encoded<typeof InstanceConfigRequest>;
|
|
208
|
+
export declare const InstanceConfigResponse: t.ObjectCodec<{
|
|
209
|
+
config: t.OptionalCodec<t.Codec<{
|
|
210
|
+
region: string;
|
|
211
|
+
api?: {
|
|
212
|
+
tokens?: ({
|
|
213
|
+
secret: string;
|
|
214
|
+
} | {
|
|
215
|
+
secret_ref: string;
|
|
216
|
+
})[] | undefined;
|
|
217
|
+
} | undefined;
|
|
218
|
+
client_auth?: {
|
|
219
|
+
additional_audiences?: string[] | undefined;
|
|
220
|
+
allow_temporary_tokens?: boolean | undefined;
|
|
221
|
+
jwks?: {
|
|
222
|
+
keys: ({
|
|
223
|
+
e: string;
|
|
224
|
+
kty: "RSA";
|
|
225
|
+
n: string;
|
|
226
|
+
kid: string;
|
|
227
|
+
alg?: "RS256" | "RS384" | "RS512" | undefined;
|
|
228
|
+
use?: string | undefined;
|
|
229
|
+
} | {
|
|
230
|
+
k: {
|
|
231
|
+
secret: string;
|
|
232
|
+
} | {
|
|
233
|
+
secret_ref: string;
|
|
234
|
+
};
|
|
235
|
+
kty: "oct";
|
|
236
|
+
alg: "HS256" | "HS384" | "HS512";
|
|
237
|
+
kid: string;
|
|
238
|
+
use?: string | undefined;
|
|
239
|
+
})[];
|
|
240
|
+
} | undefined;
|
|
241
|
+
jwks_uri?: string | undefined;
|
|
242
|
+
supabase?: boolean | undefined;
|
|
243
|
+
} | undefined;
|
|
244
|
+
dev?: {
|
|
245
|
+
crud_api?: boolean | undefined;
|
|
246
|
+
demo_auth?: boolean | undefined;
|
|
247
|
+
demo_client?: boolean | undefined;
|
|
248
|
+
demo_password?: {
|
|
249
|
+
secret: string;
|
|
250
|
+
} | {
|
|
251
|
+
secret_ref: string;
|
|
252
|
+
} | undefined;
|
|
253
|
+
} | undefined;
|
|
254
|
+
replication?: {
|
|
255
|
+
connections?: ({
|
|
256
|
+
type: "postgresql";
|
|
257
|
+
uri?: string | undefined;
|
|
258
|
+
hostname?: string | undefined;
|
|
259
|
+
port?: number | undefined;
|
|
260
|
+
name?: string | undefined;
|
|
261
|
+
id?: string | undefined;
|
|
262
|
+
cacert?: string | undefined;
|
|
263
|
+
client_certificate?: string | undefined;
|
|
264
|
+
client_private_key?: {
|
|
265
|
+
secret: string;
|
|
266
|
+
} | {
|
|
267
|
+
secret_ref: string;
|
|
268
|
+
} | undefined;
|
|
269
|
+
database?: string | undefined;
|
|
270
|
+
debug_api?: boolean | undefined;
|
|
271
|
+
password?: {
|
|
272
|
+
secret: string;
|
|
273
|
+
} | {
|
|
274
|
+
secret_ref: string;
|
|
275
|
+
} | undefined;
|
|
276
|
+
sslmode?: "verify-full" | "verify-ca" | undefined;
|
|
277
|
+
tag?: string | undefined;
|
|
278
|
+
username?: string | undefined;
|
|
279
|
+
} | {
|
|
280
|
+
type: "postgresql-demo";
|
|
281
|
+
tag?: string | undefined;
|
|
282
|
+
})[] | undefined;
|
|
283
|
+
} | undefined;
|
|
284
|
+
}, {
|
|
285
|
+
region: string;
|
|
286
|
+
api?: {
|
|
287
|
+
tokens?: ({
|
|
288
|
+
secret: string;
|
|
289
|
+
} | {
|
|
290
|
+
secret_ref: string;
|
|
291
|
+
})[] | undefined;
|
|
292
|
+
} | undefined;
|
|
293
|
+
client_auth?: {
|
|
294
|
+
additional_audiences?: string[] | undefined;
|
|
295
|
+
allow_temporary_tokens?: boolean | undefined;
|
|
296
|
+
jwks?: {
|
|
297
|
+
keys: ({
|
|
298
|
+
e: string;
|
|
299
|
+
kty: "RSA";
|
|
300
|
+
n: string;
|
|
301
|
+
kid: string;
|
|
302
|
+
alg?: "RS256" | "RS384" | "RS512" | undefined;
|
|
303
|
+
use?: string | undefined;
|
|
304
|
+
} | {
|
|
305
|
+
k: {
|
|
306
|
+
secret: string;
|
|
307
|
+
} | {
|
|
308
|
+
secret_ref: string;
|
|
309
|
+
};
|
|
310
|
+
kty: "oct";
|
|
311
|
+
alg: "HS256" | "HS384" | "HS512";
|
|
312
|
+
kid: string;
|
|
313
|
+
use?: string | undefined;
|
|
314
|
+
})[];
|
|
315
|
+
} | undefined;
|
|
316
|
+
jwks_uri?: string | undefined;
|
|
317
|
+
supabase?: boolean | undefined;
|
|
318
|
+
} | undefined;
|
|
319
|
+
dev?: {
|
|
320
|
+
crud_api?: boolean | undefined;
|
|
321
|
+
demo_auth?: boolean | undefined;
|
|
322
|
+
demo_client?: boolean | undefined;
|
|
323
|
+
demo_password?: {
|
|
324
|
+
secret: string;
|
|
325
|
+
} | {
|
|
326
|
+
secret_ref: string;
|
|
327
|
+
} | undefined;
|
|
328
|
+
} | undefined;
|
|
329
|
+
replication?: {
|
|
330
|
+
connections?: ({
|
|
331
|
+
type: "postgresql";
|
|
332
|
+
uri?: string | undefined;
|
|
333
|
+
hostname?: string | undefined;
|
|
334
|
+
port?: number | undefined;
|
|
335
|
+
name?: string | undefined;
|
|
336
|
+
id?: string | undefined;
|
|
337
|
+
cacert?: string | undefined;
|
|
338
|
+
client_certificate?: string | undefined;
|
|
339
|
+
client_private_key?: {
|
|
340
|
+
secret: string;
|
|
341
|
+
} | {
|
|
342
|
+
secret_ref: string;
|
|
343
|
+
} | undefined;
|
|
344
|
+
database?: string | undefined;
|
|
345
|
+
debug_api?: boolean | undefined;
|
|
346
|
+
password?: {
|
|
347
|
+
secret: string;
|
|
348
|
+
} | {
|
|
349
|
+
secret_ref: string;
|
|
350
|
+
} | undefined;
|
|
351
|
+
sslmode?: "verify-full" | "verify-ca" | undefined;
|
|
352
|
+
tag?: string | undefined;
|
|
353
|
+
username?: string | undefined;
|
|
354
|
+
} | {
|
|
355
|
+
type: "postgresql-demo";
|
|
356
|
+
tag?: string | undefined;
|
|
357
|
+
})[] | undefined;
|
|
358
|
+
} | undefined;
|
|
359
|
+
}, string, t.CodecProps>>;
|
|
360
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
361
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
362
|
+
sync_rules: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
363
|
+
}>;
|
|
364
|
+
export type InstanceConfigResponse = t.Encoded<typeof InstanceConfigResponse>;
|
|
365
|
+
export declare const InstanceStatusRequest: t.ObjectCodec<{
|
|
366
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
367
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
368
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
369
|
+
}>;
|
|
370
|
+
export type InstanceStatusRequest = t.Encoded<typeof InstanceStatusRequest>;
|
|
371
|
+
export declare const InstanceStatusResponse: t.ObjectCodec<{
|
|
372
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
373
|
+
instance_url: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
374
|
+
operations: t.ArrayCodec<t.ObjectCodec<{
|
|
375
|
+
created_at: t.IdentityCodec<t.CodecType.String>;
|
|
376
|
+
finished_at: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
377
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
378
|
+
started_at: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
379
|
+
status: t.Union<t.Codec<"pending" | "running" | "failed", "pending" | "running" | "failed", string, t.CodecProps>, t.LiteralCodec<"completed">>;
|
|
380
|
+
type: t.Union<t.Codec<"up", "up", string, t.CodecProps>, t.LiteralCodec<"down">>;
|
|
381
|
+
}>>;
|
|
382
|
+
/** True if provisioned at least once, and should therefore be running. */
|
|
383
|
+
provisioned: t.IdentityCodec<t.CodecType.Boolean>;
|
|
384
|
+
}>;
|
|
385
|
+
export type InstanceStatusResponse = t.Encoded<typeof InstanceStatusResponse>;
|
|
386
|
+
export declare const DestroyInstanceRequest: t.ObjectCodec<{
|
|
387
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
388
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
389
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
390
|
+
}>;
|
|
391
|
+
export type DestroyInstanceRequest = t.Encoded<typeof DestroyInstanceRequest>;
|
|
392
|
+
export declare const DestroyInstanceResponse: t.ObjectCodec<{
|
|
393
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
394
|
+
operation_id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
395
|
+
}>;
|
|
396
|
+
export type DestroyInstanceResponse = t.Encoded<typeof DestroyInstanceResponse>;
|
|
397
|
+
export declare const DeactivateInstanceRequest: t.ObjectCodec<{
|
|
398
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
399
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
400
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
401
|
+
}>;
|
|
402
|
+
export type DeactivateInstanceRequest = t.Encoded<typeof DeactivateInstanceRequest>;
|
|
403
|
+
export declare const DeactivateInstanceResponse: t.ObjectCodec<{
|
|
404
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
405
|
+
operation_id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
406
|
+
}>;
|
|
407
|
+
export type DeactivateInstanceResponse = t.Encoded<typeof DeactivateInstanceResponse>;
|
|
408
|
+
export declare enum DEV_ROUTES {
|
|
409
|
+
DEMO_CREDENTIALS = "/api/v1/instances/demo-credentials",
|
|
410
|
+
EXECUTE_SQL = "/api/v1/instances/dev/execute-sql",
|
|
411
|
+
GET_SCHEMA = "/api/v1/instances/dev/schema",
|
|
412
|
+
REPROCESS_SYNC_RULES = "/api/v1/instances/dev/reprocess-sync-rules",
|
|
413
|
+
TEST_CONNECTION = "/api/v1/connections/test",
|
|
414
|
+
VALIDATE_SYNC_RULES = "/api/v1/instances/dev/validate-sync-rules"
|
|
415
|
+
}
|
|
416
|
+
export declare const DemoCredentialsRequest: t.Intersection<t.Codec<{
|
|
417
|
+
id: string;
|
|
418
|
+
app_id: string;
|
|
419
|
+
org_id: string;
|
|
420
|
+
}, {
|
|
421
|
+
id: string;
|
|
422
|
+
app_id: string;
|
|
423
|
+
org_id: string;
|
|
424
|
+
}, string, t.CodecProps>, t.ObjectCodec<{
|
|
425
|
+
connection_id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
426
|
+
}>>;
|
|
427
|
+
export type DemoCredentialsRequest = t.Encoded<typeof DemoCredentialsRequest>;
|
|
428
|
+
export declare const DemoCredentialsResponse: t.ObjectCodec<{
|
|
429
|
+
credentials: t.OptionalCodec<t.Codec<{
|
|
430
|
+
postgres_uri: string;
|
|
431
|
+
}, {
|
|
432
|
+
postgres_uri: string;
|
|
433
|
+
}, string, t.CodecProps>>;
|
|
434
|
+
}>;
|
|
435
|
+
export type DemoCredentialsResponse = internal_routes.DemoCredentialsResponse;
|
|
436
|
+
export declare const TestPostgresConnectionRequest: t.ObjectCodec<{
|
|
437
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
438
|
+
connection: t.ObjectCodec<{
|
|
439
|
+
cacert: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
440
|
+
client_certificate: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
441
|
+
client_private_key: t.OptionalCodec<t.Codec<{
|
|
442
|
+
secret: string;
|
|
443
|
+
} | {
|
|
444
|
+
secret_ref: string;
|
|
445
|
+
}, {
|
|
446
|
+
secret: string;
|
|
447
|
+
} | {
|
|
448
|
+
secret_ref: string;
|
|
449
|
+
}, string, t.CodecProps>>;
|
|
450
|
+
database: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
451
|
+
debug_api: t.OptionalCodec<t.Codec<boolean, boolean, string, t.CodecProps>>;
|
|
452
|
+
hostname: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
453
|
+
id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
454
|
+
name: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
455
|
+
password: t.OptionalCodec<t.Codec<{
|
|
456
|
+
secret: string;
|
|
457
|
+
} | {
|
|
458
|
+
secret_ref: string;
|
|
459
|
+
}, {
|
|
460
|
+
secret: string;
|
|
461
|
+
} | {
|
|
462
|
+
secret_ref: string;
|
|
463
|
+
}, string, t.CodecProps>>;
|
|
464
|
+
port: t.OptionalCodec<t.Codec<number, number, string, t.CodecProps>>;
|
|
465
|
+
sslmode: t.OptionalCodec<t.Codec<"verify-full" | "verify-ca", "verify-full" | "verify-ca", string, t.CodecProps>>;
|
|
466
|
+
tag: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
467
|
+
type: t.LiteralCodec<"postgresql">;
|
|
468
|
+
uri: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
469
|
+
username: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
470
|
+
}>;
|
|
471
|
+
id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
472
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
473
|
+
}>;
|
|
474
|
+
export type TestPostgresConnectionRequest = t.Encoded<typeof TestPostgresConnectionRequest>;
|
|
475
|
+
export declare const TestPostgresConnectionResponse: t.ObjectCodec<{
|
|
476
|
+
/**
|
|
477
|
+
* Indicates potential configuration issues.
|
|
478
|
+
*
|
|
479
|
+
* Only present if the connection succeeded.
|
|
480
|
+
*/
|
|
481
|
+
configuration: t.OptionalCodec<t.Codec<{
|
|
482
|
+
success: boolean;
|
|
483
|
+
publication_valid?: boolean | undefined;
|
|
484
|
+
wal_valid?: boolean | undefined;
|
|
485
|
+
}, {
|
|
486
|
+
success: boolean;
|
|
487
|
+
publication_valid?: boolean | undefined;
|
|
488
|
+
wal_valid?: boolean | undefined;
|
|
489
|
+
}, string, t.CodecProps>>;
|
|
490
|
+
connection: t.ObjectCodec<{
|
|
491
|
+
/** Only set if reachable and tls_valid */
|
|
492
|
+
authenticated: t.OptionalCodec<t.Codec<boolean, boolean, string, t.CodecProps>>;
|
|
493
|
+
/** Can open a TCP connection. */
|
|
494
|
+
reachable: t.IdentityCodec<t.CodecType.Boolean>;
|
|
495
|
+
/** If false, check the fields below. */
|
|
496
|
+
success: t.IdentityCodec<t.CodecType.Boolean>;
|
|
497
|
+
/** If TLS connection failed, use this CA list. */
|
|
498
|
+
suggested_cacert: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
499
|
+
/** verify-full or verify-ca */
|
|
500
|
+
suggested_sslmode: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
501
|
+
/**
|
|
502
|
+
* Did TLS connection work? Only set if reachable.
|
|
503
|
+
*/
|
|
504
|
+
tls_valid: t.OptionalCodec<t.Codec<boolean, boolean, string, t.CodecProps>>;
|
|
505
|
+
}>;
|
|
506
|
+
/**
|
|
507
|
+
* A human-readable error message, always set if success = false.
|
|
508
|
+
*
|
|
509
|
+
* Use as a fallback if the specific reason is not clear from other response fields.
|
|
510
|
+
*/
|
|
511
|
+
error: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
512
|
+
/** If false, check the fields below. */
|
|
513
|
+
success: t.IdentityCodec<t.CodecType.Boolean>;
|
|
514
|
+
}>;
|
|
515
|
+
export type TestPostgresConnectionResponse = t.Encoded<typeof TestPostgresConnectionResponse>;
|
|
516
|
+
export declare const GetSchemaRequest: t.ObjectCodec<{
|
|
517
|
+
app_id: t.IdentityCodec<t.CodecType.String>;
|
|
518
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
519
|
+
org_id: t.IdentityCodec<t.CodecType.String>;
|
|
520
|
+
}>;
|
|
521
|
+
export type GetSchemaRequest = t.Encoded<typeof GetSchemaRequest>;
|
|
522
|
+
export declare const GetSchemaResponse: t.ObjectCodec<{
|
|
523
|
+
connections: t.ArrayCodec<t.ObjectCodec<{
|
|
524
|
+
id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
525
|
+
schemas: t.ArrayCodec<t.ObjectCodec<{
|
|
526
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
527
|
+
tables: t.ArrayCodec<t.ObjectCodec<{
|
|
528
|
+
columns: t.ArrayCodec<t.ObjectCodec<{
|
|
529
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
530
|
+
pg_type: t.IdentityCodec<t.CodecType.String>;
|
|
531
|
+
type: t.IdentityCodec<t.CodecType.String>;
|
|
532
|
+
}>>;
|
|
533
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
534
|
+
}>>;
|
|
535
|
+
}>>;
|
|
536
|
+
tag: t.IdentityCodec<t.CodecType.String>;
|
|
537
|
+
}>>;
|
|
538
|
+
}>;
|
|
539
|
+
export type GetSchemaResponse = t.Encoded<typeof GetSchemaResponse>;
|
|
540
|
+
export declare const ExecuteSqlRequest: t.Intersection<t.Codec<{
|
|
541
|
+
id: string;
|
|
542
|
+
app_id: string;
|
|
543
|
+
org_id: string;
|
|
544
|
+
}, {
|
|
545
|
+
id: string;
|
|
546
|
+
app_id: string;
|
|
547
|
+
org_id: string;
|
|
548
|
+
}, string, t.CodecProps>, t.ObjectCodec<{
|
|
549
|
+
connection_id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
550
|
+
sql: t.ObjectCodec<{
|
|
551
|
+
args: t.ArrayCodec<t.Union<t.Codec<string | number, string | number, string, t.CodecProps>, t.IdentityCodec<t.CodecType.Boolean>>>;
|
|
552
|
+
query: t.IdentityCodec<t.CodecType.String>;
|
|
553
|
+
}>;
|
|
554
|
+
}>>;
|
|
555
|
+
export type ExecuteSqlRequest = t.Encoded<typeof ExecuteSqlRequest>;
|
|
556
|
+
export declare const ExecuteSqlResponse: t.ObjectCodec<{
|
|
557
|
+
error: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
558
|
+
results: t.ObjectCodec<{
|
|
559
|
+
columns: t.ArrayCodec<t.IdentityCodec<t.CodecType.String>>;
|
|
560
|
+
rows: t.ArrayCodec<t.ArrayCodec<t.Union<t.Codec<string | number | boolean, string | number | boolean, string, t.CodecProps>, t.Codec<null, null, t.CodecType.Null, t.CodecProps>>>>;
|
|
561
|
+
}>;
|
|
562
|
+
success: t.IdentityCodec<t.CodecType.Boolean>;
|
|
563
|
+
}>;
|
|
564
|
+
export type ExecuteSqlResponse = internal_routes.ExecuteSqlResponse;
|
|
565
|
+
export declare const ValidateSyncRulesRequest: t.Intersection<t.Codec<{
|
|
566
|
+
id: string;
|
|
567
|
+
app_id: string;
|
|
568
|
+
org_id: string;
|
|
569
|
+
}, {
|
|
570
|
+
id: string;
|
|
571
|
+
app_id: string;
|
|
572
|
+
org_id: string;
|
|
573
|
+
}, string, t.CodecProps>, t.ObjectCodec<{
|
|
574
|
+
sync_rules: t.IdentityCodec<t.CodecType.String>;
|
|
575
|
+
}>>;
|
|
576
|
+
export type ValidateSyncRulesRequest = t.Encoded<typeof ValidateSyncRulesRequest>;
|
|
577
|
+
export declare const ValidateSyncRulesResponse: t.ObjectCodec<{
|
|
578
|
+
connections: t.ArrayCodec<t.ObjectCodec<{
|
|
579
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
580
|
+
initial_replication_done: t.IdentityCodec<t.CodecType.Boolean>;
|
|
581
|
+
last_checkpoint_ts: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
582
|
+
last_keepalive_ts: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
583
|
+
last_lsn: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
584
|
+
replication_lag_bytes: t.OptionalCodec<t.Codec<number, number, string, t.CodecProps>>;
|
|
585
|
+
slot_name: t.IdentityCodec<t.CodecType.String>;
|
|
586
|
+
tables: t.ArrayCodec<t.ObjectCodec<{
|
|
587
|
+
data_queries: t.IdentityCodec<t.CodecType.Boolean>;
|
|
588
|
+
errors: t.ArrayCodec<t.ObjectCodec<{
|
|
589
|
+
level: t.Union<t.Codec<"warning", "warning", string, t.CodecProps>, t.LiteralCodec<"fatal">>;
|
|
590
|
+
message: t.IdentityCodec<t.CodecType.String>;
|
|
591
|
+
}>>;
|
|
592
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
593
|
+
parameter_queries: t.IdentityCodec<t.CodecType.Boolean>;
|
|
594
|
+
pattern: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
595
|
+
replication_id: t.ArrayCodec<t.IdentityCodec<t.CodecType.String>>;
|
|
596
|
+
schema: t.IdentityCodec<t.CodecType.String>;
|
|
597
|
+
}>>;
|
|
598
|
+
tag: t.IdentityCodec<t.CodecType.String>;
|
|
599
|
+
}>>;
|
|
600
|
+
content: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
601
|
+
errors: t.ArrayCodec<t.ObjectCodec<{
|
|
602
|
+
level: t.Union<t.Codec<"warning", "warning", string, t.CodecProps>, t.LiteralCodec<"fatal">>;
|
|
603
|
+
message: t.IdentityCodec<t.CodecType.String>;
|
|
604
|
+
}>>;
|
|
605
|
+
}>;
|
|
606
|
+
export type ValidateSyncRulesResponse = t.Encoded<typeof ValidateSyncRulesResponse>;
|
|
607
|
+
export declare const ReprocessSyncRulesRequest: t.Intersection<t.Codec<{
|
|
608
|
+
id: string;
|
|
609
|
+
app_id: string;
|
|
610
|
+
org_id: string;
|
|
611
|
+
}, {
|
|
612
|
+
id: string;
|
|
613
|
+
app_id: string;
|
|
614
|
+
org_id: string;
|
|
615
|
+
}, string, t.CodecProps>, t.ObjectCodec<{}>>;
|
|
616
|
+
export type ReprocessSyncRulesRequest = t.Encoded<typeof ReprocessSyncRulesRequest>;
|
|
617
|
+
export declare const ReprocessSyncRulesResponse: t.ObjectCodec<{
|
|
618
|
+
connections: t.ArrayCodec<t.ObjectCodec<{
|
|
619
|
+
id: t.OptionalCodec<t.Codec<string, string, string, t.CodecProps>>;
|
|
620
|
+
slot_name: t.IdentityCodec<t.CodecType.String>;
|
|
621
|
+
tag: t.IdentityCodec<t.CodecType.String>;
|
|
622
|
+
}>>;
|
|
623
|
+
}>;
|
|
624
|
+
export type ReprocessSyncRulesResponse = t.Encoded<typeof ReprocessSyncRulesResponse>;
|
|
625
|
+
export declare const InstanceDiagnosticsRequest: t.Intersection<t.Codec<{
|
|
626
|
+
id: string;
|
|
627
|
+
app_id: string;
|
|
628
|
+
org_id: string;
|
|
629
|
+
}, {
|
|
630
|
+
id: string;
|
|
631
|
+
app_id: string;
|
|
632
|
+
org_id: string;
|
|
633
|
+
}, string, t.CodecProps>, t.ObjectCodec<{
|
|
634
|
+
sync_rules_content: t.OptionalCodec<t.Codec<boolean, boolean, string, t.CodecProps>>;
|
|
635
|
+
}>>;
|
|
636
|
+
export type InstanceDiagnosticsRequest = t.Encoded<typeof InstanceDiagnosticsRequest>;
|
|
637
|
+
export declare const InstanceDiagnosticsResponse: t.ObjectCodec<{
|
|
638
|
+
active_sync_rules: t.OptionalCodec<t.Codec<{
|
|
639
|
+
connections: {
|
|
640
|
+
id: string;
|
|
641
|
+
tag: string;
|
|
642
|
+
initial_replication_done: boolean;
|
|
643
|
+
slot_name: string;
|
|
644
|
+
tables: {
|
|
645
|
+
name: string;
|
|
646
|
+
data_queries: boolean;
|
|
647
|
+
errors: {
|
|
648
|
+
message: string;
|
|
649
|
+
level: "warning" | "fatal";
|
|
650
|
+
}[];
|
|
651
|
+
parameter_queries: boolean;
|
|
652
|
+
replication_id: string[];
|
|
653
|
+
schema: string;
|
|
654
|
+
pattern?: string | undefined;
|
|
655
|
+
}[];
|
|
656
|
+
last_checkpoint_ts?: string | undefined;
|
|
657
|
+
last_keepalive_ts?: string | undefined;
|
|
658
|
+
last_lsn?: string | undefined;
|
|
659
|
+
replication_lag_bytes?: number | undefined;
|
|
660
|
+
}[];
|
|
661
|
+
errors: {
|
|
662
|
+
message: string;
|
|
663
|
+
level: "warning" | "fatal";
|
|
664
|
+
}[];
|
|
665
|
+
content?: string | undefined;
|
|
666
|
+
}, {
|
|
667
|
+
connections: {
|
|
668
|
+
id: string;
|
|
669
|
+
tag: string;
|
|
670
|
+
initial_replication_done: boolean;
|
|
671
|
+
slot_name: string;
|
|
672
|
+
tables: {
|
|
673
|
+
name: string;
|
|
674
|
+
data_queries: boolean;
|
|
675
|
+
errors: {
|
|
676
|
+
message: string;
|
|
677
|
+
level: "warning" | "fatal";
|
|
678
|
+
}[];
|
|
679
|
+
parameter_queries: boolean;
|
|
680
|
+
replication_id: string[];
|
|
681
|
+
schema: string;
|
|
682
|
+
pattern?: string | undefined;
|
|
683
|
+
}[];
|
|
684
|
+
last_checkpoint_ts?: string | undefined;
|
|
685
|
+
last_keepalive_ts?: string | undefined;
|
|
686
|
+
last_lsn?: string | undefined;
|
|
687
|
+
replication_lag_bytes?: number | undefined;
|
|
688
|
+
}[];
|
|
689
|
+
errors: {
|
|
690
|
+
message: string;
|
|
691
|
+
level: "warning" | "fatal";
|
|
692
|
+
}[];
|
|
693
|
+
content?: string | undefined;
|
|
694
|
+
}, string, t.CodecProps>>;
|
|
695
|
+
connections: t.ArrayCodec<t.ObjectCodec<{
|
|
696
|
+
connected: t.IdentityCodec<t.CodecType.Boolean>;
|
|
697
|
+
errors: t.ArrayCodec<t.ObjectCodec<{
|
|
698
|
+
level: t.Union<t.Codec<"warning", "warning", string, t.CodecProps>, t.LiteralCodec<"fatal">>;
|
|
699
|
+
message: t.IdentityCodec<t.CodecType.String>;
|
|
700
|
+
}>>;
|
|
701
|
+
id: t.IdentityCodec<t.CodecType.String>;
|
|
702
|
+
postgres_uri: t.IdentityCodec<t.CodecType.String>;
|
|
703
|
+
}>>;
|
|
704
|
+
deploying_sync_rules: t.OptionalCodec<t.Codec<{
|
|
705
|
+
connections: {
|
|
706
|
+
id: string;
|
|
707
|
+
tag: string;
|
|
708
|
+
initial_replication_done: boolean;
|
|
709
|
+
slot_name: string;
|
|
710
|
+
tables: {
|
|
711
|
+
name: string;
|
|
712
|
+
data_queries: boolean;
|
|
713
|
+
errors: {
|
|
714
|
+
message: string;
|
|
715
|
+
level: "warning" | "fatal";
|
|
716
|
+
}[];
|
|
717
|
+
parameter_queries: boolean;
|
|
718
|
+
replication_id: string[];
|
|
719
|
+
schema: string;
|
|
720
|
+
pattern?: string | undefined;
|
|
721
|
+
}[];
|
|
722
|
+
last_checkpoint_ts?: string | undefined;
|
|
723
|
+
last_keepalive_ts?: string | undefined;
|
|
724
|
+
last_lsn?: string | undefined;
|
|
725
|
+
replication_lag_bytes?: number | undefined;
|
|
726
|
+
}[];
|
|
727
|
+
errors: {
|
|
728
|
+
message: string;
|
|
729
|
+
level: "warning" | "fatal";
|
|
730
|
+
}[];
|
|
731
|
+
content?: string | undefined;
|
|
732
|
+
}, {
|
|
733
|
+
connections: {
|
|
734
|
+
id: string;
|
|
735
|
+
tag: string;
|
|
736
|
+
initial_replication_done: boolean;
|
|
737
|
+
slot_name: string;
|
|
738
|
+
tables: {
|
|
739
|
+
name: string;
|
|
740
|
+
data_queries: boolean;
|
|
741
|
+
errors: {
|
|
742
|
+
message: string;
|
|
743
|
+
level: "warning" | "fatal";
|
|
744
|
+
}[];
|
|
745
|
+
parameter_queries: boolean;
|
|
746
|
+
replication_id: string[];
|
|
747
|
+
schema: string;
|
|
748
|
+
pattern?: string | undefined;
|
|
749
|
+
}[];
|
|
750
|
+
last_checkpoint_ts?: string | undefined;
|
|
751
|
+
last_keepalive_ts?: string | undefined;
|
|
752
|
+
last_lsn?: string | undefined;
|
|
753
|
+
replication_lag_bytes?: number | undefined;
|
|
754
|
+
}[];
|
|
755
|
+
errors: {
|
|
756
|
+
message: string;
|
|
757
|
+
level: "warning" | "fatal";
|
|
758
|
+
}[];
|
|
759
|
+
content?: string | undefined;
|
|
760
|
+
}, string, t.CodecProps>>;
|
|
761
|
+
}>;
|
|
762
|
+
export type InstanceDiagnosticsResponse = internal_routes.DiagnosticsResponse;
|
|
763
|
+
export declare const ListRegionsRequest: t.ObjectCodec<{}>;
|
|
764
|
+
export type ListRegionsRequest = t.Encoded<typeof ListRegionsRequest>;
|
|
765
|
+
/**
|
|
766
|
+
* For IP whitelisting, we recommend just including IPs from all regions.
|
|
767
|
+
*
|
|
768
|
+
* An additional "dev" region is included, with IPs used for development purposes,
|
|
769
|
+
* e.g. "test connection".
|
|
770
|
+
*/
|
|
771
|
+
export declare const ListRegionsResponse: t.ObjectCodec<{
|
|
772
|
+
regions: t.ArrayCodec<t.ObjectCodec<{
|
|
773
|
+
/** false for "dev" region */
|
|
774
|
+
deployable: t.IdentityCodec<t.CodecType.Boolean>;
|
|
775
|
+
ips: t.ArrayCodec<t.IdentityCodec<t.CodecType.String>>;
|
|
776
|
+
name: t.IdentityCodec<t.CodecType.String>;
|
|
777
|
+
}>>;
|
|
778
|
+
}>;
|
|
779
|
+
export type ListRegionsResponse = t.Encoded<typeof ListRegionsResponse>;
|