Skip to content

PayPerView Plugin

Daniel Neto edited this page Nov 12, 2026 · 16 revisions

PayPerView plugin

The Pay-Per-View (PPV) plugin lets you sell access to a video for a limited time, for example 48 hours. Buyers pay with the balance of their wallet.

Follow the visual rental example for the editor, automatic video inclusion, buyer checkout and a completed Stripe test payment. For the difference between a rental and membership, start with the access comparison.

PayPerView is a paid add-on, available from the AVideo plugin marketplace. For lives, see PayPerView Live.

Configure mandatory playback access rules to require particular memberships. With the current PayPerView update, allowRentalOfGroupRestrictedVideos is on by default: an eligible rental of a title can also satisfy its mandatory rule. Turn it off if the category must remain exclusive to members even when a title has a rental plan. Free playback with ads does not satisfy the rule. Users missing the required group see an Unlock this content page that lists the PPV and subscription plans giving that group, plus the video's eligible rental when the option is on. Membership and ad-free benefits remain separate decisions.


🎯 What Can You Do with PPV?

  • Set a price and an access time (in hours) for each plan, and attach plans to videos.
  • Let free videos play with ads, and sell an ad-free, paid access.
  • Let creators make their own PPV plans and sell their own videos.
  • Split each sale between the site admin and the creator automatically.
  • See sales reports and decision reports (who to win back, who to remind).

💳 Payment Gateways

The buyer pays from their YPTWallet balance. If the balance is too low, the buyer adds funds with any gateway enabled in the wallet (PayPal, Stripe, Authorize.Net, Bitcoin...).

So you need: YPTWallet enabled, at least one gateway configured, and PayPerView enabled with its tables installed (Admin Panel → Plugins → PayPerView → Install tables).


💰 How Are Payments Handled?

🔹 Option 1: All Payments Go to the Site Admin

  • The real money from the gateways goes into the site owner's payment account.
  • Inside AVideo, the price moves from the buyer's wallet to the video owner's wallet (minus the admin split, see below).
  • Creators get their money by requesting a withdrawal. PayPal can pay withdrawals automatically if configured.

🔹 Option 2: Payments Go Directly to Creators (Stripe Required)

  • Turn on usersCanCreatePPVPlans (Users Can Create PPV Plans) and allowStripe.
  • Each creator opens Edit PayPerView in the left menu, tab Payment Configurations, and enters their own Stripe keys (Publishablekey, Restrictedkey, SigningSecret).
  • Buyers of that creator's videos pay into the creator's Stripe account.
  • Note: the admin does not receive a share in this mode.

See also options for paying content producers.


🤝 PPV Revenue Split Between Admin and Creators (Optional)

✅ Requirements

  • YPTWallet and PayPerView enabled.
  • An admin account to set the split (only admins see the split fields).

🛠️ Setup Guide

  1. Go to Admin Panel → Plugins, find PayPerView and click Edit parameters.
  2. To let creators sell their own videos, turn on:
    • usersCanCreatePPVPlans (Users Can Create PPV Plans): users who can upload can create PPV plans.
    • usersCanSetPPV (Users can set PPV plans on his videos): users can attach PPV plans to their videos.
  3. Optional: rename the split labels with adminSplitlabel (default Admin Split) and publisherSplitlabel (default Publisher Split).
  4. When creating or editing a PPV plan, choose the Admin Split (for example 30%) and the Publisher Split (for example 70%).

🔄 How Does It Work?

  • When a user buys, the full price goes to the video owner's wallet.
  • The wallet then moves the Admin Split percentage from the owner's wallet to the site owner's wallet.
  • Only the Admin Split moves money. Set the Publisher Split to the rest (so both add up to 100%) to keep the plan clear.

⚙️ Additional Plugin Options

Option What it does Default
allowFreePlayWithAds Videos play for free with ads; buying PPV removes the ads. Videos marked as only for paid users still require a purchase. off
onlyPlayVideosWithPayPerViewActive A viewer who is not allowed to watch a video is sent to the PPV buy page on
doNotShowAdsForPaidUsers Buyers see no ads on the video they bought on
hideActionButton Hides the PPV buy button on video pages off
userGroupPPVGrantsSpecificVideoOnly For plans attached to a user group: paying for one video gives access to that video only. Off: access to all videos of the group. on
allowRentalOfGroupRestrictedVideos Videos under a mandatory playback rule can also be rented one by one, when they are in an active rental plan. The rental unlocks only that video. A saved off setting is preserved after updating. on
payPerViewBuyLabel Text of the buy button Buy Now

🧑‍💻 How to Configure PPV

  1. Go to Admin Panel → Plugins, find PayPerView and click Edit (creators: Edit PayPerView in the left menu).

  2. Open the PPV Plans tab and create a plan:

    • Name and Description
    • Plan Price
    • How many hours the access lasts
    • Status
    • Admin Split / Publisher Split (admins only)
    • Optional, tab User Groups (admins only): sell a group pass. Leave this empty for a direct-video rental. A group plan and a single-video purchase from that plan can have different scopes; see group passes.

    PayPerView editor with PPV Plans selected and the Academy 48-hour plan loaded

  3. Open the PPV Videos tab and click the plan you want to fill. Then:

    • Turn the switch on beside each video that must be paid with this plan. Each switch is saved right away; there is no Save button.
    • Use the search box (title or video ID), the category list and All / In plan / Not in plan to find videos. Clear filters returns to the full list.
    • To change many videos at once, tick their boxes to show Add selected and Remove selected. Select this page selects only the visible page; Clear unticks them.
    • Open Bulk actions → Add all matching or Remove all matching to change every video matching the current search and category, on all pages. Review the count and plan in the confirmation before continuing.
    • The selected plan shows whether a change is saving, saved automatically, or failed. Controls pause while a save is pending. If the list fails to load, click Retry; bulk actions stay unavailable until it loads.
    • Plans that give access to user groups appear greyed out: their videos come from the groups, not from this list.

    Removing a video from a plan stops selling it with that plan; rentals already bought stay in the purchase history. You can also open a single video in My Videos and click PPV Plans to switch its plans on or off.

