Laravel package for easily connecting with MaakEenFactuur.nl
veiliglanceren/maakeenfactuur-laravel is a Laravel package for laravel package for easily connecting with maakeenfactuur.nl.
It currently has 2 GitHub stars and 35 downloads on Packagist (latest version 1.2.0).
Install it with composer require veiliglanceren/maakeenfactuur-laravel.
Discover more Laravel packages by veiliglanceren
or browse all Laravel packages to compare alternatives.
Last updated
![]()
📜 Overview
This Laravel package is a PHP library that provides simplified interfaces for managing customers and invoices via our API. It includes two primary facades: Customer and Invoice, which are backed by powerful service classes handling all interactions with the API.

This package is maintained by VeiligLanceren.nl, your partner in website development and everything else to power up your online company. More information available on our website.
To use the Laravel package of MaakEenFactuur.nl in your project, require it via Composer in your terminal:
composer require veiliglanceren/maakeenfactuur-laravel
The API key is handled by the ApiService of the package. Set up your API key to authenticate requests.
By default this will be loaded from the config file config/maakeenfactuur.php which can be exported by running:
php artisan vendor:publish --tag="maakeenfactuur-config"
This will add the default .env variable MAAKEENFACTUUR_API_KEY which can be set:
MAAKEENFACTUUR_API_KEY="YOUR_API_KEY"
use VeiligLanceren\MaakEenFactuur\Facades\Customer;
// Fetch all customers
$customers = Customer::all();
// Create a new customer
$newCustomer = Customer::create(['name' => 'John Doe', 'email' => '[email protected]']);
// Find a specific customer
$customer = Customer::find(1);
use VeiligLanceren\MaakEenFactuur\Facades\Invoice;
// Create an invoice
$newInvoice = Invoice::create(['customer_id' => 1, 'amount' => 100.00]);
// Update an existing invoice
$updatedInvoice = Invoice::update(1, ['amount' => 150.00]);
// Fetch all invoices
$invoices = Invoice::all();
// Find a specific invoice
$invoice = Invoice::find(1);
Both Customer and Invoice services throw an ApiErrorException if an API request fails, allowing you to handle errors gracefully in your application.
try {
$invoice = Invoice::find(1);
} catch (VeiligLanceren\MaakEenFactuur\Exception\ApiErrorException $e) {
// TODO: Handle error
echo 'Error: ' . $e->getMessage();
}
Contributions are welcome! Please feel free to submit a pull request or create an issue if you have any suggestions or find any bugs.
This project is licensed under the MIT License - see the LICENSE.md file for details.
This README is structured to provide a comprehensive introduction and guide on how to use the library, complete with installation instructions, usage examples, and basic error handling. Adjust the details according to your actual project structure and requirements.