name('Project') ->model(Project::class) ->expectsJsonData() ->transformer(ProjectTransformer::class) ->handler(CrudResourceController::class) ->itemKey('project') ->collectionKey('projects') ->deny(AclRoles::UNAUTHORIZED) ->endpoint(ApiEndpoint::all() ->description('Returns all projects') ) ->endpoint(ApiEndpoint::create()) ->endpoint(ApiEndpoint::find()) ->endpoint(ApiEndpoint::update()) ->endpoint(ApiEndpoint::remove()) ->endpoint(ApiEndpoint::get('/test', 'test') ->allow(AclRoles::USER) ->description('Returns tall projects') ) ; } }