| Required role: | TenantReader |
| PATCH | /api/deployments/generation/resolvedvariables | Resolve variables for a new deployment from template and parent collection | |
|---|---|---|---|
| PATCH | /deployments/generation/resolvedvariables | Resolve variables for a new deployment from template and parent collection |
<?php namespace dtos;
use DateTime;
use Exception;
use DateInterval;
use JsonSerializable;
use ServiceStack\{IReturn,IReturnVoid,IGet,IPost,IPut,IDelete,IPatch,IMeta,IHasSessionId,IHasBearerToken,IHasVersion};
use ServiceStack\{ICrud,ICreateDb,IUpdateDb,IPatchDb,IDeleteDb,ISaveDb,AuditBase,QueryDb,QueryDb2,QueryData,QueryData2,QueryResponse};
use ServiceStack\{ResponseStatus,ResponseError,EmptyResponse,IdResponse,ArrayList,KeyValuePair2,StringResponse,StringsResponse,Tuple2,Tuple3,ByteArray};
use ServiceStack\{JsonConverters,Returns,TypeContext};
/** @description Resolve variables for a new deployment from template and parent collection */
// @Api(Description="Resolve variables for a new deployment from template and parent collection")
// @ApiResponse(Description="Success", IsDefaultResponse=true, ResponseType="typeof(System.Collections.Generic.IList`1[[CoreService.ServiceModel.Dtos.Base.Responses.VariableDto, CoreService.ServiceModel, Version=0.15.14.0, Culture=neutral, PublicKeyToken=null]])", StatusCode=200)
class ResolveDeploymentVariables implements IBaseRequest, IHasTenantName, IPatch, JsonSerializable
{
public function __construct(
// @ApiMember(DataType="string", IsRequired=true, ParameterType="header")
// @Validate(Validator="NotEmpty")
/** @var string */
public string $tenantName='',
/** @description The id of the selected parent collection */
// @ApiMember(DataType="string", Description="The id of the selected parent collection", Format="guid", IsRequired=true, ParameterType="body")
/** @var string */
public string $collectionId='',
/** @description The id of the selected deployment template */
// @ApiMember(DataType="string", Description="The id of the selected deployment template", Format="guid", IsRequired=true, ParameterType="body")
/** @var string */
public string $deploymentTemplateId=''
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['tenantName'])) $this->tenantName = $o['tenantName'];
if (isset($o['collectionId'])) $this->collectionId = $o['collectionId'];
if (isset($o['deploymentTemplateId'])) $this->deploymentTemplateId = $o['deploymentTemplateId'];
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->tenantName)) $o['tenantName'] = $this->tenantName;
if (isset($this->collectionId)) $o['collectionId'] = $this->collectionId;
if (isset($this->deploymentTemplateId)) $o['deploymentTemplateId'] = $this->deploymentTemplateId;
return empty($o) ? new class(){} : $o;
}
}
PHP ResolveDeploymentVariables 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
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
PATCH /api/deployments/generation/resolvedvariables HTTP/1.1
Host: core.starburst.svc
Accept: application/json
Content-Type: application/json
Content-Length: length
{"tenantName":"String","collectionId":"00000000-0000-0000-0000-000000000000","deploymentTemplateId":"00000000-0000-0000-0000-000000000000","txId":"00000000-0000-0000-0000-000000000000"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
[{"name":"String","value":"String","type":"String","description":"String","isInherited":false,"environment":"Lab"}]