@crvouga/mockingbird-service-cognito 3.16.0 → 3.17.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.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,22 @@
1
1
  # Changelog — @crvouga/mockingbird-service-cognito
2
2
 
3
- ## 3.16.0 (2026-11-14)
3
+ ## 3.17.1 (2026-11-16)
4
+
5
+ ### Dependencies
6
+
7
+ - `@crvouga/mockingbird-runtime`
8
+ - `@crvouga/mockingbird-service-sqlite`
9
+
10
+ ## 3.17.0 (2026-11-14)
11
+
12
+ ### Features
13
+
14
+ - expand in-process emulation and resolve Plane and streaming gaps ([e6733fd](https://github.com/crvouga/mockingbird/commit/e6733fd00f5dd03259f36cc0f452780a7e0deea4))
15
+ - add browser runtime polyfills and edge-snapping app cycle ([815b739](https://github.com/crvouga/mockingbird/commit/815b7399f1e058b89b3fa025f79a5014172b3ab8))
16
+ - run lab systems in browser PR previews ([df14882](https://github.com/crvouga/mockingbird/commit/df148828ca66db1e20cf9fa2fdf38b56b5116da4))
17
+ - publish the shared runtime once; services depend on it instead of inlining it ([4903c4a](https://github.com/crvouga/mockingbird/commit/4903c4a748fd801001ad3fd34b6016b55e0f9953))
18
+
19
+ ## 3.16.0 (2026-11-13)
4
20
 
5
21
  ### Features
6
22
 
@@ -0,0 +1,52 @@
1
+ import {
2
+ createRuntime
3
+ } from "./chunk-KDE35R22.js";
4
+
5
+ // src/server.ts
6
+ import {
7
+ listen,
8
+ providerServeOptions,
9
+ providerServeValues
10
+ } from "@crvouga/mockingbird-runtime/adapter-node";
11
+ var DEFAULT_PORT = 8811;
12
+ var createServer = async (options = {}) => {
13
+ const { port, host, ...rest } = options;
14
+ const runtime = createRuntime(rest);
15
+ return { ...await listen(runtime, { port: port ?? 0, ...host ? { host } : {} }), runtime };
16
+ };
17
+ var serveTarget = {
18
+ name: "cognito",
19
+ defaultPort: DEFAULT_PORT,
20
+ options: {
21
+ ...providerServeOptions,
22
+ "pool-id": { type: "string", value: "<id>", description: "User pool id" },
23
+ "client-id": { type: "string", value: "<id>", description: "App client id" },
24
+ region: { type: "string", value: "<region>", description: "AWS region (default us-east-1)" }
25
+ },
26
+ create: async (values, common) => createRuntime({
27
+ ...await providerServeValues(
28
+ values,
29
+ common
30
+ ),
31
+ ...typeof values["pool-id"] === "string" ? { poolId: values["pool-id"] } : {},
32
+ ...typeof values["client-id"] === "string" ? { clientId: values["client-id"] } : {},
33
+ ...typeof values.region === "string" ? { region: values.region } : {},
34
+ ...common.adminPrefix !== void 0 ? { adminPrefix: common.adminPrefix } : {},
35
+ ...common.adminKey !== void 0 ? { adminKey: common.adminKey } : {},
36
+ ...common.adminControls !== void 0 ? { adminControls: common.adminControls } : {},
37
+ ...common.seed !== void 0 ? { seed: common.seed } : {},
38
+ ...common.onLog ? { onLog: common.onLog } : {}
39
+ }),
40
+ banner: () => [
41
+ "AWS SDK endpoint: set COGNITO_ENDPOINT to this URL",
42
+ "admin: POST /__admin/users; GET /__admin/codes?username=\u2026; GET /__admin/outbox lists delivered codes",
43
+ "hosted UI: GET /oauth2/authorize, POST /oauth2/token; POST /__admin/app-clients registers callback URLs"
44
+ ]
45
+ };
46
+
47
+ export {
48
+ DEFAULT_PORT,
49
+ createServer,
50
+ serveTarget
51
+ };
52
+ //# sourceMappingURL=chunk-6TLQZALD.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/server.ts"],
4
+ "sourcesContent": ["/// <reference types=\"node\" />\nimport {\n type Listening,\n listen,\n providerServeOptions,\n providerServeValues,\n type ServeTarget,\n} from \"@crvouga/mockingbird-adapter-node\"\nimport { type CognitoRuntime, type CognitoRuntimeOptions, createRuntime } from \"./runtime.js\"\nexport const DEFAULT_PORT = 8811\nexport type CognitoServerOptions = CognitoRuntimeOptions & { port?: number; host?: string }\nexport const createServer = async (\n options: CognitoServerOptions = {},\n): Promise<Listening & { runtime: CognitoRuntime }> => {\n const { port, host, ...rest } = options\n const runtime = createRuntime(rest)\n return { ...(await listen(runtime, { port: port ?? 0, ...(host ? { host } : {}) })), runtime }\n}\nexport const serveTarget: ServeTarget = {\n name: \"cognito\",\n defaultPort: DEFAULT_PORT,\n options: {\n ...providerServeOptions,\n \"pool-id\": { type: \"string\", value: \"<id>\", description: \"User pool id\" },\n \"client-id\": { type: \"string\", value: \"<id>\", description: \"App client id\" },\n region: { type: \"string\", value: \"<region>\", description: \"AWS region (default us-east-1)\" },\n },\n create: async (values, common) =>\n createRuntime({\n ...(await providerServeValues<NonNullable<CognitoRuntimeOptions[\"fixtures\"]>>(\n values,\n common,\n )),\n ...(typeof values[\"pool-id\"] === \"string\" ? { poolId: values[\"pool-id\"] } : {}),\n ...(typeof values[\"client-id\"] === \"string\" ? { clientId: values[\"client-id\"] } : {}),\n ...(typeof values.region === \"string\" ? { region: values.region } : {}),\n ...(common.adminPrefix !== undefined ? { adminPrefix: common.adminPrefix } : {}),\n ...(common.adminKey !== undefined ? { adminKey: common.adminKey } : {}),\n ...(common.adminControls !== undefined ? { adminControls: common.adminControls } : {}),\n ...(common.seed !== undefined ? { seed: common.seed } : {}),\n ...(common.onLog ? { onLog: common.onLog } : {}),\n }),\n banner: () => [\n \"AWS SDK endpoint: set COGNITO_ENDPOINT to this URL\",\n \"admin: POST /__admin/users; GET /__admin/codes?username=\u2026; GET /__admin/outbox lists delivered codes\",\n \"hosted UI: GET /oauth2/authorize, POST /oauth2/token; POST /__admin/app-clients registers callback URLs\",\n ],\n}\n"],
5
+ "mappings": ";;;;;AACA;AAAA,EAEE;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AAEA,IAAM,eAAe;AAErB,IAAM,eAAe,OAC1B,UAAgC,CAAC,MACoB;AACrD,QAAM,EAAE,MAAM,MAAM,GAAG,KAAK,IAAI;AAChC,QAAM,UAAU,cAAc,IAAI;AAClC,SAAO,EAAE,GAAI,MAAM,OAAO,SAAS,EAAE,MAAM,QAAQ,GAAG,GAAI,OAAO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