Skip to content

invoicetronic/ruby-sdk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ruby SDK for the Italian Invoicetronic API

The Invoicetronic API is a RESTful service that allows you to send and receive invoices through the Italian Servizio di Interscambio (SDI), or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools.

For more information, see Invoicetronic website

This SDK is automatically generated by the OpenAPI Generator project:

  • API version: 1
  • Package version: 1
  • Generator version: 7.12.0
  • Build package: org.openapitools.codegen.languages.RubyClientCodegen For more information, please visit https://invoicetronic.com

Installation

Build a gem

To build the Ruby code into a gem:

gem build invoicetronic_sdk.gemspec

Then either install the gem locally:

gem install ./invoicetronic_sdk-1.gem

(for development, run gem install --dev ./invoicetronic_sdk-1.gem to install the development dependencies)

or publish the gem to a gem hosting service, e.g. RubyGems.

Finally add this to the Gemfile:

gem 'invoicetronic_sdk', '~> 1'

Install from Git

If the Ruby gem is hosted at a git repository: https://github.com/invoicetronic/ruby-sdk, then add the following in the Gemfile:

gem 'invoicetronic_sdk', :git => 'https://github.com/invoicetronic/ruby-sdk.git'

Include the Ruby code directly

Include the Ruby code directly using -I as follows:

ruby -Ilib script.rb

Getting Started

Please follow the installation procedure and then run the following code:

# Load the gem
require 'invoicetronic_sdk'

# Setup authorization
Invoicetronic_Sdk.configure do |config|
  # Configure HTTP basic authorization: Basic
  config.username = 'YOUR_USERNAME'
  config.password = 'YOUR_PASSWORD'
end

api_instance = Invoicetronic_Sdk::CompanyApi.new
opts = {
  page: 56, # Integer | Page number. Defaults to 1.
  page_size: 56, # Integer | Items per page. Defaults to 50. Cannot be greater than 200.
  sort: 'sort_example' # String | Sort by field. Prefix with '-' for descending order.
}

begin
  #List companies
  result = api_instance.company_get(opts)
  p result
rescue Invoicetronic_Sdk::ApiError => e
  puts "Exception when calling CompanyApi->company_get: #{e}"
end

Documentation for API Endpoints

All URIs are relative to http://localhost

Class Method HTTP request Description
Invoicetronic_Sdk::CompanyApi company_get GET /company List companies
Invoicetronic_Sdk::CompanyApi company_id_delete DELETE /company/{id} Delete a company
Invoicetronic_Sdk::CompanyApi company_id_get GET /company/{id} Get a company by id
Invoicetronic_Sdk::CompanyApi company_post POST /company Add a company
Invoicetronic_Sdk::CompanyApi company_put PUT /company Update a company
Invoicetronic_Sdk::LogApi log_get GET /log List events
Invoicetronic_Sdk::LogApi log_id_get GET /log/{id} Get an event by id
Invoicetronic_Sdk::ReceiveApi receive_get GET /receive List incoming invoices
Invoicetronic_Sdk::ReceiveApi receive_id_delete DELETE /receive/{id} Delete an incoming invoice by id
Invoicetronic_Sdk::ReceiveApi receive_id_get GET /receive/{id} Get an incoming invoice by id
Invoicetronic_Sdk::SendApi send_file_post POST /send/file Add an invoice by file
Invoicetronic_Sdk::SendApi send_get GET /send List invoices
Invoicetronic_Sdk::SendApi send_id_get GET /send/{id} Get a invoice by id
Invoicetronic_Sdk::SendApi send_json_post POST /send/json Add an invoice by json
Invoicetronic_Sdk::SendApi send_post POST /send Add an invoice
Invoicetronic_Sdk::SendApi send_validate_files_post POST /send/validate/files Validate an invoice by file
Invoicetronic_Sdk::SendApi send_validate_json_post POST /send/validate/json Validate an invoice by json
Invoicetronic_Sdk::SendApi send_validate_post POST /send/validate Validate an invoice
Invoicetronic_Sdk::SendApi send_validate_xml_post POST /send/validate/xml Validate an invoice by xml
Invoicetronic_Sdk::SendApi send_xml_post POST /send/xml Add an invoice by xml
Invoicetronic_Sdk::StatusApi status_get GET /status Account status
Invoicetronic_Sdk::UpdateApi update_get GET /update List updates
Invoicetronic_Sdk::UpdateApi update_id_get GET /update/{id} Get an update by id
Invoicetronic_Sdk::WebhookApi webhook_get GET /webhook List webhooks
Invoicetronic_Sdk::WebhookApi webhook_id_delete DELETE /webhook/{id} Delete a webhook by id
Invoicetronic_Sdk::WebhookApi webhook_id_get GET /webhook/{id} Get a webhook by id
Invoicetronic_Sdk::WebhookApi webhook_post POST /webhook Add a webhook
Invoicetronic_Sdk::WebhookApi webhook_put PUT /webhook Update a webhook
Invoicetronic_Sdk::WebhookApi webhookhistory_get GET /webhookhistory List webhook history items
Invoicetronic_Sdk::WebhookApi webhookhistory_id_get GET /webhookhistory/{id} Get a webhook history item by id

Documentation for Models

Documentation for Authorization

Authentication schemes defined for the API:

Basic

  • Type: HTTP basic authentication

Releases

No releases published

Packages

No packages published

Languages