import { api } from './client'

export const fetchSimulationConfig = () => api.get('/api/v1/simulation/config')
export const fetchScenarios = () => api.get('/api/v1/simulation/scenarios')
export const fetchSessions = () => api.get('/api/v1/simulation/sessions')
export const fetchRuns = () => api.get('/api/v1/simulation/runs')
export const fetchRun = (runId) => api.get(`/api/v1/simulation/runs/${runId}`)
export const startRun = (body) => api.post('/api/v1/simulation/runs', body)
export const startSession = (sessionId, body = {}) =>
  api.post(`/api/v1/simulation/sessions/${sessionId}/start`, body)
export const stopRun = (runId) => api.post(`/api/v1/simulation/runs/${runId}/stop`)
export const fetchDataSummary = () => api.get('/api/v1/simulation/data/summary')
export const purgeData = () => api.delete('/api/v1/simulation/data')
