Skip to main content

Create a configuration

API operation: Open the endpoint in the API reference

Use POST /configs to add a project configuration. The current public operation is Config.register.

The operation contract requires a unique key. It supports configuration types 1 through 5; value, options, and image requirements depend on the selected type. See the API Reference request schema for the complete field contract.

The behavior is operation-specific:

  • value is required unless type is 5.
  • options is required for types 2, 3, and 4 and is validated as structured JSON.
  • image is required for type 5; successful image handling stores its result as the configuration value.
  • Creating a configuration is restricted to the server or administrator roles represented by the current middleware.

Do not place credentials, provider secrets, or customer data in examples. Protected configuration values can be masked in API responses.

Legacy SDK example​

const response = await ordering.configs().save(data)

Confirm the SDK package and version before using this helper. The operation guide specifies POST /configs, including request fields, authentication, responses, and errors.