ATUM REST API

Settings

ATUM

The settings API allows you to view all groups of ATUM settings available and to batch update setting options from different groups at once. To view or update the options within a group, see Setting options.

The settings endpoints require the ATUM manage_settings capability. The available groups depend on the enabled ATUM modules and the installed add-ons.

Setting group properties

AttributeTypeDescription
idstringA unique identifier that can be used to link settings together. read-only
labelstringA human readable label for the setting used in interfaces. read-only
descriptionstringA human readable description for the setting used in interfaces. read-only
sectionsobjectThe sections within the group, as section_id: label pairs. read-only

List all settings groups

This API helps you to view all the settings groups.

HTTP request

GET/wp-json/wc/v3/atum/settings
curl https://example.com/wp-json/wc/v3/atum/settings \
	-u consumer_key:consumer_secret
JSON response example
[
    {
        "id": "general",
        "label": "General",
        "description": "",
        "sections": {
            "general": "General Options",
            "list_tables": "List Tables"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/general"
                }
            ]
        }
    },
    {
        "id": "store_details",
        "label": "Store Details",
        "description": "",
        "sections": {
            "company": "Company info",
            "shipping": "Shipping info"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/store_details"
                }
            ]
        }
    },
    {
        "id": "advanced",
        "label": "Advanced",
        "description": "",
        "sections": {
            "advanced": "Advanced Options"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/advanced"
                }
            ]
        }
    },
    {
        "id": "module_manager",
        "label": "Modules",
        "description": "",
        "sections": {
            "module_manager": "Module Manager"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/module_manager"
                }
            ]
        }
    },
    {
        "id": "stock_central",
        "label": "Stock Central",
        "description": "",
        "sections": {
            "stock_central": "Stock Central Options"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/stock_central"
                }
            ]
        }
    },
    {
        "id": "visual_settings",
        "label": "Visual Settings",
        "description": "",
        "sections": {
            "color_mode": "Color Mode",
            "color_scheme": "Color Scheme"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/visual_settings"
                }
            ]
        }
    },
    {
        "id": "notifications",
        "label": "Notifications",
        "description": "",
        "sections": {
            "atum_notifications": "Email Notifications"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/notifications"
                }
            ]
        }
    },
    {
        "id": "multi_inventory",
        "label": "Multi-Inventory",
        "description": "",
        "sections": {
            "mi_multi_inventory": "Multi-Inventory Options",
            "mi_geoprompt": "Geo Prompt Popup"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/multi_inventory"
                }
            ]
        }
    },
    {
        "id": "product_levels",
        "label": "Product Levels",
        "description": "",
        "sections": {
            "pl_product_levels": "General Options",
            "pl_manufacturing_central": "Manufacturing Central Options"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/product_levels"
                }
            ]
        }
    },
    {
        "id": "tools",
        "label": "Tools",
        "description": "",
        "sections": {
            "tools": "ATUM Tools"
        },
        "_links": {
            "options": [
                {
                    "href": "https://example.com/wp-json/wc/v3/atum/settings/tools"
                }
            ]
        }
    }
]

Batch update setting options

This API helps you to batch update multiple setting options, even if they belong to different groups. Each item must include the group_id and the id of the setting option, and its new value. To update setting options within a single group, you can also use the setting options batch endpoint.

Only the update action is supported, as setting options can't be created or deleted. By default it's limited to up to 100 objects.

HTTP request

POST/wp-json/wc/v3/atum/settings/batch
curl -X POST https://example.com/wp-json/wc/v3/atum/settings/batch 	-u consumer_key:consumer_secret 	-H "Content-Type: application/json" 	-d '{
      "update": [
        {
          "group_id": "general",
          "id": "enable_admin_bar_menu",
          "value": "no"
        },
        {
          "group_id": "store_details",
          "id": "company_name",
          "value": "My Store Inc."
        }
      ]
    }'
JSON response example
{
    "update": [
        {
            "id": "enable_admin_bar_menu",
            "group": "general",
            "section": "general",
            "name": "Enable admin bar menu",
            "desc": "When enabled, the ATUM menu will be accessible through the WP admin bar.",
            "type": "switcher",
            "default": "yes",
            "value": "no",
            "_links": {
                "self": [
                    {
                        "href": "https://example.com/wp-json/wc/v3/atum/settings/general/enable_admin_bar_menu"
                    }
                ],
                "collection": [
                    {
                        "href": "https://example.com/wp-json/wc/v3/atum/settings/general"
                    }
                ]
            }
        },
        {
            "id": "company_name",
            "group": "store_details",
            "section": "company",
            "name": "Company name",
            "desc": "Fill your company's name",
            "type": "text",
            "default": "",
            "value": "My Store Inc.",
            "_links": {
                "self": [
                    {
                        "href": "https://example.com/wp-json/wc/v3/atum/settings/store_details/company_name"
                    }
                ],
                "collection": [
                    {
                        "href": "https://example.com/wp-json/wc/v3/atum/settings/store_details"
                    }
                ]
            }
        }
    ]
}

On this page