https://github.com/sensson/laravel-directadmin
A simple DirectAdmin API for Laravel.
https://github.com/sensson/laravel-directadmin
directadmin laravel
Last synced: 12 months ago
JSON representation
A simple DirectAdmin API for Laravel.
- Host: GitHub
- URL: https://github.com/sensson/laravel-directadmin
- Owner: sensson
- License: mit
- Created: 2024-05-31T11:35:23.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-02-24T16:18:08.000Z (12 months ago)
- Last Synced: 2025-02-24T16:52:21.491Z (12 months ago)
- Topics: directadmin, laravel
- Language: PHP
- Homepage:
- Size: 63.5 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
Awesome Lists containing this project
README
# DirectAdmin integration for Laravel
[](https://packagist.org/packages/sensson/laravel-directadmin)
[](https://github.com/sensson/laravel-directadmin/actions?query=workflow%3Arun-tests+branch%3Amain)
[](https://github.com/sensson/laravel-directadmin/actions?query=workflow%3A"Fix+PHP+code+style+issues"+branch%3Amain)
[](https://packagist.org/packages/sensson/laravel-directadmin)
PHP library for interacting with the DirectAdmin API in Laravel.
## Installation
You can install the package via composer:
```bash
composer require sensson/laravel-directadmin
php artisan vendor:publish --tag="laravel-directadmin-config"
```
## Usage
You will need the following credentials to authenticate:
- `DIRECTADMIN_SERVER`
- `DIRECTADMIN_USERNAME`
- `DIRECTADMIN_PASSWORD`
### A simple example
You can call any DirectAdmin API by using the `DirectAdmin` facade:
```php
post('{DIRECTADMIN_API_CALL}');
```
This will run the `DIRECTADMIN_API_CALL` as the user `user`.
### Debugging
You can enable debugging by calling the `debug` method:
```php
$result = DirectAdmin::debug()->post('{DIRECTADMIN_API_CALL}', []);
```
This will enable debugging for the HTTP request. This can help you identify
issues with the DirectAdmin server.
### More information
For more information on the available commands, please refer to the
[DirectAdmin API documentation](https://docs.directadmin.com/directadmin/customizing-workflow/api-all-about.html).
## Testing
```bash
composer test
```
## Changelog
Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.
## Contributing
Please see [CONTRIBUTING](CONTRIBUTING.md) for details.
## Security Vulnerabilities
Please review [our security policy](../../security/policy) on how to report security vulnerabilities.
## Credits
- [Sensson](https://github.com/Sensson)
- [All Contributors](../../contributors)
## License
The MIT License (MIT). Please see [License File](LICENSE.md) for more information.