fwd-sdk 0.1.1
Forward Compute API
Requires Python: >=3.9
Keywords: OpenAPI, OpenAPI-Generator, Forward Compute API

# Forward Compute SDK
Forward Compute API for managing machines, contracts, and compute resources

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

- API version: 1.0.0
- Package version: 0.1.1
- Generator version: 7.18.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:

```sh
pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git
```
(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`)

Then import the package:
```python
import fwd_sdk
```

### 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 fwd_sdk
```

### Tests

Execute `pytest` to run the tests.

## Getting Started

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

```python

import fwd_sdk
from fwd_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://app.forwardcompute.ai
# See configuration.py for a list of all supported configuration parameters.
configuration = fwd_sdk.Configuration(
    host = "https://app.forwardcompute.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 Bearer authorization (JWT): bearerAuth
configuration = fwd_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)


# Enter a context with an instance of the API client
with fwd_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = fwd_sdk.AudioApi(api_client)
    create_speech_request = fwd_sdk.CreateSpeechRequest() # CreateSpeechRequest | 

    try:
        # Create speech from text
        api_response = api_instance.create_speech(create_speech_request)
        print("The response of AudioApi->create_speech:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling AudioApi->create_speech: %s\n" % e)

```

## Documentation for API Endpoints

All URIs are relative to *https://app.forwardcompute.ai*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*AudioApi* | [**create_speech**](docs/AudioApi.md#create_speech) | **POST** /v1/audio/speech | Create speech from text
*AudioApi* | [**create_transcription**](docs/AudioApi.md#create_transcription) | **POST** /v1/audio/transcriptions | Create transcription from audio
*AudioApi* | [**create_translation**](docs/AudioApi.md#create_translation) | **POST** /v1/audio/translations | Create translation from audio
*AudioApi* | [**list_voices**](docs/AudioApi.md#list_voices) | **GET** /v1/audio/voices | List available TTS voices
*ChatApi* | [**create_completion**](docs/ChatApi.md#create_completion) | **POST** /v1/chat/completions | Create chat completion
*ChatApi* | [**get_completion**](docs/ChatApi.md#get_completion) | **GET** /v1/chat/completions/{id} | Get inference metadata
*ChatApi* | [**list_completions**](docs/ChatApi.md#list_completions) | **GET** /v1/chat/completions | List inference history
*ComputeApi* | [**get_offering**](docs/ComputeApi.md#get_offering) | **GET** /v1/spot/compute/offerings/{id} | Get compute offering
*ComputeApi* | [**list_offerings**](docs/ComputeApi.md#list_offerings) | **GET** /v1/spot/compute/offerings | List compute offerings
*EmbeddingsApi* | [**create_embedding**](docs/EmbeddingsApi.md#create_embedding) | **POST** /v1/embeddings/ | Create embeddings
*ImagesApi* | [**create_image**](docs/ImagesApi.md#create_image) | **POST** /v1/images/generations | Generate images from a text prompt
*InstancesApi* | [**create_instance**](docs/InstancesApi.md#create_instance) | **POST** /v1/spot/instances/ | Create instance
*InstancesApi* | [**delete_instance**](docs/InstancesApi.md#delete_instance) | **DELETE** /v1/spot/instances/{id} | Delete instance
*InstancesApi* | [**get_instance**](docs/InstancesApi.md#get_instance) | **GET** /v1/spot/instances/{id} | Get instance
*InstancesApi* | [**list_instances**](docs/InstancesApi.md#list_instances) | **GET** /v1/spot/instances/ | List instances
*InstancesApi* | [**restart_instance**](docs/InstancesApi.md#restart_instance) | **POST** /v1/spot/instances/{id}/restart | Restart instance
*ModelsApi* | [**list_models**](docs/ModelsApi.md#list_models) | **GET** /v1/models/ | List models
*SSHKeysApi* | [**create_ssh_key**](docs/SSHKeysApi.md#create_ssh_key) | **POST** /v1/spot/ssh-keys/ | Create SSH key
*SSHKeysApi* | [**delete_ssh_key**](docs/SSHKeysApi.md#delete_ssh_key) | **DELETE** /v1/spot/ssh-keys/{id} | Delete SSH key
*SSHKeysApi* | [**list_ssh_keys**](docs/SSHKeysApi.md#list_ssh_keys) | **GET** /v1/spot/ssh-keys/ | List SSH keys
*SupportApi* | [**contact**](docs/SupportApi.md#contact) | **POST** /v1/support/ | Submit support request
*VolumesApi* | [**create_volume**](docs/VolumesApi.md#create_volume) | **POST** /v1/spot/volumes/ | Create volume
*VolumesApi* | [**delete_volume**](docs/VolumesApi.md#delete_volume) | **DELETE** /v1/spot/volumes/{id} | Delete volume
*VolumesApi* | [**get_volume**](docs/VolumesApi.md#get_volume) | **GET** /v1/spot/volumes/{id} | Get volume
*VolumesApi* | [**get_volume_offering**](docs/VolumesApi.md#get_volume_offering) | **GET** /v1/spot/volumes/offerings/{id} | Get volume offering
*VolumesApi* | [**list_volume_offerings**](docs/VolumesApi.md#list_volume_offerings) | **GET** /v1/spot/volumes/offerings | List volume offerings
*VolumesApi* | [**list_volumes**](docs/VolumesApi.md#list_volumes) | **GET** /v1/spot/volumes/ | List volumes


## Documentation For Models

 - [Contact400Response](docs/Contact400Response.md)
 - [Contact400ResponseError](docs/Contact400ResponseError.md)
 - [ContactRequest](docs/ContactRequest.md)
 - [CreateCompletion200Response](docs/CreateCompletion200Response.md)
 - [CreateCompletion200ResponseChoicesInner](docs/CreateCompletion200ResponseChoicesInner.md)
 - [CreateCompletion200ResponseUsage](docs/CreateCompletion200ResponseUsage.md)
 - [CreateCompletionRequest](docs/CreateCompletionRequest.md)
 - [CreateCompletionRequestMessagesInner](docs/CreateCompletionRequestMessagesInner.md)
 - [CreateCompletionRequestMessagesInnerToolCallsInner](docs/CreateCompletionRequestMessagesInnerToolCallsInner.md)
 - [CreateCompletionRequestMessagesInnerToolCallsInnerFunction](docs/CreateCompletionRequestMessagesInnerToolCallsInnerFunction.md)
 - [CreateCompletionRequestToolsInner](docs/CreateCompletionRequestToolsInner.md)
 - [CreateCompletionRequestToolsInnerFunction](docs/CreateCompletionRequestToolsInnerFunction.md)
 - [CreateEmbedding200Response](docs/CreateEmbedding200Response.md)
 - [CreateEmbedding200ResponseDataInner](docs/CreateEmbedding200ResponseDataInner.md)
 - [CreateEmbedding200ResponseDataInnerEmbedding](docs/CreateEmbedding200ResponseDataInnerEmbedding.md)
 - [CreateEmbedding200ResponseUsage](docs/CreateEmbedding200ResponseUsage.md)
 - [CreateEmbeddingRequest](docs/CreateEmbeddingRequest.md)
 - [CreateEmbeddingRequestInput](docs/CreateEmbeddingRequestInput.md)
 - [CreateImage200Response](docs/CreateImage200Response.md)
 - [CreateImage200ResponseDataInner](docs/CreateImage200ResponseDataInner.md)
 - [CreateImageRequest](docs/CreateImageRequest.md)
 - [CreateInstance200Response](docs/CreateInstance200Response.md)
 - [CreateInstanceRequest](docs/CreateInstanceRequest.md)
 - [CreateSpeech400Response](docs/CreateSpeech400Response.md)
 - [CreateSpeech400ResponseError](docs/CreateSpeech400ResponseError.md)
 - [CreateSpeech402Response](docs/CreateSpeech402Response.md)
 - [CreateSpeech402ResponseError](docs/CreateSpeech402ResponseError.md)
 - [CreateSpeechRequest](docs/CreateSpeechRequest.md)
 - [CreateSshKeyRequest](docs/CreateSshKeyRequest.md)
 - [CreateTranscription200Response](docs/CreateTranscription200Response.md)
 - [CreateTranscription200ResponseSegmentsInner](docs/CreateTranscription200ResponseSegmentsInner.md)
 - [CreateTranscriptionRequest](docs/CreateTranscriptionRequest.md)
 - [CreateTranslationRequest](docs/CreateTranslationRequest.md)
 - [CreateVolumeRequest](docs/CreateVolumeRequest.md)
 - [DeleteInstance200Response](docs/DeleteInstance200Response.md)
 - [DeleteSshKey200Response](docs/DeleteSshKey200Response.md)
 - [DeleteVolume200Response](docs/DeleteVolume200Response.md)
 - [GetOffering200Response](docs/GetOffering200Response.md)
 - [GetVolumeOffering200Response](docs/GetVolumeOffering200Response.md)
 - [ListCompletions200Response](docs/ListCompletions200Response.md)
 - [ListCompletions200ResponseItemsInner](docs/ListCompletions200ResponseItemsInner.md)
 - [ListInstances200Response](docs/ListInstances200Response.md)
 - [ListInstances200ResponseDataInner](docs/ListInstances200ResponseDataInner.md)
 - [ListInstances200ResponseDataInnerEnvsInner](docs/ListInstances200ResponseDataInnerEnvsInner.md)
 - [ListModels200Response](docs/ListModels200Response.md)
 - [ListModels200ResponseModelsInner](docs/ListModels200ResponseModelsInner.md)
 - [ListModels200ResponseModelsInnerPricing](docs/ListModels200ResponseModelsInnerPricing.md)
 - [ListModels200ResponseModelsInnerPricingOneOf](docs/ListModels200ResponseModelsInnerPricingOneOf.md)
 - [ListModels200ResponseModelsInnerPricingOneOf1](docs/ListModels200ResponseModelsInnerPricingOneOf1.md)
 - [ListModels200ResponseModelsInnerPricingOneOf2](docs/ListModels200ResponseModelsInnerPricingOneOf2.md)
 - [ListModels200ResponseModelsInnerPricingOneOf3](docs/ListModels200ResponseModelsInnerPricingOneOf3.md)
 - [ListModels200ResponseModelsInnerPricingOneOf4](docs/ListModels200ResponseModelsInnerPricingOneOf4.md)
 - [ListModels200ResponseModelsInnerPricingOneOf5](docs/ListModels200ResponseModelsInnerPricingOneOf5.md)
 - [ListOfferings200Response](docs/ListOfferings200Response.md)
 - [ListOfferings200ResponseDataInner](docs/ListOfferings200ResponseDataInner.md)
 - [ListOfferings200ResponseDataInnerBootTime](docs/ListOfferings200ResponseDataInnerBootTime.md)
 - [ListOfferings200ResponseDataInnerConfiguration](docs/ListOfferings200ResponseDataInnerConfiguration.md)
 - [ListSshKeys200Response](docs/ListSshKeys200Response.md)
 - [ListSshKeys200ResponseDataInner](docs/ListSshKeys200ResponseDataInner.md)
 - [ListVoices200Response](docs/ListVoices200Response.md)
 - [ListVoices200ResponseVoicesInner](docs/ListVoices200ResponseVoicesInner.md)
 - [ListVolumeOfferings200Response](docs/ListVolumeOfferings200Response.md)
 - [ListVolumeOfferings200ResponseDataInner](docs/ListVolumeOfferings200ResponseDataInner.md)
 - [ListVolumes200Response](docs/ListVolumes200Response.md)
 - [ListVolumes200ResponseDataInner](docs/ListVolumes200ResponseDataInner.md)


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


Authentication schemes defined for the API:
<a id="bearerAuth"></a>
### bearerAuth

- **Type**: Bearer authentication (JWT)


## Author