Recommend Chart Palettes
palette.recommend
Overview
Tell us the colour-set kind (distinct series colours or a continuous scale), light or dark background, and optional preferences (context, tone, hues). We return a short ranked list of reviewed Squillify palettes with colours or continuous stops and ready-to-apply tokens. We choose among already approved palettes; if none of them can meet your requirements, you can send whenNothingFits=generate and we build one to those requirements instead of sending you to another skill with the same constraints. At most 8 candidates (default 3). Max input 8192 bytes.
You need safe, reviewed chart colours without inventing one-off palettes.
Reliability
STRICT and deterministic for the same input, including when whenNothingFits=generate builds one: the colours come from the request, so the same requirements always give the same palette. Returns at most 8 candidates. Domain errors (not retryable — fix the input; unchanged input will fail again): PALETTE_UNSATISFIABLE (nothing matches — the message names the requirement that emptied the list and how close the library gets, so you know what to relax; send whenNothingFits=generate to have one built instead, and if that is impossible too the message says why both failed); PALETTE_KIND_UNSUPPORTED (the kind is not one we publish — use one of categorical, cyclical, diverging, sequential — or a field that does not apply to the kind you asked for, such as center on anything but a diverging scale, which you should remove); PALETTE_TARGET_UNSUPPORTED (target belongs to the other shape, or is not one of chart_series, color_gradient, generic — leave it out and kind decides); PALETTE_COUNT_REQUIRED (kind=categorical without count — pass count 2..8); PALETTE_UNSUPPORTED_COUNT (count outside the range for the kind you asked for — 2..8 series colours, 2..32 stops); PALETTE_VALUE_INVALID (a value we do not recognise, such as an unknown whenNothingFits, avoid with kind=cyclical, or a center that is not one of neutral, target, zero — correct the value).
Context footprint
Returns a short ranked list of palette objects with hex colours and, for continuous kinds, stops. No chart image is rendered. A successful call costs 1 execution credit.
When to use it
You know the colour-set kind and background and want Squillify-approved options.
You already have an exact palette id — use palette.get. If you want a palette built to order rather than chosen, use palette.generate — or send whenNothingFits=generate and let this skill fall back to it.
Scope
Non-goals
- Does not invent colours unless you ask for it with whenNothingFits=generate, and says so when it did
- Does not present a generated palette as a reviewed library member
- Does not change chart layout, typography, or themes
- Does not accept free-form mood prompts — use the preference fields below
- Does not map your data values onto colours — your chart skill does that
Properties
Capabilities
Cost & billing
Flat rate per invocation
File handling
How we handle your data
What this means
This skill may receive sensitive content, but it does not target sensitive data and returns only a structured non-sensitive result.
Squillify guarantees
- Runs inside Squillify
- This skill runs inside Squillify.
- Payloads are not sent to an external service by this skill.
- Squillify does not permanently store submitted payloads.
- Telemetry records metadata only, not submitted content.
- Submitted payloads are not used for training.
- Submitted payloads are not reviewed by humans.
- This skill does not target sensitive data.
- The response does not contain submitted content.
Your responsibility
Squillify does not determine whether submitted content is sensitive. Your application is responsible for deciding what data it is allowed to submit. Your application is responsible for securing the response.
Input schema
| Field | Type | Required | Description |
|---|---|---|---|
| kind | string | Yes | Which colour-set family to generate or look up. |
| count | integer | No | How many colours to return, 2 through 8 for categorical and 2 through 32 stops for a continuous ramp. Required for kind=categorical; omit it on a continuous kind to get the ramp's own stops. |
| center | string | No | Where a diverging ramp is centred; omit it for zero on diverging palettes. Rejected for other kinds. |
| surface | string | Yes | Chart background the colours were checked against. |
| context | string | No | Where the chart will be read, which lifts matching palettes; omit it for general. |
| tone | array | No | Preferred tones in priority order, 1 through 9 names; omit it when you have no tone preference. |
| intensity | string | No | Preferred intensity which lifts matching palettes; omit it when you have no intensity preference. |
| temperature | string | No | Preferred colour temperature which lifts matching palettes; omit it when you have no temperature preference. |
| huePreference | array | No | Preferred hue families in priority order, 1 through 14 names; omit it when you have no hue preference. |
| avoid | array | No | Hue families to drop, 0 through 8 names; omit it or send [] when nothing is ruled out. Not accepted with kind=cyclical. |
| accessibility | object | No | Closed readability requirements that remove palettes rather than reorder them: colorVision, print and optional minimumSurfaceContrast; omit the whole object for default checks only. |
| whenNothingFits | string | No | fail returns PALETTE_UNSATISFIABLE; generate builds one palette to the same requirements. Omit it for fail. |
| target | string | No | Where the colours will be applied: chart_series, color_gradient or generic; omit it so the palette's own shape chooses. |
| direction | string | No | Colour order; omit it for normal. |
| resultLimit | integer | No | How many candidates to return, 1 through 8; omit it for 3. |
Output schema
| Field | Type | Required | Description |
|---|---|---|---|
| library | object | Yes | Closed reviewed-library identity with id, content digest and publication status. |
| candidates | array | Yes | Ranked options best first, 1 through 8 closed {palette, score, reasons} objects. |
| warnings | array | Yes | Non-fatal notices as strings, 0 through 32 items, often empty. |
API contract
POST /v1/executecurl -sS -X POST "$BASE/v1/execute" -H "Authorization: Bearer $KEY" -H 'Content-Type: application/json' -d '{"skillKey":"palette.recommend","input":{"kind":"categorical","count":6,"surface":"light","context":"dashboard","resultLimit":1}}'import { Squillify } from "@squillify/sdk";
const sq = new Squillify({ apiKey: process.env.SQUILLIFY_API_KEY });
const { output } = await sq.execute("palette.recommend", {"tone":["professional","calm"],"count":6,"kind":"categorical","surface":"light","context":"dashboard","resultLimit":1});Errors
| Code | HTTP | Retryable | Description |
|---|---|---|---|
| VALIDATION_ERROR | 400 | No | The request payload failed schema validation. |
| UNAUTHORIZED | 401 | No | Missing or invalid API key. |
| SKILL_NOT_ACCESSIBLE | 403 | No | The API key is not granted access to this skill. |
| SKILL_NOT_AVAILABLE_FOR_PLAN | 403 | No | This skill is not included in your current plan. |
| PLAN_ELIGIBILITY_UNAVAILABLE | 503 | Yes | Plan eligibility could not be decided. Retry after backoff. |
| SKILL_NOT_FOUND | 404 | No | The requested skill or version does not exist. |
| TENANT_RATE_LIMITED | 429 | Yes | Request rate limit exceeded. Retry after backoff. |
| QUOTA_EXCEEDED | 429 | Yes | Plan quota exhausted. Retryable once the quota period resets. |
| EXECUTION_TIMEOUT | 504 | Yes | Execution exceeded the allowed time budget. |
| PALETTE_UNSATISFIABLE | 412 | No | The input is valid but cannot be processed as-is. |
| PALETTE_KIND_UNSUPPORTED | 400 | No | The skill does not support the requested variant. |
| PALETTE_TARGET_UNSUPPORTED | 400 | No | The skill does not support the requested variant. |
| PALETTE_COUNT_REQUIRED | 400 | No | The request payload failed this skill's input validation. |
| PALETTE_UNSUPPORTED_COUNT | 400 | No | The request payload failed this skill's input validation. |
| PALETTE_VALUE_INVALID | 400 | No | The request payload failed this skill's input validation. |
Other limits
| Limit | Value |
|---|---|
| Recommended inline bytes | 32 KiB |
Limitations
- Does not invent colours unless you ask for it with whenNothingFits=generate, and says so when it did
- Does not present a generated palette as a reviewed library member
- Does not change chart layout, typography, or themes
- Does not accept free-form mood prompts — use the preference fields below
- Does not map your data values onto colours — your chart skill does that
- Open-ended mood prompts instead of the preference fields
- Exact lookup when you already have a palette id — use palette.get
How to call
POST /v1/execute (requires authentication)
{
"skillKey": "palette.recommend",
"input": {
"tone": [
"professional",
"calm"
],
"count": 6,
"kind": "categorical",
"surface": "light",
"context": "dashboard",
"resultLimit": 1
}
}Examples
Six-series professional dashboard on a light background
{
"tone": [
"professional",
"calm"
],
"count": 6,
"kind": "categorical",
"surface": "light",
"context": "dashboard",
"resultLimit": 1
}{
"warnings": [],
"candidates": [
{
"palette": {
"ref": {
"source": "registry",
"registry": "squillify-core-palettes",
"registryDigest": "sha256:d5d4ee7cdb6425cdfe6cc0cf1bac317cb9bb0bc7c9b70380de4adf31fb0b3e17",
"paletteId": "sq.categorical.dashboard.professional-cool-spectrum.002@1",
"variant": "count-6.light",
"paletteDigest": "sha256:73536ed4d96c4c3dcc431ea6094df3ca993597ffd17f2e86ab42073f17025a9f"
},
"displayName": "Squillify Dashboard Professional — Cool Spectrum 002",
"kind": "categorical",
"model": "adaptive",
"surface": "light",
"cardinality": 6,
"colors": [
"#077F61",
"#00616C",
"#2E8FB5",
"#004273",
"#705FA2",
"#004E1E"
],
"direction": "normal",
"application": {
"target": "chart_series",
"chartStyleTokens": {
"--sq-series-1": "#077F61",
"--sq-series-2": "#00616C",
"--sq-series-3": "#2E8FB5",
"--sq-series-4": "#004273",
"--sq-series-5": "#705FA2",
"--sq-series-6": "#004E1E"
}
},
"evidence": {
"state": "certified"
},
"warnings": []
},
"score": 52,
"reasons": [
"matches categorical cardinality 6",
"matches dashboard context",
"matches light surface"
]
}
],
"library": {
"id": "squillify-core-palettes",
"digest": "sha256:d5d4ee7cdb6425cdfe6cc0cf1bac317cb9bb0bc7c9b70380de4adf31fb0b3e17",
"status": "CERTIFIED"
}
}Sequential scale for a light heatmap
{
"kind": "sequential",
"surface": "light",
"resultLimit": 1,
"context": "dashboard"
}{
"warnings": [],
"candidates": [
{
"palette": {
"ref": {
"source": "registry",
"registry": "squillify-core-palettes",
"registryDigest": "sha256:d5d4ee7cdb6425cdfe6cc0cf1bac317cb9bb0bc7c9b70380de4adf31fb0b3e17",
"paletteId": "sq.sequential.dashboard.calm-cool-spectrum.010@1",
"variant": "continuous.light",
"paletteDigest": "sha256:2ff6799cc4f2f0af87be6900a69b2f582f757a2b866bd44e06cc718cf0930d12"
},
"displayName": "Squillify Dashboard Calm — Cool Spectrum 010",
"kind": "sequential",
"model": "continuous",
"surface": "light",
"cardinality": 9,
"colors": [
"#DFFAE7",
"#AAE8D2",
"#70D3CA",
"#36BBC6",
"#079FC0",
"#2281B1",
"#376496",
"#3C4B73",
"#36354B"
],
"stops": [
{
"color": "#DFFAE7",
"t": 0
},
{
"color": "#AAE8D2",
"t": 0.125
},
{
"color": "#70D3CA",
"t": 0.25
},
{
"color": "#36BBC6",
"t": 0.375
},
{
"color": "#079FC0",
"t": 0.5
},
{
"color": "#2281B1",
"t": 0.625
},
{
"color": "#376496",
"t": 0.75
},
{
"color": "#3C4B73",
"t": 0.875
},
{
"color": "#36354B",
"t": 1
}
],
"interpolation": {
"colourSpace": "OKLab",
"profile": "perceptual-smooth"
},
"closure": "clamp",
"direction": "normal",
"application": {
"target": "color_gradient",
"chartStyleTokens": {}
},
"evidence": {
"state": "certified"
},
"warnings": []
},
"score": 32,
"reasons": [
"matches sequential continuous scale",
"matches dashboard context",
"matches light surface"
]
}
],
"library": {
"id": "squillify-core-palettes",
"digest": "sha256:d5d4ee7cdb6425cdfe6cc0cf1bac317cb9bb0bc7c9b70380de4adf31fb0b3e17",
"status": "CERTIFIED"
}
}Recommended use cases
- Pick a dashboard palette for a fixed number of series
- Give an agent a short list of approved colour options instead of free-form colours
- Compare a few safe alternatives before locking a palette id
Avoid for
- Open-ended mood prompts instead of the preference fields
- Exact lookup when you already have a palette id — use palette.get
Related skills
Composable with
Safety & privacy
- Runs without calling any external service.
- Your payloads are never stored permanently.
- Telemetry captures metadata only — never your payload contents.
- We never train models on your payloads.
- No human reviews your payloads.