---
title: "Update a simulation"
method: PUT
path: "/simulations/{sim_identifier}"
tags: ["basic"]
---

# Update a simulation

`PUT /simulations/{sim_identifier}`

## Path parameters

- `sim_identifier` integer, required

## Request body

- SimulationDetailed
  - `detail_type` string, required
  - `identifier` integer, required
  - `description` string
  - `created` string, date-time, required
  - `result` integer, required — 0 is scheduled, -1 is prep failed, -100 is sim failed, 100 is sim succeeded
  - `environment_name` string, required — Name of the simulation environment
  - `queued_task_identifier` string — Identifier of the task associated to this simulation
  - `queued_task_state` integer — Read only value, taken from associated task
  - `config` object, required — Configuration of the simulation.
  - `on_complete_action` object — Action to take when simulation completes.
  - `environment` SimulationEnvironmentDetailed
    - `detail_type` string, required
    - `name` string, required
    - `module_name` string, required
    - `rosbag_store` string
    - `config` object, required — Configuration of the simulation environment.
    - `example_config` string, required — Example simulation configuration shown in the simulation overview
  - `runs` SimulationRunDetailed[] — Read only value, expanded on request.
    - `detail_type` string, required
    - `identifier` integer, required
    - `success` boolean, required
    - `description` string, required
    - `duration` number, required
    - `bag_name` string
    - `bag_store_name` string
    - `results` object, required — Configuration of the simulation.
    - `bag` BagSummary
      - `detail_type` string, required
      - `name` string, required
      - `store_data` object, required — Data that is specific to the bag store type.
      - `discovered` string, date-time, required — Date and time this bag was discovered.
      - `extraction_failure` boolean — True if the extraction failed
      - `in_trash` boolean — True if the bag is in the trash bin.
      - `is_extracted` boolean, required — True if data is extracted from this bag.
      - `meta_available` boolean, required — True if meta data is known for this bag.
      - `size` integer — Size of the bag in bytes.
      - `start_time` string, date-time — Start time of this bag.
      - `end_time` string, date-time — Start time of this bag.
      - `duration` number — duration of this bag in seconds.
      - `messages` integer — Number of messages in this bag.
      - `tags` Tag[]
        - `tag` string, required
        - `color` string, required
  - `queued_task` TaskDetailed
    - `detail_type` string, required
    - `identifier` string, required
    - `priority` number, required
    - `description` string, required — Simple description to identify the type of task
    - `assigned_to` string, required — Name of worker assigned to the task.
    - `created` string, date-time, required — Date the task was added to the queue.
    - `last_updated` string, date-time, required — Date the task was updated to the queue.
    - `state` integer, required — State of the task.
    - `task` string, required — The task.
    - `success` boolean, required
    - `runtime` number, required
    - `worker_labels` string, required — Worker that can take this task.
    - `config` object — Configuration of the task.
    - `result` object — Result of the task
    - `log` string — Standard output of the task

## Response `200`

Returns the simulation

## Other responses

- `400` — General error
- `404` — Simulation not found

---

[API](https://skmtc.net/amz-racing/apis/rosbag-bazaar-api.md) · [All operations](https://skmtc.net/amz-racing/apis/rosbag-bazaar-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/amz-racing/rosbag-bazaar-api/versions/9167cc5a1f11/schema)
