@palbase/backend 10.3.0 → 12.0.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/chunk-7LAXRLPG.js +418 -0
- package/dist/chunk-7LAXRLPG.js.map +1 -0
- package/dist/{chunk-4WOQWFUP.js → chunk-LUV36KQU.js} +26 -11
- package/dist/{chunk-4WOQWFUP.js.map → chunk-LUV36KQU.js.map} +1 -1
- package/dist/{chunk-2PCNZBNZ.js → chunk-XATG7BRC.js} +20 -2
- package/dist/chunk-XATG7BRC.js.map +1 -0
- package/dist/db/index.cjs +438 -10
- package/dist/db/index.cjs.map +1 -1
- package/dist/db/index.d.cts +2 -2
- package/dist/db/index.d.ts +2 -2
- package/dist/db/index.js +13 -1
- package/dist/{endpoint-92kVepng.d.cts → endpoint-Ck4hER_7.d.cts} +343 -11
- package/dist/{endpoint-92kVepng.d.ts → endpoint-Ck4hER_7.d.ts} +343 -11
- package/dist/{index-BaHs33jr.d.cts → index-BJAf1uPC.d.cts} +64 -34
- package/dist/{index-DfryIw9U.d.ts → index-l7DhBDtn.d.ts} +64 -34
- package/dist/index.cjs +589 -124
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +60 -162
- package/dist/index.d.ts +60 -162
- package/dist/index.js +139 -108
- package/dist/index.js.map +1 -1
- package/dist/test/index.cjs +545 -12
- package/dist/test/index.cjs.map +1 -1
- package/dist/test/index.d.cts +1 -1
- package/dist/test/index.d.ts +1 -1
- package/dist/test/index.js +153 -12
- package/dist/test/index.js.map +1 -1
- package/docs/background.md +8 -9
- package/docs/database.md +106 -16
- package/docs/events.md +20 -17
- package/docs/llms-full.txt +141 -47
- package/docs/schema.md +6 -4
- package/package.json +1 -1
- package/dist/chunk-2PCNZBNZ.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { C as CacheClient, b as PalbaseDocsClient, c as PalbaseFlagsClient, L as Logger, d as PalbaseNotificationsClient, Q as QueueClient, e as PalbaseRealtimeClient, D as DBClient, f as PalbaseStorageClient, A as AuthSpec, R as RateLimitConfig, H as HttpError, U as User$1 } from './endpoint-
|
|
2
|
-
export { g as AuthConfig, B as BadRequest, h as ClientInfo, i as Conflict, j as DBOps, E as ErrorDef, k as ErrorMap, l as ErrorThrowers, F as FileContext, m as Forbidden, n as HttpMethod, M as
|
|
1
|
+
import { C as CacheClient, b as PalbaseDocsClient, c as PalbaseFlagsClient, L as Logger, d as PalbaseNotificationsClient, Q as QueueClient, e as PalbaseRealtimeClient, D as DBClient, f as PalbaseStorageClient, A as AuthSpec, R as RateLimitConfig, H as HttpError, U as User$1 } from './endpoint-Ck4hER_7.cjs';
|
|
2
|
+
export { g as AuthConfig, B as BadRequest, h as ClientInfo, i as Conflict, j as DBOps, E as ErrorDef, k as ErrorMap, l as ErrorThrowers, F as FileContext, m as Forbidden, n as HttpMethod, M as Materialized, o as Middleware, p as MiddlewareContext, q as MiddlewareHandler, N as NotFound, P as PBRequest, r as PalError, s as PalbaseAnalyticsClient, t as PalbaseAnalyticsManagementNamespace, u as PalbaseAnalyticsProperties, v as PalbaseAnalyticsQueryNamespace, w as PalbaseAttestAndroidParams, x as PalbaseAttestAndroidResult, y as PalbaseAttestiOSParams, z as PalbaseAttestiOSResult, G as PalbaseAuthClient, I as PalbaseBatchOverrideOperation, J as PalbaseBatchSetOverridesResult, K as PalbaseBindDeviceParams, O as PalbaseBucketClient, S as PalbaseClearAllOverridesResult, T as PalbaseClearOverrideResult, V as PalbaseCohortQueryInput, W as PalbaseCohortResult, X as PalbaseCollectionRef, Y as PalbaseCountQueryInput, Z as PalbaseCountResult, _ as PalbaseCreateLinkParams, $ as PalbaseDeviceInfo, a0 as PalbaseDeviceTokenView, a1 as PalbaseDocumentRef, a2 as PalbaseDocumentSnapshot, a3 as PalbaseEmailClient, a4 as PalbaseEmailSendParams, a5 as PalbaseEmailSendResponse, a6 as PalbaseEventNamesResult, a7 as PalbaseEventsQueryInput, a8 as PalbaseEventsResult, a9 as PalbaseFileObject, aa as PalbaseFlag, ab as PalbaseFlagContext, ac as PalbaseFlagSource, ad as PalbaseFlagValue, ae as PalbaseFlagVariant, af as PalbaseFlagsServiceClient, ag as PalbaseFunctionsClient, ah as PalbaseFunnelQueryInput, ai as PalbaseFunnelResult, aj as PalbaseIdentifyTraits, ak as PalbaseInboxClient, al as PalbaseInboxListOptions, am as PalbaseInboxListResult, an as PalbaseInboxMessage, ao as PalbaseInboxSendParams, ap as PalbaseInboxSendResponse, aq as PalbaseInitialLink, ar as PalbaseInvokeOptions, as as PalbaseLink, at as PalbaseLinkAnalytics, au as PalbaseLinkDetails, av as PalbaseLinksClient, aw as PalbaseListLinksOptions, ax as PalbaseListLinksResult, ay as PalbaseListOptions, az as PalbaseMatchParams, aA as PalbaseMultiChannelResponse, aB as PalbaseOverviewResult, aC as PalbasePreferences, aD as PalbasePreferencesClient, aE as PalbasePublicUrlResponse, aF as PalbasePushClient, aG as PalbasePushSendParams, aH as PalbasePushSendResponse, aI as PalbaseQrCodeOptions, aJ as PalbaseQuerySnapshot, aK as PalbaseRegisterDeviceParams, aL as PalbaseResult, aM as PalbaseRetentionQueryInput, aN as PalbaseRetentionResult, aO as PalbaseSession, aP as PalbaseSetOverrideResult, aQ as PalbaseSetOverridesResult, aR as PalbaseSignedUrlResponse, aS as PalbaseSmsClient, aT as PalbaseSmsSendParams, aU as PalbaseSmsSendResponse, aV as PalbaseTransformOptions, aW as PalbaseUpdateLinkParams, aX as PalbaseUploadOptions, aY as PalbaseUser, aZ as PalbaseUserDetailResult, a_ as PalbaseUsersQueryInput, a$ as PalbaseUsersResult, b0 as PalbaseVerifyRequestSignatureParams, b1 as PalbaseWhereOperator, b2 as Ref, b3 as TooManyRequests, b4 as TxColumnExpr, b5 as TxInsertShape, b6 as TxInsertValue, b7 as TxNow, b8 as TxPlanBody, b9 as TxPlanError, ba as TxPlanHandle, bb as TxPlanOpResult, bc as TxPlanRejection, bd as TxPlanResponse, be as TxRefError, bf as TxRow, bg as TxRows, bh as TxSelectOptions, bi as TxSetShape, bj as TxSetValue, bk as TxTable, bl as TxWhere, bm as TxWireExpr, bn as TxWireGuard, bo as TxWireOp, bp as TxWireRef, bq as TxWireValue, br as Unauthorized, bs as VerifiedDevice, bt as dec, bu as defineMiddleware, bv as inc, bw as now } from './endpoint-Ck4hER_7.cjs';
|
|
3
3
|
import { AsyncLocalStorage } from 'node:async_hooks';
|
|
4
|
-
import { E as EnvTypedDatabase, S as SchemaDef } from './index-
|
|
5
|
-
export { C as ColumnBuilder, a as ColumnDef, b as ColumnMap, c as ColumnType, d as EXTENSION_DEPENDENCIES, e as EnvServiceDatabase, f as EnvTables, g as EnvTypedTable,
|
|
4
|
+
import { E as EnvTypedDatabase, S as SchemaDef } from './index-BJAf1uPC.cjs';
|
|
5
|
+
export { C as ColumnBuilder, a as ColumnDef, b as ColumnMap, c as ColumnType, d as EXTENSION_DEPENDENCIES, e as EnvServiceDatabase, f as EnvTables, g as EnvTypedTable, I as InsertShape, O as OnDeleteAction, P as PALBASE_EXTENSIONS, h as PalbaseExtension, i as PolicyBuilder, j as PolicyCommand, k as PolicyDef, l as PolicyMode, R as RawConstraintDef, m as RowShape, n as SchemaInput, T as TableDef, o as TableInput, p as TxPlan, q as TxTables, r as TypedDB, s as TypedTable, t as TypedTx, u as bigint, v as boolean, w as defineSchema, x as enumType, y as integer, z as isPalbaseExtension, A as jsonb, B as makeTypedDB, D as numeric, F as policy, G as raw, H as text, J as timestamp, K as uuid } from './index-BJAf1uPC.cjs';
|
|
6
6
|
import { EntitlementKey, LimitKey } from './purchases/keys.cjs';
|
|
7
7
|
import { TableTypes, Tables } from './db/env.cjs';
|
|
8
8
|
import { ZodTypeAny, z } from 'zod';
|
|
@@ -1459,43 +1459,6 @@ interface JobMeta {
|
|
|
1459
1459
|
/** The globally unique Environment runtime identifier. */
|
|
1460
1460
|
environmentId: string;
|
|
1461
1461
|
}
|
|
1462
|
-
/** Configuration for defining a scheduled job. */
|
|
1463
|
-
interface JobConfig {
|
|
1464
|
-
/** Unique job name — alphanumeric, underscore, hyphen only. */
|
|
1465
|
-
name: string;
|
|
1466
|
-
/** Cron expression (e.g., "0 3 * * *"). */
|
|
1467
|
-
schedule: string;
|
|
1468
|
-
/** Execution timeout in seconds. Defaults to 30. */
|
|
1469
|
-
timeout?: number;
|
|
1470
|
-
/** Job handler function. */
|
|
1471
|
-
handler: (meta: JobMeta) => Promise<void>;
|
|
1472
|
-
}
|
|
1473
|
-
/** Resolved job configuration with defaults applied. */
|
|
1474
|
-
interface ResolvedJobConfig {
|
|
1475
|
-
name: string;
|
|
1476
|
-
schedule: string;
|
|
1477
|
-
timeout: number;
|
|
1478
|
-
handler: (meta: JobMeta) => Promise<void>;
|
|
1479
|
-
}
|
|
1480
|
-
/**
|
|
1481
|
-
* Define a scheduled cron job.
|
|
1482
|
-
*
|
|
1483
|
-
* Jobs are placed in the `jobs/` directory and auto-discovered at deploy time.
|
|
1484
|
-
*
|
|
1485
|
-
* @example
|
|
1486
|
-
* ```ts
|
|
1487
|
-
* export default defineJob({
|
|
1488
|
-
* name: "cleanup-expired",
|
|
1489
|
-
* schedule: "0 3 * * *", // every day at 3 AM
|
|
1490
|
-
* timeout: 60,
|
|
1491
|
-
* handler: async (meta) => {
|
|
1492
|
-
* await Database.delete("sessions", "expired < NOW()");
|
|
1493
|
-
* Log.info("Cleaned up expired sessions");
|
|
1494
|
-
* },
|
|
1495
|
-
* });
|
|
1496
|
-
* ```
|
|
1497
|
-
*/
|
|
1498
|
-
declare function defineJob(config: JobConfig): ResolvedJobConfig;
|
|
1499
1462
|
|
|
1500
1463
|
/** Supported webhook provider types. */
|
|
1501
1464
|
type WebhookProvider = "stripe" | "github" | "twilio" | "sendgrid" | "slack" | "discord" | "livekit";
|
|
@@ -1509,135 +1472,70 @@ interface WebhookMeta {
|
|
|
1509
1472
|
/** The globally unique Environment runtime identifier. */
|
|
1510
1473
|
environmentId: string;
|
|
1511
1474
|
}
|
|
1512
|
-
/**
|
|
1513
|
-
interface EnvSecretRef {
|
|
1514
|
-
env: string;
|
|
1515
|
-
}
|
|
1516
|
-
/** Provider-specific event maps for type-safe event handlers. */
|
|
1517
|
-
interface ProviderEventMap {
|
|
1518
|
-
stripe: {
|
|
1519
|
-
"checkout.session.completed": Record<string, unknown>;
|
|
1520
|
-
"payment_intent.succeeded": Record<string, unknown>;
|
|
1521
|
-
"payment_intent.payment_failed": Record<string, unknown>;
|
|
1522
|
-
"customer.subscription.created": Record<string, unknown>;
|
|
1523
|
-
"customer.subscription.updated": Record<string, unknown>;
|
|
1524
|
-
"customer.subscription.deleted": Record<string, unknown>;
|
|
1525
|
-
"invoice.paid": Record<string, unknown>;
|
|
1526
|
-
"invoice.payment_failed": Record<string, unknown>;
|
|
1527
|
-
[key: string]: Record<string, unknown>;
|
|
1528
|
-
};
|
|
1529
|
-
github: {
|
|
1530
|
-
push: Record<string, unknown>;
|
|
1531
|
-
pull_request: Record<string, unknown>;
|
|
1532
|
-
issues: Record<string, unknown>;
|
|
1533
|
-
"pull_request.opened": Record<string, unknown>;
|
|
1534
|
-
"pull_request.closed": Record<string, unknown>;
|
|
1535
|
-
"pull_request.merged": Record<string, unknown>;
|
|
1536
|
-
[key: string]: Record<string, unknown>;
|
|
1537
|
-
};
|
|
1538
|
-
twilio: {
|
|
1539
|
-
"message.received": Record<string, unknown>;
|
|
1540
|
-
"message.sent": Record<string, unknown>;
|
|
1541
|
-
"call.completed": Record<string, unknown>;
|
|
1542
|
-
[key: string]: Record<string, unknown>;
|
|
1543
|
-
};
|
|
1544
|
-
sendgrid: {
|
|
1545
|
-
delivered: Record<string, unknown>;
|
|
1546
|
-
bounce: Record<string, unknown>;
|
|
1547
|
-
open: Record<string, unknown>;
|
|
1548
|
-
click: Record<string, unknown>;
|
|
1549
|
-
[key: string]: Record<string, unknown>;
|
|
1550
|
-
};
|
|
1551
|
-
slack: {
|
|
1552
|
-
url_verification: Record<string, unknown>;
|
|
1553
|
-
event_callback: Record<string, unknown>;
|
|
1554
|
-
[key: string]: Record<string, unknown>;
|
|
1555
|
-
};
|
|
1556
|
-
discord: {
|
|
1557
|
-
PING: Record<string, unknown>;
|
|
1558
|
-
MESSAGE_CREATE: Record<string, unknown>;
|
|
1559
|
-
INTERACTION_CREATE: Record<string, unknown>;
|
|
1560
|
-
[key: string]: Record<string, unknown>;
|
|
1561
|
-
};
|
|
1562
|
-
livekit: {
|
|
1563
|
-
"room.started": Record<string, unknown>;
|
|
1564
|
-
"room.finished": Record<string, unknown>;
|
|
1565
|
-
"participant.joined": Record<string, unknown>;
|
|
1566
|
-
"participant.left": Record<string, unknown>;
|
|
1567
|
-
[key: string]: Record<string, unknown>;
|
|
1568
|
-
};
|
|
1569
|
-
}
|
|
1570
|
-
/** Event handler function type. */
|
|
1571
|
-
type WebhookEventHandler<TEvent = Record<string, unknown>> = (event: TEvent, meta: WebhookMeta) => Promise<void>;
|
|
1572
|
-
/** Provider-based webhook configuration. */
|
|
1573
|
-
interface ProviderWebhookConfig<P extends WebhookProvider = WebhookProvider> {
|
|
1574
|
-
provider: P;
|
|
1575
|
-
secret: EnvSecretRef;
|
|
1576
|
-
events: {
|
|
1577
|
-
[K in keyof ProviderEventMap[P]]?: WebhookEventHandler<ProviderEventMap[P][K]>;
|
|
1578
|
-
};
|
|
1579
|
-
}
|
|
1580
|
-
/** Incoming request representation for custom verify functions. */
|
|
1475
|
+
/** Raw incoming request representation, read by signature verification. */
|
|
1581
1476
|
interface WebhookRequest {
|
|
1582
1477
|
headers: Record<string, string>;
|
|
1583
1478
|
body: string;
|
|
1584
1479
|
method: string;
|
|
1585
1480
|
url: string;
|
|
1586
1481
|
}
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
/**
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1482
|
+
|
|
1483
|
+
/** A signature scheme spelled out, for a service with no preset. The presets
|
|
1484
|
+
* (`provider`) are named configurations of this same shape. */
|
|
1485
|
+
interface SignatureSpec {
|
|
1486
|
+
/** Header carrying the signature. */
|
|
1487
|
+
header: string;
|
|
1488
|
+
/** Stripped before comparison (e.g. `sha256=`). Omit when absent. */
|
|
1489
|
+
prefix?: string;
|
|
1490
|
+
algo: "hmac-sha256" | "hmac-sha1";
|
|
1491
|
+
encoding: "hex" | "base64";
|
|
1492
|
+
/** What the HMAC covers. Exactly two placeholders: `{body}` and `{ts}`.
|
|
1493
|
+
* Everything else is literal. `{ts}` requires `timestampHeader` and brings
|
|
1494
|
+
* the five-minute replay window with it. */
|
|
1495
|
+
signs: string;
|
|
1496
|
+
timestampHeader?: string;
|
|
1497
|
+
}
|
|
1498
|
+
interface WebhookOptions {
|
|
1499
|
+
provider?: WebhookProvider;
|
|
1500
|
+
signature?: SignatureSpec;
|
|
1501
|
+
/** Env-var REFERENCE for the signing secret — the platform never holds it. */
|
|
1502
|
+
secret: {
|
|
1503
|
+
env: string;
|
|
1504
|
+
};
|
|
1505
|
+
}
|
|
1506
|
+
type WebhookEventHandler = (event: unknown, meta: WebhookMeta) => Promise<void>;
|
|
1507
|
+
interface ResolvedWebhook {
|
|
1508
|
+
provider?: WebhookProvider;
|
|
1509
|
+
signature?: SignatureSpec;
|
|
1510
|
+
secret: {
|
|
1511
|
+
env: string;
|
|
1512
|
+
};
|
|
1598
1513
|
events: Record<string, WebhookEventHandler>;
|
|
1599
1514
|
}
|
|
1600
|
-
/**
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1515
|
+
/** Mark a class as an inbound webhook. The mount name is the FILE name — there
|
|
1516
|
+
* is deliberately no `name` option, because the file name IS the public URL. */
|
|
1517
|
+
declare function Webhook(options: WebhookOptions): <T extends abstract new (...args: never[]) => object>(ctor: T) => T;
|
|
1518
|
+
/** Bind a method to one event name. Any string is valid: presets provide
|
|
1519
|
+
* autocomplete, never a constraint, because we do not carry provider catalogs. */
|
|
1520
|
+
declare function On(event: string): (target: object, fnName: string | symbol) => void;
|
|
1521
|
+
/** Read a decorated class back as the resolved config the runtime consumes.
|
|
1522
|
+
* Every misuse throws HERE, at build time, rather than becoming a webhook that
|
|
1523
|
+
* answers 200 and does nothing. */
|
|
1524
|
+
declare function getWebhookConfig(ctor: object): ResolvedWebhook;
|
|
1525
|
+
|
|
1526
|
+
interface JobOptions {
|
|
1527
|
+
/** Cron expression, five fields (e.g. "0 3 * * *"). */
|
|
1528
|
+
schedule: string;
|
|
1529
|
+
/** Execution timeout in seconds. Defaults to 30, ceiling 300 (sandbox limit). */
|
|
1530
|
+
timeout?: number;
|
|
1606
1531
|
}
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
* export default defineWebhook({
|
|
1615
|
-
* provider: "stripe",
|
|
1616
|
-
* secret: { env: "STRIPE_WEBHOOK_SECRET" },
|
|
1617
|
-
* events: {
|
|
1618
|
-
* "checkout.session.completed": async (event, meta) => {
|
|
1619
|
-
* await Database.insert("orders", { status: "paid" });
|
|
1620
|
-
* },
|
|
1621
|
-
* },
|
|
1622
|
-
* });
|
|
1623
|
-
* ```
|
|
1624
|
-
*/
|
|
1625
|
-
declare function defineWebhook<P extends WebhookProvider>(config: ProviderWebhookConfig<P>): ResolvedProviderWebhook<P>;
|
|
1626
|
-
/**
|
|
1627
|
-
* Define a custom webhook with optional verification.
|
|
1628
|
-
*
|
|
1629
|
-
* @example
|
|
1630
|
-
* ```ts
|
|
1631
|
-
* export default defineWebhook({
|
|
1632
|
-
* path: "/webhooks/livekit",
|
|
1633
|
-
* verify: async (req) => req.headers["x-api-key"] === "secret",
|
|
1634
|
-
* handler: async (payload, meta) => {
|
|
1635
|
-
* Log.info("Received webhook", payload);
|
|
1636
|
-
* },
|
|
1637
|
-
* });
|
|
1638
|
-
* ```
|
|
1639
|
-
*/
|
|
1640
|
-
declare function defineWebhook(config: CustomWebhookConfig): ResolvedCustomWebhook;
|
|
1532
|
+
interface ResolvedJob {
|
|
1533
|
+
schedule: string;
|
|
1534
|
+
timeout: number;
|
|
1535
|
+
handler: (meta: JobMeta) => Promise<void>;
|
|
1536
|
+
}
|
|
1537
|
+
declare function Job(options: JobOptions): <T extends abstract new (...args: never[]) => object>(ctor: T) => T;
|
|
1538
|
+
declare function getJobConfig(ctor: object): ResolvedJob;
|
|
1641
1539
|
|
|
1642
1540
|
/**
|
|
1643
1541
|
* resource.ts — external connections as lifecycle-managed classes.
|
|
@@ -1848,4 +1746,4 @@ declare const documents: {
|
|
|
1848
1746
|
onDocumentDeleted(handler: HookHandler<DocumentDeletedEvent>): ResolvedHook<DocumentDeletedEvent>;
|
|
1849
1747
|
};
|
|
1850
1748
|
|
|
1851
|
-
export { type AcsOptions, type ApnsOptions, type BackoffStrategy, Body, type BucketDef, type BucketOptions, Cache, CacheClient, Client, Controller, type ControllerOptions,
|
|
1749
|
+
export { type AcsOptions, type ApnsOptions, type BackoffStrategy, Body, type BucketDef, type BucketOptions, Cache, CacheClient, Client, Controller, type ControllerOptions, DBClient, Database, type DefinedError, type DefinedErrorWithData, Delete, type DocumentCreatedEvent, type DocumentDeletedEvent, type DocumentUpdatedEvent, Documents, EGRESS_CONFIG_KIND, type EgressConfig, type EgressInput, EntitlementKey, EnvTypedDatabase, FLAGS_CONFIG_KIND, type FcmOptions, type FileDeletedEvent, type FileUploadedEvent, type FlagDef, type FlagJsonObject, type FlagJsonValue, type FlagOptions, type FlagType, type FlagValue, Flags, type FlagsConfig, type FlagsInput, Get, Headers, type HookHandler, type HookMeta, HttpError, type HttpMethodUpper, Job, type JobMeta, type JobOptions, LimitKey, type LimitState, Log, Logger, NOTIFICATIONS_CONFIG_KIND, Notifications, type NotificationsConfig, type NotificationsInput, On, OptionalUser, type OwnedTablesOf, PROVIDER_CATALOG, PalbaseDocsClient, PalbaseFlagsClient, PalbaseNotificationsClient, PalbaseRealtimeClient, PalbaseStorageClient, Param, type ParamKind, type ParamMeta, type PasswordResetEvent, Patch, Post, type ProviderCatalogEntry, type ProviderDef, type ProviderName, type ProviderOptions, Purchases, type PurchasesManifest, type PurchasesService, Put, Query, QueryParams, Queue, QueueClient, RESERVED_SECRET_PREFIX, RateLimitConfig, Realtime, type RegisteredError, Req, RequestId, type RequestStore, RequireEntitlement, type ResolvedHook, type ResolvedJob, type ResolvedWebhook, type ResolvedWorkerConfig, Resource, type ResourceEnv, type RouteMeta, type RouteOptions, type RuntimeServices, STORAGE_CONFIG_KIND, SchemaDef, type Seed, type SeedFor, type SeedJson, type SeedRowFor, type SendgridOptions, type SesOptions, type SignInEvent, type SignOutEvent, type SignatureSpec, type SmtpOptions, Spend, type SpendMeta, type SpendOptions, Storage, type StorageConfig, type StorageInput, type StoreEnv, TEST_USERS_CONFIG_KIND, type TableGraph, TableTypes, Tables, type TestUserDef, type TestUserOptions, type TestUsersConfig, type TestUsersInput, type ThrowDescriptor, TraceId, type TwilioOptions, Upload, type UploadConfig, UploadedObject, User, type UserCreatedEvent, User$1 as UserT, Webhook, type WebhookEventHandler, type WebhookMeta, type WebhookOptions, type WebhookProvider, type WebhookRequest, type WorkerConfig, type WorkerMeta, __getRuntime, __registerResource, __requestALS, __runResourceBoot, __runWithRuntime, __setRuntime, __shutdownResources, auth, bucket, buildProvider, defineEgress, defineError, defineFlags, defineNotifications, defineStorage, defineTestUsers, defineWorker, documents, entitlementFor, flag, getErrorRegistry, getJobConfig, getRoutes, getWebhookConfig, makeEnvDts, makePurchasesDts, parseFileSizeLimit, recordThrows, reservedSecretKey, spendFor, storage, testUser, validateUploadAgainstStorage };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { C as CacheClient, b as PalbaseDocsClient, c as PalbaseFlagsClient, L as Logger, d as PalbaseNotificationsClient, Q as QueueClient, e as PalbaseRealtimeClient, D as DBClient, f as PalbaseStorageClient, A as AuthSpec, R as RateLimitConfig, H as HttpError, U as User$1 } from './endpoint-
|
|
2
|
-
export { g as AuthConfig, B as BadRequest, h as ClientInfo, i as Conflict, j as DBOps, E as ErrorDef, k as ErrorMap, l as ErrorThrowers, F as FileContext, m as Forbidden, n as HttpMethod, M as
|
|
1
|
+
import { C as CacheClient, b as PalbaseDocsClient, c as PalbaseFlagsClient, L as Logger, d as PalbaseNotificationsClient, Q as QueueClient, e as PalbaseRealtimeClient, D as DBClient, f as PalbaseStorageClient, A as AuthSpec, R as RateLimitConfig, H as HttpError, U as User$1 } from './endpoint-Ck4hER_7.js';
|
|
2
|
+
export { g as AuthConfig, B as BadRequest, h as ClientInfo, i as Conflict, j as DBOps, E as ErrorDef, k as ErrorMap, l as ErrorThrowers, F as FileContext, m as Forbidden, n as HttpMethod, M as Materialized, o as Middleware, p as MiddlewareContext, q as MiddlewareHandler, N as NotFound, P as PBRequest, r as PalError, s as PalbaseAnalyticsClient, t as PalbaseAnalyticsManagementNamespace, u as PalbaseAnalyticsProperties, v as PalbaseAnalyticsQueryNamespace, w as PalbaseAttestAndroidParams, x as PalbaseAttestAndroidResult, y as PalbaseAttestiOSParams, z as PalbaseAttestiOSResult, G as PalbaseAuthClient, I as PalbaseBatchOverrideOperation, J as PalbaseBatchSetOverridesResult, K as PalbaseBindDeviceParams, O as PalbaseBucketClient, S as PalbaseClearAllOverridesResult, T as PalbaseClearOverrideResult, V as PalbaseCohortQueryInput, W as PalbaseCohortResult, X as PalbaseCollectionRef, Y as PalbaseCountQueryInput, Z as PalbaseCountResult, _ as PalbaseCreateLinkParams, $ as PalbaseDeviceInfo, a0 as PalbaseDeviceTokenView, a1 as PalbaseDocumentRef, a2 as PalbaseDocumentSnapshot, a3 as PalbaseEmailClient, a4 as PalbaseEmailSendParams, a5 as PalbaseEmailSendResponse, a6 as PalbaseEventNamesResult, a7 as PalbaseEventsQueryInput, a8 as PalbaseEventsResult, a9 as PalbaseFileObject, aa as PalbaseFlag, ab as PalbaseFlagContext, ac as PalbaseFlagSource, ad as PalbaseFlagValue, ae as PalbaseFlagVariant, af as PalbaseFlagsServiceClient, ag as PalbaseFunctionsClient, ah as PalbaseFunnelQueryInput, ai as PalbaseFunnelResult, aj as PalbaseIdentifyTraits, ak as PalbaseInboxClient, al as PalbaseInboxListOptions, am as PalbaseInboxListResult, an as PalbaseInboxMessage, ao as PalbaseInboxSendParams, ap as PalbaseInboxSendResponse, aq as PalbaseInitialLink, ar as PalbaseInvokeOptions, as as PalbaseLink, at as PalbaseLinkAnalytics, au as PalbaseLinkDetails, av as PalbaseLinksClient, aw as PalbaseListLinksOptions, ax as PalbaseListLinksResult, ay as PalbaseListOptions, az as PalbaseMatchParams, aA as PalbaseMultiChannelResponse, aB as PalbaseOverviewResult, aC as PalbasePreferences, aD as PalbasePreferencesClient, aE as PalbasePublicUrlResponse, aF as PalbasePushClient, aG as PalbasePushSendParams, aH as PalbasePushSendResponse, aI as PalbaseQrCodeOptions, aJ as PalbaseQuerySnapshot, aK as PalbaseRegisterDeviceParams, aL as PalbaseResult, aM as PalbaseRetentionQueryInput, aN as PalbaseRetentionResult, aO as PalbaseSession, aP as PalbaseSetOverrideResult, aQ as PalbaseSetOverridesResult, aR as PalbaseSignedUrlResponse, aS as PalbaseSmsClient, aT as PalbaseSmsSendParams, aU as PalbaseSmsSendResponse, aV as PalbaseTransformOptions, aW as PalbaseUpdateLinkParams, aX as PalbaseUploadOptions, aY as PalbaseUser, aZ as PalbaseUserDetailResult, a_ as PalbaseUsersQueryInput, a$ as PalbaseUsersResult, b0 as PalbaseVerifyRequestSignatureParams, b1 as PalbaseWhereOperator, b2 as Ref, b3 as TooManyRequests, b4 as TxColumnExpr, b5 as TxInsertShape, b6 as TxInsertValue, b7 as TxNow, b8 as TxPlanBody, b9 as TxPlanError, ba as TxPlanHandle, bb as TxPlanOpResult, bc as TxPlanRejection, bd as TxPlanResponse, be as TxRefError, bf as TxRow, bg as TxRows, bh as TxSelectOptions, bi as TxSetShape, bj as TxSetValue, bk as TxTable, bl as TxWhere, bm as TxWireExpr, bn as TxWireGuard, bo as TxWireOp, bp as TxWireRef, bq as TxWireValue, br as Unauthorized, bs as VerifiedDevice, bt as dec, bu as defineMiddleware, bv as inc, bw as now } from './endpoint-Ck4hER_7.js';
|
|
3
3
|
import { AsyncLocalStorage } from 'node:async_hooks';
|
|
4
|
-
import { E as EnvTypedDatabase, S as SchemaDef } from './index-
|
|
5
|
-
export { C as ColumnBuilder, a as ColumnDef, b as ColumnMap, c as ColumnType, d as EXTENSION_DEPENDENCIES, e as EnvServiceDatabase, f as EnvTables, g as EnvTypedTable,
|
|
4
|
+
import { E as EnvTypedDatabase, S as SchemaDef } from './index-l7DhBDtn.js';
|
|
5
|
+
export { C as ColumnBuilder, a as ColumnDef, b as ColumnMap, c as ColumnType, d as EXTENSION_DEPENDENCIES, e as EnvServiceDatabase, f as EnvTables, g as EnvTypedTable, I as InsertShape, O as OnDeleteAction, P as PALBASE_EXTENSIONS, h as PalbaseExtension, i as PolicyBuilder, j as PolicyCommand, k as PolicyDef, l as PolicyMode, R as RawConstraintDef, m as RowShape, n as SchemaInput, T as TableDef, o as TableInput, p as TxPlan, q as TxTables, r as TypedDB, s as TypedTable, t as TypedTx, u as bigint, v as boolean, w as defineSchema, x as enumType, y as integer, z as isPalbaseExtension, A as jsonb, B as makeTypedDB, D as numeric, F as policy, G as raw, H as text, J as timestamp, K as uuid } from './index-l7DhBDtn.js';
|
|
6
6
|
import { EntitlementKey, LimitKey } from './purchases/keys.js';
|
|
7
7
|
import { TableTypes, Tables } from './db/env.js';
|
|
8
8
|
import { ZodTypeAny, z } from 'zod';
|
|
@@ -1459,43 +1459,6 @@ interface JobMeta {
|
|
|
1459
1459
|
/** The globally unique Environment runtime identifier. */
|
|
1460
1460
|
environmentId: string;
|
|
1461
1461
|
}
|
|
1462
|
-
/** Configuration for defining a scheduled job. */
|
|
1463
|
-
interface JobConfig {
|
|
1464
|
-
/** Unique job name — alphanumeric, underscore, hyphen only. */
|
|
1465
|
-
name: string;
|
|
1466
|
-
/** Cron expression (e.g., "0 3 * * *"). */
|
|
1467
|
-
schedule: string;
|
|
1468
|
-
/** Execution timeout in seconds. Defaults to 30. */
|
|
1469
|
-
timeout?: number;
|
|
1470
|
-
/** Job handler function. */
|
|
1471
|
-
handler: (meta: JobMeta) => Promise<void>;
|
|
1472
|
-
}
|
|
1473
|
-
/** Resolved job configuration with defaults applied. */
|
|
1474
|
-
interface ResolvedJobConfig {
|
|
1475
|
-
name: string;
|
|
1476
|
-
schedule: string;
|
|
1477
|
-
timeout: number;
|
|
1478
|
-
handler: (meta: JobMeta) => Promise<void>;
|
|
1479
|
-
}
|
|
1480
|
-
/**
|
|
1481
|
-
* Define a scheduled cron job.
|
|
1482
|
-
*
|
|
1483
|
-
* Jobs are placed in the `jobs/` directory and auto-discovered at deploy time.
|
|
1484
|
-
*
|
|
1485
|
-
* @example
|
|
1486
|
-
* ```ts
|
|
1487
|
-
* export default defineJob({
|
|
1488
|
-
* name: "cleanup-expired",
|
|
1489
|
-
* schedule: "0 3 * * *", // every day at 3 AM
|
|
1490
|
-
* timeout: 60,
|
|
1491
|
-
* handler: async (meta) => {
|
|
1492
|
-
* await Database.delete("sessions", "expired < NOW()");
|
|
1493
|
-
* Log.info("Cleaned up expired sessions");
|
|
1494
|
-
* },
|
|
1495
|
-
* });
|
|
1496
|
-
* ```
|
|
1497
|
-
*/
|
|
1498
|
-
declare function defineJob(config: JobConfig): ResolvedJobConfig;
|
|
1499
1462
|
|
|
1500
1463
|
/** Supported webhook provider types. */
|
|
1501
1464
|
type WebhookProvider = "stripe" | "github" | "twilio" | "sendgrid" | "slack" | "discord" | "livekit";
|
|
@@ -1509,135 +1472,70 @@ interface WebhookMeta {
|
|
|
1509
1472
|
/** The globally unique Environment runtime identifier. */
|
|
1510
1473
|
environmentId: string;
|
|
1511
1474
|
}
|
|
1512
|
-
/**
|
|
1513
|
-
interface EnvSecretRef {
|
|
1514
|
-
env: string;
|
|
1515
|
-
}
|
|
1516
|
-
/** Provider-specific event maps for type-safe event handlers. */
|
|
1517
|
-
interface ProviderEventMap {
|
|
1518
|
-
stripe: {
|
|
1519
|
-
"checkout.session.completed": Record<string, unknown>;
|
|
1520
|
-
"payment_intent.succeeded": Record<string, unknown>;
|
|
1521
|
-
"payment_intent.payment_failed": Record<string, unknown>;
|
|
1522
|
-
"customer.subscription.created": Record<string, unknown>;
|
|
1523
|
-
"customer.subscription.updated": Record<string, unknown>;
|
|
1524
|
-
"customer.subscription.deleted": Record<string, unknown>;
|
|
1525
|
-
"invoice.paid": Record<string, unknown>;
|
|
1526
|
-
"invoice.payment_failed": Record<string, unknown>;
|
|
1527
|
-
[key: string]: Record<string, unknown>;
|
|
1528
|
-
};
|
|
1529
|
-
github: {
|
|
1530
|
-
push: Record<string, unknown>;
|
|
1531
|
-
pull_request: Record<string, unknown>;
|
|
1532
|
-
issues: Record<string, unknown>;
|
|
1533
|
-
"pull_request.opened": Record<string, unknown>;
|
|
1534
|
-
"pull_request.closed": Record<string, unknown>;
|
|
1535
|
-
"pull_request.merged": Record<string, unknown>;
|
|
1536
|
-
[key: string]: Record<string, unknown>;
|
|
1537
|
-
};
|
|
1538
|
-
twilio: {
|
|
1539
|
-
"message.received": Record<string, unknown>;
|
|
1540
|
-
"message.sent": Record<string, unknown>;
|
|
1541
|
-
"call.completed": Record<string, unknown>;
|
|
1542
|
-
[key: string]: Record<string, unknown>;
|
|
1543
|
-
};
|
|
1544
|
-
sendgrid: {
|
|
1545
|
-
delivered: Record<string, unknown>;
|
|
1546
|
-
bounce: Record<string, unknown>;
|
|
1547
|
-
open: Record<string, unknown>;
|
|
1548
|
-
click: Record<string, unknown>;
|
|
1549
|
-
[key: string]: Record<string, unknown>;
|
|
1550
|
-
};
|
|
1551
|
-
slack: {
|
|
1552
|
-
url_verification: Record<string, unknown>;
|
|
1553
|
-
event_callback: Record<string, unknown>;
|
|
1554
|
-
[key: string]: Record<string, unknown>;
|
|
1555
|
-
};
|
|
1556
|
-
discord: {
|
|
1557
|
-
PING: Record<string, unknown>;
|
|
1558
|
-
MESSAGE_CREATE: Record<string, unknown>;
|
|
1559
|
-
INTERACTION_CREATE: Record<string, unknown>;
|
|
1560
|
-
[key: string]: Record<string, unknown>;
|
|
1561
|
-
};
|
|
1562
|
-
livekit: {
|
|
1563
|
-
"room.started": Record<string, unknown>;
|
|
1564
|
-
"room.finished": Record<string, unknown>;
|
|
1565
|
-
"participant.joined": Record<string, unknown>;
|
|
1566
|
-
"participant.left": Record<string, unknown>;
|
|
1567
|
-
[key: string]: Record<string, unknown>;
|
|
1568
|
-
};
|
|
1569
|
-
}
|
|
1570
|
-
/** Event handler function type. */
|
|
1571
|
-
type WebhookEventHandler<TEvent = Record<string, unknown>> = (event: TEvent, meta: WebhookMeta) => Promise<void>;
|
|
1572
|
-
/** Provider-based webhook configuration. */
|
|
1573
|
-
interface ProviderWebhookConfig<P extends WebhookProvider = WebhookProvider> {
|
|
1574
|
-
provider: P;
|
|
1575
|
-
secret: EnvSecretRef;
|
|
1576
|
-
events: {
|
|
1577
|
-
[K in keyof ProviderEventMap[P]]?: WebhookEventHandler<ProviderEventMap[P][K]>;
|
|
1578
|
-
};
|
|
1579
|
-
}
|
|
1580
|
-
/** Incoming request representation for custom verify functions. */
|
|
1475
|
+
/** Raw incoming request representation, read by signature verification. */
|
|
1581
1476
|
interface WebhookRequest {
|
|
1582
1477
|
headers: Record<string, string>;
|
|
1583
1478
|
body: string;
|
|
1584
1479
|
method: string;
|
|
1585
1480
|
url: string;
|
|
1586
1481
|
}
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
/**
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1482
|
+
|
|
1483
|
+
/** A signature scheme spelled out, for a service with no preset. The presets
|
|
1484
|
+
* (`provider`) are named configurations of this same shape. */
|
|
1485
|
+
interface SignatureSpec {
|
|
1486
|
+
/** Header carrying the signature. */
|
|
1487
|
+
header: string;
|
|
1488
|
+
/** Stripped before comparison (e.g. `sha256=`). Omit when absent. */
|
|
1489
|
+
prefix?: string;
|
|
1490
|
+
algo: "hmac-sha256" | "hmac-sha1";
|
|
1491
|
+
encoding: "hex" | "base64";
|
|
1492
|
+
/** What the HMAC covers. Exactly two placeholders: `{body}` and `{ts}`.
|
|
1493
|
+
* Everything else is literal. `{ts}` requires `timestampHeader` and brings
|
|
1494
|
+
* the five-minute replay window with it. */
|
|
1495
|
+
signs: string;
|
|
1496
|
+
timestampHeader?: string;
|
|
1497
|
+
}
|
|
1498
|
+
interface WebhookOptions {
|
|
1499
|
+
provider?: WebhookProvider;
|
|
1500
|
+
signature?: SignatureSpec;
|
|
1501
|
+
/** Env-var REFERENCE for the signing secret — the platform never holds it. */
|
|
1502
|
+
secret: {
|
|
1503
|
+
env: string;
|
|
1504
|
+
};
|
|
1505
|
+
}
|
|
1506
|
+
type WebhookEventHandler = (event: unknown, meta: WebhookMeta) => Promise<void>;
|
|
1507
|
+
interface ResolvedWebhook {
|
|
1508
|
+
provider?: WebhookProvider;
|
|
1509
|
+
signature?: SignatureSpec;
|
|
1510
|
+
secret: {
|
|
1511
|
+
env: string;
|
|
1512
|
+
};
|
|
1598
1513
|
events: Record<string, WebhookEventHandler>;
|
|
1599
1514
|
}
|
|
1600
|
-
/**
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1515
|
+
/** Mark a class as an inbound webhook. The mount name is the FILE name — there
|
|
1516
|
+
* is deliberately no `name` option, because the file name IS the public URL. */
|
|
1517
|
+
declare function Webhook(options: WebhookOptions): <T extends abstract new (...args: never[]) => object>(ctor: T) => T;
|
|
1518
|
+
/** Bind a method to one event name. Any string is valid: presets provide
|
|
1519
|
+
* autocomplete, never a constraint, because we do not carry provider catalogs. */
|
|
1520
|
+
declare function On(event: string): (target: object, fnName: string | symbol) => void;
|
|
1521
|
+
/** Read a decorated class back as the resolved config the runtime consumes.
|
|
1522
|
+
* Every misuse throws HERE, at build time, rather than becoming a webhook that
|
|
1523
|
+
* answers 200 and does nothing. */
|
|
1524
|
+
declare function getWebhookConfig(ctor: object): ResolvedWebhook;
|
|
1525
|
+
|
|
1526
|
+
interface JobOptions {
|
|
1527
|
+
/** Cron expression, five fields (e.g. "0 3 * * *"). */
|
|
1528
|
+
schedule: string;
|
|
1529
|
+
/** Execution timeout in seconds. Defaults to 30, ceiling 300 (sandbox limit). */
|
|
1530
|
+
timeout?: number;
|
|
1606
1531
|
}
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
* export default defineWebhook({
|
|
1615
|
-
* provider: "stripe",
|
|
1616
|
-
* secret: { env: "STRIPE_WEBHOOK_SECRET" },
|
|
1617
|
-
* events: {
|
|
1618
|
-
* "checkout.session.completed": async (event, meta) => {
|
|
1619
|
-
* await Database.insert("orders", { status: "paid" });
|
|
1620
|
-
* },
|
|
1621
|
-
* },
|
|
1622
|
-
* });
|
|
1623
|
-
* ```
|
|
1624
|
-
*/
|
|
1625
|
-
declare function defineWebhook<P extends WebhookProvider>(config: ProviderWebhookConfig<P>): ResolvedProviderWebhook<P>;
|
|
1626
|
-
/**
|
|
1627
|
-
* Define a custom webhook with optional verification.
|
|
1628
|
-
*
|
|
1629
|
-
* @example
|
|
1630
|
-
* ```ts
|
|
1631
|
-
* export default defineWebhook({
|
|
1632
|
-
* path: "/webhooks/livekit",
|
|
1633
|
-
* verify: async (req) => req.headers["x-api-key"] === "secret",
|
|
1634
|
-
* handler: async (payload, meta) => {
|
|
1635
|
-
* Log.info("Received webhook", payload);
|
|
1636
|
-
* },
|
|
1637
|
-
* });
|
|
1638
|
-
* ```
|
|
1639
|
-
*/
|
|
1640
|
-
declare function defineWebhook(config: CustomWebhookConfig): ResolvedCustomWebhook;
|
|
1532
|
+
interface ResolvedJob {
|
|
1533
|
+
schedule: string;
|
|
1534
|
+
timeout: number;
|
|
1535
|
+
handler: (meta: JobMeta) => Promise<void>;
|
|
1536
|
+
}
|
|
1537
|
+
declare function Job(options: JobOptions): <T extends abstract new (...args: never[]) => object>(ctor: T) => T;
|
|
1538
|
+
declare function getJobConfig(ctor: object): ResolvedJob;
|
|
1641
1539
|
|
|
1642
1540
|
/**
|
|
1643
1541
|
* resource.ts — external connections as lifecycle-managed classes.
|
|
@@ -1848,4 +1746,4 @@ declare const documents: {
|
|
|
1848
1746
|
onDocumentDeleted(handler: HookHandler<DocumentDeletedEvent>): ResolvedHook<DocumentDeletedEvent>;
|
|
1849
1747
|
};
|
|
1850
1748
|
|
|
1851
|
-
export { type AcsOptions, type ApnsOptions, type BackoffStrategy, Body, type BucketDef, type BucketOptions, Cache, CacheClient, Client, Controller, type ControllerOptions,
|
|
1749
|
+
export { type AcsOptions, type ApnsOptions, type BackoffStrategy, Body, type BucketDef, type BucketOptions, Cache, CacheClient, Client, Controller, type ControllerOptions, DBClient, Database, type DefinedError, type DefinedErrorWithData, Delete, type DocumentCreatedEvent, type DocumentDeletedEvent, type DocumentUpdatedEvent, Documents, EGRESS_CONFIG_KIND, type EgressConfig, type EgressInput, EntitlementKey, EnvTypedDatabase, FLAGS_CONFIG_KIND, type FcmOptions, type FileDeletedEvent, type FileUploadedEvent, type FlagDef, type FlagJsonObject, type FlagJsonValue, type FlagOptions, type FlagType, type FlagValue, Flags, type FlagsConfig, type FlagsInput, Get, Headers, type HookHandler, type HookMeta, HttpError, type HttpMethodUpper, Job, type JobMeta, type JobOptions, LimitKey, type LimitState, Log, Logger, NOTIFICATIONS_CONFIG_KIND, Notifications, type NotificationsConfig, type NotificationsInput, On, OptionalUser, type OwnedTablesOf, PROVIDER_CATALOG, PalbaseDocsClient, PalbaseFlagsClient, PalbaseNotificationsClient, PalbaseRealtimeClient, PalbaseStorageClient, Param, type ParamKind, type ParamMeta, type PasswordResetEvent, Patch, Post, type ProviderCatalogEntry, type ProviderDef, type ProviderName, type ProviderOptions, Purchases, type PurchasesManifest, type PurchasesService, Put, Query, QueryParams, Queue, QueueClient, RESERVED_SECRET_PREFIX, RateLimitConfig, Realtime, type RegisteredError, Req, RequestId, type RequestStore, RequireEntitlement, type ResolvedHook, type ResolvedJob, type ResolvedWebhook, type ResolvedWorkerConfig, Resource, type ResourceEnv, type RouteMeta, type RouteOptions, type RuntimeServices, STORAGE_CONFIG_KIND, SchemaDef, type Seed, type SeedFor, type SeedJson, type SeedRowFor, type SendgridOptions, type SesOptions, type SignInEvent, type SignOutEvent, type SignatureSpec, type SmtpOptions, Spend, type SpendMeta, type SpendOptions, Storage, type StorageConfig, type StorageInput, type StoreEnv, TEST_USERS_CONFIG_KIND, type TableGraph, TableTypes, Tables, type TestUserDef, type TestUserOptions, type TestUsersConfig, type TestUsersInput, type ThrowDescriptor, TraceId, type TwilioOptions, Upload, type UploadConfig, UploadedObject, User, type UserCreatedEvent, User$1 as UserT, Webhook, type WebhookEventHandler, type WebhookMeta, type WebhookOptions, type WebhookProvider, type WebhookRequest, type WorkerConfig, type WorkerMeta, __getRuntime, __registerResource, __requestALS, __runResourceBoot, __runWithRuntime, __setRuntime, __shutdownResources, auth, bucket, buildProvider, defineEgress, defineError, defineFlags, defineNotifications, defineStorage, defineTestUsers, defineWorker, documents, entitlementFor, flag, getErrorRegistry, getJobConfig, getRoutes, getWebhookConfig, makeEnvDts, makePurchasesDts, parseFileSizeLimit, recordThrows, reservedSecretKey, spendFor, storage, testUser, validateUploadAgainstStorage };
|