# Get template GET https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123 Get template by ID (requires `group`). Reference: https://api.hublinks.io/alsona-api/templates/get-template ## OpenAPI Specification ```yaml openapi: 3.1.0 info: title: collection version: 1.0.0 paths: /rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123: get: operationId: get-template summary: Get template description: Get template by ID (requires `group`). tags: - subpackage_templates parameters: - name: group in: query required: false schema: type: string - name: X-API-KEY in: header required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/Templates_Get template_Response_200' '400': description: Bad Request content: application/json: schema: $ref: >- #/components/schemas/GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestBadRequestError '401': description: Unauthorized content: application/json: schema: $ref: >- #/components/schemas/GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestUnauthorizedError servers: - url: https://alsona.com components: schemas: RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItemsStyle: type: object properties: opacity: type: integer required: - opacity title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItemsStyle RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItems: type: object properties: id: type: string type: type: string style: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItemsStyle source: type: string target: type: string selectable: type: boolean required: - id - type - style - source - target - selectable title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItems RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsData: type: object properties: icon: type: string title: type: string required: - icon - title title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsData RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsStyle: type: object properties: opacity: type: integer required: - opacity title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsStyle RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsMeasured: type: object properties: width: type: integer height: type: integer required: - width - height title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsMeasured RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsPosition: type: object properties: x: type: integer 'y': type: integer required: - x - 'y' title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsPosition RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItems: type: object properties: id: type: string data: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsData type: type: string style: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsStyle measured: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsMeasured position: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItemsPosition selected: type: boolean required: - id - data - type - style - measured - position - selected title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItems RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflow: type: object properties: edges: type: array items: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowEdgesItems nodes: type: array items: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflowNodesItems required: - edges - nodes title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflow RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplate: type: object properties: name: type: string group: type: string workflow: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplateWorkflow account_id: type: string created_at: type: integer updated_at: type: integer description: type: string template_id: type: string required: - name - group - workflow - account_id - created_at - updated_at - description - template_id title: >- RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplate Templates_Get template_Response_200: type: object properties: success: type: boolean template: $ref: >- #/components/schemas/RestAccountsAccountCd855C2Bb1Cc72097238TemplatesTemplateTest123GetResponsesContentApplicationJsonSchemaTemplate required: - success - template title: Templates_Get template_Response_200 GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestBadRequestError: type: object properties: error: type: string message: type: string required: - error - message title: >- GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestBadRequestError GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestUnauthorizedError: type: object properties: error: type: string message: type: string required: - error - message title: >- GetRestAccountsAccount_cd855c2bb1cc72097238TemplatesTemplate_test_123RequestUnauthorizedError securitySchemes: apiKeyAuth: type: apiKey in: header name: X-API-KEY ``` ## SDK Code Examples ```python Templates_Get template_example import requests url = "https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123" querystring = {"group":"account_abc_workflows"} headers = {"X-API-KEY": ""} response = requests.get(url, headers=headers, params=querystring) print(response.json()) ``` ```javascript Templates_Get template_example const url = 'https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows'; const options = {method: 'GET', headers: {'X-API-KEY': ''}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go Templates_Get template_example package main import ( "fmt" "net/http" "io" ) func main() { url := "https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("X-API-KEY", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Templates_Get template_example require 'uri' require 'net/http' url = URI("https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["X-API-KEY"] = '' response = http.request(request) puts response.read_body ``` ```java Templates_Get template_example import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows") .header("X-API-KEY", "") .asString(); ``` ```php Templates_Get template_example request('GET', 'https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows', [ 'headers' => [ 'X-API-KEY' => '', ], ]); echo $response->getBody(); ``` ```csharp Templates_Get template_example using RestSharp; var client = new RestClient("https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows"); var request = new RestRequest(Method.GET); request.AddHeader("X-API-KEY", ""); IRestResponse response = client.Execute(request); ``` ```swift Templates_Get template_example import Foundation let headers = ["X-API-KEY": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://alsona.com/rest/accounts/account_cd855c2bb1cc72097238/templates/template_test_123?group=account_abc_workflows")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```