palbase 0.33.0 → 0.34.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.
Files changed (48) hide show
  1. package/README.md +2 -2
  2. package/dist/ai/index.js +2 -2
  3. package/dist/backend/engine.js +2 -2
  4. package/dist/backend/env.js +1 -1
  5. package/dist/backend/index.js +3 -3
  6. package/dist/backend/stack.js +1 -1
  7. package/dist/backend/test.js +2 -2
  8. package/dist/chunks/{HKUBQA4K.js → 23NFADPH.js} +1 -1
  9. package/dist/chunks/{D4P4XLMT.js → 2KUOCM4W.js} +1 -1
  10. package/dist/chunks/{PCOLUMJ2.js → 3WO4MSQK.js} +2 -2
  11. package/dist/chunks/{AKE3ARBQ.js → 56CR6XQX.js} +1 -1
  12. package/dist/chunks/{S4UAMADF.js → 7KAQJOKQ.js} +2 -2
  13. package/dist/chunks/{NAHDBHAC.js → AAJTXVUF.js} +2 -2
  14. package/dist/chunks/{6D5QSXFP.js → BORV4XQE.js} +2 -2
  15. package/dist/chunks/{L5JYBOI3.js → CVZYB52V.js} +2 -2
  16. package/dist/chunks/{GVR2PSNL.js → DP7HCIWR.js} +2 -2
  17. package/dist/chunks/{24U4NDH6.js → FFLUB3R2.js} +2 -2
  18. package/dist/chunks/{KMWZK74K.js → HJTZ5RUV.js} +2 -2
  19. package/dist/chunks/{ECVJH7GC.js → I6FOJBJG.js} +2 -2
  20. package/dist/chunks/{7MEZ7I4T.js → JNARDSKO.js} +2 -2
  21. package/dist/chunks/{OBLZE7OG.js → QLGKS7OC.js} +2 -2
  22. package/dist/chunks/{7KKXGZP6.js → SVEMN34N.js} +1 -1
  23. package/dist/chunks/{5U6L3QNV.js → TGGBNVFF.js} +1 -1
  24. package/dist/chunks/{2TNGTQX6.js → TO7DBGJO.js} +2 -2
  25. package/dist/chunks/{W5YFK4GY.js → TSZBPILF.js} +1 -1
  26. package/dist/chunks/{BJ4U62LX.js → TXPV2FZL.js} +2 -2
  27. package/dist/chunks/{STM6MJLC.js → U2OSMAAB.js} +1 -1
  28. package/dist/chunks/{WRGRQURQ.js → VYJZI4ZF.js} +2 -2
  29. package/dist/chunks/{WBYKUJPE.js → WFXZMNDL.js} +2 -2
  30. package/dist/chunks/{HLESDZU4.js → ZXOT7B45.js} +2 -2
  31. package/dist/cli.js +3 -3
  32. package/dist/cloud/index.js +2 -2
  33. package/dist/refuse/ai.js +1 -1
  34. package/dist/refuse/backend.js +1 -1
  35. package/dist/refuse/cloud.js +1 -1
  36. package/dist/refuse/server.js +1 -1
  37. package/dist/server/index.js +2 -2
  38. package/dist/server/testing.js +2 -2
  39. package/dist/web/calls-ui.js +2 -2
  40. package/dist/web/index.js +2 -2
  41. package/dist/web/message.js +2 -2
  42. package/dist/web/palbe.js +2 -2
  43. package/dist/web/paywall.js +2 -2
  44. package/dist/web/push-sw.js +1 -1
  45. package/dist/web/ssr.js +2 -2
  46. package/dist/web/vite.js +2 -2
  47. package/package.json +2 -2
  48. package/types/internal/src/modules/machines.d.ts +25 -9
