# Cloud World Model – Inject Traffic

> Cloud World Model – Inject Traffic is a paid API for AI agents from www.cloudworldmodel.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Injects a simulated HTTP traffic spike into a running cloud infrastructure simulation to test autoscaling and load handling

## Facts

- Endpoint: POST https://www.cloudworldmodel.ai/api/simulations/%7BsimulationId%7D/inject-traffic
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/cloud-world-model-inject-traffic-5bffb1df
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_DSKeoVGZA6-v-lNStXhUb

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability cloud-world-model-inject-traffic-5bffb1df -d '<json body>'
```

Example prompt: Inject an HTTP traffic spike into my running Cloud World Model simulation sim-abc123 — I want to see how the environment reacts to a sudden surge in requests.

## When to prefer this

Use this endpoint when you need to test how a simulated cloud environment responds to sudden HTTP traffic surges without provisioning real infrastructure. It is ideal for RL agent training loops, chaos engineering drills, and autoscaling validation in sandbox environments. Prefer it over real load testing tools (e.g., k6, Locust) when you want zero real-infra cost and instant safe experimentation across AWS, GCP, Azure, OCI, or DigitalOcean simulations.

## Known failure modes

- Invalid or non-existent simulationId returns an error or 404-equivalent
- Malformed input body or missing required fields (type, method, bodyType, body) causes a 400-level error
- Simulation not in a running state may reject traffic injection
- Payment failure or insufficient USDC balance prevents the call from completing (x402 payment required)
- Injecting traffic while simulation is paused or completed may return an error or stale state

## How this service works

Simulate AWS, GCP, Azure, OCI, and DigitalOcean cloud infrastructure without provisioning real resources. Built for Canvas Cloud AI learners and agents.

## Output

Returns a JSON object with two top-level keys: 'event' (containing event ID, a human-readable message describing the traffic spike magnitude e.g. '1000 → 4200 RPS', severity level, and simulation ID) and 'simulation' (containing the simulation ID, new traffic value in RPS, and current simulation time in seconds).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "targetRps": {
   "type": "integer",
   "maximum": 500000,
   "minimum": 1,
   "description": "Absolute traffic target in RPS. Takes precedence over deltaPercent. Deactivates any active traffic patterns so the level persists across steps."
  },
  "deltaPercent": {
   "type": "number",
   "description": "Relative traffic change in percent (e.g. 75 = +75% of current traffic). Ignored when targetRps is supplied.",
   "exclusiveMinimum": -100
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "mode": "target_rps",
  "event": {
   "id": "evt-id",
   "message": "Traffic set (target_rps): 400 → 700 RPS (+300 RPS)",
   "severity": "info",
   "simulationId": "sim-abc123"
  },
  "appliedRps": 700,
  "simulation": {
   "id": "sim-abc123",
   "traffic": 700,
   "currentTime": 5
  },
  "previousRps": 400
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/cloud-world-model-inject-traffic-5bffb1df/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from www.cloudworldmodel.ai](https://www.zero.xyz/host/www.cloudworldmodel.ai/llms.txt)
