Skip to content

User Endpoints

Get a paginated list of the authenticated user’s simulations.

GET /user/simulations?page_size=10&page_idx=1
Cookie: access_token=<jwt>

Query parameters:

ParameterTypeDefaultDescription
page_sizeinteger6Number of simulations per page
page_idxinteger1Page number (1-indexed)
order_bystringstart_timeSort field: start_time or end_time
order_typestringdescendSort order: ascend or descend
job_statestringFilter by state(s), comma-separated: COMPLETED,FAILED

Response 200 OK

{
"message": "User simulations",
"simulations": [
{
"job_id": "abc123-def456",
"title": "Water phantom dose",
"start_time": "2024-01-15T10:00:00Z",
"end_time": "2024-01-15T10:05:23Z",
"job_state": "COMPLETED",
"sim_type": "shieldhit",
"input_type": "editor",
"platform": "direct",
"ntasks": 10
},
{
"job_id": "batch-789xyz",
"title": "Carbon beam spread",
"start_time": "2024-01-14T14:00:00Z",
"end_time": "2024-01-14T15:30:00Z",
"job_state": "COMPLETED",
"sim_type": "shieldhit",
"input_type": "editor",
"platform": "batch",
"ntasks": 100
}
],
"page_count": 5,
"simulations_count": 47
}

Filtering by state:

GET /user/simulations?job_state=COMPLETED,FAILED

Returns only simulations in the specified states.


Remove a simulation and all its associated data (results, logfiles, inputs) from the database. The simulation must be in a terminal state (COMPLETED, FAILED, or CANCELED).

DELETE /user/simulations?job_id=abc123-def456
Cookie: access_token=<jwt>

Response 200 OK

{
"message": "Simulation deleted"
}

Errors:

  • 400 — Missing job_id
  • 403 — Simulation belongs to another user
  • 404 — Simulation not found
  • 409 — Simulation is still running (cannot delete)

Update the authenticated user’s profile information.

POST /user/update
Cookie: access_token=<jwt>
Content-Type: application/json
{
"field": "value"
}

Response 200 OK

{
"message": "User updated"
}

List available HPC clusters for batch job submission. Requires Keycloak authentication (PLGrid access).

GET /clusters
Cookie: access_token=<jwt>

Response 200 OK

{
"message": "Available clusters",
"clusters": [
{
"cluster_name": "prometheus",
"display_name": "Prometheus (Cyfronet)",
"available": true
}
]
}

Errors:

  • 403 — Not a Keycloak-authenticated user (local users cannot access HPC clusters)