@canopy-io/node 0.24.0 → 0.24.1

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,11 @@
1
1
  # @canopy-io/node
2
2
 
3
+ ## 0.24.1
4
+
5
+ ### Patch Changes
6
+
7
+ - e895215: Follows Canopy's custom CSS release for hosted pages. The generated types add `custom_css` to the branding change and response, and to a web OAuth client's `branding`. The agent skill says what the CSS may name (the published `--hp-*` tokens and `hp-*` classes, `data-page` and `data-provider`), how to write the dark look, and what a save refuses. No caller changes are needed.
8
+
3
9
  ## 0.24.0
4
10
 
5
11
  ### Minor Changes
package/dist/index.d.cts CHANGED
@@ -3009,7 +3009,7 @@ interface paths {
3009
3009
  head?: never;
3010
3010
  /**
3011
3011
  * Change an Environment's branding
3012
- * @description Sets the Environment's branding. Every field is optional and stands on its own: send only what you want to change, send `null` to clear a field (the primary color then returns to the default blue). The product name shows in the browser tab, as the logo's alt text and in place of a missing logo; the logo shows at the top and the favicon in the tab; the primary color drives buttons and links, and the hover, link and focus shades are derived from it; the background color paints the page behind the card; the text and card colors set the card and what is written on it, with secondary text, lines and field borders derived from the pair; the color scheme chooses the light look, the dark look or whichever the visitor's device asks for, and the dark colors and dark logo describe the dark look, each with a default; the layout is one centred card or a split page with a panel beside the card, which holds a heading, a short text and an image; the background style paints the background color, a two-color gradient or an image behind the card; the corner radius rounds the card, its panels, fields and buttons together; the card style gives the card a border or none, and the card shadow sets the shadow under it; the body font sets the text and the heading font the headings, each a curated font from the fonts list or the https URL of a WOFF2 file, with the system font behind it; the support, terms and privacy links show as "Need help?", "Terms" and "Privacy" under every hosted page; `header_html`, `notice_html` and `footer_html` place your own content in a bar across the top of the page, above the card and under it, kept to links, paragraphs, bold, italics, line breaks, lists and images with https addresses, everything else being removed when it is saved, so the response shows what was kept; `text_overrides` rewords the hosted page texts the text keys list names, one text at a time. Returns `400` (`validation`) for a malformed value, and `403` (`plan_feature_unavailable`) when the request sets `color_scheme`, `logo_dark_url`, a dark color, `layout`, `background_style`, a gradient color, a background or panel image, `panel_heading`, `panel_text`, a text in `text_overrides`, `header_html`, `notice_html`, `footer_html`, `text_color`, `surface_color`, `corner_radius`, `card_style`, `card_shadow`, `heading_font` or `body_font` and the Account's plan does not include hosted page customization; clearing one with `null` is always allowed. Emits `environment.branding_updated`, which records the fields that changed.
3012
+ * @description Sets the Environment's branding. Every field is optional and stands on its own: send only what you want to change, send `null` to clear a field (the primary color then returns to the default blue). The product name shows in the browser tab, as the logo's alt text and in place of a missing logo; the logo shows at the top and the favicon in the tab; the primary color drives buttons and links, and the hover, link and focus shades are derived from it; the background color paints the page behind the card; the text and card colors set the card and what is written on it, with secondary text, lines and field borders derived from the pair; the color scheme chooses the light look, the dark look or whichever the visitor's device asks for, and the dark colors and dark logo describe the dark look, each with a default; the layout is one centred card or a split page with a panel beside the card, which holds a heading, a short text and an image; the background style paints the background color, a two-color gradient or an image behind the card; the corner radius rounds the card, its panels, fields and buttons together; the card style gives the card a border or none, and the card shadow sets the shadow under it; the body font sets the text and the heading font the headings, each a curated font from the fonts list or the https URL of a WOFF2 file, with the system font behind it; the support, terms and privacy links show as "Need help?", "Terms" and "Privacy" under every hosted page; `header_html`, `notice_html` and `footer_html` place your own content in a bar across the top of the page, above the card and under it, kept to links, paragraphs, bold, italics, line breaks, lists and images with https addresses, everything else being removed when it is saved, so the response shows what was kept; `text_overrides` rewords the hosted page texts the text keys list names, one text at a time; `custom_css` is your own CSS for hosted pages, applied after every other setting, which may set the published `--hp-*` tokens and style the published `hp-*` classes, and is refused when it loads a file from anywhere (`@import`, `@font-face`, `url()`), selects on a field's `value` or does not parse. Returns `400` (`validation`) for a malformed value, and `403` (`plan_feature_unavailable`) when the request sets `custom_css`, `color_scheme`, `logo_dark_url`, a dark color, `layout`, `background_style`, a gradient color, a background or panel image, `panel_heading`, `panel_text`, a text in `text_overrides`, `header_html`, `notice_html`, `footer_html`, `text_color`, `surface_color`, `corner_radius`, `card_style`, `card_shadow`, `heading_font` or `body_font` and the Account's plan does not include hosted page customization; clearing one with `null` is always allowed. Emits `environment.branding_updated`, which records the fields that changed.
3013
3013
  */
3014
3014
  patch: operations["ApiBrandingController_updateBranding"];
3015
3015
  trace?: never;
@@ -7239,6 +7239,7 @@ interface components {
7239
7239
  header_html: string | null;
7240
7240
  notice_html: string | null;
7241
7241
  footer_html: string | null;
7242
+ custom_css: string | null;
7242
7243
  /**
7243
7244
  * @description The customer's own wording for hosted page texts, by locale and then by the text's key. Empty where none is set.
7244
7245
  * @example {
@@ -7344,6 +7345,8 @@ interface components {
7344
7345
  notice_html: string | null;
7345
7346
  /** @description The content under the card, likewise. */
7346
7347
  footer_html: string | null;
7348
+ /** @description The customer's own CSS as hosted pages wear it, or null for none. Null on a plan without hosted page customization, whatever is stored. */
7349
+ custom_css: string | null;
7347
7350
  /** @description The wording the hosted pages show in place of their own, by locale and then by the text's key. Empty where none is set, and on a plan without hosted page customization. */
7348
7351
  text_overrides: {
7349
7352
  [key: string]: {
@@ -7523,6 +7526,12 @@ interface components {
7523
7526
  * @example <p>Need a hand? <a href="https://acme.example/help">Ask us</a>.</p>
7524
7527
  */
7525
7528
  footer_html?: string | null;
7529
+ /**
7530
+ * @description Your own CSS for hosted pages, applied after the settings: where it styles what a setting styles, the CSS wins, and everything else follows the settings. It may set the published `--hp-*` tokens and style the published `hp-*` classes; `[data-page]` on `<body>` names the page and `[data-provider]` a social sign-in button's provider. Write the dark look as `@media (prefers-color-scheme: dark)`: it follows `color_scheme`, so it always applies under `dark`, never under `light`, and by the device under `system`. Refused, with the line of each problem: `@import`, `@font-face`, `url()` and every other function that loads a file (set images and fonts with the branding fields), a selector on a field's `value`, the `--_hp-*` custom properties, `</`, and CSS that does not parse. It does not reach emails or the organization admin portal. Null removes it. Needs the `hosted_page_customization` plan feature to set.
7531
+ * @example :root { --hp-field-height: 52px; }
7532
+ * [data-page="register"] .hp-card { padding: 40px; }
7533
+ */
7534
+ custom_css?: string | null;
7526
7535
  /**
7527
7536
  * @description Your own wording for texts on hosted pages, by locale and then by the text's `key` from `GET /api/v1/branding/text-keys`. Each text set here replaces the stored wording, `null` returns that text to its default, and a text left out keeps what is stored; `null` for the whole value returns every text to its default. Wording is plain text without `<` or `>`, no longer than the text's `max_length`, and keeps each of the text's `placeholders` in double braces. A locale the pages are not written in, a key outside the list, or wording that breaks these rules is refused. Needs the `hosted_page_customization` plan feature to set.
7528
7537
  * @example {
@@ -31549,7 +31558,7 @@ interface operations {
31549
31558
  };
31550
31559
  };
31551
31560
  };
31552
- /** @description A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, and a heading or body font a curated font's id or an https URL; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
31561
+ /** @description A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, a heading or body font a curated font's id or an https URL, and `custom_css` CSS of at most 20,000 characters that parses, loads no file (`@import`, `@font-face`, `url()`), selects on no field's `value` and names no `--_hp-*` property or `</`; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
31553
31562
  400: {
31554
31563
  headers: {
31555
31564
  [name: string]: unknown;
@@ -31560,7 +31569,7 @@ interface operations {
31560
31569
  * "error": {
31561
31570
  * "statusCode": 400,
31562
31571
  * "code": "request.invalid",
31563
- * "message": "A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, and a heading or body font a curated font's id or an https URL; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
31572
+ * "message": "A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, a heading or body font a curated font's id or an https URL, and `custom_css` CSS of at most 20,000 characters that parses, loads no file (`@import`, `@font-face`, `url()`), selects on no field's `value` and names no `--_hp-*` property or `</`; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
31564
31573
  * "timestamp": "2026-04-20T12:00:00.000Z",
31565
31574
  * "path": "/api/v1/branding",
31566
31575
  * "method": "PATCH"
@@ -42520,7 +42529,7 @@ interface operations {
42520
42529
  };
42521
42530
  };
42522
42531
  };
42523
- /** @description The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
42532
+ /** @description The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`), or `branding` holds a value a branding change would refuse (`validation`) or is sent for a machine client (`oauth.machine_client_branding_invalid`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
42524
42533
  400: {
42525
42534
  headers: {
42526
42535
  [name: string]: unknown;
@@ -42531,7 +42540,7 @@ interface operations {
42531
42540
  * "error": {
42532
42541
  * "statusCode": 400,
42533
42542
  * "code": "request.invalid",
42534
- * "message": "The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
42543
+ * "message": "The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`), or `branding` holds a value a branding change would refuse (`validation`) or is sent for a machine client (`oauth.machine_client_branding_invalid`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
42535
42544
  * "timestamp": "2026-04-20T12:00:00.000Z",
42536
42545
  * "path": "/api/v1/oauth-clients/{id}",
42537
42546
  * "method": "PATCH"
@@ -42562,7 +42571,7 @@ interface operations {
42562
42571
  "application/json": components["schemas"]["ErrorResponseDto"];
42563
42572
  };
42564
42573
  };
42565
- /** @description The bearer token is not an admin or platform token, or the caller lacks the permission this operation checks: a scoped API key without that scope, an admin without the Account capability that covers it, or, for a node-scoped check, a node outside this Environment */
42574
+ /** @description The caller lacks `oauth_clients.manage`, or the request sets a `branding` value and the Account's plan does not include hosted page customization (`plan_feature_unavailable`) */
42566
42575
  403: {
42567
42576
  headers: {
42568
42577
  [name: string]: unknown;
@@ -42573,10 +42582,10 @@ interface operations {
42573
42582
  * "error": {
42574
42583
  * "statusCode": 403,
42575
42584
  * "code": "auth.forbidden",
42576
- * "message": "The bearer token is not an admin or platform token, or the caller lacks the permission this operation checks: a scoped API key without that scope, an admin without the Account capability that covers it, or, for a node-scoped check, a node outside this Environment",
42585
+ * "message": "The caller lacks `oauth_clients.manage`, or the request sets a `branding` value and the Account's plan does not include hosted page customization (`plan_feature_unavailable`)",
42577
42586
  * "timestamp": "2026-04-20T12:00:00.000Z",
42578
- * "path": "/api/v1/oauth-clients",
42579
- * "method": "GET"
42587
+ * "path": "/api/v1/oauth-clients/{id}",
42588
+ * "method": "PATCH"
42580
42589
  * }
42581
42590
  * }
42582
42591
  */
package/dist/index.d.ts CHANGED
@@ -3009,7 +3009,7 @@ interface paths {
3009
3009
  head?: never;
3010
3010
  /**
3011
3011
  * Change an Environment's branding
3012
- * @description Sets the Environment's branding. Every field is optional and stands on its own: send only what you want to change, send `null` to clear a field (the primary color then returns to the default blue). The product name shows in the browser tab, as the logo's alt text and in place of a missing logo; the logo shows at the top and the favicon in the tab; the primary color drives buttons and links, and the hover, link and focus shades are derived from it; the background color paints the page behind the card; the text and card colors set the card and what is written on it, with secondary text, lines and field borders derived from the pair; the color scheme chooses the light look, the dark look or whichever the visitor's device asks for, and the dark colors and dark logo describe the dark look, each with a default; the layout is one centred card or a split page with a panel beside the card, which holds a heading, a short text and an image; the background style paints the background color, a two-color gradient or an image behind the card; the corner radius rounds the card, its panels, fields and buttons together; the card style gives the card a border or none, and the card shadow sets the shadow under it; the body font sets the text and the heading font the headings, each a curated font from the fonts list or the https URL of a WOFF2 file, with the system font behind it; the support, terms and privacy links show as "Need help?", "Terms" and "Privacy" under every hosted page; `header_html`, `notice_html` and `footer_html` place your own content in a bar across the top of the page, above the card and under it, kept to links, paragraphs, bold, italics, line breaks, lists and images with https addresses, everything else being removed when it is saved, so the response shows what was kept; `text_overrides` rewords the hosted page texts the text keys list names, one text at a time. Returns `400` (`validation`) for a malformed value, and `403` (`plan_feature_unavailable`) when the request sets `color_scheme`, `logo_dark_url`, a dark color, `layout`, `background_style`, a gradient color, a background or panel image, `panel_heading`, `panel_text`, a text in `text_overrides`, `header_html`, `notice_html`, `footer_html`, `text_color`, `surface_color`, `corner_radius`, `card_style`, `card_shadow`, `heading_font` or `body_font` and the Account's plan does not include hosted page customization; clearing one with `null` is always allowed. Emits `environment.branding_updated`, which records the fields that changed.
3012
+ * @description Sets the Environment's branding. Every field is optional and stands on its own: send only what you want to change, send `null` to clear a field (the primary color then returns to the default blue). The product name shows in the browser tab, as the logo's alt text and in place of a missing logo; the logo shows at the top and the favicon in the tab; the primary color drives buttons and links, and the hover, link and focus shades are derived from it; the background color paints the page behind the card; the text and card colors set the card and what is written on it, with secondary text, lines and field borders derived from the pair; the color scheme chooses the light look, the dark look or whichever the visitor's device asks for, and the dark colors and dark logo describe the dark look, each with a default; the layout is one centred card or a split page with a panel beside the card, which holds a heading, a short text and an image; the background style paints the background color, a two-color gradient or an image behind the card; the corner radius rounds the card, its panels, fields and buttons together; the card style gives the card a border or none, and the card shadow sets the shadow under it; the body font sets the text and the heading font the headings, each a curated font from the fonts list or the https URL of a WOFF2 file, with the system font behind it; the support, terms and privacy links show as "Need help?", "Terms" and "Privacy" under every hosted page; `header_html`, `notice_html` and `footer_html` place your own content in a bar across the top of the page, above the card and under it, kept to links, paragraphs, bold, italics, line breaks, lists and images with https addresses, everything else being removed when it is saved, so the response shows what was kept; `text_overrides` rewords the hosted page texts the text keys list names, one text at a time; `custom_css` is your own CSS for hosted pages, applied after every other setting, which may set the published `--hp-*` tokens and style the published `hp-*` classes, and is refused when it loads a file from anywhere (`@import`, `@font-face`, `url()`), selects on a field's `value` or does not parse. Returns `400` (`validation`) for a malformed value, and `403` (`plan_feature_unavailable`) when the request sets `custom_css`, `color_scheme`, `logo_dark_url`, a dark color, `layout`, `background_style`, a gradient color, a background or panel image, `panel_heading`, `panel_text`, a text in `text_overrides`, `header_html`, `notice_html`, `footer_html`, `text_color`, `surface_color`, `corner_radius`, `card_style`, `card_shadow`, `heading_font` or `body_font` and the Account's plan does not include hosted page customization; clearing one with `null` is always allowed. Emits `environment.branding_updated`, which records the fields that changed.
3013
3013
  */
3014
3014
  patch: operations["ApiBrandingController_updateBranding"];
3015
3015
  trace?: never;
@@ -7239,6 +7239,7 @@ interface components {
7239
7239
  header_html: string | null;
7240
7240
  notice_html: string | null;
7241
7241
  footer_html: string | null;
7242
+ custom_css: string | null;
7242
7243
  /**
7243
7244
  * @description The customer's own wording for hosted page texts, by locale and then by the text's key. Empty where none is set.
7244
7245
  * @example {
@@ -7344,6 +7345,8 @@ interface components {
7344
7345
  notice_html: string | null;
7345
7346
  /** @description The content under the card, likewise. */
7346
7347
  footer_html: string | null;
7348
+ /** @description The customer's own CSS as hosted pages wear it, or null for none. Null on a plan without hosted page customization, whatever is stored. */
7349
+ custom_css: string | null;
7347
7350
  /** @description The wording the hosted pages show in place of their own, by locale and then by the text's key. Empty where none is set, and on a plan without hosted page customization. */
7348
7351
  text_overrides: {
7349
7352
  [key: string]: {
@@ -7523,6 +7526,12 @@ interface components {
7523
7526
  * @example <p>Need a hand? <a href="https://acme.example/help">Ask us</a>.</p>
7524
7527
  */
7525
7528
  footer_html?: string | null;
7529
+ /**
7530
+ * @description Your own CSS for hosted pages, applied after the settings: where it styles what a setting styles, the CSS wins, and everything else follows the settings. It may set the published `--hp-*` tokens and style the published `hp-*` classes; `[data-page]` on `<body>` names the page and `[data-provider]` a social sign-in button's provider. Write the dark look as `@media (prefers-color-scheme: dark)`: it follows `color_scheme`, so it always applies under `dark`, never under `light`, and by the device under `system`. Refused, with the line of each problem: `@import`, `@font-face`, `url()` and every other function that loads a file (set images and fonts with the branding fields), a selector on a field's `value`, the `--_hp-*` custom properties, `</`, and CSS that does not parse. It does not reach emails or the organization admin portal. Null removes it. Needs the `hosted_page_customization` plan feature to set.
7531
+ * @example :root { --hp-field-height: 52px; }
7532
+ * [data-page="register"] .hp-card { padding: 40px; }
7533
+ */
7534
+ custom_css?: string | null;
7526
7535
  /**
7527
7536
  * @description Your own wording for texts on hosted pages, by locale and then by the text's `key` from `GET /api/v1/branding/text-keys`. Each text set here replaces the stored wording, `null` returns that text to its default, and a text left out keeps what is stored; `null` for the whole value returns every text to its default. Wording is plain text without `<` or `>`, no longer than the text's `max_length`, and keeps each of the text's `placeholders` in double braces. A locale the pages are not written in, a key outside the list, or wording that breaks these rules is refused. Needs the `hosted_page_customization` plan feature to set.
7528
7537
  * @example {
@@ -31549,7 +31558,7 @@ interface operations {
31549
31558
  };
31550
31559
  };
31551
31560
  };
31552
- /** @description A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, and a heading or body font a curated font's id or an https URL; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
31561
+ /** @description A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, a heading or body font a curated font's id or an https URL, and `custom_css` CSS of at most 20,000 characters that parses, loads no file (`@import`, `@font-face`, `url()`), selects on no field's `value` and names no `--_hp-*` property or `</`; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
31553
31562
  400: {
31554
31563
  headers: {
31555
31564
  [name: string]: unknown;
@@ -31560,7 +31569,7 @@ interface operations {
31560
31569
  * "error": {
31561
31570
  * "statusCode": 400,
31562
31571
  * "code": "request.invalid",
31563
- * "message": "A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, and a heading or body font a curated font's id or an https URL; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
31572
+ * "message": "A value is malformed: the logo, favicon, terms and privacy links must be https URLs, the colors six-digit hex, the support link an https URL or a mailto: address, the product name at most 60 characters, the color scheme, layout, background style, corner radius, card style and card shadow one of their listed values, a background or panel image an https URL holding no quote, bracket or space, the panel heading at most 80 characters and its text at most 240, `text_overrides` texts from the text keys list, each plain text within its length that keeps its placeholders, the header, notice and footer content at most 2,000 characters each, a heading or body font a curated font's id or an https URL, and `custom_css` CSS of at most 20,000 characters that parses, loads no file (`@import`, `@font-face`, `url()`), selects on no field's `value` and names no `--_hp-*` property or `</`; or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
31564
31573
  * "timestamp": "2026-04-20T12:00:00.000Z",
31565
31574
  * "path": "/api/v1/branding",
31566
31575
  * "method": "PATCH"
@@ -42520,7 +42529,7 @@ interface operations {
42520
42529
  };
42521
42530
  };
42522
42531
  };
42523
- /** @description The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
42532
+ /** @description The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`), or `branding` holds a value a branding change would refuse (`validation`) or is sent for a machine client (`oauth.machine_client_branding_invalid`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`) */
42524
42533
  400: {
42525
42534
  headers: {
42526
42535
  [name: string]: unknown;
@@ -42531,7 +42540,7 @@ interface operations {
42531
42540
  * "error": {
42532
42541
  * "statusCode": 400,
42533
42542
  * "code": "request.invalid",
42534
- * "message": "The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
42543
+ * "message": "The request failed validation: a body field, a query parameter or an id in the path is missing, malformed or out of range, `backchannel_logout_uri` names an address Canopy's servers will not call, `initiate_login_uri` is malformed or not `https` (loopback hosts excepted), `scopes` names a scope Canopy does not issue (`oauth.client_scope_unknown`), a machine client names an `organization_node_id` that is not a live organization of this Environment (`oauth.client_organization_invalid`), takes a web client's field or a scope other than `permissions` (`oauth.machine_client_fields_invalid`) or is asked to be public (`oauth.machine_client_public_invalid`), a web client sends `allowed_audiences` (`oauth.web_client_audiences_invalid`) or `token_exchange` (`oauth.web_client_token_exchange_invalid`), or a confidential client registers a private-use scheme redirect (`oauth.redirect_uri_not_allowed_for_client`), or `branding` holds a value a branding change would refuse (`validation`) or is sent for a machine client (`oauth.machine_client_branding_invalid`); or the request sent both an `X-API-Key` and an `Authorization` header, or its `X-Canopy-Environment` header is missing for an account key, names no Environment of the key's Account, or names another Environment than an Environment key's own; or its `If-Match` header names no version (`if_match.invalid`)",
42535
42544
  * "timestamp": "2026-04-20T12:00:00.000Z",
42536
42545
  * "path": "/api/v1/oauth-clients/{id}",
42537
42546
  * "method": "PATCH"
@@ -42562,7 +42571,7 @@ interface operations {
42562
42571
  "application/json": components["schemas"]["ErrorResponseDto"];
42563
42572
  };
42564
42573
  };
42565
- /** @description The bearer token is not an admin or platform token, or the caller lacks the permission this operation checks: a scoped API key without that scope, an admin without the Account capability that covers it, or, for a node-scoped check, a node outside this Environment */
42574
+ /** @description The caller lacks `oauth_clients.manage`, or the request sets a `branding` value and the Account's plan does not include hosted page customization (`plan_feature_unavailable`) */
42566
42575
  403: {
42567
42576
  headers: {
42568
42577
  [name: string]: unknown;
@@ -42573,10 +42582,10 @@ interface operations {
42573
42582
  * "error": {
42574
42583
  * "statusCode": 403,
42575
42584
  * "code": "auth.forbidden",
42576
- * "message": "The bearer token is not an admin or platform token, or the caller lacks the permission this operation checks: a scoped API key without that scope, an admin without the Account capability that covers it, or, for a node-scoped check, a node outside this Environment",
42585
+ * "message": "The caller lacks `oauth_clients.manage`, or the request sets a `branding` value and the Account's plan does not include hosted page customization (`plan_feature_unavailable`)",
42577
42586
  * "timestamp": "2026-04-20T12:00:00.000Z",
42578
- * "path": "/api/v1/oauth-clients",
42579
- * "method": "GET"
42587
+ * "path": "/api/v1/oauth-clients/{id}",
42588
+ * "method": "PATCH"
42580
42589
  * }
42581
42590
  * }
42582
42591
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@canopy-io/node",
3
- "version": "0.24.0",
3
+ "version": "0.24.1",
4
4
  "description": "Official TypeScript SDK for Canopy \u2014 hierarchical identity and access management.",
5
5
  "license": "MIT",
6
6
  "author": "Canopy Identity Inc.",