@salsita-ai/contracts 0.0.0-stage → 0.49.0-develop.d4bea2382c
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 +419 -0
- package/LICENSE +61 -0
- package/README.md +28 -2
- package/dist/api/access-level.d.ts +7 -0
- package/dist/api/access-level.js +1 -0
- package/dist/api/access-token.d.ts +6 -0
- package/dist/api/access-token.js +1 -0
- package/dist/api/index.d.ts +4 -0
- package/dist/api/index.js +1 -0
- package/dist/api/session-role.d.ts +8 -0
- package/dist/api/session-role.js +1 -0
- package/dist/api/session-token.d.ts +22 -0
- package/dist/api/session-token.js +1 -0
- package/dist/assistant/browser-details-tool.d.ts +16 -0
- package/dist/assistant/browser-details-tool.js +1 -0
- package/dist/assistant/deployment-assistant.d.ts +84 -0
- package/dist/assistant/deployment-assistant.js +1 -0
- package/dist/assistant/graphql-tools.d.ts +120 -0
- package/dist/assistant/graphql-tools.js +1 -0
- package/dist/assistant/index.d.ts +6 -0
- package/dist/assistant/index.js +1 -0
- package/dist/assistant/message-metadata.d.ts +17 -0
- package/dist/assistant/message-metadata.js +1 -0
- package/dist/chat/api.d.ts +52 -0
- package/dist/chat/api.js +1 -0
- package/dist/chat/completions/messages.d.ts +3 -0
- package/dist/chat/completions/messages.js +1 -0
- package/dist/chat/completions/types.d.ts +28 -0
- package/dist/chat/completions/types.js +1 -0
- package/dist/chat/functions/augmentations.d.ts +3 -0
- package/dist/chat/functions/augmentations.js +1 -0
- package/dist/chat/functions/create.d.ts +5 -0
- package/dist/chat/functions/create.js +1 -0
- package/dist/chat/functions/process.d.ts +14 -0
- package/dist/chat/functions/process.js +1 -0
- package/dist/chat/functions/types.d.ts +21 -0
- package/dist/chat/functions/types.js +1 -0
- package/dist/chat/functions/validate.d.ts +1 -0
- package/dist/chat/functions/validate.js +2 -0
- package/dist/chat/index.d.ts +10 -0
- package/dist/chat/index.js +1 -0
- package/dist/chat/utils/types.d.ts +1 -0
- package/dist/chat/utils/types.js +1 -0
- package/dist/clerk/clerk-backend-api-client.d.ts +129 -0
- package/dist/clerk/clerk-backend-api-client.js +1 -0
- package/dist/clerk/clerk-backend-api-types.d.ts +740 -0
- package/dist/clerk/clerk-backend-api-types.js +1 -0
- package/dist/clerk/clerk-session-token.d.ts +28 -0
- package/dist/clerk/clerk-session-token.js +1 -0
- package/dist/clerk/clerk-token-service.d.ts +15 -0
- package/dist/clerk/clerk-token-service.js +1 -0
- package/dist/clerk/index.d.ts +4 -0
- package/dist/clerk/index.js +1 -0
- package/dist/domain/deployments/ai-image-domain.d.ts +10 -0
- package/dist/domain/deployments/ai-image-domain.js +1 -0
- package/dist/domain/deployments/api-token-domain.d.ts +8 -0
- package/dist/domain/deployments/api-token-domain.js +1 -0
- package/dist/domain/deployments/configuration-schema-domain.d.ts +22 -0
- package/dist/domain/deployments/configuration-schema-domain.js +1 -0
- package/dist/domain/deployments/customer-domain.d.ts +69 -0
- package/dist/domain/deployments/customer-domain.js +1 -0
- package/dist/domain/deployments/deployment-build-domain.d.ts +78 -0
- package/dist/domain/deployments/deployment-build-domain.js +1 -0
- package/dist/domain/deployments/deployment-domain.d.ts +126 -0
- package/dist/domain/deployments/deployment-domain.js +1 -0
- package/dist/domain/deployments/embedding-domain.d.ts +9 -0
- package/dist/domain/deployments/embedding-domain.js +1 -0
- package/dist/domain/deployments/environment-domain.d.ts +107 -0
- package/dist/domain/deployments/environment-domain.js +1 -0
- package/dist/domain/deployments/image-render-domain.d.ts +22 -0
- package/dist/domain/deployments/image-render-domain.js +1 -0
- package/dist/domain/deployments/index.d.ts +14 -0
- package/dist/domain/deployments/index.js +1 -0
- package/dist/domain/deployments/oauth-connection-domain.d.ts +62 -0
- package/dist/domain/deployments/oauth-connection-domain.js +1 -0
- package/dist/domain/deployments/oauth-provider-domain.d.ts +23 -0
- package/dist/domain/deployments/oauth-provider-domain.js +1 -0
- package/dist/domain/deployments/project-domain.d.ts +26 -0
- package/dist/domain/deployments/project-domain.js +1 -0
- package/dist/domain/deployments/sdk-builder-setup-domain.d.ts +13 -0
- package/dist/domain/deployments/sdk-builder-setup-domain.js +1 -0
- package/dist/domain/deployments/session-domain.d.ts +20 -0
- package/dist/domain/deployments/session-domain.js +1 -0
- package/dist/domain/feedback/feedback-domain.d.ts +55 -0
- package/dist/domain/feedback/feedback-domain.js +1 -0
- package/dist/domain/feedback/index.d.ts +1 -0
- package/dist/domain/feedback/index.js +1 -0
- package/dist/domain/index.d.ts +3 -0
- package/dist/domain/index.js +1 -0
- package/dist/domain/product-configurations/configurations-domain.d.ts +113 -0
- package/dist/domain/product-configurations/configurations-domain.js +1 -0
- package/dist/domain/product-configurations/index.d.ts +1 -0
- package/dist/domain/product-configurations/index.js +1 -0
- package/dist/webhook/core/index.d.ts +3 -0
- package/dist/webhook/core/index.js +1 -0
- package/dist/webhook/core/task-resource.d.ts +80 -0
- package/dist/webhook/core/task-resource.js +1 -0
- package/dist/webhook/core/task-type.d.ts +18 -0
- package/dist/webhook/core/task-type.js +1 -0
- package/dist/webhook/core/template.d.ts +65 -0
- package/dist/webhook/core/template.js +1 -0
- package/dist/webhook/empty-xlsx.d.ts +10 -0
- package/dist/webhook/empty-xlsx.js +1 -0
- package/dist/webhook/excel-workbook-client.d.ts +78 -0
- package/dist/webhook/excel-workbook-client.js +1 -0
- package/dist/webhook/google-sheets-client.d.ts +23 -0
- package/dist/webhook/google-sheets-client.js +1 -0
- package/dist/webhook/implementation/index.d.ts +4 -0
- package/dist/webhook/implementation/index.js +1 -0
- package/dist/webhook/implementation/webhook-api-types.d.ts +302 -0
- package/dist/webhook/implementation/webhook-api-types.js +1 -0
- package/dist/webhook/implementation/webhook-client.d.ts +85 -0
- package/dist/webhook/implementation/webhook-client.js +1 -0
- package/dist/webhook/implementation/webhook-routing.d.ts +30 -0
- package/dist/webhook/implementation/webhook-routing.js +1 -0
- package/dist/webhook/implementation/webhook-tunnel-types.d.ts +114 -0
- package/dist/webhook/implementation/webhook-tunnel-types.js +1 -0
- package/dist/webhook/index.d.ts +7 -0
- package/dist/webhook/index.js +1 -0
- package/dist/webhook/spreadsheet-adapter-factory.d.ts +10 -0
- package/dist/webhook/spreadsheet-adapter-factory.js +1 -0
- package/dist/webhook/spreadsheet-adapter.d.ts +94 -0
- package/dist/webhook/spreadsheet-adapter.js +1 -0
- package/dist/webhook/tasks/call-lambda-back-task.d.ts +22 -0
- package/dist/webhook/tasks/call-lambda-back-task.js +1 -0
- package/dist/webhook/tasks/edit-google-spreadsheet-task.d.ts +48 -0
- package/dist/webhook/tasks/edit-google-spreadsheet-task.js +1 -0
- package/dist/webhook/tasks/finalize-task.d.ts +184 -0
- package/dist/webhook/tasks/finalize-task.js +1 -0
- package/dist/webhook/tasks/generate-configuration-link-task.d.ts +56 -0
- package/dist/webhook/tasks/generate-configuration-link-task.js +1 -0
- package/dist/webhook/tasks/generate-csv-task.d.ts +30 -0
- package/dist/webhook/tasks/generate-csv-task.js +1 -0
- package/dist/webhook/tasks/generate-images-task.d.ts +404 -0
- package/dist/webhook/tasks/generate-images-task.js +1 -0
- package/dist/webhook/tasks/generate-pdf-task.d.ts +188 -0
- package/dist/webhook/tasks/generate-pdf-task.js +1 -0
- package/dist/webhook/tasks/index.d.ts +13 -0
- package/dist/webhook/tasks/index.js +1 -0
- package/dist/webhook/tasks/publish-revision-chunks-staged-task.d.ts +73 -0
- package/dist/webhook/tasks/publish-revision-chunks-staged-task.js +1 -0
- package/dist/webhook/tasks/publish-revision-chunks-task.d.ts +76 -0
- package/dist/webhook/tasks/publish-revision-chunks-task.js +1 -0
- package/dist/webhook/tasks/publish-revision-task.d.ts +38 -0
- package/dist/webhook/tasks/publish-revision-task.js +1 -0
- package/dist/webhook/tasks/send-email-task.d.ts +129 -0
- package/dist/webhook/tasks/send-email-task.js +1 -0
- package/dist/webhook/tasks/send-http-task.d.ts +27 -0
- package/dist/webhook/tasks/send-http-task.js +1 -0
- package/dist/webhook/tasks/woocommerce-add-to-cart-task.d.ts +91 -0
- package/dist/webhook/tasks/woocommerce-add-to-cart-task.js +1 -0
- package/dist/webhook/webhook-payload.d.ts +56 -0
- package/dist/webhook/webhook-payload.js +1 -0
- package/package.json +84 -3
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,419 @@
|
|
|
1
|
+
# Change Log
|
|
2
|
+
|
|
3
|
+
All notable changes to the @salsita-ai/contracts package will be documented in this file.
|
|
4
|
+
|
|
5
|
+
## [0.48.0]
|
|
6
|
+
|
|
7
|
+
change!: remove the process-local `ClerkBackendApiClient.fetchUserCached()` method (CON-2556, CON-2685)
|
|
8
|
+
|
|
9
|
+
**Migration:** replace `fetchUserCached(userId, tenantId)` with `fetchUser(userId)`. Applications that need caching should provide a shared, caller-owned cache appropriate for their runtime.
|
|
10
|
+
|
|
11
|
+
feat: add deployment source metadata
|
|
12
|
+
|
|
13
|
+
Deployment contracts now expose the readable project ref and resolved commit SHA, with null defaults for legacy creation paths.
|
|
14
|
+
|
|
15
|
+
change!: add explicit normal, transient, and development environment types
|
|
16
|
+
|
|
17
|
+
Migration:
|
|
18
|
+
|
|
19
|
+
- Replace the `transient` argument to `Environment.create()` with `type: EnvironmentType.Normal` or
|
|
20
|
+
`type: EnvironmentType.Transient`. Keep passing `localConfig` for both types.
|
|
21
|
+
- To create a development environment, pass `type: EnvironmentType.Development` and
|
|
22
|
+
`developmentConfig` with its public and private buckets instead of `localConfig`.
|
|
23
|
+
- Add `type` to manually constructed `Environment` and `NewEnvironment` values, keeping the legacy
|
|
24
|
+
`transient` field consistent with it.
|
|
25
|
+
|
|
26
|
+
feat: add the `DevelopmentKey` branded type and `createDevelopmentKey` factory to the environment domain
|
|
27
|
+
|
|
28
|
+
The development-environment key format `dev_<project-slug>_<environment-slug>_<random>` is owned by the domain; the server supplies the random part.
|
|
29
|
+
|
|
30
|
+
feat: bind webhook base URLs in the HTTP transport
|
|
31
|
+
|
|
32
|
+
WebhookClient accepts a transport that consumes relative operation routes. Use createUrlWebhookHttpClient to bind a destination URL; the existing URL constructor remains available as a deprecated compatibility overload.
|
|
33
|
+
|
|
34
|
+
feat: add webhook tunnel wire contracts and support relative webhook routes
|
|
35
|
+
|
|
36
|
+
Webhook contracts now describe tunneled request polling and responses, while webhook clients can use relative operation routes when development deployments have no stored webhook URL.
|
|
37
|
+
|
|
38
|
+
fix: allow explicit `null` Blender material texture-map overrides so render workers can distinguish removal from omission
|
|
39
|
+
|
|
40
|
+
fix: carry the optional `transparent` flag in Blender material overrides so workers can match Three.js opacity behavior
|
|
41
|
+
|
|
42
|
+
feat: add JWKS-based Clerk session-token verification for auth webhooks, including issuer, expiry, required session claims, and authorized deployment-origin checks
|
|
43
|
+
|
|
44
|
+
chore: build and type-check with the TypeScript 7 native compiler
|
|
45
|
+
|
|
46
|
+
chore: resolve all pnpm audit findings (CON-2655)
|
|
47
|
+
|
|
48
|
+
Bump the vite devDependency to 6.4.3 as part of bringing `pnpm audit` to zero findings workspace-wide.
|
|
49
|
+
|
|
50
|
+
fix: allow custom environment variables to override system and generated active values
|
|
51
|
+
|
|
52
|
+
fix: export the shared `PdfUnitValue` type and `PdfUnitValueSchema`
|
|
53
|
+
|
|
54
|
+
Finalize worker job contracts can now reuse the same unit-bearing PDF values accepted by `GeneratePdfTask` and `GenerateStaticPdfTask`.
|
|
55
|
+
|
|
56
|
+
fix: add backward-compatible staged revision-chunk webhook contracts
|
|
57
|
+
|
|
58
|
+
Servers can offer a private staging upload URL, and current SDK webhooks can return a lightweight publication task while older inline chunk tasks remain supported.
|
|
59
|
+
|
|
60
|
+
feat: support protected project Lambda webhooks
|
|
61
|
+
|
|
62
|
+
Webhook calls can now use authenticated access without changing existing project integrations or local development.
|
|
63
|
+
|
|
64
|
+
## [0.47.0]
|
|
65
|
+
|
|
66
|
+
### 2026-07-22 commit f58f411f3 PR #1602
|
|
67
|
+
|
|
68
|
+
feat: `GeneratePdfTask`/`GenerateStaticPdfTask` margin and header/footer height accept strings with unit suffix (`px`/`cm`/`mm`/`in`/`pt`) in addition to numbers (px)
|
|
69
|
+
|
|
70
|
+
## [0.46.0]
|
|
71
|
+
|
|
72
|
+
### 2026-06-09 commit 1f03b862b PR #1635
|
|
73
|
+
|
|
74
|
+
fix: add SharePoint tenant domain to site config
|
|
75
|
+
|
|
76
|
+
### 2026-06-09 commit 48bfcfe65 PR #1636
|
|
77
|
+
|
|
78
|
+
fix: stop preserving stale active environment variables
|
|
79
|
+
|
|
80
|
+
### 2026-06-08 commit be12ba53d PR #1633
|
|
81
|
+
|
|
82
|
+
fix: skip unsupported Microsoft Excel data validation API
|
|
83
|
+
|
|
84
|
+
## [0.45.0]
|
|
85
|
+
|
|
86
|
+
### 2026-06-02 commit 525a87f9b PR #1609
|
|
87
|
+
|
|
88
|
+
chore: bump vitest 3.2.4 → 4.1.7 to clear critical advisory
|
|
89
|
+
|
|
90
|
+
Clears critical advisory GHSA-5xrq-8626-4rwp (vitest <4.1.0: arbitrary file read/exec when Vitest UI server listening).
|
|
91
|
+
|
|
92
|
+
### 2026-06-02 commit 78215678b PR #1596
|
|
93
|
+
|
|
94
|
+
chore: add `vite` 5.4.21 as direct devDep
|
|
95
|
+
|
|
96
|
+
Promotes vitest's transitive vite to a pinned devDep so it uses the patched version.
|
|
97
|
+
|
|
98
|
+
### 2026-06-02 commit c1a67bb99 PR #1593
|
|
99
|
+
|
|
100
|
+
chore: align vitest 3.2.1 → 3.2.4
|
|
101
|
+
|
|
102
|
+
### 2026-06-01 commit 75664ca05 PR #1583
|
|
103
|
+
|
|
104
|
+
chore: bump ajv 8.17.1 → 8.20.0 (ReDoS in <8.18.0)
|
|
105
|
+
|
|
106
|
+
### 2026-06-01 commit dd378335f PR #1582
|
|
107
|
+
|
|
108
|
+
chore: bump @lingui/core 4.11.3 → 5.9.5
|
|
109
|
+
|
|
110
|
+
See `@salsita-ai/platform-project-sdk` changelog for the lingui 4 → 5 migration guide.
|
|
111
|
+
|
|
112
|
+
### 2026-06-01 commit eba73549e PR #1581
|
|
113
|
+
|
|
114
|
+
chore: bump @swc/core 1.4.2 → 1.7.28, @swc/cli 0.3.10 → 0.7.10
|
|
115
|
+
|
|
116
|
+
### 2026-06-01 commit fabe5ce58 PR #1580
|
|
117
|
+
|
|
118
|
+
chore: bump typescript 5.7.2 → 5.9.3
|
|
119
|
+
|
|
120
|
+
### 2026-06-01 commit 868ced09c PR #1572
|
|
121
|
+
|
|
122
|
+
chore: drop unused chokidar dep; bump prettier 3.2.5 → 3.8.3
|
|
123
|
+
|
|
124
|
+
### 2026-06-01 commit 868ced09c PR #1572
|
|
125
|
+
|
|
126
|
+
chore: bump openai 4.53.0 → 6.38.0; dropped `openai/core.mjs` Response import (use SDK return type); relocated `openai/uploads.mjs` → `openai/core/uploads`; narrowed `createCompletionTool` return + `ChatToolCalls.tool_calls` + `processToolCalls`/`createAssistantMessage` to function-tool variant (v6 split tool calls into function + custom union); switched `createTranscription` param type to the non-streaming overload
|
|
127
|
+
|
|
128
|
+
### 2026-06-01 commit fdd0ae84c PR #1570
|
|
129
|
+
|
|
130
|
+
chore: dep updates
|
|
131
|
+
|
|
132
|
+
- `http-errors` 2.0.0 → 2.0.1, `@types/http-errors` 2.0.0 → 2.0.5
|
|
133
|
+
- `ts-pattern` 5.1.2 → 5.9.0
|
|
134
|
+
- `jose` 5.2.1 → 6.2.3
|
|
135
|
+
- `lodash-es` 4.17.21 → 4.18.1 (CVE-2026-4800, CVE-2026-2950, CVE-2025-13465)
|
|
136
|
+
- `uuid` 9.0.1 → 14.0.0, dropped `@types/uuid` (types ship with uuid since v11)
|
|
137
|
+
|
|
138
|
+
### 2026-05-27 commit 10b52f456 PR #1532
|
|
139
|
+
|
|
140
|
+
- feat: Excel SpreadsheetAdapter implementation
|
|
141
|
+
|
|
142
|
+
Full Microsoft Excel adapter with parity to Google: create workbook,
|
|
143
|
+
list files, fetch / reset data. Powers the connected-data flow for
|
|
144
|
+
SharePoint-hosted workbooks.
|
|
145
|
+
|
|
146
|
+
Excel and Google adapters also behave identically on error reporting,
|
|
147
|
+
cell-value coercion on write, and in-sheet data validation (dropdowns
|
|
148
|
+
/ list locks). Connected-data UX is provider-agnostic.
|
|
149
|
+
|
|
150
|
+
### 2026-05-18 commit 53f48433c PR #1546
|
|
151
|
+
|
|
152
|
+
feat: optional `replyTo` on `SendEmailTask` — recipients see it in the Reply-To header; falls back to `from` when unset
|
|
153
|
+
|
|
154
|
+
## [0.44.0]
|
|
155
|
+
|
|
156
|
+
### 2026-04-13 commit df99c3334 PR #1486
|
|
157
|
+
|
|
158
|
+
change!: `GenerateImagesTask.images[].camera` is now optional — omit it to use the Blender template's own camera instead of a programmatic look-at camera
|
|
159
|
+
|
|
160
|
+
**Migration:** existing webhook handlers that always provide `camera` are unaffected. If you relied on the type requiring `camera`, add an explicit `camera` field or update your type expectations.
|
|
161
|
+
|
|
162
|
+
feat: extend `GenerateImagesTask` with `renderSettings` (task-level and per-image), `lights`, extended `camera` fields (`dof`, `sensorWidth`, `clipStart`, `clipEnd`, `fov`), and `scale` on `DefaultRenderedEntity`
|
|
163
|
+
|
|
164
|
+
feat: add `BlenderRenderSettings`, `BlenderLight`, `BlenderCameraDof`, `BlenderMaterialOverride` types and `BlenderMaterialOverrideSchema` Zod schema — material overrides expanded from color+baseMaterial to full PBR (textures, opacity, clearcoat, sheen, transmission, anisotropy, etc.)
|
|
165
|
+
|
|
166
|
+
## [0.43.0]
|
|
167
|
+
|
|
168
|
+
### 2026-03-27 commit adf02f34c PR #1395
|
|
169
|
+
|
|
170
|
+
feat: add image render tracking domain with configurable per-environment limits
|
|
171
|
+
|
|
172
|
+
feat: add `imageRenderLimitEnabled` customer feature flag
|
|
173
|
+
|
|
174
|
+
## [0.42.0]
|
|
175
|
+
|
|
176
|
+
- Empty
|
|
177
|
+
|
|
178
|
+
## [0.41.0]
|
|
179
|
+
|
|
180
|
+
- feat: add `connectedProvidersEnabled` to `Customer` interface and `updateBasicInfo`
|
|
181
|
+
|
|
182
|
+
- feat: add `OAuthConnection` domain types (`OAuthConnectionId`, `OAuthConnectionProvider`, `OAuthRefreshToken`, `OAuthGrantedScopes`)
|
|
183
|
+
|
|
184
|
+
- feat: add `connectedProviderAccessTokens` optional field to `FinalizeWebhookPayload`
|
|
185
|
+
|
|
186
|
+
- feat: add Google Sheets client utilities (`fetchSpreadsheetMeta`, `fetchTabHeaders`, `fetchSheetData`)
|
|
187
|
+
|
|
188
|
+
- feat: add `releaseToProductionEnabled` to `Customer` interface and `updateBasicInfo`
|
|
189
|
+
|
|
190
|
+
- feat: add `applicationVersion` and `publishedDataHash` to `Deployment`, `NewDeployment`, `CreateDeploymentData`
|
|
191
|
+
|
|
192
|
+
- feat: export `PRODUCTION_ENVIRONMENT_SLUG` constant
|
|
193
|
+
|
|
194
|
+
- feat: add `publishedDataHash` field to `ChunkedPublishedDataRevision` and `PublishRevisionChunksTask`
|
|
195
|
+
|
|
196
|
+
- feat: add configurable `serverKey` and `baseDomain` params to environment domain functions (`getPublicS3Bucket`, `getPrivateS3Bucket`, `getServiceName`, `getActiveVariables`, `getLocalActiveVariables`)
|
|
197
|
+
|
|
198
|
+
- feat: store `publicS3Bucket`, `privateS3Bucket`, `serviceName` on `Environment` and `NewEnvironment` interfaces
|
|
199
|
+
|
|
200
|
+
- change!: `Environment.create()` now requires `serverKey` param to compute resource names at creation time
|
|
201
|
+
|
|
202
|
+
- change!: `getActiveVariables` no longer accepts `serverKey` — reads stored values from environment
|
|
203
|
+
|
|
204
|
+
- change!: `getLocalActiveVariables` no longer accepts `serverKey` — reads `serviceName` from environment
|
|
205
|
+
|
|
206
|
+
- change!: rename `getPublicS3Bucket` → `computePublicS3Bucket`, `getPrivateS3Bucket` → `computePrivateS3Bucket`, `getServiceName` → `computeServiceName`
|
|
207
|
+
|
|
208
|
+
## [0.40.0]
|
|
209
|
+
|
|
210
|
+
- feat: add support for order/email attachments in WooCommerceAddToCartTask. It is now possible to include images, PDFs and CSVs with the cart item. These resources are copied to WordPress instance's media library and referenced by the cart, order and order email.
|
|
211
|
+
- fix: rendering of WooCommerce cart item custom description.
|
|
212
|
+
|
|
213
|
+
## [0.39.0]
|
|
214
|
+
|
|
215
|
+
- feat: add chunked published data revision domain types (`ChunkedPublishedDataRevision`, `PublishedDataRevisionKind`, `ChunkKey`, `ChunkScope`)
|
|
216
|
+
|
|
217
|
+
- feat: add `PublishRevisionChunks` task type and `PublishRevisionChunksTask` webhook task
|
|
218
|
+
|
|
219
|
+
- feat: add `scopes` field to session token contract
|
|
220
|
+
|
|
221
|
+
- feat: add `configurationPreviewEnabled` to `Customer` interface for controlling configuration preview in Studio
|
|
222
|
+
|
|
223
|
+
- feat: add `integratedAdminEnabled` to `Customer` interface for controlling admin panel visibility in Studio
|
|
224
|
+
|
|
225
|
+
- feat: add `configurationPreviewEnabled` to `Customer` interface for controlling configuration preview in Studio
|
|
226
|
+
|
|
227
|
+
## [0.38.0]
|
|
228
|
+
|
|
229
|
+
- feat: add `configurationListEnabled` field to `Customer` domain
|
|
230
|
+
|
|
231
|
+
- feat: add `activityAnalyticsEnabled` field to `Customer` domain
|
|
232
|
+
|
|
233
|
+
- feat: add `activityAnalyticsEnabled` field to `Customer` domain
|
|
234
|
+
|
|
235
|
+
## [0.38.0]
|
|
236
|
+
|
|
237
|
+
- feat: add support for custom fees to WooCommerceAddToCartTask
|
|
238
|
+
|
|
239
|
+
## [0.37.0]
|
|
240
|
+
|
|
241
|
+
- feat: add customData field to WooCommerceAddToCartItem for passing custom data (e.g., shipping info, dimensions) stored in WooCommerce cart with 'salsita\_' prefix
|
|
242
|
+
|
|
243
|
+
## [0.36.0]
|
|
244
|
+
|
|
245
|
+
- Empty
|
|
246
|
+
|
|
247
|
+
## [0.35.0]
|
|
248
|
+
|
|
249
|
+
- Empty
|
|
250
|
+
|
|
251
|
+
## [0.34.0]
|
|
252
|
+
|
|
253
|
+
- Empty
|
|
254
|
+
|
|
255
|
+
## [0.33.0]
|
|
256
|
+
|
|
257
|
+
- Empty
|
|
258
|
+
|
|
259
|
+
## [0.32.0]
|
|
260
|
+
|
|
261
|
+
- feat: add support for "base64"" attachment type in webhook email task - can be used for sending custom attachments
|
|
262
|
+
|
|
263
|
+
## [0.31.0]
|
|
264
|
+
|
|
265
|
+
- Empty
|
|
266
|
+
|
|
267
|
+
## [0.30.0]
|
|
268
|
+
|
|
269
|
+
- Empty
|
|
270
|
+
|
|
271
|
+
## [0.29.0]
|
|
272
|
+
|
|
273
|
+
- feat: Introduce `BackendData` for data collected on... wait for it... backend, which is fed to the domain both in FE and webhooks
|
|
274
|
+
|
|
275
|
+
## [0.28.0]
|
|
276
|
+
|
|
277
|
+
- change!: `SessionTokenPayload`'s data are now required field
|
|
278
|
+
|
|
279
|
+
- feat: `SessionRole`, `SessionTokenPayload` and `AccessTokenPayload` are now provided from contracts
|
|
280
|
+
|
|
281
|
+
## [0.27.0]
|
|
282
|
+
|
|
283
|
+
- feat: add Clerk backend API client and Clerk authorization webhook
|
|
284
|
+
|
|
285
|
+
## [0.26.0]
|
|
286
|
+
|
|
287
|
+
- Empty
|
|
288
|
+
|
|
289
|
+
## [0.25.0]
|
|
290
|
+
|
|
291
|
+
- Empty
|
|
292
|
+
|
|
293
|
+
## [0.24.0]
|
|
294
|
+
|
|
295
|
+
- Empty
|
|
296
|
+
|
|
297
|
+
## [0.23.0]
|
|
298
|
+
|
|
299
|
+
- Empty
|
|
300
|
+
|
|
301
|
+
## [0.22.0] (2025-1-29)
|
|
302
|
+
|
|
303
|
+
- feat: all webhook types (resource, tasks, payload, etc...) and validation functions are now available for consumption by project-sdk and possibly projects
|
|
304
|
+
|
|
305
|
+
- feat: `AccessLevel`, `SessionRole` and all domain types are now available for consumption
|
|
306
|
+
|
|
307
|
+
## [0.21.0] (2025-1-22)
|
|
308
|
+
|
|
309
|
+
- Empty
|
|
310
|
+
|
|
311
|
+
## [0.20.0] (2025-1-15)
|
|
312
|
+
|
|
313
|
+
- Empty
|
|
314
|
+
|
|
315
|
+
## [0.19.0] (2025-1-8)
|
|
316
|
+
|
|
317
|
+
- Empty
|
|
318
|
+
|
|
319
|
+
## [0.18.2] (2025-1-7)
|
|
320
|
+
|
|
321
|
+
- Empty
|
|
322
|
+
|
|
323
|
+
## [0.18.1] (2025-1-7)
|
|
324
|
+
|
|
325
|
+
- Empty
|
|
326
|
+
|
|
327
|
+
## [0.18.0] (2025-1-7)
|
|
328
|
+
|
|
329
|
+
- change!: original chat-sdk package is now available under /chat import path
|
|
330
|
+
|
|
331
|
+
## [0.17.0] (2024-12-18)
|
|
332
|
+
|
|
333
|
+
- Empty
|
|
334
|
+
|
|
335
|
+
## [0.16.0] (2024-11-26)
|
|
336
|
+
|
|
337
|
+
- Empty
|
|
338
|
+
|
|
339
|
+
## [0.15.0] (2024-11-19)
|
|
340
|
+
|
|
341
|
+
- Empty
|
|
342
|
+
|
|
343
|
+
## [0.14.0] (2024-11-15)
|
|
344
|
+
|
|
345
|
+
- Empty
|
|
346
|
+
|
|
347
|
+
## [0.13.0] (2024-11-7)
|
|
348
|
+
|
|
349
|
+
- Empty
|
|
350
|
+
|
|
351
|
+
## [0.12.0] (2024-11-5)
|
|
352
|
+
|
|
353
|
+
- Empty
|
|
354
|
+
|
|
355
|
+
## [0.11.0] (2024-10-25)
|
|
356
|
+
|
|
357
|
+
- Empty
|
|
358
|
+
|
|
359
|
+
## [0.10.0] (2024-10-22)
|
|
360
|
+
|
|
361
|
+
- Empty
|
|
362
|
+
|
|
363
|
+
## [0.9.0] (2024-10-16)
|
|
364
|
+
|
|
365
|
+
- Empty
|
|
366
|
+
|
|
367
|
+
## [0.8.0] (2024-10-10)
|
|
368
|
+
|
|
369
|
+
- Empty
|
|
370
|
+
|
|
371
|
+
## [0.7.0] (2024-10-9)
|
|
372
|
+
|
|
373
|
+
- Empty
|
|
374
|
+
|
|
375
|
+
## [0.6.0] (2024-10-2)
|
|
376
|
+
|
|
377
|
+
- Empty
|
|
378
|
+
|
|
379
|
+
## [0.5.0] (2024-9-27)
|
|
380
|
+
|
|
381
|
+
### Bug Fixes
|
|
382
|
+
|
|
383
|
+
- None
|
|
384
|
+
|
|
385
|
+
### Features
|
|
386
|
+
|
|
387
|
+
- None
|
|
388
|
+
|
|
389
|
+
## [0.4.0] (2024-9-23)
|
|
390
|
+
|
|
391
|
+
### Bug Fixes
|
|
392
|
+
|
|
393
|
+
- None
|
|
394
|
+
|
|
395
|
+
### Features
|
|
396
|
+
|
|
397
|
+
- Providing .d.ts files for the published build
|
|
398
|
+
|
|
399
|
+
## [0.3.0] (2024-9-20)
|
|
400
|
+
|
|
401
|
+
### Bug Fixes
|
|
402
|
+
|
|
403
|
+
- None
|
|
404
|
+
|
|
405
|
+
### Features
|
|
406
|
+
|
|
407
|
+
- None
|
|
408
|
+
|
|
409
|
+
## 0.2.0 (2024-9-4)
|
|
410
|
+
|
|
411
|
+
Initial testing release
|
|
412
|
+
|
|
413
|
+
## 0.1.0 (2024-9-3)
|
|
414
|
+
|
|
415
|
+
Initial testing release
|
|
416
|
+
|
|
417
|
+
## 0.0.1 (2024-8-12)
|
|
418
|
+
|
|
419
|
+
Initial testing release
|
package/LICENSE
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
Salsita SDK License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Salsita s.r.o. All rights reserved.
|
|
4
|
+
|
|
5
|
+
This software and its associated documentation (the "Software") are
|
|
6
|
+
proprietary to Salsita s.r.o., Štefánikova 18/25, 150 00 Prague 5,
|
|
7
|
+
Czech Republic, Company ID 272 04 201 ("Salsita"). The Software is
|
|
8
|
+
licensed, not sold. By installing, copying or using the Software you
|
|
9
|
+
agree to this license and to the Salsita SDK Terms at
|
|
10
|
+
https://salsita.ai/terms (the "Terms"). If you do not agree,
|
|
11
|
+
do not use the Software.
|
|
12
|
+
|
|
13
|
+
1. License grant
|
|
14
|
+
Subject to this license and the Terms, Salsita grants you a limited,
|
|
15
|
+
non-exclusive, non-transferable, non-sublicensable, revocable license to:
|
|
16
|
+
(a) install and use the Software to develop, test and evaluate
|
|
17
|
+
applications built for the Salsita platform; and
|
|
18
|
+
(b) use the Software in production, and distribute it in compiled form
|
|
19
|
+
as part of such applications, only while you hold an active
|
|
20
|
+
Salsita account in good standing.
|
|
21
|
+
|
|
22
|
+
2. Restrictions
|
|
23
|
+
Except as expressly permitted above or by applicable law, you may not:
|
|
24
|
+
(a) redistribute, sublicense, sell, rent or lease the Software, or make
|
|
25
|
+
it available to third parties as a standalone product;
|
|
26
|
+
(b) modify, translate or create derivative works of the Software;
|
|
27
|
+
(c) reverse engineer, decompile or disassemble the Software, or attempt
|
|
28
|
+
to derive its source code;
|
|
29
|
+
(d) use the Software with, or to build, a product or service that
|
|
30
|
+
competes with or replaces the Salsita platform;
|
|
31
|
+
(e) remove or alter any copyright, trademark or licence notice.
|
|
32
|
+
|
|
33
|
+
3. Ownership
|
|
34
|
+
Salsita and its licensors retain all right, title and interest in the
|
|
35
|
+
Software, including all intellectual property rights. No rights are
|
|
36
|
+
granted except those expressly stated in this license.
|
|
37
|
+
|
|
38
|
+
4. Third-party components
|
|
39
|
+
The Software may include third-party components distributed under their
|
|
40
|
+
own licences. Those licences govern your use of those components.
|
|
41
|
+
|
|
42
|
+
5. Termination
|
|
43
|
+
This license ends automatically if you breach it or if your account is
|
|
44
|
+
closed. On termination you must stop using the Software and delete all
|
|
45
|
+
copies in your possession. Sections 2, 3, 6 and 7 survive termination.
|
|
46
|
+
|
|
47
|
+
6. Disclaimer of warranty
|
|
48
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
|
49
|
+
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
50
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
|
|
51
|
+
|
|
52
|
+
7. Limitation of liability
|
|
53
|
+
TO THE MAXIMUM EXTENT PERMITTED BY LAW, SALSITA SHALL NOT BE LIABLE FOR
|
|
54
|
+
ANY INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL OR PUNITIVE DAMAGES, OR
|
|
55
|
+
FOR ANY LOSS OF PROFITS, REVENUE OR DATA, ARISING OUT OF OR RELATED TO
|
|
56
|
+
THE SOFTWARE, WHETHER IN CONTRACT, TORT OR OTHERWISE.
|
|
57
|
+
|
|
58
|
+
8. Terms
|
|
59
|
+
The Terms supplement this license. If the Terms and this license
|
|
60
|
+
conflict, the Terms prevail. If you have a separate signed agreement
|
|
61
|
+
with Salsita covering the Software, that agreement prevails over both.
|
package/README.md
CHANGED
|
@@ -1,3 +1,29 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @salsita-ai/contracts
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Shared TypeScript types and runtime schemas of the Salsita platform: the data that crosses the boundary between a configurator project, its webhooks, the API server and Studio.
|
|
4
|
+
|
|
5
|
+
A project on the application-spec pipeline does not install this package itself: `@salsita-ai/sdk` depends on it and re-exports every entry point, so the project imports it through the SDK. Projects in the legacy format still declare it directly and import it by its own name; both paths resolve to the same code.
|
|
6
|
+
|
|
7
|
+
```ts
|
|
8
|
+
import { DeploymentId, ProjectSlug } from '@salsita-ai/sdk/contracts/domain'
|
|
9
|
+
import type { CallbackPayload } from '@salsita-ai/sdk/contracts/webhook'
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Entry points
|
|
13
|
+
|
|
14
|
+
There is no package-root export. Import from the path that owns the boundary; the exact paths are declared in `package.json`.
|
|
15
|
+
|
|
16
|
+
| Entry point | Boundary it defines |
|
|
17
|
+
| ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
18
|
+
| `api` | API access levels, session roles, and access and session token payloads. |
|
|
19
|
+
| `clerk` | Clerk backend client and services and the shared user, invitation, role, and token schemas. |
|
|
20
|
+
| `domain` | Branded deployment, customer, project, environment, configuration, and revision data: types, schemas, constructors, and the state values clients compare against. |
|
|
21
|
+
| `chat` | Chat completion and stream chunks, tool definitions, validation, speech, and embeddings. |
|
|
22
|
+
| `assistant` | Experimental assistant: shared client-tool definitions and user-message metadata. |
|
|
23
|
+
| `webhook` | Webhook clients and building blocks, finalization tasks and resources, spreadsheet adapters. |
|
|
24
|
+
|
|
25
|
+
Runtime schemas and TypeScript types are kept aligned, so a value that passes the schema has the declared type.
|
|
26
|
+
|
|
27
|
+
## Licence
|
|
28
|
+
|
|
29
|
+
Proprietary software of Salsita s.r.o., published under the Salsita SDK License (the `LICENSE` file in this package) and the terms at https://salsita.ai/terms. The published package contains minified code without source maps.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const AccessLevel={Owner:"o",ReadRevision:"rr",Read:"r"};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{AccessLevel}from"./access-level.js";export{SessionRole}from"./session-role.js";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ValueOf } from '@salsita-ai/common/utils';
|
|
2
|
+
export declare const SessionRole: {
|
|
3
|
+
readonly Anonymous: 'anonymous';
|
|
4
|
+
readonly User: 'user';
|
|
5
|
+
readonly Admin: 'admin';
|
|
6
|
+
readonly SuperAdmin: 'superadmin';
|
|
7
|
+
};
|
|
8
|
+
export type SessionRole = ValueOf<typeof SessionRole>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const SessionRole={Anonymous:"anonymous",User:"user",Admin:"admin",SuperAdmin:"superadmin"};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { AllowedOrigin, ApplicationType, ChunkScope, ConfigurationSchemaId, DeploymentId, EnvironmentId } from '../domain/index.js';
|
|
2
|
+
import type { SessionRole } from './session-role.js';
|
|
3
|
+
export interface SessionTokenPayload<T extends Record<string, unknown>> {
|
|
4
|
+
readonly deploymentId: DeploymentId;
|
|
5
|
+
readonly applicationType: ApplicationType;
|
|
6
|
+
readonly publishedAdminRevisionPath?: string;
|
|
7
|
+
readonly environmentId: EnvironmentId;
|
|
8
|
+
readonly configurationSchemaId: ConfigurationSchemaId;
|
|
9
|
+
readonly role: SessionRole;
|
|
10
|
+
readonly chunkScopes?: readonly ChunkScope[];
|
|
11
|
+
/**
|
|
12
|
+
* The user the session belongs to, namespaced by the server with its source: `clerk-<id>`, `custom-<id>`,
|
|
13
|
+
* `anonymous-<browser uuid>` or `studio-<id>`. Per-user data (assistant threads) is keyed on it. The prefix
|
|
14
|
+
* is applied only on the server, so a browser-supplied id can never pass as a signed-in user. Absent when
|
|
15
|
+
* neither the auth handler nor the frontend supplied an id (old SDKs without an auth hook user id).
|
|
16
|
+
*/
|
|
17
|
+
readonly sub?: string;
|
|
18
|
+
readonly origins: readonly AllowedOrigin[];
|
|
19
|
+
readonly data: T;
|
|
20
|
+
iat: number;
|
|
21
|
+
exp: number;
|
|
22
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Client-side tool of the assistant chat: the browser draws its own details (user agent, viewport,
|
|
3
|
+
* pixel ratio, language) onto a canvas and returns the capture as an image content part. It carries
|
|
4
|
+
* no domain meaning; it proves that a client tool result reaches the model as an image.
|
|
5
|
+
*
|
|
6
|
+
* The server passes the definition to the model without an implementation, so every call becomes a
|
|
7
|
+
* client-tool interrupt; the SDK registers the browser implementation via `.client()`.
|
|
8
|
+
*
|
|
9
|
+
* The input schema is plain JSON Schema because `@tanstack/ai` converts only schemas that expose
|
|
10
|
+
* `~standard.jsonSchema` (Zod 4.2+), which the workspace's Zod 3 does not.
|
|
11
|
+
*/
|
|
12
|
+
export declare const browserDetailsTool: import("@tanstack/ai").ToolDefinition<{
|
|
13
|
+
type: string;
|
|
14
|
+
properties: {};
|
|
15
|
+
required: never[];
|
|
16
|
+
}, undefined, "getBrowserDetails", false, undefined>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{toolDefinition as e}from"@tanstack/ai";export const browserDetailsTool=e({name:"getBrowserDetails",description:"Captures the user's browser details (user agent, viewport size, device pixel ratio, language) as an image.",inputSchema:{type:"object",properties:{},required:[]}});
|