public function store()
    {
        try {
            $incident = execute(new CreateIncidentCommand(
                Binput::get('name'),
                Binput::get('status'),
                Binput::get('message', null, false, false),
                (bool) Binput::get('visible', true),
                Binput::get('component_id'),
                Binput::get('component_status'),
                (bool) Binput::get('notify', true),
                (bool) Binput::get('stickied', false),
                Binput::get('occurred_at'),
                Binput::get('template'),
                Binput::get('vars', []),
                Binput::get('meta', [])
            ));
        } catch (QueryException $e) {
            throw new BadRequestHttpException();
        }

        return $this->item($incident);
    }
public function store()
    {
        try {
            $incident = execute(new CreateIncidentCommand(
                Binput::get('name'),
                Binput::get('status'),
                Binput::get('message', null, false, false),
                (bool) Binput::get('visible', true),
                Binput::get('component_id'),
                Binput::get('component_status'),
                (bool) Binput::get('notify', true),
                (bool) Binput::get('stickied', false),
                Binput::get('occurred_at'),
                Binput::get('template'),
                Binput::get('vars', []),
                Binput::get('meta', [])
            ));
        } catch (QueryException $e) {
            throw new BadRequestHttpException();
        }

        return $this->item($incident);
    }
public function store ( ) { try { $ incident = execute ( new CreateIncidentCommand ( Binput :: get ( 'name' ) , Binput :: get ( 'status' ) , Binput :: get ( 'message' , null , false , false ) , ( bool ) Binput :: get ( 'visible' , true ) , Binput :: get ( 'component_id' ) , Binput :: get ( 'component_status' ) , ( bool ) Binput :: get ( 'notify' , true ) , ( bool ) Binput :: get ( 'stickied' , false ) , Binput :: get ( 'occurred_at' ) , Binput :: get ( 'template' ) , Binput :: get ( 'vars' , [ ] ) , Binput :: get ( 'meta' , [ ] ) ) ) ; } catch ( QueryException $ e ) { throw new BadRequestHttpException ( ) ; } return $ this -> item ( $ incident ) ; }
Create a new incident.

@return \Illuminate\Http\JsonResponse
Create a new incident .