@deepdockai/cli 1.0.15 → 1.0.17

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,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.0.17
4
+
5
+ - A device whose identity is held by two PCs (a copied PC or VM snapshot) answers every call with `409 device_connected_twice`; nothing runs and the `Idempotency-Key` is free. The skill's error reference lists it, and the CLI exits with 2 for it.
6
+
7
+ ## 1.0.16
8
+
9
+ - A new organisation waits for Deepdock's approval before it can act as a partner: until then every call with its keys answers `403 partner_not_approved`. The skill's error reference lists it, and the CLI exits with 2 for it.
10
+
3
11
  ## 1.0.15
4
12
 
5
13
  - `device_offline` also covers a call cut off by a Deepdock restart or deploy (retry a write with the same key). `temporarily_unavailable` is also sent, with `Retry-After: 5`, when Deepdock cannot reach its database. The skill's error reference, idempotency and concepts pages say so.
package/dist/deepdock.js CHANGED
@@ -10851,6 +10851,7 @@ var EXIT_CODES = {
10851
10851
  organization_required: 1,
10852
10852
  invalid_request: 2,
10853
10853
  forbidden: 2,
10854
+ partner_not_approved: 2,
10854
10855
  not_found: 2,
10855
10856
  device_not_found: 2,
10856
10857
  system_not_on_device: 2,
@@ -10860,6 +10861,7 @@ var EXIT_CODES = {
10860
10861
  pairing_code_invalid: 2,
10861
10862
  other_partner_build: 2,
10862
10863
  device_learning_only: 2,
10864
+ device_connected_twice: 2,
10863
10865
  rate_limited: 2,
10864
10866
  target_rejected: 2,
10865
10867
  check_failed: 2,
@@ -11428,7 +11430,7 @@ import { spawn } from "node:child_process";
11428
11430
  import { homedir, hostname } from "node:os";
11429
11431
 
11430
11432
  // src/version.ts
11431
- var VERSION = "1.0.15";
11433
+ var VERSION = "1.0.17";
11432
11434
 
11433
11435
  // src/runtime.ts
11434
11436
  var DEFAULT_BASE_URL = "https://api.deepdock.ai";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deepdockai/cli",
3
- "version": "1.0.15",
3
+ "version": "1.0.17",
4
4
  "description": "Deepdock partner CLI: pair devices, see systems and actions, create the API key your code runs them with.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -16,6 +16,7 @@ with the **same** `Idempotency-Key`); **Show** says what the end user should see
16
16
  | `invalid_request` | 400 (405 for a wrong method) | malformed request: bad query, `limit` or `cursor`; missing or malformed `Idempotency-Key`; a body that is not an object of strings; a malformed pairing code or device id; a write called with the other method (`Allow` names the right one) | no; fix the code | nothing; a developer bug |
17
17
  | `payload_too_large` | 413 | the request body is over 1 MiB | no; send less | nothing; a developer bug, or shorten the text |
18
18
  | `unauthenticated` | 401 | the key is missing, malformed, for the other environment, unknown, revoked or expired | no | "Deepdock API key refused; check it in the dashboard" to an operator |
19
+ | `partner_not_approved` | 403 | your organisation is waiting for approval by Deepdock; no key of it works yet. Keys made before the approval start working once it is given | no, until Deepdock approves; then yes | "our Deepdock account is waiting for approval; contact Deepdock" |
19
20
  | `not_found` | 404 | no such route; an update whose id matches no record; a write naming a record that does not exist or belongs to another one | no | "record not found" when it is a record; otherwise a bug |
20
21
  | `rate_limited` | 429 | more than 600 calls, or more than 120 writes (counted in both), with this key in a minute; or more than 5 failed pairing claims in 60 s | yes, after `Retry-After: 60` (`retryAfterSeconds: 60` in the body); a write keeps its key. The pairing claim answer has neither: wait up to a minute | "try again in a minute" |
21
22
 
@@ -36,6 +37,7 @@ dashboard-only.
36
37
  | `pairing_code_invalid` | 404 | pairing: the code is unknown, expired, replaced, used, or its device is offline | with a fresh code | "read the code off the device screen again" |
37
38
  | `other_partner_build` | 409 | pairing: the device runs another partner's client build | no | "this device is set up for another provider" |
38
39
  | `device_learning_only` | 409 | the PC runs the Deepdock client for learning only, which runs no actions; nothing was sent to it. Reads, writes and the systems list on it all answer this | no; it changes only when the Deepdock service is installed on that PC | "this PC needs the Deepdock service to run actions" |
40
+ | `device_connected_twice` | 409 | two PCs are connected with this device's identity (a copied PC or VM snapshot); nothing ran, so the `Idempotency-Key` is free | no; a person shuts the copy down, and calls work again about five minutes after only one PC is connected | "two PCs use this device; shut the copy down" |
39
41
 
40
42
  ## Input
41
43
 
@@ -89,6 +91,7 @@ const REACTION: Record<string, Reaction> = {
89
91
  pairing_code_invalid: 'fix-input',
90
92
  other_partner_build: 'stop',
91
93
  device_learning_only: 'stop',
94
+ device_connected_twice: 'stop',
92
95
  invalid_input: 'fix-input',
93
96
  target_rejected: 'fix-input',
94
97
  unknown_author: 'fix-input',