---
title: Get the fields of a recipient list
slug: campaign/api/get-the-fields-of-a-recipient-list
docTags: 
createdAt: 2026-09-02T15:04:15.718Z
---

{
  "id": "DxwpsFfO24LCczyNN-RdV",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "https://api.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields",
    "servers": [
      {
        "url": "https://api.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields"
      }
    ],
    "name": "Get the fields of a recipient list",
    "description": "",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "clientId",
          "type": "string",
          "description": "Client ID"
        },
        {
          "kind": "required",
          "name": "recipientListId",
          "type": "integer<int64>",
          "description": "Recipient list ID",
          "format": "int64"
        }
      ],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json",
            "application/vnd.optivo.broadmail.v1+json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "Authorization",
          "name": "Authorization",
          "kind": "optional",
          "type": "apiKey",
          "in": "header"
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "The recipient list's fields were retrieved successfully.",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "RestRecipientListFieldStreamingCollection",
            "schema": [
              {
                "name": "elements",
                "kind": "optional",
                "type": "array",
                "description": "",
                "modelRef": "#/components/schemas/RestRecipientListField",
                "customType": "RestRecipientListField[]",
                "schema": [
                  {
                    "name": "internalName",
                    "kind": "optional",
                    "type": "string",
                    "description": "Internal name"
                  },
                  {
                    "name": "displayName",
                    "kind": "optional",
                    "type": "string",
                    "description": "Display name"
                  },
                  {
                    "name": "type",
                    "kind": "optional",
                    "type": "string<LONG | INTEGER | SHORT | STRING | TEXT | FLOAT | DECIMAL | DATE | TIMESTAMP | BOOLEAN>",
                    "description": "Field's type",
                    "enum": [
                      "LONG",
                      "INTEGER",
                      "SHORT",
                      "STRING",
                      "TEXT",
                      "FLOAT",
                      "DECIMAL",
                      "DATE",
                      "TIMESTAMP",
                      "BOOLEAN"
                    ]
                  },
                  {
                    "name": "required",
                    "kind": "optional",
                    "type": "boolean",
                    "description": "<p>If true, the field is required</p>"
                  }
                ]
              },
              {
                "name": "count",
                "kind": "optional",
                "type": "integer<int32>",
                "description": "",
                "format": "int32"
              },
              {
                "name": "offset",
                "kind": "optional",
                "type": "integer<int32>",
                "description": "",
                "format": "int32"
              },
              {
                "name": "limit",
                "kind": "optional",
                "type": "integer<int32>",
                "description": "",
                "format": "int32"
              }
            ],
            "modelRef": "#/components/schemas/RestRecipientListFieldStreamingCollection",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "409",
        "description": "The recipient list's attribute names could not be retrieved. Ensure that the required parameters such as \"recipientListId\" are correct and the recipient list exists.",
        "jsonExample": "",
        "isExpanded": true
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "mtT2ZWpX8EEpfRVCzKUK6",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url https://api.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields \\\n     --header 'accept: application/json'"
        },
        {
          "id": "Sjd-lSN4A_bE26iD3hMqg",
          "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.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "0or2MqQv-wKmTZx4ffpP-",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields\")\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": "7Hlhtl5LE1s6OPDN798OB",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api.campaign.episerver.net/rest/{clientId}/recipientlists/{recipientListId}/fields\"\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": "mtT2ZWpX8EEpfRVCzKUK6"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// The recipient list's fields were retrieved successfully.\n{\n  \"elements\": [\n    {\n      \"internalName\": \"\",\n      \"displayName\": \"\",\n      \"type\": \"\",\n      \"required\": false\n    }\n  ],\n  \"count\": \"\",\n  \"offset\": \"\",\n  \"limit\": \"\"\n}"
        },
        {
          "id": "response-1-409",
          "language": "409",
          "code": "// The recipient list's attribute names could not be retrieved. Ensure that the required parameters such as \"recipientListId\" are correct and the recipient list exists.\n"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}