Login/Register
Installatron Plugin
API Documentation

Create Template

POST /installs/{id}/template

Create a template from an install.

Parameters


API

/installs/{id}/template
API endpoint.

{id} is the internal ID of the install to create the template from.
POST
Method.

Required parameters

name
string
Title of the template.
(eg.
10 Popular Plugins
)

Optional parameters

desc
string
Short description of the template.
(eg.
Adds demo content.
)

default is no description
scope
enum
Determine which users will have access to the template and in what form the template will be available.
  • user
    = Make this template only accessible to the user that created the template. This template is then available as a content option when this user is installing this type of application in the future. This option is only available to users with websites.
  • admin
    = Make this template available to everyone as a content option for this application.
  • app
    = Make this template available to everyone as a new, separate application in the Applications Browser tab.


default is
admin
image
TODO
(When scope =
admin
) Image used to represent this template when selecting it as a content option.
(1024x640 PNG or 2048x1280 HiDPI PNG, less than 1MB)

default is an automatically generated screenshot of the website that the template is being generated from
icon
TODO
(When scope =
app
) Icon to use for this template as application in the Applications Browser tab.
(512x512 PNG, less than 300KB)

default is TODO
appcategory
enum
(When scope =
app
) Category this new application belongs to.
  • _categories_contentmanagementsystems
    = Content Management Systems
  • _categories_communitysoftware
    = Community Software
  • _categories_ecommerceandbusiness
    = eCommerce and Business
  • _categories_imagesandfiles
    = Images and Files
  • _categories_surveysandstatistics
    Surveys and Statistics
  • _categories_miscellaneous
    = Miscellaneous


default is
_categories_contentmanagementsystems
apptype
enum
(When scope =
app
) Type of application this is.
  • _types_administration
    = Administration
  • _types_adverts
    = Adverts
  • _types_blog
    = Blog
  • _types_business
    = Business
  • _types_bookmarks
    = Bookmarks
  • _types_calendar
    = Calendar
  • _types_chat
    = Chat
  • _types_clock
    = Clock
  • _types_cms
    = CMS
  • _types_crm
    = CRM
  • _types_ecards
    = eCards
  • _types_ecommerce
    = eCommerce
  • _types_education
    = Education
  • _types_email
    = eMail
  • _types_faqs
    = FAQS
  • _types_files
    = Files
  • _types_forms
    = Forms
  • _types_forum
    = Forum
  • _types_framework
    = Framework
  • _types_gallery
    = Gallery
  • _types_genealogy
    = Genealogy
  • _types_groupware
    = Groupware
  • _types_guestbook
    = Guestbook
  • _types_invoicing
    = Invoicing
  • _types_pollsurvey
    = Poll/Survey
  • _types_portal
    = Portal
  • _types_projects
    = Projects
  • _types_rss
    = RSS
  • _types_search
    = Search
  • _types_statistics
    = Statistics
  • _types_support
    = Support
  • _types_tickets
    = Tickets
  • _types_tool
    = Tool
  • _types_wiki
    = Wiki
  • _types_vpn
    = VPN
  • _types_addon
    = Addon
  • _types_plugin
    = Plugin
  • _types_theme
    = Theme
  • _types_securityrelease
    Security Release
  • _types_majorversion
    = Major Version
  • _types_betarelease
    = Beta Release
  • _types_addendum
    = Addendum


default is TODO
ss1
TODO
(When scope =
app
) Screenshot #1.
(1024x640 PNG or 2048x1280 HiDPI PNG, less than 1MB)

default is screenshot #1
ss2
TODO
(When scope =
app
) Screenshot #2.
(1024x640 PNG or 2048x1280 HiDPI PNG, less than 1MB)

default is screenshot #2
ss3
TODO
(When scope =
app
) Screenshot #3.
(1024x640 PNG or 2048x1280 HiDPI PNG, less than 1MB)

default is screenshot #3
ss4
TODO
(When scope =
app
) Screenshot #4.
(1024x640 PNG or 2048x1280 HiDPI PNG, less than 1MB)

default is no screenshot #4
longdesc
string
(When scope =
app
) A longer, detailed description for this application. Can include HTML.

default is no long description
linksite
string
(When scope =
app
) URL to website about this new application.

default is no link
linkdocs
string
(When scope =
app
) URL to documentation for this application.

default is no link
linkfaq
string
(When scope =
app
) URL to FAQ for this application.

default is no link
linksupport
string
(When scope =
app
) URL to support for this application.

default is no link
user
string
Change scope to this server or control panel admin, reseller, or user.

default is the current user

