---
title: Delete Component
slug: telemetry-pipeline/delete-component
docTags: 
createdAt: 2023-12-26T14:37:58.070Z
---

{
  "id": "xDRK4cmbzbqrWRiB9mLI7",
  "type": "api-oas-v2",
  "data": {
    "method": "DELETE",
    "url": "{{url}}/api/portal/external/components/{id}",
    "servers": [
      {
        "url": "{{url}}/api/portal/external/components/{id}",
        "description": "Development environment"
      }
    ],
    "name": "Delete Component",
    "description": "The API provides functionality to delete an existing source or destination from the system.",
    "contentType": "application/json",
    "request": {
      "pathParameters": [
        {
          "kind": "required",
          "name": "id",
          "type": "string"
        }
      ],
      "headerParameters": [],
      "queryParameters": [],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "cookieAuth",
          "name": "SESSION",
          "kind": "optional",
          "type": "apiKey",
          "in": "cookie"
        },
        {
          "id": "tokenAuth",
          "name": "X-XSRF-TOKEN",
          "kind": "optional",
          "type": "apiKey",
          "in": "header"
        }
      ]
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "OK",
        "jsonExample": "",
        "isExpanded": true
      }
    ],
    "examples": {
      "languages": [
        {
          "id": "oPCDy2lYBtBe701BUXDmf",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request DELETE \\\n     --url {{url}}/api/portal/external/components/{id} \\\n     --header 'accept: application/json'"
        },
        {
          "id": "jr2fQWkZsIsG1D4OVm05h",
          "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: 'DELETE',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"{{url}}/api/portal/external/components/{id}\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "ciqJD1sfhqC5YFjKrqIy6",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"{{url}}/api/portal/external/components/{id}\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Delete.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "DnKnpDcCR6NrAkP5VmBwJ",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"{{url}}/api/portal/external/components/{id}\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"DELETE\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "oPCDy2lYBtBe701BUXDmf"
    },
    "results": {
      "languages": [
        {
          "id": "dlpRbZxQAGiwvtbtID5di",
          "language": "200",
          "code": "// OK\n"
        }
      ],
      "selectedLanguageId": "dlpRbZxQAGiwvtbtID5di"
    }
  },
  "children": [
    {
      "id": "KniXrnC9NTi2NpDpD5Ph0",
      "type": "paragraph",
      "children": [
        {
          "text": "The API provides functionality to delete an existing source or destination from the system."
        }
      ]
    }
  ]
}