---
title: "POST /create-recommendation-template"
method: POST
path: "/create-recommendation-template"
---

# POST /create-recommendation-template

`POST /create-recommendation-template`

Creates a new recommendation template for the Resilience Hub application.

## Request body

- object
  - `assessmentArn` string, required — Amazon Resource Name (ARN) of the assessment. The format for this ARN is: arn:<code>partition</code>:resiliencehub:<code>region</code>:<code>account</code>:app-assessment/<code>app-id</code>. For more information about ARNs, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html"> Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i> guide.
  - `bucketName` string — The name of the Amazon S3 bucket that will contain the recommendation template.
  - `clientToken` string — Used for an idempotency token. A client token is a unique, case-sensitive string of up to 64 ASCII characters. You should not reuse the same client token for other API requests.
  - `format` 'CfnYaml' | 'CfnJson' — <p>The format for the recommendation template.</p> <dl> <dt>CfnJson</dt> <dd> <p>The template is CloudFormation JSON.</p> </dd> <dt>CfnYaml</dt> <dd> <p>The template is CloudFormation YAML.</p> </dd> </dl>
  - `name` string, required — The name for the recommendation template.
  - `recommendationIds` Uuid[] — Identifiers for the recommendations used to create a recommendation template.
  - `recommendationTypes` RenderRecommendationType[] — <p>An array of strings that specify the recommendation template type or types.</p> <dl> <dt>Alarm</dt> <dd> <p>The template is an <a>AlarmRecommendation</a> template.</p> </dd> <dt>Sop</dt> <dd> <p>The template is a <a>SopRecommendation</a> template.</p> </dd> <dt>Test</dt> <dd> <p>The template is a <a>TestRecommendation</a> template.</p> </dd> </dl>
  - `tags` object — Tags assigned to the resource. A tag is a label that you assign to an Amazon Web Services resource. Each tag consists of a key/value pair.

## Response `200`

Success

- CreateRecommendationTemplateResponse
  - `recommendationTemplate` object — The newly created recommendation template, returned as an object. This object includes the template's name, format, status, tags, Amazon S3 bucket location, and more.
    - `appArn` string — Amazon Resource Name (ARN) of the Resilience Hub application. The format for this ARN is: arn:<code>partition</code>:resiliencehub:<code>region</code>:<code>account</code>:app/<code>app-id</code>. For more information about ARNs, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html"> Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i> guide.
    - `assessmentArn` string, required — Amazon Resource Name (ARN) of the assessment. The format for this ARN is: arn:<code>partition</code>:resiliencehub:<code>region</code>:<code>account</code>:app-assessment/<code>app-id</code>. For more information about ARNs, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html"> Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i> guide.
    - `endTime` string, date-time — The end time for the action.
    - `format` 'CfnYaml' | 'CfnJson', required — <p>Format of the recommendation template.</p> <dl> <dt>CfnJson</dt> <dd> <p>The template is CloudFormation JSON.</p> </dd> <dt>CfnYaml</dt> <dd> <p>The template is CloudFormation YAML.</p> </dd> </dl>
    - `message` string — Message for the recommendation template.
    - `name` string, required — Name for the recommendation template.
    - `needsReplacements` boolean — Indicates if replacements are needed.
    - `recommendationIds` Uuid[] — Identifiers for the recommendations used in the recommendation template.
    - `recommendationTemplateArn` string, required — Amazon Resource Name (ARN) for the recommendation template.
    - `recommendationTypes` RenderRecommendationType[], required — <p>An array of strings that specify the recommendation template type or types.</p> <dl> <dt>Alarm</dt> <dd> <p>The template is an <a>AlarmRecommendation</a> template.</p> </dd> <dt>Sop</dt> <dd> <p>The template is a <a>SopRecommendation</a> template.</p> </dd> <dt>Test</dt> <dd> <p>The template is a <a>TestRecommendation</a> template.</p> </dd> </dl>
    - `startTime` string, date-time — The start time for the action.
    - `status` 'Pending' | 'InProgress' | 'Failed' | 'Success', required — Status of the action.
    - `tags` object — Tags assigned to the resource. A tag is a label that you assign to an Amazon Web Services resource. Each tag consists of a key/value pair.
    - `templatesLocation` object — The file location of the template.
      - `bucket` string — The name of the Amazon S3 bucket.
      - `prefix` string — The prefix for the Amazon S3 bucket.

## Other responses

- `480` — InternalServerException
- `481` — ResourceNotFoundException
- `482` — ConflictException
- `483` — ServiceQuotaExceededException
- `484` — ThrottlingException
- `485` — ValidationException
- `486` — AccessDeniedException

---

[API](https://skmtc.net/aws/apis/resiliencehub.md) · [All operations](https://skmtc.net/aws/apis/resiliencehub/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/resiliencehub/revisions/163b82209f70/schema)