Special parameters

background
boolean
Determines whether a task is run as a foreground or background process.
  • false
    = No backgrounding (the task will complete before returning to your script or prompt).
  • true
    = Return to your script after preliminary error checking is completed (disk space, PHP requirements, etc) and then perform the rest of the task on a different process.
Use the GET /tasks API to query the status of a background task.

default is
false
dryrun
enum
Perform a test run of this API call: run the tests, check connections to the database server and remote locations, but don't actually perform this task itself. This is just a test-run to make sure that when it is run for real that there is nothing to stop it from working.
  • none
    = No dry run.
  • all
    = Check all input values and test all connections.
  • input
    = Check only the input values.


default is
none

Response


Response

status
int
HTTP status code describing the result of the request.

200
for Success.
All other numbers represent errors which are described in the errcode output below.
result
boolean
true
= Success.
false
= Failure.
errcode
string
status code 200
complete_dryrun
dryrun was enabled and finished without error.
status code 404
template_not_found
user_not_found
The specified user could not be found in the system control panel.
errfield
enum
If the cause of an error was an incorrect field value then this will show the ID of the field.
(eg.
login
,
passwd
,
email
)
message
string
Message describing the result of the request. Do not rely on this to determine the success or failure of the request.
data


template_scope
enum
Selects which users will have access to the template and in what form the template will be available.
  • user
    - Make this template only accessible to the user that created the template. This template is then available as a content option when this user is installing this type of application in the future. This option is only available to users with websites.
  • admin
    - Make this template available to everyone as a content option for this application.
  • app
    - Make this template available to everyone as a new, separate application in the Applications Browser tab.
template_application
string
Internal application ID of the application this template was created from.
(eg.
wordpress
,
drupal
,
magento
)
template_desc
string
Short description of the template.
(eg.
Adds demo content.
)
template_filename
string
Filename of this Installatron Template archive.
(eg.
template_wordpress_My-Template-Example_2025-01-01_12-01-01
)
template_name
string
Template's title.
(eg.
My Template Example
)
template_time
int
Date and time when the template was created (as a Unix timestamp).
(eg.
1234567890
)
template_linkdocs
string
(When template_scope =
app
)
URL to the documentation for this new application.
(eg.
https://website.com/mynewapplication/docs
)
template_linkfaq
string
(When template_scope =
app
)
URL to the frequently asked questions (FAQ) page for this new application.
(eg.
https://website.com/newapplication/faq
)
template_linksite
string
(When template_scope =
app
)
URL to the website of this new application.
(eg.
https://website.com/newapplication
)
template_linksupport
string
(When template_scope =
app
)
URL to support for this new application.
(eg.
https://website.com/newapplication/forum
)
template_longdesc
string
(When template_scope =
app
)
A longer, detailed description for this application.
template_appcategory
enum
(When template_scope =
app
)
The category this new application belongs to.
  • _categories_contentmanagementsystems
    = Content Management Systems
  • _categories_communitysoftware
    = Community Software
  • _categories_ecommerceandbusiness
    = eCommerce and Business
  • _categories_imagesandfiles
    = Images and Files
  • _categories_surveysandstatistics
    Surveys and Statistics
  • _categories_miscellaneous
    = Miscellaneous
default is
_categories_contentmanagementsystems
template_apptype
enum
(When template_scope =
app
)
The type of application this is.
  • _types_administration
    = Administration
  • _types_adverts
    = Adverts
  • _types_blog
    = Blog
  • _types_business
    = Business
  • _types_bookmarks
    = Bookmarks
  • _types_calendar
    = Calendar
  • _types_chat
    = Chat
  • _types_clock
    = Clock
  • _types_cms
    = CMS
  • _types_crm
    = CRM
  • _types_ecards
    = eCards
  • _types_ecommerce
    = eCommerce
  • _types_education
    = Education
  • _types_email
    = eMail
  • _types_faqs
    = FAQS
  • _types_files
    = Files
  • _types_forms
    = Forms
  • _types_forum
    = Forum
  • _types_framework
    = Framework
  • _types_gallery
    = Gallery
  • _types_genealogy
    = Genealogy
  • _types_groupware
    = Groupware
  • _types_guestbook
    = Guestbook
  • _types_invoicing
    = Invoicing
  • _types_pollsurvey
    = Poll/Survey
  • _types_portal
    = Portal
  • _types_projects
    = Projects
  • _types_rss
    = RSS
  • _types_search
    = Search
  • _types_statistics
    = Statistics
  • _types_support
    = Support
  • _types_tickets
    = Tickets
  • _types_tool
    = Tool
  • _types_wiki
    = Wiki
  • _types_vpn
    = VPN
  • _types_addon
    = Addon
  • _types_plugin
    = Plugin
  • _types_theme
    = Theme
  • _types_securityrelease
    Security Release
  • _types_majorversion
    = Major Version
  • _types_betarelease
    = Beta Release
  • _types_addendum
    = Addendum

