everully/laravel-wildberries-sdk

v0.0.1 2024-08-25 14:20 UTC

This package is auto-updated.

Last update: 2025-04-25 15:46:01 UTC


README

Under the hook this package use everully/php-wildberries-sdk to provide a simple way to interact with Wildberries API.

Requirements

  • Laravel 8.0 or later.
  • PHP 8.2 or later.

Installation

Install via composer:

composer require everully/laravel-wildberries-sdk

You can publish the config file with:

php artisan vendor:publish --tag="wildberries-config"

Ensure that you have updated your application .env with credentials from Wildberries i.e.

#.env file

WILDBERRIES_TOKEN=
WILDBERRIES_SANDBOX=

Usage

You can use everully/php-wildberries-sdk functionality directly:

/** @var \Everully\PhpWildberriesSdk\WildberriesApi $wildberriesContent */
$wildberriesContent = WildberriesApi::content();
$wildberriesContent->content()->cards()->get($data);

You can set up api token and sandbox mode in the config file config/wildberries.php:

/** @var \Everully\PhpWildberriesSdk\WildberriesApi $wildberriesContent */
$token = 'your-wildberries-token';

$wildberriesContent = WildberriesApi::setToken($token)
    ->content()
    ->cards()
    ->get($data);

More about all WildberriesApi methods see here: everully/php-wildberries-sdk

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits

License

The MIT License (MIT). Please see License File for more information.