{"uid":"cap_DSKeoVGZA6-v-lNStXhUb","slug":"cloud-world-model-inject-traffic-5bffb1df","name":"Cloud World Model – Inject Traffic","description":"Simulate AWS, GCP, Azure, OCI, and DigitalOcean cloud infrastructure without provisioning real resources. Built for Canvas Cloud AI learners and agents.","url":"https://www.cloudworldmodel.ai/api/simulations/%7BsimulationId%7D/inject-traffic","method":"POST","headers":{},"bodySchema":{"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}}},"responseSchema":{"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}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_-ZTYt23lS5Vuto39gE66w","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Injects a simulated HTTP traffic spike into a running cloud infrastructure simulation to test autoscaling and load handling","exampleAgentPrompt":"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.","exampleUseCases":[{"title":"Autoscaling stress test in simulation","prompt":"I'm running a simulated AWS environment on Cloud World Model with ID sim-abc123 — can you inject a big HTTP traffic spike into it so I can see if the autoscaling policies kick in correctly?"},{"title":"Load resilience training for RL agent","prompt":"My reinforcement learning agent is training on a cloud simulation with ID sim-xyz789. Send a sudden traffic burst to that simulation so the agent has to learn how to respond to a load event."},{"title":"Chaos engineering drill without real infra","prompt":"I want to do a chaos engineering exercise without touching production — inject a heavy HTTP traffic event into simulation sim-def456 on Cloud World Model and tell me what the resulting RPS and severity look like."}],"resultDescription":"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).","failureModes":["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"],"whenToPreferThis":"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.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T00:45:24.210Z","isFirstParty":false}