Not to big a fix here but in my game I have a part, when the part is touched the player can donate for 20 robux, somehow my code isn't working, there have been no errors in output. The script is a local script. Its parent is the brick the player touches. Its a really simple script, I have zero clue why it didn't work, thank you.
local id = 1113057306
script.Parent.Touched:Connect(function()
game:GetService("MarketplaceService"):PromptProductPurchase(game.Players.LocalPlayer,id)
end)

4 comments
you might have misspelled id, or Touched event doesn't work in a local script. Use a remote event and fireClient it.
Is it a gamepass or developer product?
dev product
Local Scripts don't work on Workspace