---
updatedAt: 2026-04-21T03:40:36.000Z
agentTools:
  projectIndex: https://docs.ternary.app/llms.txt
---

# Create AWS integration

Create a new AWS data integration for importing Cost and Usage Report (CUR) data.

Configure one or more CUR sources, an IAM role ARN for cross-account access, and optional linked accounts for consolidated billing. An optional monitoring role ARN can be provided for CloudWatch metrics collection.

See [Data Integrations](https://docs.ternary.app/docs/integrations-overview) for setup guidance.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Core API",
    "description": "Ternary Resource Management API",
    "version": "1.0.0",
    "contact": {},
    "license": {
      "name": "MIT",
      "identifier": "MIT"
    }
  },
  "tags": [
    {
      "name": "Data Integration: AWS",
      "description": "Manage AWS Cost and Usage Report integrations."
    }
  ],
  "servers": [
    {
      "url": "https://core-api.ternary.app/api",
      "description": "Core API"
    },
    {
      "url": "https://core-api.eu.ternary.app/api",
      "description": "Core API (EU)"
    }
  ],
  "externalDocs": {
    "description": "Raw JSON",
    "url": "https://core-api.ternary.app/api/docs.json"
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    },
    "schemas": {
      "FailureResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "HTTP status code",
            "example": "400 - Bad Request"
          },
          "message": {
            "type": "string",
            "description": "Error message",
            "example": "ERROR_INVALID_PARAMS"
          },
          "reason": {
            "type": "string",
            "description": "Error reason code"
          }
        },
        "required": [
          "code",
          "message"
        ]
      },
      "CreateAWSIntegrationResponseBody": {
        "type": "object",
        "properties": {
          "integrationID": {
            "type": "string"
          }
        },
        "required": [
          "integrationID"
        ]
      },
      "CreateAWSIntegrationRequestBody": {
        "type": "object",
        "properties": {
          "tenantID": {
            "type": "string",
            "format": "uuid",
            "description": "A unique identifier for an organization",
            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
            "example": "92f36764-5af2-4ff5-a494-d841f32040be"
          },
          "costAndUsageReports": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string",
                  "description": "Cost and usage report name"
                },
                "region": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "Cost and usage report region"
                },
                "reportPathPrefix": {
                  "type": "string",
                  "description": "Cost and usage report path prefix"
                },
                "s3BucketName": {
                  "type": "string",
                  "description": "Cost and usage report s3 bucket name"
                }
              },
              "required": [
                "name",
                "region",
                "reportPathPrefix",
                "s3BucketName"
              ],
              "description": "AWS Cost and Usage Report (CUR)"
            }
          },
          "monitoringRoleARN": {
            "type": [
              "string",
              "null"
            ],
            "description": "Metrics collection role ARN"
          },
          "name": {
            "type": "string",
            "description": "Cloud integration name"
          },
          "roleARN": {
            "type": "string",
            "description": "Role ARN"
          },
          "linkedAccounts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "accountID": {
                  "type": "string",
                  "description": "Account ID"
                },
                "roleARN": {
                  "type": "string",
                  "description": "Role ARN"
                }
              },
              "required": [
                "accountID",
                "roleARN"
              ]
            }
          }
        },
        "required": [
          "tenantID",
          "costAndUsageReports",
          "name",
          "roleARN"
        ]
      }
    }
  },
  "paths": {
    "/data-integrations/aws": {
      "post": {
        "summary": "Create AWS integration",
        "tags": [
          "Data Integration: AWS"
        ],
        "operationId": "createAWSIntegration",
        "description": "Create a new AWS data integration for importing Cost and Usage Report (CUR) data.\n\nConfigure one or more CUR sources, an IAM role ARN for cross-account access, and optional linked accounts for consolidated billing. An optional monitoring role ARN can be provided for CloudWatch metrics collection.\n\nSee [Data Integrations](https://docs.ternary.app/docs/integrations-overview) for setup guidance.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateAWSIntegrationRequestBody"
              },
              "examples": {
                "createAWSIntegration": {
                  "value": {
                    "tenantID": "a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
                    "name": "Production AWS Cost Reports",
                    "roleARN": "arn:aws:iam::123456789012:role/TernaryReadRole",
                    "monitoringRoleARN": "arn:aws:iam::536868854562:role/test-cmp-service-agent",
                    "costAndUsageReports": [
                      {
                        "name": "ternary-cur-report",
                        "s3BucketName": "my-billing-bucket",
                        "reportPathPrefix": "cost-reports",
                        "region": "us-east-1"
                      }
                    ],
                    "linkedAccounts": [
                      {
                        "accountID": "612445658905",
                        "roleARN": "arn:aws:iam::612445658905:role/test-cmp-service-agent"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Operation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateAWSIntegrationResponseBody"
                },
                "examples": {
                  "createAWSIntegration": {
                    "value": {
                      "integrationID": "5urDCEWi8GDPPdqmLhUF"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FailureResponse"
                },
                "examples": {
                  "400Response": {
                    "value": {
                      "code": "400 - Bad Request",
                      "message": "ERROR_INVALID_PARAMS"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FailureResponse"
                },
                "examples": {
                  "401Response": {
                    "value": {
                      "code": "401 - Unauthorized",
                      "message": "ERROR_UNAUTHORIZED"
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FailureResponse"
                },
                "examples": {
                  "403Response": {
                    "value": {
                      "code": "403 - Forbidden",
                      "message": "ERROR_PERMISSION_DENIED"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "x-tagGroups": [
    {
      "name": "Core API",
      "tags": [
        "Alert Rule",
        "Alert Rule Events",
        "API Keys",
        "AWS Rate Recommendations",
        "Azure Rate Recommendations",
        "Billing Rules",
        "Budget",
        "Cases",
        "Cost Alerts",
        "Custom Label",
        "Custom Measures",
        "Data Integration",
        "Data Integration: Alibaba",
        "Data Integration: AWS",
        "Data Integration: Azure",
        "Data Integration: Custom Data",
        "Data Integration: Databricks",
        "Data Integration: GCP",
        "Data Integration: Oracle",
        "Data Integration: Snowflake",
        "Dimension Preferences",
        "GCP Rate Recommendations",
        "Integrations",
        "Label Map",
        "MCP Availability",
        "MCP Client Usage",
        "Measure Preferences",
        "MSP Billing Information",
        "MSP Child",
        "MSP Shared Payer Integrations",
        "MSP Tenant Settings",
        "Permissions",
        "Ramp Plans",
        "Report",
        "Resource Subscriptions",
        "Role",
        "Savings Opportunity Filter",
        "Scoped View",
        "Support Tickets",
        "Tenant",
        "Tenant SSO Config",
        "Usage Recommendations",
        "User",
        "User Group Config"
      ]
    }
  ]
}
```