@@ -214,7 +214,7 @@ export type Machine = {
214
214
  */
215
215
  always_on: boolean;
216
216
  /**
217
- * Whether a pull request opened against its branch is previewed: its head built into a machine of its own, <name>-pr<n>, in this environment, with this environment's settings and secrets, answering at <name>-pr<n>-<ref> until the pull request closes; the pull request is told where in a comment. Turn it on in an environment kept for previews, not production's: the pull request's code runs with the environment's secrets.
217
+ * Whether a pull request opened against its branch is previewed: its head built into a machine of its own, <name>-pr<n>, in this environment, with this environment's settings and secrets, answering at <name>-pr<n>-<ref> until the pull request closes; the pull request is told where in a comment. Any environment previews, production's too: the pull request's code runs with the environment's settings, secrets and users, with a database of its own when the machine runs its database's migrations.
218
218
  */
219
219
  previews: boolean;
220
220
  /**
@@ -307,7 +307,7 @@ export type MachineCreate = {
307
307
  */
308
308
  always_on?: boolean;
309
309
  /**
310
- * Whether a pull request opened against its branch is previewed: its head built into a machine of its own, <name>-pr<n>, in this environment, with this environment's settings and secrets, answering at <name>-pr<n>-<ref> until the pull request closes; the pull request is told where in a comment. Turn it on in an environment kept for previews, not production's: the pull request's code runs with the environment's secrets. A machine read with a platform's tokens (source.access token) previews what its platform puts (PUT /machines/{name}/previews/{pull_request}), no comment written.
310
+ * Whether a pull request opened against its branch is previewed: its head built into a machine of its own, <name>-pr<n>, in this environment, with this environment's settings and secrets, answering at <name>-pr<n>-<ref> until the pull request closes; the pull request is told where in a comment. Any environment previews, production's too: the pull request's code runs with the environment's settings, secrets and users, with a database of its own when the machine runs its database's migrations. A machine read with a platform's tokens (source.access token) previews what its platform puts (PUT /machines/{name}/previews/{pull_request}), no comment written.
311
311
  */
312
312
  previews?: boolean;
313
313
  /**
@@ -802,6 +802,14 @@ export type DatabaseLimits = {
802
802
  * The connections it takes (Postgres' max_connections).
803
803
  */
804
804
  connections: number;
805
+ /**
806
+ * The sessions its direct port (5432) takes at once.
807
+ */
808
+ direct_connections: number;
809
+ /**
810
+ * The transactions its pooled port (6543) runs at once.
811
+ */
812
+ pooled_connections: number;
805
813
  };
806
814
  /**
807
815
  * One bucket of a database's usage.
@@ -1197,6 +1205,14 @@ export type DatabaseSize = {
1197
1205
  * A week asleep, its volume is taken back and its next connection brings it back from its backup.
1198
1206
  */
1199
1207
  archives: boolean;
1208
+ /**
1209
+ * How many sessions its direct port (5432) takes at once: a session holds one until it ends, and a client past them is refused (53300).
1210
+ */
1211
+ direct_connections: number;
1212
+ /**
1213
+ * How many transactions its pooled port (6543) runs at once, however many of its clients are connected: a transaction that finds none of them free within 20 s is refused (53300).
1214
+ */
1215
+ pooled_connections: number;
1200
1216
  /**
1201
1217
  * A size counted against the project's free databases; the others are paid for.
1202
1218
  */
