think.studio / laravel-sproutsocials-api
sproutsocials api integration for laravel
1.1.0
2023-09-03 14:27 UTC
Requires
- php: ^8.0
- ext-json: *
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.20
- guzzlehttp/guzzle: ^7.3
- orchestra/testbench: ^8.5
- phpunit/phpunit: ^10.2
- psalm/plugin-laravel: ^2.8
- vimeo/psalm: ^5.13
README
Installation
You can install the package via composer:
composer require think.studio/laravel-sproutsocials-api # optional publish configs php artisan vendor:publish --provider="ThinkOne\LaravelSproutsocialsApi\ServiceProvider" --tag="config"
Usage
/** @var Metadata $endpoint */ $endpoint = SproutsocialsApi::endpointGroup(Metadata::class); $response = $endpoint->getTags($customerId); if($response->successful()) { $tags = $response->json('data'); }
/** @var Analytics $endpoint */ $endpoint = SproutsocialsApi::endpointGroup(Analytics::class); $response = $endpoint->getPosts($requestData); if($response->successful()) { $posts = $response->json('data'); }