HP VAN SDN Controller REST API Guide

List flows for a given table_id:
GET /sdn/v2.0/of/datapaths/{dpid}/flows?table_id=200
There is no request body.
Sample response
{
"flows": [
{
"byte_count": 0,
"cookie": "0xffff000000000000",
"duration_nsec": 488000000,
"duration_sec": 10019,
"flow_mod_flags": [
"send_flow_rem"
],
"hard_timeout": 0,
"idle_timeout": 0,
"instructions": [
{
"apply_actions": [
{
"output": "CONTROLLER"
}
]
}
],
"match": [],
"packet_count": 0,
"priority": 0,
"table_id": 200
}
],
"version": "1.3.0"
}
Response codes
Normal: OK (200)
Error: Bad Request (400), Unauthorized (401), Not Found (404), Service Unavailable (503)
Add a flow
Sample request
Add a flow:
POST /sdn/v2.0/of/datapaths/{dpid}/flows
Sample request:
{"flow": {
"priority": 30000,
"table_id": 200,
"idle_timeout": 60,
"match": [
{"ipv4_src": "10.0.0.1"},
68
{"ipv4_dst": "10.0.0.22"},
{"ip_proto": "tcp"},
{"eth_type": "ipv4"},
{"tcp_dst": "80"}
],
Datapaths 63