Metadata-Version: 2.1
Name: bacalhau_apiclient
Version: 1.1.0.dev0
Summary: A Python client for the Bacalhau public API - https://github.com/bacalhau-project/bacalhau/tree/main/clients/python
Project-URL: Homepage, https://github.com/bacalhau-project/bacalhau/
Project-URL: Bug Tracker, https://github.com/bacalhau-project/bacalhau/issues
Author-email: Enrico Rotundo <enrico.rotundo@gmail.com>
License-File: LICENSE
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.6.2
Description-Content-Type: text/markdown

# bacalhau_apiclient
This page is the reference of the Bacalhau REST API. Project docs are available at https://docs.bacalhau.org/. Find more information about Bacalhau at https://github.com/bacalhau-project/bacalhau.

This Python package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:

- API version: ${PYPI_VERSION}
- Package version: 1.1.0.dev0
- Build package: io.swagger.codegen.v3.generators.python.PythonClientCodegen
For more information, please visit [https://github.com/bacalhau-project/bacalhau](https://github.com/bacalhau-project/bacalhau)

## Requirements.

Python 3.6+

## Installation & Usage
### pip install

If the python package is hosted on Github, you can install directly from Github

```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 bacalhau_apiclient 
```

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

## Getting Started

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

```python
from __future__ import print_function
import time
import bacalhau_apiclient
from bacalhau_apiclient.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = bacalhau_apiclient.HealthApi(bacalhau_apiclient.ApiClient(configuration))

try:
    # Returns debug information on what the current node is doing.
    api_response = api_instance.api_serverdebug()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling HealthApi->api_serverdebug: %s\n" % e)

# create an instance of the API class
api_instance = bacalhau_apiclient.HealthApi(bacalhau_apiclient.ApiClient(configuration))

try:
    # Returns debug information on what the current node is doing.
    api_response = api_instance.debug()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling HealthApi->debug: %s\n" % e)
```

## Documentation for API Endpoints

All URIs are relative to *http://bootstrap.production.bacalhau.org:1234/*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*HealthApi* | [**api_serverdebug**](docs/HealthApi.md#api_serverdebug) | **GET** /api/v1/compute/debug | Returns debug information on what the current node is doing.
*HealthApi* | [**debug**](docs/HealthApi.md#debug) | **GET** /api/v1/requester/debug | Returns debug information on what the current node is doing.
*JobApi* | [**cancel**](docs/JobApi.md#cancel) | **POST** /api/v1/requester/cancel | Cancels the job with the job-id specified in the body payload.
*JobApi* | [**events**](docs/JobApi.md#events) | **POST** /api/v1/requester/events | Returns the events related to the job-id passed in the body payload. Useful for troubleshooting.
*JobApi* | [**list**](docs/JobApi.md#list) | **POST** /api/v1/requester/list | Simply lists jobs.
*JobApi* | [**logs**](docs/JobApi.md#logs) | **POST** /api/v1/requester/logs | Displays the logs for a current job/execution
*JobApi* | [**results**](docs/JobApi.md#results) | **POST** /api/v1/requester/results | Returns the results of the job-id specified in the body payload.
*JobApi* | [**states**](docs/JobApi.md#states) | **POST** /api/v1/requester/states | Returns the state of the job-id specified in the body payload.
*JobApi* | [**submit**](docs/JobApi.md#submit) | **POST** /api/v1/requester/submit | Submits a new job to the network.
*MiscApi* | [**api_serverversion**](docs/MiscApi.md#api_serverversion) | **POST** /api/v1/version | Returns the build version running on the server.
*OpsApi* | [**agentalive**](docs/OpsApi.md#agentalive) | **GET** /api/v1/agent/alive | 
*OpsApi* | [**agentnode**](docs/OpsApi.md#agentnode) | **GET** /api/v1/agent/node | Returns the info of the node.
*OpsApi* | [**agentversion**](docs/OpsApi.md#agentversion) | **GET** /api/v1/agent/version | Returns the build version running on the server.
*UtilsApi* | [**healthz**](docs/UtilsApi.md#healthz) | **GET** /api/v1/healthz | 
*UtilsApi* | [**id**](docs/UtilsApi.md#id) | **GET** /api/v1/id | Returns the id of the host node.
*UtilsApi* | [**livez**](docs/UtilsApi.md#livez) | **GET** /api/v1/livez | 
*UtilsApi* | [**node_info**](docs/UtilsApi.md#node_info) | **GET** /api/v1/node_info | Returns the info of the node.
*UtilsApi* | [**peers**](docs/UtilsApi.md#peers) | **GET** /api/v1/peers | Returns the peers connected to the host via the transport layer.
*DefaultApi* | [**api_serverapprover**](docs/DefaultApi.md#api_serverapprover) | **GET** /api/v1/compute/approve | Approves a job to be run on this compute node.
*DefaultApi* | [**nodes**](docs/DefaultApi.md#nodes) | **GET** /api/v1/requester/nodes | Displays the nodes that this requester knows about

## Documentation For Models

 - [AllOfExecutionStateDesiredState](docs/AllOfExecutionStateDesiredState.md)
 - [AllOfExecutionStatePublishedResults](docs/AllOfExecutionStatePublishedResults.md)
 - [AllOfExecutionStateRunOutput](docs/AllOfExecutionStateRunOutput.md)
 - [AllOfExecutionStateState](docs/AllOfExecutionStateState.md)
 - [AllOfJobCreatePayloadSpec](docs/AllOfJobCreatePayloadSpec.md)
 - [AllOfJobMetadata](docs/AllOfJobMetadata.md)
 - [AllOfJobSpec](docs/AllOfJobSpec.md)
 - [AllOfJobSpecWasmEntryModule](docs/AllOfJobSpecWasmEntryModule.md)
 - [AllOfJobStateState](docs/AllOfJobStateState.md)
 - [AllOfJobWithInfoJob](docs/AllOfJobWithInfoJob.md)
 - [AllOfJobWithInfoState](docs/AllOfJobWithInfoState.md)
 - [AllOfLabelSelectorRequirementOperator](docs/AllOfLabelSelectorRequirementOperator.md)
 - [AllOfSpecDeal](docs/AllOfSpecDeal.md)
 - [AllOfSpecDocker](docs/AllOfSpecDocker.md)
 - [AllOfSpecEngine](docs/AllOfSpecEngine.md)
 - [AllOfSpecNetwork](docs/AllOfSpecNetwork.md)
 - [AllOfSpecPublisher](docs/AllOfSpecPublisher.md)
 - [AllOfSpecResources](docs/AllOfSpecResources.md)
 - [AllOfSpecWasm](docs/AllOfSpecWasm.md)
 - [AllOfStorageSpecStorageSource](docs/AllOfStorageSpecStorageSource.md)
 - [AllOflegacyCancelRequestPayload](docs/AllOflegacyCancelRequestPayload.md)
 - [AllOflegacyEventsRequestFilters](docs/AllOflegacyEventsRequestFilters.md)
 - [AllOflegacyLogRequestPayload](docs/AllOflegacyLogRequestPayload.md)
 - [AllOflegacySubmitRequestPayload](docs/AllOflegacySubmitRequestPayload.md)
 - [ApiGetVersionResponse](docs/ApiGetVersionResponse.md)
 - [BuildVersionInfo](docs/BuildVersionInfo.md)
 - [ComputeNodeInfo](docs/ComputeNodeInfo.md)
 - [Deal](docs/Deal.md)
 - [Engine](docs/Engine.md)
 - [EngineSpec](docs/EngineSpec.md)
 - [ExecutionDesiredState](docs/ExecutionDesiredState.md)
 - [ExecutionState](docs/ExecutionState.md)
 - [ExecutionStateType](docs/ExecutionStateType.md)
 - [FreeSpace](docs/FreeSpace.md)
 - [HealthInfo](docs/HealthInfo.md)
 - [Job](docs/Job.md)
 - [JobCancelPayload](docs/JobCancelPayload.md)
 - [JobCreatePayload](docs/JobCreatePayload.md)
 - [JobHistory](docs/JobHistory.md)
 - [JobHistoryType](docs/JobHistoryType.md)
 - [JobRequester](docs/JobRequester.md)
 - [JobSpecDocker](docs/JobSpecDocker.md)
 - [JobSpecWasm](docs/JobSpecWasm.md)
 - [JobState](docs/JobState.md)
 - [JobStateType](docs/JobStateType.md)
 - [JobWithInfo](docs/JobWithInfo.md)
 - [LabelSelectorRequirement](docs/LabelSelectorRequirement.md)
 - [LegacyCancelRequest](docs/LegacyCancelRequest.md)
 - [LegacyCancelResponse](docs/LegacyCancelResponse.md)
 - [LegacyEventFilterOptions](docs/LegacyEventFilterOptions.md)
 - [LegacyEventsRequest](docs/LegacyEventsRequest.md)
 - [LegacyEventsResponse](docs/LegacyEventsResponse.md)
 - [LegacyListRequest](docs/LegacyListRequest.md)
 - [LegacyListResponse](docs/LegacyListResponse.md)
 - [LegacyLogRequest](docs/LegacyLogRequest.md)
 - [LegacyResultsResponse](docs/LegacyResultsResponse.md)
 - [LegacyStateRequest](docs/LegacyStateRequest.md)
 - [LegacyStateResponse](docs/LegacyStateResponse.md)
 - [LegacySubmitRequest](docs/LegacySubmitRequest.md)
 - [LegacySubmitResponse](docs/LegacySubmitResponse.md)
 - [LegacyVersionRequest](docs/LegacyVersionRequest.md)
 - [LegacyVersionResponse](docs/LegacyVersionResponse.md)
 - [LogsPayload](docs/LogsPayload.md)
 - [Metadata](docs/Metadata.md)
 - [MountStatus](docs/MountStatus.md)
 - [Network](docs/Network.md)
 - [NetworkConfig](docs/NetworkConfig.md)
 - [NodeInfo](docs/NodeInfo.md)
 - [NodeType](docs/NodeType.md)
 - [PeerAddrInfo](docs/PeerAddrInfo.md)
 - [PublishedResult](docs/PublishedResult.md)
 - [Publisher](docs/Publisher.md)
 - [PublisherSpec](docs/PublisherSpec.md)
 - [ResourceUsageConfig](docs/ResourceUsageConfig.md)
 - [Resources](docs/Resources.md)
 - [RunCommandResult](docs/RunCommandResult.md)
 - [S3StorageSpec](docs/S3StorageSpec.md)
 - [SelectionOperator](docs/SelectionOperator.md)
 - [Spec](docs/Spec.md)
 - [StateChangeExecutionStateType](docs/StateChangeExecutionStateType.md)
 - [StateChangeJobStateType](docs/StateChangeJobStateType.md)
 - [StorageSourceType](docs/StorageSourceType.md)
 - [StorageSpec](docs/StorageSpec.md)

## Documentation For Authorization

 All endpoints do not require authorization.


## Author

team@bacalhau.org
