Recommend this page to a friend! |
![]() |
Info | ![]() |
![]() |
![]() |
Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2025-06-08 (2 hours ago) ![]() | Not yet rated by the users | Total: Not yet counted | Not yet ranked |
Version | License | PHP version | Categories | |||
laravel-tikfinity-we 1.0 | MIT/X Consortium ... | 5 | Web services, Video, PHP 7 |
Description | Author | |||||||||||||||||||||||
This package can handle TikTok events using TikFinity Webhooks. |
|
Please read this document to learn how to create TikTok live-streaming webhook event handlers.
<a href="https://www.buymeacoffee.com/KgBot"><img src="https://img.buymeacoffee.com/button-api/?text=Buy me a beer&emoji=?&slug=KgBot&button_colour=5F7FFF&font_colour=ffffff&font_family=Cookie&outline_colour=000000&coffee_colour=FFDD00"></a>
This package provides a set of webhooks for TikFinity, allowing you to easily integrate TikTok LIVE events into your application.
You can install the package via Composer:
composer require kg-bot/laravel-tikfinity-webhooks
After installing the package, you need to publish the configuration file:
php artisan vendor:publish --tag="tikfinity-webhooks-config
This will create a tikfinity-webhooks.php
file in your config
directory. You can customize the configuration as needed.
You can publish the migrations using the following command:
php artisan vendor:publish --tag="tikfinity-webhooks-migrations"
The package provides a set of routes for handling TikTok webhooks. You can find the routes in the routes/web.php
file. You can customize the routes as needed.
You can use the webhooks in your application to handle TikTok LIVE Gift and LIVE comment events.
To handle the events, you should configure the pipes in your tikfinity-webhooks.php
configuration file. The package provides a set of example pipes that you can use to handle the events. You can also create your own pipes to handle the events as needed.
You can use the KgBot\TikfinityWebhooks\Models\TikTokProfile
model to save TikTok profile information.
You can use the package to handle TikTok LIVE Gift and LIVE comment events. Here is an example of how to handle a LIVE Gift event:
You can create a pipe to handle the LIVE Gift event. Here is an example of a pipe that verifies if the event is a gift event:
use Closure;
use KgBot\TikFinityWebhooks\Contracts\PipeContract;
use KgBot\TikFinityWebhooks\DTO\WebhookData;
final class VerifyGiftWebhook implements PipeContract
{
/
* @throws EventNotAllowed
*/
public function handle(WebhookData $webhookData, Closure $next): mixed
{
if(!$webhookData->isGiftEvent()) {
throw new EventNotAllowed('Event is not a gift event');
}
return $next($webhookData);
}
}
Each pipe should implement the PipeContract
interface and define the handle
method. The handle
method receives the WebhookData
object and a closure to pass the data to.
You can register the pipe for each event in the tikfinity-webhooks.php
configuration file by overwriting the pipes
array. Here is an example of how to register the VerifyGiftWebhook
pipe for the gift
event:
return [
'pipes' => [
'gift' => [
VerifyGiftWebhook::class,
// Other pipes can be added here
],
],
];
composer test
This package is open-sourced software licensed under the MIT license.
If you want to contribute to this package, feel free to open a pull request or create an issue. Your contributions are welcome!
If you have any questions or need support, you can open an issue on the GitHub repository or contact me directly.
![]() |
File | Role | Description | ||
---|---|---|---|---|
![]() |
||||
![]() |
||||
![]() |
||||
![]() |
||||
![]() |
||||
![]() |
||||
![]() ![]() |
Data | Auxiliary data | ||
![]() ![]() |
Data | Auxiliary data | ||
![]() ![]() |
Lic. | License text | ||
![]() ![]() |
Doc. | Documentation |
The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page. |
![]() |
Version Control | Unique User Downloads | |||||||
100% |
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.