@fleetless/contracts 15.5.0-next.1 → 15.5.0-next.2
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 +11 -0
- package/artifacts/openapi.json +2 -2
- package/artifacts/routes.json +5 -3
- package/dist/app-mail-html.d.ts +1 -1
- package/dist/errors.d.ts +1 -1
- package/dist/errors.js +18 -0
- package/dist/routes.js +8 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -32,6 +32,17 @@ version.
|
|
|
32
32
|
`app.logo_shape` (`square`, `wide` or null). Sixteen in all. A consumer
|
|
33
33
|
that checks a template against the list accepts them; one that typed
|
|
34
34
|
`html` as `null` reads a string.
|
|
35
|
+
- **The logo upload declares its 429 and 503**
|
|
36
|
+
(fleetless/fleetless#1155). `PUT /api/apps/:id/auth-config/logo` is
|
|
37
|
+
`rateLimited: true` and lists `rate_limited` and a new code,
|
|
38
|
+
`logo_draw_unavailable`. The cloud now draws each uploaded logo once into
|
|
39
|
+
the small picture the app's mails show; uploads are limited per
|
|
40
|
+
organization, five at once and then one a minute, answering
|
|
41
|
+
`429 rate_limited` with `retry_after_ms`. `logo_draw_unavailable` is `503`
|
|
42
|
+
when too many logos already wait to be drawn on the server or the drawing
|
|
43
|
+
itself fails: nothing was stored, the logo in place stays, retrying
|
|
44
|
+
shortly may work, and there is no details payload. A logo that cannot be
|
|
45
|
+
drawn because of its content stays `400 validation_error`.
|
|
35
46
|
|
|
36
47
|
## [15.4.0] — 2026-11-13
|
|
37
48
|
|
package/artifacts/openapi.json
CHANGED
|
@@ -3628,7 +3628,7 @@
|
|
|
3628
3628
|
}
|
|
3629
3629
|
},
|
|
3630
3630
|
"default": {
|
|
3631
|
-
"description": "An error envelope. Codes this route is known to answer: `unauthorized`, `token_expired`, `token_revoked`, `invalid_uuid`, `validation_error`, `not_found`, `unsupported_media_type`.",
|
|
3631
|
+
"description": "An error envelope. Codes this route is known to answer: `unauthorized`, `token_expired`, `token_revoked`, `invalid_uuid`, `validation_error`, `not_found`, `unsupported_media_type`, `rate_limited`, `logo_draw_unavailable`.",
|
|
3632
3632
|
"content": {
|
|
3633
3633
|
"application/json": {
|
|
3634
3634
|
"schema": {
|
|
@@ -3638,7 +3638,7 @@
|
|
|
3638
3638
|
}
|
|
3639
3639
|
}
|
|
3640
3640
|
},
|
|
3641
|
-
"description": "The body is the **raw image**, not JSON, so it has no request schema: `Content-Type` is one of `HOSTED_LOGO_TYPES` (`image/png`, `image/svg+xml`) and anything else is `415 unsupported_media_type`. At most `HOSTED_LOGO_MAX_BYTES` (512 KB); a larger body, or one that is not the image its type names, is `400 validation_error`. A new logo replaces the stored one. The hosted pages load it from `hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs."
|
|
3641
|
+
"description": "The body is the **raw image**, not JSON, so it has no request schema: `Content-Type` is one of `HOSTED_LOGO_TYPES` (`image/png`, `image/svg+xml`) and anything else is `415 unsupported_media_type`. At most `HOSTED_LOGO_MAX_BYTES` (512 KB); a larger body, or one that is not the image its type names, is `400 validation_error`. A new logo replaces the stored one. The hosted pages load it from `hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs. \n\n**Each upload is also drawn once**, into the small picture the app's mails show, and a logo that cannot be drawn is `400 validation_error`. Drawing costs the server, so uploads are limited per organization: five at once, then one a minute, answering `429 rate_limited` with `retry_after_ms`. When too many logos already wait to be drawn on the server, or the drawing itself fails, the answer is `503 logo_draw_unavailable`: nothing was stored, the logo in place stays, and retrying shortly may work."
|
|
3642
3642
|
},
|
|
3643
3643
|
"delete": {
|
|
3644
3644
|
"operationId": "delete_api_apps_id_auth_config_logo",
|
package/artifacts/routes.json
CHANGED
|
@@ -2010,7 +2010,7 @@
|
|
|
2010
2010
|
"summary": "Stores the logo the hosted pages show above the app's name.",
|
|
2011
2011
|
"audience": "developer",
|
|
2012
2012
|
"auth": "developer",
|
|
2013
|
-
"rateLimited":
|
|
2013
|
+
"rateLimited": true,
|
|
2014
2014
|
"ownerTier": false,
|
|
2015
2015
|
"status": 200,
|
|
2016
2016
|
"params": [
|
|
@@ -2029,10 +2029,12 @@
|
|
|
2029
2029
|
"invalid_uuid",
|
|
2030
2030
|
"validation_error",
|
|
2031
2031
|
"not_found",
|
|
2032
|
-
"unsupported_media_type"
|
|
2032
|
+
"unsupported_media_type",
|
|
2033
|
+
"rate_limited",
|
|
2034
|
+
"logo_draw_unavailable"
|
|
2033
2035
|
],
|
|
2034
2036
|
"transport": "http",
|
|
2035
|
-
"notes": "The body is the **raw image**, not JSON, so it has no request schema: `Content-Type` is one of `HOSTED_LOGO_TYPES` (`image/png`, `image/svg+xml`) and anything else is `415 unsupported_media_type`. At most `HOSTED_LOGO_MAX_BYTES` (512 KB); a larger body, or one that is not the image its type names, is `400 validation_error`. A new logo replaces the stored one. The hosted pages load it from `hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs."
|
|
2037
|
+
"notes": "The body is the **raw image**, not JSON, so it has no request schema: `Content-Type` is one of `HOSTED_LOGO_TYPES` (`image/png`, `image/svg+xml`) and anything else is `415 unsupported_media_type`. At most `HOSTED_LOGO_MAX_BYTES` (512 KB); a larger body, or one that is not the image its type names, is `400 validation_error`. A new logo replaces the stored one. The hosted pages load it from `hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs. \n\n**Each upload is also drawn once**, into the small picture the app's mails show, and a logo that cannot be drawn is `400 validation_error`. Drawing costs the server, so uploads are limited per organization: five at once, then one a minute, answering `429 rate_limited` with `retry_after_ms`. When too many logos already wait to be drawn on the server, or the drawing itself fails, the answer is `503 logo_draw_unavailable`: nothing was stored, the logo in place stays, and retrying shortly may work."
|
|
2036
2038
|
},
|
|
2037
2039
|
{
|
|
2038
2040
|
"method": "DELETE",
|
package/dist/app-mail-html.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* The default HTML of the four app mails, as the cloud's
|
|
6
6
|
* `scripts/print-app-mail-defaults.ts` prints it on cloud branch
|
|
7
7
|
* `feat/1155-mails-have-no-layout`,
|
|
8
|
-
*
|
|
8
|
+
* pull request fleetless/cloud#246.
|
|
9
9
|
* Written by `scripts/write-app-mail-html.ts`, which says how to regenerate
|
|
10
10
|
* it.
|
|
11
11
|
*
|
package/dist/errors.d.ts
CHANGED
|
@@ -304,5 +304,5 @@ export type RoleCycleDetails = z.infer<typeof roleCycleDetails>;
|
|
|
304
304
|
* list is the shared vocabulary, not a closed set, so a new refusal never
|
|
305
305
|
* needs a contracts release before it can be reported honestly.
|
|
306
306
|
*/
|
|
307
|
-
export declare const ERROR_CODES: readonly ["not_found", "validation_error", "bad_request", "unknown_datapoint", "invalid_token", "protocol_mismatch", "bridge_too_old", "invalid_frame", "duplicate_slug", "reserved_slug", "unknown_slug", "unknown_field_path", "unknown_type", "unknown_topic", "invalid_rate", "invalid_range", "config_conflict", "no_data", "robot_offline", "bridge_timeout", "unauthorized", "forbidden", "invalid_credentials", "token_expired", "token_revoked", "email_taken", "identifier_taken", "weak_password", "account_blocked", "busy", "parameter_invalid", "cancel_rejected", "job_lost", "operator_verified_stopped", "job_unknown_to_bridge", "action_server_lost", "action_failed", "goal_rejected", "goal_send_failed", "result_failed", "goal_uncontrollable", "bridge_disconnected", "config_changed", "publisher_busy", "unknown_command", "not_subscribable", "camera_offline", "no_snapshot_yet", "live_unavailable", "wrong_kind", "not_recorded", "not_aggregatable", "quota_exceeded", "credential_in_use", "goal_timeout", "robot_in_use", "robot_deletion_partial", "job_queue_full", "invalid_uuid", "rate_limited", "tier_required", "token_spent", "service_timeout", "asset_missing", "dynamic_registration_disabled", "client_limit_reached", "idp_unavailable", "mcp_disabled", "tool_not_available", "capability_required", "last_owner", "role_cycle", "role_key_taken", "confirmation_required", "target_state_conflict", "job_state_conflict", "signup_closed", "draft_not_a_document", "internal_error", "not_cancellable", "unsupported_media_type", "wrong_browser", "invalid_yaml", "unstorable_yaml", "registration_closed", "domain_not_allowed", "email_unverified", "origin_not_allowed", "template_invalid", "provider_disabled", "provider_misconfigured", "invalid_redirect_uri", "interaction_expired", "invalid_code", "method_not_allowed", "plan_limit", "plan_required", "org_locked", "file_too_large", "billing_unavailable", "legal_offer_unavailable", "payment_provider_unavailable", "history_migrating", "billing_documents_unavailable", "support_read_only", "support_forbidden", "record_referenced", "record_changed", "collection_not_found", "collection_removed", "reference_invalid", "required_missing", "robot_not_attached"];
|
|
307
|
+
export declare const ERROR_CODES: readonly ["not_found", "validation_error", "bad_request", "unknown_datapoint", "invalid_token", "protocol_mismatch", "bridge_too_old", "invalid_frame", "duplicate_slug", "reserved_slug", "unknown_slug", "unknown_field_path", "unknown_type", "unknown_topic", "invalid_rate", "invalid_range", "config_conflict", "no_data", "robot_offline", "bridge_timeout", "unauthorized", "forbidden", "invalid_credentials", "token_expired", "token_revoked", "email_taken", "identifier_taken", "weak_password", "account_blocked", "busy", "parameter_invalid", "cancel_rejected", "job_lost", "operator_verified_stopped", "job_unknown_to_bridge", "action_server_lost", "action_failed", "goal_rejected", "goal_send_failed", "result_failed", "goal_uncontrollable", "bridge_disconnected", "config_changed", "publisher_busy", "unknown_command", "not_subscribable", "camera_offline", "no_snapshot_yet", "live_unavailable", "wrong_kind", "not_recorded", "not_aggregatable", "quota_exceeded", "credential_in_use", "goal_timeout", "robot_in_use", "robot_deletion_partial", "job_queue_full", "invalid_uuid", "rate_limited", "tier_required", "token_spent", "service_timeout", "asset_missing", "dynamic_registration_disabled", "client_limit_reached", "idp_unavailable", "mcp_disabled", "tool_not_available", "capability_required", "last_owner", "role_cycle", "role_key_taken", "confirmation_required", "target_state_conflict", "job_state_conflict", "signup_closed", "draft_not_a_document", "internal_error", "not_cancellable", "unsupported_media_type", "wrong_browser", "invalid_yaml", "unstorable_yaml", "registration_closed", "domain_not_allowed", "email_unverified", "origin_not_allowed", "template_invalid", "provider_disabled", "provider_misconfigured", "invalid_redirect_uri", "interaction_expired", "invalid_code", "method_not_allowed", "plan_limit", "plan_required", "org_locked", "file_too_large", "billing_unavailable", "legal_offer_unavailable", "payment_provider_unavailable", "history_migrating", "billing_documents_unavailable", "support_read_only", "support_forbidden", "logo_draw_unavailable", "record_referenced", "record_changed", "collection_not_found", "collection_removed", "reference_invalid", "required_missing", "robot_not_attached"];
|
|
308
308
|
export type ErrorCode = (typeof ERROR_CODES)[number];
|
package/dist/errors.js
CHANGED
|
@@ -1212,6 +1212,24 @@ export const ERROR_CODES = [
|
|
|
1212
1212
|
* policy guard on the developer HTTP surface.
|
|
1213
1213
|
*/
|
|
1214
1214
|
'support_forbidden',
|
|
1215
|
+
// 2026-11-14 — a layout for every mail (fleetless/fleetless#1155). Before the
|
|
1216
|
+
// collections, whose codes a test holds to be the last of the list.
|
|
1217
|
+
/**
|
|
1218
|
+
* `503` from `PUT /api/apps/:id/auth-config/logo`: the cloud could not draw
|
|
1219
|
+
* the small picture of the logo that mails show, for a reason that is the
|
|
1220
|
+
* server's and not the file's. Either too many logos already wait to be
|
|
1221
|
+
* drawn on this server, or the drawing itself failed. Nothing was stored,
|
|
1222
|
+
* the logo in place stays, and retrying shortly may work. No details
|
|
1223
|
+
* payload.
|
|
1224
|
+
*
|
|
1225
|
+
* One code for both: the caller's remedy is the same, and which of the two
|
|
1226
|
+
* it was belongs in the server's log. A logo that cannot be drawn because
|
|
1227
|
+
* of what is in it is `400 validation_error`, never this. Not `busy`,
|
|
1228
|
+
* which is the command path's one-job-per-slug refusal with its
|
|
1229
|
+
* `busyDetails`; not `internal_error`, which is the `500` of a handler
|
|
1230
|
+
* that threw something unmapped.
|
|
1231
|
+
*/
|
|
1232
|
+
'logo_draw_unavailable',
|
|
1215
1233
|
// 2026-11-04 — app collections.
|
|
1216
1234
|
/**
|
|
1217
1235
|
* `409`: the record cannot be deleted, or an import cannot delete it,
|
package/dist/routes.js
CHANGED
|
@@ -1251,14 +1251,19 @@ export const ROUTES = [
|
|
|
1251
1251
|
{
|
|
1252
1252
|
method: 'PUT', path: '/api/apps/:id/auth-config/logo', section: 'apps',
|
|
1253
1253
|
summary: "Stores the logo the hosted pages show above the app's name.",
|
|
1254
|
-
audience: 'developer', auth: 'developer', rateLimited:
|
|
1254
|
+
audience: 'developer', auth: 'developer', rateLimited: true, ownerTier: false, status: 200,
|
|
1255
1255
|
params: [{ name: 'id', description: 'The app\'s uuid, as returned by `POST /api/apps` or listed by `GET /api/apps`.' }],
|
|
1256
1256
|
query: null, request: null, response: appAuthConfig,
|
|
1257
|
-
errors: [...DEVELOPER_GUARD, 'invalid_uuid', 'validation_error', 'not_found', 'unsupported_media_type'
|
|
1257
|
+
errors: [...DEVELOPER_GUARD, 'invalid_uuid', 'validation_error', 'not_found', 'unsupported_media_type', 'rate_limited', 'logo_draw_unavailable'],
|
|
1258
|
+
transport: 'http',
|
|
1258
1259
|
notes: 'The body is the **raw image**, not JSON, so it has no request schema: `Content-Type` is one of `HOSTED_LOGO_TYPES` (`image/png`, ' +
|
|
1259
1260
|
'`image/svg+xml`) and anything else is `415 unsupported_media_type`. At most `HOSTED_LOGO_MAX_BYTES` (512 KB); a larger body, or one ' +
|
|
1260
1261
|
'that is not the image its type names, is `400 validation_error`. A new logo replaces the stored one. The hosted pages load it from ' +
|
|
1261
|
-
'`hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs.'
|
|
1262
|
+
'`hosted_logo_url` as an image only, and the cloud serves an SVG sandboxed, so a script inside one never runs. \n\n**Each upload is ' +
|
|
1263
|
+
'also drawn once**, into the small picture the app\'s mails show, and a logo that cannot be drawn is `400 validation_error`. Drawing ' +
|
|
1264
|
+
'costs the server, so uploads are limited per organization: five at once, then one a minute, answering `429 rate_limited` with ' +
|
|
1265
|
+
'`retry_after_ms`. When too many logos already wait to be drawn on the server, or the drawing itself fails, the answer is ' +
|
|
1266
|
+
'`503 logo_draw_unavailable`: nothing was stored, the logo in place stays, and retrying shortly may work.',
|
|
1262
1267
|
},
|
|
1263
1268
|
{
|
|
1264
1269
|
method: 'DELETE', path: '/api/apps/:id/auth-config/logo', section: 'apps',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fleetless/contracts",
|
|
3
|
-
"version": "15.5.0-next.
|
|
3
|
+
"version": "15.5.0-next.2",
|
|
4
4
|
"description": "Fleetless wire contracts: the bridge-cloud protocol, the REST API schemas and the error codes, as zod schemas with generated JSON Schema and OpenAPI artifacts.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Dehne Robotik GmbH",
|