Developer product says it's not on sale-even though it is

I’m working on a donation system for my game. I thought this would be simple, and normally it should be; but then I ran into a glitch that had me staring helplessly at the screen for 30 minutes.

Whenever I try to purchase one of the donations, it tells me the developer product is not currently for sale.

I looked for solutions online and found out that most common cause of this error is using PromptPurchase instead of PromptProductPurchase. I noticed I made that mistake, but then I fixed that. It was still broken; the output was blank.

I then:

  1. Double checked all the IDs to make sure they were entered properly (they were)
  2. Double checked the arguments I was passing over in the PromptProductPurchase function along with checking the API reference to make sure I was sending over the right things (I was)

At this point I’ve run out of ideas. Can anyone figure out what’s going on?

local rst = game:GetService("ReplicatedStorage")
local mks = game:GetService("MarketplaceService")

local assetsFolder = rst.Assets

local plr = game.Players.LocalPlayer

local ui, donateUI, viewButton = nil, nil, nil

local donateOptionButtons = {}

local uiOpen = false

local productIDs = {
	1185279848,
	1185279869,
	1185279887,
	1185279903,
	1185279915,
	1185279930
}

local productInfoDictionary = {}

local donationButtons = {}

local totalDonationOptions = #productIDs

local function toggleUI()
	uiOpen = not uiOpen
	donateUI.Visible = uiOpen
end

local function close()
	donateUI.Visible = false
end

for i=1, totalDonationOptions do
	local button = assetsFolder.UI.Donation.DonationOption:Clone()
	button.LayoutOrder = i
	
	local productID = productIDs[i]
	print(productID)
	
	button.MouseButton1Click:Connect(function()
		mks:PromptProductPurchase(plr, productID)
	end)
	
	donateOptionButtons[i] = button
	
	local productInfo = mks:GetProductInfo(productID, Enum.InfoType.Product)
	productInfoDictionary[i] = productInfo
	
	button.Text = "Donate R$"..productInfo.PriceInRobux
end

ui = plr.PlayerGui:WaitForChild("UI")

donateUI = ui.Donation
viewButton = ui.DonateButton

for i,button in pairs(donateOptionButtons) do
	button.Parent = donateUI.Options
end

donateUI.Options.UIGridLayout.CellSize = UDim2.new(1, 0, 1/totalDonationOptions, -5)

donateUI.Close.MouseButton1Down:Connect(close)
viewButton.MouseButton1Down:Connect(toggleUI)

If the products were not made in the current game you’ll need to allow third-party sales in security game settings.

2 Likes

I checked just now and that’s not it; the products were created under the same game.

Try enabling the setting and testing anyway since there seem to be weird glitches in where Roblox doesn’t notice this.

Also is this same game the game with the script.

Yes, same game with the same script and developer products.

And sure, I’ll try enabling third-party sales anyways. Crossing my fingers there’ll be a miracle.

EDIT: Didn’t work…

EDIT 2: I am very close to screaming

please

Wrong asset id it seems as I looked it up on an api and it says its a Roblox place by someone.

1 Like

That’s strange? I got the IDs from the developer product page under game configuration. Is there a different type of ID I’m supposed to use?

image

By any chance do you know the universe id of the game since if you do I have an api that lists the dev products.

Yup, found it. Here it is: 2601492419

Not good:

{
	"errors": [
		{
			"code": 403,
			"message": "Asset type does not match requested type"
		}
	],
	"requestId": "637601752201872584",
	"IsHashDynamic": false,
	"IsCopyrightProtected": false,
	"isArchived": false
}

Do you mind printing the info in the getproduct info.

1 Like

wh

what

t

Um, yea, I can do that. Give me a moment…

This error is quite weird, never seen it before.

1 Like

If you go in game settings there is one there.

That’s interesting. Perhaps I got the unlucky draw and encountered a rare bug?

Here’s the product info. Something’s definitely wrong, a bunch of IDs are displaying as 0, even essential ones like the creator ID.

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:40:52.3246618Z",
	["Creator"] =  {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 5",
	["PriceInRobux"] = 5,
	["ProductId"] = 1185279848,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398769,
	["Updated"] = "2021-06-25T03:50:42.2733242Z"
}

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:41:00.5769442Z",
	["Creator"] =  {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 25",
	["PriceInRobux"] = 25,
	["ProductId"] = 1185279869,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398771,
	["Updated"] = "2021-06-25T03:51:04.3225939Z"
}

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:41:05.2800486Z",
	["Creator"] = {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 50",
	["PriceInRobux"] = 50,
	["ProductId"] = 1185279887,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398773,
	["Updated"] = "2021-06-25T03:50:49.9434339Z"
}

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:41:11.7025062Z",
	["Creator"] =  {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 100",
	["PriceInRobux"] = 100,
	["ProductId"] = 1185279903,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398774,
	["Updated"] = "2021-06-25T03:50:56.1627175Z"
}

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:41:18.1191754Z",
	["Creator"] =  {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 500",
	["PriceInRobux"] = 500,
	["ProductId"] = 1185279915,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398777,
	["Updated"] = "2021-06-25T03:51:09.015715Z"
}

{
	["AssetId"] = 0,
	["AssetTypeId"] = 0,
	["Created"] = "2021-06-25T01:41:24.9677851Z",
	["Creator"] =  {["CreatorTargetId"] = 0, ["Id"] = 0},
	["IconImageAssetId"] = 0,
	["IsForSale"] = false,
	["IsLimited"] = false,
	["IsLimitedUnique"] = false,
	["IsNew"] = true,
	["IsPublicDomain"] = false,
	["MinimumMembershipLevel"] = 0,
	["Name"] = "Donation - 1000",
	["PriceInRobux"] = 1000,
	["ProductId"] = 1185279930,
	["ProductType"] = "Developer Product",
	["TargetId"] = 8398778,
	["Updated"] = "2021-06-25T03:51:13.003072Z"
}

Creator ids only appear for assets, I believe.

1 Like

Ah, so that part’s normal. That much is good, at least.

Could this be an internal issue? From what I’ve seen there’s nothing I can do about this except just reupload the developer products. Which I might actually try, now that I think about it…

Do they appear to work in a real game or no, just remember Roblox just had server issues so this may be a side effect of this.

1 Like

I just checked and the same exact thing happens in real servers.

Could it be that these were made during the big Roblox server problems today.

1 Like