local H=game:GetService("\082\101\112\108\105\099\097\116\101\100\083\116\111\114\097\103\101")local u=require((H:WaitForChild("\080\114\111\106\101\099\116")):WaitForChild("\083\101\114\118\101\114\083\099\114\105\112\116\083\101\114\118\105\099\101"))local z=u:GetResource("\083\101\114\118\105\099\101\046\083\116\111\114\101\083\101\114\118\105\099\101")return{Keyword="\099\111\109\112\108\101\116\101\116\114\097\110\115\097\099\116\105\111\110",Description="\067\111\109\112\108\101\116\101\115 \097 \109\111\099\107 \116\114\097\110\115\097\099\116\105\111\110 \097 \115\101\116 \111\102 \112\108\097\121\101\114\115\046",Arguments={{Type="\110\101\120\117\115\065\100\109\105\110\080\108\097\121\101\114\115",Name="\080\108\097\121\101\114\115";Description="\080\108\097\121\101\114\115 \116\111 \099\111\109\112\108\101\116\101 \116\114\097\110\115\097\099\116\105\111\110\115\046"};{Type="\103\097\109\101\083\116\111\114\101\084\114\097\110\115\097\099\116\105\111\110",Name="\084\114\097\110\115\097\099\116\105\111\110",Description="\084\114\097\110\115\097\099\116\105\111\110 \116\111 \112\101\114\102\111\114\109\046"}};Run=function(H,u,A,Z)local W=""for H,u in pairs(A)do if W~=""then W=W.."\n"end if z:CompleteTransaction(u,Z)then W=W..("\084\114\097\110\115\097\099\116\105\111\110 \102\111\114 "..(u.Name.." \119\111\114\107\101\100\046"))else W=W..("\084\114\097\110\115\097\099\116\105\111\110 \102\111\114 "..(u.Name.." \102\097\105\108\101\100\046"))end end return W end}

--[[
TheNexusAvenger

Data for a command for completing mock transactions.
--]]

local ReplicatedStorage = game:GetService("ReplicatedStorage")

local ServerScriptServiceProject = require(ReplicatedStorage:WaitForChild("Project"):WaitForChild("ServerScriptService"))
local StoreService = ServerScriptServiceProject:GetResource("Service.StoreService")



return {
    Keyword = "completetransaction",
    Description = "Completes a mock transaction a set of players.",
    Arguments = {
        {
            Type = "nexusAdminPlayers",
            Name = "Players",
            Description = "Players to complete transactions.",
        },
        {
            Type = "gameStoreTransaction",
            Name = "Transaction",
            Description = "Transaction to perform.",
        },
    },
    Run = function(self,CommandContext,Players,TransactionId)
        local Result = ""
        for _,Player in pairs(Players) do
            if Result ~= "" then Result = Result.."\n" end
            if StoreService:CompleteTransaction(Player,TransactionId) then
                Result = Result.."Transaction for "..Player.Name.." worked."
            else
                Result = Result.."Transaction for "..Player.Name.." failed."
            end
        end
        return Result
    end
}