Operazioni sul brand

13 operazioni di nome brand.*. Ognuna si esegue in un batch con apply_ops, dry_run_ops, la CLI o l’admin.

Aggiornato il
OperationWhat it doesPermissionConfirmation
brand.setupSet the site's brand from three colours, a type pairing, a type ratio and base size, a spacing unit and a corner style: the server derives every token write of the brand (the brand, accent and neutral palette ramps, the light and dark colour roles as aliases of palette steps, the font sizes and families, the main type presets, the space steps and the radii) and lands them as one designSystem.setTokens change, gated once for AA contrast on the end state, so one undo restores the lot.designSystem.operationnone
brand.presetsList the site's brand presets, the brand identities its brand templates draw from, each with its id, name and last change.site.adminnone
brand.templatesList the site's brand templates, the fixed-size canvases (a social post, a banner) brand.render draws: each with its name, size, status (draft or approved), version and canvas page.site.adminnone
brand.updateIdentityPatch a brand identity (the default preset's, or presetId's): its brand name, tagline, logos, the four brand colours, the headline and body roles, the tone words and the do and don't rules.site.adminnone
brand.createPresetAdd a brand preset named presetName: a copy of preset cloneFrom, or without it the theme's default identity for the site.site.adminnone
brand.renamePresetRename a brand preset.site.adminnone
brand.deletePresetDelete a brand preset; the site's last one is refused (409 brand_last_preset).site.admindestructive
brand.createTemplateCreate a brand template: a canvas page of width by height pixels (fixed at creation) with a first section, laid out from one of the theme's canvas presets when layoutId names one.site.adminnone
brand.updateTemplateRename a brand template, approve it (status: "approved" with expectedDraftRevision, the canvas revision you approve: that canvas becomes the version brand.render draws) or set which of its fields a person may change when generating (customerSettings).site.adminnone
brand.deleteTemplateDelete a brand template, then its canvas page.site.admindestructive
brand.rebuildTemplateRecreate the canvas page of a brand template whose page was deleted, from its last approved snapshot (refused when it has none); edits made after that approval do not come back.site.adminnone
brand.renderRender an approved brand template to a PNG (scale 1 or 2) in a brand preset (presetId), with the overrides of the fields its curation lets a person change (overrides, by node), and answer it as base64 without storing it.brand.generatenone
brand.saveRender an approved brand template as brand.render does and store the PNG in the media library, with the record of how it was made.brand.generatenone

brand.setup

Set the site's brand from three colours, a type pairing, a type ratio and base size, a spacing unit and a corner style: the server derives every token write of the brand (the brand, accent and neutral palette ramps, the light and dark colour roles as aliases of palette steps, the font sizes and families, the main type presets, the space steps and the radii) and lands them as one designSystem.setTokens change, gated once for AA contrast on the end state, so one undo restores the lot. A brand with pairs below AA is refused unless the input carries acknowledgeContrast: true, the designer's explicit "save anyway", which the stored batch keeps; then the failing pairs come back as error findings. The admin's Brand setup screen runs this same operation.

permission: designSystem.operationwrites: designSystemclass: transactionundo: yes

Esempio di input

{
  "primary": "#1e3d4f",
  "secondary": "#c8553d",
  "neutral": "#737373",
  "headingFamily": [
    "DM Sans",
    "sans-serif"
  ],
  "bodyFamily": [
    "DM Sans",
    "sans-serif"
  ],
  "typeRatio": 1.25,
  "baseSize": 17,
  "spaceBase": 4,
  "radius": "soft"
}

Input

FieldTypeRequiredNotes
primarystringyes
secondarystringyes
neutralstringyes
headingFamilyarray of stringyesAt least 1 item.
bodyFamilyarray of stringyesAt least 1 item.
typeRationumberyesOne of 1.125, 1.2, 1.25, 1.333.
baseSizeintegeryesAt least 14. At most 22.
spaceBasenumberyesOne of 4, 8.
radiusstringyesOne of "sharp", "soft", "round", "pill".
acknowledgeContrasttrueno

Output

FieldTypeRequiredNotes
treeobjectno
tree.pageIdstringyes
tree.revisionintegeryes
tree.inversearray of object | object | object | object | object | object | object | object | object | object | object | object | objectyes
findingsarray of object | object | object | object | objectyes
diffarray of object | object | object | object | object | objectyes
changesarray of objectno
changes[].changestringyesOne of "added", "changed", "removed".
changes[].overrideobject | object | object | object | object | objectyes
changedbooleanyes
revisionintegeryes
dryRunbooleanyes
cssstring | nullyes
reportobjectno
report.addsarray of objectyes
report.changesarray of objectyes
report.typeConflictsarray of objectyes
report.unknownNamesarray of objectyes

