Skip to content

ionos-cloud/sdk-python-vpn

Repository files navigation

ionoscloud-vpn

The Managed VPN Gateway service provides secure and scalable connectivity, enabling encrypted communication between your IONOS cloud resources in a VDC and remote networks (on-premises, multi-cloud, private LANs in other VDCs etc).

This Python package is automatically generated by the OpenAPI Generator project:

Requirements.

Python 3.9+

Installation & Usage

pip install

If the python package is hosted on a repository, you can install directly using:

pip install git+https://github.com/ionos-cloud/sdk-python.git

(you may need to run pip with root permission: sudo pip install git+https://github.com/ionos-cloud/sdk-python.git)

Then import the package:

import ionoscloud_vpn

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import ionoscloud_vpn

Tests

Execute pytest to run the tests.

Getting Started

Please follow the installation procedure and then run the following:

import ionoscloud_vpn
from ionoscloud_vpn.rest import ApiException
from pprint import pprint
import os

# Defining the host is optional and defaults to https://vpn.de-fra.ionos.com
# See configuration.py for a list of all supported configuration parameters.
configuration = ionoscloud_vpn.Configuration(
    host = "https://vpn.de-fra.ionos.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization (JWT): tokenAuth
configuration = ionoscloud_vpn.Configuration(
    token = os.environ["IONOS_TOKEN"]
)


# Enter a context with an instance of the API client
with ionoscloud_vpn.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = ionoscloud_vpn.IPSecGatewaysApi(api_client)
    gateway_id = '66a114c7-2ddd-5119-9ddf-5a789f5a5a44' # str | The ID (UUID) of the IPSecGateway.

    try:
        # Delete IPSecGateway
        api_instance.ipsecgateways_delete(gateway_id)
    except ApiException as e:
        print("Exception when calling IPSecGatewaysApi->ipsecgateways_delete: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://vpn.de-fra.ionos.com

Class Method HTTP request Description
IPSecGatewaysApi ipsecgateways_delete DELETE /ipsecgateways/{gatewayId} Delete IPSecGateway
IPSecGatewaysApi ipsecgateways_find_by_id GET /ipsecgateways/{gatewayId} Retrieve IPSecGateway
IPSecGatewaysApi ipsecgateways_get GET /ipsecgateways Retrieve all IPSecGateways
IPSecGatewaysApi ipsecgateways_post POST /ipsecgateways Create IPSecGateway
IPSecGatewaysApi ipsecgateways_put PUT /ipsecgateways/{gatewayId} Ensure IPSecGateway
IPSecTunnelsApi ipsecgateways_tunnels_delete DELETE /ipsecgateways/{gatewayId}/tunnels/{tunnelId} Delete IPSecTunnel
IPSecTunnelsApi ipsecgateways_tunnels_find_by_id GET /ipsecgateways/{gatewayId}/tunnels/{tunnelId} Retrieve IPSecTunnel
IPSecTunnelsApi ipsecgateways_tunnels_get GET /ipsecgateways/{gatewayId}/tunnels Retrieve all IPSecTunnels
IPSecTunnelsApi ipsecgateways_tunnels_post POST /ipsecgateways/{gatewayId}/tunnels Create IPSecTunnel
IPSecTunnelsApi ipsecgateways_tunnels_put PUT /ipsecgateways/{gatewayId}/tunnels/{tunnelId} Ensure IPSecTunnel
WireguardGatewaysApi wireguardgateways_delete DELETE /wireguardgateways/{gatewayId} Delete WireguardGateway
WireguardGatewaysApi wireguardgateways_find_by_id GET /wireguardgateways/{gatewayId} Retrieve WireguardGateway
WireguardGatewaysApi wireguardgateways_get GET /wireguardgateways Retrieve all WireguardGateways
WireguardGatewaysApi wireguardgateways_post POST /wireguardgateways Create WireguardGateway
WireguardGatewaysApi wireguardgateways_put PUT /wireguardgateways/{gatewayId} Ensure WireguardGateway
WireguardPeersApi wireguardgateways_peers_delete DELETE /wireguardgateways/{gatewayId}/peers/{peerId} Delete WireguardPeer
WireguardPeersApi wireguardgateways_peers_find_by_id GET /wireguardgateways/{gatewayId}/peers/{peerId} Retrieve WireguardPeer
WireguardPeersApi wireguardgateways_peers_get GET /wireguardgateways/{gatewayId}/peers Retrieve all WireguardPeers
WireguardPeersApi wireguardgateways_peers_post POST /wireguardgateways/{gatewayId}/peers Create WireguardPeer
WireguardPeersApi wireguardgateways_peers_put PUT /wireguardgateways/{gatewayId}/peers/{peerId} Ensure WireguardPeer

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

tokenAuth

  • Type: Bearer authentication (JWT)

Author

support@cloud.ionos.com

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •