Skip to content

PabloB07/KickWP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

KickWP - WordPress Plugin

A WordPress plugin that integrates with the Kick.com API using OAuth 2.1 to manage and display channel information directly from your WordPress admin dashboard.

Features

  • OAuth 2.1 Authentication: Secure authentication using industry-standard OAuth 2.1 flow
  • Channel Management: View all Kick.com channels in a beautiful grid layout with advanced filtering
  • Real-time Data: Fetch live channel information including viewer counts and stream status
  • Metadata Updates: Update channel metadata directly from WordPress (stream title, category, tags)
  • Advanced Search: Search channels by slug, user ID, or filter by categories
  • Categories Integration: Full integration with Kick.com categories API for filtering
  • Shortcodes: Embed channels anywhere using [kickwp_channel] shortcode
  • CSS Customization: Customize styling to match your WordPress theme
  • Responsive Design: Works perfectly on desktop and mobile devices
  • Caching System: Built-in caching to reduce API calls and improve performance

Installation

  1. Download the plugin files
  2. Upload the kickwp folder to your /wp-content/plugins/ directory
  3. Activate the plugin through the WordPress admin dashboard
  4. Go to KickWP > Settings to configure your API token

Configuration

OAuth 2.1 Setup

  1. Visit Kick.com Developer Portal to create an application
  2. Get your Client ID and Client Secret from the developer portal
  3. Important: Set the Redirect URI in your Kick app to: https://yoursite.com/wp-admin/admin.php?page=kickwp-channels (replace yoursite.com with your actual domain)
  4. In your WordPress admin, go to KickWP > Settings
  5. Enter your Client ID and Client Secret
  6. Verify the Redirect URI matches what you set in the Kick Developer Portal
  7. Click Connect to Kick.com to authorize the application
  8. Set your preferred cache duration (1-60 minutes)

Required Scopes

The plugin requires the following OAuth scopes:

  • channel:read - To fetch channel information
  • channel:edit - To update channel metadata
  • user:read - To access user information

Usage

Viewing Channels

  1. Navigate to KickWP > Channels in your WordPress admin
  2. The plugin will automatically load your channels
  3. Use the Refresh Channels button to get the latest data
  4. Use the Search Channels feature to find specific channels

Editing Channel Metadata

  1. Click the Edit button on any channel card
  2. Modify the stream title, description, category, or tags
  3. Click Update Channel to save changes
  4. Changes are immediately reflected on Kick.com

Using Categories

  1. Categories are automatically loaded from Kick.com API
  2. Use the category filter dropdown to show only channels from specific categories
  3. Categories include Gaming, Music, Art, Technology, Sports, and more

Channel Information Displayed

  • Stream title and description
  • Live/offline status with viewer count
  • Channel category
  • Stream thumbnail
  • Channel slug
  • Custom tags

Shortcodes

Embed Kick.com channels anywhere in your posts or pages using shortcodes:

Basic Channel Display

[kickwp_channel slug="channelname"]

Advanced Shortcode Options

[kickwp_channel slug="channelname" show_thumbnail="true" show_description="true" show_viewers="true" class="my-custom-class"]

Parameters:

  • slug (required): Channel slug or username
  • show_thumbnail (optional): Show stream thumbnail (default: true)
  • show_description (optional): Show channel description (default: true)
  • show_viewers (optional): Show viewer count when live (default: true)
  • class (optional): Custom CSS class for styling

CSS Customization

Customize the appearance of shortcodes by adding CSS in KickWP > Settings > CSS Customization:

.kickwp-channel-widget {
    border: 2px solid #your-color;
    background: #your-background;
}

.kickwp-watch-button {
    background: #your-brand-color;
}

API Integration

The plugin integrates with the Kick.com Public API v1:

  • GET /public/v1/channels - Fetch channel information
  • PATCH /public/v1/channels - Update channel metadata

All API calls include proper error handling and authentication.

Security Features

  • Nonce verification for all AJAX requests
  • User capability checks (admin only)
  • Sanitized input data
  • Secure API token storage
  • Rate limiting through caching

Troubleshooting

Common Issues

  1. "OAuth configuration incomplete"

    • Go to KickWP > Settings and enter your Client ID and Client Secret
    • Ensure the Redirect URI matches exactly what you registered in Kick Developer Portal
  2. "invalid_grant" error during OAuth

    • This usually means the Redirect URI doesn't match what you registered in Kick Developer Portal
    • Check that the Redirect URI in your Kick app settings is exactly: https://yoursite.com/wp-admin/admin.php?page=kickwp-channels
    • Make sure there are no extra spaces or characters
  3. "OAuth not configured or token expired"

    • Click "Connect to Kick.com" to reauthorize the application
    • Check if your OAuth application is properly configured in Kick Developer Portal
  4. "Unauthorized" error

    • Verify your OAuth scopes include channel:read and channel:edit
    • Try reconnecting your account
  5. "No channels found"

    • Verify you have channels on your Kick.com account
    • Check if your OAuth scopes allow access to channel data
    • Try searching for specific channels using the search function
  6. "Categories not loading"

    • Ensure your OAuth token has the necessary permissions
    • Check your internet connection and try refreshing
  7. Caching issues

    • Use the Refresh Channels button to clear cache
    • Adjust cache duration in settings
  8. Shortcode not working

    • Ensure you are connected via OAuth
    • Check that the channel slug is correct
    • Verify the shortcode syntax is correct
    • Try clearing your site cache if using a caching plugin
  9. "Untitled Stream" in channel cards

    • This has been fixed in version 2.1.0
    • The plugin now properly displays stream titles and channel descriptions
    • If you still see this, try refreshing the channels
  10. Edit button showing for all channels

    • This has been fixed in version 2.1.0
    • Edit buttons now only show for channels you own
    • "Your Channel" indicator shows which channels belong to you
  11. Broken images in channel cards

    • This has been fixed in version 2.1.0
    • Fallback avatars are now shown when images fail to load
    • Images have better error handling and loading states

Debug Mode

Enable WordPress debug mode to see detailed error messages:

define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);

File Structure

kickwp/
├── kickwp.php              # Main plugin file
├── assets/
│   ├── css/
│   │   └── admin.css       # Admin interface styles
│   └── js/
│       └── admin.js        # Admin interface functionality
└── README.md               # This file

Requirements

  • WordPress 5.0 or higher
  • PHP 7.4 or higher
  • Valid Kick.com OAuth 2.1 application with appropriate scopes
  • HTTPS connection (required for OAuth 2.1)

Changelog

Version 1.0.0

  • Initial release with basic API token authentication
  • Channel viewing and management
  • Metadata updates
  • Basic search functionality
  • Responsive admin interface

Support

For support and bug reports, please check the WordPress plugin directory or contact the plugin author.

License

This plugin is licensed under the GPL v2 or later.

Contributing

Contributions are welcome! Please submit pull requests or report issues on the plugin repository.


Note: This plugin requires a valid Kick.com API token with the appropriate permissions to function correctly. Make sure to keep your API token secure and never share it publicly.

About

WP Plugin using kick.com API it show you channel info in real time & more.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published