CoreService

<back to all web services

GetResourceGroupTemplateDefinitions

ResourceGroupTemplate - CRUD

Returns the template definitions

Requires Authentication
Required role:TenantReader
The following routes are available for this service:
GET/api/resourcegrouptemplates/definitionsReturns the template definitions
GET/resourcegrouptemplates/definitionsReturns the template definitions
"use strict";
/** @typedef {'Json'|'Yaml'} */
export var TemplateLanguages;
(function (TemplateLanguages) {
    TemplateLanguages["Json"] = "Json"
    TemplateLanguages["Yaml"] = "Yaml"
})(TemplateLanguages || (TemplateLanguages = {}));
export class GetResourceGroupTemplateDefinitions {
    /** @param {{tenantName?:string,definitionFormat?:TemplateLanguages,name?:string,version?:string,includeDeleted?:boolean}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    tenantName;
    /** @type {TemplateLanguages} */
    definitionFormat;
    /**
     * @type {string}
     * @description The templates name */
    name;
    /**
     * @type {?string}
     * @description The templates version */
    version;
    /**
     * @type {?boolean}
     * @description If true, also soft deleted items will be returned */
    includeDeleted;
}
/** @typedef {'String'|'Number'|'Boolean'|'List'} */
export var ValueDataType;
(function (ValueDataType) {
    ValueDataType["String"] = "String"
    ValueDataType["Number"] = "Number"
    ValueDataType["Boolean"] = "Boolean"
    ValueDataType["List"] = "List"
})(ValueDataType || (ValueDataType = {}));
/** @typedef {'Lab'|'Poc'|'Dev'|'Test'|'Int'|'Uat'|'Prod'} */
export var Environments;
(function (Environments) {
    Environments["Lab"] = "Lab"
    Environments["Poc"] = "Poc"
    Environments["Dev"] = "Dev"
    Environments["Test"] = "Test"
    Environments["Int"] = "Int"
    Environments["Uat"] = "Uat"
    Environments["Prod"] = "Prod"
})(Environments || (Environments = {}));
export class VariableDto {
    /** @param {{name?:string,value?:string,type?:ValueDataType,description?:string,isInherited?:boolean,environment?:Environments}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    name;
    /**
     * @type {string}
     * @description Value in form of a json string (e.g. Number = 1234, String = "foo", Boolean = false, List = [1,2,3,4]). Note: string values need extra quotes */
    value;
    /**
     * @type {ValueDataType}
     * @description The data type of the value property */
    type;
    /** @type {?string} */
    description;
    /** @type {boolean} */
    isInherited;
    /** @type {?Environments} */
    environment;
}
/** @typedef T {any} */
export class ItemsResponse {
    /** @param {{items?:IList<VariableDto>,offset?:number,total?:number,isGrouped?:boolean,responseStatus?:ResponseStatus,meta?:{ [index:string]: string; }}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {IList<VariableDto>} */
    items;
    /** @type {number} */
    offset;
    /** @type {number} */
    total;
    /** @type {boolean} */
    isGrouped;
    /** @type {?ResponseStatus} */
    responseStatus;
    /** @type {?{ [index:string]: string; }} */
    meta;
}

JavaScript GetResourceGroupTemplateDefinitions DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /api/resourcegrouptemplates/definitions HTTP/1.1 
Host: core.starburst.svc 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"items":null,"offset":0,"total":0,"isGrouped":false,"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}},"meta":{"String":"String"}}