CoreService

<back to all web services

CreateDeployment

Deployment - CRUD

Creates a new deployment

Requires Authentication
Required role:TenantReader
The following routes are available for this service:
POST/api/deployments/Creates a new deployment
POST/deployments/Creates a new deployment
CreateDeployment Parameters:
NameParameterData TypeRequiredDescription
TenantNameheaderstringYes
NamebodystringYesThe name of the deployment
DisplayNamebodystringNoThe deployments display name
DescriptionbodystringNoA more detailed description for the deployment
ParentIdbodystringYesThe id of the collection, this deployment belongs to
TemplateIdbodystringNoThe id of the template, this deployment is based on
DefaultResourceProviderIdbodystringYesThe default resource provider for this deployment
EnvironmentbodyEnvironmentsYesWhat kind of environment is this deployment

Allowable Values

  • Lab
  • Poc
  • Dev
  • Test
  • Int
  • Uat
  • Prod
ParametersbodyarrayYes
VariablesbodyarrayNo
TagsbodyarrayNo
ValidUntilbodystringNoThe expiry date of the environment
IsNeverExpiringbodyboolNoSet if the environment should never expire
OwnerUserIdsbodyarrayYes
Environments Enum:
Lab
Poc
Dev
Test
Int
Uat
Prod
ParameterDto Parameters:
NameParameterData TypeRequiredDescription
NameformstringYes
DescriptionformstringNo
ValueformstringNoValue in form of a json string (e.g. Number = 1234, String = "foo", Boolean = false). Note: string values need extra quotes
DefaultformstringNoOptional default value for the frontend. Needs to be in the same format as the value
OptionalformboolNoOptional parameters do not need to have a value. Default -> Optional=false
TypeformParameterValueTypeNoThe data type of the value and default property
ValidationformstringNo
ParameterValueType Enum:
String
Number
Boolean
SecureString
VariableDto Parameters:
NameParameterData TypeRequiredDescription
NameformstringYes
ValueformstringYesValue 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
TypeformValueDataTypeNoThe data type of the value property
DescriptionformstringNo
IsInheritedformboolNo
EnvironmentformEnvironments?No
ValueDataType Enum:
String
Number
Boolean
List
TagDto Parameters:
NameParameterData TypeRequiredDescription
NameformstringYes
ValueformstringNo
IsProtectedformboolNo
DeploymentDto Parameters:
NameParameterData TypeRequiredDescription
OperationalStateformOperationalStatesNoThe operational state of the deployment (Running, Stopped, None, Unknown)
ResourcesRunningformintNoHow many start/stop-capable resources are currently running
ResourcesTotalformintNoTotal number of start/stop-capable resources in this deployment
ShortIdformstringYesShorter id than the guid which can be used for automation (tenant wide unique) prefixed with a 'd'. E.g. dr36x3
NameUserDefinedPartformstringYesThe user defined part of the name property {userDefined}_{environment}
TenantIdformGuidNoThe id of the tenant
StateformLifecycleStatesNoThe state of the deployment
EnvironmentformEnvironmentsNoThe environment the deployment is deployed in
TemplateIdformGuid?NoThe id of the template which was used to create the deployment
IsTemplateBasedformboolNoShows if a deployment was rolled out through a dune template or not
ParametersformIList<ParameterDto>YesThe parameters which were used to create this deployment
VariablesformIList<VariableDto>YesA deployment scoped list of variables used for deployment of resources
VariablesSnapshotformIList<VariableDto>YesA snapshot of the varialbs used to create the deployment
ParentIdformGuidNoThe id of the parent (collection) of the deployment
ParentformConfigItemDtoNoThe parent (collection) of the deployment
ValidFromformDateTimeNoThe Date when the resources got deployed
ValidUntilformDateTime?NoThe Date when the deployment expires and has to be reevaluated
IsNeverExpiringformboolNoThe deployment will never expire
NextPatchDateformDateTime?NoThe date, when the deployments resources will receive updates
DefaultResourceProviderIdformGuidNoThe default resource provider where the resources are deployed
NeedsAttentionformboolNoDeployments which have issues in Jobs are marked with NeedsAttention
CompositionformResourceCompositionsNoComposition show if all resources in the deployment are dune native, dune foreign or a mix of both
MonthlyBudgetformdecimal?NoThe monthly cost budget for the whole collection
SendBudgetNotificationMailsformbool?NoWhether to send budget information mails to the collection owners
BudgetWarningThresholdPercentformint?NoA threshold, when to send the first budget warning mail
LinksformIList<LinkDto>Yes
ConfigItemDto Parameters:
NameParameterData TypeRequiredDescription
IdformGuidNo
NameformstringYes
DisplayNameformstringYes
DescriptionformstringNo
ObjectTypeformObjectTypesNo
SelfLinkformstringYes
TagsformIList<TagDto>Yes
PathformIList<PathItemDto>Yes
CreatedformDateTimeNo
CreateUserformstringYes
CreateUserIdformstringYes
ModifiedformDateTimeNo
ModifyUserformstringYes
ModifyUserIdformstringYes
IsDeletedformboolNo
DeletedformDateTime?No
DeleteUserformstringNo
DeleteUserIdformstringNo
LinksformIList<LinkDto>Yes
ObjectTypes Enum:
None
ConfigItem
Tenant
Collection
Resource
ComputeNode
VirtualMachine
PhysicalMachine
Disk
Subnet
IPAddress
Job
JobEvent
FreezePeriod
ResourceGroup
Deployment
ResourceGroupTemplate
DeploymentTemplate
ResourceProvider
GenericResource
Role
Permission
User
PatchingWindow
Update
ReportDefinition
TimeSeries
DataPoint
Action
ActionAssignment
UserNote
PathItemDto Parameters:
NameParameterData TypeRequiredDescription
LabelformstringYes
LinkformstringYes
ObjectTypeformObjectTypesNo
ObjectIdformGuidNo
LinkDto Parameters:
NameParameterData TypeRequiredDescription
CaptionformstringYes
RelformstringYes
HRefformstringYes
MethodformstringYes
OperationalStates Enum:
None
Starting
Running
Stopping
Stopped
Restarting
Deleting
Unknown
LifecycleStates Enum:
New
Deploying
Deployed
Removing
Removed
Failure
Imported
ResourceCompositions Enum:
Native
Foreign
Mixed

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.