Actual video switch saving inclusion in the selected rental plan

MP4 with playback controls · Still image. The recording changes only the demonstration lesson and finishes with it included; switches save immediately.

Buy and recognize success

The viewer signs in, opens the video, checks the title, price and duration, and chooses a payment method. A 48-hour plan is a rental period, not automatic renewal. To prevent free-with-ads access to a paid-only title, save Only Paid Users Can see in the video's Privacy tab.

Rental checkout with the Academy lesson, $4.99 price, 48-hour duration and gateway buttons

Watch the completed Stripe test rental (MP4) · Payment confirmed, still image

Wait for Payment confirmed and Watch Now. If payment is approved but the rental is pending, use Check payment status rather than submitting another payment. Check Wallet → History and the purchase record. A credited wallet does not by itself prove that the rental finished; complete the purchase with that balance if prompted.

The PPV Users tab lists the users. Click the button on a user's row to see and edit their PPV plans.


📊 Reports

Go to Admin Panel → Plugins, find PayPerView and click one of the buttons under its name:

  • Reports: revenue, sales, top plans, top videos and top buyers for a date range.
  • Decision reports: lists of customers you can act on, such as people to win back or to remind before their access ends.

Decision reports

  1. At the top, choose the Period (7 to 90 days) and, if you want, a single Plan. Every number on the page follows these two filters.
  2. Click a card to see the customers behind it:
    • Win back: their access ended in the period and they did not buy again. Send them a comeback offer.
    • About to expire: their access ends in the period and they have not renewed yet. Remind them before they lose access.
    • Paying, not watching: their access is active, but they did not watch any video in the period. They are the most likely to leave at renewal time.
    • Renewal rate: out of the accesses that ended in the period, how many were followed by a new purchase.
  3. In the customer list, use Copy e-mails to paste the addresses into your e-mail tool, or Export CSV to open the full list (name, e-mail, phone, plan, dates and total paid) in a spreadsheet.
  4. Check Plan performance to compare sales, new customers and the renewal rate of each plan. Click a plan to filter the whole page.
  5. Check New and returning buyers to see, month by month, whether you are growing with new customers or relying on returning ones.

Click the ? button next to the filters for a guided tour of the page.

Good to know:

  • Only admins can open these reports, because the lists include e-mails and phone numbers.
  • Customers count only if they paid for at least one purchase. A free access you grant still counts as access, so those customers are not listed as lost.
  • A customer counts as renewed if they bought any plan again, not only the same plan.
  • Paying, not watching uses the site's watch history. If your site keeps less history than the chosen period, the page tells you how far back it can see.

🧪 How to Test

When an administrator changes the end date of a customer's plan, saving it must also update the access used for the plan's video groups. Test both shortening and extending an existing purchase. For purchases affected before the expiration fix, the administrator can run the batch repair described in the technical payments guide. It checks all plan purchases and synchronizes the internal access timestamp with each recorded end date and timezone, with a preview and backup. There is no need to edit each student's account individually. Updating the plugin alone does not run this maintenance command automatically.

The plan history and its Active/Expired totals use the saved access timestamp. The timezone shown beside each plan's expiration belongs to that purchase. A different server or viewer timezone must not make a plan appear expired before its actual end time. Updating the expiration also updates its internal timestamp and the timezone used to interpret the edited date.

  • Create a plan with a low price and attach it to a video.
  • With a normal user account, add funds to the wallet and buy the video.
  • Check that the video plays, and check the wallets of the buyer, the video owner and the site owner.
  • Check the transactions in the wallet History.

Common questions

Why is the buy button missing? Check that the plan is active and attached to the video in PPV Videos, that hideActionButton is off, and whether the user already has access.

Why did the purchase fail? Check the payment status, wallet credit and rental activation separately. Wallet purchases need sufficient balance; supported integrated checkouts can fund and activate the rental in one flow. Do not charge again if the existing payment was approved.

Why was payment recorded but playback denied? Check the purchase and its expiration in PPV Users, the account used, and the video's privacy and user groups.

For a mandatory playback rule with single-title rentals enabled, the rental, its video link and its PPV plan must all remain active, and the rental must not have expired. Wallet and direct-card checkouts reject ineligible selections before payment; Stripe wallet funding, PayPal and Bitcoin checkout details use the same eligibility check. A verified payment that can no longer fulfill the rental keeps its wallet credit for resolution rather than charging again.

Does PPV require the selected groups too? Ordinary visibility groups and plugin access are alternative ways to grant access. A mandatory playback group rule is checked first and cannot be replaced by a normal rental, unless allowRentalOfGroupRestrictedVideos is on: then a rental of that video also passes the rule. Test the complete combination with a normal buyer account.

I do not see the Decision reports button. Update the PayPerView plugin to the latest version, then reload the Plugins page.

The exported CSV opens in a single column in Excel. Open Excel first, then use Data → From Text/CSV to import the file and pick the separator shown in the preview.

Clone this wiki locally