@databutton/firebase-types 1.187.0 → 1.188.1
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.
|
@@ -1666,6 +1666,8 @@ export interface Project {
|
|
|
1666
1666
|
lifeStageUpdatedBy: PerformedBy;
|
|
1667
1667
|
/** Heuristic phase deduced from signals, see InferredProjectPhase. */
|
|
1668
1668
|
inferredPhase?: InferredPhaseState;
|
|
1669
|
+
/** When the last attempt to infer the phase failed. Written by the backend only. */
|
|
1670
|
+
inferredPhaseFailedAt?: Timestamp;
|
|
1669
1671
|
theme?: ProjectTheme;
|
|
1670
1672
|
guidelines?: ProjectGuidelines;
|
|
1671
1673
|
aiGeneratedSummary?: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Timestamp } from "firebase/firestore";
|
|
2
2
|
import type { RunMigrationsResponse } from "../db-api.js";
|
|
3
3
|
import type { AccountRole, CreateNeonTransferErrorCode, CreateProjectErrorCode, CreateStackAuthTransferErrorCode, CreateTeamAccountErrorCode, MigrateToRiffErrorCode, NotificationType } from "./enums.js";
|
|
4
|
-
import type { ApprovalLevel, Datafile, Dataframe, Job, Project, ProjectPermissionName, ProjectTemplate, ScheduleTarget, ScheduleWhen } from "./persisted.js";
|
|
4
|
+
import type { ApprovalLevel, Datafile, Dataframe, InferredProjectPhase, Job, Project, ProjectLifeStage, ProjectPermissionName, ProjectTemplate, ScheduleTarget, ScheduleWhen } from "./persisted.js";
|
|
5
5
|
export type DeleteJob = Pick<Job, "markedForDeletionAt" | "markedForDeletionBy">;
|
|
6
6
|
export type DeleteProject = Pick<Project, "markedForDeletionAt" | "markedForDeletionBy">;
|
|
7
7
|
export type DeleteDataframe = Pick<Dataframe, "markedForDeletionAt" | "markedForDeletionBy">;
|
|
@@ -139,6 +139,12 @@ export type AdminDetachFromParentPayload = {
|
|
|
139
139
|
export type AdminDetachFromParentResult = {
|
|
140
140
|
success: boolean;
|
|
141
141
|
};
|
|
142
|
+
export type AdminDeleteAccountPayload = {
|
|
143
|
+
accountId: string;
|
|
144
|
+
};
|
|
145
|
+
export type AdminDeleteAccountResult = {
|
|
146
|
+
success: boolean;
|
|
147
|
+
};
|
|
142
148
|
export type AdminEnableSsoPayload = {
|
|
143
149
|
accountId: string;
|
|
144
150
|
organizationId: string;
|
|
@@ -221,6 +227,38 @@ export type AdminAccountRow = {
|
|
|
221
227
|
export type AdminSearchAccountsResult = {
|
|
222
228
|
accounts: AdminAccountRow[];
|
|
223
229
|
};
|
|
230
|
+
export type AdminListHibernationCandidatesPayload = {
|
|
231
|
+
phases?: InferredProjectPhase[];
|
|
232
|
+
owner?: string;
|
|
233
|
+
deployed?: boolean;
|
|
234
|
+
weeks?: number;
|
|
235
|
+
};
|
|
236
|
+
export type AdminHibernationCandidateRow = {
|
|
237
|
+
id: string;
|
|
238
|
+
name: string;
|
|
239
|
+
owner: string;
|
|
240
|
+
ownerName: string | null;
|
|
241
|
+
lifeStage: ProjectLifeStage;
|
|
242
|
+
phase: InferredProjectPhase;
|
|
243
|
+
phaseConfidence: number;
|
|
244
|
+
phaseSinceMs: number;
|
|
245
|
+
lastOpenedAtMs: number | null;
|
|
246
|
+
deployed: boolean;
|
|
247
|
+
creditCentsByWeek: Record<string, number[]>;
|
|
248
|
+
};
|
|
249
|
+
export type AdminListHibernationCandidatesResult = {
|
|
250
|
+
projects: AdminHibernationCandidateRow[];
|
|
251
|
+
};
|
|
252
|
+
export type AdminHibernateProjectsPayload = {
|
|
253
|
+
projectIds: string[];
|
|
254
|
+
};
|
|
255
|
+
export type AdminHibernateProjectsResult = {
|
|
256
|
+
requested: string[];
|
|
257
|
+
skipped: {
|
|
258
|
+
projectId: string;
|
|
259
|
+
reason: string;
|
|
260
|
+
}[];
|
|
261
|
+
};
|
|
224
262
|
export type AdminCallableRequest = {
|
|
225
263
|
action: "addCredits";
|
|
226
264
|
payload: AdminAddCreditsPayload;
|
|
@@ -242,6 +280,9 @@ export type AdminCallableRequest = {
|
|
|
242
280
|
} | {
|
|
243
281
|
action: "detachFromParent";
|
|
244
282
|
payload: AdminDetachFromParentPayload;
|
|
283
|
+
} | {
|
|
284
|
+
action: "deleteAccount";
|
|
285
|
+
payload: AdminDeleteAccountPayload;
|
|
245
286
|
} | {
|
|
246
287
|
action: "searchAccounts";
|
|
247
288
|
payload: AdminSearchAccountsPayload;
|
|
@@ -263,6 +304,12 @@ export type AdminCallableRequest = {
|
|
|
263
304
|
} | {
|
|
264
305
|
action: "bulkLinkAccountIntegration";
|
|
265
306
|
payload: AdminBulkLinkAccountIntegrationPayload;
|
|
307
|
+
} | {
|
|
308
|
+
action: "listHibernationCandidates";
|
|
309
|
+
payload: AdminListHibernationCandidatesPayload;
|
|
310
|
+
} | {
|
|
311
|
+
action: "hibernateProjects";
|
|
312
|
+
payload: AdminHibernateProjectsPayload;
|
|
266
313
|
};
|
|
267
314
|
export type AdminCallableResponse = {
|
|
268
315
|
action: "addCredits";
|
|
@@ -285,6 +332,9 @@ export type AdminCallableResponse = {
|
|
|
285
332
|
} | {
|
|
286
333
|
action: "detachFromParent";
|
|
287
334
|
result: AdminDetachFromParentResult;
|
|
335
|
+
} | {
|
|
336
|
+
action: "deleteAccount";
|
|
337
|
+
result: AdminDeleteAccountResult;
|
|
288
338
|
} | {
|
|
289
339
|
action: "searchAccounts";
|
|
290
340
|
result: AdminSearchAccountsResult;
|
|
@@ -306,6 +356,12 @@ export type AdminCallableResponse = {
|
|
|
306
356
|
} | {
|
|
307
357
|
action: "bulkLinkAccountIntegration";
|
|
308
358
|
result: AdminBulkLinkAccountIntegrationResult;
|
|
359
|
+
} | {
|
|
360
|
+
action: "listHibernationCandidates";
|
|
361
|
+
result: AdminListHibernationCandidatesResult;
|
|
362
|
+
} | {
|
|
363
|
+
action: "hibernateProjects";
|
|
364
|
+
result: AdminHibernateProjectsResult;
|
|
309
365
|
};
|
|
310
366
|
export type CreateBillingPortalSessionRequest = {
|
|
311
367
|
returnUrl: string;
|