Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade to v2 #18

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 26 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ You can find out more about Swagger at [http://swagger.io](http://swagger.io) or

This Python package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:

- API version: 1.0.0
- API version: 2.0.0
- Package version: 1.0.0
- Build package: io.swagger.codegen.v3.generators.python.PythonClientCodegen

Expand Down Expand Up @@ -53,7 +53,7 @@ from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.ConnectionApi(swagger_client.ApiClient(configuration))
connection_id = 789 # int | ID of the connection that needs to be deleted
connection_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # str | ID of the connection that needs to be deleted

try:
# Delete connection order by ID
Expand All @@ -63,7 +63,7 @@ except ApiException as e:

# create an instance of the API class
api_instance = swagger_client.ConnectionApi(swagger_client.ApiClient(configuration))
connection_id = 789 # int | ID of connection that needs to be fetched
connection_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # str | ID of connection that needs to be fetched

try:
# Find connection by ID
Expand All @@ -74,7 +74,17 @@ except ApiException as e:

# create an instance of the API class
api_instance = swagger_client.ConnectionApi(swagger_client.ApiClient(configuration))
body = swagger_client.Connection() # Connection | order placed for creating a connection

try:
# List all connections
api_response = api_instance.getconnections()
pprint(api_response)
except ApiException as e:
print("Exception when calling ConnectionApi->getconnections: %s\n" % e)

# create an instance of the API class
api_instance = swagger_client.ConnectionApi(swagger_client.ApiClient(configuration))
body = swagger_client.ConnectionBody() # ConnectionBody | order placed for creating a connection

try:
# Place an connection request from the SDX-Controller
Expand All @@ -90,13 +100,14 @@ All URIs are relative to *https://virtserver.swaggerhub.com/SDX-Controller/1.0.0

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*ConnectionApi* | [**delete_connection**](docs/ConnectionApi.md#delete_connection) | **DELETE** /connection/{connectionId} | Delete connection order by ID
*ConnectionApi* | [**getconnection_by_id**](docs/ConnectionApi.md#getconnection_by_id) | **GET** /connection/{connectionId} | Find connection by ID
*ConnectionApi* | [**place_connection**](docs/ConnectionApi.md#place_connection) | **POST** /conection | Place an connection request from the SDX-Controller
*ConnectionApi* | [**delete_connection**](docs/ConnectionApi.md#delete_connection) | **DELETE** /connection/{connection_id} | Delete connection order by ID
*ConnectionApi* | [**getconnection_by_id**](docs/ConnectionApi.md#getconnection_by_id) | **GET** /connection/{connection_id} | Find connection by ID
*ConnectionApi* | [**getconnections**](docs/ConnectionApi.md#getconnections) | **GET** /connections | List all connections
*ConnectionApi* | [**place_connection**](docs/ConnectionApi.md#place_connection) | **POST** /connection | Place an connection request from the SDX-Controller
*LinkApi* | [**get_link**](docs/LinkApi.md#get_link) | **GET** /link | get an existing link
*NodeApi* | [**get_node**](docs/NodeApi.md#get_node) | **GET** /node | get an existing node
*TopologyApi* | [**get_topology**](docs/TopologyApi.md#get_topology) | **GET** /topology | get an existing topology
*TopologyApi* | [**get_topologyby_version**](docs/TopologyApi.md#get_topologyby_version) | **GET** /topology/{version} | Find topology by version
*TopologyApi* | [**get_topologyby_grenml**](docs/TopologyApi.md#get_topologyby_grenml) | **GET** /topology/grenml | Get topology grenml
*TopologyApi* | [**topology_version**](docs/TopologyApi.md#topology_version) | **GET** /topology/version | Finds topology version
*UserApi* | [**create_user**](docs/UserApi.md#create_user) | **POST** /user | Create user
*UserApi* | [**create_users_with_array_input**](docs/UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array
Expand All @@ -111,6 +122,13 @@ Class | Method | HTTP request | Description

- [ApiResponse](docs/ApiResponse.md)
- [Connection](docs/Connection.md)
- [ConnectionBody](docs/ConnectionBody.md)
- [ConnectionQosMetrics](docs/ConnectionQosMetrics.md)
- [ConnectionQosUnit](docs/ConnectionQosUnit.md)
- [ConnectionScheduling](docs/ConnectionScheduling.md)
- [ConnectionV2](docs/ConnectionV2.md)
- [ConnectionV2Endpoints](docs/ConnectionV2Endpoints.md)
- [ConnectionV2Notifications](docs/ConnectionV2Notifications.md)
- [Link](docs/Link.md)
- [Location](docs/Location.md)
- [Node](docs/Node.md)
Expand Down
63 changes: 54 additions & 9 deletions docs/ConnectionApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ All URIs are relative to *https://virtserver.swaggerhub.com/SDX-Controller/1.0.0

Method | HTTP request | Description
------------- | ------------- | -------------
[**delete_connection**](ConnectionApi.md#delete_connection) | **DELETE** /connection/{connectionId} | Delete connection order by ID
[**getconnection_by_id**](ConnectionApi.md#getconnection_by_id) | **GET** /connection/{connectionId} | Find connection by ID
[**place_connection**](ConnectionApi.md#place_connection) | **POST** /conection | Place an connection request from the SDX-Controller
[**delete_connection**](ConnectionApi.md#delete_connection) | **DELETE** /connection/{connection_id} | Delete connection order by ID
[**getconnection_by_id**](ConnectionApi.md#getconnection_by_id) | **GET** /connection/{connection_id} | Find connection by ID
[**getconnections**](ConnectionApi.md#getconnections) | **GET** /connections | List all connections
[**place_connection**](ConnectionApi.md#place_connection) | **POST** /connection | Place an connection request from the SDX-Controller

# **delete_connection**
> delete_connection(connection_id)
Expand All @@ -25,7 +26,7 @@ from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.ConnectionApi()
connection_id = 789 # int | ID of the connection that needs to be deleted
connection_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # str | ID of the connection that needs to be deleted

try:
# Delete connection order by ID
Expand All @@ -38,7 +39,7 @@ except ApiException as e:

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**connection_id** | **int**| ID of the connection that needs to be deleted |
**connection_id** | [**str**](.md)| ID of the connection that needs to be deleted |

### Return type

Expand Down Expand Up @@ -72,7 +73,7 @@ from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.ConnectionApi()
connection_id = 789 # int | ID of connection that needs to be fetched
connection_id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # str | ID of connection that needs to be fetched

try:
# Find connection by ID
Expand All @@ -86,7 +87,7 @@ except ApiException as e:

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**connection_id** | **int**| ID of connection that needs to be fetched |
**connection_id** | [**str**](.md)| ID of connection that needs to be fetched |

### Return type

Expand All @@ -103,6 +104,50 @@ No authorization required

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **getconnections**
> list[Connection] getconnections()

List all connections

connection details

### Example
```python
from __future__ import print_function
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.ConnectionApi()

try:
# List all connections
api_response = api_instance.getconnections()
pprint(api_response)
except ApiException as e:
print("Exception when calling ConnectionApi->getconnections: %s\n" % e)
```

### Parameters
This endpoint does not need any parameter.

### Return type

[**list[Connection]**](Connection.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json, application/xml

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **place_connection**
> Connection place_connection(body)

Expand All @@ -118,7 +163,7 @@ from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.ConnectionApi()
body = swagger_client.Connection() # Connection | order placed for creating a connection
body = swagger_client.ConnectionBody() # ConnectionBody | order placed for creating a connection

try:
# Place an connection request from the SDX-Controller
Expand All @@ -132,7 +177,7 @@ except ApiException as e:

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**body** | [**Connection**](Connection.md)| order placed for creating a connection |
**body** | [**ConnectionBody**](ConnectionBody.md)| order placed for creating a connection |

### Return type

Expand Down
8 changes: 8 additions & 0 deletions docs/ConnectionBody.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# ConnectionBody

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

17 changes: 17 additions & 0 deletions docs/ConnectionQosMetrics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# ConnectionQosMetrics

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**min_bw** | [**ConnectionQosUnit**](ConnectionQosUnit.md) | | [optional]
**max_delay** | [**ConnectionQosUnit**](ConnectionQosUnit.md) | | [optional]
**max_number_oxps** | [**ConnectionQosUnit**](ConnectionQosUnit.md) | | [optional]
**bandwidth_measured** | **float** | | [optional]
**latency_measured** | **float** | | [optional]
**packetloss_required** | **float** | | [optional]
**packetloss_measured** | **float** | | [optional]
**availability_required** | **float** | | [optional]
**availability_measured** | **float** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

10 changes: 10 additions & 0 deletions docs/ConnectionQosUnit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# ConnectionQosUnit

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**value** | **int** | | [optional]
**strict** | **bool** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

10 changes: 10 additions & 0 deletions docs/ConnectionScheduling.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# ConnectionScheduling

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**start_time** | **datetime** | | [optional]
**end_time** | **datetime** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

23 changes: 23 additions & 0 deletions docs/ConnectionV2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# ConnectionV2

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | |
**endpoints** | [**list[ConnectionV2Endpoints]**](ConnectionV2Endpoints.md) | |
**description** | **str** | |
**notifications** | [**list[ConnectionV2Notifications]**](ConnectionV2Notifications.md) | |
**scheduling** | [**ConnectionScheduling**](ConnectionScheduling.md) | |
**qos_metrics** | [**dict(str, ConnectionQosMetrics)**](ConnectionQosMetrics.md) | |
**paths** | **list[str]** | | [optional]
**status** | **str** | Connection Status | [optional]
**complete** | **bool** | | [optional] [default to False]
**quantity** | **int** | | [optional]
**multi_path** | **bool** | | [optional]
**preempt** | **bool** | | [optional]
**backup_path_type** | **str** | | [optional]
**exclusive_links** | [**list[Link]**](Link.md) | | [optional]
**inclusive_links** | [**list[Link]**](Link.md) | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

10 changes: 10 additions & 0 deletions docs/ConnectionV2Endpoints.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# ConnectionV2Endpoints

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**port_id** | **str** | | [optional]
**vlan** | **str** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

9 changes: 9 additions & 0 deletions docs/ConnectionV2Notifications.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# ConnectionV2Notifications

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**email** | **str** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

1 change: 1 addition & 0 deletions docs/Location.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Name | Type | Description | Notes
**address** | **str** | | [optional]
**latitude** | **float** | | [optional]
**longitude** | **float** | | [optional]
**iso3166_2_lvl4** | **str** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

2 changes: 1 addition & 1 deletion docs/Topology.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Name | Type | Description | Notes
**id** | **str** | |
**name** | **str** | |
**version** | **int** | |
**time_stamp** | **datetime** | |
**timestamp** | **datetime** | |
**nodes** | [**list[Node]**](Node.md) | |
**links** | [**list[Link]**](Link.md) | |

Expand Down
Loading
Loading