Skip to main content

Base URL

All API requests should be made to:
http://localhost:5000/api

Authentication

Currently, the SimulationBank API does not require authentication. All endpoints are publicly accessible for development and testing purposes.
In a production environment, you should implement proper authentication mechanisms such as API keys or OAuth tokens.

Response Format

All API responses follow a consistent JSON format:

Success Response

{
  "status": "success",
  "data": {
    // Response data specific to the endpoint
  }
}

Error Response

{
  "status": "error",
  "message": "Description of what went wrong",
  "code": "ERROR_CODE"
}

Common Error Codes

400
Bad Request
Invalid request parameters or malformed JSON body.
404
Not Found
The requested resource does not exist.
409
Conflict
Request conflicts with current state (e.g., trying to start an already running simulation).
500
Internal Server Error
An unexpected error occurred on the server.

Rate Limits

Currently, there are no rate limits enforced on API endpoints. However, running multiple concurrent simulations may impact performance.
Only one simulation can be active at a time. Attempting to start a new simulation while one is running will result in a 409 Conflict error.

Request Headers

All requests should include:
Content-Type: application/json

API Resources

The SimulationBank API provides the following resource endpoints:
  • Simulation - Control simulation lifecycle (start, pause, stop, get state)
  • Metrics - Retrieve simulation metrics and reports
  • Tellers - Query teller state and statistics

Data Models

Detailed schema documentation for request and response objects:

Build docs developers (and LLMs) love