Skip to content

ionos-cloud/sdk-python-object-storage-management

Repository files navigation

ionoscloud-object-storage-management

Object Storage Management API is a RESTful API that manages the object storage service configuration for IONOS Cloud.

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

  • API version: 0.1.0
  • Package version: 2.0.0
  • Generator version: 7.13.0-SNAPSHOT
  • Build package: org.openapitools.codegen.languages.PythonClientCodegen

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_object_storage_management

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_object_storage_management

Tests

Execute pytest to run the tests.

Getting Started

Please follow the installation procedure and then run the following:

import ionoscloud_object_storage_management
from ionoscloud_object_storage_management.rest import ApiException
from pprint import pprint
import os

# Defining the host is optional and defaults to https://s3.ionos.com
# See configuration.py for a list of all supported configuration parameters.
configuration = ionoscloud_object_storage_management.Configuration(
    host = "https://s3.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_object_storage_management.Configuration(
    token = os.environ["IONOS_TOKEN"]
)


# Enter a context with an instance of the API client
with ionoscloud_object_storage_management.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = ionoscloud_object_storage_management.AccesskeysApi(api_client)
    accesskey_id = 'fb68d39a-5706-51b4-b2b2-7b4bf9cbf0af' # str | The ID (UUID) of the AccessKey.

    try:
        # Delete AccessKey
        api_instance.accesskeys_delete(accesskey_id)
    except ApiException as e:
        print("Exception when calling AccesskeysApi->accesskeys_delete: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://s3.ionos.com

Class Method HTTP request Description
AccesskeysApi accesskeys_delete DELETE /accesskeys/{accesskeyId} Delete AccessKey
AccesskeysApi accesskeys_find_by_id GET /accesskeys/{accesskeyId} Retrieve AccessKey
AccesskeysApi accesskeys_get GET /accesskeys Retrieve all Accesskeys
AccesskeysApi accesskeys_post POST /accesskeys Create AccessKey
AccesskeysApi accesskeys_put PUT /accesskeys/{accesskeyId} Ensure AccessKey
AccesskeysApi accesskeys_renew PUT /accesskeys/{accesskeyId}/renew Ensure AccessKey
RegionsApi regions_find_by_region GET /regions/{region} Retrieve Region
RegionsApi regions_get GET /regions Retrieve all Regions

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

tokenAuth

  • Type: Bearer authentication (JWT)

Author

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors