@hasna/domains 0.0.39 → 0.0.43

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.
Files changed (52) hide show
  1. package/README.md +11 -15
  2. package/dist/cli/commands/domain.d.ts.map +1 -1
  3. package/dist/cli/index.js +19736 -32040
  4. package/dist/db/database.d.ts +24 -0
  5. package/dist/db/database.d.ts.map +1 -1
  6. package/dist/db/domain-records.d.ts +61 -2
  7. package/dist/db/domain-records.d.ts.map +1 -1
  8. package/dist/db/domains.d.ts +14 -7
  9. package/dist/db/domains.d.ts.map +1 -1
  10. package/dist/db/migrations.d.ts.map +1 -1
  11. package/dist/db/pg-migrations.d.ts.map +1 -1
  12. package/dist/db/store.d.ts +48 -48
  13. package/dist/db/store.d.ts.map +1 -1
  14. package/dist/generated/storage-kit/backend.d.ts +19 -0
  15. package/dist/generated/storage-kit/backend.d.ts.map +1 -0
  16. package/dist/generated/storage-kit/index.d.ts +2 -2
  17. package/dist/generated/storage-kit/index.d.ts.map +1 -1
  18. package/dist/generated/storage-kit/migrations.d.ts.map +1 -1
  19. package/dist/generated/storage-kit/own.d.ts +11 -0
  20. package/dist/generated/storage-kit/own.d.ts.map +1 -0
  21. package/dist/generated/storage-kit/pool.d.ts +7 -6
  22. package/dist/generated/storage-kit/pool.d.ts.map +1 -1
  23. package/dist/generated/storage-kit/query.d.ts +1 -1
  24. package/dist/generated/storage-kit/query.d.ts.map +1 -1
  25. package/dist/generated/storage-kit/tls.d.ts +30 -3
  26. package/dist/generated/storage-kit/tls.d.ts.map +1 -1
  27. package/dist/index.js +15865 -28359
  28. package/dist/lib/brandsight.d.ts.map +1 -1
  29. package/dist/lib/config.d.ts +23 -3
  30. package/dist/lib/config.d.ts.map +1 -1
  31. package/dist/lib/freshness.d.ts +65 -0
  32. package/dist/lib/freshness.d.ts.map +1 -0
  33. package/dist/lib/godaddy.d.ts.map +1 -1
  34. package/dist/lib/namecheap.d.ts +2 -0
  35. package/dist/lib/namecheap.d.ts.map +1 -1
  36. package/dist/lib/registrar.js +17 -6
  37. package/dist/lib/route53.d.ts.map +1 -1
  38. package/dist/lib/route53.js +5 -2
  39. package/dist/mcp/index.js +13479 -25921
  40. package/dist/sdk/index.d.ts +3 -2
  41. package/dist/sdk/index.d.ts.map +1 -1
  42. package/dist/sdk/index.js +280 -3
  43. package/dist/server/app.d.ts +12 -8
  44. package/dist/server/app.d.ts.map +1 -1
  45. package/dist/server/index.d.ts +4 -5
  46. package/dist/server/index.d.ts.map +1 -1
  47. package/dist/server/index.js +527 -181
  48. package/dist/server/openapi.d.ts.map +1 -1
  49. package/dist/server/repo.d.ts.map +1 -1
  50. package/package.json +7 -4
  51. package/dist/generated/storage-kit/mode.d.ts +0 -48
  52. package/dist/generated/storage-kit/mode.d.ts.map +0 -1
@@ -2,6 +2,9 @@
2
2
  export type PgSslConfig = boolean | {
3
3
  rejectUnauthorized: boolean;
4
4
  ca?: string;
5
+ cert?: string;
6
+ key?: string;
7
+ passphrase?: string;
5
8
  };
6
9
  export interface TlsResolveOptions {
7
10
  /** Inline CA bundle (PEM). Wins over every other CA source. */
@@ -12,15 +15,39 @@ export interface TlsResolveOptions {
12
15
  env?: Record<string, string | undefined>;
13
16
  }
14
17
  export type SslMode = "disable" | "prefer" | "require" | "verify-ca" | "verify-full";
18
+ /**
19
+ * Remove the TLS query parameters once this module has resolved them into an
20
+ * explicit `ssl` option. pg re-parses `connectionString` AFTER merging pool
21
+ * options and lets the parse win, so leaving `sslmode` (or `ssl`, `sslcert`,
22
+ * `sslkey`, `sslrootcert`, `sslnegotiation`) in the URL replaces the resolved
23
+ * SSL object with pg's own — discarding the CA bundle with it.
24
+ *
25
+ * Non-TLS parameters and any fragment are preserved exactly.
26
+ */
27
+ export declare function connectionStringWithoutTlsParameters(connectionString: string): string;
28
+ /**
29
+ * Preserve pg's transport negotiation choice outside the stripped URL, so
30
+ * `sslnegotiation=direct` survives as an explicit pool option instead of being
31
+ * silently dropped.
32
+ */
33
+ export declare function sslNegotiationFromConnectionString(connectionString: string): "postgres" | "direct" | undefined;
15
34
  /**
16
35
  * Extract the effective `sslmode` from a Postgres connection string. Honors the
17
- * `sslmode` query param and the legacy `ssl=true` boolean. Returns `disable`
18
- * when TLS is not requested.
36
+ * `sslmode` query param, the legacy `ssl=true` boolean, and pg's rule that
37
+ * `sslnegotiation=direct` implies TLS when no explicit SSL setting is present.
38
+ * Returns `disable` when TLS is not requested.
19
39
  */
20
40
  export declare function sslModeFromConnectionString(connectionString: string): SslMode;
21
41
  /**
22
42
  * Resolve the `pg` ssl config for a connection string. See the module header
23
- * for the full mode table. Returns `undefined` when TLS should be off.
43
+ * for the full mode table.
44
+ *
45
+ * Returns `false` when TLS was explicitly switched off, and `undefined` when the
46
+ * DSN expressed no TLS policy at all — those are different answers, and pg
47
+ * treats them differently: only `undefined` lets `PGSSLMODE` decide.
48
+ *
49
+ * The caller MUST hand pg `connectionStringWithoutTlsParameters(connectionString)`
50
+ * rather than the original DSN, or pg discards everything resolved here.
24
51
  */
25
52
  export declare function resolveTlsConfig(connectionString: string, options?: TlsResolveOptions): PgSslConfig | undefined;
26
53
  //# sourceMappingURL=tls.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tls.d.ts","sourceRoot":"","sources":["../../../src/generated/storage-kit/tls.ts"],"names":[],"mappings":"AAkCA,iEAAiE;AACjE,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG;IAAE,kBAAkB,EAAE,OAAO,CAAC;IAAC,EAAE,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEjF,MAAM,WAAW,iBAAiB;IAChC,+DAA+D;IAC/D,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,uEAAuE;IACvE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,wEAAwE;IACxE,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;CAC1C;AAED,MAAM,MAAM,OAAO,GAAG,SAAS,G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