An Amazon S3 API mock for testing object uploads.

Upload an export to a seeded bucket, then download it by key to check its bytes and content type. The trace records the PUT request.

Connect your agent
The test
  • object_uploaded

    Calls PUT /*/*

Starting records

  • buckets

    name
    acme-exports
  • buckets / acme-exports / objects

    key
    exports/ridgeway-robotics/2026-06/orders.csv

Connect your agent to the Amazon S3 mock

When ancha runs your agent, it sets:

  • AWS_ENDPOINT_URL_S3
  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • AWS_REGION

Point the client you already use at them.

import { S3Client, ListBucketsCommand } from '@aws-sdk/client-s3';
const s3 = new S3Client({ endpoint: process.env.AWS_ENDPOINT_URL_S3, forcePathStyle: true });
const { Buckets } = await s3.send(new ListBucketsCommand({}));

Locally, ancha runs your agent as an ordinary process, so keep real Amazon S3 credentials out of its environment.

See all 25 endpoints

{Bucket}

HEAD/{Bucket}
GET/{Bucket}
PUT/{Bucket}
DELETE/{Bucket}
HEAD/{Bucket}/{Key+}
GET/{Bucket}/{Key+}
PUT/{Bucket}/{Key+}
DELETE/{Bucket}/{Key+}
PUT/{Bucket}/{Key+} (x-amz-copy-source)
PUT/{Bucket}/{Key+}?partNumber&uploadId
GET/{Bucket}/{Key+}?tagging
PUT/{Bucket}/{Key+}?tagging
DELETE/{Bucket}/{Key+}?tagging
GET/{Bucket}/{Key+}?uploadId
POST/{Bucket}/{Key+}?uploadId
DELETE/{Bucket}/{Key+}?uploadId
POST/{Bucket}/{Key+}?uploads

{Bucket}?delete

POST/{Bucket}?delete

{Bucket}?list-type=2

GET/{Bucket}?list-type=2

{Bucket}?location

GET/{Bucket}?location

{Bucket}?tagging

GET/{Bucket}?tagging
PUT/{Bucket}?tagging
DELETE/{Bucket}?tagging

{Bucket}?uploads

GET/{Bucket}?uploads

versions

GET/

Seed your own data

The data the Amazon S3 mock starts with on every run, cut to a few records. ancha twins seed amazon-s3 prints every field.

Full seed YAML
twins:
  - amazon-s3
seed:
  amazon-s3:
    account:
      id: "481516234200"
      name: acme-production
    buckets:
      - name: acme-exports
        created: -6000h
        tags:
          team: platform
          env: production
        objects:
          - key: exports/ridgeway-robotics/2026-06/orders.csv
            content: |
              order_id,placed_at,warehouse,total_usd
              A-20931,2026-06-02,reno,1840.5
              A-21044,2026-06-09,reno,932
            contentType: text/csv
            modified: -3400h
            storageClass: GLACIER
            tags:
              customer: ridgeway-robotics
              retention: 400d

Check what your agent did

Checks YAML
checks:
  - id: object_uploaded
    trace:
      called: PUT /*/*

More docs and files tools

All 43 tools

Amazon S3 API mock FAQ

How do I test S3 uploads that must not overwrite an existing object?

Send PutObject with If-None-Match: *; Ancha returns PreconditionFailed when the key already exists. For an update to an existing object, If-Match checks its stored ETag and returns PreconditionFailed on a mismatch.

Does the S3 mock return folders and continuation tokens in ListObjectsV2?

With prefix and delimiter, Ancha groups matching keys into CommonPrefixes and returns individual objects in Contents. When max-keys leaves more entries, the response includes IsTruncated and NextContinuationToken; send that value as continuation-token to continue.

Can I check an agent that downloads only part of an S3 object?

A valid single Range such as bytes=0-99 returns the selected bytes with status 206 and a Content-Range header. A range that starts beyond the object's last byte returns InvalidRange.

Install the CLI and run your agent against the Amazon S3 mock.

Book a demo

Ancha is not affiliated with Amazon S3.