=== Sponzar Connect ===
Contributors: sponzar
Tags: sponzar, creator economy, content, monetization, api, headless cms
Requires at least: 5.6
Tested up to: 6.5
Stable tag: 1.0.0
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Embed your Sponzar content, series, music, podcasts, and creator profiles on any WordPress site.

== Description ==

**Sponzar Connect** turns your WordPress site into a storefront for your Sponzar content. Display posts, micro-dramas, TV series, music albums, podcasts, and creator profiles using simple shortcodes.

= Features =

* **Content Grid** — Display your Sponzar posts with thumbnails, type badges, and lock indicators
* **Series Grid** — Show your micro-dramas, TV series, music albums, and podcasts in beautiful cards
* **Series Detail** — Full series page with episode list and unlock status
* **Creator Directory** — Browse creators with avatars, subscriber counts, and subscription plans
* **API Caching** — 15-minute transient cache to minimize API calls
* **Dark Mode** — Automatic dark mode support via `prefers-color-scheme`
* **Responsive** — Looks great on all devices

= Shortcodes =

* `[sponzar_content]` — Grid of posts (attributes: type, access, per_page, columns, creator_id)
* `[sponzar_series]` — Grid of series (attributes: type, per_page, columns, creator_id)
* `[sponzar_series_detail id="X"]` — Single series with episodes
* `[sponzar_creators]` — Creator directory (attributes: search, category, per_page, columns)

= Series Types =

* `micro_drama` — Short-form drama series
* `tv_series` — Full-length TV shows
* `music_album` — Music albums with tracks
* `podcast` — Podcast series with episodes

== Installation ==

1. Upload the `sponzar-connect` folder to `/wp-content/plugins/`
2. Activate the plugin via the Plugins screen
3. Go to **Settings → Sponzar** and enter your API key
4. Click **Test Connection** to verify
5. Add shortcodes to any page or post

= Getting an API Key =

1. Log in to your Sponzar admin panel
2. Navigate to **API Keys** in the sidebar
3. Click **Generate Key** and copy the `sk_live_...` key
4. Paste it into the plugin settings

== Frequently Asked Questions ==

= Where do I get an API key? =
Log in to your Sponzar admin panel and navigate to API Keys. Generate a new key with the permissions you need.

= What permissions does my API key need? =
For content display, you need `content.read`. For series, also `content.read`. For creators, `creators.read`. Use `*` for full access.

= Can I cache API responses? =
Yes. The plugin caches responses for 15 minutes by default. You can change this in Settings → Sponzar, or click "Clear Cache" to refresh immediately.

= Does it support dark mode? =
Yes. The plugin automatically detects your system/browser dark mode preference and adjusts styles accordingly.

== Changelog ==

= 1.0.0 =
* Initial release
* Content grid shortcode
* Series grid and detail shortcodes
* Creator directory shortcode
* Admin settings page with connection testing
* Transient caching for API responses
* Responsive design with dark mode support
