# billingo
This is a Billingo API v3 documentation. Our API based on REST software architectural style. API has resource-oriented URLs, accepts JSON-encoded request bodies and returns JSON-encoded responses. To use this API you have to generate a new API key on our [site](https://app.billingo.hu/api-key). After that, you can test your API key on this page.

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

- API version: 3.0.14
- Package version: 1.0.0
- Build package: io.swagger.codegen.v3.generators.python.PythonClientCodegen
For more information, please visit [https://www.billingo.hu/kapcsolat](https://www.billingo.hu/kapcsolat)

## Requirements.

Python 2.7 and 3.4+

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

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

## Getting Started

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

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

# Configure API key authorization: api_key
configuration = billingo.Configuration()
configuration.api_key['X-API-KEY'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-API-KEY'] = 'Bearer'

# create an instance of the API class
api_instance = billingo.BankAccountApi(billingo.ApiClient(configuration))
body = billingo.BankAccount() # BankAccount | BankAccount object that you would like to store.

try:
    # Create a bank account
    api_response = api_instance.create_bank_account(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BankAccountApi->create_bank_account: %s\n" % e)

# Configure API key authorization: api_key
configuration = billingo.Configuration()
configuration.api_key['X-API-KEY'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-API-KEY'] = 'Bearer'

# create an instance of the API class
api_instance = billingo.BankAccountApi(billingo.ApiClient(configuration))
id = 56 # int | 

try:
    # Delete a bank account
    api_instance.delete_bank_account(id)
except ApiException as e:
    print("Exception when calling BankAccountApi->delete_bank_account: %s\n" % e)

# Configure API key authorization: api_key
configuration = billingo.Configuration()
configuration.api_key['X-API-KEY'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-API-KEY'] = 'Bearer'

# create an instance of the API class
api_instance = billingo.BankAccountApi(billingo.ApiClient(configuration))
id = 56 # int | 

try:
    # Retrieve a bank account
    api_response = api_instance.get_bank_account(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BankAccountApi->get_bank_account: %s\n" % e)

# Configure API key authorization: api_key
configuration = billingo.Configuration()
configuration.api_key['X-API-KEY'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-API-KEY'] = 'Bearer'

# create an instance of the API class
api_instance = billingo.BankAccountApi(billingo.ApiClient(configuration))
page = 56 # int |  (optional)
per_page = 25 # int |  (optional) (default to 25)

try:
    # List all bank account
    api_response = api_instance.list_bank_account(page=page, per_page=per_page)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BankAccountApi->list_bank_account: %s\n" % e)

# Configure API key authorization: api_key
configuration = billingo.Configuration()
configuration.api_key['X-API-KEY'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['X-API-KEY'] = 'Bearer'

# create an instance of the API class
api_instance = billingo.BankAccountApi(billingo.ApiClient(configuration))
body = billingo.BankAccount() # BankAccount | Bank account object that you would like to update.
id = 56 # int | 

try:
    # Update a bank account
    api_response = api_instance.update_bank_account(body, id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BankAccountApi->update_bank_account: %s\n" % e)
```

## Documentation for API Endpoints

All URIs are relative to *https://api.billingo.hu/v3*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*BankAccountApi* | [**create_bank_account**](docs/BankAccountApi.md#create_bank_account) | **POST** /bank-accounts | Create a bank account
*BankAccountApi* | [**delete_bank_account**](docs/BankAccountApi.md#delete_bank_account) | **DELETE** /bank-accounts/{id} | Delete a bank account
*BankAccountApi* | [**get_bank_account**](docs/BankAccountApi.md#get_bank_account) | **GET** /bank-accounts/{id} | Retrieve a bank account
*BankAccountApi* | [**list_bank_account**](docs/BankAccountApi.md#list_bank_account) | **GET** /bank-accounts | List all bank account
*BankAccountApi* | [**update_bank_account**](docs/BankAccountApi.md#update_bank_account) | **PUT** /bank-accounts/{id} | Update a bank account
*CurrencyApi* | [**get_conversion_rate**](docs/CurrencyApi.md#get_conversion_rate) | **GET** /currencies | Get currencies exchange rate.
*DocumentApi* | [**archive_document**](docs/DocumentApi.md#archive_document) | **PUT** /documents/{id}/archive | Archive a proforma document.
*DocumentApi* | [**cancel_document**](docs/DocumentApi.md#cancel_document) | **POST** /documents/{id}/cancel | Cancel a document
*DocumentApi* | [**create_document**](docs/DocumentApi.md#create_document) | **POST** /documents | Create a document
*DocumentApi* | [**create_document_from_draft**](docs/DocumentApi.md#create_document_from_draft) | **PUT** /documents/{id} | Converts a draft to an invoice.
*DocumentApi* | [**create_document_from_proforma**](docs/DocumentApi.md#create_document_from_proforma) | **POST** /documents/{id}/create-from-proforma | Create a document from proforma.
*DocumentApi* | [**create_modification_document**](docs/DocumentApi.md#create_modification_document) | **POST** /documents/{id}/create-modification-document | Create a modification document.
*DocumentApi* | [**create_receipt**](docs/DocumentApi.md#create_receipt) | **POST** /documents/receipt | Create a receipt
*DocumentApi* | [**create_receipt_from_draft**](docs/DocumentApi.md#create_receipt_from_draft) | **PUT** /documents/receipt/{id} | Converts a draft to a receipt.
*DocumentApi* | [**delete_document**](docs/DocumentApi.md#delete_document) | **DELETE** /documents/{id} | Delete a draft.
*DocumentApi* | [**delete_payment**](docs/DocumentApi.md#delete_payment) | **DELETE** /documents/{id}/payments | Delete all payment history on document
*DocumentApi* | [**document_copy**](docs/DocumentApi.md#document_copy) | **POST** /documents/{id}/copy | Copy a document
*DocumentApi* | [**download_document**](docs/DocumentApi.md#download_document) | **GET** /documents/{id}/download | Download a document in PDF format.
*DocumentApi* | [**get_document**](docs/DocumentApi.md#get_document) | **GET** /documents/{id} | Retrieve a document
*DocumentApi* | [**get_document_by_vendor_id**](docs/DocumentApi.md#get_document_by_vendor_id) | **GET** /documents/vendor/{vendor_id} | Retrieve a document by vendor id
*DocumentApi* | [**get_online_szamla_status**](docs/DocumentApi.md#get_online_szamla_status) | **GET** /documents/{id}/online-szamla | Retrieve a document Online Számla status
*DocumentApi* | [**get_payment**](docs/DocumentApi.md#get_payment) | **GET** /documents/{id}/payments | Retrieve a payment histroy
*DocumentApi* | [**get_public_url**](docs/DocumentApi.md#get_public_url) | **GET** /documents/{id}/public-url | Retrieve a document download public url.
*DocumentApi* | [**list_document**](docs/DocumentApi.md#list_document) | **GET** /documents | List all documents
*DocumentApi* | [**pos_print**](docs/DocumentApi.md#pos_print) | **GET** /documents/{id}/print/pos | Returns a printable POS PDF
*DocumentApi* | [**send_document**](docs/DocumentApi.md#send_document) | **POST** /documents/{id}/send | Send invoice to given email adresses.
*DocumentApi* | [**update_payment**](docs/DocumentApi.md#update_payment) | **PUT** /documents/{id}/payments | Update payment history
*DocumentBlockApi* | [**list_document_block**](docs/DocumentBlockApi.md#list_document_block) | **GET** /document-blocks | List all document blocks
*DocumentExportApi* | [**create**](docs/DocumentExportApi.md#create) | **POST** /document-export | Create document export.
*DocumentExportApi* | [**download**](docs/DocumentExportApi.md#download) | **GET** /document-export/{id}/download | Return exported binary file.
*DocumentExportApi* | [**poll**](docs/DocumentExportApi.md#poll) | **GET** /document-export/{id}/poll | Retrieve export state.
*OrganizationApi* | [**get_organization_data**](docs/OrganizationApi.md#get_organization_data) | **GET** /organization | Retrieve a organization data.
*PartnerApi* | [**create_partner**](docs/PartnerApi.md#create_partner) | **POST** /partners | Create a partner
*PartnerApi* | [**delete_partner**](docs/PartnerApi.md#delete_partner) | **DELETE** /partners/{id} | Delete a partner
*PartnerApi* | [**get_partner**](docs/PartnerApi.md#get_partner) | **GET** /partners/{id} | Retrieve a partner
*PartnerApi* | [**list_partner**](docs/PartnerApi.md#list_partner) | **GET** /partners | List all partners
*PartnerApi* | [**update_partner**](docs/PartnerApi.md#update_partner) | **PUT** /partners/{id} | Update a partner
*ProductApi* | [**create_product**](docs/ProductApi.md#create_product) | **POST** /products | Create a product
*ProductApi* | [**delete_product**](docs/ProductApi.md#delete_product) | **DELETE** /products/{id} | Delete a product
*ProductApi* | [**get_product**](docs/ProductApi.md#get_product) | **GET** /products/{id} | Retrieve a product
*ProductApi* | [**list_product**](docs/ProductApi.md#list_product) | **GET** /products | List all product
*ProductApi* | [**update_product**](docs/ProductApi.md#update_product) | **PUT** /products/{id} | Update a product
*SpendingApi* | [**spending_delete**](docs/SpendingApi.md#spending_delete) | **DELETE** /spendings/{id} | Deletes a spending.
*SpendingApi* | [**spending_list**](docs/SpendingApi.md#spending_list) | **GET** /spendings | Lists all spending
*SpendingApi* | [**spending_save**](docs/SpendingApi.md#spending_save) | **POST** /spendings | Creates a new spending.
*SpendingApi* | [**spending_show**](docs/SpendingApi.md#spending_show) | **GET** /spendings/{id} | Retrieves one specific spending.
*SpendingApi* | [**spending_update**](docs/SpendingApi.md#spending_update) | **PUT** /spendings/{id} | Updates a spending item.
*UtilApi* | [**check_tax_number**](docs/UtilApi.md#check_tax_number) | **GET** /utils/check-tax-number/{tax_number} | Check tax number.
*UtilApi* | [**get_id**](docs/UtilApi.md#get_id) | **GET** /utils/convert-legacy-id/{id} | Convert legacy ID to v3 ID.
*UtilApi* | [**get_server_time**](docs/UtilApi.md#get_server_time) | **GET** /utils/time | Get the server time

## Documentation For Models

 - [Address](docs/Address.md)
 - [BankAccount](docs/BankAccount.md)
 - [BankAccountList](docs/BankAccountList.md)
 - [Category](docs/Category.md)
 - [CheckTaxNumberMessage](docs/CheckTaxNumberMessage.md)
 - [ClientError](docs/ClientError.md)
 - [ClientErrorResponse](docs/ClientErrorResponse.md)
 - [ConversationRate](docs/ConversationRate.md)
 - [CorrectionType](docs/CorrectionType.md)
 - [Country](docs/Country.md)
 - [CreateDocumentExport](docs/CreateDocumentExport.md)
 - [Currency](docs/Currency.md)
 - [DateType](docs/DateType.md)
 - [Discount](docs/Discount.md)
 - [DiscountType](docs/DiscountType.md)
 - [Document](docs/Document.md)
 - [DocumentAncestor](docs/DocumentAncestor.md)
 - [DocumentBankAccount](docs/DocumentBankAccount.md)
 - [DocumentBlock](docs/DocumentBlock.md)
 - [DocumentBlockList](docs/DocumentBlockList.md)
 - [DocumentBlockType](docs/DocumentBlockType.md)
 - [DocumentCancellation](docs/DocumentCancellation.md)
 - [DocumentExportFilterExtra](docs/DocumentExportFilterExtra.md)
 - [DocumentExportId](docs/DocumentExportId.md)
 - [DocumentExportOtherOptions](docs/DocumentExportOtherOptions.md)
 - [DocumentExportQueryType](docs/DocumentExportQueryType.md)
 - [DocumentExportSortBy](docs/DocumentExportSortBy.md)
 - [DocumentExportStatus](docs/DocumentExportStatus.md)
 - [DocumentExportStatusState](docs/DocumentExportStatusState.md)
 - [DocumentExportType](docs/DocumentExportType.md)
 - [DocumentForm](docs/DocumentForm.md)
 - [DocumentFormat](docs/DocumentFormat.md)
 - [DocumentInsert](docs/DocumentInsert.md)
 - [DocumentInsertType](docs/DocumentInsertType.md)
 - [DocumentItem](docs/DocumentItem.md)
 - [DocumentItemData](docs/DocumentItemData.md)
 - [DocumentLanguage](docs/DocumentLanguage.md)
 - [DocumentList](docs/DocumentList.md)
 - [DocumentNotificationStatus](docs/DocumentNotificationStatus.md)
 - [DocumentOrganization](docs/DocumentOrganization.md)
 - [DocumentPartner](docs/DocumentPartner.md)
 - [DocumentProductData](docs/DocumentProductData.md)
 - [DocumentPublicUrl](docs/DocumentPublicUrl.md)
 - [DocumentSettings](docs/DocumentSettings.md)
 - [DocumentSummary](docs/DocumentSummary.md)
 - [DocumentType](docs/DocumentType.md)
 - [DocumentVatRateSummary](docs/DocumentVatRateSummary.md)
 - [Entitlement](docs/Entitlement.md)
 - [Feature](docs/Feature.md)
 - [Id](docs/Id.md)
 - [InvoiceSettings](docs/InvoiceSettings.md)
 - [LedgerNumberInformation](docs/LedgerNumberInformation.md)
 - [ModificationDocumentInsert](docs/ModificationDocumentInsert.md)
 - [OneOfDocumentInsertItemsItems](docs/OneOfDocumentInsertItemsItems.md)
 - [OneOfModificationDocumentInsertItemsItems](docs/OneOfModificationDocumentInsertItemsItems.md)
 - [OneOfReceiptInsertItemsItems](docs/OneOfReceiptInsertItemsItems.md)
 - [OnlinePayment](docs/OnlinePayment.md)
 - [OnlineSzamlaStatus](docs/OnlineSzamlaStatus.md)
 - [OnlineSzamlaStatusEnum](docs/OnlineSzamlaStatusEnum.md)
 - [OnlineSzamlaStatusMessage](docs/OnlineSzamlaStatusMessage.md)
 - [OrganizationData](docs/OrganizationData.md)
 - [Partner](docs/Partner.md)
 - [PartnerCustomBillingSettings](docs/PartnerCustomBillingSettings.md)
 - [PartnerList](docs/PartnerList.md)
 - [PartnerTaxType](docs/PartnerTaxType.md)
 - [PaymentHistory](docs/PaymentHistory.md)
 - [PaymentMethod](docs/PaymentMethod.md)
 - [PaymentStatus](docs/PaymentStatus.md)
 - [PaymentStatusSpending](docs/PaymentStatusSpending.md)
 - [Product](docs/Product.md)
 - [ProductList](docs/ProductList.md)
 - [ReceiptInsert](docs/ReceiptInsert.md)
 - [ReceiptItemData](docs/ReceiptItemData.md)
 - [ReceiptProductData](docs/ReceiptProductData.md)
 - [Round](docs/Round.md)
 - [SendDocument](docs/SendDocument.md)
 - [ServerError](docs/ServerError.md)
 - [ServerErrorResponse](docs/ServerErrorResponse.md)
 - [ServerTime](docs/ServerTime.md)
 - [Source](docs/Source.md)
 - [Spending](docs/Spending.md)
 - [SpendingList](docs/SpendingList.md)
 - [SpendingListItem](docs/SpendingListItem.md)
 - [SpendingPartner](docs/SpendingPartner.md)
 - [SpendingPaymentMethod](docs/SpendingPaymentMethod.md)
 - [SpendingSave](docs/SpendingSave.md)
 - [Subscription](docs/Subscription.md)
 - [SubscriptionErrorResponse](docs/SubscriptionErrorResponse.md)
 - [TaxNumber](docs/TaxNumber.md)
 - [TooManyRequestsResponse](docs/TooManyRequestsResponse.md)
 - [UnitPriceType](docs/UnitPriceType.md)
 - [ValidationError](docs/ValidationError.md)
 - [ValidationErrorResponse](docs/ValidationErrorResponse.md)
 - [Vat](docs/Vat.md)

## Documentation For Authorization


## api_key

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


## Author

hello@billingo.hu
