Configure how a Builder Space behaves across users, regions, and devices. Use these operations to manage targeting attributes, locales and locale groups, responsive breakpoints, and other environment-level settings.
Get the current settings for your Builder Space. For more details, see Spaces Overview.
Query
const response = await adminSDK
.query({
settings: true,
});Response
{
"data": {
"settings": { ... }
}
}Replace every custom targeting attribute for the current space while preserving the existing locale definition.
Query:
const result = await adminSDK
.chain.mutation.setCustomTargetingAttributes({
attributes: [
{
key: "plan",
schema: {
type: "string",
enum: ["free", "pro", "enterprise"]
}
}
]
})
.execute();Response:
{
"data": {
"setCustomTargetingAttributes": [
{
"key": "locale",
"schema": { "type": "string", "enum": ["en-US"] }
},
{
"key": "plan",
"schema": { "type": "string", "enum": ["free", "pro", "enterprise"] }
}
]
}
}Remove a single non-locale attribute.
Query:
const result = await adminSDK
.chain.mutation.deleteCustomTargetingAttribute({
key: "plan"
})
.execute();Response:
{
"data": {
"deleteCustomTargetingAttribute": [
{ "key": "device" }
]
}
}Create or update a single attribute, except locale.
Query:
const result = await adminSDK
.chain.mutation.upsertCustomTargetingAttribute({
key: "device",
schema: {
type: "string",
enum: ["mobile", "desktop"]
}
})
.execute();Response:
{
"data": {
"upsertCustomTargetingAttribute": [
{ "key": "device", "schema": { "type": "string", "enum": ["mobile", "desktop"] } }
]
}
}Remove a locale value and clean up related groups.
Query:
const result = await adminSDK
.chain.mutation.setSpaceLocales({
locales: ["en-US", "de-DE", "es-ES"]
})
.execute();Response:
{
"data": {
"setSpaceLocales": {
"enum": ["en-US", "de-DE", "es-ES"]
}
}
}Add or update a locale entry, optionally attaching descriptions and groups.
Query:
const result = await adminSDK
.chain.mutation.upsertSpaceLocale({
locale: {
name: "fr-FR",
description: "French",
groups: ["eu"]
}
})
.execute();Response:
{
"data": {
"upsertSpaceLocale": {
"enum": ["en-US", "fr-FR"],
"descriptions": [
{ "name": "en-US", "description": "English" },
{ "name": "fr-FR", "description": "French", "groups": ["eu"] }
]
}
}
}Remove a locale value and clean up related groups.
Query:
const result = await adminSDK
.chain.mutation.deleteSpaceLocale({
locale: "fr-FR"
})
.execute();Response:
{
"data": {
"deleteSpaceLocale": {
"enum": ["en-US"]
}
}
}Replace the complete set of locale groups.
Query:
const result = await adminSDK
.chain.mutation.setSpaceLocaleGroups({
groups: [
{ name: "amer", defaultLocale: "en-US" },
{ name: "emea", defaultLocale: "en-GB" }
]
})
.execute();Response:
{
"data": {
"setSpaceLocaleGroups": {
"groups": {
"amer": "en-US",
"emea": "en-GB"
}
}
}
}Remove a locale group and associated memberships.
Query:
const result = await adminSDK
.chain.mutation.deleteSpaceLocaleGroup({
name: "emea"
})
.execute();Response:
{
"data": {
"deleteSpaceLocaleGroup": {
"groups": {}
}
}
}Create or update a locale group with a default locale.
Query:
const result = await adminSDK
.chain.mutation.upsertSpaceLocaleGroup({
name: "emea",
defaultLocale: "en-GB"
})
.execute();Response:
{
"data": {
"upsertSpaceLocaleGroup": {
"groups": { "emea": "en-GB" }
}
}
}Persist responsive breakpoints with validation (integers, ≥2px spacing).
Query:
const result = await adminSDK
.chain.mutation.setSpaceBreakpoints({
breakpoints: {
xsmall: 360,
small: 640,
medium: 1024
}
})
.execute();Response:
{
"data": {
"setSpaceBreakpoints": {
"xsmall": 360,
"small": 640,
"medium": 1024
}
}
}Continue to explore the Admin API documentation or use the GraphQL Explorer to try out these queries with your own Space and Organization. Then, visit the Admin API GraphQL Schema for more details on how to modify your queries.