I campi più annidati sono nello schema di output che risponde discover_operations con outputSchemas: true.

Provala

yarn splash brand.setup '{"primary":"#1e3d4f","secondary":"#c8553d","neutral":"#737373","headingFamily":["DM Sans","sans-serif"],"bodyFamily":["DM Sans","sans-serif"],"typeRatio":1.25,"baseSize":17,"spaceBase":4,"radius":"soft"}' --dry-run

brand.presets

List the site's brand presets, the brand identities its brand templates draw from, each with its id, name and last change. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminreads onlyclass: read

Esempio di input

{}

Input

L’input è un record: vedi lo schema qui sotto.

{
  "type": "object",
  "properties": {},
  "additionalProperties": false
}

Output

FieldTypeRequiredNotes
presetsarray of objectyes
presets[].presetIdstringyes
presets[].presetNamestringyes
presets[].updatedAtstringyes

Provala

yarn splash brand.presets '{}' --dry-run

brand.templates

List the site's brand templates, the fixed-size canvases (a social post, a banner) brand.render draws: each with its name, size, status (draft or approved), version and canvas page. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminreads onlyclass: read

Esempio di input

{}

Input

L’input è un record: vedi lo schema qui sotto.

{
  "type": "object",
  "properties": {},
  "additionalProperties": false
}

Output

FieldTypeRequiredNotes
templatesarray of objectyes
templates[].idstringyesAt least 1 character.
templates[].namestringyes
templates[].pageIdstringyesAt least 1 character.
templates[].snapshotobject | nullyesDefault null.
templates[].customerSettingsrecord of array of string | nullyesDefault null.
templates[].statusstringyesOne of "draft", "approved".
templates[].versionnumberyes
templates[].widthnumberyes
templates[].heightnumberyes
templates[].createdAtstringyes
templates[].updatedAtstringyes

Provala

yarn splash brand.templates '{}' --dry-run

brand.updateIdentity

Patch a brand identity (the default preset's, or presetId's): its brand name, tagline, logos, the four brand colours, the headline and body roles, the tone words and the do and don't rules. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brandclass: transactionundo: yes

Esempio di input

{
  "identity": {
    "brandName": "Studio",
    "tagline": "Architecture and landscape"
  }
}

Input

FieldTypeRequiredNotes
presetIdstringnoAt least 1 character.
identityobjectyes
identity.brandNamestringno
identity.taglinestringno
identity.logoPrimarystring | nullno
identity.logoInversestring | nullno
identity.logoMarkstring | nullno
identity.brandPrimarystringno
identity.brandSecondarystringno
identity.brandSurfacestringno
identity.brandOnSurfacestringno
identity.headlineRolestringno
identity.bodyRolestringno
identity.toneWordsstringno
identity.doRulesstringno
identity.dontRulesstringno

Output

FieldTypeRequiredNotes
identityobjectyes
identity.brandNamestringyes
identity.taglinestringyes
identity.logoPrimarystring | nullyes
identity.logoInversestring | nullyes
identity.logoMarkstring | nullyes
identity.brandPrimarystringyes
identity.brandSecondarystringyes
identity.brandSurfacestringyes
identity.brandOnSurfacestringyes
identity.headlineRolestringyes
identity.bodyRolestringyes
identity.toneWordsstringyes
identity.doRulesstringyes
identity.dontRulesstringyes

Provala

yarn splash brand.updateIdentity '{"identity":{"brandName":"Studio","tagline":"Architecture and landscape"}}' --dry-run

brand.createPreset

Add a brand preset named presetName: a copy of preset cloneFrom, or without it the theme's default identity for the site. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brandclass: transactionundo: yes

Esempio di input

{
  "presetName": "Autumn campaign"
}

Input

FieldTypeRequiredNotes
presetNamestringyesAt least 1 character. At most 120 characters.
cloneFromstringnoAt least 1 character.

Output

FieldTypeRequiredNotes
presetIdstringyes
presetNamestringyes
updatedAtstringyes

Provala

yarn splash brand.createPreset '{"presetName":"Autumn campaign"}' --dry-run

brand.renamePreset

Rename a brand preset. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brandclass: transactionundo: yes

Esempio di input

{
  "presetId": "autumn-campaign",
  "presetName": "Autumn campaign 2026"
}

Input

