Thanks to visit codestin.com
Credit goes to github.com

Skip to content

deep-image-ai/python-client

Repository files navigation

deep-image-ai-client

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

  • API version: 1
  • Package version: 1.0.0
  • Generator version: 7.4.0
  • Build package: org.openapitools.codegen.languages.PythonClientCodegen

Requirements.

Python 3.7+

Installation & Usage

pip install

You can install the package using:

pip install git+https://github.com/deep-image-ai/python-client.git

(you may need to run pip with root permission: sudo pip install git+https://github.com/deep-image-ai/python-client.git)

Then import the package:

import deep_image_ai_client

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 deep_image_ai_client

Getting Started

Please follow the installation procedure and then run the following:

import deep_image_ai_client
from deep_image_ai_client.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://deep-image.ai
# See configuration.py for a list of all supported configuration parameters.
configuration = deep_image_ai_client.Configuration(
    host = "https://deep-image.ai"
)

# 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 API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'


# Enter a context with an instance of the API client
with deep_image_ai_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = deep_image_ai_client.DefaultApi(api_client)
    process_payload = {"url":"https://deep-image.ai/api-example2.jpg","width":"200%","height":"200%"} # ProcessPayload | 

    try:
        # Schedules a job to perform selected enhancement options.
        api_response = api_instance.rest_api_process_post(process_payload)
        print("The response of DefaultApi->rest_api_process_post:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling DefaultApi->rest_api_process_post: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://deep-image.ai

Class Method HTTP request Description
DefaultApi rest_api_process_post POST /rest_api/process Schedules a job to perform selected enhancement options.
DefaultApi rest_api_process_result_post POST /rest_api/process_result Schedules a job to perform selected enhancement options and waits for the result.
DefaultApi rest_api_result_hash_get GET /rest_api/result/{hash} Returns processing job result.

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

ApiKeyAuth

  • Type: API key
  • API key parameter name: X-API-KEY
  • Location: HTTP header

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages