PHP code example of thank-song / teapplix

1. Go to this page and download the library: Download thank-song/teapplix library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

thank-song / teapplix example snippets


return [
    // 使用 .env 中的配置自动初始化
    'api_token'=>env('TEAPPLIX_API_TOKEN','YOUR-API-TOKEN-HERE')
];


use ThankSong\Teapplix\Teapplix;

$res = Teapplix::getProducts();
dump($res -> getData());
dump($res -> getPage());
dump($res -> getPageSize());
dump($res -> hasMore());
bash
php artisan vendor:publish --tag=teapplix