Port (managed_by_service==True)

This page describes operations you can perform on ports. List, and get details for.

List Port

List all visible ports.

Synchronous / Asynchronous

  • Synchronous

Request

HTTP Request Method

  • GET

HTTP Request Path

{endpoint}/v2.0/ports

HTTP Request Parameters

Parameter Style Type Format Enumeration Description Required
description query string - - Port description. no
device_id query string hyph-uuid-or-empty - The Id of device (i.e physical port id for baremetal). no
device_owner query string - - The name of the port owner no
id query string hyph-uuid - Port unique id. no
mac_address query string - - The MAC address of the port. no
name query string - - Port name. no
network_id query string hyph-uuid - The ID of network this port belongs to. no
status query string - - The port status. no
tenant_id query string non-hyph-uuid-or-empty - The owner name of port. no

Response

HTTP Response Code List

Response Code Description
200 OK
400 Bad Request
401 UnAuthorized
404 Not Found
500 Internal Server Error

HTTP Response Parameters

Parameter Type Format Description
ports array<object> Port (managed_by_service==True) -
admin_state_up boolean - Administrative state of Port (supported when device_owner starts with "compute:")
allowed_address_pairs array<object> - Allowed address pairs
ip_address string cidr-or-ipv4 -
mac_address string - -
description string - Port description.
device_id string hyph-uuid-or-empty The Id of device (i.e physical port id for baremetal).
device_owner string - The name of the port owner
fixed_ips array<object> - List of fixes IP addresses assign to port.
ip_address string - The IP address assign to port within subnet.
subnet_id string hyph-uuid The ID of subnet from which IP address is allocated.
id string hyph-uuid Port unique id.
mac_address string - The MAC address of the port.
managed_by_service boolean - Set to true if only admin can modify it. Normal user has only read access.
name string - Port name.
network_id string hyph-uuid The ID of network this port belongs to.
security_groups array<string> hyph-uuid The IDs of security groups applied to the port.
status string - The port status.
tags object - Port tags.
tenant_id string non-hyph-uuid-or-empty The owner name of port.

Examples

Sample Request Body

This operation does not send a request body.

Sample Response Body

{
  "ports": [
    {
      "admin_state_up": true,
      "allowed_address_pairs": [],
      "description": "Port created by service",
      "device_id": "b269b8c0-1a42-4464-9314-4396e51e5107",
      "device_owner": "physical_port",
      "fixed_ips": [
        {
          "ip_address": "10.161.54.13",
          "subnet_id": "93bb920c-19be-4026-8cc7-564bfcd41456"
        }
      ],
      "id": "81c3b7d4-eae2-4858-ab76-fa56117b8ab4",
      "mac_address": "26:8d:42:f6:c2:c4",
      "managed_by_service": true,
      "name": "Port created by service",
      "network_id": "ba199c9e-ff09-4d7d-a164-ff61c66cf01f",
      "security_groups": [
        "5a79909b-2bf3-4e26-8a9c-0bf6bb175457"
      ],
      "status": "ACTIVE",
      "tags": {},
      "tenant_id": "6a156ddf2ecd497ca786ff2da6df5aa8"
    },
    {
      "admin_state_up": true,
      "allowed_address_pairs": [],
      "description": "",
      "device_id": "b269b8c0-1a42-4464-9314-4396e51e5107",
      "device_owner": "network:gw_interface",
      "fixed_ips": [
        {
          "ip_address": "10.161.55.13",
          "subnet_id": "64887030-9623-4a20-bcb0-c92e8a2496ca"
        }
      ],
      "id": "268d42f6-c25c-4f24-90fe-11324f0dd7ab",
      "mac_address": "b3:e9:45:86:a9:dd",
      "managed_by_service": true,
      "name": "Port for : 3042b2c0-8c4b-4bc6-b847-9d5dff790f29",
      "network_id": "ba199c9e-ff09-4d7d-a164-ff61c66cf01f",
      "security_groups": [
        "5a79909b-2bf3-4e26-8a9c-0bf6bb175457"
      ],
      "status": "ACTIVE",
      "tags": {},
      "tenant_id": "6a156ddf2ecd497ca786ff2da6df5aa8"
    }
  ]
}

Show Port

Show details for port.

Synchronous / Asynchronous

  • Synchronous

Request

HTTP Request Method

  • GET

HTTP Request Path

{endpoint}/v2.0/ports/{port (managed_by_service==True)_id}

HTTP Request Parameters

Parameter Style Type Format Enumeration Description Required
port (managed_by_service==True)_id URI string hyph-uuid - Port unique id. yes

Response

HTTP Response Code List

Response Code Description
200 OK
400 Bad Request
401 UnAuthorized
404 Not Found
500 Internal Server Error

HTTP Response Parameters

Parameter Type Format Description
port object Port (managed_by_service==True) -
admin_state_up boolean - Administrative state of Port (supported when device_owner starts with "compute:")
allowed_address_pairs array<object> - Allowed address pairs
ip_address string cidr-or-ipv4 -
mac_address string - -
description string - Port description.
device_id string hyph-uuid-or-empty The Id of device (i.e physical port id for baremetal).
device_owner string - The name of the port owner
fixed_ips array<object> - List of fixes IP addresses assign to port.
ip_address string - The IP address assign to port within subnet.
subnet_id string hyph-uuid The ID of subnet from which IP address is allocated.
id string hyph-uuid Port unique id.
mac_address string - The MAC address of the port.
managed_by_service boolean - Set to true if only admin can modify it. Normal user has only read access.
name string - Port name.
network_id string hyph-uuid The ID of network this port belongs to.
security_groups array<string> hyph-uuid The IDs of security groups applied to the port.
status string - The port status.
tags object - Port tags.
tenant_id string non-hyph-uuid-or-empty The owner name of port.

Examples

Sample Request Body

This operation does not send a request body.

Sample Response Body

{
  "port": {
    "admin_state_up": true,
    "allowed_address_pairs": [],
    "description": "Port created by service",
    "device_id": "b269b8c0-1a42-4464-9314-4396e51e5107",
    "device_owner": "physical_port",
    "fixed_ips": [
      {
        "ip_address": "10.161.54.13",
        "subnet_id": "93bb920c-19be-4026-8cc7-564bfcd41456"
      }
    ],
    "id": "81c3b7d4-eae2-4858-ab76-fa56117b8ab4",
    "mac_address": "26:8d:42:f6:c2:c4",
    "managed_by_service": true,
    "name": "Port created by service",
    "network_id": "ba199c9e-ff09-4d7d-a164-ff61c66cf01f",
    "security_groups": [
      "5a79909b-2bf3-4e26-8a9c-0bf6bb175457"
    ],
    "status": "ACTIVE",
    "tags": {},
    "tenant_id": "6a156ddf2ecd497ca786ff2da6df5aa8"
  }
}