@lovable.dev/sdk 1.2.3 → 1.4.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/index.d.ts +259 -287
- package/dist/index.js +2 -48
- package/dist/index.js.map +1 -1
- package/dist/schemas.d.ts +65 -65
- package/dist/schemas.js +40 -36
- package/dist/schemas.js.map +1 -1
- package/package.json +1 -1
- package/src/client.ts +10 -54
- package/src/generated/paths.ts +256 -257
- package/src/generated/zod/zod.gen.ts +46 -36
- package/src/index.ts +0 -6
- package/src/types.ts +1 -15
|
@@ -191,22 +191,7 @@ export const CursorListResponseProjectPiiFindingDtoSchema = z.object({
|
|
|
191
191
|
pagination: PaginationSchema
|
|
192
192
|
});
|
|
193
193
|
|
|
194
|
-
export const PublicV1AddConnectorBodySchema = z.object({
|
|
195
|
-
auth_type: z.enum(['none', 'bearer_token']),
|
|
196
|
-
connector_id: z.string().optional(),
|
|
197
|
-
name: z.string().min(1),
|
|
198
|
-
network_transport_endpoint_id: z.string().optional(),
|
|
199
|
-
network_transport_profile_id: z.string().optional(),
|
|
200
|
-
network_transport_type: z.string().optional(),
|
|
201
|
-
relay_client_id: z.string().optional(),
|
|
202
|
-
relay_service_name: z.string().optional(),
|
|
203
|
-
token: z.string().optional(),
|
|
204
|
-
url: z.string().optional(),
|
|
205
|
-
workspace_id: z.string()
|
|
206
|
-
});
|
|
207
|
-
|
|
208
194
|
export const PublicV1ConnectorItemSchema = z.object({
|
|
209
|
-
auth_type: z.string().optional(),
|
|
210
195
|
categories: z.array(z.string()).nullish(),
|
|
211
196
|
category: z.string().optional(),
|
|
212
197
|
connector_id: z.string().optional(),
|
|
@@ -215,11 +200,12 @@ export const PublicV1ConnectorItemSchema = z.object({
|
|
|
215
200
|
id: z.string(),
|
|
216
201
|
is_connected: z.boolean().optional(),
|
|
217
202
|
is_enabled_for_workspace: z.boolean().optional(),
|
|
218
|
-
|
|
203
|
+
settings_url: z.string().optional(),
|
|
219
204
|
short_description: z.string().optional(),
|
|
220
205
|
status: z.string().optional(),
|
|
221
206
|
summary: z.string().optional(),
|
|
222
|
-
type: z.string()
|
|
207
|
+
type: z.string(),
|
|
208
|
+
types: z.array(z.string()).optional()
|
|
223
209
|
});
|
|
224
210
|
|
|
225
211
|
export const CursorListResponsePublicV1ConnectorItemSchema = z.object({
|
|
@@ -473,13 +459,6 @@ export const StandardConnectorPromotionSchema = z.object({
|
|
|
473
459
|
});
|
|
474
460
|
|
|
475
461
|
export const StandardConnectorApiSchema = z.object({
|
|
476
|
-
auth_type: z.enum([
|
|
477
|
-
'APIKEY',
|
|
478
|
-
'OAUTH2',
|
|
479
|
-
'OAUTH2_CLIENT_CREDENTIALS',
|
|
480
|
-
'WIF',
|
|
481
|
-
'STEPS'
|
|
482
|
-
]),
|
|
483
462
|
can_be_managed: z.boolean(),
|
|
484
463
|
can_restrict_to_admins: z.boolean(),
|
|
485
464
|
categories: z.array(z.enum([
|
|
@@ -645,11 +624,6 @@ export const V1AvailableConnectorEntrySchema = z.object({
|
|
|
645
624
|
summary: z.string()
|
|
646
625
|
});
|
|
647
626
|
|
|
648
|
-
export const CursorListResponseV1AvailableConnectorEntrySchema = z.object({
|
|
649
|
-
data: z.array(V1AvailableConnectorEntrySchema).nullable(),
|
|
650
|
-
pagination: PaginationSchema
|
|
651
|
-
});
|
|
652
|
-
|
|
653
627
|
export const V1AwaitingInputSummarySchema = z.object({
|
|
654
628
|
event_id: z.string(),
|
|
655
629
|
input_schema: z.unknown().optional(),
|
|
@@ -672,6 +646,29 @@ export const V1BillingPeriodSchema = z.object({
|
|
|
672
646
|
start: z.iso.datetime()
|
|
673
647
|
});
|
|
674
648
|
|
|
649
|
+
export const V1BulkMemberCreditLimitItemSchema = z.object({
|
|
650
|
+
monthly_credit_limit: z.number().gte(0).nullable(),
|
|
651
|
+
user_id: z.string()
|
|
652
|
+
});
|
|
653
|
+
|
|
654
|
+
export const V1BulkMemberCreditLimitResultSchema = z.object({
|
|
655
|
+
error: z.string().optional(),
|
|
656
|
+
status: z.string(),
|
|
657
|
+
user_id: z.string()
|
|
658
|
+
});
|
|
659
|
+
|
|
660
|
+
export const V1BulkSetMemberCreditLimitInputBodySchema = z.object({
|
|
661
|
+
members: z.array(V1BulkMemberCreditLimitItemSchema).min(1).max(50),
|
|
662
|
+
workspace_id: z.string()
|
|
663
|
+
});
|
|
664
|
+
|
|
665
|
+
export const V1BulkSetMemberCreditLimitOutputBodySchema = z.object({
|
|
666
|
+
failed: z.number(),
|
|
667
|
+
results: z.array(V1BulkMemberCreditLimitResultSchema).nullable(),
|
|
668
|
+
successful: z.number(),
|
|
669
|
+
total: z.number()
|
|
670
|
+
});
|
|
671
|
+
|
|
675
672
|
export const V1ConnectionItemSchema = z.object({
|
|
676
673
|
connector_id: z.string(),
|
|
677
674
|
created_at: z.string(),
|
|
@@ -682,11 +679,6 @@ export const V1ConnectionItemSchema = z.object({
|
|
|
682
679
|
updated_at: z.string()
|
|
683
680
|
});
|
|
684
681
|
|
|
685
|
-
export const CursorListResponseV1ConnectionItemSchema = z.object({
|
|
686
|
-
data: z.array(V1ConnectionItemSchema).nullable(),
|
|
687
|
-
pagination: PaginationSchema
|
|
688
|
-
});
|
|
689
|
-
|
|
690
682
|
export const V1ConnectorResponseSchema = z.object({
|
|
691
683
|
auth_type: z.string(),
|
|
692
684
|
connector_id: z.string().optional(),
|
|
@@ -790,8 +782,7 @@ export const V1DiffEntrySchema = z.object({
|
|
|
790
782
|
});
|
|
791
783
|
|
|
792
784
|
export const V1DiffResponseSchema = z.object({
|
|
793
|
-
diffs: z.array(V1DiffEntrySchema).nullable()
|
|
794
|
-
error: z.string().optional()
|
|
785
|
+
diffs: z.array(V1DiffEntrySchema).nullable()
|
|
795
786
|
});
|
|
796
787
|
|
|
797
788
|
export const V1EditSummarySchema = z.object({
|
|
@@ -803,6 +794,13 @@ export const V1EditSummarySchema = z.object({
|
|
|
803
794
|
type: z.string()
|
|
804
795
|
});
|
|
805
796
|
|
|
797
|
+
export const PublicV1GetEditsOutputBodySchema = z.object({
|
|
798
|
+
data: z.array(V1EditSummarySchema).nullable(),
|
|
799
|
+
edits: z.array(V1EditSummarySchema).nullable(),
|
|
800
|
+
has_more: z.boolean(),
|
|
801
|
+
pagination: PaginationSchema
|
|
802
|
+
});
|
|
803
|
+
|
|
806
804
|
export const V1EnableDatabaseOutputBodySchema = z.object({
|
|
807
805
|
enabled: z.boolean(),
|
|
808
806
|
stack: z.string()
|
|
@@ -1204,6 +1202,16 @@ export const V1SendMessageInputBodySchema = z.object({
|
|
|
1204
1202
|
variant_id: z.string().optional()
|
|
1205
1203
|
});
|
|
1206
1204
|
|
|
1205
|
+
export const V1UpdateMemberCreditLimitInputBodySchema = z.object({
|
|
1206
|
+
monthly_credit_limit: z.number().gte(0).nullish(),
|
|
1207
|
+
workspace_id: z.string()
|
|
1208
|
+
});
|
|
1209
|
+
|
|
1210
|
+
export const V1UpdateWorkspaceSettingsInputBodySchema = z.object({
|
|
1211
|
+
default_monthly_member_credit_limit: z.number().gte(0).nullish(),
|
|
1212
|
+
workspace_id: z.string()
|
|
1213
|
+
});
|
|
1214
|
+
|
|
1207
1215
|
export const V1UsagePeriodSchema = z.object({
|
|
1208
1216
|
end: z.string(),
|
|
1209
1217
|
granularity: z.string().optional(),
|
|
@@ -1269,6 +1277,7 @@ export const V1WorkspaceMemberSchema = z.object({
|
|
|
1269
1277
|
email: z.string().optional(),
|
|
1270
1278
|
invited_at: z.iso.datetime().optional(),
|
|
1271
1279
|
joined_at: z.iso.datetime().optional(),
|
|
1280
|
+
monthly_credit_limit: z.number().optional(),
|
|
1272
1281
|
role: z.string(),
|
|
1273
1282
|
user_id: z.string(),
|
|
1274
1283
|
workspace_id: z.string()
|
|
@@ -1421,6 +1430,7 @@ export const V1WorkspaceSecurityDashboardBodySchema = z.object({
|
|
|
1421
1430
|
export const V1WorkspaceSettingsBodySchema = z.object({
|
|
1422
1431
|
billing_period_end_date: z.iso.datetime().optional(),
|
|
1423
1432
|
billing_period_start_date: z.iso.datetime().optional(),
|
|
1433
|
+
default_monthly_member_credit_limit: z.number().optional(),
|
|
1424
1434
|
default_project_visibility: z.string().optional(),
|
|
1425
1435
|
enable_pii: z.boolean(),
|
|
1426
1436
|
enforce_sso: z.boolean(),
|
package/src/index.ts
CHANGED
|
@@ -69,20 +69,14 @@ export type {
|
|
|
69
69
|
TemplateProjectResponse,
|
|
70
70
|
ListLibraryProjectsResponse,
|
|
71
71
|
ListTemplateProjectsResponse,
|
|
72
|
-
ConnectorResponse,
|
|
73
|
-
AvailableConnectorEntry,
|
|
74
|
-
AddConnectorBody,
|
|
75
72
|
ConnectorItem,
|
|
76
73
|
StandardConnectorItem,
|
|
77
74
|
SeamlessConnectorItem,
|
|
78
75
|
MCPConnectorItem,
|
|
79
|
-
ConnectionItem,
|
|
80
76
|
ListConnectorsResponse,
|
|
81
|
-
ListAvailableConnectorsResponse,
|
|
82
77
|
ListStandardConnectorsResponse,
|
|
83
78
|
ListSeamlessConnectorsResponse,
|
|
84
79
|
ListMCPConnectorsResponse,
|
|
85
|
-
ListConnectionsResponse,
|
|
86
80
|
TimeSeriesDataPoint,
|
|
87
81
|
TimeSeriesData,
|
|
88
82
|
ListDataPoint,
|
package/src/types.ts
CHANGED
|
@@ -136,7 +136,7 @@ export type GitDiffResponse = Schemas["V1DiffResponse"];
|
|
|
136
136
|
export type GitFileEntry = Schemas["GitFileEntryLite"];
|
|
137
137
|
export type GitFilesResponse = Schemas["PublicV1GitFilesResponse"] & { files: GitFileEntry[] };
|
|
138
138
|
export type EditSummary = Schemas["V1EditSummary"];
|
|
139
|
-
export type EditsResponse = Schemas["
|
|
139
|
+
export type EditsResponse = Schemas["PublicV1GetEditsOutputBody"];
|
|
140
140
|
|
|
141
141
|
// --- Libraries & templates ---
|
|
142
142
|
|
|
@@ -155,24 +155,15 @@ export type ListTemplateProjectsResponse = {
|
|
|
155
155
|
|
|
156
156
|
// --- Connectors ---
|
|
157
157
|
|
|
158
|
-
export type ConnectorResponse = Schemas["V1ConnectorResponse"];
|
|
159
|
-
export type AvailableConnectorEntry = Schemas["V1AvailableConnectorEntry"];
|
|
160
|
-
export type AddConnectorBody = Omit<Schemas["PublicV1AddConnectorBody"], "workspace_id">;
|
|
161
158
|
export type ConnectorItem = Schemas["PublicV1ConnectorItem"];
|
|
162
159
|
export type StandardConnectorItem = ConnectorItem;
|
|
163
160
|
export type SeamlessConnectorItem = ConnectorItem;
|
|
164
161
|
export type MCPConnectorItem = ConnectorItem;
|
|
165
|
-
export type ConnectionItem = Schemas["V1ConnectionItem"];
|
|
166
162
|
export type ListConnectorsResponse = Omit<Schemas["CursorListResponsePublicV1ConnectorItem"], "data"> & {
|
|
167
163
|
data: ConnectorItem[];
|
|
168
164
|
connectors: ConnectorItem[];
|
|
169
165
|
has_more: boolean;
|
|
170
166
|
};
|
|
171
|
-
export type ListAvailableConnectorsResponse = Omit<Schemas["CursorListResponseV1AvailableConnectorEntry"], "data"> & {
|
|
172
|
-
data: AvailableConnectorEntry[];
|
|
173
|
-
catalog: AvailableConnectorEntry[];
|
|
174
|
-
has_more: boolean;
|
|
175
|
-
};
|
|
176
167
|
export type ListStandardConnectorsResponse = Omit<ListConnectorsResponse, "connectors"> & {
|
|
177
168
|
connectors: StandardConnectorItem[];
|
|
178
169
|
};
|
|
@@ -184,11 +175,6 @@ export type ListMCPConnectorsResponse = Omit<ListConnectorsResponse, "connectors
|
|
|
184
175
|
data: MCPConnectorItem[];
|
|
185
176
|
connectors: MCPConnectorItem[];
|
|
186
177
|
};
|
|
187
|
-
export type ListConnectionsResponse = Omit<Schemas["CursorListResponseV1ConnectionItem"], "data"> & {
|
|
188
|
-
data: ConnectionItem[];
|
|
189
|
-
connections: ConnectionItem[];
|
|
190
|
-
has_more: boolean;
|
|
191
|
-
};
|
|
192
178
|
|
|
193
179
|
// --- Analytics ---
|
|
194
180
|
|