Upon all attempts to call PromptProductPurchase(), it gives me:
could not get product info because MarketplaceService:getProductInfo() failed because rawProductInfo was empty
What is causing this? Here is my client-side code. I'm not sure if server-side is involved, but it's there as well
Client-side
local player = game.Players.LocalPlayer
local productId = 176578601
local Market = game:GetService("MarketplaceService")
script.Parent.MouseButton1Click:connect(function()
Market:PromptProductPurchase(player, productId)
end)
Server-side
local marketplaceService = game:GetService("MarketplaceService")
local replicatedStorage = game:GetService("ReplicatedStorage")
local event = replicatedStorage:WaitForChild("RemoteEvent")
local ds = game:GetService("DataStoreService"):GetDataStore("PurchaseHistory")
local productIds = {176578601, 123456}
game.Players.PlayerAdded:connect(function()
print("start")
local DeveloperProducts = marketplaceService:GetDeveloperProductsAsync():GetCurrentPage()
for _, DevProductContainer in pairs(DeveloperProducts) do
for Field, Value in pairs(DevProductContainer) do
print(Field .. ": " .. Value)
end
print(" ")
end
print("end")
end)
marketplaceService.ProcessReceipt = function(receiptInfo)
for i, player in pairs(game.Players:GetPlayers()) do
if player.userId == receiptInfo.PlayerId then
if receiptInfo.ProductId == productIds[1] then --Donation
event:FireAllClients("Donation", player.Name)
local playerProductKey = "player_" .. receiptInfo.PlayerId .. "_testDonation_" .. receiptInfo.PurchaseId
ds:IncrementAsync(playerProductKey, 1)
else
print("nothing yet")
end
end
end
return Enum.ProductPurchaseDecision.PurchaseGranted
end
The client-side code is in a LocalScript, which is inside an ImageButton. The ImageButton is in a Frame, which is in a ScreenGui.
The server-side code is in a Script, which is in ServerScriptStorage.

2 comments
Hmmm... lol. I should probably double check that.
Yep, that was the problem. The real ID was 21410672... (Don't know where I got 176578601, might've been a sound or decal?)