A simple wrapper for the GleSYS API.
You can install the package via composer:
composer require dronki/glesys-laravel
php artisan vendor:publish --provider="Dronki\GlesysLaravel\GlesysLaravelServiceProvider"
Register the service-provider in your config/app.php
file:
'providers' => [
...
Dronki\GlesysLaravel\GlesysLaravelServiceProvider::class,
],
The wrapper is written in such a way that it can be used in any Laravel application.
By using the facade, you can access the API in a simple way:
GleSYS::punyEncode( 'www.example.com' );
#General
GleSYS::getResponse(); // Gets the response from the last request
GleSYS::punyEncode( $string ); // Puny-encodes a string
GleSYS::punyDecode( $string ); // Puny-decodes a string
# Email
GleSYS::emailOverview(); // Gets a list of all email-accounts and aliases
GleSYS::emailsByDomain( $domain, $filter = '', $objects = false ); // Gets a list of all email-accounts and aliases for a domain, optionally filtered by $filter, and optionally return objects instead of arrays
GleSYS::emailCreateAccount( $email, $password, $settings = [] ); // Creates a new email-account
GleSYS::emailEditAccount( $email, $settings = [] ); // Edits an existing email-account
GleSYS::emailDeleteAccount( $email ); // Deletes an email-account
GleSYS::emailAccountQuota( $email ); // Gets the quota of an email-account
# Aliases for email-account
GleSYS::emailCreateAlias( $alias, $recipient ); // Creates a new alias for an email-account
GleSYS::emailEditAlias( $alias, $recipient ); // Edits an existing alias for an email-account
GleSYS::emailDeleteAlias( $alias ); // Deletes an alias for an email-account
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security related issues, please email rickard@ahlstedt.xyz instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.
If you like this package and would like to support my work, consider donating.