@@ -1476,7 +1492,7 @@ export type Site = {
1476
1492
  source: SiteSourceView;
1477
1493
  build: SiteBuildSettings;
1478
1494
  /**
1479
- * Whether a pull request opened against its source's branch is previewed: its head built, with this environment's build settings, into a release of its own that answers at <name>-pr<n>-<ref> until the pull request closes — never what the site serves, none of its releases; the pull request is told where in a comment. Turn it on in an environment kept for previews, not production's.
1495
+ * Whether a pull request opened against its source's branch is previewed: its head built, with this environment's build settings, into a release of its own that answers at <name>-pr<n>-<ref> until the pull request closes — never what the site serves, none of its releases; the pull request is told where in a comment. Any environment previews, production's too: the pull request's build runs with the environment's settings.
1480
1496
  */
1481
1497
  previews: boolean;
1482
1498
  /**
@@ -1522,7 +1538,7 @@ export type SiteCreate = {
1522
1538
  source?: SiteSource;
1523
1539
  build?: SiteBuildSettings;
1524
1540
  /**
1525
- * Whether a pull request opened against its source's branch is previewed: its head built, with this environment's build settings, into a release of its own that answers at <name>-pr<n>-<ref> until the pull request closes — never what the site serves, none of its releases; the pull request is told where in a comment. Turn it on in an environment kept for previews, not production's.
1541
+ * Whether a pull request opened against its source's branch is previewed: its head built, with this environment's build settings, into a release of its own that answers at <name>-pr<n>-<ref> until the pull request closes — never what the site serves, none of its releases; the pull request is told where in a comment. Any environment previews, production's too: the pull request's build runs with the environment's settings.
1526
1542
  */
1527
1543
  previews?: boolean;
1528
1544
  /**
@@ -1858,7 +1874,7 @@ export type PreviewOpened = {
1858
1874
  commit: string;
1859
1875
  };
1860
1876
  /**
1861
- * A platform's pull request: its branch — one of the machine's repository's own — the head its machine's preview builds, and the token it is read with.
1877
+ * A platform's pull request: its branch — one of the machine's repository's own — the head its machine's preview builds, and, for a machine read with a platform's tokens, the token it is read with.
1862
1878
  */
1863
1879
  export type PreviewDeploy = {
1864
1880
  /**
@@ -1870,9 +1886,9 @@ export type PreviewDeploy = {
1870
1886
  */
1871
1887
  commit?: string;
1872
1888
  /**
1873
- * A GitHub App installation's token (ghs_…) for the machine's repository alone, read-only: used once, never kept.
1889
+ * For a machine read with a platform's tokens (source.access token), and required for one: a GitHub App installation's token (ghs_…) for the machine's repository alone, read-only, used once, never kept. A machine read with Palbase's GitHub App takes none (400 token_not_taken): its branch is read with the project's installation.
1874
1890
  */
1875
- git_access_token: string;
1891
+ git_access_token?: string;
1876
1892
  };
1877
1893
  /** Palbase Machines */
1878
1894
  export declare function client(t: Transport): {
@@ -2044,7 +2060,7 @@ export declare function client(t: Transport): {
2044
2060
  /**
2045
2061
  * Open or update a platform's pull request preview
2046
2062
  *
2047
- * For a machine read with a platform's tokens (source.access token: PalCore's, whose repositories have no Palbase App, so no pull request is heard here): opens the preview of the pull request at the head of its branch — one of the machine's repository's own: a fork's is not built — its own machine, <name>-pr<n>, and a database of its own when the machine runs its database's migrations — or builds the open one at it, and opens one that went idle again. The branch is read with git_access_token, a GitHub App installation's token for the machine's repository alone (ghs_…), once; a commit named must be the branch's head (409 commit_not_head). Its address and state are read with GET /machines/{name}/previews; the platform tells its pull request itself. Refused in a production environment (409 previews_in_production), for a machine read with Palbase's GitHub App (409 previews_from_github), with previews off (409 previews_off), and when the environment's limits refuse the preview (409 preview_refused, with why).
2063
+ * For a platform — PalCore — that previews its product's machine itself: one read with its tokens (source.access token), whose pull requests are not heard here, or one read with Palbase's GitHub App, whose numbers then are the platform's (a pull request GitHub told of keeps its own: 409 preview_taken). Opens the preview of the pull request at the head of its branch — one of the machine's repository's own: a fork's is not built — its own machine, <name>-pr<n>, and a database of its own when the machine runs its database's migrations — or builds the open one at it, and opens one that went idle again. A machine read with tokens has its branch read with git_access_token, a GitHub App installation's token for the machine's repository alone (ghs_…), once (400 token_required without); one read with Palbase's App, with the project's installation (400 token_not_taken with one). A commit named must be the branch's head (409 commit_not_head). Any environment previews, production's too: the preview runs with its settings, secrets and users. Its address and state are read with GET /machines/{name}/previews; the platform tells its pull request itself. Refused with previews off (409 previews_off), and when the environment's limits refuse the preview (409 preview_refused, with why).
2048
2064
  */
2049
2065
  putMachinePreview(input: {
2050
2066
  path: {
@@ -2057,7 +2073,7 @@ export declare function client(t: Transport): {
2057
2073
  /**
2058
2074
  * Close a platform's pull request preview
2059
2075
  *
2060
- * For a machine read with a platform's tokens: closes the preview of the pull request, its pull request closed — its machine and its own database are deleted at once. A machine read with Palbase's GitHub App has its previews closed as GitHub tells (409 previews_from_github).
2076
+ * Closes a preview its platform put (PUT): its machine and its own database are deleted at once. A preview GitHub told of closes as its pull request does (409 previews_from_github).
2061
2077
  */
2062
2078
  deleteMachinePreview(input: {
2063
2079
  path: {