Перейти до вмісту
AstroWay/api v2.19.0 · docs
усі системи в нормі
UA EN

Update White-label Config

PATCH
/whitelabel/config

Update one or more branding fields. Hex colours validated as #RRGGBB; custom_domain validated as RFC-1035 subdomain. Setting custom_domain resets domain_verified=false — call /whitelabel/domain/verify after pointing your CNAME to api.astroway.info.

curl -X PATCH https://api.astroway.info/v1/whitelabel/config \
-H "X-Api-Key: aw_live_..." \
-H "Content-Type: application/json" \
-d '{ "primary_color": "#0a0b1e", "footer_text": "© 2026 MyAstroBrand", "custom_domain": "api.myastrobrand.com" }'

Successful calculation

object
ok
boolean
Example
true
data
object
primary_color
string
secondary_color
string
font_family
string
footer_text
string
custom_domain
string
domain_verified
boolean
domain_last_checked_at
object
logo_storage_key
object
updated_at
string
Example
{
"ok": true,
"data": {
"primary_color": "#0a0b1e",
"secondary_color": "#7e6bff",
"font_family": "Inter",
"footer_text": "© 2026 MyAstroBrand",
"custom_domain": "api.myastrobrand.com",
"domain_verified": false,
"domain_last_checked_at": null,
"logo_storage_key": null,
"updated_at": "..."
}
}

Validation error

Example
{
"ok": false,
"error": {
"code": "INVALID_INPUT",
"message": "Validation failed: date: Date must be YYYY-MM-DD",
"details": [
{
"path": "date",
"message": "Date must be YYYY-MM-DD"
}
]
}
}

Missing or invalid API key

Example
{
"ok": false,
"error": {
"code": "INVALID_API_KEY",
"message": "Invalid API key"
}
}
Корисно?