Get templates by organization and template name
CoderSessionTokenCoder-Session-Token<token>organization*stringOrganization ID
uuidtemplatename*stringTemplate name
OK
application/json- response
active_user_count?integerActiveUserCount is set to -1 when loading.
active_version_id?stringuuidactivity_bump_ms?integeragents_allowed?booleanallow_user_autostart?booleanAllowUserAutostart and AllowUserAutostop are Premium features. Their values are only used if your license is entitled to use the advanced template scheduling feature.
allow_user_autostop?booleanallow_user_cancel_workspace_jobs?booleanallow_workspace_renames?booleanAllowWorkspaceRenames permits users to rename workspaces built from this template. Renaming can be destructive for templates whose Terraform references the workspace name.
autostart_requirement?autostop_requirement?AutostopRequirement and AutostartRequirement are Premium features. Their values are only used if your license is entitled to use the advanced template scheduling feature.
build_time_stats?cors_behavior?codersdk.CORSBehavior"simple""passthru"created_at?stringdate-timecreated_by_id?stringuuidcreated_by_name?stringdefault_ttl_ms?integerdeleted?booleandeprecated?booleandeprecation_message?stringdescription?stringdisable_module_cache?booleanDisableModuleCache disables the use of cached Terraform modules during provisioning for this template. It is read-only while ModuleCacheDisabledByDeployment is true.
display_name?stringfailure_ttl_ms?integerFailureTTLMillis, TimeTilDormantMillis, and TimeTilDormantAutoDeleteMillis are Premium features. Their values are used if your license is entitled to use the advanced template scheduling feature.
icon?stringid?stringuuidmax_port_share_level?codersdk.WorkspaceAgentPortShareLevel"owner""authenticated""organization""public"module_cache_disabled_by_deployment?booleanModuleCacheDisabledByDeployment reports that the deployment disables the Terraform module cache for every template. Templates cannot opt back in, so the effective state is disabled regardless of DisableModuleCache.
name?stringorganization_display_name?stringorganization_icon?stringorganization_id?stringuuidorganization_name?stringurlprovisioner?"terraform""terraform"require_active_version?booleanRequireActiveVersion mandates that workspaces are built with the active template version.
time_til_autostop_notify_ms?integerTimeTilAutostopNotifyMillis is the duration before the workspace's autostop deadline at which a reminder notification is sent. 0 disables the notification.
time_til_dormant_autodelete_ms?integertime_til_dormant_ms?integerupdated_at?stringdate-timeuse_classic_parameter_flow?booleanThe samples read CODER_URL and CODER_SESSION_TOKEN: set up your environment.
curl -X GET \ "$CODER_URL/api/v2/organizations/{organization}/templates/{templatename}" \ -H "Coder-Session-Token: $CODER_SESSION_TOKEN"{ "active_user_count": 0, "active_version_id": "eae64611-bd53-4a80-bb77-df1e432c0fbc", "activity_bump_ms": 0, "agents_allowed": true, "allow_user_autostart": true, "allow_user_autostop": true, "allow_user_cancel_workspace_jobs": true, "allow_workspace_renames": true, "autostart_requirement": { "days_of_week": [ "monday" ] }, "autostop_requirement": { "days_of_week": [ "monday" ], "weeks": 0 }, "build_time_stats": { "property1": { "p50": 123, "p95": 146 }, "property2": { "p50": 123, "p95": 146 } }, "cors_behavior": "simple", "created_at": "2019-08-24T14:15:22Z", "created_by_id": "9377d689-01fb-4abf-8450-3368d2c1924f", "created_by_name": "string", "default_ttl_ms": 0, "deleted": true, "deprecated": true, "deprecation_message": "string", "description": "string", "disable_module_cache": true, "display_name": "string", "failure_ttl_ms": 0, "icon": "string", "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "max_port_share_level": "owner", "module_cache_disabled_by_deployment": true, "name": "string", "organization_display_name": "string", "organization_icon": "string", "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6", "organization_name": "string", "provisioner": "terraform", "require_active_version": true, "time_til_autostop_notify_ms": 0, "time_til_dormant_autodelete_ms": 0, "time_til_dormant_ms": 0, "updated_at": "2019-08-24T14:15:22Z", "use_classic_parameter_flow": true}