Ruby SDK
for Peppol E-Invoicing
The official Ruby gem for e-invoice.be. Elegant, idiomatic Ruby for Rails, Sinatra, and any Ruby application.
gem install e-invoice-apiWhat is e-invoice.be?
e-invoice.be is a recognized Peppol Access Point and SMP operating under the Belgian Peppol Authority (BOSA). We enable businesses worldwide to send and receive electronic invoices via the Peppol network.
Our API lets you send invoices from JSON, upload pre-generated UBL XML, create invoices from PDF files, or integrate via our reseller programme. The Ruby gem makes integrating with our API elegant and Rubyesque.
Instant Delivery
E-invoices delivered instantly via Peppol
Peppol Compliant
Automatic UBL BIS Billing 3.0 conversion
Real-time Validation
Validate invoices before sending
Quick Start
Get up and running in minutes with our Ruby gem.
1. Install the gem
Add the following to your application's Gemfile:
gem "e-invoice-api"
2. Usage
require "bundler/setup" require "e_invoice_api" e_invoice = EInvoiceAPI::Client.new( api_key: ENV["E_INVOICE_API_KEY"] # This is the default and can be omitted ) document_response = e_invoice.documents.create puts(document_response.id)
Features
Ruby 3.0+ Support
Built for modern Ruby with pattern matching, endless methods, and other Ruby 3 features.
ActiveRecord-style API
Familiar method chaining and query interface. Feels native to Ruby on Rails developers.
Faraday HTTP Client
Uses Faraday for flexible HTTP with middleware support. Compatible with Net::HTTP, Typhoeus, and more.
Auto-retry with Backoff
Automatic retry logic with exponential backoff for transient failures. Configurable retry strategies.
Block-based Iteration
Idiomatic Ruby enumeration with blocks. Iterate through paginated results the Ruby way.
Rails & Sinatra Ready
First-class support for Rails with initializers and configuration. Also works with Sinatra, Hanami, and pure Ruby.
Start integrating today
Get your API key and start sending e-invoices in minutes. Our documentation has everything you need to get started.