> For the complete documentation index, see [llms.txt](https://docs.platform9.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.platform9.com/api-docs/networking-service/ports.md).

# Ports

Network port management operations

## List ports

> Lists ports to which the project has access.

```json
{"openapi":"3.0.3","info":{"title":"Networking API","version":"2.0"},"tags":[{"name":"Ports","description":"Network port management operations"}],"servers":[{"url":"https://{host}/neutron","description":"PCD Network API v2.0","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"pcdAuth":[]}],"components":{"securitySchemes":{"pcdAuth":{"name":"X-Auth-Token","type":"apiKey","in":"header","description":"PCD Identity Service token authentication"}},"parameters":{"AdminStateUp":{"name":"admin_state_up","description":"Filter the list result by the administrative state of the resource.","schema":{"type":"boolean"},"in":"query"},"IdFilter":{"name":"id","description":"Filter the list result by the ID of the resource.","schema":{"type":"string"},"in":"query"},"NameFilter":{"name":"name","description":"Filter the list result by the human-readable name of the resource.","schema":{"type":"string"},"in":"query"},"NetworkIdFilter":{"name":"network_id","description":"Filter the list result by the network ID.","schema":{"type":"string"},"in":"query"},"ProjectIdFilter":{"name":"project_id","description":"Filter the list result by the ID of the project that owns the resource.","schema":{"type":"string"},"in":"query"},"TenantIdFilter":{"name":"tenant_id","description":"Filter the list result by the ID of the project that owns the resource.","schema":{"type":"string"},"in":"query"},"DeviceIdFilter":{"name":"device_id","description":"Filter ports by device ID.","schema":{"type":"string"},"in":"query"},"DeviceOwnerFilter":{"name":"device_owner","description":"Filter ports by device owner.","schema":{"type":"string"},"in":"query"},"StatusFilter":{"name":"status","description":"Filter the list result by status.","schema":{"enum":["ACTIVE","BUILD","DOWN","ERROR"],"type":"string"},"in":"query"},"Fields":{"name":"fields","description":"The fields that you want the server to return. If no fields are specified, all fields are returned.","schema":{"type":"string"},"in":"query"},"SortDir":{"name":"sort_dir","description":"Sort direction. A valid value is asc (ascending) or desc (descending).","schema":{"enum":["asc","desc"],"type":"string"},"in":"query"},"SortKey":{"name":"sort_key","description":"Sorts by a resource attribute.","schema":{"type":"string"},"in":"query"},"Tags":{"name":"tags","description":"A list of tags to filter the list result by. Resources that match all tags in this list will be returned.","schema":{"type":"string"},"in":"query"},"TagsAny":{"name":"tags-any","description":"A list of tags to filter the list result by. Resources that match any tag in this list will be returned.","schema":{"type":"string"},"in":"query"},"NotTags":{"name":"not-tags","description":"A list of tags to filter the list result by. Resources that match all tags in this list will be excluded.","schema":{"type":"string"},"in":"query"},"NotTagsAny":{"name":"not-tags-any","description":"A list of tags to filter the list result by. Resources that match any tag in this list will be excluded.","schema":{"type":"string"},"in":"query"}},"schemas":{"PortsResponse":{"type":"object","properties":{"ports":{"type":"array","items":{"$ref":"#/components/schemas/Port"}}},"title":"PortsResponse"},"Port":{"type":"object","properties":{"id":{"format":"uuid","type":"string","readOnly":true},"name":{"type":"string"},"description":{"type":"string"},"network_id":{"format":"uuid","type":"string"},"admin_state_up":{"type":"boolean"},"status":{"enum":["ACTIVE","BUILD","DOWN","ERROR"],"type":"string","readOnly":true},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"project_id":{"format":"uuid","type":"string"},"tenant_id":{"format":"uuid","type":"string"},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_assignment":{"type":"array","items":{"$ref":"#/components/schemas/DnsAssignment"},"readOnly":true},"dns_domain":{"type":"string"},"data_plane_status":{"enum":[null,"ACTIVE","DOWN"],"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"},"qos_network_policy_id":{"format":"uuid","type":"string"},"binding:vnic_type":{"type":"string"},"binding:profile":{"type":"object","additionalProperties":true},"binding:host_id":{"type":"string"},"binding:vif_type":{"type":"string","readOnly":true},"binding:vif_details":{"type":"object","additionalProperties":true,"readOnly":true},"resource_request":{"type":"object","nullable":true,"readOnly":true},"tags":{"type":"array","items":{"type":"string"}},"revision_number":{"type":"integer","readOnly":true},"created_at":{"format":"date-time","type":"string","readOnly":true},"updated_at":{"format":"date-time","type":"string","readOnly":true}},"title":"Port"},"FixedIP":{"type":"object","properties":{"subnet_id":{"format":"uuid","type":"string"},"ip_address":{"format":"ipv4","type":"string"}},"title":"FixedIP"},"AllowedAddressPair":{"type":"object","properties":{"ip_address":{"type":"string"},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"}},"title":"AllowedAddressPair"},"ExtraDhcpOpt":{"type":"object","properties":{"opt_name":{"type":"string"},"opt_value":{"type":"string"},"ip_version":{"enum":[4,6],"type":"integer"}},"title":"ExtraDhcpOpt"},"DnsAssignment":{"type":"object","properties":{"hostname":{"type":"string"},"ip_address":{"type":"string"},"fqdn":{"type":"string"}},"title":"DnsAssignment"},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"type":{"type":"string"},"detail":{"type":"string"}}}},"title":"Error"}},"responses":{"Unauthorized":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Unauthorized"}}},"paths":{"/v2.0/ports":{"get":{"tags":["Ports"],"parameters":[{"$ref":"#/components/parameters/AdminStateUp"},{"$ref":"#/components/parameters/IdFilter"},{"$ref":"#/components/parameters/NameFilter"},{"$ref":"#/components/parameters/NetworkIdFilter"},{"$ref":"#/components/parameters/ProjectIdFilter"},{"$ref":"#/components/parameters/TenantIdFilter"},{"$ref":"#/components/parameters/DeviceIdFilter"},{"$ref":"#/components/parameters/DeviceOwnerFilter"},{"$ref":"#/components/parameters/StatusFilter"},{"$ref":"#/components/parameters/Fields"},{"$ref":"#/components/parameters/SortDir"},{"$ref":"#/components/parameters/SortKey"},{"$ref":"#/components/parameters/Tags"},{"$ref":"#/components/parameters/TagsAny"},{"$ref":"#/components/parameters/NotTags"},{"$ref":"#/components/parameters/NotTagsAny"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortsResponse"}}},"description":"Successful operation"},"401":{"$ref":"#/components/responses/Unauthorized"}},"operationId":"listPorts","summary":"List ports","description":"Lists ports to which the project has access."}}}}
```

## Create port

> Creates a port.

```json
{"openapi":"3.0.3","info":{"title":"Networking API","version":"2.0"},"tags":[{"name":"Ports","description":"Network port management operations"}],"servers":[{"url":"https://{host}/neutron","description":"PCD Network API v2.0","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"pcdAuth":[]}],"components":{"securitySchemes":{"pcdAuth":{"name":"X-Auth-Token","type":"apiKey","in":"header","description":"PCD Identity Service token authentication"}},"schemas":{"PortCreateRequest":{"required":["port"],"type":"object","properties":{"port":{"required":["network_id"],"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"network_id":{"format":"uuid","type":"string"},"admin_state_up":{"default":true,"type":"boolean"},"mac_address":{"type":"string"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"project_id":{"format":"uuid","type":"string"},"tenant_id":{"format":"uuid","type":"string"},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_domain":{"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"},"binding:vnic_type":{"type":"string"},"binding:profile":{"type":"object","additionalProperties":true}}}},"title":"PortCreateRequest"},"FixedIP":{"type":"object","properties":{"subnet_id":{"format":"uuid","type":"string"},"ip_address":{"format":"ipv4","type":"string"}},"title":"FixedIP"},"AllowedAddressPair":{"type":"object","properties":{"ip_address":{"type":"string"},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"}},"title":"AllowedAddressPair"},"ExtraDhcpOpt":{"type":"object","properties":{"opt_name":{"type":"string"},"opt_value":{"type":"string"},"ip_version":{"enum":[4,6],"type":"integer"}},"title":"ExtraDhcpOpt"},"PortResponse":{"type":"object","properties":{"port":{"$ref":"#/components/schemas/Port"}},"title":"PortResponse"},"Port":{"type":"object","properties":{"id":{"format":"uuid","type":"string","readOnly":true},"name":{"type":"string"},"description":{"type":"string"},"network_id":{"format":"uuid","type":"string"},"admin_state_up":{"type":"boolean"},"status":{"enum":["ACTIVE","BUILD","DOWN","ERROR"],"type":"string","readOnly":true},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"project_id":{"format":"uuid","type":"string"},"tenant_id":{"format":"uuid","type":"string"},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_assignment":{"type":"array","items":{"$ref":"#/components/schemas/DnsAssignment"},"readOnly":true},"dns_domain":{"type":"string"},"data_plane_status":{"enum":[null,"ACTIVE","DOWN"],"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"},"qos_network_policy_id":{"format":"uuid","type":"string"},"binding:vnic_type":{"type":"string"},"binding:profile":{"type":"object","additionalProperties":true},"binding:host_id":{"type":"string"},"binding:vif_type":{"type":"string","readOnly":true},"binding:vif_details":{"type":"object","additionalProperties":true,"readOnly":true},"resource_request":{"type":"object","nullable":true,"readOnly":true},"tags":{"type":"array","items":{"type":"string"}},"revision_number":{"type":"integer","readOnly":true},"created_at":{"format":"date-time","type":"string","readOnly":true},"updated_at":{"format":"date-time","type":"string","readOnly":true}},"title":"Port"},"DnsAssignment":{"type":"object","properties":{"hostname":{"type":"string"},"ip_address":{"type":"string"},"fqdn":{"type":"string"}},"title":"DnsAssignment"},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"type":{"type":"string"},"detail":{"type":"string"}}}},"title":"Error"}},"responses":{"BadRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Bad Request"},"Unauthorized":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Unauthorized"}}},"paths":{"/v2.0/ports":{"post":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortCreateRequest"}}},"required":true},"tags":["Ports"],"responses":{"201":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortResponse"}}},"description":"Port created successfully"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"}},"operationId":"createPort","summary":"Create port","description":"Creates a port."}}}}
```

## Show port details

> Shows details for a port.

```json
{"openapi":"3.0.3","info":{"title":"Networking API","version":"2.0"},"tags":[{"name":"Ports","description":"Network port management operations"}],"servers":[{"url":"https://{host}/neutron","description":"PCD Network API v2.0","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"pcdAuth":[]}],"components":{"securitySchemes":{"pcdAuth":{"name":"X-Auth-Token","type":"apiKey","in":"header","description":"PCD Identity Service token authentication"}},"parameters":{"PortId":{"name":"port_id","description":"The ID of the port.","schema":{"format":"uuid","type":"string"},"in":"path","required":true},"Fields":{"name":"fields","description":"The fields that you want the server to return. If no fields are specified, all fields are returned.","schema":{"type":"string"},"in":"query"}},"schemas":{"PortResponse":{"type":"object","properties":{"port":{"$ref":"#/components/schemas/Port"}},"title":"PortResponse"},"Port":{"type":"object","properties":{"id":{"format":"uuid","type":"string","readOnly":true},"name":{"type":"string"},"description":{"type":"string"},"network_id":{"format":"uuid","type":"string"},"admin_state_up":{"type":"boolean"},"status":{"enum":["ACTIVE","BUILD","DOWN","ERROR"],"type":"string","readOnly":true},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"project_id":{"format":"uuid","type":"string"},"tenant_id":{"format":"uuid","type":"string"},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_assignment":{"type":"array","items":{"$ref":"#/components/schemas/DnsAssignment"},"readOnly":true},"dns_domain":{"type":"string"},"data_plane_status":{"enum":[null,"ACTIVE","DOWN"],"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"},"qos_network_policy_id":{"format":"uuid","type":"string"},"binding:vnic_type":{"type":"string"},"binding:profile":{"type":"object","additionalProperties":true},"binding:host_id":{"type":"string"},"binding:vif_type":{"type":"string","readOnly":true},"binding:vif_details":{"type":"object","additionalProperties":true,"readOnly":true},"resource_request":{"type":"object","nullable":true,"readOnly":true},"tags":{"type":"array","items":{"type":"string"}},"revision_number":{"type":"integer","readOnly":true},"created_at":{"format":"date-time","type":"string","readOnly":true},"updated_at":{"format":"date-time","type":"string","readOnly":true}},"title":"Port"},"FixedIP":{"type":"object","properties":{"subnet_id":{"format":"uuid","type":"string"},"ip_address":{"format":"ipv4","type":"string"}},"title":"FixedIP"},"AllowedAddressPair":{"type":"object","properties":{"ip_address":{"type":"string"},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"}},"title":"AllowedAddressPair"},"ExtraDhcpOpt":{"type":"object","properties":{"opt_name":{"type":"string"},"opt_value":{"type":"string"},"ip_version":{"enum":[4,6],"type":"integer"}},"title":"ExtraDhcpOpt"},"DnsAssignment":{"type":"object","properties":{"hostname":{"type":"string"},"ip_address":{"type":"string"},"fqdn":{"type":"string"}},"title":"DnsAssignment"},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"type":{"type":"string"},"detail":{"type":"string"}}}},"title":"Error"}},"responses":{"Unauthorized":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Unauthorized"},"NotFound":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Not Found"}}},"paths":{"/v2.0/ports/{port_id}":{"get":{"tags":["Ports"],"parameters":[{"$ref":"#/components/parameters/PortId"},{"$ref":"#/components/parameters/Fields"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortResponse"}}},"description":"Successful operation"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"}},"operationId":"showPort","summary":"Show port details","description":"Shows details for a port."}}}}
```

## Update port

> Updates a port.

```json
{"openapi":"3.0.3","info":{"title":"Networking API","version":"2.0"},"tags":[{"name":"Ports","description":"Network port management operations"}],"servers":[{"url":"https://{host}/neutron","description":"PCD Network API v2.0","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"pcdAuth":[]}],"components":{"securitySchemes":{"pcdAuth":{"name":"X-Auth-Token","type":"apiKey","in":"header","description":"PCD Identity Service token authentication"}},"schemas":{"PortUpdateRequest":{"type":"object","properties":{"port":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"admin_state_up":{"type":"boolean"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_domain":{"type":"string"},"data_plane_status":{"enum":[null,"ACTIVE","DOWN"],"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"}}}},"title":"PortUpdateRequest"},"FixedIP":{"type":"object","properties":{"subnet_id":{"format":"uuid","type":"string"},"ip_address":{"format":"ipv4","type":"string"}},"title":"FixedIP"},"AllowedAddressPair":{"type":"object","properties":{"ip_address":{"type":"string"},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"}},"title":"AllowedAddressPair"},"ExtraDhcpOpt":{"type":"object","properties":{"opt_name":{"type":"string"},"opt_value":{"type":"string"},"ip_version":{"enum":[4,6],"type":"integer"}},"title":"ExtraDhcpOpt"},"PortResponse":{"type":"object","properties":{"port":{"$ref":"#/components/schemas/Port"}},"title":"PortResponse"},"Port":{"type":"object","properties":{"id":{"format":"uuid","type":"string","readOnly":true},"name":{"type":"string"},"description":{"type":"string"},"network_id":{"format":"uuid","type":"string"},"admin_state_up":{"type":"boolean"},"status":{"enum":["ACTIVE","BUILD","DOWN","ERROR"],"type":"string","readOnly":true},"mac_address":{"pattern":"^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$","type":"string"},"fixed_ips":{"type":"array","items":{"$ref":"#/components/schemas/FixedIP"}},"project_id":{"format":"uuid","type":"string"},"tenant_id":{"format":"uuid","type":"string"},"device_id":{"type":"string"},"device_owner":{"type":"string"},"security_groups":{"type":"array","items":{"format":"uuid","type":"string"}},"allowed_address_pairs":{"type":"array","items":{"$ref":"#/components/schemas/AllowedAddressPair"}},"extra_dhcp_opts":{"type":"array","items":{"$ref":"#/components/schemas/ExtraDhcpOpt"}},"port_security_enabled":{"type":"boolean"},"dns_name":{"type":"string"},"dns_assignment":{"type":"array","items":{"$ref":"#/components/schemas/DnsAssignment"},"readOnly":true},"dns_domain":{"type":"string"},"data_plane_status":{"enum":[null,"ACTIVE","DOWN"],"type":"string"},"qos_policy_id":{"format":"uuid","type":"string"},"qos_network_policy_id":{"format":"uuid","type":"string"},"binding:vnic_type":{"type":"string"},"binding:profile":{"type":"object","additionalProperties":true},"binding:host_id":{"type":"string"},"binding:vif_type":{"type":"string","readOnly":true},"binding:vif_details":{"type":"object","additionalProperties":true,"readOnly":true},"resource_request":{"type":"object","nullable":true,"readOnly":true},"tags":{"type":"array","items":{"type":"string"}},"revision_number":{"type":"integer","readOnly":true},"created_at":{"format":"date-time","type":"string","readOnly":true},"updated_at":{"format":"date-time","type":"string","readOnly":true}},"title":"Port"},"DnsAssignment":{"type":"object","properties":{"hostname":{"type":"string"},"ip_address":{"type":"string"},"fqdn":{"type":"string"}},"title":"DnsAssignment"},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"type":{"type":"string"},"detail":{"type":"string"}}}},"title":"Error"}},"parameters":{"PortId":{"name":"port_id","description":"The ID of the port.","schema":{"format":"uuid","type":"string"},"in":"path","required":true}},"responses":{"BadRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Bad Request"},"Unauthorized":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Unauthorized"},"Forbidden":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Forbidden"},"NotFound":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Not Found"},"PreconditionFailed":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Precondition Failed"}}},"paths":{"/v2.0/ports/{port_id}":{"put":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortUpdateRequest"}}},"required":true},"tags":["Ports"],"parameters":[{"$ref":"#/components/parameters/PortId"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortResponse"}}},"description":"Port updated successfully"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"412":{"$ref":"#/components/responses/PreconditionFailed"}},"operationId":"updatePort","summary":"Update port","description":"Updates a port."}}}}
```

## Delete port

> Deletes a port.

```json
{"openapi":"3.0.3","info":{"title":"Networking API","version":"2.0"},"tags":[{"name":"Ports","description":"Network port management operations"}],"servers":[{"url":"https://{host}/neutron","description":"PCD Network API v2.0","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"pcdAuth":[]}],"components":{"securitySchemes":{"pcdAuth":{"name":"X-Auth-Token","type":"apiKey","in":"header","description":"PCD Identity Service token authentication"}},"parameters":{"PortId":{"name":"port_id","description":"The ID of the port.","schema":{"format":"uuid","type":"string"},"in":"path","required":true}},"responses":{"Unauthorized":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Unauthorized"},"NotFound":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Not Found"},"PreconditionFailed":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Precondition Failed"}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"type":{"type":"string"},"detail":{"type":"string"}}}},"title":"Error"}}},"paths":{"/v2.0/ports/{port_id}":{"delete":{"tags":["Ports"],"parameters":[{"$ref":"#/components/parameters/PortId"}],"responses":{"204":{"description":"Port deleted successfully"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"412":{"$ref":"#/components/responses/PreconditionFailed"}},"operationId":"deletePort","summary":"Delete port","description":"Deletes a port."}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.platform9.com/api-docs/networking-service/ports.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
