Application Pattern Orchestrator on AWS API Documentation
Create a new attribute
POST /attributes
Name | Type | Description |
---|---|---|
key | String[1..120] |
The key of the attribute Allowed values: "[0-9a-zA-Z-]"_ |
value | String[1..120] |
The value of the attribute Allowed values: "[0-9a-zA-Z-]"_ |
description | String[1..1024] |
optional The description of the attribute |
metadata | Object |
optional The metadata of the attribute in JSON format. The maximum length is 7000. |
json
- Request-Example:
{
"key": "hostingConstruct"
"value": "Lambda"
"description": "The application that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless application"
}
}
Name | Type | Description |
---|---|---|
name | String |
The name of the attribute |
description | String |
The description of the attribute |
key | String |
The key of the attribute |
value | String |
The value of the attribute |
metadata | Object |
The metadata of the attribute |
createTime | String |
The timestamp when the attribute is created |
lastUpdateTime | String |
The timestamp when the attribute is updated last time |
HTTP/1.1 201 Created
{
"name": "hostingConstruct:Lambda",
"key": "hostingConstruct"
"value": "Lambda"
"description": "The application that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless application"
},
"createTime": "2021-05-17T07:04:24.102Z",
"lastUpdateTime": "2021-05-17T07:04:24.102Z"
}
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Delete an existing attribute.
DELETE /attributes/:id
Name | Type | Description |
---|---|---|
id | String |
id or name of the attribute |
Name | Type | Description |
---|---|---|
id | String |
The id of the deleted attribute |
HTTP/1.1 200 OK
{
"id": "HOSTINGCONSTRUCT:EC2",
}
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 404 Not Found
{
"error": "Specified item is not found. id: TestKey:TestValue",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Get details of an attribute
GET /attributes/:id
Name | Type | Description |
---|---|---|
id | String |
id or name of the attribute |
Name | Type | Description |
---|---|---|
name | String |
The name of the attribute. |
description | String |
The description of the attribute |
key | String |
The key of the attribute |
value | String |
The value of the attribute |
metadata | Object |
The metadata of the attribute |
createTime | String |
The timestamp when the attribute is created |
lastUpdateTime | String |
The timestamp when the attribute is updated last time |
HTTP/1.1 200 OK
{
"name": "hostingConstruct:Lambda",
"key": "hostingConstruct"
"value": "Lambda"
"description": "The pattern that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless patterns"
},
"createTime": "2021-05-17T07:04:24.102Z",
"lastUpdateTime": "2021-05-17T07:04:24.102Z"
}
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 404 Not Found
{
"error": "Specified item is not found. id: TestKey:TestValue",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
List all attributes
GET /attributes
Name | Type | Description |
---|---|---|
key | String |
optional Specify key name to retrieve attributes that have the given key. |
maxRow | Number |
optional Maximum number of rows in the response page Default value: 100Allowed values: 1-1000 |
nextToken | String |
optional Specify the value of the |
Name | Type | Description |
---|---|---|
results | Object[] |
results |
results.name | String |
The name of the attribute |
results.description | String |
The description of the attribute |
results.key | String |
The key of the attribute |
results.value | String |
The value of the attribute |
results.metadata | Object |
The metadata of the attribute |
results.createTime | String |
The timestamp when the attribute is created |
results.lastUpdateTime | String |
The timestamp when the attribute is updated last time |
nextToken | UUID |
optional The token for retrieving next page |
HTTP/1.1 200 OK
{
"results": [
{
"name": "hostingConstruct:Lambda",
"key": "hostingConstruct"
"value": "Lambda"
"description": "The pattern that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless pattern"
},
"createTime": "2021-05-17T07:04:24.102Z",
"lastUpdateTime": "2021-05-17T07:04:24.102Z"
},
{
"name": "hostingConstruct:EC2",
"key": "hostingConstruct"
"value": "EC2"
"description": "The pattern that is mainly based on AWS EC2",
"metadata": {
"notes": "Only use it for pattern that requires linux OS"
},
"createTime": "2021-05-17T07:04:24.102Z",
"lastUpdateTime": "2021-05-17T07:04:24.102Z"
},
],
"nextToken": "5f55c3f4-792e-4ae0-a7a5-76541f8d5ebb"
}
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Update an existing attribute. This will replace the current attribute entirly, so all parameters need to be specified.
PUT /attributes/:id
Name | Type | Description |
---|---|---|
key | String[1..120] |
The key of the attribute Allowed values: "[0-9a-zA-Z-]"_ |
value | String[1..120] |
The value of the attribute Allowed values: "[0-9a-zA-Z-]"_ |
description | String[1..1024] |
optional The description of the attribute |
metadata | Object |
optional The metadata of the attribute in JSON format. The maximum length is 7000. |
json
- Request-Example:
{
"key": "hostingConstruct"
"value": "Lambda"
"description": "The application that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless application"
}
}
Name | Type | Description |
---|---|---|
name | String |
The name of the attribute |
description | String |
The description of the attribute |
key | String |
The key of the attribute |
value | String |
The value of the attribute |
metadata | Object |
The metadata of the attribute |
createTime | String |
The timestamp when the attribute is created |
lastUpdateTime | String |
The timestamp when the attribute is updated last time |
HTTP/1.1 200 OK
{
"name": "hostingConstruct:Lambda",
"key": "hostingConstruct"
"value": "Lambda"
"description": "The application that is mainly based on AWS Lambda Service",
"metadata": {
"notes": "Only use it for serverless application"
},
"createTime": "2021-05-17T07:04:24.102Z",
"lastUpdateTime": "2021-05-17T07:04:24.102Z"
}
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 404 Not Found
{
"error": "Specified item is not found. id: TestKey:TestValue",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Creates new pattern
POST /patterns
Name | Type | Description |
---|---|---|
name | String |
Pattern's Name |
description | String |
Pattern's Description |
patternType | String |
Pattern Type i.e. CDK or CFN |
attributes | Object |
JSON Object |
HTTP/1.1 201 Created
API Headers {"Access-Control-Allow-Origin":"*","X-Amzn-Trace-Id":"Root=1-6168f480-0bd8024e6ceb2ff2602efa94;Sampled=1","Content-Type":"application/json"}
{
"patternObject": {
"patternId": "sample-pattern1",
"name": "sample-pattern1",
"description": "test pattern",
"patternType": "CFN",
"updatedTimestamp": "2022-09-16T07:01:02.145Z",
"createdTimestamp": "2022-09-16T07:01:02.145Z",
"infrastructureStackStatus": "CREATE_IN_PROGRESS",
"patternRepoURL": "git://dev.github-enterprise.abc/enterprise/sample-pattern1.git",
"attributes": {
"DataClassification": "PII",
"SecurityLevel": "Medium"
},
"codeRepository": {
"branchName": "master",
"repoName": "sample-pattern1"
}
}
}
Get pattern details
GET /patterns/{id}
HTTP/1.1 200 OK
{
"metadata": {
"codeRepository": {
"branchName": "master",
"type": "github",
"repoOwner": "enterprise",
"repoName": "sample-pattern"
},
"updatedTimestamp": "2022-09-16T06:34:33.648Z",
"lastCommitId": "5291a66986299b60536e1d944a82f6edaa88287e",
"attributes": {
"DataClassification": "PII",
"SecurityLevel": "Medium"
},
"patternType": "CFN",
"description": "test decription",
"name": "sample-pattern",
"createdTimestamp": "2022-09-16T04:17:10.656Z",
"patternRepoURL": "git://dev.github-enterprise.abc/enterprise/sample-pattern.git",
"infrastructureStackStatus": "CREATE_COMPLETE",
"patternId": "sample-pattern"
},
"lastCommitPublishData": {
"allPackages": [
{
"name": "@sample-pattern/dynamodb-pattern",
"version": "1.0.2"
}
],
"updatedTimestamp": "2022-09-16T06:34:33.648Z",
"changedPackages": [
{
"name": "@sample-pattern/dynamodb-pattern",
"version": "1.0.2"
}
],
"artifacts": [
{
"type": "CONTROL",
"name": "cfn_nag.txt",
"location": "sample-pattern/5291a66986299b60536e1d944a82f6edaa88287e/controls/cfn_nag.txt"
},
{
"type": "MARKDOWN",
"name": "README.md",
"location": "sample-pattern/5291a66986299b60536e1d944a82f6edaa88287e/markdown/README.md"
}
],
"serviceCatalogProducts": [
{
"name": "sample-pattern_@sample-pattern/dynamodb-pattern",
"region": "ap-southeast-2",
"productId": "prod-otgvptp6uh6nc",
"account": "111111111111",
"provisioningArtifactId": "pa-y6vhyv6t6j4aa"
}
],
"commitMessage": "Merge pull request #2 from enterprise/feature initial commit",
"createdTimestamp": "2022-09-16T06:34:33.648Z",
"commitId": "5291a66986299b60536e1d944a82f6edaa88287e",
"patternId": "sample-pattern"
}
}
List all patterns
GET /patterns
HTTP/1.1 200 OK
{
"results": [
{
"patternMetaData": {
"codeRepository": {
"branchName": "master",
"type": "github",
"repoOwner": "enterprise",
"repoName": "sample-pattern"
},
"updatedTimestamp": "2022-09-16T06:34:33.648Z",
"lastCommitId": "5291a66986299b60536e1d944a82f6edaa88287e",
"attributes": {
"DataClassification": "PII",
"SecurityLevel": "Medium"
},
"patternType": "CFN",
"description": "decription",
"name": "sample-pattern",
"createdTimestamp": "2022-09-16T04:17:10.656Z",
"patternRepoURL": "git://dev.github-enterprise.abc/enterprise/sample-pattern.git",
"infrastructureStackStatus": "CREATE_COMPLETE",
"patternId": "sample-pattern"
},
"lastCommitPublishData": {
"allPackages": [
{
"name": "@my-cfn/dynamodb",
"version": "1.0.2"
}
],
"updatedTimestamp": "2022-10-25T02:53:14.535Z",
"changedPackages": [
{
"name": "@my-cfn/dynamodb",
"version": "1.0.2"
}
],
"artifacts": [
{
"type": "CONTROL",
"name": "cfn_nag.txt",
"location": "sample-pattern/29c26261aa732dd9851258c89a6c375af7cf3d0d/controls/cfn_nag.txt"
},
{
"type": "IMAGE",
"name": "architecture.png",
"location": "sample-pattern/29c26261aa732dd9851258c89a6c375af7cf3d0d/images/architecture.png"
},
{
"type": "MARKDOWN",
"name": "README.md",
"location": "sample-pattern/29c26261aa732dd9851258c89a6c375af7cf3d0d/markdown/README.md"
},
{
"type": "MARKDOWN",
"name": "USAGE.md",
"location": "sample-pattern/29c26261aa732dd9851258c89a6c375af7cf3d0d/markdown/USAGE.md"
}
],
"serviceCatalogProducts": [
{
"name": "sample-pattern_@my-cfn/dynamodb",
"region": "ap-southeast-2",
"productId": "prod-42323232dsd",
"account": "xxxxxxxxxxxx",
"provisioningArtifactId": "pa-1111aaaassss"
}
],
"commitMessage": "Merge pull request #1 from test/feature new templates added",
"createdTimestamp": "2022-10-25T02:53:14.535Z",
"commitId": "29c26261aa732dd9851258c89a6c375af7cf3d0d",
"patternId": "sample-pattern"
}
}
]
}
Triggers codepipeline to build failed patterns
PUT /patterns/pipeline/{id}
Name | Type | Description |
---|---|---|
id | String |
Pattern's name |
HTTP/1.1 201 Created
API Headers {"Access-Control-Allow-Origin":"*","X-Amzn-Trace-Id":"Root=1-6168f480-0bd8024e6ceb2ff2602efa94;Sampled=1","Content-Type":"application/json"}
{
"codeRepository": {
"branchName": "master",
"type": "github",
"repoOwner": "enterprise",
"repoName": "sample-pattern"
},
"updatedTimestamp": "2022-09-16T06:25:59.256Z",
"attributes": {
"DataClassification": "PII"
},
"patternType": "CFN",
"description": "",
"createdTimestamp": "2022-09-16T06:25:59.256Z",
"name": "sample-pattern",
"patternRepoURL": "git://dev.github-enterprise.abc/enterprise/sample-pattern.git",
"infrastructureStackStatus": "CREATE_IN_PROGRESS",
"patternId": "sample-pattern"
}
Update pattern's metadata
PUT /patterns/:id
Name | Type | Description |
---|---|---|
description | String |
Pattern's Description |
attributes | Object |
JSON Object |
HTTP/1.1 200 OK
API Headers {"Access-Control-Allow-Origin":"*","X-Amzn-Trace-Id":"Root=1-6168f480-0bd8024e6ceb2ff2602efa94;Sampled=1","Content-Type":"application/json"}
{
"patternObject": {
"patternId": "sample-pattern1",
"name": "sample-pattern1",
"description": "test pattern",
"patternType": "CFN",
"updatedTimestamp": "2022-09-16T07:01:02.145Z",
"createdTimestamp": "2022-09-16T07:01:02.145Z",
"infrastructureStackStatus": "CREATE_IN_PROGRESS",
"patternRepoURL": "git://dev.github-enterprise.abc/enterprise/sample-pattern1.git",
"attributes": {
"DataClassification": "PII",
"SecurityLevel": "Medium"
},
"codeRepository": {
"type": "github",
"repoOwner": "enterprise",
"branchName": "master",
"repoName": "sample-pattern1"
}
}
}
Creates a new notification subscription
POST /subscriptions
Name | Type | Description |
---|---|---|
patternId | UUID |
The pattern's id. |
String |
The subscription destination email address. |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Deletes a notification subscription
DELETE /subscriptions
Name | Type | Description |
---|---|---|
patternId | UUID |
The pattern's id. |
String |
The subscription destination email address. |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
Name | Type | Description |
---|---|---|
error | String |
Error message |
retryable | Boolean |
Indicate if the request can be retryable |
HTTP/1.1 400 Bad Request
{
"error": "Invalid attribute id. The attribute id must match /^[-\\w]{1,120}:[-\\w]{1,120}$/."",
"retryable": false
}
HTTP/1.1 500 Internal Server Error
{
"error": "Connection failure.",
"retryable": false
}
Returns subscription data for a pattern and email id
GET /subscriptions
Name | Type | Description |
---|---|---|
patternId | String |
Pattern Id |
String |
Subscriber's email address |
HTTP/1.1 200 OK
{
"email": "test@testdomain.com",
"patternId": "test-pattern-id"
}