├── .gitignore ├── LICENSE ├── README.md ├── composer.json ├── docs ├── more-about-builder.md ├── more-about-models.md ├── more-about-transports.md ├── more-about-wrapper.md ├── transports │ └── oauth2.md ├── work-standalone.md ├── work-with-laravel.md └── work-with-symfony.md ├── phpunit.xml.dist ├── rector.php ├── src ├── Api.php ├── Bridges │ ├── BarryvdhLaravelDebugbar │ │ ├── ApiCollector.php │ │ └── DebugbarTransportDecorator.php │ ├── Laravel │ │ ├── HasApiRelations.php │ │ ├── HasEloquentRelations.php │ │ ├── Model.php │ │ └── Relations │ │ │ ├── BelongsTo.php │ │ │ ├── Builder.php │ │ │ ├── Decorators │ │ │ └── RelationWithoutBuilder.php │ │ │ ├── HasMany.php │ │ │ └── HasOne.php │ └── Symfony │ │ ├── Adapter │ │ └── ApiWrapperPaginatorAdapter.php │ │ ├── ApiWrapperBundle.php │ │ ├── ClassMetadata.php │ │ ├── ConnectionInterface.php │ │ ├── DataProvider │ │ └── ApiPlatformDataProvider.php │ │ ├── DependencyInjection │ │ ├── ManagerConnectionPass.php │ │ ├── RepositoryPass.php │ │ └── WrapperExtension.php │ │ ├── Exception │ │ ├── ConnectionNotFoundException.php │ │ └── RepositoryNotFoundException.php │ │ ├── ManagerRegistry.php │ │ ├── Mapping │ │ └── Entity.php │ │ ├── Paginator.php │ │ ├── PaginatorInterface.php │ │ ├── Repository.php │ │ └── Resources │ │ └── config │ │ └── services.yaml ├── Builder.php ├── Concerns │ ├── HasAttributes.php │ ├── HasCache.php │ ├── HasGlobalScopes.php │ ├── HasRelationships.php │ └── HidesAttributes.php ├── Exceptions │ ├── ApiBadRequestException.php │ ├── ApiEntityNotFoundException.php │ ├── ApiException.php │ ├── ApiForbiddenException.php │ ├── ApiUnauthorizedException.php │ ├── Handlers │ │ ├── AbstractErrorHandler.php │ │ ├── BadRequestErrorHandler.php │ │ ├── ForbiddenErrorHandler.php │ │ ├── NetworkErrorHandler.php │ │ ├── NotFoundErrorHandler.php │ │ └── UnauthorizedErrorHandler.php │ └── MissingApiException.php ├── Model.php ├── MultipartParam.php ├── Relations │ ├── BelongsTo.php │ ├── Decorators │ │ └── RelationWithoutBuilder.php │ ├── HasMany.php │ ├── HasOne.php │ ├── Relation.php │ └── RelationInterface.php └── Transports │ ├── Basic.php │ ├── Bearer.php │ ├── NullTransport.php │ ├── OAuth2.php │ ├── Transport.php │ └── TransportInterface.php └── tests ├── ApiTest.php └── TransportCurlTest.php /.gitignore: -------------------------------------------------------------------------------- 1 | /.phpunit.cache 2 | /composer.lock 3 | /vendor/ 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/README.md -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/composer.json -------------------------------------------------------------------------------- /docs/more-about-builder.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/more-about-builder.md -------------------------------------------------------------------------------- /docs/more-about-models.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/more-about-models.md -------------------------------------------------------------------------------- /docs/more-about-transports.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/more-about-transports.md -------------------------------------------------------------------------------- /docs/more-about-wrapper.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/more-about-wrapper.md -------------------------------------------------------------------------------- /docs/transports/oauth2.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/transports/oauth2.md -------------------------------------------------------------------------------- /docs/work-standalone.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/work-standalone.md -------------------------------------------------------------------------------- /docs/work-with-laravel.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/work-with-laravel.md -------------------------------------------------------------------------------- /docs/work-with-symfony.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/docs/work-with-symfony.md -------------------------------------------------------------------------------- /phpunit.xml.dist: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/phpunit.xml.dist -------------------------------------------------------------------------------- /rector.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/rector.php -------------------------------------------------------------------------------- /src/Api.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Api.php -------------------------------------------------------------------------------- /src/Bridges/BarryvdhLaravelDebugbar/ApiCollector.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/BarryvdhLaravelDebugbar/ApiCollector.php -------------------------------------------------------------------------------- /src/Bridges/BarryvdhLaravelDebugbar/DebugbarTransportDecorator.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/BarryvdhLaravelDebugbar/DebugbarTransportDecorator.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/HasApiRelations.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/HasApiRelations.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/HasEloquentRelations.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/HasEloquentRelations.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Model.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Model.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Relations/BelongsTo.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Relations/BelongsTo.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Relations/Builder.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Relations/Builder.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Relations/Decorators/RelationWithoutBuilder.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Relations/Decorators/RelationWithoutBuilder.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Relations/HasMany.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Relations/HasMany.php -------------------------------------------------------------------------------- /src/Bridges/Laravel/Relations/HasOne.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Laravel/Relations/HasOne.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Adapter/ApiWrapperPaginatorAdapter.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Adapter/ApiWrapperPaginatorAdapter.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/ApiWrapperBundle.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/ApiWrapperBundle.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/ClassMetadata.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/ClassMetadata.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/ConnectionInterface.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/ConnectionInterface.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/DataProvider/ApiPlatformDataProvider.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/DataProvider/ApiPlatformDataProvider.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/DependencyInjection/ManagerConnectionPass.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/DependencyInjection/ManagerConnectionPass.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/DependencyInjection/RepositoryPass.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/DependencyInjection/RepositoryPass.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/DependencyInjection/WrapperExtension.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/DependencyInjection/WrapperExtension.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Exception/ConnectionNotFoundException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Exception/ConnectionNotFoundException.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Exception/RepositoryNotFoundException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Exception/RepositoryNotFoundException.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/ManagerRegistry.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/ManagerRegistry.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Mapping/Entity.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Mapping/Entity.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Paginator.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Paginator.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/PaginatorInterface.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/PaginatorInterface.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Repository.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Repository.php -------------------------------------------------------------------------------- /src/Bridges/Symfony/Resources/config/services.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Bridges/Symfony/Resources/config/services.yaml -------------------------------------------------------------------------------- /src/Builder.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Builder.php -------------------------------------------------------------------------------- /src/Concerns/HasAttributes.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Concerns/HasAttributes.php -------------------------------------------------------------------------------- /src/Concerns/HasCache.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Concerns/HasCache.php -------------------------------------------------------------------------------- /src/Concerns/HasGlobalScopes.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Concerns/HasGlobalScopes.php -------------------------------------------------------------------------------- /src/Concerns/HasRelationships.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Concerns/HasRelationships.php -------------------------------------------------------------------------------- /src/Concerns/HidesAttributes.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Concerns/HidesAttributes.php -------------------------------------------------------------------------------- /src/Exceptions/ApiBadRequestException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/ApiBadRequestException.php -------------------------------------------------------------------------------- /src/Exceptions/ApiEntityNotFoundException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/ApiEntityNotFoundException.php -------------------------------------------------------------------------------- /src/Exceptions/ApiException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/ApiException.php -------------------------------------------------------------------------------- /src/Exceptions/ApiForbiddenException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/ApiForbiddenException.php -------------------------------------------------------------------------------- /src/Exceptions/ApiUnauthorizedException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/ApiUnauthorizedException.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/AbstractErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/AbstractErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/BadRequestErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/BadRequestErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/ForbiddenErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/ForbiddenErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/NetworkErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/NetworkErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/NotFoundErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/NotFoundErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/Handlers/UnauthorizedErrorHandler.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/Handlers/UnauthorizedErrorHandler.php -------------------------------------------------------------------------------- /src/Exceptions/MissingApiException.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Exceptions/MissingApiException.php -------------------------------------------------------------------------------- /src/Model.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Model.php -------------------------------------------------------------------------------- /src/MultipartParam.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/MultipartParam.php -------------------------------------------------------------------------------- /src/Relations/BelongsTo.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/BelongsTo.php -------------------------------------------------------------------------------- /src/Relations/Decorators/RelationWithoutBuilder.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/Decorators/RelationWithoutBuilder.php -------------------------------------------------------------------------------- /src/Relations/HasMany.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/HasMany.php -------------------------------------------------------------------------------- /src/Relations/HasOne.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/HasOne.php -------------------------------------------------------------------------------- /src/Relations/Relation.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/Relation.php -------------------------------------------------------------------------------- /src/Relations/RelationInterface.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Relations/RelationInterface.php -------------------------------------------------------------------------------- /src/Transports/Basic.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/Basic.php -------------------------------------------------------------------------------- /src/Transports/Bearer.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/Bearer.php -------------------------------------------------------------------------------- /src/Transports/NullTransport.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/NullTransport.php -------------------------------------------------------------------------------- /src/Transports/OAuth2.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/OAuth2.php -------------------------------------------------------------------------------- /src/Transports/Transport.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/Transport.php -------------------------------------------------------------------------------- /src/Transports/TransportInterface.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/src/Transports/TransportInterface.php -------------------------------------------------------------------------------- /tests/ApiTest.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/tests/ApiTest.php -------------------------------------------------------------------------------- /tests/TransportCurlTest.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CristalTeam/php-api-wrapper/HEAD/tests/TransportCurlTest.php --------------------------------------------------------------------------------