Builder
Get template V2
Builder
Get template V2
Gets the template for a new plugin of the given language initialized with the supplied plugin name.
GET
/api/v2/template/{language}/{pluginName}
language*
pluginName*
curl --request GET \
--url https://api.suborbital.network/api/v2/template/{language}/{pluginName}
{
"contents": " ```rust\n import { logInfo } from \"@suborbital/suborbital\"\n\n export function run(input: ArrayBuffer): ArrayBuffer {\n let inStr = String.UTF8.decode(input)\n\n let out = \"Hello there, \" + inStr\n\n return String.UTF8.encode(out)\n }\n ```\n",
"lang": "rust",
"tests": [
{
"description": "string",
"name": "string",
"payload": "string"
}
]
}
Path Parameters
languagerequired
string
The language toolchain used to configure the builder
pluginNamerequired
string
The plugin name (user-defined)
Query Parameters
namespace
string
Response
contentsrequired
string
The source code of a plugin
langrequired
string
The language of a plugin
tests
array
An array of tests
curl --request GET \
--url https://api.suborbital.network/api/v2/template/{language}/{pluginName}
{
"contents": " ```rust\n import { logInfo } from \"@suborbital/suborbital\"\n\n export function run(input: ArrayBuffer): ArrayBuffer {\n let inStr = String.UTF8.decode(input)\n\n let out = \"Hello there, \" + inStr\n\n return String.UTF8.encode(out)\n }\n ```\n",
"lang": "rust",
"tests": [
{
"description": "string",
"name": "string",
"payload": "string"
}
]
}