Managing your storefront
Edit your brand page, theme, and sections with a store:write personal access token.
Editing your storefront — the brand page, theme, and section layout — needs a
token with the store:write scope. Grant it at Settings → API tokens
(/vendor/settings/api). Everything is scoped to your company; a token can only
edit its own storefront.
Validate section and theme payloads before sending them with the validate_code
tool (see the AI Toolkit) — it runs the same schema the API
enforces.
Theme
curl -X PATCH "$IORDERTRACK_API_URL/companies/123/store-theme" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "theme": { "primaryColor": "#1d4ed8", "secondaryColor": "#f59e0b",
"fontFamily": "Inter" } }'Brand page
curl -X PATCH "$IORDERTRACK_API_URL/companies/123/storefront" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "storefrontTagline": "Linens, woven to last", "storefrontAbout": "Family-run since 1974." }'Sections
A storefront is an ordered list of sections (hero, banner, rich_text,
image_text, faq, product_grid). Each has a typed config.
# Add a section
curl -X POST "$IORDERTRACK_API_URL/companies/123/store-sections" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "type": "banner", "config": { "text": "Free shipping over $75", "href": "/c/sale" } }'
# Update a section's config
curl -X PATCH "$IORDERTRACK_API_URL/companies/123/store-sections/456" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "config": { "text": "Free shipping over $50" } }'
# Reorder sections (ids in the order you want)
curl -X POST "$IORDERTRACK_API_URL/companies/123/store-sections/reorder" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "sectionIds": ["456", "789", "123"] }'
# Delete a section
curl -X DELETE "$IORDERTRACK_API_URL/companies/123/store-sections/456" \
-H "Authorization: Bearer $IORDERTRACK_API_TOKEN"Read the current sections + theme any time (no write scope needed) with
GET /storefronts/{handle}/store-config, or through the toolkit's
store_execute (list_sections, get_theme).
With the AI Toolkit
The store_write tool exposes update_storefront, update_theme,
add_section, update_section, reorder_sections, and delete_section. Pass
companyId (and sectionId for section edits). Validate section/theme bodies
with validate_code first. See the AI Toolkit.