Divided APIs docs in sections
Change-Id: I6240e2bc90647ee38c92333957fd7e4a7db60e52
diff --git a/apiary.apib b/apiary.apib
index 1c8816a..fbd11f9 100644
--- a/apiary.apib
+++ b/apiary.apib
@@ -3,741 +3,11 @@
# XOS
-# Group Deployments
-
-List of the XOS deployments
-
-## Deployments [/api/core/deployments/{id}/]
-
-### List all deployments [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "MyDeployment",
- "id": 1,
- "created": "2016-04-29T16:19:03.549901Z",
- "updated": "2016-04-29T16:19:05.624151Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "MyDeployment",
- "accessControl": "allow all",
- "images": [
- "1"
- ],
- "sites": [
- "1"
- ],
- "flavors": [
- "1",
- "2",
- "3"
- ],
- "dashboardviews": [
- "1"
- ]
- }
- ]
-
-### Create a deployment [POST]
-
-+ Request (application/json)
-
- {
- "humanReadableName": "MyDeployment",
- }
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "MyDeployment",
- "id": 1,
- "created": "2016-04-29T16:19:03.549901Z",
- "updated": "2016-04-29T16:19:05.624151Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "MyDeployment",
- "accessControl": "allow all",
- "images": [
- "1"
- ],
- "sites": [
- "1"
- ],
- "flavors": [
- "1",
- "2",
- "3"
- ],
- "dashboardviews": [
- "1"
- ]
- }
-
-### View a Deployment Detail [GET]
-
-+ Parameters
- + id: 1 (number) - ID of the Deployment in the form of an integer
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "MyDeployment",
- "id": 1,
- "created": "2016-04-27T21:46:57.354544Z",
- "updated": "2016-04-27T21:47:05.221720Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "MyDeployment",
- "accessControl": "allow all",
- "images": [],
- "sites": [
- "1"
- ],
- "flavors": [
- "3",
- "2",
- "1"
- ],
- "dashboardviews": [
- "3"
- ]
- }
-
-### Delete a Deployment [DELETE]
-
-+ Parameters
- + id: 1 (number) - ID of the Deployment in the form of an integer
-
-+ Response 204
-
-
-# Group Flavors
-
-List of the XOS flavors
-
-## Flavors [/api/core/flavors/{id}/]
-
-### List all flavors [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "m1.large",
- "id": 1,
- "created": "2016-04-29T16:19:01.979548Z",
- "updated": "2016-04-29T16:19:03.568238Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "m1.large",
- "description": null,
- "flavor": "m1.large",
- "order": 0,
- "default": false,
- "deployments": [
- "1"
- ]
- }
- ]
-
-### Create a Flavor [POST]
-
-+ Request (application/json)
-
- {
- "humanReadableName": "mq.test",
- }
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "m1.large",
- "id": 1,
- "created": "2016-04-29T16:19:01.979548Z",
- "updated": "2016-04-29T16:19:03.568238Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "m1.large",
- "description": null,
- "flavor": "m1.large",
- "order": 0,
- "default": false,
- "deployments": [
- "1"
- ]
- }
-
-### View a Flavors Detail [GET]
-
-+ Parameters
- + id: 1 (number) - ID of the Flavors in the form of an integer
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "m1.large",
- "id": 1,
- "created": "2016-04-29T16:19:01.979548Z",
- "updated": "2016-04-29T16:19:03.568238Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "m1.large",
- "description": null,
- "flavor": "m1.large",
- "order": 0,
- "default": false,
- "deployments": [
- "1"
- ]
- }
-
-### Delete a Flavors Detail [DELETE]
-
-+ Parameters
- + id: 1 (number) - ID of the Flavors in the form of an integer
-
-+ Response 204
-
-
-# Group Instances
-
-List of the XOS instances
-
-## Instances Collection [/api/core/instances/{?no_hyperlinks}]
-
- + no_hyperlinks (number, optional) - Wheter to return relation with links or ids
- + Default: `0`
-
-### List all Instances [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "id": 1,
- "humanReadableName": "uninstantiated-1",
- "created": "2016-04-26T00:36:22.465259Z",
- "updated": "2016-04-26T00:36:22.465288Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "instance_id": null,
- "instance_uuid": null,
- "name": "mysite_vcpe",
- "instance_name": null,
- "ip": null,
- "image": "1",
- "creator": "1",
- "slice": "1",
- "deployment": "1",
- "node": "1",
- "numberCores": 0,
- "flavor": "1",
- "userData": null,
- "isolation": "vm",
- "volumes": "/etc/dnsmasq.d,/etc/ufw",
- "parent": null,
- "networks": [
- "1"
- ]
- }
- ]
-
-### Create an Instance [POST]
-
-+ Parameters
- + no_hyperlinks: 1
-
-+ Request (application/json)
-
- {
- "name": "test-instance",
- "image": 1,
- "slice": 1,
- "deployment": 1,
- "node": 1
- }
-
-+ Response 200 (application/json)
-
- {
- "id": 1,
- "humanReadableName": "uninstantiated-1",
- "created": "2016-04-26T00:36:22.465259Z",
- "updated": "2016-04-26T00:36:22.465288Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "instance_id": null,
- "instance_uuid": null,
- "name": "test-instance",
- "instance_name": null,
- "ip": null,
- "image": "1",
- "creator": "1",
- "slice": "1",
- "deployment": "1",
- "node": "1",
- "numberCores": 0,
- "flavor": "1",
- "userData": null,
- "isolation": "vm",
- "volumes": "/etc/dnsmasq.d,/etc/ufw",
- "parent": null,
- "networks": [
- "1"
- ]
- }
-
-## Instances Detail [/api/core/instances/{id}/]
-
-### Get instance details [GET]
-
-+ Parameters
- + id: 1 (number) - ID of the Instance in the form of an integer
-
-+ Response 200 (application/json)
-
- {
- "id": 1,
- "humanReadableName": "uninstantiated-1",
- "created": "2016-04-26T00:36:22.465259Z",
- "updated": "2016-04-26T00:36:22.465288Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "instance_id": null,
- "instance_uuid": null,
- "name": "mysite_vcpe",
- "instance_name": null,
- "ip": null,
- "image": "1",
- "creator": "1",
- "slice": "1",
- "deployment": "1",
- "node": "1",
- "numberCores": 0,
- "flavor": "1",
- "userData": null,
- "isolation": "vm",
- "volumes": "/etc/dnsmasq.d,/etc/ufw",
- "parent": null,
- "networks": [
- "1"
- ]
- }
-
-### Delete instance [DELETE]
-
-+ Parameters
- + id: 1 (number) - ID of the Instance in the form of an integer
-
-+ Response 204
-
-
-# Group Nodes
-
-List of the XOS nodes
-
-## Nodes [/api/core/nodes/{id}/]
-
-### List all nodes [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "node2.opencloud.us",
- "id": 1,
- "created": "2016-04-29T16:19:05.661567Z",
- "updated": "2016-04-29T16:19:05.661454Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": true,
- "name": "node2.opencloud.us",
- "site_deployment": "1",
- "site": "1",
- "nodelabels": []
- }
- ]
-
-
-
-# Group Services
-
-List of the XOS Services
-
-## Services [/api/core/services/{id}/]
-
-### List all Services [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "MyService",
- "id": 1,
- "created": "2016-05-05T23:06:33.835277Z",
- "updated": "2016-05-05T23:06:33.835302Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "no_policy": false,
- "description": null,
- "enabled": true,
- "kind": "vROUTER",
- "name": "MyService",
- "versionNumber": null,
- "published": true,
- "view_url": "/admin/vrouter/vrouterservice/$id$/",
- "icon_url": null,
- "public_key": null,
- "private_key_fn": null,
- "service_specific_id": null,
- "service_specific_attribute": null
- }
- ]
-
-### Create a Service [POST]
-
-+ Request (application/json)
-
- {
- "name": "MyService",
- "kind": "vROUTER"
- }
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "MyService",
- "id": 1,
- "created": "2016-05-05T23:06:33.835277Z",
- "updated": "2016-05-05T23:06:33.835302Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "no_policy": false,
- "description": null,
- "enabled": true,
- "kind": "vROUTER",
- "name": "MyService",
- "versionNumber": null,
- "published": true,
- "view_url": "/admin/vrouter/vrouterservice/$id$/",
- "icon_url": null,
- "public_key": null,
- "private_key_fn": null,
- "service_specific_id": null,
- "service_specific_attribute": null
- }
-
-### View a Service Detail [GET]
-
-+ Parameters
- + id: 1 (number) - ID of the Service in the form of an integer
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "MyService",
- "id": 1,
- "created": "2016-05-05T23:06:33.835277Z",
- "updated": "2016-05-05T23:06:33.835302Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "no_policy": false,
- "description": null,
- "enabled": true,
- "kind": "vROUTER",
- "name": "MyService",
- "versionNumber": null,
- "published": true,
- "view_url": "/admin/vrouter/vrouterservice/$id$/",
- "icon_url": null,
- "public_key": null,
- "private_key_fn": null,
- "service_specific_id": null,
- "service_specific_attribute": null
- }
-
-### Delete a Service [DELETE]
-
-+ Parameters
- + id: 1 (number) - ID of the Service in the form of an integer
-
-+ Response 204
-
-
-
-# Group Sites
-
-List of the XOS sites
-
-## Sites [/api/core/sites/{id}/]
-
-### List all sites [GET]
-
-+ Response 200 (application/json)
-
- {
- "humanReadableName": "mysite",
- "id": 1,
- "created": "2016-04-29T16:19:03.587770Z",
- "updated": "2016-04-29T16:19:05.651933Z",
- "enacted": null,
- "policed": null,
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "name": "MySite",
- "site_url": "http://opencord.us/",
- "enabled": true,
- "hosts_nodes": true,
- "hosts_users": true,
- "location": null,
- "longitude": null,
- "latitude": null,
- "login_base": "mysite",
- "is_public": true,
- "abbreviated_name": "",
- "deployments": [
- "1"
- ]
- }
-
-
-# Group Slices
-
-List of the XOS slices
-
-## Slices [/api/core/slices/{id}/]
-
-### List all slices [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "mysite_slice",
- "id": 1,
- "created": "2016-04-29T16:23:22.505072Z",
- "updated": "2016-04-29T16:23:22.504691Z",
- "enacted": null,
- "policed": "2016-04-29T16:23:22.781298Z",
- "backend_register": "{}",
- "backend_status": "0 - Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "lazy_blocked": false,
- "no_sync": false,
- "name": "mysite_slice",
- "enabled": true,
- "omf_friendly": false,
- "description": "",
- "slice_url": "",
- "site": "http://apt118.apt.emulab.net/api/core/sites/1/",
- "max_instances": 10,
- "service": null,
- "network": null,
- "exposed_ports": null,
- "serviceClass": "http://apt118.apt.emulab.net/api/core/serviceclasses/1/",
- "creator": "http://apt118.apt.emulab.net/api/core/users/1/",
- "default_flavor": null,
- "default_image": null,
- "mount_data_sets": "GenBank",
- "default_isolation": "vm",
- "networks": [
- "http://apt118.apt.emulab.net/api/core/networks/1/"
- ]
- }
- ]
-
-
-
-# Group Users
-
-List of the XOS users
-
-## Users [/api/core/users/{id}/]
-
-### List all Users [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "id": 2,
- "password": "pbkdf2_sha256$12000$9gn8DmZuIoz2$YPQkx3AOOV7jZNYr2ddrgUCkiuaPpvb8+aJR7RwLZNA=",
- "last_login": "2016-04-12T18:50:45.880823Z",
- "email": "johndoe@myhouse.com",
- "username": "johndoe@myhouse.com",
- "firstname": "john",
- "lastname": "doe",
- "phone": null,
- "user_url": null,
- "site": "http://xos.dev:9999/api/core/sites/1/",
- "public_key": null,
- "is_active": true,
- "is_admin": false,
- "is_staff": true,
- "is_readonly": false,
- "is_registering": false,
- "is_appuser": false,
- "login_page": null,
- "created": "2016-04-12T18:50:45.912602Z",
- "updated": "2016-04-12T18:50:45.912671Z",
- "enacted": null,
- "policed": null,
- "backend_status": "Provisioning in progress",
- "deleted": false,
- "write_protect": false,
- "timezone": "America/New_York"
- }
- ]
-
-
-
-# Group Example
-
-## Example Services Collection [/api/service/exampleservice/]
-
-### List all Example Services [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "MyExample",
- "id": 1,
- "service_message": "This is the test message"
- }
- ]
-
-
-
-# Group ONOS Services
-
-List of the active onos services
-
-## ONOS Services Collection [/api/service/onos/]
-
-### List all ONOS Services [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "service_ONOS_vBNG",
- "id": 5,
- "rest_hostname": "",
- "rest_port": "8181",
- "no_container": false,
- "node_key": ""
- }
- ]
-
-
-# Group vSG
-
-## vSG Collection [/api/service/vsg/]
-
-### List all vSGs [GET]
-
-+ Response 200 (application/json)
-
- [
- {
- "humanReadableName": "service_vsg",
- "id": 2,
- "dns_servers": "8.8.8.8",
- "url_filter_kind": null,
- "node_label": null
- }
- ]
-
-
# Group Utility
List of the XOS Utility API
-
+
+
## Login [/api/utility/login/]
### Log a user in the system [POST]
@@ -914,12 +184,13 @@
]
-# Group Subscribers
+# Group Tenant
+
+
+## Subscribers [/api/tenant/cord/subscriber/{subscriber_id}/]
Resource related to the CORD Subscribers.
-## Subscribers [/api/tenant/cord/subscriber/{subscriber_id}/]
-
### List All Subscribers [GET]
+ Response 200 (application/json)
@@ -1146,12 +417,10 @@
}
-# Group Truckroll
+## Truckroll Collection [/api/tenant/truckroll/{truckroll_id}/]
Virtual Truckroll, enable to perform basic test on user connectivity such as ping, traceroute and tcpdump.
-## Truckroll Collection [/api/tenant/truckroll/{truckroll_id}/]
-
### List all Truckroll [GET]
+ Response 200 (application/json)
@@ -1232,12 +501,10 @@
-# Group vOLT
+## vOLT Collection [/api/tenant/cord/volt/{volt_id}/]
OLT devices aggregate a set of subscriber connections
-## vOLT Collection [/api/tenant/cord/volt/{volt_id}/]
-
### List all vOLT [GET]
+ Response 200 (application/json)
@@ -1313,8 +580,6 @@
-# Group ONOS Apps
-
## ONOS App Collection [/api/tenant/onos/app/]
### List all apps [GET]
@@ -1328,4 +593,711 @@
"name": "vBNG_ONOS_app",
"dependencies": "org.onosproject.proxyarp, org.onosproject.virtualbng, org.onosproject.openflow, org.onosproject.fwd"
}
- ]
\ No newline at end of file
+ ]
+
+
+# Group Service
+
+
+## Example Services Collection [/api/service/exampleservice/]
+
+### List all Example Services [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "MyExample",
+ "id": 1,
+ "service_message": "This is the test message"
+ }
+ ]
+
+
+
+## ONOS Services Collection [/api/service/onos/]
+
+List of the active onos services
+
+### List all ONOS Services [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "service_ONOS_vBNG",
+ "id": 5,
+ "rest_hostname": "",
+ "rest_port": "8181",
+ "no_container": false,
+ "node_key": ""
+ }
+ ]
+
+
+## vSG Collection [/api/service/vsg/]
+
+### List all vSGs [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "service_vsg",
+ "id": 2,
+ "dns_servers": "8.8.8.8",
+ "url_filter_kind": null,
+ "node_label": null
+ }
+ ]
+
+
+# Group Core
+
+List of the XOS Core API
+
+
+## Deployments [/api/core/deployments/{id}/]
+
+List of the XOS deployments
+
+### List all deployments [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "MyDeployment",
+ "id": 1,
+ "created": "2016-04-29T16:19:03.549901Z",
+ "updated": "2016-04-29T16:19:05.624151Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "MyDeployment",
+ "accessControl": "allow all",
+ "images": [
+ "1"
+ ],
+ "sites": [
+ "1"
+ ],
+ "flavors": [
+ "1",
+ "2",
+ "3"
+ ],
+ "dashboardviews": [
+ "1"
+ ]
+ }
+ ]
+
+### Create a deployment [POST]
+
++ Request (application/json)
+
+ {
+ "humanReadableName": "MyDeployment",
+ }
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "MyDeployment",
+ "id": 1,
+ "created": "2016-04-29T16:19:03.549901Z",
+ "updated": "2016-04-29T16:19:05.624151Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "MyDeployment",
+ "accessControl": "allow all",
+ "images": [
+ "1"
+ ],
+ "sites": [
+ "1"
+ ],
+ "flavors": [
+ "1",
+ "2",
+ "3"
+ ],
+ "dashboardviews": [
+ "1"
+ ]
+ }
+
+### View a Deployment Detail [GET]
+
++ Parameters
+ + id: 1 (number) - ID of the Deployment in the form of an integer
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "MyDeployment",
+ "id": 1,
+ "created": "2016-04-27T21:46:57.354544Z",
+ "updated": "2016-04-27T21:47:05.221720Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "MyDeployment",
+ "accessControl": "allow all",
+ "images": [],
+ "sites": [
+ "1"
+ ],
+ "flavors": [
+ "3",
+ "2",
+ "1"
+ ],
+ "dashboardviews": [
+ "3"
+ ]
+ }
+
+### Delete a Deployment [DELETE]
+
++ Parameters
+ + id: 1 (number) - ID of the Deployment in the form of an integer
+
++ Response 204
+
+
+## Flavors [/api/core/flavors/{id}/]
+
+List of the XOS flavors
+
+### List all flavors [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "m1.large",
+ "id": 1,
+ "created": "2016-04-29T16:19:01.979548Z",
+ "updated": "2016-04-29T16:19:03.568238Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "m1.large",
+ "description": null,
+ "flavor": "m1.large",
+ "order": 0,
+ "default": false,
+ "deployments": [
+ "1"
+ ]
+ }
+ ]
+
+### Create a Flavor [POST]
+
++ Request (application/json)
+
+ {
+ "humanReadableName": "mq.test",
+ }
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "m1.large",
+ "id": 1,
+ "created": "2016-04-29T16:19:01.979548Z",
+ "updated": "2016-04-29T16:19:03.568238Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "m1.large",
+ "description": null,
+ "flavor": "m1.large",
+ "order": 0,
+ "default": false,
+ "deployments": [
+ "1"
+ ]
+ }
+
+### View a Flavors Detail [GET]
+
++ Parameters
+ + id: 1 (number) - ID of the Flavors in the form of an integer
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "m1.large",
+ "id": 1,
+ "created": "2016-04-29T16:19:01.979548Z",
+ "updated": "2016-04-29T16:19:03.568238Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "m1.large",
+ "description": null,
+ "flavor": "m1.large",
+ "order": 0,
+ "default": false,
+ "deployments": [
+ "1"
+ ]
+ }
+
+### Delete a Flavors Detail [DELETE]
+
++ Parameters
+ + id: 1 (number) - ID of the Flavors in the form of an integer
+
++ Response 204
+
+
+## Instances Collection [/api/core/instances/{?no_hyperlinks}]
+
+ + no_hyperlinks (number, optional) - Wheter to return relation with links or ids
+ + Default: `0`
+
+### List all Instances [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "id": 1,
+ "humanReadableName": "uninstantiated-1",
+ "created": "2016-04-26T00:36:22.465259Z",
+ "updated": "2016-04-26T00:36:22.465288Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "instance_id": null,
+ "instance_uuid": null,
+ "name": "mysite_vcpe",
+ "instance_name": null,
+ "ip": null,
+ "image": "1",
+ "creator": "1",
+ "slice": "1",
+ "deployment": "1",
+ "node": "1",
+ "numberCores": 0,
+ "flavor": "1",
+ "userData": null,
+ "isolation": "vm",
+ "volumes": "/etc/dnsmasq.d,/etc/ufw",
+ "parent": null,
+ "networks": [
+ "1"
+ ]
+ }
+ ]
+
+### Create an Instance [POST]
+
++ Parameters
+ + no_hyperlinks: 1
+
++ Request (application/json)
+
+ {
+ "name": "test-instance",
+ "image": 1,
+ "slice": 1,
+ "deployment": 1,
+ "node": 1
+ }
+
++ Response 200 (application/json)
+
+ {
+ "id": 1,
+ "humanReadableName": "uninstantiated-1",
+ "created": "2016-04-26T00:36:22.465259Z",
+ "updated": "2016-04-26T00:36:22.465288Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "instance_id": null,
+ "instance_uuid": null,
+ "name": "test-instance",
+ "instance_name": null,
+ "ip": null,
+ "image": "1",
+ "creator": "1",
+ "slice": "1",
+ "deployment": "1",
+ "node": "1",
+ "numberCores": 0,
+ "flavor": "1",
+ "userData": null,
+ "isolation": "vm",
+ "volumes": "/etc/dnsmasq.d,/etc/ufw",
+ "parent": null,
+ "networks": [
+ "1"
+ ]
+ }
+
+## Instances Detail [/api/core/instances/{id}/]
+
+### Get instance details [GET]
+
++ Parameters
+ + id: 1 (number) - ID of the Instance in the form of an integer
+
++ Response 200 (application/json)
+
+ {
+ "id": 1,
+ "humanReadableName": "uninstantiated-1",
+ "created": "2016-04-26T00:36:22.465259Z",
+ "updated": "2016-04-26T00:36:22.465288Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "instance_id": null,
+ "instance_uuid": null,
+ "name": "mysite_vcpe",
+ "instance_name": null,
+ "ip": null,
+ "image": "1",
+ "creator": "1",
+ "slice": "1",
+ "deployment": "1",
+ "node": "1",
+ "numberCores": 0,
+ "flavor": "1",
+ "userData": null,
+ "isolation": "vm",
+ "volumes": "/etc/dnsmasq.d,/etc/ufw",
+ "parent": null,
+ "networks": [
+ "1"
+ ]
+ }
+
+### Delete instance [DELETE]
+
++ Parameters
+ + id: 1 (number) - ID of the Instance in the form of an integer
+
++ Response 204
+
+
+## Nodes [/api/core/nodes/{id}/]
+
+### List all nodes [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "node2.opencloud.us",
+ "id": 1,
+ "created": "2016-04-29T16:19:05.661567Z",
+ "updated": "2016-04-29T16:19:05.661454Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": true,
+ "name": "node2.opencloud.us",
+ "site_deployment": "1",
+ "site": "1",
+ "nodelabels": []
+ }
+ ]
+
+
+
+## Services [/api/core/services/{id}/]
+
+### List all Services [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "MyService",
+ "id": 1,
+ "created": "2016-05-05T23:06:33.835277Z",
+ "updated": "2016-05-05T23:06:33.835302Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "no_policy": false,
+ "description": null,
+ "enabled": true,
+ "kind": "vROUTER",
+ "name": "MyService",
+ "versionNumber": null,
+ "published": true,
+ "view_url": "/admin/vrouter/vrouterservice/$id$/",
+ "icon_url": null,
+ "public_key": null,
+ "private_key_fn": null,
+ "service_specific_id": null,
+ "service_specific_attribute": null
+ }
+ ]
+
+### Create a Service [POST]
+
++ Request (application/json)
+
+ {
+ "name": "MyService",
+ "kind": "vROUTER"
+ }
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "MyService",
+ "id": 1,
+ "created": "2016-05-05T23:06:33.835277Z",
+ "updated": "2016-05-05T23:06:33.835302Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "no_policy": false,
+ "description": null,
+ "enabled": true,
+ "kind": "vROUTER",
+ "name": "MyService",
+ "versionNumber": null,
+ "published": true,
+ "view_url": "/admin/vrouter/vrouterservice/$id$/",
+ "icon_url": null,
+ "public_key": null,
+ "private_key_fn": null,
+ "service_specific_id": null,
+ "service_specific_attribute": null
+ }
+
+### View a Service Detail [GET]
+
++ Parameters
+ + id: 1 (number) - ID of the Service in the form of an integer
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "MyService",
+ "id": 1,
+ "created": "2016-05-05T23:06:33.835277Z",
+ "updated": "2016-05-05T23:06:33.835302Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "no_policy": false,
+ "description": null,
+ "enabled": true,
+ "kind": "vROUTER",
+ "name": "MyService",
+ "versionNumber": null,
+ "published": true,
+ "view_url": "/admin/vrouter/vrouterservice/$id$/",
+ "icon_url": null,
+ "public_key": null,
+ "private_key_fn": null,
+ "service_specific_id": null,
+ "service_specific_attribute": null
+ }
+
+### Delete a Service [DELETE]
+
++ Parameters
+ + id: 1 (number) - ID of the Service in the form of an integer
+
++ Response 204
+
+
+
+## Sites [/api/core/sites/{id}/]
+
+### List all sites [GET]
+
++ Response 200 (application/json)
+
+ {
+ "humanReadableName": "mysite",
+ "id": 1,
+ "created": "2016-04-29T16:19:03.587770Z",
+ "updated": "2016-04-29T16:19:05.651933Z",
+ "enacted": null,
+ "policed": null,
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "name": "MySite",
+ "site_url": "http://opencord.us/",
+ "enabled": true,
+ "hosts_nodes": true,
+ "hosts_users": true,
+ "location": null,
+ "longitude": null,
+ "latitude": null,
+ "login_base": "mysite",
+ "is_public": true,
+ "abbreviated_name": "",
+ "deployments": [
+ "1"
+ ]
+ }
+
+
+## Slices [/api/core/slices/{id}/]
+
+List of the XOS slices
+
+### List all slices [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "humanReadableName": "mysite_slice",
+ "id": 1,
+ "created": "2016-04-29T16:23:22.505072Z",
+ "updated": "2016-04-29T16:23:22.504691Z",
+ "enacted": null,
+ "policed": "2016-04-29T16:23:22.781298Z",
+ "backend_register": "{}",
+ "backend_status": "0 - Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "lazy_blocked": false,
+ "no_sync": false,
+ "name": "mysite_slice",
+ "enabled": true,
+ "omf_friendly": false,
+ "description": "",
+ "slice_url": "",
+ "site": "http://apt118.apt.emulab.net/api/core/sites/1/",
+ "max_instances": 10,
+ "service": null,
+ "network": null,
+ "exposed_ports": null,
+ "serviceClass": "http://apt118.apt.emulab.net/api/core/serviceclasses/1/",
+ "creator": "http://apt118.apt.emulab.net/api/core/users/1/",
+ "default_flavor": null,
+ "default_image": null,
+ "mount_data_sets": "GenBank",
+ "default_isolation": "vm",
+ "networks": [
+ "http://apt118.apt.emulab.net/api/core/networks/1/"
+ ]
+ }
+ ]
+
+
+
+## Users [/api/core/users/{id}/]
+
+### List all Users [GET]
+
++ Response 200 (application/json)
+
+ [
+ {
+ "id": 2,
+ "password": "pbkdf2_sha256$12000$9gn8DmZuIoz2$YPQkx3AOOV7jZNYr2ddrgUCkiuaPpvb8+aJR7RwLZNA=",
+ "last_login": "2016-04-12T18:50:45.880823Z",
+ "email": "johndoe@myhouse.com",
+ "username": "johndoe@myhouse.com",
+ "firstname": "john",
+ "lastname": "doe",
+ "phone": null,
+ "user_url": null,
+ "site": "http://xos.dev:9999/api/core/sites/1/",
+ "public_key": null,
+ "is_active": true,
+ "is_admin": false,
+ "is_staff": true,
+ "is_readonly": false,
+ "is_registering": false,
+ "is_appuser": false,
+ "login_page": null,
+ "created": "2016-04-12T18:50:45.912602Z",
+ "updated": "2016-04-12T18:50:45.912671Z",
+ "enacted": null,
+ "policed": null,
+ "backend_status": "Provisioning in progress",
+ "deleted": false,
+ "write_protect": false,
+ "timezone": "America/New_York"
+ }
+ ]
+
\ No newline at end of file
diff --git a/xos/tests/api/gulpfile.js b/xos/tests/api/gulpfile.js
index 988dd8c..c9be91c 100644
--- a/xos/tests/api/gulpfile.js
+++ b/xos/tests/api/gulpfile.js
@@ -10,7 +10,14 @@
gulp.task('concat', function() {
return gulp.src([
'./source/base.md',
- './source/**/*.md'
+ './source/utility/group.md',
+ './source/utility/**/*.md',
+ './source/tenant/group.md',
+ './source/tenant/**/*.md',
+ './source/service/group.md',
+ './source/service/**/*.md',
+ './source/core/group.md',
+ './source/core/**/*.md',
])
.pipe(concat('../../../apiary.apib', {newLine: '\n \n \n'}))
.pipe(gulp.dest('./'));
diff --git a/xos/tests/api/helpers/subscriber.py b/xos/tests/api/helpers/subscriber.py
index 3d56354..caac1fe 100644
--- a/xos/tests/api/helpers/subscriber.py
+++ b/xos/tests/api/helpers/subscriber.py
@@ -12,25 +12,17 @@
from services.volt.models import *
from services.vsg.models import *
from services.vtr.models import *
-from django.contrib.auth import authenticate, login
-from django.core.exceptions import PermissionDenied
-from django.contrib.sessions.models import Session
import urllib2
import json
+from django.utils import timezone
django.setup()
-token = ''
-
def doLogin(username, password):
-
- url = "http://127.0.0.1:8000/xoslib/login?username=%s&password=%s" % (username, password)
-
- print url
-
+ url = "http://127.0.0.1:9999/xoslib/login?username=%s&password=%s" % (username, password)
res = urllib2.urlopen(url).read()
-
- token = json.loads(res)['xoscsrftoken']
+ parsed = json.loads(res)
+ return {'token': parsed['xoscsrftoken'], 'sessionid': parsed['xossessionid']}
def cleanDB():
@@ -64,12 +56,19 @@
for s in AddressPool.objects.all():
s.delete(purge=True)
- print 'DB Cleaned'
+ for s in Flavor.objects.all():
+ s.delete(purge=True)
+
+ for s in Image.objects.all():
+ s.delete(purge=True)
+
+ # print 'DB Cleaned'
def createTestSubscriber():
cleanDB()
+ createFlavors()
# load user
user = User.objects.get(email="padmin@vicci.org")
@@ -81,6 +80,7 @@
# creating the test subscriber
subscriber = CordSubscriberRoot(name='Test Subscriber 1', id=1)
+ subscriber.created = timezone.now()
subscriber.save()
# vRouter service
@@ -97,7 +97,10 @@
ap_vsg.gateway_mac = '02:42:0a:a8:00:01'
ap_vsg.save()
- print 'vRouter created'
+ # print 'vRouter created'
+
+ # cvpe image
+ vsg_img = createImage('ubuntu-vcpe4')
# Site
site = Site.objects.get(name='mysite')
@@ -107,12 +110,12 @@
vsg_service.name = 'service_vsg'
# vSG slice
- vsg_slice = Slice()
+ vsg_slice = Slice(id=2)
vsg_slice.name = site.login_base + "_testVsg"
vsg_slice.service = vsg_service.id
vsg_slice.site = site
vsg_slice.caller = user
-
+ vsg_slice.default_image = vsg_img
vsg_slice.save()
vsg_service.save()
@@ -122,19 +125,19 @@
volt_service.name = 'service_volt'
volt_service.save()
-
# vcpe slice
- vcpe_slice = Slice()
+ vcpe_slice = Slice(id=3)
vcpe_slice.name = site.login_base + "_testVcpe"
vcpe_slice.service = Service.objects.get(kind='vCPE')
vcpe_slice.site = site
vcpe_slice.caller = user
+ vcpe_slice.default_image = vsg_img
vcpe_slice.save()
# print 'vcpe_slice created'
# create a lan network
- lan_net = Network()
+ lan_net = Network(id=1)
lan_net.name = 'lan_network'
lan_net.owner = vcpe_slice
lan_net.template = private_template
@@ -150,13 +153,6 @@
# print 'vcpe network relation added'
- # vbng service
- vbng_service = VBNGService()
- vbng_service.name = 'service_vbng'
- vbng_service.save()
-
- # print 'vbng_service creater'
-
# volt tenant
vt = VOLTTenant(subscriber=subscriber.id, id=1)
vt.s_tag = "222"
@@ -165,7 +161,7 @@
vt.caller = user
vt.save()
- print "Subscriber Created"
+ # print "Subscriber Created"
def deleteTruckrolls():
@@ -182,7 +178,222 @@
def createTruckroll():
setUpTruckroll()
tn = VTRTenant(id=1)
+ tn.created = timezone.now()
tn.save()
-createTestSubscriber()
+def createFlavors():
+ small = Flavor(id=1)
+ small.name = "m1.small"
+ small.created = timezone.now()
+ small.save()
+
+ medium = Flavor(id=2)
+ medium.name = "m1.medium"
+ medium.created = timezone.now()
+ medium.save()
+
+ large = Flavor(id=3)
+ large.name = "m1.large"
+ large.created = timezone.now()
+ large.save()
+
+
+def createSlice():
+ site = Site.objects.get(name='mysite')
+ user = User.objects.get(email="padmin@vicci.org")
+
+ sl = Slice(id=1)
+ sl.created = timezone.now()
+ sl.name = site.login_base + "_testSlice"
+ sl.site = site
+ sl.caller = user
+ sl.save()
+ return sl
+
+
+def createDeployment():
+ deployment = Deployment(id=1)
+ deployment.created = timezone.now()
+ deployment.name = 'MyTestDeployment'
+ deployment.save()
+ return deployment
+
+
+def createImage(name):
+ img = Image(id=1)
+ img.name = name
+ img.created = timezone.now()
+ img.disk_format = 'QCOW2'
+ img.kind = 'vm'
+ img.save()
+ return img
+
+
+def createNode(deployment):
+ site = Site.objects.get(name='mysite')
+
+ site_deployment = SiteDeployment(id=1)
+ site_deployment.site = site
+ site_deployment.created = timezone.now()
+ site_deployment.deployment = deployment
+ site_deployment.save()
+
+ node = Node(id=1)
+ node.name = 'test-node'
+ node.created = timezone.now()
+ node.site = site
+ node.site_deployment = site_deployment
+ node.save()
+ return node
+
+
+def setupInstance():
+ deployment = createDeployment()
+ sl = createSlice()
+ node = createNode(deployment)
+ img = createImage('test-image')
+ # print {'image': img.id, 'deployment': deployment.id, 'slice': sl.id}
+ return {'image': img, 'deployment': deployment, 'slice': sl}
+
+
+def createInstance():
+ requirements = setupInstance()
+ user = User.objects.get(email="padmin@vicci.org")
+
+ instance = Instance(id=1)
+ instance.name = 'test-instance'
+ instance.created = timezone.now()
+ instance.node = Node.objects.all()[0]
+ instance.image = requirements['image']
+ instance.slice = requirements['slice']
+ instance.deployment = requirements['deployment']
+ instance.caller = user
+ instance.save()
+
+
+def createService():
+ service = Service(id=1)
+ service.name = 'test-service'
+ service.save()
+
+@hooks.before_all
+def my_before_all_hook(transactions):
+ # print "-------------------------------- Before All Hook --------------------------------"
+ cleanDB()
+
+
+@hooks.before_each
+def my_before_each_hook(transaction):
+ print "-------------------------------- Before Each Hook --------------------------------"
+ print transaction['name']
+ auth = doLogin('padmin@vicci.org', 'letmein')
+ transaction['request']['headers']['X-CSRFToken'] = auth['token']
+ transaction['request']['headers']['Cookie'] = "xossessionid=%s; xoscsrftoken=%s" % (auth['sessionid'], auth['token'])
+ createTestSubscriber()
+ setupInstance()
+ sys.stdout.flush()
+
+
+# @hooks.after_each
+# def my_after_each(transaction):
+# print "-------------------------------- Test end --------------------------------"
+
+
+@hooks.before("Core > Services > View a Service Detail")
+def get_service(transaction):
+ createService()
+
+
+@hooks.before("Core > Services > Delete a Service")
+def delete_service(transaction):
+ createService()
+
+
+@hooks.before("Tenant > Truckroll Collection > Create a Truckroll")
+def test1(transaction):
+ setUpTruckroll()
+
+
+@hooks.before("Tenant > Truckroll Collection > View a Truckroll Detail")
+def test2(transaction):
+ deleteTruckrolls()
+ createTruckroll()
+
+
+@hooks.before("Tenant > Truckroll Collection > Delete a Truckroll Detail")
+def test3(transaction):
+ deleteTruckrolls()
+ createTruckroll()
+
+
+@hooks.before("Tenant > vOLT Collection > Create a vOLT")
+def test4(transaction):
+ # transaction['skip'] = True
+ VOLTTenant.objects.get(kind='vOLT').delete()
+
+
+@hooks.before("Core > Flavors > View a Flavors Detail")
+def test5(transaction):
+ createFlavors()
+
+
+@hooks.before("Core > Deployments > View a Deployment Detail")
+def get_deployments(transaction):
+ createDeployment()
+
+
+@hooks.before("Core > Deployments > Delete a Deployment")
+def delete_deployments(transaction):
+ createDeployment()
+
+
+@hooks.before("Core > Instances Collection > Create an Instance")
+def create_instance(transaction):
+ setupInstance()
+ transaction['skip'] = True
+
+
+@hooks.before("Core > Instances Detail > Get instance details")
+def get_instance(transaction):
+ createInstance()
+
+
+@hooks.before("Core > Instances Detail > Delete instance")
+def delete_instance(transaction):
+ createInstance()
+
+
+@hooks.before("Service > Example Services Collection > List all Example Services")
+def exampleTest(transaction):
+ transaction['skip'] = True
+
+
+@hooks.before("Service > Login > Log a user in the system")
+def before_logout_hook(transaction):
+ transaction['skip'] = True
+ # auth = doLogin('padmin@vicci.org', 'letmein')
+ # transaction['request']['body'] = {}
+ # transaction['request']['body']['xossessionid'] = auth['sessionid']
+
+
+@hooks.before("Utility > Logout > Log a user out of the system")
+def skip_logout(transaction):
+ transaction['skip'] = True
+
+
+@hooks.before("Utility > Onboarding > Get service status")
+def skip_onboarding(transaction):
+ transaction['skip'] = True
+
+
+@hooks.after("Utility > Tosca > Load a Tosca recipe")
+def check_tosca(transaction):
+ try:
+ site = Site.objects.get(name='Test Site')
+ except Exception, e:
+ transaction['fail'] = "Test Site has not been created"
+
+
+deleteTruckrolls()
+createTruckroll()
diff --git a/xos/tests/api/hooks.py b/xos/tests/api/hooks.py
index 61d00c7..248907b 100644
--- a/xos/tests/api/hooks.py
+++ b/xos/tests/api/hooks.py
@@ -300,76 +300,76 @@
# print "-------------------------------- Test end --------------------------------"
-@hooks.before("Services > Services > View a Service Detail")
+@hooks.before("Core > Services > View a Service Detail")
def get_service(transaction):
createService()
-@hooks.before("Services > Services > Delete a Service")
+@hooks.before("Core > Services > Delete a Service")
def delete_service(transaction):
createService()
-@hooks.before("Truckroll > Truckroll Collection > Create a Truckroll")
+@hooks.before("Tenant > Truckroll Collection > Create a Truckroll")
def test1(transaction):
setUpTruckroll()
-@hooks.before("Truckroll > Truckroll Collection > View a Truckroll Detail")
+@hooks.before("Tenant > Truckroll Collection > View a Truckroll Detail")
def test2(transaction):
deleteTruckrolls()
createTruckroll()
-@hooks.before("Truckroll > Truckroll Collection > Delete a Truckroll Detail")
+@hooks.before("Tenant > Truckroll Collection > Delete a Truckroll Detail")
def test3(transaction):
deleteTruckrolls()
createTruckroll()
-@hooks.before("vOLT > vOLT Collection > Create a vOLT")
+@hooks.before("Tenant > vOLT Collection > Create a vOLT")
def test4(transaction):
# transaction['skip'] = True
VOLTTenant.objects.get(kind='vOLT').delete()
-@hooks.before("Flavors > Flavors > View a Flavors Detail")
+@hooks.before("Core > Flavors > View a Flavors Detail")
def test5(transaction):
createFlavors()
-@hooks.before("Deployments > Deployments > View a Deployment Detail")
+@hooks.before("Core > Deployments > View a Deployment Detail")
def get_deployments(transaction):
createDeployment()
-@hooks.before("Deployments > Deployments > Delete a Deployment")
+@hooks.before("Core > Deployments > Delete a Deployment")
def delete_deployments(transaction):
createDeployment()
-@hooks.before("Instances > Instances Collection > Create an Instance")
+@hooks.before("Core > Instances Collection > Create an Instance")
def create_instance(transaction):
setupInstance()
transaction['skip'] = True
-@hooks.before("Instances > Instances Detail > Get instance details")
+@hooks.before("Core > Instances Detail > Get instance details")
def get_instance(transaction):
createInstance()
-@hooks.before("Instances > Instances Detail > Delete instance")
+@hooks.before("Core > Instances Detail > Delete instance")
def delete_instance(transaction):
createInstance()
-@hooks.before("Example > Example Services Collection > List all Example Services")
+@hooks.before("Service > Example Services Collection > List all Example Services")
def exampleTest(transaction):
transaction['skip'] = True
-@hooks.before("Utility > Login > Log a user in the system")
+@hooks.before("Service > Login > Log a user in the system")
def before_logout_hook(transaction):
transaction['skip'] = True
# auth = doLogin('padmin@vicci.org', 'letmein')
diff --git a/xos/tests/api/source/core/deployment.md b/xos/tests/api/source/core/deployment.md
index 764a73f..d6e9931 100644
--- a/xos/tests/api/source/core/deployment.md
+++ b/xos/tests/api/source/core/deployment.md
@@ -1,9 +1,7 @@
-# Group Deployments
+## Deployments [/api/core/deployments/{id}/]
List of the XOS deployments
-## Deployments [/api/core/deployments/{id}/]
-
### List all deployments [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/core/flavors.md b/xos/tests/api/source/core/flavors.md
index aba5a6b..78ca189 100644
--- a/xos/tests/api/source/core/flavors.md
+++ b/xos/tests/api/source/core/flavors.md
@@ -1,9 +1,7 @@
-# Group Flavors
+## Flavors [/api/core/flavors/{id}/]
List of the XOS flavors
-## Flavors [/api/core/flavors/{id}/]
-
### List all flavors [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/core/group.md b/xos/tests/api/source/core/group.md
new file mode 100644
index 0000000..7298012
--- /dev/null
+++ b/xos/tests/api/source/core/group.md
@@ -0,0 +1,3 @@
+# Group Core
+
+List of the XOS Core API
\ No newline at end of file
diff --git a/xos/tests/api/source/core/instances.md b/xos/tests/api/source/core/instances.md
index 9caf93e..b3f4ce9 100644
--- a/xos/tests/api/source/core/instances.md
+++ b/xos/tests/api/source/core/instances.md
@@ -1,7 +1,3 @@
-# Group Instances
-
-List of the XOS instances
-
## Instances Collection [/api/core/instances/{?no_hyperlinks}]
+ no_hyperlinks (number, optional) - Wheter to return relation with links or ids
diff --git a/xos/tests/api/source/core/nodes.md b/xos/tests/api/source/core/nodes.md
index d9931dc..bad3a3a 100644
--- a/xos/tests/api/source/core/nodes.md
+++ b/xos/tests/api/source/core/nodes.md
@@ -1,7 +1,3 @@
-# Group Nodes
-
-List of the XOS nodes
-
## Nodes [/api/core/nodes/{id}/]
### List all nodes [GET]
diff --git a/xos/tests/api/source/core/services.md b/xos/tests/api/source/core/services.md
index 3454bdb..fb2d4a2 100644
--- a/xos/tests/api/source/core/services.md
+++ b/xos/tests/api/source/core/services.md
@@ -1,7 +1,3 @@
-# Group Services
-
-List of the XOS Services
-
## Services [/api/core/services/{id}/]
### List all Services [GET]
diff --git a/xos/tests/api/source/core/sites.md b/xos/tests/api/source/core/sites.md
index 731199e..7f963c3 100644
--- a/xos/tests/api/source/core/sites.md
+++ b/xos/tests/api/source/core/sites.md
@@ -1,7 +1,3 @@
-# Group Sites
-
-List of the XOS sites
-
## Sites [/api/core/sites/{id}/]
### List all sites [GET]
diff --git a/xos/tests/api/source/core/slices.md b/xos/tests/api/source/core/slices.md
index 6ec5c7e..050aade 100644
--- a/xos/tests/api/source/core/slices.md
+++ b/xos/tests/api/source/core/slices.md
@@ -1,9 +1,7 @@
-# Group Slices
+## Slices [/api/core/slices/{id}/]
List of the XOS slices
-## Slices [/api/core/slices/{id}/]
-
### List all slices [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/core/users.md b/xos/tests/api/source/core/users.md
index 8ccabb5..5a6518a 100644
--- a/xos/tests/api/source/core/users.md
+++ b/xos/tests/api/source/core/users.md
@@ -1,7 +1,3 @@
-# Group Users
-
-List of the XOS users
-
## Users [/api/core/users/{id}/]
### List all Users [GET]
diff --git a/xos/tests/api/source/service/exampleservice.md b/xos/tests/api/source/service/exampleservice.md
index b2d031b..df79fc7 100644
--- a/xos/tests/api/source/service/exampleservice.md
+++ b/xos/tests/api/source/service/exampleservice.md
@@ -1,5 +1,3 @@
-# Group Example
-
## Example Services Collection [/api/service/exampleservice/]
### List all Example Services [GET]
diff --git a/xos/tests/api/source/service/group.md b/xos/tests/api/source/service/group.md
new file mode 100644
index 0000000..daf5737
--- /dev/null
+++ b/xos/tests/api/source/service/group.md
@@ -0,0 +1 @@
+# Group Service
\ No newline at end of file
diff --git a/xos/tests/api/source/service/onos.md b/xos/tests/api/source/service/onos.md
index 0b82a86..33e39d3 100644
--- a/xos/tests/api/source/service/onos.md
+++ b/xos/tests/api/source/service/onos.md
@@ -1,9 +1,7 @@
-# Group ONOS Services
+## ONOS Services Collection [/api/service/onos/]
List of the active onos services
-## ONOS Services Collection [/api/service/onos/]
-
### List all ONOS Services [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/service/vsg.md b/xos/tests/api/source/service/vsg.md
index 1a0569a..1cec60e 100644
--- a/xos/tests/api/source/service/vsg.md
+++ b/xos/tests/api/source/service/vsg.md
@@ -1,5 +1,3 @@
-# Group vSG
-
## vSG Collection [/api/service/vsg/]
### List all vSGs [GET]
diff --git a/xos/tests/api/source/tenant/cord/subscribers.md b/xos/tests/api/source/tenant/cord/subscribers.md
index 61126ce..b9397a5 100644
--- a/xos/tests/api/source/tenant/cord/subscribers.md
+++ b/xos/tests/api/source/tenant/cord/subscribers.md
@@ -1,9 +1,7 @@
-# Group Subscribers
+## Subscribers [/api/tenant/cord/subscriber/{subscriber_id}/]
Resource related to the CORD Subscribers.
-## Subscribers [/api/tenant/cord/subscriber/{subscriber_id}/]
-
### List All Subscribers [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/tenant/cord/truckroll.md b/xos/tests/api/source/tenant/cord/truckroll.md
index 996c19c..2792863 100644
--- a/xos/tests/api/source/tenant/cord/truckroll.md
+++ b/xos/tests/api/source/tenant/cord/truckroll.md
@@ -1,9 +1,7 @@
-# Group Truckroll
+## Truckroll Collection [/api/tenant/truckroll/{truckroll_id}/]
Virtual Truckroll, enable to perform basic test on user connectivity such as ping, traceroute and tcpdump.
-## Truckroll Collection [/api/tenant/truckroll/{truckroll_id}/]
-
### List all Truckroll [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/tenant/cord/volt.md b/xos/tests/api/source/tenant/cord/volt.md
index 51cb679..3f644ad 100644
--- a/xos/tests/api/source/tenant/cord/volt.md
+++ b/xos/tests/api/source/tenant/cord/volt.md
@@ -1,9 +1,7 @@
-# Group vOLT
+## vOLT Collection [/api/tenant/cord/volt/{volt_id}/]
OLT devices aggregate a set of subscriber connections
-## vOLT Collection [/api/tenant/cord/volt/{volt_id}/]
-
### List all vOLT [GET]
+ Response 200 (application/json)
diff --git a/xos/tests/api/source/tenant/group.md b/xos/tests/api/source/tenant/group.md
new file mode 100644
index 0000000..52dde1c
--- /dev/null
+++ b/xos/tests/api/source/tenant/group.md
@@ -0,0 +1 @@
+# Group Tenant
\ No newline at end of file
diff --git a/xos/tests/api/source/tenant/onos/app.md b/xos/tests/api/source/tenant/onos/app.md
index 5376c33..c77365a 100644
--- a/xos/tests/api/source/tenant/onos/app.md
+++ b/xos/tests/api/source/tenant/onos/app.md
@@ -1,5 +1,3 @@
-# Group ONOS Apps
-
## ONOS App Collection [/api/tenant/onos/app/]
### List all apps [GET]
diff --git a/xos/tests/api/source/utility/group.md b/xos/tests/api/source/utility/group.md
new file mode 100644
index 0000000..cac339c
--- /dev/null
+++ b/xos/tests/api/source/utility/group.md
@@ -0,0 +1,3 @@
+# Group Utility
+
+List of the XOS Utility API
\ No newline at end of file
diff --git a/xos/tests/api/source/utility/utility.md b/xos/tests/api/source/utility/utility.md
index 962ba6e..2dce77b 100644
--- a/xos/tests/api/source/utility/utility.md
+++ b/xos/tests/api/source/utility/utility.md
@@ -1,7 +1,3 @@
-# Group Utility
-
-List of the XOS Utility API
-
## Login [/api/utility/login/]
### Log a user in the system [POST]