> ## Documentation Index
> Fetch the complete documentation index at: https://docs.emergence.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# AWS Marketplace

> Deploy CRAFT from the AWS Marketplace using private offers, container products, and EDP committed spend drawdown.

# AWS Marketplace

CRAFT is available on the **AWS Marketplace** as a Container Product. Customers can deploy the platform into their own EKS clusters and apply purchases against their AWS Enterprise Discount Program (EDP) commitments.

## Why AWS Marketplace

<CardGroup cols={2}>
  <Card title="EDP Drawdown" icon="wallet">
    Customers apply CRAFT purchases against their AWS Enterprise Discount Program (EDP) commitments, removing budget approval friction.
  </Card>

  <Card title="Co-Sell with AWS" icon="handshake">
    Private offers enable AWS field teams to co-sell, earning quota credit and aligning sales incentives.
  </Card>

  <Card title="Larger Deals" icon="chart-line">
    Marketplace-transacted deals are 112% larger on average than direct sales, according to industry research.
  </Card>

  <Card title="Low Fees" icon="percent">
    3% fee for contract-based pricing, 1.5-3% for private offers. Contract-based pricing is recommended to avoid higher hourly/monthly fees.
  </Card>
</CardGroup>

## Architecture

CRAFT's cloud-agnostic Helm chart deploys the same platform services on EKS as on GKE. The AWS-specific work is scoped to infrastructure modules and marketplace packaging:

| Component                 | Source                                                             |
| ------------------------- | ------------------------------------------------------------------ |
| **Application chart**     | `em-runtime` Helm chart (cloud-agnostic)                           |
| **Infrastructure module** | EKS Terraform module (to be built as part of marketplace strategy) |
| **Container images**      | Published to Amazon ECR via CI/CD multi-registry pipeline          |
| **Marketplace packaging** | Container product with Helm charts and container images            |

## Deployment Model

<Tabs>
  <Tab title="Private Offer">
    Private offers are managed through the AWS Marketplace Management Portal (AMMP).

    <Steps>
      <Step title="Create a private offer in AMMP">
        The sales team configures pricing using contract-based pricing (recommended) with custom dimensions and generates a private offer for the target customer.
      </Step>

      <Step title="Customer accepts the offer">
        The customer receives the private offer link, reviews pricing and EULA terms, and subscribes through their AWS Console. Charges apply against their EDP commitment.
      </Step>

      <Step title="Deploy to EKS">
        After subscription, deploy the platform into the customer's EKS cluster using the Terraform module and Helm chart provided with the listing.
      </Step>
    </Steps>
  </Tab>

  <Tab title="Self-Service (Phase 3)">
    In the self-service model, the listing includes a CloudFormation template that provisions:

    * An EKS cluster (or targets an existing one)
    * Amazon RDS for PostgreSQL (9 databases)
    * Amazon ElastiCache for Redis
    * IAM roles and policies for IRSA (IAM Roles for Service Accounts)
    * Helm chart installation with marketplace-specific values
  </Tab>
</Tabs>

## Billing Integration

AWS billing uses the **MeterUsage** and **RegisterUsage** APIs for consumption tracking.

### Pricing Model

AWS Marketplace requires **contract-based pricing** for the most favorable fee structure:

| Model                      | Fee             | Mechanism                                             |
| -------------------------- | --------------- | ----------------------------------------------------- |
| **Contract**               | 3%              | Customer commits to a term (monthly/annual)           |
| **Contract + Consumption** | 3% base + usage | Contract base plus metered overage via MeterUsage API |
| **Private Offer**          | 1.5-3%          | Custom pricing per customer                           |

### Metered Dimensions

| Dimension              | Unit  | API          |
| ---------------------- | ----- | ------------ |
| `agents_registered`    | count | `MeterUsage` |
| `api_requests`         | count | `MeterUsage` |
| `data_transfer_out_gb` | GB    | `MeterUsage` |
| `health_checks`        | count | `MeterUsage` |

<Note>
  AWS enforces stricter dimension naming conventions than GCP or Azure. Dimension names must use snake\_case and match exactly between the listing definition and the metering API calls.
</Note>

## Container Image Publishing

The CI/CD pipeline publishes images to Amazon ECR as part of the multi-registry strategy:

```yaml theme={null}
# ci-main.yml excerpt
- name: Push to ECR
  run: |
    aws ecr get-login-password --region us-east-1 | \
      docker login --username AWS --password-stdin $ECR_REGISTRY
    docker tag emergence/governance:$VERSION $ECR_REGISTRY/emergence/governance:$VERSION
    docker push $ECR_REGISTRY/emergence/governance:$VERSION
```

The following images are published:

* 3 production services (Governance, Assets, Utils)
* 5 subchart images (Keycloak, OpenFGA, PostgreSQL, Redis, Infisical (or ESO))
* 4 init container images (schema migration, bootstrap, health-check, seed data)

## Prerequisites for Deployment

Before deploying from AWS Marketplace:

1. **EKS cluster** -- An existing EKS cluster (1.28+) with managed node groups or Fargate profiles
2. **Amazon RDS** -- PostgreSQL 17+ instance with 9 databases
3. **ElastiCache** -- Redis 7 cluster for caching and event streaming
4. **IAM** -- IRSA (IAM Roles for Service Accounts) configured for service-to-AWS authentication
5. **Networking** -- VPC with private subnets and security groups allowing cluster-to-database connectivity

## Comparison with GCP and Azure

| Aspect              | AWS                          | GCP                     | Azure                     |
| ------------------- | ---------------------------- | ----------------------- | ------------------------- |
| **Offer Type**      | Container Product            | Terraform K8s App       | Container Offer (K8s App) |
| **Packaging**       | Container images + Helm      | Helm + Terraform module | CNAB bundle               |
| **Commit Drawdown** | EDP                          | MCPO                    | MACC                      |
| **Fee Structure**   | 3% contract / 1.5-3% private | 3% / 1.5% renewals      | \~3% flat                 |
| **Complexity**      | Moderate                     | Lowest                  | Highest                   |

## Troubleshooting

<AccordionGroup>
  <Accordion title="ECR image pull failures">
    Verify the EKS node role has the `ecr:GetDownloadUrlForLayer`, `ecr:BatchGetImage`, and `ecr:GetAuthorizationToken` permissions. Ensure the ECR repository policy allows cross-account access if the customer's EKS cluster is in a different AWS account.
  </Accordion>

  <Accordion title="MeterUsage API returns InvalidProductCode">
    Confirm the product code matches the listing ID in AMMP. Ensure the metering calls originate from within the customer's AWS account using IRSA credentials.
  </Accordion>

  <Accordion title="EDP credits not being applied">
    Verify the customer's EDP agreement covers AWS Marketplace purchases. Some older EDP agreements exclude marketplace spend -- the customer should contact their AWS account team.
  </Accordion>
</AccordionGroup>

## Next Steps

<CardGroup cols={2}>
  <Card title="GCP Marketplace" icon="cloud" href="/guides/marketplace/gcp">
    Learn about the GCP Marketplace listing and GKE deployment.
  </Card>

  <Card title="Azure Marketplace" icon="cloud" href="/guides/marketplace/azure">
    Learn about the Azure Marketplace listing and AKS deployment.
  </Card>
</CardGroup>