FieldTypeRequiredNotes
presetIdstringyesAt least 1 character.
presetNamestringyesAt least 1 character. At most 120 characters.

Output

FieldTypeRequiredNotes
presetIdstringyes
presetNamestringyes
updatedAtstringyes

Provala

yarn splash brand.renamePreset '{"presetId":"autumn-campaign","presetName":"Autumn campaign 2026"}' --dry-run

brand.deletePreset

Delete a brand preset; the site's last one is refused (409 brand_last_preset). Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brandclass: transactionconfirm: destructiveundo: yes

Esempio di input

{
  "presetId": "autumn-campaign"
}

Input

FieldTypeRequiredNotes
presetIdstringyesAt least 1 character.

Output

FieldTypeRequiredNotes
status"deleted"yes

Vuole confirmed: ["destructive"] sul batch, che la forma della CLI per una sola operazione non imposta: mettila in un file di batch ed esegui yarn splash apply <file> --dry-run.

brand.createTemplate

Create a brand template: a canvas page of width by height pixels (fixed at creation) with a first section, laid out from one of the theme's canvas presets when layoutId names one. Edit its content with tree.commit on its page, then approve it with brand.updateTemplate. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brand, pagesclass: transactionundo: yes

Esempio di input

{
  "name": "Instagram post",
  "width": 1080,
  "height": 1080
}

Input

FieldTypeRequiredNotes
namestringyesAt least 1 character. At most 120 characters.
widthintegeryesAt least 16. At most 4096.
heightintegeryesAt least 16. At most 4096.
layoutIdstringnoAt least 1 character.

Output

FieldTypeRequiredNotes
idstringyesAt least 1 character.
namestringyes
pageIdstringyesAt least 1 character.
snapshotobject | nullyesDefault null.
customerSettingsrecord of array of string | nullyesDefault null.
statusstringyesOne of "draft", "approved".
versionnumberyes
widthnumberyes
heightnumberyes
createdAtstringyes
updatedAtstringyes

Provala

yarn splash brand.createTemplate '{"name":"Instagram post","width":1080,"height":1080}' --dry-run

brand.updateTemplate

Rename a brand template, approve it (status: "approved" with expectedDraftRevision, the canvas revision you approve: that canvas becomes the version brand.render draws) or set which of its fields a person may change when generating (customerSettings). Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brand, pagesclass: transactionundo: yes

Esempio di input

{
  "templateId": "4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b",
  "patch": {
    "name": "Instagram post, square"
  }
}

Input

FieldTypeRequiredNotes
templateIdstringyesAt least 1 character.
patchobjectyes
patch.namestringnoAt most 120 characters.
patch.statusstringnoOne of "draft", "approved".
patch.customerSettingsrecord of array of string | nullno
patch.expectedDraftRevisionstringno

Output

FieldTypeRequiredNotes
idstringyesAt least 1 character.
namestringyes
pageIdstringyesAt least 1 character.
snapshotobject | nullyesDefault null.
customerSettingsrecord of array of string | nullyesDefault null.
statusstringyesOne of "draft", "approved".
versionnumberyes
widthnumberyes
heightnumberyes
createdAtstringyes
updatedAtstringyes

Provala

yarn splash brand.updateTemplate '{"templateId":"4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b","patch":{"name":"Instagram post, square"}}' --dry-run

brand.deleteTemplate

Delete a brand template, then its canvas page. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brand, pagesclass: transactionconfirm: destructiveundo: yes

Esempio di input

{
  "templateId": "4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b"
}

Input

FieldTypeRequiredNotes
templateIdstringyesAt least 1 character.

Output

FieldTypeRequiredNotes
successtrueyes

Vuole confirmed: ["destructive"] sul batch, che la forma della CLI per una sola operazione non imposta: mettila in un file di batch ed esegui yarn splash apply <file> --dry-run.

brand.rebuildTemplate

Recreate the canvas page of a brand template whose page was deleted, from its last approved snapshot (refused when it has none); edits made after that approval do not come back. Brand validation applies, and history.undo restores the brand rows the batch changed.

permission: site.adminwrites: brand, pagesclass: transactionundo: yes

Esempio di input

{
  "templateId": "4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b"
}

Input

FieldTypeRequiredNotes
templateIdstringyesAt least 1 character.

Output

FieldTypeRequiredNotes
idstringyesAt least 1 character.
namestringyes
pageIdstringyesAt least 1 character.
snapshotobject | nullyesDefault null.
customerSettingsrecord of array of string | nullyesDefault null.
statusstringyesOne of "draft", "approved".
versionnumberyes
widthnumberyes
heightnumberyes
createdAtstringyes
updatedAtstringyes

