---
title: "Set Credentials for AWS"
method: POST
path: "/setup/credentials/aws"
tags: ["Accounts"]
---

# Set Credentials for AWS

`POST /setup/credentials/aws`

Link a Spot account to an AWS Cloud account. \
Please create external id using spot api (see /setup/credentials/aws/externalId) \
and use it when creating the AWS role and then call this route with your AWS role's arn to link it to your spot account

## Parameters

- `#/paths/~1azure~1costs/get/parameters/0` — unresolved $ref

## Request body

- object
  - `credentials` object — Credentials details
    - `iamRole` string, required — Provide the IAM Role ARN connected to another AWS account 922761411349 and with the latest Spot Policy - https://docs.flexera.com/spot/administration/api/spot-policy-in-aws

## Response `200`

Set Cloud Credentials For AWS Response

- object
  - `request` object — Original request properties
    - `id` string — Unique ID associated with this request
    - `url` string — The URL that was used for the request
    - `method` string — The HTTP **METHOD** used for the request
    - `timestamp` string — When the request was received by Spot
  - `response` object — Response package that includes, status, type and any relevant data.
    - `status` object
      - `code` integer — HTTP status code assigned to this response
      - `message` string — HTTP status message for the respective status code

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/spot/apis/spot-by-flexera-api.md) · [All operations](https://skmtc.net/spot/apis/spot-by-flexera-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/spot/spot-by-flexera-api/revisions/72813baf8d47/schema)
