header('X-Gitlab-Token') !== null && $this->header('X-Gitlab-Token') === config('webhooks.gitlab.token'); } /** * Get the validation rules that apply to the request. * * @return array */ public function rules() { return [ 'event_type' => 'required|in:merge_request' ]; } }