uichemy_add_blog
ChatGPTGive a project a blog: a listing page, an article page per post, the four archive pages, and the posts themselves. THE ARTICLE PAGES SHARE ONE SECTION LIST, and that is not a shortcut — slot tokens belong to the layout, so per-post copy could not live in them. Each post's title, byline, date and read time come from the post data written here, and the canvas paints them onto the page that belongs to that post. At most three article pages: the canvas matches a post to a page by the page's NAME ("Blog Detail Page", "… 2", "… 3"), and there is no fourth name it knows. Extra posts still appear on the listing. THE ARCHIVES COME TOO, because the pages already built point at them: an article's tag row links to a tag archive, its byline to an author archive, and the listing's search to a results page. Search Results, Author, Category and Tag Featured are built under the names the app's own generator uses, so a blog built here and one generated in the app are the same blog. Pass archives: false for the two-page blog this tool used to make. What this does NOT do: the WordPress export builds its posts from the backend's own blog collection, which only the app's blog generator writes. Posts written here are the site's canvas and listing; the export will still generate its own.
uichemy_add_code_section
ChatGPTWRITES to the user's project and only APPENDS: inserts one new section on a page (creating the page, or a new project when projectId is omitted). It never replaces or edits an existing section; it does re-save the page's section list and its combined page-wide CSS and scripts to include the new one. To change an existing section use uichemy_update_code_section, which overwrites. Add ONE section you wrote to a page — for a site built section by section in conversation. Omit projectId to start a new project with this as its first section (projectName, palette and fonts then set its look). The page is created if it does not exist. Pick format by how you wrote it. For uichemy, CALL uichemy_section_spec FIRST and follow it exactly — the section is validated and render-checked, and refused whole with the reasons if it fails. For html, write one root element and put images at absolute https urls. Iterate with uichemy_update_code_section (same position, new code). Reorder, duplicate and remove with the ordinary section tools. Nothing is exported until Export (or uichemy_mark_exported) runs, which prepares every section for Elementor and Gutenberg.
uichemy_add_page
ChatGPTAdd a whole page to a project — the sitemap node, its sections, their layouts and their copy. Build a real page, not an outline: navbar first and footer last, and 5 to 8 sections between them. Call uichemy_template_slots for every layout first and fill EVERY text slot, or the section renders its own tokens on the page. File it with category: a policy under Legal, a blog post under Blog, a 404 under Site Extras. Omitted, the name is read, and only a name that can mean one thing is claimed. A page NAMED as a blog page is held to the blog section rule: a listing takes navbar, blog, newsletter, footer; a detail page must include post-featured-area and post-content, and takes only the single-post sections beside them.
uichemy_add_section
ChatGPTAdd a section to a page at a position. Both documents are updated together — the sitemap node that says the page HAS a section there, and the variant map that says what renders in it. Updating one alone is how 'add a pricing section' silently repeats the hero. Fill its slots: call uichemy_template_slots and pass text, or the section renders its own tokens. BLOG PAGES ARE CONSTRAINED. A blog listing page takes navbar, blog, newsletter, footer; a blog detail page takes those plus the single-post sections. A hero, a pricing table or an FAQ on one is refused, not added.
uichemy_batch
ChatGPTMany edits in ONE write. Copy, pictures, video clips, per-element text styles, button roles, badge designs, image display settings, section backgrounds and icons, in the order you give them. Prefer this to calling the single tools thirty times: each of those is its own revision and its own chance to collide with somebody editing the project in the browser, and a collision halfway through leaves fourteen changes applied and no record of where it stopped. ALL OR NOTHING — one invalid op refuses the whole batch and nothing is written, with every problem named so the batch can be fixed and sent again. link points a button or text link (by its text_… / icon_url_… key, from uichemy_list_links) at an href, the same as uichemy_set_link.
uichemy_check_layouts
ChatGPTCheck a SHORTLIST of layouts against each other before building with them. Slot tokens are project-wide, and 114 of the library's tokens are owned by more than one layout — so two layouts that share one render the same words in both places, on different pages, and neither section looks wrong on its own. Call this while choosing sections, not after: uichemy_create_project writes the sitemap and the variants together and there is no tool that re-layouts a built project, so a clash found afterwards costs the build. Takes no project and changes nothing.
uichemy_check_responsive
ChatGPTWhat a page does at a phone, a tablet and a desktop width: copy that overflows its slot, layouts that cannot fit their columns, fixed widths wider than the screen, text that cannot wrap, colours that do not read on the surface they are painted on, and slots still showing their own token. THIS IS NOT A SCREENSHOT and does not claim to be. It reads the two things that decide whether a section breaks narrow — the template's own Tailwind responsive classes, which are resolvable exactly at a given width, and the length of the copy against the length the layout was designed for. A rendered picture would need a second renderer, and a second renderer that disagrees with the canvas is a new bug rather than a check.
uichemy_clear_icon_override
ChatGPTPut one icon back to whatever the template ships. Safe for either key scheme — removing is what resolves a fighting pair, not what causes one.
uichemy_clear_text_style
ChatGPTPut one element back to the global scale — alignment, size, colour and tag all released.
uichemy_create_canvas
ChatGPTDo what the editor's "Continue to design" does on the first canvas open, with no AI call: derive the colour roles, pin the section style (the canvas would otherwise roll one at random) and write the band colour every section gets from it, write the export's section list, and mark every page built. Safe to call again — it writes only what changed. Says what, if anything, the canvas would still do on its first open (a random layout for a section with none, or the AI copy fill for a project with no copy).
uichemy_create_project
ChatGPTCreates a new UiChemy project from layouts in the UiChemy template library, using the copy, fonts and colours passed in. Each page is a list of sections, normally a navbar first and a footer last; a home page usually has 8 to 12 sections (hero, social proof, features, how it works, testimonials, pricing or offer, FAQ, CTA) and an inner page 5 to 8. Text and image slots belong to the layout: uichemy_template_slots lists them with their maximum length and what each one is for. A slot left empty shows its token on the page, an image slot left empty keeps the template's stock photo, and copy over a slot's limit makes the whole call fail. Two sections using the same layout share the same copy. Image slots take urls, so a generated picture needs to be uploaded first. category files a page in the sitemap (Blog, Legal, Site Extras...); pages without one are filed under Core Pages. brief fills the project's Scope tab and is required, as are headingFont, bodyFont and all five palette colours. The result names any slot left unfilled and any layout that was not found.
uichemy_create_variant
ChatGPTAdd a colour variant to a project — another whole palette the user can switch to, without touching the one currently applied. Omit colors to seed it from one of the built-in concepts.
uichemy_crop_image
ChatGPTCrop a picture to a shape, and/or shrink it — as a NEW file, which is then put in the slot. This is the change that survives: sections export to static HTML, so a crop that exists only as CSS on our own markup ships uncropped. focus decides which part survives the crop — the focal point — and maxWidth is how you stop a 4000px photograph being downloaded by every visitor to fill a 400px card. The original is untouched and still in storage, so a second crop can start from it rather than compounding.
uichemy_delete_project
ChatGPTDelete a whole project — its sitemap, its sections and everything written into them. IRREVERSIBLE, and there is no restore point in this product: nothing here can read an earlier revision back, so a delete is the end of that project. confirmName must match the project's own name exactly. That is not ceremony — project ids are opaque, a list read a minute ago may name a different project now, and the name is the only thing the caller and the user can both see. Superseded projects otherwise accumulate with no way to remove them except the browser.
uichemy_delete_variant
ChatGPTRemove a colour variant. It comes out of the list the picker walks as well as the store — a variant left in one and not the other either cannot be chosen or points at nothing.
uichemy_describe_sections
ChatGPTWrite the sitemap note on one or more of a page's sections — the text the sitemap panel shows under the section name. It is documentation, not copy: NOTHING on the rendered page changes, and a note is not a way to put words on a section (that is uichemy_set_text). Say what the section is FOR and what is in it, from what the section actually holds — read uichemy_get_page first and describe the copy that is there. A note restating the section name is worse than none, because it reads as done. Every note on a page goes in ONE call: this writes the sitemap, and one write is one revision to lose a race with.
uichemy_duplicate_page
ChatGPTCopy a page — its sections, their layouts, and their backgrounds, overlays and padding. THE COPY SHOWS THE SAME WORDS, and cannot be made to show different ones by copying: slot tokens belong to the LAYOUT, so both pages read from the same slots. To make the copy say something else, give its sections different layouts with uichemy_replace_section and then write copy into those.
uichemy_duplicate_section
ChatGPTCopy a section, with everything it is wearing, and put the copy after it. uichemy_duplicate_page exists; this is the same move one level down. The copy carries the original's background, overlay and padding — a duplicate that took only its layout would come back unpainted, which reads as the wrong section. The COPY is not copied and must not be: slot tokens belong to the layout, so the duplicate renders the same words by construction, and a second copy of them would be a second source of truth for one piece of text.
uichemy_edit_image_masked
ChatGPTEdit part of a picture with AI and put the result in its slot — the Image panel's Generative Fill (fill: paint something new into the area, described by prompt), Magic Eraser (erase: remove what is in the area) and Expand (expand: extend the picture outward). Runs the SAME code as the editor and costs the same UiChemy credits (refunded down to what the model actually used); it needs the plan the editor's smart editing needs. The area is region — a rectangle in fractions of the picture (0-1, from the top-left) — or maskUrl, a PNG the size of the picture that is transparent where it should change. The result is a NEW file; the original stays in storage. Same write as uichemy_crop_image.
uichemy_embed_url
ChatGPTInternal: the UiChemy panel's one-time sign-in url.
uichemy_find_templates
ChatGPTFind layouts of one kind by what they ARE — column count, background, the media they carry, how much copy they want. 849 layouts named layout-x6 are 849 coin flips otherwise, and picking blind means trying one and replacing it. Every filter given must match (AND, not OR): asking for a two-column hero with a photo means both, or the whole folder comes back with the matches buried in it.
uichemy_get_blog
ChatGPTThe posts this project has — title, byline, date, category, read time — and which article page each one lands on. Call it before changing a post: the post number, not the title, is what identifies it.
uichemy_get_colors
ChatGPTWhat every colour in this project IS — the vocabulary, not a list of hexes. Read it before choosing any colour. Every colour decision here is made by ROLE: uichemy_set_text_style takes colorRole: "titleLight", the templates paint from bgLight1 / bgLight2 / bgDark1 / bgDark2, and a section painted anything outside the palette mints a new swatch — of which a project holds five. Without this a caller is choosing between hexes with no meaning attached, and picks one that looks right while the palette already had that exact surface under a name.
uichemy_get_images
ChatGPTEvery picture and clip in the project, with the FULL url, and the section each one sits in. uichemy_set_images writes and nothing read it back: after uploading eighty pictures the only record of which token holds which was whatever the caller kept by hand, and losing it meant rebuilding the mapping by eye. Slots still showing the template's stock picture are named too — those are the ones worth filling. Urls stored against tokens no section renders any more are listed last.
uichemy_get_logo
ChatGPTEvery place a logo appears, and what is in each: the SITE's logo slots (navbar, footer, coming-soon / 404), with the band each one sits on, and the PARTNER slots — client logos in content sections, which hold their own picture. Use it to check that no slot is still showing the template's built-in mark or a placeholder from the image library — a slot nobody filled does not look empty, it looks like somebody else's brand.
uichemy_get_page
ChatGPTOne page's sections in order, and EVERY slot in each — text and images, filled or empty, with the token, what the slot is for, its character cap and what is in it now. Use it to find the slot token a piece of text lives in before changing that text, and to see which slots are still rendering their own token or the template's stock picture.
uichemy_get_page_settings
ChatGPTRead each page's Settings — slug, meta title and description, social image, canonical URL, language, indexing, AI crawlers, advanced search options and custom code — as the editor's Page Settings screen shows them. Defaults are named as defaults.
uichemy_get_project
ChatGPTLook INSIDE a UiChemy project: its pages in order, the sections on each, the palette, the fonts, the button and card designs, and whether it was imported from an existing site. Call this before changing anything — the design tools need the current values to describe what they are about to replace, and an imported project answers to rules a generated one does not.
uichemy_get_style_kit
ChatGPTThe stylesheet UiChemy library sections need in the user's own React app (uichemy_get_page_code already includes it). Returns a download command for one self-contained CSS file — type scale, palette, radii, shadows, animations and every utility the given layouts use — that works with Tailwind v4, v3 or none. It covers the layouts passed, so pass every layout the app uses; when a section is added, run it again with the full list. palette (hex) and fonts (Google Fonts) brand every section at once. Set inline only when the caller cannot run a command.
uichemy_get_text
ChatGPTThe FULL copy in named slots. uichemy_get_page clips every value at 80 characters so a page of forty slots stays readable, which makes it useless for reading a paragraph back — a rebuild from it would truncate every passage over 80 characters, silently. This is the reader for those: exact values, nothing clipped. Ask for the tokens you need, or name a page to read everything on it. A page of long-form copy is large, so a page read is capped and says so when it caps.
uichemy_import_files
ChatGPTCreates a UiChemy project from HTML, CSS and JavaScript files passed in the call (no hosting step), for a site written from a prompt. A site that already exists as a .zip archive, on the web (zipUrl) or on the user's machine (zipData), goes through uichemy_import_zip instead; unpacking an archive and re-typing its files here loses bytes the archive had. An index.html at the root is the home page, and the other pages are ordered by the links the home page makes to them, in document order, so the navigation is the sitemap. A page no link points to is placed last. Plain, semantic HTML imports best: a section per <section>, real headings, real <img> tags. uichemy_section_spec describes the vocabulary the design system reads back. Stylesheets can be separate files or <style> blocks; both are read. The result lists the pages, sections, assets stored and assets skipped. The Design tab then offers only what each section allows (its text and images); the WordPress export ships the site's own code once uichemy_sync_builders has run (uichemy_mark_exported runs it).
uichemy_import_spec
ChatGPTREAD THIS BEFORE IMPORTING A ZIP of an existing website, and again whenever an imported site renders wrong. Returns what the importer does to their files, the two surfaces it renders on and why they differ, how to verify an import honestly, and a table of real failures listed BY THE SIGNATURE THEY LEAVE — each naming the one file that owns the fix. The single most important rule: the uploaded zip is EVIDENCE, NOT A DEFECT. A site that works in a browser and not in UiChemy is a bug in the importer, so do not rewrite the user's files to make an import succeed unless they ask.
uichemy_import_zip
ChatGPTImport an EXISTING website — their HTML, CSS and JavaScript, zipped — and get a UiChemy project back. Pass EXACTLY ONE of: zipUrl — a publicly reachable https url, which this server fetches; or zipData — the archive's own bytes as base64, for a .zip that is on the user's machine rather than on the web. READ THE FILE AND PASS ITS BYTES; do not unpack a local archive and re-type its files through uichemy_import_files, which makes you a lossy channel for bytes nobody needs you to read and is usually larger than the zip besides. CALL uichemy_import_spec FIRST. Its most important rule: the zip is EVIDENCE, NOT A DEFECT — a site that works in a browser and not in UiChemy is a bug in the importer, so do not rewrite the user's files to make an import succeed unless they ask. After it returns, say what actually happened: pages, sections, assets stored, assets SKIPPED by name, and any sectionError — an import can succeed and still be worth talking about. To export it, uichemy_sync_builders puts each section in Label Studio with its Elementor and Gutenberg code (uichemy_mark_exported runs it).
uichemy_insert_saved_section
ChatGPTOVERWRITES: the saved copy, pictures, clips and button/badge choices are written per layout, so they replace those in any existing section that uses the same layout. Put a saved section into a page — the layout, then its copy, pictures, videos and per-button / per-badge choices — through uichemy_add_section, so the page is written exactly the way adding a section always writes it. Its background colour is reported rather than painted: set it with uichemy_set_section_background if you want it here too.
uichemy_list_exported
ChatGPTThe projects on this account that are marked exported, with the builder each went to.
uichemy_list_icon_overrides
ChatGPTThe icons this project has had replaced, and under which key. Two key schemes exist — a LABEL shared by every instance of an icon, and a POSITIONAL id naming one element — and knowing which you are looking at is what stops a change from fighting an existing one.
uichemy_list_icons
ChatGPTEvery icon SLOT the pages render, whether or not anything has been put in one — which is what uichemy_list_icon_overrides cannot tell you, because it lists only icons already replaced. On a project where none have been it answers "No icons replaced", and there was no id to write to; the icons were unreachable until somebody picked one by hand in the browser. The slot label is authored in the template, so it is readable without a rendered page. instances is how many icons on that section wear the same label — a loop-drawn row shares one, so replacing it replaces the row.
uichemy_list_links
ChatGPTEvery link on a page's sections — buttons and text links — with the key uichemy_set_link takes, where it points now, and any destination written into the LAYOUT itself (a phone number, an email, a map) that has no key and cannot be changed from here.
uichemy_list_projects
ChatGPTThe UiChemy projects this account can open, newest first. Use it to find the project id another tool needs, rather than asking the user to copy one out of a url.
uichemy_list_saved_sections
ChatGPTThe sections this account has saved with uichemy_save_section, newest first.
uichemy_list_section_backgrounds
ChatGPTEvery section in the project and the KEY its background is painted under — including the ones nobody has painted yet, which is the point: the key cannot be guessed, and a list of only the painted ones leaves no way to paint the first. A section marked global (navbar and footer, by default) has one key for the whole project, so painting it paints every instance on every page — said so here rather than discovered. It also lists the FOUR SURFACES the palette paints — the canvas picker's Light 1 / Light 2 / Dark 1 / Dark 2. Painting a section one of those keeps it inside the design system and adds no new swatch; painting it anything else mints one, and the strip holds five. The swatch strip is DERIVED from the colours in use: its tokens are assigned by luminance, so a colour's name tells you whether the canvas treats it as a light or a dark band.
uichemy_list_section_kinds
ChatGPTEvery kind of section the UiChemy library ships — hero, features, pricing, footer and 60-odd more — with how many layouts each has. Start here when building a project from the library rather than from an uploaded site.
uichemy_list_sites
ChatGPTEvery site this account has published on uichemysites.com, and how many more it may have.
uichemy_list_templates
ChatGPTThe layout ids available for one section kind. Pick one and call uichemy_template_slots to find out what copy it needs.
uichemy_list_text_styles
ChatGPTThe per-element text styles this project has set — alignment, size, colour role and semantic tag, keyed by the same text_* slot the copy lives in. These are the Text panel's per-element controls, not the global type scale.
uichemy_list_variants
ChatGPTThe colour variants on this project — the sidebar's Variant 1, Variant 2 … Each is a whole palette the user can switch between, kept alongside the applied one, so this is how you see what alternatives a project already has before adding another.
uichemy_mark_exported
ChatGPTMark a project as exported, which is what puts it in the Exported list and what the WordPress plugin reads. It does NOT generate the Elementor or Gutenberg payload — the plugin pulls that itself when it syncs — so say that plainly rather than implying a file was produced.
uichemy_open_preview
ChatGPTOpen a UiChemy project inside ChatGPT, in the real UiChemy canvas editor, or in the full-page preview of one page (view: "preview"). Call it after changing a project so the user sees the result. Without a projectId it opens the dashboard so the user can pick one.
uichemy_open_projects
ChatGPTOpen the UiChemy dashboard (the user's projects) inside ChatGPT. Use when the user wants to see, pick or open one of their UiChemy sites, or just open UiChemy.
uichemy_open_site_admin
ChatGPTSign the user in to the WordPress ADMIN (wp-admin dashboard) of a project's hosted site on uichemysites.com. Call it whenever the user asks to open, log in to, or get into the site's admin, dashboard or backend. Returns a one-time link that signs them straight in, no username or password needed: give them the link right away, it works ONCE and expires about a minute after this call. If it has expired, call this again for a fresh one. Never send the user to /wp-admin or wp-login.php instead: UiChemy created the admin account and the user does not know its password. For a username and password they can keep, use uichemy_site_admin_login.
uichemy_publish_site
ChatGPTPut a project ONLINE as a real WordPress site at https://<address>.uichemysites.com, hosted by UiChemy: the pages are exported and imported into WordPress with the UiChemy plugin. This is PUBLIC: anyone with the link can see it, so only call it when the user asks to publish, go live, or put the site online, and tell them the address. One site per project; calling it again for a published project UPDATES that same site (same address, pages replaced with the current design). An account can have as many sites as projects its plan allows; unpublishing frees one. Only generated pages are published. Publishing takes a few minutes: this returns at once with the address, then check progress with uichemy_publish_status. WordPress only. To open the site's WordPress admin afterwards, use uichemy_open_site_admin (the user has no password for it).
uichemy_publish_status
ChatGPTWhere a publish is up to, or the project's hosted site if no publishId is given: its address, whether it is live, setting up or failed, and when it was last published.
uichemy_remove_page
ChatGPTDelete a page and everything on it — its sections' layouts, their backgrounds, overlays and padding, and the copy and pictures in their slots. Copy a section on ANOTHER page still renders is kept: slot tokens belong to the layout, not the page. The home page cannot be removed; it is the root every other page hangs off. What was deleted is reported — this destroys writing, and the caller has to be able to say so.
uichemy_remove_post
ChatGPTDelete one blog post. The posts above it are RENUMBERED down, because the canvas finds a post by its number — including which article page belongs to it — so a hole in the numbering is an empty card on the listing and an article page looking for a post that is not there. The listing's card pictures move down with them. Before this the only way to remove a post was to overwrite the whole list positionally, which created article pages as a side effect: three deletions cost two extra pages. The surplus article page goes with the post, unless keepPages says otherwise.
uichemy_remove_section
ChatGPTTake a section off a page. Everything after it moves up, and its variant keys are rebuilt — a stale key is how a removed section reappears on the next change. Everything else the section owned goes with it: its background, its overlay, its padding, and the copy and pictures in its slots — unless another section still renders that layout, in which case the copy is shared and is kept. What was dropped is reported, because it is the user's writing. The last Post Featured Area or Post Content on a blog detail page cannot be removed: they are what puts the post on the page.
uichemy_remove_section_background
ChatGPTStop painting a section — or clear the paint left behind by sections that are gone. Give sectionKey (one uichemy_list_section_backgrounds shows) to unpaint that section: both what it wears and the override that survives a style recompute, so the colour does not come back on the next one. Give orphans: true instead to drop every per-section background, overlay and padding whose section is no longer in the project. Those are what deletes left behind before deletes took their own state with them, and nothing else can reach them: the page they name does not exist, so no page tool will answer for it. uichemy_validate lists them as orphan-section-key. The swatch strip is derived, so a colour nothing wears any more drops out of it by itself.
uichemy_remove_swatch
ChatGPTRemove one saved section colour from the swatch strip — the background picker's remove button. Every section painted that colour is unpainted with it (back to its section style's colour), as in the editor; the strip is rederived.
uichemy_rename_page
ChatGPTChange what a page is called. Its id does not change, and neither does any of its sections' — every layout, background and piece of copy is keyed against those, so a rename is safe. The variant aliases that embed the old name are rebuilt under the new one.
uichemy_reorder_pages
ChatGPTPut the pages in a new order. Pass every page name exactly once, in the order you want them. The home page stays first — it is the root every other page hangs off. The Design canvas draws one card per page in exactly this order (it does not group by category). The Site map tab groups pages under their category's container, and the order of those containers is fixed by the app; within a container pages keep this order.
uichemy_reorder_sections
ChatGPTPut a page's sections in a new order. Pass every position once, 1-based, in the order you want them — [3,1,2] moves the third to the front.
uichemy_replace_section
ChatGPTSwap the layout rendering at one position — same slot, different template. The copy does NOT carry over: slot tokens belong to the template, so the new one has its own and will render them raw until filled. Call uichemy_template_slots for the new layout and pass text.
uichemy_save_section
ChatGPTSave one section — its layout AND its copy, pictures, videos and per-button / per-badge choices — so it can be put into any other project with uichemy_insert_saved_section. Saved to this account; uichemy_list_saved_sections shows them. Library layouts only: an AI or code section cannot be saved.
uichemy_search_layouts
ChatGPTFind layouts by DESCRIBING what you want — "a hero with a big photo and one line of copy", "a pricing table for three plans". This is the semantic search the app's own layout selection uses, matched against the labelling team's descriptions of each layout. Prefer it to uichemy_find_templates when the need is a feeling rather than a field: find_templates filters on exact values (2 columns, photo, airy) and never leaves the machine; this one understands the sentence and needs Label Studio to answer. Hits the library cannot render are dropped, so what comes back is pickable.
uichemy_section_spec
ChatGPTREAD THIS FIRST, before writing any section. Returns the exact vocabulary a UiChemy section may use — the section kinds, the type scale, the button and radius classes, the colour tokens — plus every rule the validator enforces and one section that passes.
uichemy_set_badge_design
ChatGPTMake ONE badge louder or quieter — Outline, Solid, Soft, Dot or Underline. The site-wide badge look is a separate thing; this is "this particular eyebrow should stand out". The key is the badge's own text slot, which uichemy_get_page lists against it, and which the exported site resolves too. A key belongs to the TEMPLATE, so a layout used on three pages changes on all three. Pass design: 0 to put it back to the site-wide design.
uichemy_set_badge_style
ChatGPTThe site-wide badge look — the Style Guide's Badges panel: size, corner radius, whether badges show their icon, and the design (1 Outline · 2 Solid · 3 Soft · 4 Dot · 5 Underline). uichemy_set_badge_design overrides ONE badge on top of this. design: null clears the pick, which leaves every badge as its layout drew it.
uichemy_set_button_design
ChatGPTChoose the button design, corner radius, size, icon and LABEL COLOUR — the Style Guide's Buttons panel. On an imported project this is what hands the site's buttons over to our design system — until it is called, their buttons stay theirs. Pass design: null to give them back ("keep the site's own look").
uichemy_set_button_role
ChatGPTMake ONE button primary, secondary or a plain link — the per-button control, not the site-wide button design uichemy_set_button_design sets. The key is the button's own label slot (text_…), or its icon slot for an icon-only button; uichemy_get_page lists both against each button. That key is what the exported site resolves too, so this reaches WordPress and not just the canvas. A key belongs to the TEMPLATE, so the same button in a layout used on three pages changes on all three — the same way per-element text styling already behaves. Pass role: "reset" to put it back to whatever the template paints.
uichemy_set_card_design
ChatGPTChoose the card design and corner radius. Same contract as the buttons: on an imported project the site's cards stay theirs until this is called.
uichemy_set_field_design
ChatGPTThe form-field look — the Style Guide's field control (what "Randomize fields" picks from): design 1 Soft fill · 2 Outlined white · 3 Heavy border · 4 Offset shadow · 5 Filled grey · 6 Pill outlined · 7 Icon prefixed · 8 Borderless; corner radius; whether fields show their leading icon. design: null clears the pick.
uichemy_set_fonts
ChatGPTSet the heading and/or body font. On an imported project only the control you change is applied — changing the heading face leaves their body face and their weight, case and tracking exactly as the site had them.
uichemy_set_global_section
ChatGPTShare one section across pages — the editor's "Attach to a global". Every page's section of that kind renders the same layout, and because copy and images belong to the layout, they share the same words and pictures too: write them once. Globalness in the editor is per KIND across the whole site, so pages must cover every page that has the kind (or be "all"). Pass variant to put every instance on one layout first; omitted, they must already agree. global: false detaches the kind so instances can differ again.
uichemy_set_icon
ChatGPTReplace one icon. The id is the authored slot label — icon_url_…, from uichemy_list_icons — or a key uichemy_list_icon_overrides already shows. An authored label is a slot in the TEMPLATE, so a layout that draws its cards from one loop carries the same label on every card and this changes all of them; uichemy_list_icons says how many. The other key scheme is POSITIONAL (svg-<sectionId>-<n>), minted by auto-match from the rendered page and not derivable here. Writing a label while positional overrides exist is refused: the pair fights every frame and shows as the icon flickering between old and new.
uichemy_set_icon_color
ChatGPTColour icons — the Icon panel's colour control. One colour per icon key; the key is an authored label (icon_url_…, from uichemy_list_icons — every instance of that slot) or a key uichemy_list_icon_overrides shows. Colour is a role (primary, accent, titleLight …), { role, step } on its ramp, a #hex, or "auto" to follow the section again. Stored as the hex it resolves to, exactly as the panel stores a swatch pick, so it is painted on the canvas and in the export alike — and it does not follow a later palette change.
uichemy_set_icon_style
ChatGPTThe site-wide icon style for auto-matched icons — outline or filled. One choice for the whole site; hand-picked icons are left alone.
uichemy_set_image_display
ChatGPTHow a picture SITS in its slot: its aspect ratio, which part of it stays visible when the slot is a different shape (the focal point), and whether it is darkened for text to sit on. Alt text is stored here too. THESE ARE CANVAS SETTINGS. The WordPress export reads the overlay flag and nothing else, so a ratio or a position set here is not in the exported site — to change the picture itself, use uichemy_crop_image, which bakes the crop into a new file. Alt text is the exception: the canvas writes it onto the picture and the WordPress and Astro exports ship it as the img alt. uichemy_validate reports the pictures that have none.
uichemy_set_images
ChatGPTPut pictures in image slots. Slot tokens come from uichemy_template_slots; urls come from uichemy_upload_image, or any https url that will still be there tomorrow.
uichemy_set_link
ChatGPTPoint a button or text link somewhere — the editor's Link control. The key is the link's label slot (text_…) or, for an icon-only link, its icon slot (icon_url_…); uichemy_list_links lists them. Takes https://…, a site path (/contact), #anchor, mailto: or tel:. An empty href puts back the template's own. A key belongs to the LAYOUT, so a navbar used on every page gets the link on every page. The WordPress and Astro exports ship it.
uichemy_set_logo
ChatGPTThe site's logo, painted onto every navbar and footer (and coming-soon / 404 mark) that carries one — or, with slot, ONE client/partner logo slot. Pass a LIGHT-BACKGROUND logo as url and, when the brand has one, a light-coloured mark as darkUrl. Which one a slot gets is decided by the band its section is ACTUALLY painted — the section style (a dark nav + hero, a dark footer), a background you picked, a dark bar inside the layout — the same answer the canvas reaches, and that per-slot choice is what the export ships. A single dark logo on a dark navbar is invisible; pass the pair. scale sizes the logo per area exactly like the panel's slider (0.5-2, 1 = as designed). PARTNER LOGOS: a logo_url_… slot in a content section labelled as a client or partner mark (a 'trusted by' row) holds that client's logo, never the site's. uichemy_get_logo lists them; pass slot + url to set one. There is no logo COLOUR to set: the canvas adapts each shape of an uploaded SVG to its section, and no stored colour is read by the canvas or the export. uichemy_upload_image will give you a url for a picture you hold.
uichemy_set_page_category
ChatGPTMove a page to another group of the sitemap — Core, Blog, Legal, Site Extras or Shop — IN PLACE. Its id, its sections' ids, layouts, copy, backgrounds and slug are untouched; only the group changes. The home page is the root and has no group to move.
uichemy_set_page_settings
ChatGPTSet one page's Settings — the editor's Page Settings screen: slug, meta title, meta description, canonical URL, language, social image, "Show this page in Google", follow links, "Ask AI crawlers not to use this page", image size in search results, longest text preview, and custom code. Only the fields passed change; null or "" clears one. The WordPress and Astro exports ship these. Saving needs a Superadmin, Marketing or Posimyth Team account while the feature is in testing.
uichemy_set_palette
ChatGPTSet the project's colour palette, and the controls that sit beside it in the editor. Hex values only. The colour roles (uichemy_get_colors) are derived in the same write, so role-based tools work straight after it with no canvas open. saturation is the palette's tint slider (0-100): it tints the title and description inks with the main colour, exactly as the slider does; titleColor / descriptionColor pin those two inks instead. On an IMPORTED project this also repaints the site's own stylesheet, because its colours are bound to these slots — call uichemy_get_project first and tell the user before doing it.
uichemy_set_section_background
ChatGPTOne section's background band — its colour, the dark scrim over it, and how tall it is. The key is one uichemy_list_section_backgrounds shows: it identifies the template, the section and its variant, so it cannot be guessed. COLOUR: three fields move together — what the section is painted, the override that survives a section-style recompute, and the DERIVED swatch list whose token names the canvas and the export both read. Writing the first two alone is the 'colour lands in the swatch but the section stays black' fault. SCRIM: for a section whose background is a picture. "black" darkens it so text reads, "off" removes a tint the template painted itself, and "reset" leaves the template's own tint alone — 44 layouts draw one, and off is not the same as never asked. HEIGHT: a multiplier of the page's vertical rhythm, not pixels — 1.5 is half again as tall at every screen width, 1 puts the section back on the global rhythm. There is no gradient or pattern background: the product has neither, on this side or in the editor. A picture background is an image slot in the layout — set it with uichemy_set_images.
uichemy_set_section_style
ChatGPTHow sections alternate their backgrounds across the page — the Section Style control. These three are what the panel ships; the stored field accepts more, but nothing offers them and they are not drawn in the editor. On an imported project this takes the site's own band backgrounds over, so say so first.
uichemy_set_spacing
ChatGPTThe page's vertical rhythm and side gutter — the Spacing control. sectionY is the padding between sections, sectionX the gutter at the sides.
uichemy_set_text
ChatGPTReplace the copy in one or more text slots. Get the slot tokens from uichemy_get_page — a token that is not on the page writes an override nothing renders. Copy longer than the slot's max (see uichemy_template_slots) is refused. OVERWRITES the current copy and does not keep the old wording: read it with uichemy_get_page first if the user may want it back.
uichemy_set_text_style
ChatGPTStyle ONE element — its alignment, size, colour, hover colour or semantic tag — keyed by the text_* slot its copy lives in (uichemy_get_page lists those, including badge labels). This is the Text panel, not the global scale: use uichemy_set_type_scale to move every heading at once. COLOUR takes a ROLE (primary, accent, extra1, extra2, titleLight, descriptionLight), which follows palette changes and the surface the text sits on; a RAMP SHADE { role, step } (0 is the lightest of the picker's ten); or a #hex. A shade or a hex is stored as that hex and does not follow a later palette change. hoverColorRole takes the same. A BUTTON label takes no per-element colour — in the editor either — because its ink belongs to the button's role; use uichemy_set_button_design labelColor. SIZE IS A SLOT ON THE GLOBAL SCALE — heading-lg, body-md — painted as a variable, so a resized element still ramps across breakpoints instead of pinning to one pixel value.
uichemy_set_theme
ChatGPTLight or dark mode, and the section style (footerColorMode). The editor normally derives the theme from the page background — uichemy_set_palette does the same when bg changes — so set it here only to override that. footerColorMode: subtle_01 Clean Light · subtle_02 Light + Dark Footer · zigzag_pure Pure Zigzag. Call uichemy_create_canvas afterwards to repaint the section bands headlessly.
uichemy_set_type_scale
ChatGPTThe typography controls beyond the font itself: size, weight, case, letter spacing and line height, for headings and body separately. On an IMPORTED project each of these is applied on its own — setting the heading weight leaves their case and tracking exactly as the site had them, so change only what was asked for.
uichemy_set_videos
ChatGPTPut a clip in a slot. Two kinds of slot, and both are taken here: a VIDEO slot — video_url_…, the <video> a handful of layouts ship — and an IMAGE slot (image_url_…, portrait_image_url_…) turned into a video, which is the Image panel's 'Convert to Video': the picture stays as the poster underneath and the clip covers its exact box. Slot tokens come from uichemy_get_page or uichemy_template_slots. playback mirrors the Video panel for a converted image slot: startTime (seconds), preload, mobile ("poster" serves the still alone on phones) and overlay (0-100 % black over the clip). loop / muted / autoplay / controls are NOT settable there — a converted slot is decoration, so the engine always loops it muted with no controls and decides autoplay per surface; and it has no fit or ratio of its own, it takes the image slot's (uichemy_set_image_display). The panel stores no playback for a template video_url_… slot either, so none is accepted there. remove turns converted image slots back into pictures. An unset video_url slot is NOT broken — the canvas fills it from stock footage on first render.
uichemy_site_admin_login
ChatGPTWordPress admin login details for a project's hosted site: the admin username and a NEW password, so the user can sign in at wp-login.php any time. Only call it when the user asks for the username/password or login details (to just get into the admin now, use uichemy_open_site_admin). Each call sets a new password: the previous one stops working and anyone signed in to that admin is signed out. The password is shown once and UiChemy does not keep it, so tell the user to save it.
uichemy_sync_builders
ChatGPTFor a project IMPORTED from code (uichemy_import_zip / uichemy_import_files): put every imported section in Label Studio with its Elementor and Gutenberg code — their own HTML, the part of their CSS each section uses, their page script, and the copy and pictures as edited. This is what makes the WordPress export ship the uploaded site rather than fallback templates. uichemy_mark_exported runs it too; call this to check the result first. Unchanged sections are skipped unless force is set.
uichemy_template_slots
ChatGPTWhat copy a template needs, slot by slot: WHAT EACH SLOT IS — headline, eyebrow, primaryButton, cardTitle, price, quote — and WHERE IT SITS ("plans 2 of 3", "section header"), plus the template's sample copy and the MOST CHARACTERS it takes. The layout was designed around the sample's length; copy over max is refused by every tool that writes it. Write to about the sample's length, and put each piece of copy in the slot whose for matches it — a name in the name slot, a review in the review slot. READ THIS BEFORE WRITING COPY, and fill every slot: a UiChemy template renders its TOKEN, so a slot left empty puts text_a1b2c3 on the page at whatever size the design paints it. There is no placeholder to improve on later — unfilled is broken.
uichemy_unpublish_site
ChatGPTTake a project's site OFFLINE and delete it: the WordPress site at its uichemysites.com address is removed, including anything changed in its WordPress admin, and the address is freed. The UiChemy project itself is not touched and can be published again. Irreversible: confirm with the user first, naming the address.
uichemy_update_code_section
ChatGPTOVERWRITES a section on the user's page: its previous code, copy and pictures are replaced and not kept. Confirm with the user before rewriting a section they have edited. Rewrite a section on a page — same page, same position, new code. Its copy and pictures come from the new code: canvas edits made to the OLD section do not carry over. Any format can replace any other, and a library layout can be replaced by your own code.
uichemy_upload_image
ChatGPTStore a picture in UiChemy and get back a url for an image slot. Pass EXACTLY ONE of: url — a picture already on the web (the image file's own url, not a page), which is copied into our storage so it cannot break later; or data — base64 / a data: URI for a picture you generated as bytes. A picture the user attached in chat cannot be passed as base64; ask them for its url instead. Stored exactly where the image panel stores one (WebP, content-hashed, our own storage). Pass the returned url to uichemy_set_images or to create_project's images.
uichemy_upload_ticket
ChatGPTA way to upload pictures you have ON DISK without retyping them as base64. uichemy_upload_image is the right tool for a picture you generated as bytes, but its payload travels through the model a token at a time, so a folder of photos costs minutes and arrives shrunken. This hands back a short-lived ticket and a curl line: the bytes go straight from the file to our storage, at full size, and never enter the conversation. Same pipeline as the image panel (WebP, content-hashed, R2), so the result is indistinguishable downstream. The ticket lasts 10 minutes, is fixed to THIS project, and is write-only — it reads nothing. Each upload answers with the stored url; pass those to uichemy_set_images.
uichemy_validate
ChatGPTCheck the whole project for the faults that do not raise an error anywhere: slots still rendering their own token, pictures saved into one store and read from another, per-section colours keyed to a layout the section has moved off, overrides belonging to sections that no longer exist, icon keys that fight each other, a logo the navbars never received, a blog detail page with no post on it, a blog whose tag and author links point at pages that do not exist. Every check here is an already-reported failure, and each is invisible until somebody opens the right page on the right surface — which is why an agent should run this before telling anyone the work is done.
uichemy_whoami
ChatGPTWhich UiChemy account this connection is signed in as, and what it can reach. Call this first when something is refused — connecting the wrong account is the commonest cause, and it looks identical to a broken server.