PhalconRest\Api\ApiEndpoint::create PHP Méthode

create() public static méthode

Returns pre-configured create endpoint
public static create ( ) : static
Résultat static
    public static function create()
    {
        return self::factory('/', HttpMethods::POST, 'create')->name(self::CREATE)->description('Creates a new item using the posted data');
    }

Usage Example

 public function initialize()
 {
     $this->name('Photo')->model(Photo::class)->expectsJsonData()->transformer(PhotoTransformer::class)->itemKey('photo')->collectionKey('photos')->deny(AclRoles::UNAUTHORIZED)->handler(CrudResourceController::class)->endpoint(ApiEndpoint::all())->endpoint(ApiEndpoint::create())->endpoint(ApiEndpoint::find())->endpoint(ApiEndpoint::update())->endpoint(ApiEndpoint::remove());
 }
All Usage Examples Of PhalconRest\Api\ApiEndpoint::create