Provala

yarn splash brand.rebuildTemplate '{"templateId":"4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b"}' --dry-run

brand.render

Render an approved brand template to a PNG (scale 1 or 2) in a brand preset (presetId), with the overrides of the fields its curation lets a person change (overrides, by node), and answer it as base64 without storing it. The render runs in a standalone boundary; run it alone in a batch.

permission: brand.generatereads onlyclass: external

Esempio di input

{
  "templateId": "4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b",
  "scale": 1
}

Input

FieldTypeRequiredNotes
templateIdstringyesAt least 1 character.
presetIdstringnoAt least 1 character.
scale1 | 2noDefault 1.
overridesvalueno

Output

FieldTypeRequiredNotes
pngstringyes
contentType"image/png"yes
filenamestringyes
templateVersionintegeryesMore than 0.
widthintegeryesMore than 0.
heightintegeryesMore than 0.
warningsarray of stringyes

Un dry run rifiuta un’operazione esterna, quindi non ha una riga di prova: eseguila da sola in un batch.

brand.save

Render an approved brand template as brand.render does and store the PNG in the media library, with the record of how it was made. The render runs in a standalone boundary; run it alone in a batch.

permission: brand.generatewrites: media, generationsclass: externalundo: yes

Esempio di input

{
  "templateId": "4e5f6a7b-8c9d-4e0f-9a1b-2c3d4e5f6a7b",
  "scale": 2
}

Input

FieldTypeRequiredNotes
templateIdstringyesAt least 1 character.
presetIdstringnoAt least 1 character.
scale1 | 2noDefault 1.
overridesvalueno

Output

FieldTypeRequiredNotes
kind"template"yes
mediaobjectyes
media.idstring (uuid)yes
media.kindstringyesOne of "image", "svg", "video", "document".
media.filenamestringyesAt least 1 character. At most 255 characters.
media.mimestringyesAt least 1 character. At most 127 characters.
media.sizeintegeryesAt least 0.
media.urlstringyesAt least 1 character. At most 2048 characters.
media.widthintegernoAt least 1. At most 100000.
media.heightintegernoAt least 1. At most 100000.
media.variantsarray of objectyes
media.altstring | record of stringyes
media.captionstring | record of stringno
media.creditstringnoAt most 200 characters.
media.folderIdstring (uuid) | nullno
media.pageCountintegernoAt least 1.
templateIdstringyes
templateVersionintegeryesMore than 0.
widthintegeryesMore than 0.
heightintegeryesMore than 0.
warningsarray of stringyes

I campi più annidati sono nello schema di output che risponde discover_operations con outputSchemas: true.

Un dry run rifiuta un’operazione esterna, quindi non ha una riga di prova: eseguila da sola in un batch.

Generato dal registro delle operazioni e dal catalogo degli strumenti MCP (sorgente 31b79796ca558f73).

Qualcosa non va in questa pagina? Scrivi a docs@librettocms.com.

Guida di Libretto

Colophon. Questa guida è un sito Libretto: 70 pagine in due lingue, 21 pagine della guida importate da Markdown e 42 pagine di riferimento generate dal registro delle operazioni. Composta in Softcore, il codice in IBM Plex Mono. La sua struttura:

/it/ Guida di Libretto /it/start Per iniziare /it/start/request-access Richiedere l'accesso /it/start/workspace Il tuo spazio di lavoro /it/start/first-site Il tuo primo sito /it/start/invite-a-client Invitare un cliente /it/start/connect-claude Connettere Claude a Libretto /it/build Costruire /it/build/first-page Costruire una pagina /it/build/layers-and-canvas Livelli e canvas /it/build/site-components Componenti del sito /it/design-system Design system /it/design-system/tokens Colori, spazi e temi /it/design-system/components Componenti e varianti /it/design-system/fonts Tipografia e font /it/motion Movimento /it/motion/scenes Scene e ricette /it/motion/image-sequences Sequenze di immagini /it/motion/reduced-motion Movimento ridotto /it/publish Pubblicazione /it/publish/languages Le lingue del sito /it/publish/versions Pubblicazione e versioni /it/publish/members-and-forms Iscritti e moduli /it/publish/domains Domini /it/publish/redirects Reindirizzamenti /it/handover Consegnare un sito al cliente /it/glossary Glossario /it/agents Agenti e API /it/agents/mcp Server MCP /it/agents/cli CLI /it/agents/batches Batch /it/agents/errors Errori e segnalazioni /it/agents/operations Operazioni /it/search Cerca