---
title: List Extensions
slug: web-experimentation/api/list-extensions
docTags: 
createdAt: 2026-10-02T13:15:18.296Z
---

{
  "id": "wLkegM43vrwQvmR2mdVyF",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "https://api.optimizely.com/v2/extensions",
    "servers": [
      {
        "url": "https://api.optimizely.com/v2/extensions"
      }
    ],
    "name": "List Extensions",
    "description": "List Extensions under a project",
    "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": "per_page",
          "type": "integer",
          "description": "Optional pagination argument that specifies the maximum number of objects to return per request",
          "default": 25,
          "maximum": 100
        },
        {
          "kind": "optional",
          "name": "page",
          "type": "integer",
          "description": "Optional pagination argument that specifies the page to return. If you have 140 objects and you choose to return 100 objects per page you will be able to access the last 40 objects on page 2. The default value is 1.\n",
          "default": 1
        },
        {
          "kind": "required",
          "name": "project_id",
          "type": "integer<int64>",
          "description": "The ID of the project you would like to list all extensions for",
          "format": "int64"
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "apiKey",
          "name": "apiKey",
          "kind": "optional",
          "type": "http",
          "scheme": "bearer"
        },
        {
          "id": "OAuth2",
          "name": "OAuth2",
          "kind": "optional",
          "type": "oauth2",
          "description": "<p>Write applications that authenticate with the REST API via OAuth 2.0. Or, to authenticate using a personal token, see <a href=\"https://docs.developers.optimizely.com/web/docs/personal-token\" target=\"_blank\">https://docs.developers.optimizely.com/web/docs/personal-token</a></p>",
          "oauth2Flows": {
            "authorizationCode": {
              "authorizationUrl": "https://app.optimizely.com/oauth2/authorize",
              "tokenUrl": "https://app.optimizely.com/oauth2/token",
              "scopes": {
                "all": "Full access to your account"
              }
            }
          },
          "requiredScopes": [
            "read",
            "write"
          ]
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "Return all extensions in the specified project",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "array",
            "description": "",
            "customType": "Extension[]",
            "schema": [
              {
                "name": "archived",
                "kind": "optional",
                "type": "boolean",
                "readOnly": true,
                "description": "Whether the extension is archived"
              },
              {
                "name": "created",
                "kind": "optional",
                "type": "string<date-time>",
                "readOnly": true,
                "description": "The time when the extension was initially created",
                "format": "date-time"
              },
              {
                "name": "description",
                "kind": "optional",
                "type": "string",
                "description": "The description for the extension"
              },
              {
                "name": "edit_url",
                "kind": "required",
                "type": "string",
                "description": "The URL to load when editing the extension"
              },
              {
                "name": "enabled",
                "kind": "optional",
                "type": "boolean",
                "description": "Whether the extension is enabled. A disabled extension won't appear in the editor and won't be built into the snippet"
              },
              {
                "name": "experiment_count",
                "kind": "optional",
                "type": "integer<int64>",
                "readOnly": true,
                "description": "<p>Number of experiments that reference this extension across all statuses (running, paused, draft, archived). Computed by the upstream service.</p>",
                "example": 3,
                "format": "int64"
              },
              {
                "name": "fields",
                "kind": "optional",
                "type": "array",
                "description": "Array of editable fields in the extension",
                "modelRef": "#/components/schemas/Field",
                "customType": "Field[]",
                "schema": [
                  {
                    "name": "api_name",
                    "kind": "required",
                    "type": "string",
                    "description": "The API name of the field"
                  },
                  {
                    "name": "default_value",
                    "kind": "required",
                    "type": "string",
                    "description": "<p>A string in JSON format that corresponds to the default_value of the field</p>"
                  },
                  {
                    "name": "field_type",
                    "kind": "required",
                    "type": "string<selector | text | multi_text | rich_text | number | html | css | js | toggle | dropdown | multi_select | image | color | slider>",
                    "description": "The type of the field",
                    "enum": [
                      "selector",
                      "text",
                      "multi_text",
                      "rich_text",
                      "number",
                      "html",
                      "css",
                      "js",
                      "toggle",
                      "dropdown",
                      "multi_select",
                      "image",
                      "color",
                      "slider"
                    ]
                  },
                  {
                    "name": "label",
                    "kind": "required",
                    "type": "string",
                    "description": "The label of the field"
                  },
                  {
                    "name": "options",
                    "kind": "optional",
                    "type": "object",
                    "description": "",
                    "modelRef": "#/components/schemas/Options",
                    "customType": "Options",
                    "schema": [
                      {
                        "name": "choices",
                        "kind": "optional",
                        "type": "array",
                        "description": "The choices for a field",
                        "modelRef": "#/components/schemas/Choices",
                        "customType": "Choices[]",
                        "schema": [
                          {
                            "name": "label",
                            "kind": "optional",
                            "type": "string",
                            "description": "label of the choice"
                          },
                          {
                            "name": "value",
                            "kind": "optional",
                            "type": "string",
                            "description": "value of the choice"
                          }
                        ]
                      }
                    ]
                  }
                ]
              },
              {
                "name": "id",
                "kind": "optional",
                "type": "integer<int64>",
                "readOnly": true,
                "description": "The unique identifier for the extension",
                "example": 3000,
                "format": "int64"
              },
              {
                "name": "implementation",
                "kind": "required",
                "type": "object",
                "description": "",
                "modelRef": "#/components/schemas/Implementation",
                "customType": "Implementation",
                "schema": [
                  {
                    "name": "apply_js",
                    "kind": "optional",
                    "type": "string",
                    "description": "The Apply JS code is used to inject the extension onto the page",
                    "default": ""
                  },
                  {
                    "name": "css",
                    "kind": "optional",
                    "type": "string",
                    "description": "<p>Some extensions may not need any CSS because they inherit styles from the page itself. However, you can add additional styling here. This will be injected on the page through a  tag</p>",
                    "default": ""
                  },
                  {
                    "name": "html",
                    "kind": "optional",
                    "type": "string",
                    "description": "The html implementation of the field",
                    "default": ""
                  },
                  {
                    "name": "reset_js",
                    "kind": "optional",
                    "type": "string",
                    "description": "<p>Reset JS is used to \"clean up\" after a extension. It's used in the editor, when changing field values or removing an existing extension. Reset JS should remove the element and any other side-effects</p>",
                    "default": ""
                  }
                ]
              },
              {
                "name": "last_modified",
                "kind": "optional",
                "type": "string<date-time>",
                "readOnly": true,
                "description": "The last time when the extension was modified",
                "format": "date-time"
              },
              {
                "name": "name",
                "kind": "required",
                "type": "string",
                "description": "Name of the extension",
                "example": "My Extension"
              },
              {
                "name": "project_id",
                "kind": "required",
                "type": "integer<int64>",
                "description": "The project the extension is in",
                "example": 1000,
                "format": "int64"
              }
            ],
            "modelRef": "#/components/schemas/Extension",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "401",
        "description": "Invalid credentials",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Error",
            "schema": [
              {
                "name": "code",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "message",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "messages",
                "kind": "optional",
                "type": "object",
                "description": "",
                "example": "",
                "schema": []
              },
              {
                "name": "uuid",
                "kind": "optional",
                "type": "string<uuid>",
                "description": "",
                "format": "uuid"
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "403",
        "description": "You do not have permission to access the extensions in the specified project",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Error",
            "schema": [
              {
                "name": "code",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "message",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "messages",
                "kind": "optional",
                "type": "object",
                "description": "",
                "example": "",
                "schema": []
              },
              {
                "name": "uuid",
                "kind": "optional",
                "type": "string<uuid>",
                "description": "",
                "format": "uuid"
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "404",
        "description": "Extensions not found",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Error",
            "schema": [
              {
                "name": "code",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "message",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "messages",
                "kind": "optional",
                "type": "object",
                "description": "",
                "example": "",
                "schema": []
              },
              {
                "name": "uuid",
                "kind": "optional",
                "type": "string<uuid>",
                "description": "",
                "format": "uuid"
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "default",
        "description": "Unexpected error",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Error",
            "schema": [
              {
                "name": "code",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "message",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "messages",
                "kind": "optional",
                "type": "object",
                "description": "",
                "example": "",
                "schema": []
              },
              {
                "name": "uuid",
                "kind": "optional",
                "type": "string<uuid>",
                "description": "",
                "format": "uuid"
              }
            ],
            "modelRef": "#/components/schemas/Error",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "njSHt4oi7OM5ARfQkgNCN",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url 'https://api.optimizely.com/v2/extensions?per_page=25&page=1&project_id=integer%3Cint64%3E' \\\n     --header 'accept: application/json'"
        },
        {
          "id": "treAQE0zGE1svgS3Iihal",
          "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.optimizely.com/v2/extensions?per_page=25&page=1&project_id=integer<int64>\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "NFC7aQ2Uq7v1TQKMNeUZe",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api.optimizely.com/v2/extensions?per_page=25&page=1&project_id=integer<int64>\")\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": "ISGF9MRrkq7j_lI18Rmre",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api.optimizely.com/v2/extensions?per_page=25&page=1&project_id=integer<int64>\"\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": "njSHt4oi7OM5ARfQkgNCN"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// Return all extensions in the specified project\n[\n  {\n    \"archived\": false,\n    \"created\": \"\",\n    \"description\": \"\",\n    \"edit_url\": \"\",\n    \"enabled\": false,\n    \"experiment_count\": 3,\n    \"fields\": [\n      {\n        \"api_name\": \"\",\n        \"default_value\": \"\",\n        \"field_type\": \"\",\n        \"label\": \"\",\n        \"options\": {\n          \"choices\": [\n            {\n              \"label\": \"\",\n              \"value\": \"\"\n            }\n          ]\n        }\n      }\n    ],\n    \"id\": 3000,\n    \"implementation\": {\n      \"apply_js\": \"\",\n      \"css\": \"\",\n      \"html\": \"\",\n      \"reset_js\": \"\"\n    },\n    \"last_modified\": \"\",\n    \"name\": \"My Extension\",\n    \"project_id\": 1000\n  }\n]"
        },
        {
          "id": "response-1-401",
          "language": "401",
          "code": "// Invalid credentials\n{\n  \"code\": \"\",\n  \"message\": \"\",\n  \"messages\": {},\n  \"uuid\": \"\"\n}"
        },
        {
          "id": "response-2-403",
          "language": "403",
          "code": "// You do not have permission to access the extensions in the specified project\n{\n  \"code\": \"\",\n  \"message\": \"\",\n  \"messages\": {},\n  \"uuid\": \"\"\n}"
        },
        {
          "id": "response-3-404",
          "language": "404",
          "code": "// Extensions not found\n{\n  \"code\": \"\",\n  \"message\": \"\",\n  \"messages\": {},\n  \"uuid\": \"\"\n}"
        },
        {
          "id": "response-4-default",
          "language": "default",
          "code": "// Unexpected error\n{\n  \"code\": \"\",\n  \"message\": \"\",\n  \"messages\": {},\n  \"uuid\": \"\"\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}