Updated Wrapper
This commit is contained in:
parent
a11a17f9d2
commit
9711bb903c
|
@ -1,6 +1,9 @@
|
||||||
# APP_URL="http://localhost:8000" # Full url path, PLEASE REPLACE TO YOUR OWN ONE
|
# APP_URL="http://localhost:8000" # Full url path, PLEASE REPLACE TO YOUR OWN ONE
|
||||||
# SIGNER_URL="https://tiktok-sign.herokuapp.com/signature" # External signing service
|
|
||||||
# LATTE_CACHE=/tmp/proxitok_api # Path for Latte cache, leave commented for ./cache/latte
|
# LATTE_CACHE=/tmp/proxitok_api # Path for Latte cache, leave commented for ./cache/latte
|
||||||
|
|
||||||
|
# API CONFIG
|
||||||
|
# USE_TEST_ENDPOINTS=1 # Discomment for usage of t.tiktok.com
|
||||||
|
# SIGNER_URL="https://tiktok-sign.herokuapp.com/signature" # External signing service
|
||||||
# API_CACHE=redis # Cache engine for TikTok Api, (more info on README)
|
# API_CACHE=redis # Cache engine for TikTok Api, (more info on README)
|
||||||
|
|
||||||
# Redis cache, used on Helpers\CacheEngines\RedisCache
|
# Redis cache, used on Helpers\CacheEngines\RedisCache
|
||||||
|
|
|
@ -18,7 +18,7 @@ class Misc {
|
||||||
}
|
}
|
||||||
|
|
||||||
static public function env(string $key, string $default_value): string {
|
static public function env(string $key, string $default_value): string {
|
||||||
return isset($_ENV[$key]) && !empty($_ENV[$key]) ? $_ENV[$key] : $default_value;
|
return $_ENV[$key] ?? $default_value;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -33,7 +33,8 @@ class Misc {
|
||||||
*/
|
*/
|
||||||
static public function api(): \TikScraper\Api {
|
static public function api(): \TikScraper\Api {
|
||||||
$options = [
|
$options = [
|
||||||
'remote_signer' => self::env('SIGNER_URL', 'http://localhost:8080/signature')
|
'remote_signer' => self::env('SIGNER_URL', 'http://localhost:8080/signature'),
|
||||||
|
'use_test_endpoints' => self::env('USE_TEST_ENDPOINTS', false)
|
||||||
];
|
];
|
||||||
$cacheEngine = false;
|
$cacheEngine = false;
|
||||||
// Proxy config
|
// Proxy config
|
||||||
|
|
12
composer.lock
generated
12
composer.lock
generated
|
@ -306,16 +306,16 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "pablouser1/tikscraper",
|
"name": "pablouser1/tikscraper",
|
||||||
"version": "v1.2.2",
|
"version": "v1.2.3",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/pablouser1/TikScraperPHP.git",
|
"url": "https://github.com/pablouser1/TikScraperPHP.git",
|
||||||
"reference": "a001bc0dce7fbd15f85b15cbe365de436c515457"
|
"reference": "2ecba60b580979b6be6b58436bce7a55f8bc0d49"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/pablouser1/TikScraperPHP/zipball/a001bc0dce7fbd15f85b15cbe365de436c515457",
|
"url": "https://api.github.com/repos/pablouser1/TikScraperPHP/zipball/2ecba60b580979b6be6b58436bce7a55f8bc0d49",
|
||||||
"reference": "a001bc0dce7fbd15f85b15cbe365de436c515457",
|
"reference": "2ecba60b580979b6be6b58436bce7a55f8bc0d49",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -339,9 +339,9 @@
|
||||||
"description": "Get data from TikTok API",
|
"description": "Get data from TikTok API",
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/pablouser1/TikScraperPHP/issues",
|
"issues": "https://github.com/pablouser1/TikScraperPHP/issues",
|
||||||
"source": "https://github.com/pablouser1/TikScraperPHP/tree/v1.2.2"
|
"source": "https://github.com/pablouser1/TikScraperPHP/tree/v1.2.3"
|
||||||
},
|
},
|
||||||
"time": "2022-02-13T21:42:57+00:00"
|
"time": "2022-02-15T12:46:29+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpoption/phpoption",
|
"name": "phpoption/phpoption",
|
||||||
|
|
Loading…
Reference in a new issue