@zinn-digital/sdk 0.1.1967 → 0.1.1971

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.
@@ -30481,6 +30481,26 @@ export interface paths {
30481
30481
  patch?: never;
30482
30482
  trace?: never;
30483
30483
  };
30484
+ "/v1/compute/server-sites": {
30485
+ parameters: {
30486
+ query?: never;
30487
+ header?: never;
30488
+ path?: never;
30489
+ cookie?: never;
30490
+ };
30491
+ /**
30492
+ * Your servers that can host websites, with how many sites each one holds.
30493
+ * @description The deploy screen's "Your servers" group (cloud panel L1, docs/1146 §3.3): every server of the organisation (or, with `org_id`, of one organisation in the caller's scope) that the platform manages as a website host, its site count, and `can_deploy` (false while the server is not running). No live capacity reading here: the server's `listComputeServerSites` answers whether one more site fits. Requires `sites.view`.
30494
+ */
30495
+ get: operations["listComputeServerSiteChoices"];
30496
+ put?: never;
30497
+ post?: never;
30498
+ delete?: never;
30499
+ options?: never;
30500
+ head?: never;
30501
+ patch?: never;
30502
+ trace?: never;
30503
+ };
30484
30504
  "/v1/compute/servers": {
30485
30505
  parameters: {
30486
30506
  query?: never;
@@ -31612,6 +31632,33 @@ export interface paths {
31612
31632
  patch?: never;
31613
31633
  trace?: never;
31614
31634
  };
31635
+ "/v1/compute/servers/{serverId}/sites": {
31636
+ parameters: {
31637
+ query?: never;
31638
+ header?: never;
31639
+ path: {
31640
+ /** @description The server's id, as `listComputeServers` reports it. **Ours** (UUIDv7), minted when the order row was written — never the provider's own identifier for the machine. */
31641
+ serverId: components["parameters"]["ComputeServerId"];
31642
+ };
31643
+ cookie?: never;
31644
+ };
31645
+ /**
31646
+ * The sites on one of your servers, and whether another one fits.
31647
+ * @description Lists the organisation's sites placed on this server and answers, from a live reading, whether a new site can be deployed onto it. `can_deploy` is false with a machine `refusal` code (`not_managed`, `not_operable`, `disk_full`, `low_memory`, `capacity_unknown`, `not_in_good_standing`) the dashboard turns into words per locale. `capacity` is `null` when the server is not managed by the platform. `applications` and `php_versions` are the choices a deploy accepts. A site's `can_move_back` is true while its move onto this server is inside the seven-day hold; moving it back is `rollbackSiteOwnVps`. Requires `sites.view`; `404` for a server that is not the caller's.
31648
+ */
31649
+ get: operations["listComputeServerSites"];
31650
+ put?: never;
31651
+ /**
31652
+ * Deploy a new site onto one of your servers.
31653
+ * @description Creates a site pinned to this server after the same live capacity check the list answers. Refusals are `422` with a machine code in `details[0].code` (the list's refusal codes plus `bad_application`, `bad_php_version`, `domain_refused`, `domain_taken`) and, where one input is at fault, `details[0].field`. The deploy is audit-logged as `compute.server.site_deployed`. Requires `sites.create`; `404` for a server that is not the caller's.
31654
+ */
31655
+ post: operations["deployComputeServerSite"];
31656
+ delete?: never;
31657
+ options?: never;
31658
+ head?: never;
31659
+ patch?: never;
31660
+ trace?: never;
31661
+ };
31615
31662
  "/v1/compute/servers/{serverId}/snapshots": {
31616
31663
  parameters: {
31617
31664
  query?: never;
@@ -84057,6 +84104,14 @@ export interface components {
84057
84104
  /** @description The pinned monthly price, which one calendar month of hours never exceeds. */
84058
84105
  monthly_cap_minor: number | null;
84059
84106
  };
84107
+ /** @description A live reading of the server's room. A `null` number is a reading we could not take; `refusal` is `null` when another site fits, otherwise the refusal code. */
84108
+ ComputeServerCapacity: {
84109
+ disk_total_gb: number | null;
84110
+ disk_used_percent: number | null;
84111
+ ram_free_mb: number | null;
84112
+ ram_total_mb: number | null;
84113
+ refusal: string | null;
84114
+ };
84060
84115
  /**
84061
84116
  * @description A short-lived out-of-band console onto a machine.
84062
84117
  *
@@ -84109,6 +84164,8 @@ export interface components {
84109
84164
  ComputeServerFirewall: {
84110
84165
  /** @description Whether a firewall resource is actually applied to this machine. */
84111
84166
  attached: boolean;
84167
+ /** @description The rule directions this machine's firewall can filter, set by its provider's driver (P3-042). `["in"]` means the firewall filters incoming traffic only: offer no outgoing rule, because a save holding one is refused. Present whether or not a firewall is attached yet. */
84168
+ directions: ("in" | "out")[];
84112
84169
  /** @description The provider's firewall id */
84113
84170
  id: string;
84114
84171
  /** @description Its name at the provider */
@@ -84184,12 +84241,12 @@ export interface components {
84184
84241
  /** @description The machines, across every organisation the caller can read. */
84185
84242
  data: components["schemas"]["ComputeServer"][];
84186
84243
  };
84187
- /** @description How hard a machine has worked across a window, as the provider stated it. Rates, never counters. Series keys: `cpu_percent` (0-100 across all cores), `network_in_bps`, `network_out_bps`, `disk_read_bps`, `disk_write_bps` (bytes per second). */
84244
+ /** @description How hard a machine has worked across a window, as the provider stated it. Rates, never counters. Series keys: `cpu_percent` (0-100 across all cores), `network_in_bps`, `network_out_bps`, `disk_read_bps`, `disk_write_bps` (bytes per second), and two levels read from inside the machine when it reports them: `memory_used_percent` and `disk_used_percent` (0-100, root filesystem). Some ranges count traffic once a day: their `step_seconds` is 86400 and a window under a day has no complete point yet. The answer is cached for one step (60 s to 5 min). */
84188
84245
  ComputeServerMetricsHistory: {
84189
84246
  /** @description ⛔ A quantity this range does not measure is absent, not empty. */
84190
84247
  series: {
84191
84248
  /** @enum {string} */
84192
- key: "cpu_percent" | "network_in_bps" | "network_out_bps" | "disk_read_bps" | "disk_write_bps";
84249
+ key: "cpu_percent" | "network_in_bps" | "network_out_bps" | "disk_read_bps" | "disk_write_bps" | "memory_used_percent" | "disk_used_percent";
84193
84250
  points: {
84194
84251
  /** @description Unix seconds, UTC. */
84195
84252
  at: number;
@@ -84318,6 +84375,47 @@ export interface components {
84318
84375
  ComputeServerSetFirewallRequest: {
84319
84376
  rules: components["schemas"]["ComputeFirewallRule"][];
84320
84377
  };
84378
+ /** @description One site placed on a customer's own server. */
84379
+ ComputeServerSite: {
84380
+ /** @description Inside the hold of its move onto this server; `rollbackSiteOwnVps` moves it back. */
84381
+ can_move_back: boolean;
84382
+ /** Format: date-time */
84383
+ created_at: string | null;
84384
+ /** Format: uuid */
84385
+ id: string;
84386
+ name: string;
84387
+ php_version: string | null;
84388
+ primary_domain: string;
84389
+ stack_type: string;
84390
+ status: string;
84391
+ };
84392
+ ComputeServerSiteChoices: {
84393
+ data: {
84394
+ can_deploy: boolean;
84395
+ name: string;
84396
+ /** Format: uuid */
84397
+ server_id: string;
84398
+ site_count: number;
84399
+ }[];
84400
+ };
84401
+ ComputeServerSiteDeployRequest: {
84402
+ application: string;
84403
+ php_version?: string;
84404
+ primary_domain: string;
84405
+ };
84406
+ /** @description The sites on one server plus whether a new one can be deployed there. */
84407
+ ComputeServerSites: {
84408
+ applications: string[];
84409
+ can_deploy: boolean;
84410
+ capacity: components["schemas"]["ComputeServerCapacity"] | null;
84411
+ data: components["schemas"]["ComputeServerSite"][];
84412
+ /** @description True when the platform runs this server as a site host. */
84413
+ managed: boolean;
84414
+ php_versions: string[];
84415
+ refusal: string | null;
84416
+ /** Format: uuid */
84417
+ server_id: string;
84418
+ };
84321
84419
  /**
84322
84420
  * @description One on-demand image of a machine's disk.
84323
84421
  *
@@ -174371,6 +174469,30 @@ export interface operations {
174371
174469
  503: components["responses"]["ServiceUnavailable"];
174372
174470
  };
174373
174471
  };
174472
+ listComputeServerSiteChoices: {
174473
+ parameters: {
174474
+ query?: {
174475
+ org_id?: string;
174476
+ };
174477
+ header?: never;
174478
+ path?: never;
174479
+ cookie?: never;
174480
+ };
174481
+ requestBody?: never;
174482
+ responses: {
174483
+ /** @description The servers a website can be deployed onto. */
174484
+ 200: {
174485
+ headers: {
174486
+ [name: string]: unknown;
174487
+ };
174488
+ content: {
174489
+ "application/json": components["schemas"]["ComputeServerSiteChoices"];
174490
+ };
174491
+ };
174492
+ 401: components["responses"]["Unauthorized"];
174493
+ 403: components["responses"]["Forbidden"];
174494
+ };
174495
+ };
174374
174496
  listComputeServers: {
174375
174497
  parameters: {
174376
174498
  query?: {
@@ -176184,6 +176306,63 @@ export interface operations {
176184
176306
  503: components["responses"]["ServiceUnavailable"];
176185
176307
  };
176186
176308
  };
176309
+ listComputeServerSites: {
176310
+ parameters: {
176311
+ query?: never;
176312
+ header?: never;
176313
+ path: {
176314
+ /** @description The server's id, as `listComputeServers` reports it. **Ours** (UUIDv7), minted when the order row was written — never the provider's own identifier for the machine. */
176315
+ serverId: components["parameters"]["ComputeServerId"];
176316
+ };
176317
+ cookie?: never;
176318
+ };
176319
+ requestBody?: never;
176320
+ responses: {
176321
+ /** @description The server's sites and its live capacity verdict. */
176322
+ 200: {
176323
+ headers: {
176324
+ [name: string]: unknown;
176325
+ };
176326
+ content: {
176327
+ "application/json": components["schemas"]["ComputeServerSites"];
176328
+ };
176329
+ };
176330
+ 401: components["responses"]["Unauthorized"];
176331
+ 403: components["responses"]["Forbidden"];
176332
+ 404: components["responses"]["NotFound"];
176333
+ };
176334
+ };
176335
+ deployComputeServerSite: {
176336
+ parameters: {
176337
+ query?: never;
176338
+ header?: never;
176339
+ path: {
176340
+ /** @description The server's id, as `listComputeServers` reports it. **Ours** (UUIDv7), minted when the order row was written — never the provider's own identifier for the machine. */
176341
+ serverId: components["parameters"]["ComputeServerId"];
176342
+ };
176343
+ cookie?: never;
176344
+ };
176345
+ requestBody: {
176346
+ content: {
176347
+ "application/json": components["schemas"]["ComputeServerSiteDeployRequest"];
176348
+ };
176349
+ };
176350
+ responses: {
176351
+ /** @description The site, created and placed on this server. */
176352
+ 201: {
176353
+ headers: {
176354
+ [name: string]: unknown;
176355
+ };
176356
+ content: {
176357
+ "application/json": components["schemas"]["ComputeServerSite"];
176358
+ };
176359
+ };
176360
+ 401: components["responses"]["Unauthorized"];
176361
+ 403: components["responses"]["Forbidden"];
176362
+ 404: components["responses"]["NotFound"];
176363
+ 422: components["responses"]["UnprocessableEntity"];
176364
+ };
176365
+ };
176187
176366
  listComputeServerSnapshots: {
176188
176367
  parameters: {
176189
176368
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zinn-digital/sdk",
3
- "version": "0.1.1967",
3
+ "version": "0.1.1971",
4
4
  "description": "Typed TypeScript client for the Zinn Digital Platform API, generated from its OpenAPI spec.",
5
5
  "license": "MIT",
6
6
  "author": "Neil Lock \u2014 CEO, Zinn Digital\u00ae Ltd <office@zinndigital.com>",