Skip to main content

ResourceState

idstringrequired

A globally unique identifier for the resource.

Example: 60d7c6c5-3984-42b9-a3c1-ae8a47a9bf55
namestringrequired

The logical name of the resource in the blueprint.

Example: my-existing-resource
typestringrequired

The type of the resource.

Example: aws/lambda/function
templateNamestringnullable

The name of the resource template in the source blueprint that the resource is derived from. This will be empty, null or not set if the resource is not derived from a template.

Example: my-template
instanceIdstringrequired

The ID of the blueprint instance that the resource belongs to.

Example: a97cf86f-2a5e-4614-984e-da480a0daa7a
statusintegerrequired

The high level status of the resource.

The following high level status codes are supported:

  • Unknown (0) - The status used when we can't determine an accurate status for a resource.
  • Creating (1) - The status used when an initial resource deployment is currently in progress.
  • Created (2) - The status used when a resource has been deployed successfully for the first time.
  • Create Failed (3) - The status used when the first creation of a resource has failed.
  • Destroying (4) - The status used when a resource is in the process of being destroyed.
  • Destroyed (5) - The status used when a resource has been destroyed.
  • Destroy Failed (6) - The status used when the destruction of a resource fails.
  • Updating (7) - The status used when a resource is being updated.
  • Updated (8) - The status used when a resource has been updated successfully.
  • Update Failed (9) - The status used when the update of a resource fails.
  • Rolling Back (10) - The status used when another change in the same blueprint has failed and the latest change involving the current resource is being rolled back.
  • Rollback Failed (11) - The status used when another change in the same blueprint has failed and the latest change involving the current resource could not be rolled back.
  • Rollback Complete (12) - The status used when another change in the same blueprint has failed and the latest change involving the current resource has been rolled back.

Possible values: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]

Example: 2
preciseStatusintegerrequired

The precise status of the resource.

The following precise status codes are supported:

  • Unknown (0) - The precise status used when we can't determine an accurate status for a resource.
  • Creating (1) - The precise status used when an initial resource deployment is currently in progress.
  • Config Compelte (2) - The precise status used when a resource has been configured successfully.
  • Created (3) - The precise status used when a resource has been deployed successfully and is considered stable.
  • Create Failed (4) - The precise status used when the first creation of a resource has failed.
  • Create Rolling Back (5) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully created is being rolled back.
  • Create Rollback Failed (6) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully created could not be rolled back.
  • Create Rollback Complete (7) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully created has been rolled back.
  • Destroying (8) - The precise status used when a resource is in the process of being destroyed.
  • Destroyed (9) - The precise status used when a resource has been destroyed.
  • Destroy Failed (10) - The precise status used when the destruction of a resource fails.
  • Destroy Rolling Back (11) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully destroyed is being rolled back.
  • Destroy Rollback Failed (12) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully destroyed could not be rolled back.
  • Destroy Rollback Config Complete (13) - The precise status used when another change in the same blueprint has failed and the current resource that was succesfully removed has been rolled back (recreated) but is not yet in a stable state.
  • Destroy Rollback Complete (14) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully removed has been rolled back (recreated) and is in a stable state.
  • Updating (15) - The precise status used when a resource is being updated.
  • Update Config Complete (16) - The precise status used when a resource being updated has been configured successfully.
  • Updated (17) - The precise status used when a resource has been updated successfully and is considered stable.
  • Update Failed (18) - The precise status used when the update of a resource fails.
  • Update Rolling Back (19) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully updated is being rolled back.
  • Update Rollback Failed (20) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully updated could not be rolled back.
  • Update Rollback Config Complete (21) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully updated has been rolled back but is not yet in a stable state.
  • Update Rollback Complete (22) - The precise status used when another change in the same blueprint has failed and the current resource that was successfully updated has been rolled back and is in a stable state.

Possible values: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22]

Example: 3
lastStatusUpdateTimestampintegernullable

The unix timestamp when the resource deployment status was last updated.

Example: 1678901234
lastDeployedTimestampintegerrequired

The unix timestamp when the resource was last deployed.

Example: 1678901234
lastDeployAttemptTimestampintegerrequired

The unix timestamp for when the last attempt was made to deploy the resource.

Example: 1678901234
specData objectrequired

The resolved resource spec for the currently deployed version of the resource along with computed fields derived from the deployed resource in the upstream provider.

property name*any

The resolved resource spec for the currently deployed version of the resource along with computed fields derived from the deployed resource in the upstream provider.

Example: {"functionName":"my-lambda-function","handler":"index.handler","runtime":"nodejs20.x","arn":"arn:aws:lambda:us-east-1:123456789012:function:my-lambda-function"}
descriptionstringnullable

A description of the resource.

Example: A lambda function for processing events
metadata object

The metadata for the resource that is derived from a source blueprint that includes additional information that allows for extensions built on top of the blueprint framework along with the storage of labels, annotations and a human-friendly display name for the resource.

displayNamestringnullable

A human-friendly display name for the resource.

Example: My Lambda Function
annotations object

Annotations for the resource.

labels object

Labels for the resource.

property name*string

The label value.

Example: processing
customobject

Custom metadata for the resource.

dependsOnResourcesstring[]

The names of resources that this resource depends on in the blueprint.

dependsOnChildrenstring[]

The names of child blueprints that this resource depends on in the blueprint.

failureReasonsstring[]required

The reasons why the resource deployment has failed, if applicable.

driftedbooleannullable

If true, the resource has drifted from the current state stored in the Deploy Engine. This is used to indicate that the resource has been modified in the upstream provider outside of the Deploy Engine.

Example: false
lastDriftDetectedTimestampintegernullable

The unix timestamp when the resource was last detected to be drifted.

Example: 1678901234
durations objectnullable

Duration information for the latest deployment of the resource.

configCompleteDurationnumbernullable

The duration in milliseconds for the resource to be configured. This will only be set if the resource has reached the config complete status.

Example: 10000
totalDurationnumbernullable

The duration in milliseconds for the resource change to reach the final status.

Example: 20000
attemptDurationsnumber[]

The durations in milliseconds for each attempt to deploy the resource.

ResourceState
{
"id": "60d7c6c5-3984-42b9-a3c1-ae8a47a9bf55",
"name": "my-existing-resource",
"type": "aws/lambda/function",
"templateName": "my-template",
"instanceId": "a97cf86f-2a5e-4614-984e-da480a0daa7a",
"status": 2,
"preciseStatus": 3,
"lastStatusUpdateTimestamp": 1678901234,
"lastDeployedTimestamp": 1678901234,
"lastDeployAttemptTimestamp": 1678901234,
"specData": {
"functionName": "my-lambda-function",
"handler": "index.handler",
"runtime": "nodejs20.x",
"arn": "arn:aws:lambda:us-east-1:123456789012:function:my-lambda-function"
},
"description": "A lambda function for processing events",
"metadata": {
"displayName": "My Lambda Function",
"annotations": {},
"labels": {},
"custom": {}
},
"dependsOnResources": [
"my-other-resource"
],
"dependsOnChildren": [
"my-other-child-blueprint"
],
"failureReasons": [
"The resource could not be created because the IAM role does not exist."
],
"drifted": false,
"lastDriftDetectedTimestamp": 1678901234,
"durations": {
"configCompleteDuration": 10000,
"totalDuration": 20000,
"attemptDurations": [
20000
]
}
}