Difference between revisions of "Neutron/LBaaS/RESTAPI/proposal"
(talk) |
(Moved under Quantum) |
||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
− | + | <!-- ## page was renamed from LBaaS/RESTAPI/proposal --> | |
+ | = Provider API = | ||
{| border="1" cellpadding="2" cellspacing="0" | {| border="1" cellpadding="2" cellspacing="0" | ||
− | | /v2/services/lbaas/devices.json | + | | /v2.0/services/lbaas/devices.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/devices.json | + | | /v2.0/services/lbaas/devices.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/devices/{device_id}.json | + | | /v2.0/services/lbaas/devices/{device_id}.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/devices/{device_id}.json | + | | /v2.0/services/lbaas/devices/{device_id}.json |
| DELETE | | DELETE | ||
|- | |- | ||
− | | /v2/services/lbaas/algorithms.json | + | | /v2.0/services/lbaas/algorithms.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/protocols.json | + | | /v2.0/services/lbaas/protocols.json |
| GET | | GET | ||
|} | |} | ||
− | + | = Tenant API = | |
{| border="1" cellpadding="2" cellspacing="0" | {| border="1" cellpadding="2" cellspacing="0" | ||
− | | /v2/services/lbaas/vips.json | + | |- |
+ | | /v2.0/services/lbaas/vips.json | ||
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/vips.json | + | | /v2.0/services/lbaas/vips.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/vips/{vip_id}.json | + | | /v2.0/services/lbaas/vips/{vip_id}.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/vips/{vip_id}.json | + | | /v2.0/services/lbaas/vips/{vip_id}.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/vips/{vip_id}.json | + | | /v2.0/services/lbaas/vips/{vip_id}.json |
| DELETE | | DELETE | ||
− | | | + | |- |
− | + | |- | |
− | + | | /v2.0/services/lbaas/pools.json | |
− | | /v2/services/lbaas/pools.json | ||
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/pools.json | + | | /v2.0/services/lbaas/pools.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/pools/{pool_id}.json | + | | /v2.0/services/lbaas/pools/{pool_id}.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/pools/{pool_id}.json | + | | /v2.0/services/lbaas/pools/{pool_id}.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/pools/{pool_id}.json | + | | /v2.0/services/lbaas/pools/{pool_id}.json |
| DELETE | | DELETE | ||
− | | | + | |- |
− | + | |- | |
− | + | | /v2.0/services/lbaas/members.json | |
− | | /v2/services/lbaas/members.json | ||
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/members.json | + | | /v2.0/services/lbaas/members.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/members/{member_id}.json | + | | /v2.0/services/lbaas/members/{member_id}.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/members/{member_id}.json | + | | /v2.0/services/lbaas/members/{member_id}.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/members/{member_id}.json | + | | /v2.0/services/lbaas/members/{member_id}.json |
| DELETE | | DELETE | ||
− | | | + | |- |
− | + | |- | |
− | + | | /v2.0/services/lbaas/health_monitors.json | |
− | | /v2/services/lbaas/health_monitors.json | ||
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/health_monitors.json | + | | /v2.0/services/lbaas/health_monitors.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/health_monitors/{health_monitor_id}.json | + | | /v2.0/services/lbaas/health_monitors/{health_monitor_id}.json |
| GET | | GET | ||
|- | |- | ||
− | | /v2/services/lbaas/health_monitors/{health_monitor_id}.json | + | | /v2.0/services/lbaas/health_monitors/{health_monitor_id}.json |
| POST | | POST | ||
|- | |- | ||
− | | /v2/services/lbaas/health_monitors/{health_monitor_id}.json | + | | /v2.0/services/lbaas/health_monitors/{health_monitor_id}.json |
| DELETE | | DELETE | ||
+ | |- | ||
+ | |- | ||
+ | | /v2.0/services/lbaas/pools/{pool_id}/stats.json | ||
+ | | GET | ||
+ | |} | ||
+ | |||
+ | == VIP management == | ||
+ | === List VIPs === | ||
+ | |||
+ | {| border="1" cellpadding="2" cellspacing="0" | ||
+ | | Verb | ||
+ | | URI | ||
+ | |- | ||
+ | | GET | ||
+ | | /vips | ||
+ | |} | ||
+ | |||
+ | Normal Response Code: 200 | ||
+ | |||
+ | Error Response Codes:Unauthorized (401) | ||
+ | |||
+ | This operation does not require a request body, unless the Quantum server is running without Keystone integration. | ||
+ | |||
+ | This operation returns a response body. | ||
+ | |||
+ | '''JSON Request:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | GET /v2.0/services/lbaas/vips.json | ||
+ | Accept: application/json | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | '''JSON Response:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "id": "4b15f63d17834203bec5558851c1c2fc", | ||
+ | "name": "test", | ||
+ | "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", | ||
+ | "address": "172.18.76.14", | ||
+ | "pools": [ | ||
+ | { | ||
+ | "id": "7562ca4be14c42d388b4b9e7be865a87" | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | === Show VIP === | ||
+ | |||
+ | {| border="1" cellpadding="2" cellspacing="0" | ||
+ | | Verb | ||
+ | | URI | ||
+ | |- | ||
+ | | GET | ||
+ | | /vip/{vip_id} | ||
+ | |} | ||
+ | |||
+ | Normal Response Code: 200 | ||
+ | |||
+ | Error Response Codes: Unauthorized (401), Not Found (404) | ||
+ | |||
+ | This operation does not require a request body, unless the Quantum server is running without Keystone integration. | ||
+ | |||
+ | This operation returns a response body. | ||
+ | |||
+ | '''JSON Request:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | GET /v2.0/services/lbaas/vips/{afc75773-640e-403c-9fff-62ba98db1f19}.json | ||
+ | Accept: application/json | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | '''JSON Response:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "id": "4b15f63d17834203bec5558851c1c2fc", | ||
+ | "name": "test", | ||
+ | "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", | ||
+ | "address": "172.18.76.14", | ||
+ | "pools": [ | ||
+ | { | ||
+ | "id": "7562ca4be14c42d388b4b9e7be865a87" | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | === Create VIP === | ||
+ | |||
+ | {| border="1" cellpadding="2" cellspacing="0" | ||
+ | | Verb | ||
+ | | URI | ||
+ | |- | ||
+ | | POST | ||
+ | | /vips | ||
+ | |} | ||
+ | |||
+ | Normal Response Code: 201 | ||
+ | |||
+ | Error Response Codes: Bad Request (400) Unauthorized (401) | ||
+ | |||
+ | This operation requires a request body. The request body must contain a network object that specifies a symbolic name for the network. | ||
+ | |||
+ | This operation returns a response body. | ||
+ | |||
+ | '''JSON Request:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | POST /v2.0/services/lbaas/vips.json | ||
+ | Content-Type: application/json | ||
+ | Accept: application/json | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "name": "test", | ||
+ | "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", | ||
+ | "address": "172.18.76.14", | ||
+ | "pools": [ | ||
+ | { | ||
+ | "id": "7562ca4be14c42d388b4b9e7be865a87" | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | '''JSON Response:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "id": "4b15f63d17834203bec5558851c1c2fc", | ||
+ | "name": "test", | ||
+ | "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", | ||
+ | "address": "172.18.76.14" | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | === Update VIP === | ||
+ | |||
+ | {| border="1" cellpadding="2" cellspacing="0" | ||
+ | | Verb | ||
+ | | URI | ||
+ | |- | ||
+ | | POST | ||
+ | | /vips/{vip_id} | ||
+ | |} | ||
+ | |||
+ | Normal Response Code: 200 | ||
+ | |||
+ | Error Response Codes: Bad Request (400) Unauthorized (401), Forbidden (403) | ||
+ | |||
+ | This operation requires a request body. You can set the following attributes in the request body: | ||
+ | {| border="1" cellpadding="2" cellspacing="0" | ||
+ | | Attribute | ||
+ | |- | ||
+ | | name | ||
|} | |} | ||
+ | |||
+ | This operation returns a response body. | ||
+ | |||
+ | '''JSON Request:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | POST /v2.0/services/lbaas/vips/fc68ea2c-b60b-4b4f-bd82-94ec81110766.json | ||
+ | Content-Type: application/json | ||
+ | Accept: application/json | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "name": "test2", | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | '''JSON Response:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | { | ||
+ | "vips": [ | ||
+ | { | ||
+ | "id": "4b15f63d17834203bec5558851c1c2fc", | ||
+ | "name": "test2", | ||
+ | "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", | ||
+ | "address": "172.18.76.14" | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | === Delete VIP === | ||
{| border="1" cellpadding="2" cellspacing="0" | {| border="1" cellpadding="2" cellspacing="0" | ||
− | | / | + | | Verb |
− | + | | URI | |
+ | |- | ||
+ | | DELETE | ||
+ | | /vip/{vip_id} | ||
|} | |} | ||
+ | |||
+ | Normal Response Code: 204 | ||
+ | |||
+ | Error Response Codes: Unauthorized (401), Not Found (404) | ||
+ | |||
+ | This operation does not require a request body. | ||
+ | |||
+ | This operation does not return a response body. | ||
+ | |||
+ | '''JSON Request:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | DELETE /v2.0/services/lbaas/vips/{afc75773-640e-403c-9fff-62ba98db1f19}.json | ||
+ | Accept: application/json | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | '''JSON Response:''' | ||
+ | |||
+ | <pre><nowiki> | ||
+ | status: 204 | ||
+ | </nowiki></pre> |
Revision as of 15:43, 23 October 2012
Provider API
/v2.0/services/lbaas/devices.json | GET |
/v2.0/services/lbaas/devices.json | POST |
/v2.0/services/lbaas/devices/{device_id}.json | GET |
/v2.0/services/lbaas/devices/{device_id}.json | DELETE |
/v2.0/services/lbaas/algorithms.json | GET |
/v2.0/services/lbaas/protocols.json | GET |
Tenant API
/v2.0/services/lbaas/vips.json | GET |
/v2.0/services/lbaas/vips.json | POST |
/v2.0/services/lbaas/vips/{vip_id}.json | GET |
/v2.0/services/lbaas/vips/{vip_id}.json | POST |
/v2.0/services/lbaas/vips/{vip_id}.json | DELETE |
/v2.0/services/lbaas/pools.json | GET |
/v2.0/services/lbaas/pools.json | POST |
/v2.0/services/lbaas/pools/{pool_id}.json | GET |
/v2.0/services/lbaas/pools/{pool_id}.json | POST |
/v2.0/services/lbaas/pools/{pool_id}.json | DELETE |
/v2.0/services/lbaas/members.json | GET |
/v2.0/services/lbaas/members.json | POST |
/v2.0/services/lbaas/members/{member_id}.json | GET |
/v2.0/services/lbaas/members/{member_id}.json | POST |
/v2.0/services/lbaas/members/{member_id}.json | DELETE |
/v2.0/services/lbaas/health_monitors.json | GET |
/v2.0/services/lbaas/health_monitors.json | POST |
/v2.0/services/lbaas/health_monitors/{health_monitor_id}.json | GET |
/v2.0/services/lbaas/health_monitors/{health_monitor_id}.json | POST |
/v2.0/services/lbaas/health_monitors/{health_monitor_id}.json | DELETE |
/v2.0/services/lbaas/pools/{pool_id}/stats.json | GET |
VIP management
List VIPs
Verb | URI |
GET | /vips |
Normal Response Code: 200
Error Response Codes:Unauthorized (401)
This operation does not require a request body, unless the Quantum server is running without Keystone integration.
This operation returns a response body.
JSON Request:
GET /v2.0/services/lbaas/vips.json Accept: application/json
JSON Response:
{ "vips": [ { "id": "4b15f63d17834203bec5558851c1c2fc", "name": "test", "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", "address": "172.18.76.14", "pools": [ { "id": "7562ca4be14c42d388b4b9e7be865a87" } ] } ] }
Show VIP
Verb | URI |
GET | /vip/{vip_id} |
Normal Response Code: 200
Error Response Codes: Unauthorized (401), Not Found (404)
This operation does not require a request body, unless the Quantum server is running without Keystone integration.
This operation returns a response body.
JSON Request:
GET /v2.0/services/lbaas/vips/{afc75773-640e-403c-9fff-62ba98db1f19}.json Accept: application/json
JSON Response:
{ "vips": [ { "id": "4b15f63d17834203bec5558851c1c2fc", "name": "test", "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", "address": "172.18.76.14", "pools": [ { "id": "7562ca4be14c42d388b4b9e7be865a87" } ] } ] }
Create VIP
Verb | URI |
POST | /vips |
Normal Response Code: 201
Error Response Codes: Bad Request (400) Unauthorized (401)
This operation requires a request body. The request body must contain a network object that specifies a symbolic name for the network.
This operation returns a response body.
JSON Request:
POST /v2.0/services/lbaas/vips.json Content-Type: application/json Accept: application/json
{ "vips": [ { "name": "test", "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", "address": "172.18.76.14", "pools": [ { "id": "7562ca4be14c42d388b4b9e7be865a87" } ] } ] }
JSON Response:
{ "vips": [ { "id": "4b15f63d17834203bec5558851c1c2fc", "name": "test", "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", "address": "172.18.76.14" } ] }
Update VIP
Verb | URI |
POST | /vips/{vip_id} |
Normal Response Code: 200
Error Response Codes: Bad Request (400) Unauthorized (401), Forbidden (403)
This operation requires a request body. You can set the following attributes in the request body:
Attribute |
name |
This operation returns a response body.
JSON Request:
POST /v2.0/services/lbaas/vips/fc68ea2c-b60b-4b4f-bd82-94ec81110766.json Content-Type: application/json Accept: application/json
{ "vips": [ { "name": "test2", } ] }
JSON Response:
{ "vips": [ { "id": "4b15f63d17834203bec5558851c1c2fc", "name": "test2", "network_id": "4a0dc4bb28f74d0aad9903f807c3073c", "address": "172.18.76.14" } ] }
Delete VIP
Verb | URI |
DELETE | /vip/{vip_id} |
Normal Response Code: 204
Error Response Codes: Unauthorized (401), Not Found (404)
This operation does not require a request body.
This operation does not return a response body.
JSON Request:
DELETE /v2.0/services/lbaas/vips/{afc75773-640e-403c-9fff-62ba98db1f19}.json Accept: application/json
JSON Response:
status: 204