Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

Everything you can see done in Iguana X’s graphical user interface is done via very simple APIs. One can call these APIs as web APIs but even more convenient is calling them from Lua using iguana.call.

Here’s an example that uses the API to create a component:

local Params= {}
Params.connected = false
Params.components = {}
Params.components[1] = {}
Params.components[1].description = "Created component"
Params.components[1].editable = true
Params.components[1].name = "C"..os.time()
Params.components[1].git = "https://bitbucket.org/interfaceware/blank-template.git"
iguana.call{api="/component/create", data=Params}

Be careful - every time this script runs it will create new component based on the GIT repository given. This gives you a taste of the power and simplicity of Iguana X APIs.

  • No labels