Feature flags

Feature flags let you control how and when functionality is delivered to users by toggling behavior in your code without deploying changes. In the Atono public API, each feature flag includes its key, variants, and creation metadata, as well as environment-specific configurations through flag_environment relationships.


Flag attributes

FieldTypeDescription
idstringThe UUID or key of the feature flag.
keystringThe flag name used to identify this feature flag in your codebase or SDK configuration. This name is unique within your workspace.
variantsobjectA list of named variants the flag can evaluate to. Each variant maps to a value used in your application. For boolean flags, variants include "on": true and "off": false.
createdAtdatetime (ISO 8601)The date and time the feature flag was created.
updatedAtdatetime (ISO 8601)The date and time the feature flag was last updated.

Flag relationships

FieldTypeDescription
slicesarray of objectsThe flag’s configuration for each environment, linked via flag_environment objects.

Each related flag_environment includes:

FieldTypeDescription
configurationstringThe current configuration for the environment (on, off, or MIXED).
environmentCodestringThe environment associated with this configuration (e.g., prod, test).

Example JSON for flag

{
  "data": {
    "type": "flag",
    "id": "56338410-4aa2-417c-acf1-eda94d344c5f",
    "attributes": {
      "key": "improve_patch_loading_time23",
      "variants": {
        "on": true,
        "off": false
      },
      "createdAt": "2024-08-09T23:35:39Z",
      "updatedAt": "2025-05-08T21:36:44Z"
    },
    "relationships": {
      "slices": {
        "links": {
          "self": "/api/v1/flags/56338410-4aa2-417c-acf1-eda94d344c5f/environments"
        },
        "data": [
          {
            "type": "flag_environment",
            "id": "bc25a1cc-d41b-4d07-9b80-09b80b90199f"
          },
          {
            "type": "flag_environment",
            "id": "4b7885f4-5942-472a-855c-0dfe07702d00"
          },
          {
            "type": "flag_environment",
            "id": "5b213133-229b-4854-9fc3-86e1a0377cbe"
          },
          {
            "type": "flag_environment",
            "id": "94066897-46e2-4084-9b6f-cdeb8f28fa6f"
          }
        ]
      }
    }
  },
  "included": [
    {
      "type": "flag_environment",
      "id": "bc25a1cc-d41b-4d07-9b80-09b80b90199f",
      "attributes": {
        "configuration": "off"
      },
      "relationships": {
        "flag": {
          "links": {
            "related": "/api/v1/flags/56338410-4aa2-417c-acf1-eda94d344c5f"
          },
          "data": {
            "type": "flag",
            "id": "56338410-4aa2-417c-acf1-eda94d344c5f"
          }
        }
      },
      "meta": {
        "environmentCode": "prod"
      }
    },
    {
      "type": "flag_environment",
      "id": "5b213133-229b-4854-9fc3-86e1a0377cbe",
      "attributes": {
        "configuration": "off"
      },
      "relationships": {
        "flag": {
          "links": {
            "related": "/api/v1/flags/56338410-4aa2-417c-acf1-eda94d344c5f"
          },
          "data": {
            "type": "flag",
            "id": "56338410-4aa2-417c-acf1-eda94d344c5f"
          }
        }
      },
      "meta": {
        "environmentCode": "test"
      }
    },
    {
      "type": "flag_environment",
      "id": "94066897-46e2-4084-9b6f-cdeb8f28fa6f",
      "attributes": {
        "configuration": "MIXED"
      },
      "relationships": {
        "flag": {
          "links": {
            "related": "/api/v1/flags/56338410-4aa2-417c-acf1-eda94d344c5f"
          },
          "data": {
            "type": "flag",
            "id": "56338410-4aa2-417c-acf1-eda94d344c5f"
          }
        }
      },
      "meta": {
        "environmentCode": "dev"
      }
    },
    {
      "type": "flag_environment",
      "id": "4b7885f4-5942-472a-855c-0dfe07702d00",
      "attributes": {
        "configuration": "off"
      },
      "relationships": {
        "flag": {
          "links": {
            "related": "/api/v1/flags/56338410-4aa2-417c-acf1-eda94d344c5f"
          },
          "data": {
            "type": "flag",
            "id": "56338410-4aa2-417c-acf1-eda94d344c5f"
          }
        }
      },
      "meta": {
        "environmentCode": "stage"
      }
    }
  ]
}