---
title: GET /fields
slug: content-marketing-platform/api/get-fields
docTags: 
createdAt: 2026-10-01T18:51:26.265Z
---

{
  "id": "WCix87PjVm6eTtyoY1lmz",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "https://api.cmp.optimizely.com/v3/fields",
    "servers": [
      {
        "url": "https://api.cmp.optimizely.com/v3/fields",
        "description": "v3 version of Optimizely CMP Open API"
      }
    ],
    "name": "GET /fields",
    "description": "<p>Experimental Get the list of fields of an Organization.</p>",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [
        {
          "kind": "optional",
          "name": "ids",
          "type": "string",
          "example": "12p5ca474ba9i7cc92y164aa7",
          "description": "<p>Unique identifier of the field. Can be appended multiple times, such as <code>ids=fieldId1&#x26;ids=fieldId2</code></p>"
        },
        {
          "kind": "optional",
          "name": "offset",
          "type": "integer",
          "example": 5,
          "description": "<p>Starting index of results (zero indexed)</p>",
          "default": 0,
          "minimum": 0
        },
        {
          "kind": "optional",
          "name": "page_size",
          "type": "integer",
          "example": 15,
          "description": "Number of results to return per page",
          "default": 10,
          "minimum": 1,
          "maximum": 100
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "OAuth2",
          "name": "OAuth2",
          "kind": "optional",
          "type": "oauth2",
          "oauth2Flows": {
            "clientCredentials": {
              "tokenUrl": "https://accounts.cmp.optimizely.com/o/oauth2/v1/token",
              "scopes": {}
            },
            "authorizationCode": {
              "authorizationUrl": "https://accounts.cmp.optimizely.com/o/oauth2/v1/auth",
              "tokenUrl": "https://accounts.cmp.optimizely.com/o/oauth2/v1/token",
              "scopes": {
                "openid": "Grants the ability to receive a unique identifier for the user.",
                "profile": "Grants access to user profile information.",
                "offline_access": "Grants the ability to refresh access_token using the refresh token even when user is not present (not logged in)."
              }
            }
          },
          "requiredScopes": [
            "openid",
            "profile",
            "offline_access"
          ]
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "List of fetched fields",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "schema": [
              {
                "name": "data",
                "kind": "required",
                "type": "object",
                "description": "List of fields",
                "modelRef": "#/components/schemas/CurrencyNumberTypeSettingsFieldResponse",
                "customType": "CurrencyNumberTypeSettingsFieldResponse[]",
                "schema": [],
                "complexType": "allOf",
                "complexItems": [
                  {
                    "name": "GenericNumberTypeSettingsFieldResponse",
                    "description": "",
                    "modelRef": "#/components/schemas/GenericNumberTypeSettingsFieldResponse",
                    "schema": [
                      {
                        "name": "id",
                        "kind": "required",
                        "type": "string",
                        "description": "Identifier of the field",
                        "example": "6ceee2f4fa3411ecb37802420ac8001b"
                      },
                      {
                        "name": "name",
                        "kind": "required",
                        "type": "string",
                        "description": "Name of the field",
                        "example": "Sample Checkbox"
                      },
                      {
                        "name": "helper_text",
                        "kind": "required",
                        "type": "string",
                        "description": "Used to help understand functionality of field",
                        "example": "This field is used to check options"
                      },
                      {
                        "name": "is_active",
                        "kind": "required",
                        "type": "boolean",
                        "description": "<p>Indicates active status of field. Inactive fields cannot be accessed in tasks, campaigns or workflows.</p>",
                        "example": true
                      },
                      {
                        "name": "type",
                        "kind": "required",
                        "type": "string",
                        "description": "Type of the field",
                        "example": "checkbox"
                      },
                      {
                        "name": "links",
                        "kind": "required",
                        "type": "object",
                        "description": "Meta links",
                        "example": "",
                        "schema": [
                          {
                            "name": "source",
                            "kind": "required",
                            "type": "string",
                            "description": "URL of the list of fields filtered only with the field",
                            "example": "https://api.cmp.optimizely.com/v3/fields?ids=8p7f910551i00722y0418830aee6612"
                          }
                        ]
                      },
                      {
                        "name": "has_thousand_separator",
                        "kind": "required",
                        "type": "boolean",
                        "description": "Whether the numerical field has a thousand separator",
                        "example": true
                      },
                      {
                        "name": "decimal_places",
                        "kind": "required",
                        "type": "integer",
                        "description": "Decimal place of the numerical field",
                        "example": 2
                      }
                    ]
                  },
                  {
                    "name": "object",
                    "description": "",
                    "schema": [
                      {
                        "name": "currency_code",
                        "kind": "required",
                        "type": "string",
                        "description": "Currency code of the numerical field",
                        "example": "USD"
                      }
                    ]
                  }
                ]
              },
              {
                "name": "pagination",
                "kind": "required",
                "type": "object",
                "description": "",
                "complexType": "allOf",
                "complexItems": [
                  {
                    "name": "Pagination",
                    "description": "",
                    "modelRef": "#/components/schemas/Pagination",
                    "schema": [
                      {
                        "name": "next",
                        "kind": "required",
                        "type": "string",
                        "nullable": true,
                        "description": "URL to the next page",
                        "example": "https://api.cmp.optimizely.com/<some-path-to-next-page>?offset=10&page_size=10"
                      },
                      {
                        "name": "previous",
                        "kind": "required",
                        "type": "string",
                        "nullable": true,
                        "description": "URL to the previous page",
                        "example": ""
                      }
                    ]
                  },
                  {
                    "name": "object",
                    "description": "",
                    "schema": [
                      {
                        "name": "next",
                        "kind": "optional",
                        "type": "string",
                        "nullable": true,
                        "description": "",
                        "example": "https://api.cmp.optimizely.com/v3/fields?offset=10&page_size=10"
                      }
                    ]
                  }
                ],
                "schema": []
              }
            ],
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "400",
        "description": "Client error",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"message\":\"Unsupported arguments: a,b,c\"}",
            "description": "Error payload",
            "customType": "Error",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": "Message describing the error",
                "example": "Not found"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "map",
                "description": "Additional information",
                "example": "",
                "customType": "map<string, string>",
                "schema": []
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "401",
        "description": "Authorization error",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"message\":\"Unauthorized\"}",
            "description": "Error payload",
            "customType": "Error",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": "Message describing the error",
                "example": "Not found"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "map",
                "description": "Additional information",
                "example": "",
                "customType": "map<string, string>",
                "schema": []
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "403",
        "description": "Permission error",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"message\":\"You do not have the permission to perform this operation\"}",
            "description": "Error payload",
            "customType": "Error",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": "Message describing the error",
                "example": "Not found"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "map",
                "description": "Additional information",
                "example": "",
                "customType": "map<string, string>",
                "schema": []
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "404",
        "description": "Not found error",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "example": "{\"message\":\"Resource not found\"}",
            "description": "Error payload",
            "customType": "Error",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": "Message describing the error",
                "example": "Not found"
              },
              {
                "name": "errors",
                "kind": "optional",
                "type": "map",
                "description": "Additional information",
                "example": "",
                "customType": "map<string, string>",
                "schema": []
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "0hRhK3QHvNwkqeQEkjuPL",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url 'https://api.cmp.optimizely.com/v3/fields?offset=5&page_size=10' \\\n     --header 'accept: application/json'"
        },
        {
          "id": "2yD-4Nw415GYLScMlMS9h",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"https://api.cmp.optimizely.com/v3/fields?offset=5&page_size=10\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "fSHKTNKpg3MG9qEwxVoAA",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api.cmp.optimizely.com/v3/fields?offset=5&page_size=10\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = https.request(request)\nputs response.read_body\n"
        },
        {
          "id": "679j-uh-4-hsUSBs4qRf5",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api.cmp.optimizely.com/v3/fields?offset=5&page_size=10\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "0hRhK3QHvNwkqeQEkjuPL"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// List of fetched fields\n{\n  \"data\": {},\n  \"pagination\": {}\n}"
        },
        {
          "id": "response-1-400",
          "language": "400",
          "code": "// Client error\n{\n  \"message\": \"Not found\",\n  \"errors\": \"\"\n}"
        },
        {
          "id": "response-2-401",
          "language": "401",
          "code": "// Authorization error\n{\n  \"message\": \"Not found\",\n  \"errors\": \"\"\n}"
        },
        {
          "id": "response-3-403",
          "language": "403",
          "code": "// Permission error\n{\n  \"message\": \"Not found\",\n  \"errors\": \"\"\n}"
        },
        {
          "id": "response-4-404",
          "language": "404",
          "code": "// Not found error\n{\n  \"message\": \"Not found\",\n  \"errors\": \"\"\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}