
{M} below is the name from module.json, for example PterodactylService. module:doctor checks all of this.
Service modules
Service modules
Only
ModuleServiceActions and the three Actions\* classes are needed. The rest gate optional features.ServiceControlLoader always passes two arguments to getServiceControls(), so declare both.Gateway modules
Gateway modules
The gateway key is
Str::lower(Str::before($moduleName, 'Gateway')), so AcmeGateway gives acme. getGatewayName() must return it.getConfig() returns name, display_name, description, logo, enabled and optionally mode. $paymentData['type'] in handlePaymentSuccess() is market, renewal, invoice, upgrade, downgrade, configurable_options_change, addon, balance or standalone.Optional gateway interfaces
Optional gateway interfaces
Vault providers can also implement
LooksUpCharges, HandlesCustomerAction and ImportsExistingPaymentMethods. Build charge results with ChargeResult::succeeded(), pending(), requiresAction(), failed() or unknown().Login providers
Login providers
App\Modules\OAuthProviderRegistry scans enabled modules whose name contains Provider.Registrar modules
Registrar modules
RegistrarManager resolves Modules\{M}\Services\Registrar. It must implement App\Domains\Contracts\DomainRegistrar, usually by extending AbstractRegistrar. Required methods are key(), displayName(), capabilities(), isConfigured(), checkAvailability(), register(), renew() and getInfo(). The generator also writes thin subclasses of the registrar service actions, renew, cancel, controls and suspend classes. Leave them as generated.