Full Examples

Example: Create a template from the install with ID 1234567890abcdefghij12345

Method: curl
Installatron Product: Installatron Plugin (switch to Installatron Server)
$cpapi=https://{USER}:{PASS}@{SERVER_IP}:2083/3rdparty/installatron/index.cgi?     # cpanel
#$cpapi=https://{USER}:{PASS}@{SERVER_IP}:2087/3rdparty/installatron/index.cgi?    # whm
#$cpapi=https://{USER}:{PASS}@{SERVER_IP}:2222/CMD_PLUGINS/installatron/index.raw? # directadmin

curl -X POST $cpapi/installs/1234567890abcdefghij12345/template \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json' \
    -d '
        {
            "name": "Template Example"
        }
       '
 
Response: json
{
    "status": 200,
    "result": true,
    "message": "The task is complete.\n",
    "data": {
        "template_filename": "template_wordpress_My-example-template_2025-05-04_03-02-00",
        "template_name": "My example template",
        "template_desc": "My example WordPress blog template",
        "template_scope": "admin",
        "template_time": 1234567890,
        "id": "1234567890abcdefghij12345",
        "file": "/root/.appdata/templates/1234567890abcdefghij12345",
        "agent": "10.0.0",
        "application": "wordpress",
        "autoup": "none",
        "autoup_backup": "all",
        "autoup_plugins": "custom",
        "autoup_themes": "none",
        "autobk": "schedule",
        "autobk_schedule": "weeklymonthly",
        "bkloc": "local",
        "cache_archive": 12345678,
        "cache_files": 12345678,
        "cache_preview": 12345,
        "cache_tables": 123456,
        "files": [
            ".htaccess",
            ".maintenance",
            "index.php",
            "it-api.php",
            "license.txt",
            "liesmich.html",
            "readme.html",
            "wp-activate.php",
            "wp-admin",
            "wp-app.php",
            "wp-blog-header.php",
            "wp-comments-post.php",
            "wp-config.php",
            "wp-config-local.php",
            "wp-config-sample.php",
            "wp-content",
            "wp-cron.php",
            "wp-includes",
            "wp-links-opml.php",
            "wp-load.php",
            "wp-login.php",
            "wp-settings.php",
            "wp-signup.php",
            "wp-trackback.php",
            "wp-mail.php",
            "xmlrpc.php"
        ],
        "notification": [
            "backup",
            "backup_error",
            "clone",
            "clone_error",
            "install",
            "install_error",
            "plugin_update",
            "plugin_update_available",
            "plugin_update_error",
            "restore",
            "restore_error",
            "sync",
            "sync_error",
            "template",
            "template_error",
            "update",
            "update_available",
            "update_error"
        ],
        "path": "/home/useraccountname/public_html/blog",
        "plugins": [
            {
                "id": "akismet",
                "version": "5.3.6",
                "activated": false,
                "autoup": "all"
            },
            {
                "id": "limit-login-attempts-reloaded",
                "version": "2.26.18",
                "activated": true,
                "autoup": "all"
            }
        ],
        "tables": [
            "wp_commentmeta",
            "wp_comments",
            "wp_links",
            "wp_options",
            "wp_postmeta",
            "wp_posts",
            "wp_term_relationships",
            "wp_term_taxonomy",
            "wp_termmeta",
            "wp_terms",
            "wp_usermeta",
            "wp_users"
        ],
        "themes": [
            {
                "id": "twentytwentythree",
                "version": "1.6",
                "active": false,
                "autoup": "all"
            },
            {
                "id": "twentytwentyfive",
                "version": "1.1",
                "active": false,
                "autoup": "all"
            }
        ],
        "time_created": 1234567890,
        "title": "My example blog",
        "url": "https://website.com/blog",
        "user": "useraccountname",
        "version": "6.7.8",
        "vhost": "https://website.com",
        "email": "useraccountname@website.com",
        "language": "en",
        "login": "admin123",
        "limitloginattempts": "yes",
        "sitetitle": "My example blog",
        "sitetagline": "Just another WordPress site",
        "twofactor": "no"
    }
}


© 2004 - 2025 Installatron LLC. All rights reserved. Privacy Policy.