Metadata-Version: 2.4
Name: ha-sdk-python
Version: 1.0.10
Summary: Python SDK for the HostAfrica API
Author-email: HostAfrica <support@hostafrica.com>
Project-URL: Repository, https://github.com/hostafrica/ha-sdk-python
Keywords: hostafrica,vps,cloud,sdk,api
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: urllib3<3.0.0,>=2.1.0
Requires-Dist: python-dateutil>=2.8.2
Requires-Dist: pydantic<3,>=2
Requires-Dist: typing-extensions>=4.7.1
Provides-Extra: dev
Requires-Dist: pytest>=7.2.1; extra == "dev"
Requires-Dist: pytest-cov>=2.8.1; extra == "dev"
Requires-Dist: tox>=3.9.0; extra == "dev"
Requires-Dist: flake8>=4.0.0; extra == "dev"
Requires-Dist: types-python-dateutil>=2.8.19.14; extra == "dev"
Requires-Dist: mypy>=1.5; extra == "dev"
Dynamic: license-file

# ha-sdk-python

A Python SDK client for the api.hostafrica.com API.

This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

## Requirements.

Python 3.9+

## Installation & Usage
### pip install

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

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

Then import the package:
```python
import ha_sdk_python
```

### Setuptools

Install via [Setuptools](http://pypi.python.org/pypi/setuptools).

```sh
python setup.py install --user
```
(or `sudo python setup.py install` to install the package for all users)

Then import the package:
```python
import ha_sdk_python
```

### Tests

Execute `pytest` to run the tests.

## Getting Started

Please follow the [installation procedure](#installation--usage) and then run the following:

```python

import ha_sdk_python
from ha_sdk_python.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.hostafrica.com
# See configuration.py for a list of all supported configuration parameters.
configuration = ha_sdk_python.Configuration(
    host = "https://api.hostafrica.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: BearerAuth
configuration = ha_sdk_python.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)


# Enter a context with an instance of the API client
with ha_sdk_python.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = ha_sdk_python.BackupsApi(api_client)
    create_backup_request_content = ha_sdk_python.CreateBackupRequestContent() # CreateBackupRequestContent | 

    try:
        api_response = api_instance.create_backup(create_backup_request_content)
        print("The response of BackupsApi->create_backup:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling BackupsApi->create_backup: %s\n" % e)

```

## Documentation

[**API Reference Documentation**](https://api.hostafrica.com)

[**Documentation per api/operation**](docs/)


<a id="documentation-for-authorization"></a>
## Documentation For Authorization


Authentication schemes defined for the API:

<a id="BearerAuth"></a>
### BearerAuth

- **Type**: Bearer authentication






