juniorb2ss/laravel-extended-validation-rules

Rules to make easy validations in laravel 5.5.

1.0.0 2017-09-05 17:37 UTC

This package is not auto-updated.

Last update: 2024-11-07 08:40:15 UTC


README

Validate Email With Mailgun Service

In .env file you need define your api pub key

MAILGUN_PUBKEY=pubkey-5ogiflzbnjrljiky49qxsiozqef5jxp7

To make validation:

    use juniorb2ss\LaravelExtendedValidationRules\Rules\MailGunValidateEmailAddressRule;

    return Validator::make($inputs, [
        'name' => 'required|string|max:255',
        'email' => [
            'required',
            'string',
            'max:255',
            'unique:users',
            new MailGunValidateEmailAddressRule // to make validation in mailgun service
        ]
    ]);