Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

API for trello works in studio but not the game?

I made a Trello API using nstrike159's script. It works in the studio and makes new cards when I clicked the button in the studio but, when I join the game it won't do anything. Any suggestions on how I could fix this? Filtering enabled is off by the way.

The in game logs say

  1. OnServerInvoke can only be implemented on the server
  2. OnServerEvent can only be used on the server

ServerLog: Content failed because HTTP 404

local Name = script.Parent.Parent.Information.LOLNAME
	local Evidence = script.Parent.Parent.Information.Evidence.Text
	local Witness = script.Parent.Parent.Information.Witnesses.Text
	local TimeDate = script.Parent.Parent.Information.TimeDate.Text
	local Addition = script.Parent.Parent.Information.AdditionalComments.Text
	local Updates = script.Parent.Parent.Information.Update.Text
api = require(game.Workspace.TrelloAPI)
local BoardID = api:GetBoardID("LVPD Detective Database v2")
local ListID = api:GetListID("Cases Pending Distribution",BoardID)

-----
script.Parent.MouseButton1Down:connect(function()
local player = game.Players.LocalPlayer	
local CardID = api:AddCard(player.Name .. "'s Report","Name of offender:"..(script.Parent.Parent.Information.LOLNAME.Text).. "Witnesses:"..(script.Parent.Parent.Information.Witnesses.Text).."Time and Date of offence:"..(script.Parent.Parent.Information.TimeDate.Text).."Additional Comments:"..(script.Parent.Parent.Information.AdditionalComments.Text).."Update?"..(script.Parent.Parent.Information.Update.Text),ListID)
	end)
end)

3 comments

0

where did you put the module?

0

Workspace.

0

HTTP 494 means Request Header is too large. Just an info.

1 answer

Usually when a script works in studio and doesn't work in a server is because it needs to be a LocalScript.

This discussion is preserved as it was. New answers, comments, and votes are closed.