Do not use `$_GET`, instead use `Input::get('code')` it's the Laravel way. Secondly the model should not interact with the request information directly. This logic should be in the controller.