POST /api/deployments/ HTTP/1.1 
Host: core.starburst.svc 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"tenantName":"String","name":"String","displayName":"String","description":"String","parentId":"00000000-0000-0000-0000-000000000000","templateId":"00000000-0000-0000-0000-000000000000","defaultResourceProviderId":"00000000-0000-0000-0000-000000000000","environment":"Lab","parameters":null,"variables":null,"tags":null,"validUntil":"0001-01-01T00:00:00.0000000Z","isNeverExpiring":false,"ownerUserIds":null,"txId":"00000000-0000-0000-0000-000000000000"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"operationalState":"None","resourcesRunning":0,"resourcesTotal":0,"shortId":"String","nameUserDefinedPart":"String","tenantId":"00000000-0000-0000-0000-000000000000","state":"New","environment":"Lab","templateId":"00000000-0000-0000-0000-000000000000","isTemplateBased":true,"parameters":null,"variables":null,"variablesSnapshot":null,"parentId":"00000000-0000-0000-0000-000000000000","parent":{"id":"00000000-0000-0000-0000-000000000000","name":"String","displayName":"String","description":"String","objectType":"None","selfLink":"String","tags":null,"path":null,"created":"0001-01-01T00:00:00.0000000Z","createUser":"String","createUserId":"String","modified":"0001-01-01T00:00:00.0000000Z","modifyUser":"String","modifyUserId":"String","isDeleted":false,"deleted":"0001-01-01T00:00:00.0000000Z","deleteUser":"String","deleteUserId":"String","links":null},"validFrom":"0001-01-01T00:00:00.0000000Z","validUntil":"0001-01-01T00:00:00.0000000Z","isNeverExpiring":false,"nextPatchDate":"0001-01-01T00:00:00.0000000Z","defaultResourceProviderId":"00000000-0000-0000-0000-000000000000","needsAttention":false,"composition":"Native","monthlyBudget":0,"sendBudgetNotificationMails":false,"budgetWarningThresholdPercent":0,"links":[{"caption":"Index","rel":"index","hRef":"/deployments/","method":"GET"},{"caption":"Collection","rel":"up","hRef":"/collections/00000000-0000-0000-0000-000000000000","method":"GET"},{"caption":"Resourcegroups","rel":"down","hRef":"/resourcegroups?parentId=00000000-0000-0000-0000-000000000000","method":"GET"}],"id":"00000000-0000-0000-0000-000000000000","name":"String","displayName":"String","description":"String","objectType":"None","selfLink":"String","tags":null,"path":null,"created":"0001-01-01T00:00:00.0000000Z","createUser":"String","createUserId":"String","modified":"0001-01-01T00:00:00.0000000Z","modifyUser":"String","modifyUserId":"String","isDeleted":false,"deleted":"0001-01-01T00:00:00.0000000Z","deleteUser":"String","deleteUserId":"String"}