Skip to main content

Simulated Events Testing Guide

The simulation endpoints allow POS integrators to test their webhook implementations without requiring physical range hardware. These endpoints are available on the playground environment.

Base URL: https://playground.action-target.net/api/v2/pos/simulate

Note: Simulation endpoints are intended for development and testing only. They are not available on production environments.


How It Works

  1. Create a real session (optional) - Use POST /sessions with your credentials against the playground simserver
  2. Trigger test events - Use the simulate endpoints to send events to your webhook
  3. Verify your webhook - Confirm your system receives and processes events correctly

The simulate endpoints send events directly to your configured webhook URL. This allows you to verify:

  • Your webhook endpoint receives events correctly
  • Your system parses event payloads properly
  • Your error handling works as expected

Product Endpoints

These endpoints fetch products from your configured Products API, allowing you to verify your product catalog integration.

GET /simulate/products

Fetches all product types from your POS provider.

Headers:

  • session-id (optional): Session ID

Response: Object with product arrays by type

GET /simulate/products/{type}

Fetches products of a specific type from your POS provider.

Parameters:

  • type: Product type (ammo, targets, rentals, or time)

Headers:

  • session-id (optional): Session ID

Response: Array of Product objects


Lane Event Simulation

These endpoints simulate events that occur during an active session on a lane.

All event endpoints accept an optional session_id. If provided, the system will look up the real session to get the associated lane_id. If omitted (or if the session is not found), simulated IDs will be used.

POST /simulate/help

Simulates a customer requesting staff assistance from the lane.

Request Body:

{
"session_id": "uuid"
}
FieldDescription
session_idOptional. If provided, looks up real session for lane_id.

Response: 201 Created with the event payload sent to your webhook

POST /simulate/carrierHit

Simulates the carrier/trolley being shot and returned home.

Request Body:

{
"session_id": "uuid"
}

Response: 201 Created with the event payload sent to your webhook

POST /simulate/purchaseRequest

Simulates a customer requesting a purchase from the lane.

Request Body:

{
"session_id": "uuid",
"product_id": "string",
"qty": 1
}
FieldDescription
session_idOptional. If provided, looks up real session for lane_id.
product_idRequired. The product ID from your catalog.
qtyRequired. Quantity requested.

Response: 201 Created with the event payload sent to your webhook

POST /simulate/addTime

Simulates a time extension request from the lane.

Request Body:

{
"session_id": "uuid",
"qty": 30
}
FieldDescription
session_idOptional. If provided, looks up real session for lane_id.
qtyRequired. Minutes to add.

Response: 201 Created with the event payload sent to your webhook


Session Lifecycle Event Simulation

These endpoints simulate session lifecycle events. Use them to test how your system handles sessions created or stopped from the SRA Control Screen.

Event Types

EventDescription
sessionCreatedA new session was created
sessionStartedCustomer entered the lane and session timer began
sessionPausedSession was paused (e.g., during a ceasefire)
sessionResumedSession was resumed after a pause
sessionStoppedSession ended
sessionModifiedSession duration was modified

POST /simulate/sessionCreated

Simulates a session creation event being sent to your webhook.

Request Body:

{
"session_id": "uuid"
}
FieldDescription
session_idOptional. If provided, looks up real session for lane_id.

Response: 201 Created with the event payload sent to your webhook

POST /simulate/sessionStarted

POST /simulate/sessionPaused

POST /simulate/sessionResumed

POST /simulate/sessionStopped

POST /simulate/sessionModified

All use the same request body format as sessionCreated.

Note: When you receive a sessionStopped event, the session will no longer appear in the /sessions API response.