---
title: List layers
slug: model-api/list-layers
docTags: 
createdAt: 2024-06-10T16:48:45.445Z
---

{
  "id": "uc1m8hGu55XMLB5_-GK9E",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "https://api.catenda.com/v2/projects/{project-id}/ifc/layers",
    "servers": [
      {
        "url": "https://api.catenda.com/v2/projects/{project-id}/ifc/layers"
      }
    ],
    "name": "List layers",
    "description": "List all layers in a project.",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "project-id",
          "type": "string",
          "example": "af2d8af0fa54465b89bf26dd3d92cfd0",
          "description": "Catenda project id"
        }
      ],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [
        {
          "kind": "optional",
          "name": "model",
          "type": "array",
          "description": "Filter by latest revision of model id.",
          "schema": [],
          "itemType": "string",
          "customType": "string[]"
        },
        {
          "kind": "optional",
          "name": "revision",
          "type": "array",
          "description": "Filter by revision id. Can be repeated to filter by multiple revisions.",
          "schema": [],
          "itemType": "string",
          "customType": "string[]"
        },
        {
          "kind": "optional",
          "name": "ifcType",
          "type": "string",
          "description": "Filter by IFC type"
        },
        {
          "kind": "optional",
          "name": "page",
          "type": "integer",
          "description": "Default value is 1"
        },
        {
          "kind": "optional",
          "name": "pageSize",
          "type": "integer",
          "description": "<p>Default 100, max 1000</p>"
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "Bearer",
          "name": "Bearer",
          "kind": "optional",
          "type": "http",
          "scheme": "bearer"
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "OK",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "array",
            "description": "",
            "customType": "ifc-layer[]",
            "schema": [
              {
                "name": "revisionId",
                "kind": "optional",
                "type": "string",
                "description": "The id of the model revision",
                "example": "924809076a694255c489d236517a55da"
              },
              {
                "name": "objectId",
                "kind": "optional",
                "type": "integer<int64>",
                "description": "The object id of the layer",
                "example": 417236997303,
                "format": "int64"
              },
              {
                "name": "ifcType",
                "kind": "optional",
                "type": "string",
                "description": "The entity type of the layer",
                "example": "IfcPresentationLayerAssignment"
              },
              {
                "name": "attributes",
                "kind": "optional",
                "type": "object",
                "description": "The attributes of the layer including name",
                "example": "",
                "schema": []
              }
            ],
            "modelRef": "#/components/schemas/ifc-layer",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "eMuEKqucaGVz6W_Q-FtL0",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url https://api.catenda.com/v2/projects/{project-id}/ifc/layers \\\n     --header 'accept: application/json'"
        },
        {
          "id": "2NnbSCI608HPTux1NBBEY",
          "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.catenda.com/v2/projects/{project-id}/ifc/layers\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "Wst_ylfFT5Wa0U25CdqJD",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://api.catenda.com/v2/projects/{project-id}/ifc/layers\")\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": "n21OKJ82fbJLhaTH8TMbf",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api.catenda.com/v2/projects/{project-id}/ifc/layers\"\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": "eMuEKqucaGVz6W_Q-FtL0"
    },
    "results": {
      "languages": [
        {
          "id": "l8V5vTVzDWz3qptiCtXaO",
          "language": "200",
          "code": "// OK\n[\n  {\n    \"revisionId\": \"924809076a694255c489d236517a55da\",\n    \"objectId\": 417236997303,\n    \"ifcType\": \"IfcPresentationLayerAssignment\",\n    \"attributes\": {}\n  }\n]"
        }
      ],
      "selectedLanguageId": "l8V5vTVzDWz3qptiCtXaO"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}