@pidgeon-ai/sdk 1.40.0 → 1.41.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.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,18 @@ the two would publish a release for every unrelated product deploy.
7
7
  Semver applies to **this package's own surface** — the exported names, the
8
8
  call shapes, the result shape — not to the API behind it.
9
9
 
10
+ ## 1.41.0 — files larger than a request body
11
+
12
+ - `attachmentsCreateUpload` takes `identity_id`, `filename`, `content_type`
13
+ and `size`, and answers with `upload`: a signed URL to `PUT` the bytes to,
14
+ the `headers` to send with them, and `expires_at` (15 minutes). The size and
15
+ type are signed, so the store refuses anything else. Then
16
+ `attachmentsCompleteUpload` makes the id sendable; a send naming it before
17
+ then is a 409 `conflict`.
18
+ - `attachmentsUpload` is unchanged, and capped at 4.5 MB a request by the
19
+ platform whatever the plan allows — which is why the two above exist. Use
20
+ it for small files.
21
+
10
22
  ## 1.40.0 — every key states its scope
11
23
 
12
24
  - `keysCreate` requires `access`, and takes `reaches_all` beside
package/dist/index.cjs CHANGED
@@ -28,6 +28,8 @@ __export(index_exports, {
28
28
  appPasswordsCreate: () => appPasswordsCreate,
29
29
  appPasswordsList: () => appPasswordsList,
30
30
  appPasswordsRevoke: () => appPasswordsRevoke,
31
+ attachmentsCompleteUpload: () => attachmentsCompleteUpload,
32
+ attachmentsCreateUpload: () => attachmentsCreateUpload,
31
33
  attachmentsDownloadUrl: () => attachmentsDownloadUrl,
32
34
  attachmentsText: () => attachmentsText,
33
35
  attachmentsUpload: () => attachmentsUpload,
@@ -1679,6 +1681,20 @@ var attachmentsUpload = (options) => (options.client ?? client).post({
1679
1681
  ...options.headers
1680
1682
  }
1681
1683
  });
1684
+ var attachmentsCreateUpload = (options) => (options.client ?? client).post({
1685
+ security: [{ scheme: "bearer", type: "http" }],
1686
+ url: "/attachments/uploads",
1687
+ ...options,
1688
+ headers: {
1689
+ "Content-Type": "application/json",
1690
+ ...options.headers
1691
+ }
1692
+ });
1693
+ var attachmentsCompleteUpload = (options) => (options.client ?? client).post({
1694
+ security: [{ scheme: "bearer", type: "http" }],
1695
+ url: "/attachments/{id}/complete",
1696
+ ...options
1697
+ });
1682
1698
  var attachmentsDownloadUrl = (options) => (options.client ?? client).get({
1683
1699
  security: [{ scheme: "bearer", type: "http" }],
1684
1700
  url: "/attachments/{id}",
@@ -1849,6 +1865,8 @@ function sleep(ms, signal) {
1849
1865
  appPasswordsCreate,
1850
1866
  appPasswordsList,
1851
1867
  appPasswordsRevoke,
1868
+ attachmentsCompleteUpload,
1869
+ attachmentsCreateUpload,
1852
1870
  attachmentsDownloadUrl,
1853
1871
  attachmentsText,
1854
1872
  attachmentsUpload,