How to fire an event when a player paid a developer product

How to fire an event when a player paid a developer product.

You can use this
:UserOwnsGamepassAsync(Player.UserId, GamepassId).

Pretty simple,
Just enter the correct parameters into MarketplaceService | Roblox Creator Documentation

This link should be what you are looking for: Developer Products | Roblox Creator Documentation

That is to prompt a purchase, they want to know when the play actually purchases it

They just updated their title to a different question, lol.
You going to want to use MarketplaceService.ProcessReceipt to process purchases.

oh that makes more sense now lol

Example you could use from me:

local Marketplace = game:GetService("MarketplaceService")


function getPlayerFromId(id)
	for i,v in pairs(game.Players:GetChildren()) do
		if v.userId == id then
			return v
	return nil


Marketplace.ProcessReceipt = function(receiptInfo)
	local playerId = receiptInfo.PlayerId
	local player = getPlayerFromId(playerId)
	local productId = receiptInfo.ProductId
	if productId == 85383517 then