{
  "openapi": "3.1.0",
  "info": {
    "title": "GPU Kitchen controller API",
    "version": "1",
    "description": "The stable management API of a GPU Kitchen controller. Send a management key as a Bearer token, or call it from a signed-in browser session. Operations marked session-only refuse a management key. Guide: https://gpu.kitchen/docs/management-api/"
  },
  "servers": [
    {
      "url": "https://gpu-kitchen.example.lan",
      "description": "Your controller: the address you open the GPU Kitchen app with."
    }
  ],
  "tags": [
    {
      "name": "access-grid"
    },
    {
      "name": "audit-log"
    },
    {
      "name": "auth"
    },
    {
      "name": "authentication"
    },
    {
      "name": "benchmarks"
    },
    {
      "name": "budgets"
    },
    {
      "name": "containers"
    },
    {
      "name": "engines"
    },
    {
      "name": "fair-share"
    },
    {
      "name": "feature-flags"
    },
    {
      "name": "gpus"
    },
    {
      "name": "inference-credentials"
    },
    {
      "name": "mail"
    },
    {
      "name": "management-keys"
    },
    {
      "name": "me"
    },
    {
      "name": "members"
    },
    {
      "name": "menu"
    },
    {
      "name": "models"
    },
    {
      "name": "nodes"
    },
    {
      "name": "planning"
    },
    {
      "name": "production-reports"
    },
    {
      "name": "recipes"
    },
    {
      "name": "reservations"
    },
    {
      "name": "teams"
    },
    {
      "name": "templates"
    },
    {
      "name": "usage"
    }
  ],
  "paths": {
    "/api/v1/access-grid": {
      "get": {
        "operationId": "getAccessGrid",
        "summary": "Read the access grid and its editable rules",
        "tags": [
          "access-grid"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "scope": {
                      "type": "object",
                      "properties": {
                        "admin": {
                          "type": "boolean"
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      },
                      "required": [
                        "admin",
                        "teams"
                      ],
                      "additionalProperties": false
                    },
                    "rules": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "revision": {
                            "type": "string",
                            "pattern": "^[a-f0-9]{64}$"
                          },
                          "orphaned": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "scope_team_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "subject_type": {
                            "type": "string",
                            "enum": [
                              "all",
                              "team",
                              "member",
                              "application",
                              "key"
                            ]
                          },
                          "subject_id": {
                            "type": "string"
                          },
                          "resource_type": {
                            "type": "string",
                            "enum": [
                              "all",
                              "local",
                              "external",
                              "provider",
                              "model"
                            ]
                          },
                          "resource_id": {
                            "type": "string"
                          },
                          "access": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "allow",
                                  "deny",
                                  "local_only"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rpm_limit": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "tpm_limit": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "monthly_budget": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "note": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "usage": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "spend": {
                                    "type": "string"
                                  },
                                  "blocked_until": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "spend",
                                  "blocked_until"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "revision",
                          "orphaned",
                          "scope_team_id",
                          "subject_type",
                          "subject_id",
                          "resource_type",
                          "resource_id",
                          "access",
                          "rpm_limit",
                          "tpm_limit",
                          "monthly_budget",
                          "note",
                          "usage",
                          "created_at",
                          "updated_at"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "catalog": {
                      "type": "object",
                      "properties": {
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "name"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "members": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "email": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "name": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "email",
                              "name"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "keys": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key_id": {
                                "type": "string"
                              },
                              "label": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "team_id": {
                                "type": "string"
                              },
                              "member_id": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "subject_type": {
                                "type": "string",
                                "enum": [
                                  "user",
                                  "app"
                                ]
                              }
                            },
                            "required": [
                              "key_id",
                              "label",
                              "team_id",
                              "member_id",
                              "subject_type"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "applications": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "number"
                              },
                              "name": {
                                "type": "string"
                              },
                              "slug": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "slug"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "models": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "model": {
                                "type": "string"
                              },
                              "provider_id": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              },
                              "off_site": {
                                "type": "boolean"
                              },
                              "shared_pool": {
                                "type": "boolean"
                              },
                              "team_pools": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              }
                            },
                            "required": [
                              "model",
                              "provider_id",
                              "off_site"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "teams",
                        "members",
                        "keys",
                        "applications",
                        "providers",
                        "models"
                      ],
                      "additionalProperties": false
                    },
                    "history": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "actor_member_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "action": {
                            "type": "string"
                          },
                          "target": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "at",
                          "actor_member_id",
                          "action",
                          "target"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "enabled",
                    "scope",
                    "rules",
                    "catalog",
                    "history"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-33",
          "EAU-58",
          "EAU-60"
        ]
      }
    },
    "/api/v1/access-grid/orphans": {
      "delete": {
        "operationId": "deleteAccessGridOrphans",
        "summary": "Delete orphaned access-grid rules",
        "tags": [
          "access-grid"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "rules": {
                    "minItems": 1,
                    "maxItems": 10000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 2147483647
                        },
                        "revision": {
                          "type": "string",
                          "pattern": "^[a-f0-9]{64}$"
                        }
                      },
                      "required": [
                        "id",
                        "revision"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "rules"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: access_grid_selection_changed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-60",
          "API-67",
          "ERG-48"
        ]
      }
    },
    "/api/v1/access-grid/preview": {
      "get": {
        "operationId": "previewAccessGrid",
        "summary": "Preview a key or member's effective model access",
        "tags": [
          "access-grid"
        ],
        "parameters": [
          {
            "name": "key_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "member_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key_id": {
                            "type": "string"
                          },
                          "team_id": {
                            "type": "string"
                          },
                          "member_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "governed": {
                            "type": "boolean"
                          },
                          "models": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "model": {
                                  "type": "string"
                                },
                                "provider_id": {
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "off_site": {
                                  "type": "boolean"
                                },
                                "key_allowed": {
                                  "type": "boolean"
                                },
                                "allowed": {
                                  "type": "boolean"
                                },
                                "slot": {
                                  "type": "string",
                                  "enum": [
                                    "shared",
                                    "reserved_for_your_team",
                                    "reserved_for_other_team"
                                  ]
                                },
                                "access": {
                                  "anyOf": [
                                    {
                                      "type": "object",
                                      "properties": {
                                        "value": {
                                          "anyOf": [
                                            {
                                              "type": "string",
                                              "enum": [
                                                "allow",
                                                "deny",
                                                "local_only"
                                              ]
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        },
                                        "rule_id": {
                                          "type": "number"
                                        }
                                      },
                                      "required": [
                                        "value",
                                        "rule_id"
                                      ],
                                      "additionalProperties": false
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "rpm": {
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "limit": {
                                        "type": [
                                          "number",
                                          "null"
                                        ]
                                      },
                                      "rule_id": {
                                        "type": "number"
                                      }
                                    },
                                    "required": [
                                      "limit",
                                      "rule_id"
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "tpm": {
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "limit": {
                                        "type": [
                                          "number",
                                          "null"
                                        ]
                                      },
                                      "rule_id": {
                                        "type": "number"
                                      }
                                    },
                                    "required": [
                                      "limit",
                                      "rule_id"
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "monthly_budget": {
                                  "type": "array",
                                  "items": {
                                    "anyOf": [
                                      {
                                        "type": "object",
                                        "properties": {
                                          "rule_id": {
                                            "type": "number"
                                          }
                                        },
                                        "required": [
                                          "rule_id"
                                        ],
                                        "additionalProperties": false
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "blocked_until": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "format": "date-time"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "model",
                                "provider_id",
                                "off_site",
                                "key_allowed",
                                "allowed",
                                "slot",
                                "access",
                                "rpm",
                                "tpm",
                                "monthly_budget",
                                "blocked_until"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "key_id",
                          "team_id",
                          "member_id",
                          "governed",
                          "models"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "enabled",
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-60",
          "PLN-22",
          "API-48"
        ]
      }
    },
    "/api/v1/access-grid/rules": {
      "post": {
        "operationId": "createAccessGridRule",
        "summary": "Create an access-grid rule",
        "tags": [
          "access-grid"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "scope_team_id": {
                    "type": "string"
                  },
                  "subject_type": {
                    "type": "string",
                    "enum": [
                      "all",
                      "team",
                      "member",
                      "application",
                      "key"
                    ]
                  },
                  "subject_id": {
                    "default": "",
                    "type": "string",
                    "maxLength": 200
                  },
                  "resource_type": {
                    "type": "string",
                    "enum": [
                      "all",
                      "local",
                      "external",
                      "provider",
                      "model"
                    ]
                  },
                  "resource_id": {
                    "type": [
                      "string",
                      "number"
                    ]
                  },
                  "access": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "allow",
                          "deny",
                          "local_only"
                        ]
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "rpm_limit": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 2147483647
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "tpm_limit": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 2147483647
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "monthly_budget": {
                    "type": [
                      "string",
                      "number",
                      "null"
                    ]
                  },
                  "note": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 500
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "subject_type",
                  "resource_type"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "revision": {
                      "type": "string",
                      "pattern": "^[a-f0-9]{64}$"
                    },
                    "orphaned": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "scope_team_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "subject_type": {
                      "type": "string",
                      "enum": [
                        "all",
                        "team",
                        "member",
                        "application",
                        "key"
                      ]
                    },
                    "subject_id": {
                      "type": "string"
                    },
                    "resource_type": {
                      "type": "string",
                      "enum": [
                        "all",
                        "local",
                        "external",
                        "provider",
                        "model"
                      ]
                    },
                    "resource_id": {
                      "type": "string"
                    },
                    "access": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "allow",
                            "deny",
                            "local_only"
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "rpm_limit": {
                      "type": [
                        "number",
                        "null"
                      ]
                    },
                    "tpm_limit": {
                      "type": [
                        "number",
                        "null"
                      ]
                    },
                    "monthly_budget": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "note": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "usage": {
                      "anyOf": [
                        {
                          "type": "object",
                          "properties": {
                            "spend": {
                              "type": "string"
                            },
                            "blocked_until": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "spend",
                            "blocked_until"
                          ],
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "updated_at": {
                      "type": "string",
                      "format": "date-time"
                    }
                  },
                  "required": [
                    "id",
                    "revision",
                    "orphaned",
                    "scope_team_id",
                    "subject_type",
                    "subject_id",
                    "resource_type",
                    "resource_id",
                    "access",
                    "rpm_limit",
                    "tpm_limit",
                    "monthly_budget",
                    "note",
                    "usage",
                    "created_at",
                    "updated_at"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: access_grid_rule_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: access_grid_rule_exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-33",
          "EAU-58",
          "EAU-60",
          "API-67"
        ]
      }
    },
    "/api/v1/access-grid/rules/{id}": {
      "delete": {
        "operationId": "deleteAccessGridRule",
        "summary": "Delete an access-grid rule",
        "tags": [
          "access-grid"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: access_grid_rule_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-60",
          "API-48",
          "API-67"
        ]
      },
      "put": {
        "operationId": "updateAccessGridRule",
        "summary": "Update an access-grid rule",
        "tags": [
          "access-grid"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "scope_team_id": {
                    "type": "string"
                  },
                  "subject_type": {
                    "type": "string",
                    "enum": [
                      "all",
                      "team",
                      "member",
                      "application",
                      "key"
                    ]
                  },
                  "subject_id": {
                    "default": "",
                    "type": "string",
                    "maxLength": 200
                  },
                  "resource_type": {
                    "type": "string",
                    "enum": [
                      "all",
                      "local",
                      "external",
                      "provider",
                      "model"
                    ]
                  },
                  "resource_id": {
                    "type": [
                      "string",
                      "number"
                    ]
                  },
                  "access": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "allow",
                          "deny",
                          "local_only"
                        ]
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "rpm_limit": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 2147483647
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "tpm_limit": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 2147483647
                      },
                      {
                        "type": "string",
                        "const": ""
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "monthly_budget": {
                    "type": [
                      "string",
                      "number",
                      "null"
                    ]
                  },
                  "note": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 500
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "subject_type",
                  "resource_type"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "revision": {
                      "type": "string",
                      "pattern": "^[a-f0-9]{64}$"
                    },
                    "orphaned": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "scope_team_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "subject_type": {
                      "type": "string",
                      "enum": [
                        "all",
                        "team",
                        "member",
                        "application",
                        "key"
                      ]
                    },
                    "subject_id": {
                      "type": "string"
                    },
                    "resource_type": {
                      "type": "string",
                      "enum": [
                        "all",
                        "local",
                        "external",
                        "provider",
                        "model"
                      ]
                    },
                    "resource_id": {
                      "type": "string"
                    },
                    "access": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "allow",
                            "deny",
                            "local_only"
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "rpm_limit": {
                      "type": [
                        "number",
                        "null"
                      ]
                    },
                    "tpm_limit": {
                      "type": [
                        "number",
                        "null"
                      ]
                    },
                    "monthly_budget": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "note": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "usage": {
                      "anyOf": [
                        {
                          "type": "object",
                          "properties": {
                            "spend": {
                              "type": "string"
                            },
                            "blocked_until": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "spend",
                            "blocked_until"
                          ],
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "updated_at": {
                      "type": "string",
                      "format": "date-time"
                    }
                  },
                  "required": [
                    "id",
                    "revision",
                    "orphaned",
                    "scope_team_id",
                    "subject_type",
                    "subject_id",
                    "resource_type",
                    "resource_id",
                    "access",
                    "rpm_limit",
                    "tpm_limit",
                    "monthly_budget",
                    "note",
                    "usage",
                    "created_at",
                    "updated_at"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: access_grid_rule_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: access_grid_rule_exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-33",
          "EAU-58",
          "API-48"
        ]
      }
    },
    "/api/v1/access-grid/settings": {
      "put": {
        "operationId": "setAccessGridSettings",
        "summary": "Enable or disable the access grid",
        "tags": [
          "access-grid"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "enabled": {
                    "type": "boolean"
                  }
                },
                "required": [
                  "enabled"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "enabled"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, enterprise_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-58",
          "EAU-60"
        ]
      }
    },
    "/api/v1/audit-log": {
      "get": {
        "operationId": "listAuditLog",
        "summary": "Read the administration audit journal",
        "description": "Newest first; paginated with `limit` and `cursor`.",
        "tags": [
          "audit-log"
        ],
        "parameters": [
          {
            "name": "action",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "actor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "involving",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          },
          {
            "name": "scope",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "people"
              ]
            }
          },
          {
            "name": "since",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string",
                  "const": ""
                },
                {
                  "type": "string",
                  "format": "date-time",
                  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                }
              ]
            }
          },
          {
            "name": "target",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "until",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string",
                  "const": ""
                },
                {
                  "type": "string",
                  "format": "date-time",
                  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                }
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "entries": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "actor": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "action": {
                            "type": "string"
                          },
                          "target": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "target_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "subject_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "detail": {}
                        },
                        "required": [
                          "id",
                          "at",
                          "actor",
                          "action",
                          "target",
                          "target_name",
                          "subject_name",
                          "detail"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "facets": {
                      "type": "object",
                      "properties": {
                        "actions": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "actors": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "email": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "name": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "email",
                              "name"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "actions",
                        "actors"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "entries",
                    "next_cursor",
                    "facets"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EDI-15",
          "API-47",
          "API-67"
        ]
      }
    },
    "/api/v1/audit-log/export.csv": {
      "get": {
        "operationId": "exportAuditLog",
        "summary": "Export the audit journal the filters keep, as CSV",
        "description": "Newest first, at most 10000 lines.",
        "tags": [
          "audit-log"
        ],
        "parameters": [
          {
            "name": "action",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "actor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "involving",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "scope",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "people"
              ]
            }
          },
          {
            "name": "since",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string",
                  "const": ""
                },
                {
                  "type": "string",
                  "format": "date-time",
                  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                }
              ]
            }
          },
          {
            "name": "target",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "until",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string",
                  "const": ""
                },
                {
                  "type": "string",
                  "format": "date-time",
                  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                }
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "One line per entry: when, who, what, target and detail.",
            "content": {
              "text/csv; charset=utf-8": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-79"
        ]
      }
    },
    "/api/v1/auth/claim": {
      "post": {
        "operationId": "claimFirstAccount",
        "summary": "Create the cluster's first account",
        "tags": [
          "auth"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "minLength": 1
                  },
                  "password": {
                    "type": "string",
                    "minLength": 8
                  }
                },
                "required": [
                  "email",
                  "password"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "status"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "member"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: invalid_claim_key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: claim_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: profile_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "410": {
            "description": "Error codes: claim_consumed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "SEC-71",
          "API-60"
        ]
      }
    },
    "/api/v1/auth/login": {
      "post": {
        "operationId": "signIn",
        "summary": "Sign in with a login and a password",
        "description": "Opens a browser session (cookie). The login is the email of a local account, or a directory login on an enterprise cluster.",
        "tags": [
          "auth"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "login": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 320
                  },
                  "password": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 1024
                  }
                },
                "required": [
                  "login",
                  "password"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "status"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "member"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: invalid_credentials.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: member_disabled, sso_access_denied, sso_email_unverified, sso_link_required, sso_not_provisioned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "502": {
            "description": "Error codes: ldap_unreachable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "API-07",
          "EAU-11",
          "OPS-48"
        ]
      }
    },
    "/api/v1/auth/logout": {
      "post": {
        "operationId": "signOut",
        "summary": "Sign out of this browser session",
        "tags": [
          "auth"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "API-07"
        ]
      }
    },
    "/api/v1/auth/oidc/{providerId}/callback": {
      "get": {
        "operationId": "finishOidcSignIn",
        "summary": "Return from an OpenID Connect provider",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "code",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "error",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "state",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Back to the sign-in page: `/login?error=<code>` on a refusal, the requested page otherwise."
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "oidc",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-30",
          "EAU-31"
        ]
      }
    },
    "/api/v1/auth/oidc/{providerId}/start": {
      "get": {
        "operationId": "startOidcSignIn",
        "summary": "Start signing in with an OpenID Connect provider",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "redirect",
            "in": "query",
            "required": false,
            "description": "Path of this app to return to once signed in.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "To the provider's authorization page."
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "oidc",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-30",
          "EAU-31"
        ]
      }
    },
    "/api/v1/auth/providers": {
      "get": {
        "operationId": "listAuthProviders",
        "summary": "List the configured sign-in providers",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "providers": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "type": {
                            "type": "string",
                            "enum": [
                              "ldap",
                              "oidc",
                              "saml"
                            ]
                          },
                          "name": {
                            "type": "string"
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "config": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string"
                            },
                            "additionalProperties": {}
                          },
                          "secrets_set": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "group_mappings": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "group": {
                                  "type": "string",
                                  "minLength": 1
                                },
                                "role": {
                                  "type": "string",
                                  "enum": [
                                    "admin",
                                    "user"
                                  ]
                                },
                                "team": {
                                  "type": "string",
                                  "minLength": 1
                                }
                              },
                              "required": [
                                "group"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "last_test_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_test_status": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "ok",
                                  "warn",
                                  "error"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_test_detail": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "type",
                          "name",
                          "enabled",
                          "config",
                          "secrets_set",
                          "group_mappings",
                          "last_test_at",
                          "last_test_status",
                          "last_test_detail",
                          "created_at",
                          "updated_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "providers"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-12",
          "EAU-13",
          "API-60"
        ]
      },
      "post": {
        "operationId": "createAuthProvider",
        "summary": "Create a sign-in provider",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "enabled": {
                    "type": "boolean"
                  },
                  "config": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  },
                  "secrets": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "group_mappings": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "group": {
                          "type": "string",
                          "minLength": 1
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "admin",
                            "user"
                          ]
                        },
                        "team": {
                          "type": "string",
                          "minLength": 1
                        }
                      },
                      "required": [
                        "group"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "ldap",
                      "oidc",
                      "saml"
                    ]
                  }
                },
                "required": [
                  "name",
                  "type"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "provider": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "ldap",
                            "oidc",
                            "saml"
                          ]
                        },
                        "name": {
                          "type": "string"
                        },
                        "enabled": {
                          "type": "boolean"
                        },
                        "config": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {}
                        },
                        "secrets_set": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "group_mappings": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "group": {
                                "type": "string",
                                "minLength": 1
                              },
                              "role": {
                                "type": "string",
                                "enum": [
                                  "admin",
                                  "user"
                                ]
                              },
                              "team": {
                                "type": "string",
                                "minLength": 1
                              }
                            },
                            "required": [
                              "group"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "last_test_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_test_status": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "ok",
                                "warn",
                                "error"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_test_detail": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "type",
                        "name",
                        "enabled",
                        "config",
                        "secrets_set",
                        "group_mappings",
                        "last_test_at",
                        "last_test_status",
                        "last_test_detail",
                        "created_at",
                        "updated_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "provider"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-07",
          "EAU-12",
          "EAU-16",
          "EAU-43",
          "EDI-32"
        ]
      }
    },
    "/api/v1/auth/providers/{id}": {
      "delete": {
        "operationId": "deleteAuthProvider",
        "summary": "Delete a sign-in provider and revoke its sessions",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-37",
          "API-67"
        ]
      },
      "put": {
        "operationId": "updateAuthProvider",
        "summary": "Update a sign-in provider",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "enabled": {
                    "type": "boolean"
                  },
                  "config": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  },
                  "secrets": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "group_mappings": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "group": {
                          "type": "string",
                          "minLength": 1
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "admin",
                            "user"
                          ]
                        },
                        "team": {
                          "type": "string",
                          "minLength": 1
                        }
                      },
                      "required": [
                        "group"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "provider": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "ldap",
                            "oidc",
                            "saml"
                          ]
                        },
                        "name": {
                          "type": "string"
                        },
                        "enabled": {
                          "type": "boolean"
                        },
                        "config": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {}
                        },
                        "secrets_set": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "group_mappings": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "group": {
                                "type": "string",
                                "minLength": 1
                              },
                              "role": {
                                "type": "string",
                                "enum": [
                                  "admin",
                                  "user"
                                ]
                              },
                              "team": {
                                "type": "string",
                                "minLength": 1
                              }
                            },
                            "required": [
                              "group"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "last_test_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_test_status": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "ok",
                                "warn",
                                "error"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_test_detail": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "type",
                        "name",
                        "enabled",
                        "config",
                        "secrets_set",
                        "group_mappings",
                        "last_test_at",
                        "last_test_status",
                        "last_test_detail",
                        "created_at",
                        "updated_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "provider"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-07",
          "EAU-12",
          "EAU-16",
          "EAU-43",
          "EDI-32"
        ]
      }
    },
    "/api/v1/auth/providers/saml-metadata": {
      "post": {
        "operationId": "importSamlMetadata",
        "summary": "Read an identity provider's SAML metadata",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "xml": {
                    "type": "string"
                  },
                  "url": {
                    "type": "string"
                  },
                  "allow_insecure_http": {
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "idp_entity_id": {
                      "type": "string"
                    },
                    "sso_url": {
                      "type": "string"
                    },
                    "idp_certs": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "certificates": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "not_after": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "sha256": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "not_after",
                          "sha256"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "idp_entity_id",
                    "sso_url",
                    "idp_certs",
                    "certificates"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-46"
        ]
      }
    },
    "/api/v1/auth/providers/test": {
      "post": {
        "operationId": "testAuthProvider",
        "summary": "Test a saved or proposed sign-in provider",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "provider_id": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 2147483647
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "ldap",
                      "oidc",
                      "saml"
                    ]
                  },
                  "config": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  },
                  "secrets": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "sample_login": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "enum": [
                        "ok",
                        "warn",
                        "error"
                      ]
                    },
                    "checks": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "ok",
                              "warn",
                              "error"
                            ]
                          },
                          "detail": {
                            "type": "string"
                          },
                          "hint": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "status",
                          "detail"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "status",
                    "checks"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-13",
          "EAU-14",
          "EAU-43"
        ]
      }
    },
    "/api/v1/auth/saml/{providerId}/acs": {
      "post": {
        "operationId": "finishSamlSignIn",
        "summary": "Receive a SAML provider's sign-in answer",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "SAMLResponse": {
                    "type": "string"
                  },
                  "RelayState": {
                    "type": "string"
                  }
                },
                "required": [
                  "SAMLResponse"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "303": {
            "description": "Back to the sign-in page: `/login?error=<code>` on a refusal, the requested page otherwise."
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "saml",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-42",
          "EAU-43"
        ]
      }
    },
    "/api/v1/auth/saml/{providerId}/metadata": {
      "get": {
        "operationId": "getSamlMetadata",
        "summary": "Read a sign-in provider's SAML service metadata",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The SAML service provider metadata document.",
            "content": {
              "application/xml; charset=utf-8": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: sso_misconfigured.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-43",
          "EAU-64"
        ]
      }
    },
    "/api/v1/auth/saml/{providerId}/start": {
      "get": {
        "operationId": "startSamlSignIn",
        "summary": "Start signing in with a SAML provider",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "redirect",
            "in": "query",
            "required": false,
            "description": "Path of this app to return to once signed in.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "To the provider's sign-in page."
          },
          "404": {
            "description": "Error codes: provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "saml",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-42",
          "EAU-43"
        ]
      }
    },
    "/api/v1/auth/scim-tokens": {
      "get": {
        "operationId": "listScimTokens",
        "summary": "List provisioning tokens without their secrets",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "tokens": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "label": {
                            "type": "string"
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_used_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "revoked_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "label",
                          "created_at",
                          "last_used_at",
                          "revoked_at"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "scim_base_url": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "tokens",
                    "scim_base_url"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-44",
          "API-60"
        ]
      },
      "post": {
        "operationId": "createScimToken",
        "summary": "Create a provisioning token and reveal its secret once",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80
                  }
                },
                "required": [
                  "label"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    },
                    "token": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "label",
                    "token"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-44",
          "API-60",
          "EDI-32"
        ]
      }
    },
    "/api/v1/auth/scim-tokens/{id}": {
      "delete": {
        "operationId": "revokeScimToken",
        "summary": "Revoke a provisioning token",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: token_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-44",
          "API-67"
        ]
      }
    },
    "/api/v1/auth/settings": {
      "get": {
        "operationId": "getAuthSettings",
        "summary": "Read the cluster's sign-in settings",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "public_base_url": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "public_base_url_from_env": {
                      "type": "boolean"
                    },
                    "session_ttl_hours": {
                      "type": "number"
                    },
                    "cookie_secure": {
                      "type": "boolean"
                    },
                    "bootstrap_email": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "public_base_url",
                    "public_base_url_from_env",
                    "session_ttl_hours",
                    "cookie_secure",
                    "bootstrap_email"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-18",
          "EAU-23"
        ]
      },
      "put": {
        "operationId": "updateAuthSettings",
        "summary": "Update the cluster's sign-in settings",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "public_base_url": {
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "public_base_url": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "public_base_url"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-18"
        ]
      }
    },
    "/api/v1/auth/ws-ticket": {
      "post": {
        "operationId": "createWebSocketTicket",
        "summary": "Create a single-use WebSocket ticket",
        "tags": [
          "auth"
        ],
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ticket": {
                      "type": "string"
                    },
                    "expires_in": {
                      "type": "number"
                    }
                  },
                  "required": [
                    "ticket",
                    "expires_in"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "SEC-08",
          "API-60",
          "API-67"
        ]
      }
    },
    "/api/v1/benchmarks": {
      "get": {
        "operationId": "listBenchmarks",
        "summary": "List the benchmarks",
        "description": "In queue order when `status` is queued or running, newest first otherwise; paginated with `limit` and `cursor`.",
        "tags": [
          "benchmarks"
        ],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          },
          {
            "name": "recipe_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 32
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "benchmarks": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "recipe_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Null once its recipe is deleted."
                          },
                          "recipe_snapshot": {
                            "description": "The recipe as it was when the benchmark was queued."
                          },
                          "pinned_gpu_config": {
                            "type": "string",
                            "description": "The exact configuration it must run on."
                          },
                          "gpu_config": {
                            "description": "The configuration it ran on, once started.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "power_level": {
                            "type": "string",
                            "enum": [
                              "max",
                              "low"
                            ],
                            "description": "The power level it asks for."
                          },
                          "session": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "complete",
                                  "interrupted"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "How its session ended; null while it runs."
                          },
                          "correctness_passed": {
                            "type": [
                              "boolean",
                              "null"
                            ]
                          },
                          "correctness_check": {
                            "description": "The task's correctness check and its contract version, once it ran.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "correctness_trials": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "id": {
                                      "type": "string"
                                    },
                                    "passed": {
                                      "type": "boolean"
                                    },
                                    "detail": {
                                      "description": "Always null here: GET /api/benchmarks/:id/correctness gives it to an admin.",
                                      "type": [
                                        "string",
                                        "null"
                                      ]
                                    }
                                  },
                                  "required": [
                                    "id",
                                    "passed",
                                    "detail"
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Each trial of the check; what a failed one saw is the administrator's to read."
                          },
                          "publication": {
                            "type": "object",
                            "properties": {
                              "state": {
                                "type": "string",
                                "enum": [
                                  "published",
                                  "kept",
                                  "pending"
                                ]
                              },
                              "reason": {
                                "description": "Why it is kept here; null otherwise.",
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "state",
                              "reason"
                            ],
                            "additionalProperties": false,
                            "description": "Whether the closed session reached the hub, or why it stays here. [OBJ-107]"
                          },
                          "budget_usage_pct": {
                            "description": "[OBJ-121] How much of the VRAM it reserves (its budget, else its card's usable VRAM) a complete session of a bridable recipe used (%); null when no verdict was made.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "budget_verdict": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "ok",
                                  "notice",
                                  "no_proof"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[OBJ-121] [FRC-37] notice under 85 % of the budget, no_proof under 70 % (the session proves nothing); null when no verdict was made."
                          },
                          "budget_target_gb": {
                            "description": "[OBJ-121] [GPU-290] Under 70 %: the highest proposed VRAM cap per GPU, below the VRAM reserved, that would bring the usage to 70 %; null otherwise, or when none does.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "budget_places_needed": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[OBJ-121] Under 70 %: the fewest max parallel requests that would bring the usage to 70 % on the same VRAM; null otherwise."
                          },
                          "budget_overrun": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "peak_gb": {
                                    "description": "The highest attributed peak on a GPU (GB); null when no GPU memory was read.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "budget_gb": {
                                    "type": "number",
                                    "description": "The recipe's VRAM budget per GPU (GB)."
                                  }
                                },
                                "required": [
                                  "peak_gb",
                                  "budget_gb"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-161] The engine held more than the recipe's budget on a GPU, or no GPU memory was read: the session proves nothing. Null otherwise."
                          },
                          "ram_tier_shortfall": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "needed_gb": {
                                    "type": "number",
                                    "description": "The system RAM it held plus the largest cache its options declare (GB)."
                                  },
                                  "tier_gb": {
                                    "type": "number",
                                    "description": "The RAM tier its recipe declares (GB)."
                                  },
                                  "unmeasured": {
                                    "type": "boolean",
                                    "description": "True when no profile read its system RAM, so the tier could not be checked."
                                  }
                                },
                                "required": [
                                  "needed_gb",
                                  "tier_gb",
                                  "unmeasured"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[VIS-31] A tiered recipe's session whose RAM held plus its declared cache passes its tier, or whose RAM was not read: the session proves nothing. Null otherwise."
                          },
                          "status": {
                            "type": "string",
                            "description": "queued, delegated, running, completed, partial, failed, cancelled; more may come."
                          },
                          "container_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "error_message": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "profile_plan": {
                            "description": "The workload profiles it runs, in order."
                          },
                          "last_verdict_rung": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "last_verdict_note": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "last_verdict_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rebench": {
                            "type": "boolean"
                          },
                          "rebench_of_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "queue_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "template_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "variation_key": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "driver_branch": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The NVIDIA driver branch it may run on; null = any node."
                          },
                          "force_driver": {
                            "type": "boolean",
                            "description": "Started past a liftable driver verdict by an Owner or Admin (Benchmark anyway)."
                          },
                          "position": {
                            "type": "number"
                          },
                          "origin": {
                            "type": "string"
                          },
                          "not_before": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "node_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "recipe_id",
                          "recipe_snapshot",
                          "pinned_gpu_config",
                          "gpu_config",
                          "power_level",
                          "session",
                          "correctness_passed",
                          "correctness_check",
                          "correctness_trials",
                          "publication",
                          "budget_usage_pct",
                          "budget_verdict",
                          "budget_target_gb",
                          "budget_places_needed",
                          "budget_overrun",
                          "ram_tier_shortfall",
                          "status",
                          "container_id",
                          "error_message",
                          "profile_plan",
                          "last_verdict_rung",
                          "last_verdict_note",
                          "last_verdict_at",
                          "rebench",
                          "rebench_of_id",
                          "queue_id",
                          "template_id",
                          "variation_key",
                          "driver_branch",
                          "force_driver",
                          "position",
                          "origin",
                          "not_before",
                          "created_at",
                          "started_at",
                          "completed_at"
                        ],
                        "additionalProperties": false,
                        "description": "[API-96] A benchmark. A caller who is not an administrator receives no node: node_id is an administrator's."
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "benchmarks",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-67"
        ]
      },
      "post": {
        "operationId": "enqueueBenchmarks",
        "summary": "Put recipes in the benchmark queue",
        "description": "One outcome per recipe: queued, or skipped with its reason (already queued, already tested, a task GPU Kitchen does not benchmark). `profile` and `gpu_config` apply to every recipe of the call.",
        "tags": [
          "benchmarks"
        ],
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Send the request again with the same value: for 24 hours, you get the first successful answer back, and nothing is done twice.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[\\x21-\\x7E]+$"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "recipe_ids": {
                    "minItems": 1,
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 2147483647
                    }
                  },
                  "gpu_config": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 256,
                    "description": "The exact configuration to measure on (`rtx 3090*2`)."
                  },
                  "profile": {
                    "type": "string",
                    "maxLength": 64
                  },
                  "rebench": {
                    "description": "Measure again: what this cluster or the community already measured on this configuration is not reused, so already_tested is never the outcome.",
                    "type": "boolean"
                  }
                },
                "required": [
                  "recipe_ids",
                  "gpu_config"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "outcomes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "recipe_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "queued": {
                            "type": "boolean"
                          },
                          "benchmark": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  "recipe_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "Null once its recipe is deleted."
                                  },
                                  "recipe_snapshot": {
                                    "description": "The recipe as it was when the benchmark was queued."
                                  },
                                  "pinned_gpu_config": {
                                    "type": "string",
                                    "description": "The exact configuration it must run on."
                                  },
                                  "gpu_config": {
                                    "description": "The configuration it ran on, once started.",
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "power_level": {
                                    "type": "string",
                                    "enum": [
                                      "max",
                                      "low"
                                    ],
                                    "description": "The power level it asks for."
                                  },
                                  "session": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "enum": [
                                          "complete",
                                          "interrupted"
                                        ]
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "How its session ended; null while it runs."
                                  },
                                  "correctness_passed": {
                                    "type": [
                                      "boolean",
                                      "null"
                                    ]
                                  },
                                  "correctness_check": {
                                    "description": "The task's correctness check and its contract version, once it ran.",
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "correctness_trials": {
                                    "anyOf": [
                                      {
                                        "type": "array",
                                        "items": {
                                          "type": "object",
                                          "properties": {
                                            "id": {
                                              "type": "string"
                                            },
                                            "passed": {
                                              "type": "boolean"
                                            },
                                            "detail": {
                                              "description": "Always null here: GET /api/benchmarks/:id/correctness gives it to an admin.",
                                              "type": [
                                                "string",
                                                "null"
                                              ]
                                            }
                                          },
                                          "required": [
                                            "id",
                                            "passed",
                                            "detail"
                                          ],
                                          "additionalProperties": false
                                        }
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "Each trial of the check; what a failed one saw is the administrator's to read."
                                  },
                                  "publication": {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "enum": [
                                          "published",
                                          "kept",
                                          "pending"
                                        ]
                                      },
                                      "reason": {
                                        "description": "Why it is kept here; null otherwise.",
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "reason"
                                    ],
                                    "additionalProperties": false,
                                    "description": "Whether the closed session reached the hub, or why it stays here. [OBJ-107]"
                                  },
                                  "budget_usage_pct": {
                                    "description": "[OBJ-121] How much of the VRAM it reserves (its budget, else its card's usable VRAM) a complete session of a bridable recipe used (%); null when no verdict was made.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "budget_verdict": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "enum": [
                                          "ok",
                                          "notice",
                                          "no_proof"
                                        ]
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "[OBJ-121] [FRC-37] notice under 85 % of the budget, no_proof under 70 % (the session proves nothing); null when no verdict was made."
                                  },
                                  "budget_target_gb": {
                                    "description": "[OBJ-121] [GPU-290] Under 70 %: the highest proposed VRAM cap per GPU, below the VRAM reserved, that would bring the usage to 70 %; null otherwise, or when none does.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "budget_places_needed": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "[OBJ-121] Under 70 %: the fewest max parallel requests that would bring the usage to 70 % on the same VRAM; null otherwise."
                                  },
                                  "budget_overrun": {
                                    "anyOf": [
                                      {
                                        "type": "object",
                                        "properties": {
                                          "peak_gb": {
                                            "description": "The highest attributed peak on a GPU (GB); null when no GPU memory was read.",
                                            "type": [
                                              "number",
                                              "null"
                                            ]
                                          },
                                          "budget_gb": {
                                            "type": "number",
                                            "description": "The recipe's VRAM budget per GPU (GB)."
                                          }
                                        },
                                        "required": [
                                          "peak_gb",
                                          "budget_gb"
                                        ],
                                        "additionalProperties": false
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "[MOT-161] The engine held more than the recipe's budget on a GPU, or no GPU memory was read: the session proves nothing. Null otherwise."
                                  },
                                  "ram_tier_shortfall": {
                                    "anyOf": [
                                      {
                                        "type": "object",
                                        "properties": {
                                          "needed_gb": {
                                            "type": "number",
                                            "description": "The system RAM it held plus the largest cache its options declare (GB)."
                                          },
                                          "tier_gb": {
                                            "type": "number",
                                            "description": "The RAM tier its recipe declares (GB)."
                                          },
                                          "unmeasured": {
                                            "type": "boolean",
                                            "description": "True when no profile read its system RAM, so the tier could not be checked."
                                          }
                                        },
                                        "required": [
                                          "needed_gb",
                                          "tier_gb",
                                          "unmeasured"
                                        ],
                                        "additionalProperties": false
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "[VIS-31] A tiered recipe's session whose RAM held plus its declared cache passes its tier, or whose RAM was not read: the session proves nothing. Null otherwise."
                                  },
                                  "status": {
                                    "type": "string",
                                    "description": "queued, delegated, running, completed, partial, failed, cancelled; more may come."
                                  },
                                  "container_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "error_message": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "profile_plan": {
                                    "description": "The workload profiles it runs, in order."
                                  },
                                  "last_verdict_rung": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "last_verdict_note": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "last_verdict_at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "rebench": {
                                    "type": "boolean"
                                  },
                                  "rebench_of_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "queue_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "template_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "variation_key": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "driver_branch": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "The NVIDIA driver branch it may run on; null = any node."
                                  },
                                  "force_driver": {
                                    "type": "boolean",
                                    "description": "Started past a liftable driver verdict by an Owner or Admin (Benchmark anyway)."
                                  },
                                  "position": {
                                    "type": "number"
                                  },
                                  "origin": {
                                    "type": "string"
                                  },
                                  "not_before": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "created_at": {
                                    "type": "string",
                                    "format": "date-time"
                                  },
                                  "started_at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "completed_at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "node_id": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "recipe_id",
                                  "recipe_snapshot",
                                  "pinned_gpu_config",
                                  "gpu_config",
                                  "power_level",
                                  "session",
                                  "correctness_passed",
                                  "correctness_check",
                                  "correctness_trials",
                                  "publication",
                                  "budget_usage_pct",
                                  "budget_verdict",
                                  "budget_target_gb",
                                  "budget_places_needed",
                                  "budget_overrun",
                                  "ram_tier_shortfall",
                                  "status",
                                  "container_id",
                                  "error_message",
                                  "profile_plan",
                                  "last_verdict_rung",
                                  "last_verdict_note",
                                  "last_verdict_at",
                                  "rebench",
                                  "rebench_of_id",
                                  "queue_id",
                                  "template_id",
                                  "variation_key",
                                  "driver_branch",
                                  "force_driver",
                                  "position",
                                  "origin",
                                  "not_before",
                                  "created_at",
                                  "started_at",
                                  "completed_at"
                                ],
                                "additionalProperties": false,
                                "description": "[API-96] A benchmark. A caller who is not an administrator receives no node: node_id is an administrator's."
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "skipped_reason": {
                            "description": "Why nothing was queued: already_queued, already_tested, unsupported_task_type, enqueue_failed (this recipe alone could not be queued; calling again is safe), or a reason a later version adds.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "detail": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "existing_benchmark_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "existing_result_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "recipe_id",
                          "queued",
                          "benchmark",
                          "skipped_reason",
                          "detail",
                          "existing_benchmark_id",
                          "existing_result_id"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "outcomes"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, own_image_admins_only, reserved_gpus_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: recipe_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: idempotency_in_progress, kitchen_account_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "Error codes: gpu_config_invalid, idempotency_key_reused, load_profile_task_mismatch, load_profile_unknown.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "operator",
        "x-gpuk-effect": "write",
        "x-gpuk-idempotent": true,
        "x-gpuk-requirements": [
          "API-65",
          "API-79",
          "EAU-109",
          "REG-552"
        ]
      }
    },
    "/api/v1/benchmarks/{id}": {
      "get": {
        "operationId": "getBenchmark",
        "summary": "Read one benchmark",
        "tags": [
          "benchmarks"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "benchmark": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "recipe_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Null once its recipe is deleted."
                        },
                        "recipe_snapshot": {
                          "description": "The recipe as it was when the benchmark was queued."
                        },
                        "pinned_gpu_config": {
                          "type": "string",
                          "description": "The exact configuration it must run on."
                        },
                        "gpu_config": {
                          "description": "The configuration it ran on, once started.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "power_level": {
                          "type": "string",
                          "enum": [
                            "max",
                            "low"
                          ],
                          "description": "The power level it asks for."
                        },
                        "session": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "complete",
                                "interrupted"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "How its session ended; null while it runs."
                        },
                        "correctness_passed": {
                          "type": [
                            "boolean",
                            "null"
                          ]
                        },
                        "correctness_check": {
                          "description": "The task's correctness check and its contract version, once it ran.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "correctness_trials": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "passed": {
                                    "type": "boolean"
                                  },
                                  "detail": {
                                    "description": "Always null here: GET /api/benchmarks/:id/correctness gives it to an admin.",
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "passed",
                                  "detail"
                                ],
                                "additionalProperties": false
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Each trial of the check; what a failed one saw is the administrator's to read."
                        },
                        "publication": {
                          "type": "object",
                          "properties": {
                            "state": {
                              "type": "string",
                              "enum": [
                                "published",
                                "kept",
                                "pending"
                              ]
                            },
                            "reason": {
                              "description": "Why it is kept here; null otherwise.",
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          },
                          "required": [
                            "state",
                            "reason"
                          ],
                          "additionalProperties": false,
                          "description": "Whether the closed session reached the hub, or why it stays here. [OBJ-107]"
                        },
                        "budget_usage_pct": {
                          "description": "[OBJ-121] How much of the VRAM it reserves (its budget, else its card's usable VRAM) a complete session of a bridable recipe used (%); null when no verdict was made.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "budget_verdict": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "ok",
                                "notice",
                                "no_proof"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[OBJ-121] [FRC-37] notice under 85 % of the budget, no_proof under 70 % (the session proves nothing); null when no verdict was made."
                        },
                        "budget_target_gb": {
                          "description": "[OBJ-121] [GPU-290] Under 70 %: the highest proposed VRAM cap per GPU, below the VRAM reserved, that would bring the usage to 70 %; null otherwise, or when none does.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "budget_places_needed": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[OBJ-121] Under 70 %: the fewest max parallel requests that would bring the usage to 70 % on the same VRAM; null otherwise."
                        },
                        "budget_overrun": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "peak_gb": {
                                  "description": "The highest attributed peak on a GPU (GB); null when no GPU memory was read.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "budget_gb": {
                                  "type": "number",
                                  "description": "The recipe's VRAM budget per GPU (GB)."
                                }
                              },
                              "required": [
                                "peak_gb",
                                "budget_gb"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-161] The engine held more than the recipe's budget on a GPU, or no GPU memory was read: the session proves nothing. Null otherwise."
                        },
                        "ram_tier_shortfall": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "needed_gb": {
                                  "type": "number",
                                  "description": "The system RAM it held plus the largest cache its options declare (GB)."
                                },
                                "tier_gb": {
                                  "type": "number",
                                  "description": "The RAM tier its recipe declares (GB)."
                                },
                                "unmeasured": {
                                  "type": "boolean",
                                  "description": "True when no profile read its system RAM, so the tier could not be checked."
                                }
                              },
                              "required": [
                                "needed_gb",
                                "tier_gb",
                                "unmeasured"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-31] A tiered recipe's session whose RAM held plus its declared cache passes its tier, or whose RAM was not read: the session proves nothing. Null otherwise."
                        },
                        "status": {
                          "type": "string",
                          "description": "queued, delegated, running, completed, partial, failed, cancelled; more may come."
                        },
                        "container_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "error_message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "profile_plan": {
                          "description": "The workload profiles it runs, in order."
                        },
                        "last_verdict_rung": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "last_verdict_note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "last_verdict_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "rebench": {
                          "type": "boolean"
                        },
                        "rebench_of_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "queue_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "template_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "variation_key": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "driver_branch": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The NVIDIA driver branch it may run on; null = any node."
                        },
                        "force_driver": {
                          "type": "boolean",
                          "description": "Started past a liftable driver verdict by an Owner or Admin (Benchmark anyway)."
                        },
                        "position": {
                          "type": "number"
                        },
                        "origin": {
                          "type": "string"
                        },
                        "not_before": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "started_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "completed_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "node_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "recipe_id",
                        "recipe_snapshot",
                        "pinned_gpu_config",
                        "gpu_config",
                        "power_level",
                        "session",
                        "correctness_passed",
                        "correctness_check",
                        "correctness_trials",
                        "publication",
                        "budget_usage_pct",
                        "budget_verdict",
                        "budget_target_gb",
                        "budget_places_needed",
                        "budget_overrun",
                        "ram_tier_shortfall",
                        "status",
                        "container_id",
                        "error_message",
                        "profile_plan",
                        "last_verdict_rung",
                        "last_verdict_note",
                        "last_verdict_at",
                        "rebench",
                        "rebench_of_id",
                        "queue_id",
                        "template_id",
                        "variation_key",
                        "driver_branch",
                        "force_driver",
                        "position",
                        "origin",
                        "not_before",
                        "created_at",
                        "started_at",
                        "completed_at"
                      ],
                      "additionalProperties": false,
                      "description": "[API-96] A benchmark. A caller who is not an administrator receives no node: node_id is an administrator's."
                    }
                  },
                  "required": [
                    "benchmark"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: benchmark_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/benchmarks/queues": {
      "get": {
        "operationId": "listBenchQueues",
        "summary": "Read the state of the benchmark queues",
        "description": "One queue per template, running or paused, with how many of its benchmarks wait and run. Benchmarks queued outside a template carry no queue; list them with `GET /api/v1/benchmarks?status=queued`.",
        "tags": [
          "benchmarks"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "queues": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "template_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "template_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "base_model_key": {
                            "type": "string"
                          },
                          "gpu_config": {
                            "type": "string",
                            "description": "The template's exact configuration."
                          },
                          "state": {
                            "type": "string",
                            "description": "running or paused; later states may be added."
                          },
                          "priority_band": {
                            "type": "string"
                          },
                          "scope": {
                            "type": "string"
                          },
                          "queued": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "Benchmarks waiting in this queue."
                          },
                          "running": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "Benchmarks of this queue running now."
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "template_id",
                          "template_name",
                          "base_model_key",
                          "gpu_config",
                          "state",
                          "priority_band",
                          "scope",
                          "queued",
                          "running",
                          "created_at",
                          "updated_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "queues"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/benchmarks/results": {
      "get": {
        "operationId": "listBenchmarkResults",
        "summary": "List the benchmark results",
        "description": "Newest first, or ranked by `sort_by` (one task at a time); paginated with `limit` and `cursor`. Results still running are left out unless `status` asks for them.",
        "tags": [
          "benchmarks"
        ],
        "parameters": [
          {
            "name": "corpus_version",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 128
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "engine_test_engine_id",
            "in": "query",
            "required": false,
            "description": "Only the standalone tests of this engine (REG-409).",
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "gpu_count",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 64
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          },
          {
            "name": "model_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "profile",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 64
            }
          },
          {
            "name": "recipe_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "sort_by",
            "in": "query",
            "required": false,
            "description": "A ranking objective or a measured field.",
            "schema": {
              "type": "string",
              "maxLength": 64
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 32
            }
          },
          {
            "name": "task_type",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "text-generation",
                "embedding",
                "reranking",
                "classification",
                "asr",
                "tts",
                "speech-to-speech",
                "image-generation",
                "vision",
                "audio-generation",
                "video-generation",
                "custom"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "results": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "benchmark_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "benchmark_attempt_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "recipe_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Null once its recipe is deleted."
                          },
                          "recipe_label": {
                            "description": "What the recipe is called: its model setup's label (VIS-18); null for an engine test.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "engine_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "engine_test_engine_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The engine a standalone engine test tested; null for any other result."
                          },
                          "task_type": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string",
                            "description": "running, success, failed, dominated…; later states may be added."
                          },
                          "load_profile": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "corpus_version": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "params_snapshot": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "request_params": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string"
                            },
                            "additionalProperties": {},
                            "description": "The parameters each request was sent with."
                          },
                          "metrics": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Every measured value."
                          },
                          "error_message": {
                            "description": "Why the run failed or was cancelled; null otherwise.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "duration_seconds": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "tokens_per_sec_multi": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "tps_per_watt": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_peak_gb": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_peak_card_gb": {
                            "description": "The fullest card's VRAM peak held by the recipe's engine, in GB; the card's whole use when it cannot be attributed.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_peak_pct": {
                            "description": "That peak as a share of the card's total VRAM, in %.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_peak_attribution": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "attributed",
                                  "unattributed"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Whether that peak is the engine's own memory, or the card's whole use because it could not be attributed."
                          },
                          "card_vram_peak_gb": {
                            "description": "That card's whole VRAM peak, every program on it included, in GB: information only.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "idle_vram_card_gb": {
                            "description": "The engine's VRAM at rest on its fullest card, read when it became healthy, in GB: information only.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "kv_cache_peak_pct": {
                            "description": "The engine's KV cache fill peak, in %; null when the engine does not report it.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "ttft_p50_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "ttft_p99_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "itl_p50_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "itl_p99_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "e2e_p50_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "e2e_p95_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "e2e_p99_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "items_completed": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "served_seconds": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "audio_seconds": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "audio_processing_seconds": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "requests_attempted": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "requests_completed": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "first_audio_p50_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "first_playable_audio_p50_ms": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "goodput_rps": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "goodput_concurrency": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "slo_version": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "avg_power_w": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "max_power_w": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "pruned_rung": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "pruned_bar_metric": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "pruned_bar_value": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "incumbent_benchmark_id": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "container_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "checksum_test": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "checksum_bench": {
                            "description": "Null when the run's cards had mixed links: it proves, measures nothing.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "plat_key": {
                            "description": "The model setup the recipe serves.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_config": {
                            "description": "The exact configuration it ran on (`rtx 3090*2`).",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "driver_branch": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The NVIDIA driver branch it ran on; null for another vendor."
                          },
                          "suite": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "power_level": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "max",
                                  "low"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "link": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "nvlink",
                                  "pcie",
                                  "none",
                                  "mixed"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "gpu_model": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_count": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "gpu_compute_capability": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "vram_per_gpu": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "reserved_vram_per_gpu": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "gpu_state": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "env_warnings": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "error_logs": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "failure_class": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "failure_pattern_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "failure_evidence_line": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "node_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "node_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "benchmark_id",
                          "benchmark_attempt_id",
                          "recipe_id",
                          "recipe_label",
                          "engine_name",
                          "model_name",
                          "model_id",
                          "engine_test_engine_id",
                          "task_type",
                          "status",
                          "load_profile",
                          "corpus_version",
                          "params_snapshot",
                          "request_params",
                          "metrics",
                          "error_message",
                          "created_at",
                          "duration_seconds",
                          "tokens_per_sec_multi",
                          "tps_per_watt",
                          "vram_peak_gb",
                          "vram_peak_card_gb",
                          "vram_peak_pct",
                          "vram_peak_attribution",
                          "card_vram_peak_gb",
                          "idle_vram_card_gb",
                          "kv_cache_peak_pct",
                          "ttft_p50_ms",
                          "ttft_p99_ms",
                          "itl_p50_ms",
                          "itl_p99_ms",
                          "e2e_p50_ms",
                          "e2e_p95_ms",
                          "e2e_p99_ms",
                          "items_completed",
                          "served_seconds",
                          "audio_seconds",
                          "audio_processing_seconds",
                          "requests_attempted",
                          "requests_completed",
                          "first_audio_p50_ms",
                          "first_playable_audio_p50_ms",
                          "goodput_rps",
                          "goodput_concurrency",
                          "slo_version",
                          "avg_power_w",
                          "max_power_w",
                          "pruned_rung",
                          "pruned_bar_metric",
                          "pruned_bar_value",
                          "incumbent_benchmark_id",
                          "container_id",
                          "checksum_test",
                          "checksum_bench",
                          "plat_key",
                          "gpu_config",
                          "driver_branch",
                          "suite",
                          "power_level",
                          "link",
                          "gpu_model",
                          "gpu_count",
                          "gpu_compute_capability",
                          "vram_per_gpu",
                          "reserved_vram_per_gpu",
                          "gpu_state",
                          "env_warnings",
                          "error_logs",
                          "failure_class",
                          "failure_pattern_id",
                          "failure_evidence_line"
                        ],
                        "additionalProperties": false,
                        "description": "[API-96] A measured result. A caller who is not an administrator receives no node: node_id and node_name are an administrator's."
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "results",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "Error codes: ranking_needs_one_task, ranking_needs_one_workload, ranking_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-67"
        ]
      }
    },
    "/api/v1/benchmarks/results/{id}": {
      "get": {
        "operationId": "getBenchmarkResult",
        "summary": "Read one benchmark result",
        "tags": [
          "benchmarks"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "result": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "benchmark_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "benchmark_attempt_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "recipe_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Null once its recipe is deleted."
                        },
                        "recipe_label": {
                          "description": "What the recipe is called: its model setup's label (VIS-18); null for an engine test.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "engine_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "engine_test_engine_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The engine a standalone engine test tested; null for any other result."
                        },
                        "task_type": {
                          "type": "string"
                        },
                        "status": {
                          "type": "string",
                          "description": "running, success, failed, dominated…; later states may be added."
                        },
                        "load_profile": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "corpus_version": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "params_snapshot": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "request_params": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {},
                          "description": "The parameters each request was sent with."
                        },
                        "metrics": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Every measured value."
                        },
                        "error_message": {
                          "description": "Why the run failed or was cancelled; null otherwise.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "duration_seconds": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "tokens_per_sec_multi": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "tps_per_watt": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_peak_gb": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_peak_card_gb": {
                          "description": "The fullest card's VRAM peak held by the recipe's engine, in GB; the card's whole use when it cannot be attributed.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_peak_pct": {
                          "description": "That peak as a share of the card's total VRAM, in %.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_peak_attribution": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "attributed",
                                "unattributed"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Whether that peak is the engine's own memory, or the card's whole use because it could not be attributed."
                        },
                        "card_vram_peak_gb": {
                          "description": "That card's whole VRAM peak, every program on it included, in GB: information only.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "idle_vram_card_gb": {
                          "description": "The engine's VRAM at rest on its fullest card, read when it became healthy, in GB: information only.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "kv_cache_peak_pct": {
                          "description": "The engine's KV cache fill peak, in %; null when the engine does not report it.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ttft_p50_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ttft_p99_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "itl_p50_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "itl_p99_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "e2e_p50_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "e2e_p95_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "e2e_p99_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "items_completed": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "served_seconds": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "audio_seconds": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "audio_processing_seconds": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "requests_attempted": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "requests_completed": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "first_audio_p50_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "first_playable_audio_p50_ms": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "goodput_rps": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "goodput_concurrency": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "slo_version": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "avg_power_w": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "max_power_w": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "pruned_rung": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "pruned_bar_metric": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "pruned_bar_value": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "incumbent_benchmark_id": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "container_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "checksum_test": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "checksum_bench": {
                          "description": "Null when the run's cards had mixed links: it proves, measures nothing.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "plat_key": {
                          "description": "The model setup the recipe serves.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_config": {
                          "description": "The exact configuration it ran on (`rtx 3090*2`).",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "driver_branch": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The NVIDIA driver branch it ran on; null for another vendor."
                        },
                        "suite": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "power_level": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "max",
                                "low"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "link": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "nvlink",
                                "pcie",
                                "none",
                                "mixed"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "gpu_model": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_count": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "gpu_compute_capability": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "vram_per_gpu": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "reserved_vram_per_gpu": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "gpu_state": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "env_warnings": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "error_logs": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "failure_class": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "failure_pattern_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "failure_evidence_line": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "benchmark_id",
                        "benchmark_attempt_id",
                        "recipe_id",
                        "recipe_label",
                        "engine_name",
                        "model_name",
                        "model_id",
                        "engine_test_engine_id",
                        "task_type",
                        "status",
                        "load_profile",
                        "corpus_version",
                        "params_snapshot",
                        "request_params",
                        "metrics",
                        "error_message",
                        "created_at",
                        "duration_seconds",
                        "tokens_per_sec_multi",
                        "tps_per_watt",
                        "vram_peak_gb",
                        "vram_peak_card_gb",
                        "vram_peak_pct",
                        "vram_peak_attribution",
                        "card_vram_peak_gb",
                        "idle_vram_card_gb",
                        "kv_cache_peak_pct",
                        "ttft_p50_ms",
                        "ttft_p99_ms",
                        "itl_p50_ms",
                        "itl_p99_ms",
                        "e2e_p50_ms",
                        "e2e_p95_ms",
                        "e2e_p99_ms",
                        "items_completed",
                        "served_seconds",
                        "audio_seconds",
                        "audio_processing_seconds",
                        "requests_attempted",
                        "requests_completed",
                        "first_audio_p50_ms",
                        "first_playable_audio_p50_ms",
                        "goodput_rps",
                        "goodput_concurrency",
                        "slo_version",
                        "avg_power_w",
                        "max_power_w",
                        "pruned_rung",
                        "pruned_bar_metric",
                        "pruned_bar_value",
                        "incumbent_benchmark_id",
                        "container_id",
                        "checksum_test",
                        "checksum_bench",
                        "plat_key",
                        "gpu_config",
                        "driver_branch",
                        "suite",
                        "power_level",
                        "link",
                        "gpu_model",
                        "gpu_count",
                        "gpu_compute_capability",
                        "vram_per_gpu",
                        "reserved_vram_per_gpu",
                        "gpu_state",
                        "env_warnings",
                        "error_logs",
                        "failure_class",
                        "failure_pattern_id",
                        "failure_evidence_line"
                      ],
                      "additionalProperties": false,
                      "description": "[API-96] A measured result. A caller who is not an administrator receives no node: node_id and node_name are an administrator's."
                    }
                  },
                  "required": [
                    "result"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: benchmark_result_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/budgets": {
      "get": {
        "operationId": "getBudgets",
        "summary": "Read every team's and person's external budget with this month's spend",
        "description": "Budgets cap only what external models cost when a shared credential pays. Local models are never capped: privileges and recent GPU time only decide who is served first while the GPUs are full.",
        "tags": [
          "budgets"
        ],
        "parameters": [
          {
            "name": "account",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "active",
                "disabled"
              ]
            }
          },
          {
            "name": "inactive",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 3650
            }
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "default": 0,
              "type": "integer",
              "minimum": 0,
              "maximum": 9007199254740991
            }
          },
          {
            "name": "person",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 100
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "role",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "super_admin",
                "admin",
                "operator",
                "user"
              ]
            }
          },
          {
            "name": "sign_in",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "password",
                "sso"
              ]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "reached",
                "near",
                "within",
                "unlimited"
              ]
            }
          },
          {
            "name": "team",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "month_start": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "resumes_at": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "default_budget": {
                      "anyOf": [
                        {
                          "type": "string",
                          "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "totals": {
                      "type": "object",
                      "properties": {
                        "external_spend": {
                          "type": "string",
                          "pattern": "^\\d+(?:\\.\\d+)?$"
                        },
                        "gpuk_ms_24h": {
                          "type": "string",
                          "pattern": "^\\d+$"
                        },
                        "unmeasured_gpu_ms_24h": {
                          "type": "string",
                          "pattern": "^\\d+$"
                        },
                        "teams_reached": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "teams_near": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "people_reached": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "people_near": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "uncounted": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "provider_id": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              "currency": {
                                "type": "string"
                              },
                              "amount": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "provider_id",
                              "currency",
                              "amount"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "external_spend",
                        "gpuk_ms_24h",
                        "unmeasured_gpu_ms_24h",
                        "teams_reached",
                        "teams_near",
                        "people_reached",
                        "people_near",
                        "uncounted"
                      ],
                      "additionalProperties": false
                    },
                    "teams": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "standard",
                              "application"
                            ]
                          },
                          "member_count": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "directory": {
                            "type": "boolean"
                          },
                          "leads": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "privilege": {
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number"
                              },
                              "source": {
                                "type": "string",
                                "enum": [
                                  "own",
                                  "default"
                                ]
                              },
                              "range": {
                                "type": "string",
                                "enum": [
                                  "background",
                                  "standard",
                                  "priority",
                                  "critical"
                                ]
                              }
                            },
                            "required": [
                              "value",
                              "source",
                              "range"
                            ],
                            "additionalProperties": false
                          },
                          "budget": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "spent": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "within",
                              "near",
                              "reached",
                              "unlimited"
                            ]
                          },
                          "ceiling": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "enum": [
                                      "personal",
                                      "share",
                                      "team"
                                    ]
                                  },
                                  "team_id": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "spent": {
                                    "type": "string",
                                    "pattern": "^\\d+(?:\\.\\d+)?$"
                                  },
                                  "budget": {
                                    "type": "string",
                                    "pattern": "^\\d+(?:\\.\\d+)?$"
                                  }
                                },
                                "required": [
                                  "kind",
                                  "team_id",
                                  "spent",
                                  "budget"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "reached": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "near": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "kind",
                          "member_count",
                          "directory",
                          "leads",
                          "privilege",
                          "budget",
                          "spent",
                          "status",
                          "ceiling",
                          "reached",
                          "near"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "people": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "teams": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": "string"
                                },
                                "is_lead": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "id",
                                "name",
                                "is_lead"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "budget": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "source": {
                            "type": "string",
                            "enum": [
                              "own",
                              "default"
                            ]
                          },
                          "spent": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          },
                          "gpu_hours_monthly": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "privilege": {
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number"
                              },
                              "range": {
                                "type": "string",
                                "enum": [
                                  "background",
                                  "standard",
                                  "priority",
                                  "critical"
                                ]
                              },
                              "teams": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "team_id": {
                                      "type": "string"
                                    },
                                    "team_name": {
                                      "type": "string"
                                    },
                                    "team_privilege": {
                                      "type": "number"
                                    },
                                    "level": {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    "privilege": {
                                      "type": "number"
                                    },
                                    "active": {
                                      "type": "boolean"
                                    }
                                  },
                                  "required": [
                                    "team_id",
                                    "team_name",
                                    "team_privilege",
                                    "level",
                                    "privilege",
                                    "active"
                                  ],
                                  "additionalProperties": false
                                }
                              }
                            },
                            "required": [
                              "value",
                              "range",
                              "teams"
                            ],
                            "additionalProperties": false
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "has_password": {
                            "type": "boolean"
                          },
                          "providers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "is_bootstrap": {
                            "type": "boolean"
                          },
                          "role_override": {
                            "type": "boolean"
                          },
                          "invitation": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "pending",
                                  "expired"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "ceilings": {
                            "type": "array",
                            "items": {
                              "anyOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "kind": {
                                      "type": "string",
                                      "enum": [
                                        "personal",
                                        "share",
                                        "team"
                                      ]
                                    },
                                    "team_id": {
                                      "type": [
                                        "string",
                                        "null"
                                      ]
                                    },
                                    "spent": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    },
                                    "budget": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    }
                                  },
                                  "required": [
                                    "kind",
                                    "team_id",
                                    "spent",
                                    "budget"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "keys": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "key_id": {
                                  "type": "string"
                                },
                                "label": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "team": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "revoked": {
                                  "type": "boolean"
                                },
                                "spent": {
                                  "type": "string",
                                  "pattern": "^\\d+(?:\\.\\d+)?$"
                                }
                              },
                              "required": [
                                "key_id",
                                "label",
                                "team",
                                "revoked",
                                "spent"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "id",
                          "email",
                          "name",
                          "role",
                          "status",
                          "teams",
                          "budget",
                          "source",
                          "spent",
                          "budget_status",
                          "gpu_hours_monthly",
                          "privilege",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms",
                          "last_login_at",
                          "has_password",
                          "providers",
                          "is_bootstrap",
                          "role_override",
                          "invitation",
                          "ceilings",
                          "keys"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "people_all": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "operators": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "people_total": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "people_page_size": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "limits": {
                      "type": "object",
                      "properties": {
                        "members": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "teams": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "active_members": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": [
                        "members",
                        "teams",
                        "active_members"
                      ],
                      "additionalProperties": false
                    },
                    "sso_providers": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "app_keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key_id": {
                            "type": "string"
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "team_id": {
                            "type": "string"
                          },
                          "team": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "spent": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          },
                          "ceilings": {
                            "type": "array",
                            "items": {
                              "anyOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "kind": {
                                      "type": "string",
                                      "enum": [
                                        "personal",
                                        "share",
                                        "team"
                                      ]
                                    },
                                    "team_id": {
                                      "type": [
                                        "string",
                                        "null"
                                      ]
                                    },
                                    "spent": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    },
                                    "budget": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    }
                                  },
                                  "required": [
                                    "kind",
                                    "team_id",
                                    "spent",
                                    "budget"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "privilege": {
                            "type": "object",
                            "properties": {
                              "value": {
                                "type": "number"
                              },
                              "range": {
                                "type": "string",
                                "enum": [
                                  "background",
                                  "standard",
                                  "priority",
                                  "critical"
                                ]
                              },
                              "teams": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "team_id": {
                                      "type": "string"
                                    },
                                    "team_name": {
                                      "type": "string"
                                    },
                                    "team_privilege": {
                                      "type": "number"
                                    },
                                    "level": {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    "privilege": {
                                      "type": "number"
                                    },
                                    "active": {
                                      "type": "boolean"
                                    }
                                  },
                                  "required": [
                                    "team_id",
                                    "team_name",
                                    "team_privilege",
                                    "level",
                                    "privilege",
                                    "active"
                                  ],
                                  "additionalProperties": false
                                }
                              }
                            },
                            "required": [
                              "value",
                              "range",
                              "teams"
                            ],
                            "additionalProperties": false
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "key_id",
                          "label",
                          "team_id",
                          "team",
                          "created_by",
                          "spent",
                          "budget_status",
                          "ceilings",
                          "privilege",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "month_start",
                    "resumes_at",
                    "default_budget",
                    "totals",
                    "teams",
                    "people",
                    "people_all",
                    "operators",
                    "people_total",
                    "people_page_size",
                    "limits",
                    "sso_providers",
                    "app_keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-41",
          "QTA-42"
        ]
      }
    },
    "/api/v1/budgets/default": {
      "put": {
        "operationId": "setDefaultBudget",
        "summary": "Set the cluster's default monthly personal budget, in euros",
        "description": "It applies to every person without a budget of their own, owners included.",
        "tags": [
          "budgets"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "external_budget_monthly"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "default_budget": {
                      "anyOf": [
                        {
                          "type": "string",
                          "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "default_budget"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-40",
          "QTA-43"
        ]
      }
    },
    "/api/v1/budgets/people": {
      "put": {
        "operationId": "setPeopleBudgets",
        "summary": "Set personal budgets or restore the cluster default",
        "tags": [
          "budgets"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "member_ids": {
                    "minItems": 1,
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    }
                  },
                  "use_default": {
                    "type": "boolean"
                  },
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "member_ids"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-39",
          "QTA-43"
        ]
      }
    },
    "/api/v1/budgets/people.csv": {
      "get": {
        "operationId": "exportPeople",
        "summary": "Export the people the Users filters keep, every page, as CSV",
        "tags": [
          "budgets"
        ],
        "parameters": [
          {
            "name": "account",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "active",
                "disabled"
              ]
            }
          },
          {
            "name": "inactive",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 3650
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "role",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "super_admin",
                "admin",
                "operator",
                "user"
              ]
            }
          },
          {
            "name": "sign_in",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "password",
                "sso"
              ]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "reached",
                "near",
                "within",
                "unlimited"
              ]
            }
          },
          {
            "name": "team",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "One line per person: account, teams, sign-in, budget, spend, privilege.",
            "content": {
              "text/csv; charset=utf-8": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-79"
        ]
      }
    },
    "/api/v1/budgets/people/gpu-budget": {
      "put": {
        "operationId": "setPeopleGpuBudgets",
        "summary": "Set the monthly GPU-hour budgets of members without a team",
        "tags": [
          "budgets"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "member_ids": {
                    "minItems": 1,
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    }
                  },
                  "gpu_hours_monthly": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 2147483647
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "member_ids",
                  "gpu_hours_monthly"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "PLN-27"
        ]
      }
    },
    "/api/v1/budgets/teams": {
      "put": {
        "operationId": "setTeamBudgets",
        "summary": "Set the monthly external budget of one or several teams",
        "tags": [
          "budgets"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_ids": {
                    "minItems": 1,
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    }
                  },
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "team_ids",
                  "external_budget_monthly"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-05",
          "QTA-41",
          "QTA-43"
        ]
      }
    },
    "/api/v1/containers": {
      "get": {
        "operationId": "listContainers",
        "summary": "List the engine containers",
        "tags": [
          "containers"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "containers": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "recipe_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string",
                            "description": "What the engine is doing: starting, running, stopped, error; later states may be added."
                          },
                          "desired_state": {
                            "type": "string",
                            "description": "What the operator asked for: running or stopped. Differs from status while it is restored."
                          },
                          "deployment_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[VIS-20] The deployment it serves; null for a benchmark or a test."
                          },
                          "public_names": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "[VIS-21] The names it answers to at the proxy; none for a benchmark or a test."
                          },
                          "recipe_label": {
                            "description": "[VIS-18] What a page calls the recipe it runs; null without a recipe.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model": {
                            "description": "Its first public name, else the recipe's model.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "ready_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "stopped_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "on_demand_launched": {
                            "type": "boolean"
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "benchmark",
                              "reservation",
                              "on_demand",
                              "recipe"
                            ]
                          },
                          "name": {
                            "type": "string"
                          },
                          "docker_container_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "status_reason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "launch_note": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "recipe_model": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_ids": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vram_share_gb": {
                            "description": "The share of its card a small engine is held to, in GB; null = whole cards.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "api_port": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "image": {
                            "type": "string"
                          },
                          "command": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "node_id": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "node_name": {
                            "type": "string"
                          },
                          "expose_to_proxy": {
                            "type": "boolean"
                          },
                          "draining": {
                            "type": "boolean",
                            "description": "Finishing its requests and taking no new one."
                          },
                          "active_requests": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991,
                            "description": "[PRX-118] Requests the proxies report running on it now; 0 when none is reported."
                          },
                          "exit_code": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "restart_count": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "pinned": {
                            "type": "boolean"
                          },
                          "last_activity_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "task_type": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "text-generation",
                                  "embedding",
                                  "reranking",
                                  "classification",
                                  "asr",
                                  "tts",
                                  "speech-to-speech",
                                  "image-generation",
                                  "vision",
                                  "audio-generation",
                                  "video-generation",
                                  "custom"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[CVC-54] What the model of its recipe does; null without a recipe."
                          },
                          "holding": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "gpuk": {
                                    "description": "The GPUk of its cards; null if one is not measured.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "vram_gb": {
                                    "description": "The VRAM its recipe holds: the requirement per card × its cards.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "ram_gb": {
                                    "description": "The RAM requirement of its recipe on its cards.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "gpuk",
                                  "vram_gb",
                                  "ram_gb"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[CVC-55] What it holds, a requirement, not a measure; null when it holds no card (stopped, or still preparing). A figure not known is null, never 0."
                          },
                          "vram_used_gb": {
                            "description": "[CVC-55] A measure: the VRAM in use on its cards at its node's last reading. Null when it holds no card now, its node has no reading, or its engine shares its card.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "ram_used_gb": {
                            "description": "[CVC-56] A measure: the RAM its container held at its node's last reading, GB. Null when it holds no card now or its node has no reading of it.",
                            "type": [
                              "number",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "recipe_id",
                          "status",
                          "desired_state",
                          "deployment_id",
                          "public_names",
                          "recipe_label",
                          "model",
                          "created_at",
                          "started_at",
                          "ready_at",
                          "stopped_at",
                          "on_demand_launched",
                          "kind"
                        ],
                        "additionalProperties": false,
                        "description": "[API-95] An engine instance. A caller who is not an administrator receives the fields every reader may see (id, recipe_id, deployment_id, public_names, recipe_label, model, status, desired_state, kind and its instants); every other field is an administrator's."
                      }
                    }
                  },
                  "required": [
                    "containers"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/containers/{id}": {
      "get": {
        "operationId": "getContainer",
        "summary": "Read one engine container",
        "tags": [
          "containers"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "container": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "recipe_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "type": "string",
                          "description": "What the engine is doing: starting, running, stopped, error; later states may be added."
                        },
                        "desired_state": {
                          "type": "string",
                          "description": "What the operator asked for: running or stopped. Differs from status while it is restored."
                        },
                        "deployment_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-20] The deployment it serves; null for a benchmark or a test."
                        },
                        "public_names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "[VIS-21] The names it answers to at the proxy; none for a benchmark or a test."
                        },
                        "recipe_label": {
                          "description": "[VIS-18] What a page calls the recipe it runs; null without a recipe.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model": {
                          "description": "Its first public name, else the recipe's model.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "started_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "ready_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "stopped_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "on_demand_launched": {
                          "type": "boolean"
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "benchmark",
                            "reservation",
                            "on_demand",
                            "recipe"
                          ]
                        },
                        "name": {
                          "type": "string"
                        },
                        "docker_container_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status_reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "launch_note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "recipe_model": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_ids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "vram_share_gb": {
                          "description": "The share of its card a small engine is held to, in GB; null = whole cards.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "api_port": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "image": {
                          "type": "string"
                        },
                        "command": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_name": {
                          "type": "string"
                        },
                        "expose_to_proxy": {
                          "type": "boolean"
                        },
                        "draining": {
                          "type": "boolean",
                          "description": "Finishing its requests and taking no new one."
                        },
                        "active_requests": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991,
                          "description": "[PRX-118] Requests the proxies report running on it now; 0 when none is reported."
                        },
                        "exit_code": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "restart_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "pinned": {
                          "type": "boolean"
                        },
                        "last_activity_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "task_type": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "text-generation",
                                "embedding",
                                "reranking",
                                "classification",
                                "asr",
                                "tts",
                                "speech-to-speech",
                                "image-generation",
                                "vision",
                                "audio-generation",
                                "video-generation",
                                "custom"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[CVC-54] What the model of its recipe does; null without a recipe."
                        },
                        "holding": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "gpuk": {
                                  "description": "The GPUk of its cards; null if one is not measured.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "vram_gb": {
                                  "description": "The VRAM its recipe holds: the requirement per card × its cards.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "ram_gb": {
                                  "description": "The RAM requirement of its recipe on its cards.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "gpuk",
                                "vram_gb",
                                "ram_gb"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[CVC-55] What it holds, a requirement, not a measure; null when it holds no card (stopped, or still preparing). A figure not known is null, never 0."
                        },
                        "vram_used_gb": {
                          "description": "[CVC-55] A measure: the VRAM in use on its cards at its node's last reading. Null when it holds no card now, its node has no reading, or its engine shares its card.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ram_used_gb": {
                          "description": "[CVC-56] A measure: the RAM its container held at its node's last reading, GB. Null when it holds no card now or its node has no reading of it.",
                          "type": [
                            "number",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "recipe_id",
                        "status",
                        "desired_state",
                        "deployment_id",
                        "public_names",
                        "recipe_label",
                        "model",
                        "created_at",
                        "started_at",
                        "ready_at",
                        "stopped_at",
                        "on_demand_launched",
                        "kind"
                      ],
                      "additionalProperties": false,
                      "description": "[API-95] An engine instance. A caller who is not an administrator receives the fields every reader may see (id, recipe_id, deployment_id, public_names, recipe_label, model, status, desired_state, kind and its instants); every other field is an administrator's."
                    }
                  },
                  "required": [
                    "container"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: container_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/containers/{id}/stop": {
      "post": {
        "operationId": "stopContainer",
        "summary": "Stop an engine container",
        "description": "It stays stopped: it is not restarted. `soft` (default) lets the engine finish for 30 seconds; `hard` stops it at once. When its node does not answer, the stop is carried out as soon as it does.",
        "tags": [
          "containers"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": [
                      "soft",
                      "hard"
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "container": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "recipe_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "type": "string",
                          "description": "What the engine is doing: starting, running, stopped, error; later states may be added."
                        },
                        "desired_state": {
                          "type": "string",
                          "description": "What the operator asked for: running or stopped. Differs from status while it is restored."
                        },
                        "deployment_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-20] The deployment it serves; null for a benchmark or a test."
                        },
                        "public_names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "[VIS-21] The names it answers to at the proxy; none for a benchmark or a test."
                        },
                        "recipe_label": {
                          "description": "[VIS-18] What a page calls the recipe it runs; null without a recipe.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model": {
                          "description": "Its first public name, else the recipe's model.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "started_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "ready_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "stopped_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "on_demand_launched": {
                          "type": "boolean"
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "benchmark",
                            "reservation",
                            "on_demand",
                            "recipe"
                          ]
                        },
                        "name": {
                          "type": "string"
                        },
                        "docker_container_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status_reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "launch_note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "recipe_model": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_ids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "vram_share_gb": {
                          "description": "The share of its card a small engine is held to, in GB; null = whole cards.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "api_port": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "image": {
                          "type": "string"
                        },
                        "command": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_name": {
                          "type": "string"
                        },
                        "expose_to_proxy": {
                          "type": "boolean"
                        },
                        "draining": {
                          "type": "boolean",
                          "description": "Finishing its requests and taking no new one."
                        },
                        "active_requests": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991,
                          "description": "[PRX-118] Requests the proxies report running on it now; 0 when none is reported."
                        },
                        "exit_code": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "restart_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "pinned": {
                          "type": "boolean"
                        },
                        "last_activity_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "task_type": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "text-generation",
                                "embedding",
                                "reranking",
                                "classification",
                                "asr",
                                "tts",
                                "speech-to-speech",
                                "image-generation",
                                "vision",
                                "audio-generation",
                                "video-generation",
                                "custom"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[CVC-54] What the model of its recipe does; null without a recipe."
                        },
                        "holding": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "gpuk": {
                                  "description": "The GPUk of its cards; null if one is not measured.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "vram_gb": {
                                  "description": "The VRAM its recipe holds: the requirement per card × its cards.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "ram_gb": {
                                  "description": "The RAM requirement of its recipe on its cards.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "gpuk",
                                "vram_gb",
                                "ram_gb"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[CVC-55] What it holds, a requirement, not a measure; null when it holds no card (stopped, or still preparing). A figure not known is null, never 0."
                        },
                        "vram_used_gb": {
                          "description": "[CVC-55] A measure: the VRAM in use on its cards at its node's last reading. Null when it holds no card now, its node has no reading, or its engine shares its card.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ram_used_gb": {
                          "description": "[CVC-56] A measure: the RAM its container held at its node's last reading, GB. Null when it holds no card now or its node has no reading of it.",
                          "type": [
                            "number",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "recipe_id",
                        "status",
                        "desired_state",
                        "deployment_id",
                        "public_names",
                        "recipe_label",
                        "model",
                        "created_at",
                        "started_at",
                        "ready_at",
                        "stopped_at",
                        "on_demand_launched",
                        "kind",
                        "name",
                        "docker_container_id",
                        "status_reason",
                        "launch_note",
                        "recipe_model",
                        "gpu_ids",
                        "vram_share_gb",
                        "api_port",
                        "image",
                        "command",
                        "node_id",
                        "node_name",
                        "expose_to_proxy",
                        "draining",
                        "active_requests",
                        "exit_code",
                        "restart_count",
                        "pinned",
                        "last_activity_at",
                        "task_type",
                        "holding",
                        "vram_used_gb",
                        "ram_used_gb"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "container"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: container_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "Error codes: node_unreachable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "API-65",
          "RES-20",
          "BLD-318"
        ]
      }
    },
    "/api/v1/engines": {
      "get": {
        "operationId": "listEngines",
        "summary": "List the inference engines",
        "tags": [
          "engines"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "engines": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "family_id": {
                            "type": "string",
                            "description": "The engine family every version of this engine shares."
                          },
                          "name": {
                            "type": "string"
                          },
                          "docker_image": {
                            "type": "string"
                          },
                          "version": {
                            "type": "string"
                          },
                          "version_order": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "params_schema": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The parameters a recipe may set, as JSON Schema."
                          },
                          "dockerfile": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "args_map": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {
                                  "type": "object",
                                  "properties": {
                                    "flag": {
                                      "type": "string"
                                    },
                                    "source": {
                                      "type": "string",
                                      "enum": [
                                        "model.hfRepo",
                                        "model.localFile",
                                        "model.mmprojPath",
                                        "runtime.port",
                                        "runtime.servedName",
                                        "gpu.count",
                                        "recipe.params",
                                        "fixed",
                                        "default"
                                      ]
                                    },
                                    "value": {
                                      "anyOf": [
                                        {},
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "negative_flag": {
                                      "type": [
                                        "string",
                                        "null"
                                      ]
                                    },
                                    "headroom_gb": {
                                      "anyOf": [
                                        {
                                          "type": "number",
                                          "minimum": 0
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "required": [
                                    "flag",
                                    "source"
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "How recipe values become command-line flags: one mapping per parameter."
                          },
                          "process_command": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "default_concurrency": {
                            "description": "[MOT-143] How many requests the version serves at once: an integer, or an expression over the allocation; null when it does not say.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "health_check": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "path": {
                                    "type": "string"
                                  },
                                  "port_source": {
                                    "default": "runtime.port",
                                    "type": "string",
                                    "enum": [
                                      "runtime.port",
                                      "fixed"
                                    ]
                                  },
                                  "port": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "startup_patterns": {
                                    "type": "array",
                                    "items": {
                                      "type": "object",
                                      "properties": {
                                        "step": {
                                          "type": "string",
                                          "enum": [
                                            "weights",
                                            "compile",
                                            "init"
                                          ]
                                        },
                                        "pattern": {
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "step",
                                        "pattern"
                                      ],
                                      "additionalProperties": false
                                    }
                                  }
                                },
                                "required": [
                                  "path",
                                  "port_source"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Where GPU Kitchen asks the engine whether it serves."
                          },
                          "generation_route": {
                            "type": "string",
                            "enum": [
                              "completions",
                              "chat"
                            ],
                            "description": "[MOT-162] How a text-generation version generates: completions (POST /v1/completions) or chat (POST /v1/chat/completions)."
                          },
                          "failure_patterns": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string"
                                  },
                                  "additionalProperties": {}
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Log patterns that name why the engine failed."
                          },
                          "task_types": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The tasks this engine serves; null when it does not say, and is not checked."
                          },
                          "task_params": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string"
                                  },
                                  "additionalProperties": {}
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Per served task, the parameter values it imposes at launch."
                          },
                          "task_owned_params": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "Parameters a task imposes: a recipe never sets them."
                          },
                          "help_capture": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "status": {
                                    "type": "string",
                                    "enum": [
                                      "pending",
                                      "done",
                                      "failed"
                                    ]
                                  },
                                  "docker_image": {
                                    "type": "string"
                                  },
                                  "text": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "exit_code": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "error": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "started_at": {
                                    "type": "string"
                                  },
                                  "finished_at": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "status",
                                  "docker_image",
                                  "text",
                                  "exit_code",
                                  "error",
                                  "started_at",
                                  "finished_at"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The last run of the image's --help on a node, kept beside the version."
                          },
                          "cuda": {
                            "description": "[GPU-202] The CUDA toolkit the image embeds (X.Y.Z); null when unknown.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "min_driver": {
                            "description": "[GPU-202] The minimum NVIDIA driver that runs it, exact or a branch alone.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "cuda_unknown_reason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "compute_capabilities": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-66] The X.Y compute capabilities the image covers; null when unknown."
                          },
                          "dish": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "options": {
                                    "type": "object",
                                    "propertyNames": {
                                      "type": "string",
                                      "enum": [
                                        "vision",
                                        "tools",
                                        "reasoning"
                                      ]
                                    },
                                    "additionalProperties": {
                                      "type": "object",
                                      "properties": {
                                        "default": {
                                          "type": "string",
                                          "enum": [
                                            "on",
                                            "off",
                                            "template"
                                          ]
                                        },
                                        "on_when": {
                                          "type": [
                                            "string",
                                            "null"
                                          ]
                                        },
                                        "off_when": {
                                          "type": [
                                            "string",
                                            "null"
                                          ]
                                        }
                                      },
                                      "required": [
                                        "default"
                                      ],
                                      "additionalProperties": false
                                    },
                                    "required": [
                                      "vision",
                                      "tools",
                                      "reasoning"
                                    ]
                                  },
                                  "context_rule": {
                                    "type": "string",
                                    "enum": [
                                      "self_limited",
                                      "vllm-0.8",
                                      "vllm-0.19",
                                      "vllm-0.30",
                                      "sglang-0.4",
                                      "sglang-0.5"
                                    ]
                                  },
                                  "kv_auto_rule": {
                                    "type": "string",
                                    "enum": [
                                      "none",
                                      "vllm-0.26",
                                      "sglang-0.5.17",
                                      "sglang-0.5.18",
                                      "sglang-0.5.19",
                                      "tgi-3"
                                    ]
                                  }
                                },
                                "required": [
                                  "options",
                                  "context_rule",
                                  "kv_auto_rule"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-146] [MOT-164] [MOT-165] What makes a recipe's model setup on this version: its options' rules, how it gives an unstated context (it lowers it itself, or derives it from the model's configuration by its engine's rule) and which checkpoint KV its auto follows; null when the catalog has not declared it."
                          },
                          "is_public": {
                            "type": "boolean"
                          },
                          "recipe_count": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "test_result_count": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "family_id",
                          "name",
                          "docker_image",
                          "version",
                          "version_order",
                          "description",
                          "params_schema",
                          "dockerfile",
                          "args_map",
                          "process_command",
                          "default_concurrency",
                          "health_check",
                          "generation_route",
                          "failure_patterns",
                          "task_types",
                          "task_params",
                          "task_owned_params",
                          "help_capture",
                          "cuda",
                          "min_driver",
                          "cuda_unknown_reason",
                          "compute_capabilities",
                          "dish",
                          "is_public",
                          "recipe_count",
                          "test_result_count",
                          "created_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "engines"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/engines/{id}": {
      "get": {
        "operationId": "getEngine",
        "summary": "Read one inference engine",
        "tags": [
          "engines"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "engine": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "family_id": {
                          "type": "string",
                          "description": "The engine family every version of this engine shares."
                        },
                        "name": {
                          "type": "string"
                        },
                        "docker_image": {
                          "type": "string"
                        },
                        "version": {
                          "type": "string"
                        },
                        "version_order": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "params_schema": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The parameters a recipe may set, as JSON Schema."
                        },
                        "dockerfile": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "args_map": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "object",
                                "properties": {
                                  "flag": {
                                    "type": "string"
                                  },
                                  "source": {
                                    "type": "string",
                                    "enum": [
                                      "model.hfRepo",
                                      "model.localFile",
                                      "model.mmprojPath",
                                      "runtime.port",
                                      "runtime.servedName",
                                      "gpu.count",
                                      "recipe.params",
                                      "fixed",
                                      "default"
                                    ]
                                  },
                                  "value": {
                                    "anyOf": [
                                      {},
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "negative_flag": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "headroom_gb": {
                                    "anyOf": [
                                      {
                                        "type": "number",
                                        "minimum": 0
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "flag",
                                  "source"
                                ],
                                "additionalProperties": false
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "How recipe values become command-line flags: one mapping per parameter."
                        },
                        "process_command": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "default_concurrency": {
                          "description": "[MOT-143] How many requests the version serves at once: an integer, or an expression over the allocation; null when it does not say.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "health_check": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "path": {
                                  "type": "string"
                                },
                                "port_source": {
                                  "default": "runtime.port",
                                  "type": "string",
                                  "enum": [
                                    "runtime.port",
                                    "fixed"
                                  ]
                                },
                                "port": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "startup_patterns": {
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "step": {
                                        "type": "string",
                                        "enum": [
                                          "weights",
                                          "compile",
                                          "init"
                                        ]
                                      },
                                      "pattern": {
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "step",
                                      "pattern"
                                    ],
                                    "additionalProperties": false
                                  }
                                }
                              },
                              "required": [
                                "path",
                                "port_source"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Where GPU Kitchen asks the engine whether it serves."
                        },
                        "generation_route": {
                          "type": "string",
                          "enum": [
                            "completions",
                            "chat"
                          ],
                          "description": "[MOT-162] How a text-generation version generates: completions (POST /v1/completions) or chat (POST /v1/chat/completions)."
                        },
                        "failure_patterns": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Log patterns that name why the engine failed."
                        },
                        "task_types": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The tasks this engine serves; null when it does not say, and is not checked."
                        },
                        "task_params": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Per served task, the parameter values it imposes at launch."
                        },
                        "task_owned_params": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Parameters a task imposes: a recipe never sets them."
                        },
                        "help_capture": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "status": {
                                  "type": "string",
                                  "enum": [
                                    "pending",
                                    "done",
                                    "failed"
                                  ]
                                },
                                "docker_image": {
                                  "type": "string"
                                },
                                "text": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "exit_code": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "error": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "started_at": {
                                  "type": "string"
                                },
                                "finished_at": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "status",
                                "docker_image",
                                "text",
                                "exit_code",
                                "error",
                                "started_at",
                                "finished_at"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The last run of the image's --help on a node, kept beside the version."
                        },
                        "cuda": {
                          "description": "[GPU-202] The CUDA toolkit the image embeds (X.Y.Z); null when unknown.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "min_driver": {
                          "description": "[GPU-202] The minimum NVIDIA driver that runs it, exact or a branch alone.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "cuda_unknown_reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "compute_capabilities": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-66] The X.Y compute capabilities the image covers; null when unknown."
                        },
                        "dish": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "options": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string",
                                    "enum": [
                                      "vision",
                                      "tools",
                                      "reasoning"
                                    ]
                                  },
                                  "additionalProperties": {
                                    "type": "object",
                                    "properties": {
                                      "default": {
                                        "type": "string",
                                        "enum": [
                                          "on",
                                          "off",
                                          "template"
                                        ]
                                      },
                                      "on_when": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "off_when": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "default"
                                    ],
                                    "additionalProperties": false
                                  },
                                  "required": [
                                    "vision",
                                    "tools",
                                    "reasoning"
                                  ]
                                },
                                "context_rule": {
                                  "type": "string",
                                  "enum": [
                                    "self_limited",
                                    "vllm-0.8",
                                    "vllm-0.19",
                                    "vllm-0.30",
                                    "sglang-0.4",
                                    "sglang-0.5"
                                  ]
                                },
                                "kv_auto_rule": {
                                  "type": "string",
                                  "enum": [
                                    "none",
                                    "vllm-0.26",
                                    "sglang-0.5.17",
                                    "sglang-0.5.18",
                                    "sglang-0.5.19",
                                    "tgi-3"
                                  ]
                                }
                              },
                              "required": [
                                "options",
                                "context_rule",
                                "kv_auto_rule"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-146] [MOT-164] [MOT-165] What makes a recipe's model setup on this version: its options' rules, how it gives an unstated context (it lowers it itself, or derives it from the model's configuration by its engine's rule) and which checkpoint KV its auto follows; null when the catalog has not declared it."
                        },
                        "is_public": {
                          "type": "boolean"
                        },
                        "recipe_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "test_result_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "family_id",
                        "name",
                        "docker_image",
                        "version",
                        "version_order",
                        "description",
                        "params_schema",
                        "dockerfile",
                        "args_map",
                        "process_command",
                        "default_concurrency",
                        "health_check",
                        "generation_route",
                        "failure_patterns",
                        "task_types",
                        "task_params",
                        "task_owned_params",
                        "help_capture",
                        "cuda",
                        "min_driver",
                        "cuda_unknown_reason",
                        "compute_capabilities",
                        "dish",
                        "is_public",
                        "recipe_count",
                        "test_result_count",
                        "created_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "engine"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: engine_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/fair-share": {
      "get": {
        "operationId": "getFairShare",
        "summary": "Read every member's and application key's compiled privilege and recent GPU time",
        "description": "Privileges only decide who is served first while the GPUs are full; nothing is ever refused while a GPU is free.",
        "tags": [
          "fair-share"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "default_privilege": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 5
                    },
                    "wait_secs": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 3600
                    },
                    "background_wait_secs": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 3600
                    },
                    "subjects": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "type": {
                            "type": "string",
                            "enum": [
                              "member",
                              "key"
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "privilege": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 5
                          },
                          "range": {
                            "type": "string",
                            "enum": [
                              "background",
                              "standard",
                              "priority",
                              "critical"
                            ]
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "type",
                          "id",
                          "name",
                          "privilege",
                          "range",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "default_privilege",
                    "wait_secs",
                    "background_wait_secs",
                    "subjects"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-51",
          "QTA-52",
          "QTA-59",
          "QTA-70"
        ]
      }
    },
    "/api/v1/fair-share/settings": {
      "put": {
        "operationId": "setFairShareSettings",
        "summary": "Set the default privilege and the two waits of a full GPU pool",
        "tags": [
          "fair-share"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "default_privilege": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 5
                  },
                  "wait_secs": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 3600
                  },
                  "background_wait_secs": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 3600
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "default_privilege": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 5
                    },
                    "wait_secs": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 3600
                    },
                    "background_wait_secs": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 3600
                    }
                  },
                  "required": [
                    "default_privilege",
                    "wait_secs",
                    "background_wait_secs"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-51",
          "QTA-53",
          "QTA-43"
        ]
      }
    },
    "/api/v1/fair-share/subjects/{type}/{id}/usage": {
      "get": {
        "operationId": "getSubjectUsage",
        "summary": "Read where a member's or an application key's recent GPU time comes from",
        "description": "The subject's recent GPU time split by model, faded like its rank so the models add up to it: a member counts their personal keys, an application key itself, every request made with it included. Requests and tokens cover the last 7 days.",
        "tags": [
          "fair-share"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "type",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "member",
                "key"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "recent_gpuk_ms": {
                      "type": "number"
                    },
                    "recent_unmeasured_gpu_ms": {
                      "type": "number"
                    },
                    "models": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "model": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          },
                          "requests_7d": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "tokens_in_7d": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "tokens_out_7d": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": [
                          "model",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms",
                          "requests_7d",
                          "tokens_in_7d",
                          "tokens_out_7d"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "recent_gpuk_ms",
                    "recent_unmeasured_gpu_ms",
                    "models"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found, member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-52",
          "QTA-41",
          "QTA-70"
        ]
      }
    },
    "/api/v1/feature-flags": {
      "get": {
        "operationId": "listFeatureFlags",
        "summary": "List active features and unread announcements",
        "tags": [
          "feature-flags"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "flags": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": {
                            "type": "string"
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "source": {
                            "type": "string",
                            "enum": [
                              "default",
                              "central-global",
                              "central-cluster",
                              "dev-override",
                              "dev-open"
                            ]
                          },
                          "scope": {
                            "type": "string",
                            "enum": [
                              "global",
                              "cluster"
                            ]
                          },
                          "silent": {
                            "type": "boolean"
                          },
                          "requires_restart": {
                            "type": "boolean"
                          },
                          "remove_by": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "key",
                          "enabled",
                          "source",
                          "scope",
                          "silent",
                          "requires_restart",
                          "remove_by"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "announcements": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": {
                            "type": "string"
                          },
                          "title": {
                            "type": "string"
                          },
                          "body": {
                            "type": "string"
                          },
                          "fix_target": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "key",
                          "title",
                          "body",
                          "fix_target"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "flags",
                    "announcements"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "FLG-13",
          "FLG-22"
        ]
      }
    },
    "/api/v1/feature-flags/{key}/ack": {
      "post": {
        "operationId": "acknowledgeFeatureFlag",
        "summary": "Acknowledge a feature announcement",
        "tags": [
          "feature-flags"
        ],
        "parameters": [
          {
            "name": "key",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "acknowledged": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "acknowledged"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "FLG-23",
          "FLG-24"
        ]
      }
    },
    "/api/v1/gpu-configs": {
      "get": {
        "operationId": "listGpuConfigs",
        "summary": "List the GPU configurations and what is free now",
        "description": "Availability is read for one task (`alloc_task`, default local_inference) and is advisory: a card can be taken between this answer and a launch.",
        "tags": [
          "gpus"
        ],
        "parameters": [
          {
            "name": "alloc_task",
            "in": "query",
            "required": false,
            "schema": {
              "default": "local_inference",
              "type": "string",
              "enum": [
                "local_inference",
                "my_benchmark",
                "community"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "gpu_configs": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "gpu_config": {
                            "type": "string",
                            "description": "The canonical key, e.g. `rtx 3090*2`."
                          },
                          "label": {
                            "type": "string"
                          },
                          "gpu_model": {
                            "type": "string"
                          },
                          "compute_capability": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "manufacturer": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_count": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "vram_per_gpu": {
                            "type": "number",
                            "description": "Physical GB of each card."
                          },
                          "reserved_vram_per_gpu": {
                            "type": "number",
                            "description": "GB the operator reserved for the host system."
                          },
                          "usable_vram_per_gpu": {
                            "type": "number",
                            "description": "GB an engine may use on each card."
                          },
                          "total_vram": {
                            "type": "number",
                            "description": "Usable GB across the configuration."
                          },
                          "availability": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "description": "available, busy, lower_priority, not_allocated or no_hardware; later states may be added."
                              },
                              "free_slots": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 9007199254740991
                              },
                              "total_slots": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 9007199254740991
                              },
                              "blocked_by": {
                                "description": "A setting the operator could lift: bench_clock, vram_reserved or vram_system.",
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "nodes": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "node_id": {
                                      "type": "string"
                                    },
                                    "free_slots": {
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 9007199254740991
                                    },
                                    "total_slots": {
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 9007199254740991
                                    }
                                  },
                                  "required": [
                                    "node_id",
                                    "free_slots",
                                    "total_slots"
                                  ],
                                  "additionalProperties": false
                                }
                              }
                            },
                            "required": [
                              "status",
                              "free_slots",
                              "total_slots",
                              "blocked_by",
                              "nodes"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "gpu_config",
                          "label",
                          "gpu_model",
                          "compute_capability",
                          "manufacturer",
                          "gpu_count",
                          "vram_per_gpu",
                          "reserved_vram_per_gpu",
                          "usable_vram_per_gpu",
                          "total_vram",
                          "availability"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "gpu_configs"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "GPU-71"
        ]
      }
    },
    "/api/v1/gpus": {
      "get": {
        "operationId": "listGpus",
        "summary": "List the fleet's GPUs",
        "description": "Every present GPU of every node, or of one node with `node_id`; with `offline=include`, also the cards a disconnected node last reported, in state offline.",
        "tags": [
          "gpus"
        ],
        "parameters": [
          {
            "name": "node_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128
            }
          },
          {
            "name": "offline",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "include",
                "exclude"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "gpus": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "node_id": {
                            "type": "string"
                          },
                          "index": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "uid": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "vendor": {
                            "type": "string"
                          },
                          "model": {
                            "type": "string",
                            "description": "The normalized GPU model recipes and benchmarks name."
                          },
                          "compute_capability": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "vram_gb": {
                            "type": "number"
                          },
                          "usable_vram_gb": {
                            "type": "number",
                            "description": "What an engine may use: the card's VRAM minus the host's reservation."
                          },
                          "interconnect_peers": {
                            "type": "array",
                            "items": {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            }
                          },
                          "state": {
                            "type": "string",
                            "description": "free, busy (a GPU Kitchen container holds it), foreign (something else uses its VRAM), booked (a reservation or the occupancy plan holds it) or offline (its node is disconnected: the card as the node last reported it, never placeable; listed only with offline=include); later states may be added."
                          },
                          "holder": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "container_id": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  "name": {
                                    "type": "string"
                                  },
                                  "label": {
                                    "description": "What it runs, as screens call its recipe; null for a container with no recipe.",
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "alloc_task": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "enum": [
                                          "local_inference",
                                          "my_benchmark",
                                          "community"
                                        ]
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "What it was launched for; null for a container launched by hand."
                                  }
                                },
                                "required": [
                                  "container_id",
                                  "name",
                                  "label",
                                  "alloc_task"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "booking": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string"
                                  },
                                  "reservation_id": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "kind",
                                  "reservation_id"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "node_id",
                          "index",
                          "uid",
                          "name",
                          "vendor",
                          "model",
                          "compute_capability",
                          "vram_gb",
                          "usable_vram_gb",
                          "interconnect_peers",
                          "state",
                          "holder",
                          "booking"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "gpus"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: node_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "GPU-71",
          "PLN-13",
          "GPU-240"
        ]
      }
    },
    "/api/v1/invitations/{token}": {
      "get": {
        "operationId": "getInvitation",
        "summary": "Read the invitation a link opens",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "token",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 16,
              "maxLength": 128
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "email": {
                      "type": "string"
                    },
                    "name": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "email",
                    "name"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: invitation_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "410": {
            "description": "Error codes: invitation_expired, invitation_used.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-78"
        ]
      },
      "post": {
        "operationId": "acceptInvitation",
        "summary": "Choose the password of an invited account",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "token",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 16,
              "maxLength": 128
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "password": {
                    "type": "string",
                    "minLength": 8,
                    "maxLength": 1024
                  }
                },
                "required": [
                  "password"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "email": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "email"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: invitation_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "410": {
            "description": "Error codes: invitation_expired, invitation_used.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-78"
        ]
      }
    },
    "/api/v1/mail/settings": {
      "get": {
        "operationId": "getMailSettings",
        "summary": "Read the SMTP server the controller sends its e-mail through",
        "tags": [
          "mail"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "configured": {
                      "type": "boolean"
                    },
                    "host": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "port": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "security": {
                      "type": "string",
                      "enum": [
                        "tls",
                        "starttls",
                        "none"
                      ]
                    },
                    "username": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "from": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "password_set": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "configured",
                    "host",
                    "port",
                    "security",
                    "username",
                    "from",
                    "password_set"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "REG-321"
        ]
      },
      "put": {
        "operationId": "setMailSettings",
        "summary": "Set the SMTP server, or turn e-mail off with a null host",
        "description": "An omitted password keeps the stored one; null removes it. The password is stored encrypted and never read back.",
        "tags": [
          "mail"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "host": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 253
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "port": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 65535
                  },
                  "security": {
                    "type": "string",
                    "enum": [
                      "tls",
                      "starttls",
                      "none"
                    ]
                  },
                  "username": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 320
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "password": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 1024
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "from": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 320,
                        "format": "email",
                        "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "host",
                  "port",
                  "security",
                  "username",
                  "from"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "configured": {
                      "type": "boolean"
                    },
                    "host": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "port": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "security": {
                      "type": "string",
                      "enum": [
                        "tls",
                        "starttls",
                        "none"
                      ]
                    },
                    "username": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "from": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "password_set": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "configured",
                    "host",
                    "port",
                    "security",
                    "username",
                    "from",
                    "password_set"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: mail_from_required, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "REG-321"
        ]
      }
    },
    "/api/v1/mail/test": {
      "post": {
        "operationId": "sendTestMail",
        "summary": "Send a test e-mail to yourself through the stored server",
        "tags": [
          "mail"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sent_to": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "sent_to"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: mail_not_configured, no_email_address.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "502": {
            "description": "Error codes: mail_auth_failed, mail_connect_failed, mail_recipient_refused, mail_send_failed, mail_tls_failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "super_admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "REG-321"
        ]
      }
    },
    "/api/v1/me": {
      "get": {
        "operationId": "getMe",
        "summary": "Read the signed-in member",
        "tags": [
          "me"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string"
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    },
                    "pages": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "[NAV-137] The gated pages this member may open now, by root path; a page absent from the catalog is open to every member."
                    }
                  },
                  "required": [
                    "member",
                    "pages"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-04",
          "API-05",
          "NAV-137"
        ]
      }
    },
    "/api/v1/me/consumption": {
      "get": {
        "operationId": "getMyConsumption",
        "summary": "Read my GPU time",
        "description": "GPU time for the signed-in member only, with the Usage chart and timeline data. Each row's value and steps are GPUk·ms (GPUk.h × 3,600,000; an RTX 3090 = 1 GPUk); its last field is the raw GPU·ms served on cards not measured yet, never counted in the value.",
        "tags": [
          "usage"
        ],
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time",
              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
            }
          },
          {
            "name": "period",
            "in": "query",
            "required": false,
            "schema": {
              "default": "24h",
              "type": "string",
              "enum": [
                "1h",
                "24h",
                "7d",
                "30d"
              ]
            }
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time",
              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "period": {
                      "type": "string",
                      "enum": [
                        "1h",
                        "24h",
                        "7d",
                        "30d"
                      ]
                    },
                    "stretch": {
                      "anyOf": [
                        {
                          "type": "object",
                          "properties": {
                            "from": {
                              "type": "string",
                              "format": "date-time",
                              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
                            },
                            "to": {
                              "type": "string",
                              "format": "date-time",
                              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
                            }
                          },
                          "required": [
                            "from",
                            "to"
                          ],
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "generated_at": {
                      "type": "string",
                      "format": "date-time",
                      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
                    },
                    "gpus": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "series": {
                      "type": "object",
                      "properties": {
                        "from": {
                          "type": "string",
                          "format": "date-time",
                          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
                        },
                        "step_ms": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "points": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": [
                        "from",
                        "step_ms",
                        "points"
                      ],
                      "additionalProperties": false
                    },
                    "nodes": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "prefixItems": [
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        ],
                        "items": false,
                        "minItems": 2,
                        "maxItems": 2
                      }
                    },
                    "models": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "prefixItems": [
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        ],
                        "items": false,
                        "minItems": 2,
                        "maxItems": 2
                      }
                    },
                    "subjects": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "prefixItems": [
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        ],
                        "items": false,
                        "minItems": 4,
                        "maxItems": 4
                      }
                    },
                    "rows": {
                      "type": "array",
                      "items": {
                        "type": "array",
                        "prefixItems": [
                          {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          {
                            "type": "number"
                          },
                          {
                            "type": "array",
                            "items": {
                              "type": "number"
                            }
                          },
                          {
                            "type": "number"
                          }
                        ],
                        "items": false,
                        "minItems": 8,
                        "maxItems": 8
                      }
                    }
                  },
                  "required": [
                    "period",
                    "stretch",
                    "generated_at",
                    "gpus",
                    "series",
                    "nodes",
                    "models",
                    "subjects",
                    "rows"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invalid_request, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "NAV-91",
          "QTA-54",
          "QTA-71"
        ]
      }
    },
    "/api/v1/me/inference-credentials": {
      "get": {
        "operationId": "listMyInferenceCredentials",
        "summary": "List the signed-in member's inference credentials",
        "tags": [
          "inference-credentials"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "credentials": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "provider_id": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 2147483647
                          },
                          "provider_slug": {
                            "type": "string"
                          },
                          "provider_name": {
                            "type": "string"
                          },
                          "provider_kind": {
                            "type": "string",
                            "enum": [
                              "openai",
                              "anthropic",
                              "openrouter",
                              "openai_compatible"
                            ]
                          },
                          "provider_enabled": {
                            "type": "boolean"
                          },
                          "policy": {
                            "type": "string",
                            "enum": [
                              "shared_only",
                              "member_preferred",
                              "member_required"
                            ]
                          },
                          "configured": {
                            "type": "boolean"
                          },
                          "last4": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "updated_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "unknown",
                                  "invalid"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status_checked_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "provider_id",
                          "provider_slug",
                          "provider_name",
                          "provider_kind",
                          "provider_enabled",
                          "policy",
                          "configured",
                          "last4",
                          "updated_at",
                          "status",
                          "status_checked_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "credentials"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61"
        ]
      }
    },
    "/api/v1/me/inference-credentials/{providerId}": {
      "delete": {
        "operationId": "deleteMyInferenceCredential",
        "summary": "Delete the signed-in member's inference credential",
        "tags": [
          "inference-credentials"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: credential_not_found, not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61",
          "API-67"
        ]
      },
      "put": {
        "operationId": "setMyInferenceCredential",
        "summary": "Store or replace the signed-in member's inference credential",
        "tags": [
          "inference-credentials"
        ],
        "parameters": [
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "credential": {
                    "type": "string",
                    "maxLength": 4096
                  }
                },
                "required": [
                  "credential"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "credential": {
                      "type": "object",
                      "properties": {
                        "provider_id": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 2147483647
                        },
                        "provider_slug": {
                          "type": "string"
                        },
                        "provider_name": {
                          "type": "string"
                        },
                        "provider_kind": {
                          "type": "string",
                          "enum": [
                            "openai",
                            "anthropic",
                            "openrouter",
                            "openai_compatible"
                          ]
                        },
                        "provider_enabled": {
                          "type": "boolean"
                        },
                        "policy": {
                          "type": "string",
                          "enum": [
                            "shared_only",
                            "member_preferred",
                            "member_required"
                          ]
                        },
                        "configured": {
                          "type": "boolean"
                        },
                        "last4": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "updated_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "unknown",
                                "invalid"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status_checked_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "provider_id",
                        "provider_slug",
                        "provider_name",
                        "provider_kind",
                        "provider_enabled",
                        "policy",
                        "configured",
                        "last4",
                        "updated_at",
                        "status",
                        "status_checked_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "credential"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, member_disabled, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found, provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: member_credentials_not_accepted.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61"
        ]
      }
    },
    "/api/v1/me/keys": {
      "get": {
        "operationId": "listMyKeys",
        "summary": "List the member's own inference keys",
        "tags": [
          "me"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key_id": {
                            "type": "string"
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "segment": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "interactive",
                                  "realtime_api",
                                  "batch"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "revoked_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "key_id",
                          "label",
                          "segment",
                          "created_at",
                          "revoked_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-26",
          "API-60"
        ]
      },
      "post": {
        "operationId": "createMyKey",
        "summary": "Create an inference key for the member",
        "tags": [
          "me"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 80
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "segment": {},
                  "team_id": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "object",
                      "properties": {
                        "key_id": {
                          "type": "string"
                        },
                        "label": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "segment": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "interactive",
                                "realtime_api",
                                "batch"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "revoked_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "key": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "key_id",
                        "label",
                        "segment",
                        "created_at",
                        "revoked_at",
                        "key"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "key"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_membership_blocked.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-26",
          "QTA-08",
          "API-60",
          "API-67"
        ]
      }
    },
    "/api/v1/me/keys/{keyId}": {
      "delete": {
        "operationId": "revokeMyKey",
        "summary": "Revoke an inference key owned by the member",
        "tags": [
          "me"
        ],
        "parameters": [
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-26",
          "API-48",
          "API-60",
          "API-67"
        ]
      }
    },
    "/api/v1/me/keys/{keyId}/sources": {
      "get": {
        "operationId": "listMyKeySources",
        "summary": "List the source addresses that used a member's inference key",
        "tags": [
          "me"
        ],
        "parameters": [
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sources": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": "string"
                          },
                          "hostname": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "first_seen": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_seen": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "source",
                          "hostname",
                          "first_seen",
                          "last_seen",
                          "requests",
                          "tokens"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "sources"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-75",
          "USG-34",
          "API-48",
          "API-60"
        ]
      }
    },
    "/api/v1/me/management-keys": {
      "get": {
        "operationId": "listMyManagementKeys",
        "summary": "List the signed-in member's active management keys",
        "tags": [
          "management-keys"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "Key id: the public part of the token."
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role_ceiling": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ],
                            "description": "Highest role the key acts with; the owner's live role caps it."
                          },
                          "read_only": {
                            "type": "boolean",
                            "description": "A read-only key may only call GET operations."
                          },
                          "prefix": {
                            "type": "string",
                            "description": "Non-secret display hint: the head of the token."
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_used_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_used_ip": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "label",
                          "role_ceiling",
                          "read_only",
                          "prefix",
                          "created_at",
                          "expires_at",
                          "last_used_at",
                          "last_used_ip"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "SEC-62",
          "API-60"
        ]
      },
      "post": {
        "operationId": "createMyManagementKey",
        "summary": "Create a management key for the signed-in member",
        "description": "The token is in this response only, once. The role ceiling defaults to the member's role short of super_admin; a ceiling above the member's own role is refused.",
        "tags": [
          "management-keys"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 100
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "role_ceiling": {
                    "type": "string",
                    "enum": [
                      "super_admin",
                      "admin",
                      "operator",
                      "user"
                    ]
                  },
                  "read_only": {
                    "type": "boolean"
                  },
                  "expires_at": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "date-time",
                        "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "Key id: the public part of the token."
                        },
                        "label": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_ceiling": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ],
                          "description": "Highest role the key acts with; the owner's live role caps it."
                        },
                        "read_only": {
                          "type": "boolean",
                          "description": "A read-only key may only call GET operations."
                        },
                        "prefix": {
                          "type": "string",
                          "description": "Non-secret display hint: the head of the token."
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_used_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_used_ip": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "key": {
                          "type": "string",
                          "description": "The full token. Shown once."
                        }
                      },
                      "required": [
                        "id",
                        "label",
                        "role_ceiling",
                        "read_only",
                        "prefix",
                        "created_at",
                        "expires_at",
                        "last_used_at",
                        "last_used_ip",
                        "key"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "key"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: cannot_grant_higher_role, forbidden, operator_requires_offer, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "SEC-62",
          "SEC-63"
        ]
      }
    },
    "/api/v1/me/management-keys/{keyId}": {
      "delete": {
        "operationId": "revokeMyManagementKey",
        "summary": "Revoke one of the signed-in member's management keys",
        "tags": [
          "management-keys"
        ],
        "parameters": [
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "SEC-62"
        ]
      }
    },
    "/api/v1/me/models": {
      "get": {
        "operationId": "listMyModels",
        "summary": "List the models the proxy serves to the signed-in member",
        "tags": [
          "me"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "key_count": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "models": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "task_type": {
                            "type": "string",
                            "enum": [
                              "text-generation",
                              "embedding",
                              "reranking",
                              "classification",
                              "asr",
                              "tts",
                              "speech-to-speech",
                              "image-generation",
                              "vision",
                              "audio-generation",
                              "video-generation",
                              "custom"
                            ]
                          },
                          "off_site": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "name",
                          "task_type",
                          "off_site"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "on_demand": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "task_type": {
                            "type": "string",
                            "enum": [
                              "text-generation",
                              "embedding",
                              "reranking",
                              "classification",
                              "asr",
                              "tts",
                              "speech-to-speech",
                              "image-generation",
                              "vision",
                              "audio-generation",
                              "video-generation",
                              "custom"
                            ]
                          },
                          "typical_wait_seconds": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "exclusiveMinimum": 0,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "name",
                          "task_type",
                          "typical_wait_seconds"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "key_count",
                    "models",
                    "on_demand"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "NAV-58",
          "SOD-02"
        ]
      }
    },
    "/api/v1/me/notifications": {
      "get": {
        "operationId": "getMyNotifications",
        "summary": "Read how you receive each kind of e-mail",
        "tags": [
          "mail"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "kinds": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "team_requests",
                          "request_answers",
                          "support_answers",
                          "support_actions"
                        ]
                      }
                    },
                    "preferences": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string",
                        "enum": [
                          "team_requests",
                          "request_answers",
                          "support_answers",
                          "support_actions"
                        ]
                      },
                      "additionalProperties": {
                        "type": "string",
                        "enum": [
                          "each",
                          "daily",
                          "never"
                        ]
                      }
                    }
                  },
                  "required": [
                    "kinds",
                    "preferences"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-65"
        ]
      },
      "put": {
        "operationId": "setMyNotifications",
        "summary": "Choose how you receive one kind of e-mail",
        "tags": [
          "mail"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "kind": {
                    "type": "string",
                    "enum": [
                      "team_requests",
                      "request_answers",
                      "support_answers",
                      "support_actions"
                    ]
                  },
                  "mode": {
                    "type": "string",
                    "enum": [
                      "each",
                      "daily",
                      "never"
                    ]
                  }
                },
                "required": [
                  "kind",
                  "mode"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "kinds": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "team_requests",
                          "request_answers",
                          "support_answers",
                          "support_actions"
                        ]
                      }
                    },
                    "preferences": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string",
                        "enum": [
                          "team_requests",
                          "request_answers",
                          "support_answers",
                          "support_actions"
                        ]
                      },
                      "additionalProperties": {
                        "type": "string",
                        "enum": [
                          "each",
                          "daily",
                          "never"
                        ]
                      }
                    }
                  },
                  "required": [
                    "kinds",
                    "preferences"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, mail_kind_not_yours, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-65"
        ]
      }
    },
    "/api/v1/me/password": {
      "post": {
        "operationId": "changeMyPassword",
        "summary": "Change my password",
        "description": "Keeps this session signed in and ends every other session of the account.",
        "tags": [
          "me"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "current_password": {
                    "type": "string",
                    "maxLength": 1024
                  },
                  "new_password": {
                    "type": "string",
                    "minLength": 8,
                    "maxLength": 1024
                  }
                },
                "required": [
                  "new_password"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, invalid_current_password, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: no_local_password.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "API-10"
        ]
      }
    },
    "/api/v1/me/profile": {
      "patch": {
        "operationId": "updateMyProfile",
        "summary": "Change my local login and contact email",
        "description": "Requires this member's session, current local password and at least one profile field. Omitted fields keep their stored value; null clears contact. Keeps sessions, keys and linked sign-in identities.",
        "tags": [
          "me"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "login": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 320
                  },
                  "contact_email": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 320,
                        "format": "email",
                        "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "current_password": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 1024
                  }
                },
                "required": [
                  "current_password"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string"
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "member"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, invalid_current_password, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: email_already_exists, no_local_password.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-82",
          "EAU-83",
          "EAU-84",
          "EAU-85",
          "API-60"
        ]
      }
    },
    "/api/v1/me/provider-limits": {
      "get": {
        "operationId": "listMyProviderLimits",
        "summary": "List the signed-in member's shared provider budgets",
        "tags": [
          "me"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "limits": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "provider_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider_name": {
                            "type": "string"
                          },
                          "currency": {
                            "type": "string"
                          },
                          "spent": {
                            "type": "string"
                          },
                          "limit": {
                            "type": "string"
                          },
                          "blocked_until": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "provider_id",
                          "provider_name",
                          "currency",
                          "spent",
                          "limit",
                          "blocked_until"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "limits"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "FEX-36"
        ]
      }
    },
    "/api/v1/me/quota": {
      "get": {
        "operationId": "getMyQuota",
        "summary": "Read the member's own priority, recent GPU time, budget and led teams",
        "description": "The privilege range and recent GPU time only order requests while the GPUs are full; they never limit anything.",
        "tags": [
          "budgets"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "privilege": {
                      "type": "object",
                      "properties": {
                        "value": {
                          "type": "number"
                        },
                        "range": {
                          "type": "string",
                          "enum": [
                            "background",
                            "standard",
                            "priority",
                            "critical"
                          ]
                        }
                      },
                      "required": [
                        "value",
                        "range"
                      ],
                      "additionalProperties": false
                    },
                    "recent_gpuk_ms": {
                      "type": "number"
                    },
                    "recent_unmeasured_gpu_ms": {
                      "type": "number"
                    },
                    "personal": {
                      "type": "object",
                      "properties": {
                        "spent": {
                          "type": "string",
                          "pattern": "^\\d+(?:\\.\\d+)?$"
                        },
                        "budget": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "source": {
                          "type": "string",
                          "enum": [
                            "own",
                            "default"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "within",
                            "near",
                            "reached",
                            "unlimited"
                          ]
                        },
                        "ceiling": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "enum": [
                                    "personal",
                                    "share",
                                    "team"
                                  ]
                                },
                                "team_id": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "spent": {
                                  "type": "string",
                                  "pattern": "^\\d+(?:\\.\\d+)?$"
                                },
                                "budget": {
                                  "type": "string",
                                  "pattern": "^\\d+(?:\\.\\d+)?$"
                                }
                              },
                              "required": [
                                "kind",
                                "team_id",
                                "spent",
                                "budget"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "resumes_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "gpu_hours_monthly": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "spent",
                        "budget",
                        "source",
                        "status",
                        "ceiling",
                        "resumes_at",
                        "gpu_hours_monthly"
                      ],
                      "additionalProperties": false
                    },
                    "led_teams": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "spent": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "budget": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "within",
                              "near",
                              "reached",
                              "unlimited"
                            ]
                          },
                          "reached": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "near": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "spent",
                          "budget",
                          "status",
                          "reached",
                          "near"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "privilege",
                    "recent_gpuk_ms",
                    "recent_unmeasured_gpu_ms",
                    "personal",
                    "led_teams"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-44",
          "PLN-27"
        ]
      }
    },
    "/api/v1/me/team-answers": {
      "get": {
        "operationId": "getMyTeamAnswers",
        "summary": "Count the answers to your requests you have not read, per team you lead",
        "tags": [
          "teams"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "teams": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "team_id": {
                            "type": "string"
                          },
                          "unseen": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": [
                          "team_id",
                          "unseen"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "teams"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, user_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-62"
        ]
      }
    },
    "/api/v1/me/teams": {
      "get": {
        "operationId": "listMyTeams",
        "summary": "List the member's teams and their current quota usage",
        "tags": [
          "me"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "teams": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_hours_monthly": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "standard",
                              "application"
                            ]
                          },
                          "external_budget_monthly": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "member_count": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "spent_month": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "blocked": {
                            "type": "boolean"
                          },
                          "is_lead": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "description",
                          "gpu_hours_monthly",
                          "kind",
                          "external_budget_monthly",
                          "created_at",
                          "member_count",
                          "spent_month",
                          "blocked",
                          "is_lead"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "teams"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-28",
          "NAV-55",
          "NAV-59"
        ]
      }
    },
    "/api/v1/me/usage": {
      "get": {
        "operationId": "getMyUsage",
        "summary": "Read the member's own usage totals and time series",
        "tags": [
          "me"
        ],
        "parameters": [
          {
            "name": "range",
            "in": "query",
            "required": false,
            "schema": {
              "default": "7d",
              "type": "string",
              "enum": [
                "24h",
                "7d",
                "30d"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "range": {
                      "type": "string",
                      "enum": [
                        "24h",
                        "7d",
                        "30d"
                      ]
                    },
                    "since": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "totals": {
                      "type": "object",
                      "properties": {
                        "requests": {
                          "type": "string"
                        },
                        "tokens_in": {
                          "type": "string"
                        },
                        "tokens_out": {
                          "type": "string"
                        },
                        "gpuk_ms": {
                          "type": "string"
                        },
                        "unmeasured_gpu_ms": {
                          "type": "string"
                        },
                        "errors": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "requests",
                        "tokens_in",
                        "tokens_out",
                        "gpuk_ms",
                        "unmeasured_gpu_ms",
                        "errors"
                      ],
                      "additionalProperties": false
                    },
                    "by_model": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "model": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens_in": {
                            "type": "string"
                          },
                          "tokens_out": {
                            "type": "string"
                          },
                          "gpuk_ms": {
                            "type": "string"
                          },
                          "unmeasured_gpu_ms": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "model",
                          "requests",
                          "tokens_in",
                          "tokens_out",
                          "gpuk_ms",
                          "unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "timeseries": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "bucket": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens_in": {
                            "type": "string"
                          },
                          "tokens_out": {
                            "type": "string"
                          },
                          "gpuk_ms": {
                            "type": "string"
                          },
                          "unmeasured_gpu_ms": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "bucket",
                          "requests",
                          "tokens_in",
                          "tokens_out",
                          "gpuk_ms",
                          "unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "range",
                    "since",
                    "totals",
                    "by_model",
                    "timeseries"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-27",
          "API-47"
        ]
      }
    },
    "/api/v1/members": {
      "get": {
        "operationId": "listMembers",
        "summary": "List the cluster's members",
        "tags": [
          "members"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ]
                          },
                          "contact_email": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role_override": {
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "active",
                              "disabled"
                            ]
                          },
                          "has_password": {
                            "type": "boolean"
                          },
                          "is_bootstrap": {
                            "type": "boolean"
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "providers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "teams": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": "string"
                                },
                                "is_lead": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "id",
                                "name",
                                "is_lead"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "id",
                          "email",
                          "name",
                          "role",
                          "contact_email",
                          "role_override",
                          "status",
                          "has_password",
                          "is_bootstrap",
                          "created_at",
                          "last_login_at",
                          "providers",
                          "teams"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "members"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-08",
          "API-47"
        ]
      },
      "post": {
        "operationId": "createMember",
        "summary": "Create a local member account",
        "tags": [
          "members"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "format": "includes",
                    "pattern": "@"
                  },
                  "name": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "role": {
                    "default": "user",
                    "type": "string",
                    "enum": [
                      "super_admin",
                      "admin",
                      "operator",
                      "user"
                    ]
                  },
                  "password": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 8
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "invite": {
                    "type": "boolean"
                  },
                  "sso": {
                    "type": "boolean"
                  },
                  "team_id": {
                    "type": "string"
                  }
                },
                "required": [
                  "email"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "active",
                            "disabled"
                          ]
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    },
                    "initial_password": {
                      "type": "string"
                    },
                    "invitation": {
                      "type": "object",
                      "properties": {
                        "sent": {
                          "type": "boolean"
                        },
                        "error": {
                          "type": [
                            "string",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "sent",
                        "error"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "member"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invite_with_password, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, cannot_grant_higher_role, forbidden, member_limit_reached, operator_requires_offer, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: email_already_exists, mail_not_configured, multi_user_requires_sign_in.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-08",
          "API-60",
          "EAU-78",
          "EDI-30",
          "EDI-31"
        ]
      }
    },
    "/api/v1/members/{id}": {
      "delete": {
        "operationId": "deleteMember",
        "summary": "Delete an account nobody has signed in to",
        "description": "Only an account that never signed in and that no directory names: its invitation stops working and its keys are revoked. An account someone used is disabled instead.",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: cannot_delete_self, last_super_admin, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: member_signed_in.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-100"
        ]
      },
      "patch": {
        "operationId": "updateMember",
        "summary": "Update a member's account and access",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "role": {
                    "type": "string",
                    "enum": [
                      "super_admin",
                      "admin",
                      "operator",
                      "user"
                    ]
                  },
                  "role_override": {
                    "type": "boolean"
                  },
                  "status": {
                    "type": "string",
                    "enum": [
                      "active",
                      "disabled"
                    ]
                  },
                  "name": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "login": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 320,
                    "format": "includes",
                    "pattern": "@"
                  },
                  "password": {
                    "type": "string",
                    "minLength": 8
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "active",
                            "disabled"
                          ]
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "member"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, cannot_grant_higher_role, forbidden, member_limit_reached, operator_requires_offer, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: email_already_exists, login_locked, multi_user_requires_sign_in, operator_cannot_lead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-08",
          "EAU-31",
          "API-60",
          "EDI-30",
          "EAU-94"
        ]
      }
    },
    "/api/v1/members/{id}/identities": {
      "get": {
        "operationId": "listMemberIdentities",
        "summary": "List a member's linked sign-in identities and available providers",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "identities": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider": {
                            "type": "string"
                          },
                          "subject": {
                            "type": "string"
                          },
                          "linked_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "provider_id",
                          "provider",
                          "subject",
                          "linked_at",
                          "last_login_at"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "providers": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "name": {
                            "type": "string"
                          },
                          "type": {
                            "type": "string",
                            "enum": [
                              "oidc",
                              "ldap",
                              "saml"
                            ]
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "subject_source": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "type",
                          "enabled",
                          "subject_source"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "identities",
                    "providers"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-37"
        ]
      },
      "post": {
        "operationId": "linkMemberIdentity",
        "summary": "Link a sign-in identity to a member",
        "description": "Answers 201 when the identity is linked now, 200 when it was already this member's.",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "provider_id": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 2147483647
                  },
                  "subject": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 512
                  }
                },
                "required": [
                  "provider_id",
                  "subject"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success, it already existed.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string"
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    },
                    "identities": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider": {
                            "type": "string"
                          },
                          "subject": {
                            "type": "string"
                          },
                          "linked_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "provider_id",
                          "provider",
                          "subject",
                          "linked_at",
                          "last_login_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "member",
                    "identities"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "201": {
            "description": "Created.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "member": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role": {
                          "type": "string",
                          "enum": [
                            "super_admin",
                            "admin",
                            "operator",
                            "user"
                          ]
                        },
                        "contact_email": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "role_override": {
                          "type": "boolean"
                        },
                        "status": {
                          "type": "string"
                        },
                        "has_password": {
                          "type": "boolean"
                        },
                        "is_bootstrap": {
                          "type": "boolean"
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "last_login_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "providers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "teams": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "is_lead": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "is_lead"
                            ],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "id",
                        "email",
                        "name",
                        "role",
                        "contact_email",
                        "role_override",
                        "status",
                        "has_password",
                        "is_bootstrap",
                        "created_at",
                        "last_login_at",
                        "providers",
                        "teams"
                      ],
                      "additionalProperties": false
                    },
                    "identities": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "provider": {
                            "type": "string"
                          },
                          "subject": {
                            "type": "string"
                          },
                          "linked_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "provider_id",
                          "provider",
                          "subject",
                          "linked_at",
                          "last_login_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "member",
                    "identities"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invalid_subject, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found, provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: identity_already_linked.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-37",
          "API-60"
        ]
      }
    },
    "/api/v1/members/{id}/identities/{identityId}": {
      "delete": {
        "operationId": "unlinkMemberIdentity",
        "summary": "Unlink a member's sign-in identity and revoke its sessions",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "identityId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: identity_not_found, member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-37",
          "API-60"
        ]
      }
    },
    "/api/v1/members/{id}/identities/lookup": {
      "post": {
        "operationId": "lookupMemberIdentity",
        "summary": "Look up the directory subject to link to a member",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "provider_id": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 2147483647
                  },
                  "login": {
                    "type": "string",
                    "maxLength": 256
                  }
                },
                "required": [
                  "provider_id",
                  "login"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "subject": {
                      "type": "string"
                    },
                    "dn": {
                      "type": "string"
                    },
                    "email": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "subject",
                    "dn",
                    "email"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: lookup_unsupported, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: directory_entry_not_found, member_not_found, provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: directory_entry_ambiguous.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "502": {
            "description": "Error codes: ldap_unreachable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-37",
          "API-60"
        ]
      }
    },
    "/api/v1/members/{id}/inference-credentials": {
      "get": {
        "operationId": "listMemberInferenceCredentials",
        "summary": "List a member's inference credentials",
        "tags": [
          "inference-credentials"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "credentials": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "provider_id": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 2147483647
                          },
                          "provider_slug": {
                            "type": "string"
                          },
                          "provider_name": {
                            "type": "string"
                          },
                          "provider_kind": {
                            "type": "string",
                            "enum": [
                              "openai",
                              "anthropic",
                              "openrouter",
                              "openai_compatible"
                            ]
                          },
                          "provider_enabled": {
                            "type": "boolean"
                          },
                          "policy": {
                            "type": "string",
                            "enum": [
                              "shared_only",
                              "member_preferred",
                              "member_required"
                            ]
                          },
                          "configured": {
                            "type": "boolean"
                          },
                          "last4": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "updated_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "unknown",
                                  "invalid"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status_checked_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "provider_id",
                          "provider_slug",
                          "provider_name",
                          "provider_kind",
                          "provider_enabled",
                          "policy",
                          "configured",
                          "last4",
                          "updated_at",
                          "status",
                          "status_checked_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "credentials"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found, not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61"
        ]
      }
    },
    "/api/v1/members/{id}/inference-credentials/{providerId}": {
      "delete": {
        "operationId": "deleteMemberInferenceCredential",
        "summary": "Delete a member's inference credential",
        "tags": [
          "inference-credentials"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: credential_not_found, member_not_found, not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61",
          "API-67"
        ]
      },
      "put": {
        "operationId": "setMemberInferenceCredential",
        "summary": "Store or replace a member's inference credential",
        "tags": [
          "inference-credentials"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "providerId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "credential": {
                    "type": "string",
                    "maxLength": 4096
                  }
                },
                "required": [
                  "credential"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "credential": {
                      "type": "object",
                      "properties": {
                        "provider_id": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 2147483647
                        },
                        "provider_slug": {
                          "type": "string"
                        },
                        "provider_name": {
                          "type": "string"
                        },
                        "provider_kind": {
                          "type": "string",
                          "enum": [
                            "openai",
                            "anthropic",
                            "openrouter",
                            "openai_compatible"
                          ]
                        },
                        "provider_enabled": {
                          "type": "boolean"
                        },
                        "policy": {
                          "type": "string",
                          "enum": [
                            "shared_only",
                            "member_preferred",
                            "member_required"
                          ]
                        },
                        "configured": {
                          "type": "boolean"
                        },
                        "last4": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "updated_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "unknown",
                                "invalid"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status_checked_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "provider_id",
                        "provider_slug",
                        "provider_name",
                        "provider_kind",
                        "provider_enabled",
                        "policy",
                        "configured",
                        "last4",
                        "updated_at",
                        "status",
                        "status_checked_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "credential"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, member_disabled, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found, not_found, provider_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: member_credentials_not_accepted.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-32",
          "FEX-17",
          "API-61"
        ]
      }
    },
    "/api/v1/members/{id}/invitation": {
      "post": {
        "operationId": "inviteMember",
        "summary": "Send a member a new invitation e-mail to choose their password",
        "description": "The link of the previous invitation stops working.",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sent_to": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "sent_to"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: mail_not_configured, member_disabled, member_has_identity, member_has_password.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "502": {
            "description": "Error codes: mail_auth_failed, mail_connect_failed, mail_recipient_refused, mail_send_failed, mail_tls_failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-78"
        ]
      }
    },
    "/api/v1/members/{id}/management-keys": {
      "get": {
        "operationId": "listMemberManagementKeys",
        "summary": "List a member's active management keys",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role_ceiling": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ]
                          },
                          "read_only": {
                            "type": "boolean"
                          },
                          "prefix": {
                            "type": "string"
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_used_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_used_ip": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "label",
                          "role_ceiling",
                          "read_only",
                          "prefix",
                          "created_at",
                          "expires_at",
                          "last_used_at",
                          "last_used_ip"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-31",
          "API-60"
        ]
      }
    },
    "/api/v1/members/{id}/management-keys/{keyId}": {
      "delete": {
        "operationId": "revokeMemberManagementKey",
        "summary": "Revoke a member's management key",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found, member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-31",
          "API-60"
        ]
      }
    },
    "/api/v1/members/{id}/sessions/revoke": {
      "post": {
        "operationId": "revokeMemberSessions",
        "summary": "Revoke every session of a member",
        "tags": [
          "members"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "revoked": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "revoked"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "EAU-08",
          "API-60"
        ]
      }
    },
    "/api/v1/members/bulk": {
      "post": {
        "operationId": "updateMembers",
        "summary": "Give several members one role, one status, or one more team, all or none",
        "description": "The change applies to every member listed, in one transaction: a refusal for one changes none. One audit entry names them all.",
        "tags": [
          "members"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "member_ids": {
                    "minItems": 1,
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    }
                  },
                  "role": {
                    "type": "string",
                    "enum": [
                      "super_admin",
                      "admin",
                      "operator",
                      "user"
                    ]
                  },
                  "status": {
                    "type": "string",
                    "enum": [
                      "active",
                      "disabled"
                    ]
                  },
                  "add_to_team": {
                    "type": "string",
                    "minLength": 1
                  }
                },
                "required": [
                  "member_ids"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "updated": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "updated"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: cannot_disable_self, last_super_admin, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, cannot_grant_higher_role, forbidden, member_limit_reached, operator_requires_offer, session_required, super_admin_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: multi_user_requires_sign_in, operator_cannot_lead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-77",
          "EAU-08",
          "EDI-30"
        ]
      }
    },
    "/api/v1/members/invitations": {
      "post": {
        "operationId": "inviteMembers",
        "summary": "Invite several people by e-mail, into a team if one is named",
        "description": "A new address gets an account and an invitation; an existing account joins the team, or is said to exist. Each address answers on its own.",
        "tags": [
          "members"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "emails": {
                    "minItems": 1,
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 320,
                      "format": "includes",
                      "pattern": "@"
                    }
                  },
                  "role": {
                    "default": "user",
                    "type": "string",
                    "enum": [
                      "user",
                      "operator",
                      "admin",
                      "super_admin"
                    ]
                  },
                  "team_id": {
                    "type": "string"
                  }
                },
                "required": [
                  "emails"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "results": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "email": {
                            "type": "string"
                          },
                          "outcome": {
                            "type": "string",
                            "enum": [
                              "invited",
                              "added",
                              "exists",
                              "refused"
                            ]
                          },
                          "error": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "email",
                          "outcome"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "results"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, cannot_grant_higher_role, forbidden, operator_requires_offer, session_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: mail_not_configured.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-78"
        ]
      }
    },
    "/api/v1/menu": {
      "get": {
        "operationId": "listMenu",
        "summary": "List the menu: every name on it and its phase",
        "description": "One entry per name, sorted by name.",
        "tags": [
          "menu"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "menu": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string",
                            "description": "[VIS-18] The public name."
                          },
                          "plat_key": {
                            "type": "string"
                          },
                          "objective": {
                            "description": "Null for a custom model setup.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "phase": {
                            "type": "string",
                            "enum": [
                              "serving",
                              "replacing",
                              "restarting",
                              "sleeping",
                              "waking",
                              "idling",
                              "stopping",
                              "off",
                              "failed",
                              "maintenance"
                            ],
                            "description": "[MNU-03] What the proxy does with a request for it."
                          },
                          "phase_reason": {
                            "description": "Why: a restart's wait, a failure's cause; null otherwise.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "phase_since": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "covered": {
                            "type": "boolean",
                            "description": "[MNU-15] False when no deployment serves the name now: neither routed nor listed, its aliases kept. Administrators only."
                          },
                          "mode": {
                            "type": "string",
                            "enum": [
                              "always",
                              "on_demand",
                              "off"
                            ],
                            "description": "on_demand when one deployment is, off when all are, else always."
                          },
                          "strict": {
                            "type": "boolean",
                            "description": "[MNU-12] Never served by a compatible name."
                          },
                          "unlisted": {
                            "type": "boolean",
                            "description": "[PLN-146] Callable, left out of GET /v1/models."
                          },
                          "aliases": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "name": {
                                  "type": "string"
                                },
                                "unlisted": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "name",
                                "unlisted"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "compatible": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "[MNU-09] The names on the menu that serve it as well, in the fallback order."
                          },
                          "deployments": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                },
                                "gpu_config": {
                                  "type": "string"
                                },
                                "recipe_id": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "serving_mode": {
                                  "type": "string",
                                  "enum": [
                                    "always",
                                    "on_demand",
                                    "off"
                                  ]
                                },
                                "replacement_mode": {
                                  "type": "string",
                                  "enum": [
                                    "when_idle",
                                    "seamless",
                                    "night",
                                    "never"
                                  ]
                                },
                                "instances": {
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "container_id": {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991,
                                        "description": "The instance's id, never its Docker container's."
                                      },
                                      "ready_at": {
                                        "anyOf": [
                                          {
                                            "type": "string",
                                            "format": "date-time"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ],
                                        "description": "When it began answering; null while it starts."
                                      },
                                      "draining": {
                                        "type": "boolean"
                                      },
                                      "node_id": {
                                        "type": "string"
                                      },
                                      "hostname": {
                                        "type": "string"
                                      },
                                      "gpu_indices": {
                                        "type": "array",
                                        "items": {
                                          "type": "integer",
                                          "minimum": -9007199254740991,
                                          "maximum": 9007199254740991
                                        }
                                      }
                                    },
                                    "required": [
                                      "container_id",
                                      "ready_at",
                                      "draining"
                                    ],
                                    "additionalProperties": false,
                                    "description": "[API-95] Its node, hostname and cards are an administrator's."
                                  }
                                },
                                "pinned": {
                                  "anyOf": [
                                    {
                                      "type": "object",
                                      "properties": {
                                        "node_id": {
                                          "type": "string"
                                        },
                                        "gpu_indices": {
                                          "type": "array",
                                          "items": {
                                            "type": "integer",
                                            "minimum": -9007199254740991,
                                            "maximum": 9007199254740991
                                          }
                                        }
                                      },
                                      "required": [
                                        "node_id",
                                        "gpu_indices"
                                      ],
                                      "additionalProperties": false
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "gpu_config",
                                "recipe_id",
                                "serving_mode",
                                "replacement_mode",
                                "instances"
                              ],
                              "additionalProperties": false,
                              "description": "[API-95] Where it is pinned is an administrator's."
                            }
                          },
                          "holding": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "basis": {
                                    "type": "string",
                                    "enum": [
                                      "now",
                                      "when_running"
                                    ],
                                    "description": "now: the instances answering the name; when_running: nothing answers, the covering deployments once they run."
                                  },
                                  "gpuk": {
                                    "description": "[QTA-54] The GPUk of their cards; null when a card is not measured.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "vram_gb": {
                                    "description": "The VRAM their recipes hold, per card times cards; null when one has no figure.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "shared_with": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "[VIS-21] How many other names count the same instances or deployments."
                                  }
                                },
                                "required": [
                                  "basis",
                                  "gpuk",
                                  "vram_gb",
                                  "shared_with"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MNU-16] What the name holds; null when no deployment covers it."
                          }
                        },
                        "required": [
                          "name",
                          "plat_key",
                          "objective",
                          "phase",
                          "phase_reason",
                          "phase_since",
                          "covered",
                          "mode",
                          "strict",
                          "unlisted",
                          "aliases",
                          "compatible",
                          "deployments",
                          "holding"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "menu"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "MNU-13",
          "MNU-02"
        ]
      }
    },
    "/api/v1/menu/{name}": {
      "patch": {
        "operationId": "updateMenuEntry",
        "summary": "Set a name's strict and unlisted marks",
        "tags": [
          "menu"
        ],
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "description": "A public name, URL-encoded.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "strict": {
                    "type": "boolean"
                  },
                  "unlisted": {
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "entry": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "description": "[VIS-18] The public name."
                        },
                        "plat_key": {
                          "type": "string"
                        },
                        "objective": {
                          "description": "Null for a custom model setup.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "phase": {
                          "type": "string",
                          "enum": [
                            "serving",
                            "replacing",
                            "restarting",
                            "sleeping",
                            "waking",
                            "idling",
                            "stopping",
                            "off",
                            "failed",
                            "maintenance"
                          ],
                          "description": "[MNU-03] What the proxy does with a request for it."
                        },
                        "phase_reason": {
                          "description": "Why: a restart's wait, a failure's cause; null otherwise.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "phase_since": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "covered": {
                          "type": "boolean",
                          "description": "[MNU-15] False when no deployment serves the name now: neither routed nor listed, its aliases kept. Administrators only."
                        },
                        "mode": {
                          "type": "string",
                          "enum": [
                            "always",
                            "on_demand",
                            "off"
                          ],
                          "description": "on_demand when one deployment is, off when all are, else always."
                        },
                        "strict": {
                          "type": "boolean",
                          "description": "[MNU-12] Never served by a compatible name."
                        },
                        "unlisted": {
                          "type": "boolean",
                          "description": "[PLN-146] Callable, left out of GET /v1/models."
                        },
                        "aliases": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "name": {
                                "type": "string"
                              },
                              "unlisted": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "name",
                              "unlisted"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "compatible": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "[MNU-09] The names on the menu that serve it as well, in the fallback order."
                        },
                        "deployments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              "gpu_config": {
                                "type": "string"
                              },
                              "recipe_id": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "serving_mode": {
                                "type": "string",
                                "enum": [
                                  "always",
                                  "on_demand",
                                  "off"
                                ]
                              },
                              "replacement_mode": {
                                "type": "string",
                                "enum": [
                                  "when_idle",
                                  "seamless",
                                  "night",
                                  "never"
                                ]
                              },
                              "instances": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "container_id": {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991,
                                      "description": "The instance's id, never its Docker container's."
                                    },
                                    "ready_at": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "format": "date-time"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ],
                                      "description": "When it began answering; null while it starts."
                                    },
                                    "draining": {
                                      "type": "boolean"
                                    },
                                    "node_id": {
                                      "type": "string"
                                    },
                                    "hostname": {
                                      "type": "string"
                                    },
                                    "gpu_indices": {
                                      "type": "array",
                                      "items": {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      }
                                    }
                                  },
                                  "required": [
                                    "container_id",
                                    "ready_at",
                                    "draining"
                                  ],
                                  "additionalProperties": false,
                                  "description": "[API-95] Its node, hostname and cards are an administrator's."
                                }
                              },
                              "pinned": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "node_id": {
                                        "type": "string"
                                      },
                                      "gpu_indices": {
                                        "type": "array",
                                        "items": {
                                          "type": "integer",
                                          "minimum": -9007199254740991,
                                          "maximum": 9007199254740991
                                        }
                                      }
                                    },
                                    "required": [
                                      "node_id",
                                      "gpu_indices"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "gpu_config",
                              "recipe_id",
                              "serving_mode",
                              "replacement_mode",
                              "instances"
                            ],
                            "additionalProperties": false,
                            "description": "[API-95] Where it is pinned is an administrator's."
                          }
                        },
                        "holding": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "basis": {
                                  "type": "string",
                                  "enum": [
                                    "now",
                                    "when_running"
                                  ],
                                  "description": "now: the instances answering the name; when_running: nothing answers, the covering deployments once they run."
                                },
                                "gpuk": {
                                  "description": "[QTA-54] The GPUk of their cards; null when a card is not measured.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "vram_gb": {
                                  "description": "The VRAM their recipes hold, per card times cards; null when one has no figure.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "shared_with": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "[VIS-21] How many other names count the same instances or deployments."
                                }
                              },
                              "required": [
                                "basis",
                                "gpuk",
                                "vram_gb",
                                "shared_with"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MNU-16] What the name holds; null when no deployment covers it."
                        }
                      },
                      "required": [
                        "name",
                        "plat_key",
                        "objective",
                        "phase",
                        "phase_reason",
                        "phase_since",
                        "covered",
                        "mode",
                        "strict",
                        "unlisted",
                        "aliases",
                        "compatible",
                        "deployments",
                        "holding"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "entry"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "MNU-14",
          "MNU-12",
          "PLN-146"
        ]
      }
    },
    "/api/v1/menu/{name}/aliases": {
      "post": {
        "operationId": "createMenuAlias",
        "summary": "Give a name on the menu an alias",
        "tags": [
          "menu"
        ],
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "description": "A public name, URL-encoded.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "alias": {
                    "type": "string",
                    "minLength": 1
                  },
                  "unlisted": {
                    "type": "boolean"
                  }
                },
                "required": [
                  "alias"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "entry": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "description": "[VIS-18] The public name."
                        },
                        "plat_key": {
                          "type": "string"
                        },
                        "objective": {
                          "description": "Null for a custom model setup.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "phase": {
                          "type": "string",
                          "enum": [
                            "serving",
                            "replacing",
                            "restarting",
                            "sleeping",
                            "waking",
                            "idling",
                            "stopping",
                            "off",
                            "failed",
                            "maintenance"
                          ],
                          "description": "[MNU-03] What the proxy does with a request for it."
                        },
                        "phase_reason": {
                          "description": "Why: a restart's wait, a failure's cause; null otherwise.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "phase_since": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "covered": {
                          "type": "boolean",
                          "description": "[MNU-15] False when no deployment serves the name now: neither routed nor listed, its aliases kept. Administrators only."
                        },
                        "mode": {
                          "type": "string",
                          "enum": [
                            "always",
                            "on_demand",
                            "off"
                          ],
                          "description": "on_demand when one deployment is, off when all are, else always."
                        },
                        "strict": {
                          "type": "boolean",
                          "description": "[MNU-12] Never served by a compatible name."
                        },
                        "unlisted": {
                          "type": "boolean",
                          "description": "[PLN-146] Callable, left out of GET /v1/models."
                        },
                        "aliases": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "name": {
                                "type": "string"
                              },
                              "unlisted": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "name",
                              "unlisted"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "compatible": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "[MNU-09] The names on the menu that serve it as well, in the fallback order."
                        },
                        "deployments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              "gpu_config": {
                                "type": "string"
                              },
                              "recipe_id": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "serving_mode": {
                                "type": "string",
                                "enum": [
                                  "always",
                                  "on_demand",
                                  "off"
                                ]
                              },
                              "replacement_mode": {
                                "type": "string",
                                "enum": [
                                  "when_idle",
                                  "seamless",
                                  "night",
                                  "never"
                                ]
                              },
                              "instances": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "container_id": {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991,
                                      "description": "The instance's id, never its Docker container's."
                                    },
                                    "ready_at": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "format": "date-time"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ],
                                      "description": "When it began answering; null while it starts."
                                    },
                                    "draining": {
                                      "type": "boolean"
                                    },
                                    "node_id": {
                                      "type": "string"
                                    },
                                    "hostname": {
                                      "type": "string"
                                    },
                                    "gpu_indices": {
                                      "type": "array",
                                      "items": {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      }
                                    }
                                  },
                                  "required": [
                                    "container_id",
                                    "ready_at",
                                    "draining"
                                  ],
                                  "additionalProperties": false,
                                  "description": "[API-95] Its node, hostname and cards are an administrator's."
                                }
                              },
                              "pinned": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "node_id": {
                                        "type": "string"
                                      },
                                      "gpu_indices": {
                                        "type": "array",
                                        "items": {
                                          "type": "integer",
                                          "minimum": -9007199254740991,
                                          "maximum": 9007199254740991
                                        }
                                      }
                                    },
                                    "required": [
                                      "node_id",
                                      "gpu_indices"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "gpu_config",
                              "recipe_id",
                              "serving_mode",
                              "replacement_mode",
                              "instances"
                            ],
                            "additionalProperties": false,
                            "description": "[API-95] Where it is pinned is an administrator's."
                          }
                        },
                        "holding": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "basis": {
                                  "type": "string",
                                  "enum": [
                                    "now",
                                    "when_running"
                                  ],
                                  "description": "now: the instances answering the name; when_running: nothing answers, the covering deployments once they run."
                                },
                                "gpuk": {
                                  "description": "[QTA-54] The GPUk of their cards; null when a card is not measured.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "vram_gb": {
                                  "description": "The VRAM their recipes hold, per card times cards; null when one has no figure.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "shared_with": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "[VIS-21] How many other names count the same instances or deployments."
                                }
                              },
                              "required": [
                                "basis",
                                "gpuk",
                                "vram_gb",
                                "shared_with"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MNU-16] What the name holds; null when no deployment covers it."
                        }
                      },
                      "required": [
                        "name",
                        "plat_key",
                        "objective",
                        "phase",
                        "phase_reason",
                        "phase_since",
                        "covered",
                        "mode",
                        "strict",
                        "unlisted",
                        "aliases",
                        "compatible",
                        "deployments",
                        "holding"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "entry"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invalid_alias, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: alias_exists, name_taken.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "MNU-14",
          "PLN-04"
        ]
      }
    },
    "/api/v1/menu/{name}/aliases/{alias}": {
      "delete": {
        "operationId": "deleteMenuAlias",
        "summary": "Remove an alias of a name on the menu",
        "tags": [
          "menu"
        ],
        "parameters": [
          {
            "name": "alias",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64
            }
          },
          {
            "name": "name",
            "in": "path",
            "required": true,
            "description": "A public name, URL-encoded.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "MNU-14"
        ]
      }
    },
    "/api/v1/models": {
      "get": {
        "operationId": "listModels",
        "summary": "List the models",
        "description": "Oldest first; paginated with `limit` and `cursor`.",
        "tags": [
          "models"
        ],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "download_status",
            "in": "query",
            "required": false,
            "description": "Only the models in this state, e.g. delete_failed.",
            "schema": {
              "type": "string",
              "enum": [
                "pending",
                "downloading",
                "ready",
                "error",
                "evicted",
                "deleting",
                "delete_failed"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          },
          {
            "name": "task_type",
            "in": "query",
            "required": false,
            "description": "Only the models serving this task.",
            "schema": {
              "type": "string",
              "enum": [
                "text-generation",
                "embedding",
                "reranking",
                "classification",
                "asr",
                "tts",
                "speech-to-speech",
                "image-generation",
                "vision",
                "audio-generation",
                "video-generation",
                "custom"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "models": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "name": {
                            "type": "string"
                          },
                          "hf_repo": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model_version": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "source": {
                            "type": "string",
                            "description": "huggingface, modelscope, local…; later sources may be added."
                          },
                          "architecture": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "base_weights": {
                            "description": "The weights its quantizations share.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "quantization": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "quant_selection": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "group_key": {
                                    "type": "string"
                                  },
                                  "label": {
                                    "type": "string"
                                  },
                                  "files": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    }
                                  },
                                  "weight_bytes": {
                                    "type": "number"
                                  }
                                },
                                "required": [
                                  "group_key",
                                  "label",
                                  "files",
                                  "weight_bytes"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The GGUF quantization this row holds; null for a whole repository."
                          },
                          "diffusers_variant": {
                            "description": "The diffusers precision it downloaded.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "parameter_count": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d+$"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "An exact integer, as a decimal string; null when unknown."
                          },
                          "params_b": {
                            "description": "Billions of parameters.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "context_length": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "num_attention_heads": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "num_key_value_heads": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "max_position_embeddings": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "hidden_size": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "num_hidden_layers": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "torch_dtype": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "estimated_weight_bytes": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d+$"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "An exact integer, as a decimal string; null when unknown."
                          },
                          "exact_download_bytes": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d+$"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "An exact integer, as a decimal string; null when unknown."
                          },
                          "estimated_ram_bytes": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d+$"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "An exact integer, as a decimal string; null when unknown."
                          },
                          "estimated_vram_bytes": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d+$"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "An exact integer, as a decimal string; null when unknown."
                          },
                          "task_type": {
                            "description": "What it serves: a task type, other, or null when unknown; the override wins.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "task_type_detected": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "task_type_override": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "capabilities": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "What it does within its type; later capabilities may be added."
                          },
                          "capabilities_detected": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "capabilities_override": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "voices": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The voices an administrator listed for a speech model, the first being the default."
                          },
                          "voices_read": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The voices an engine of this model last listed; null when never read."
                          },
                          "download_status": {
                            "type": "string",
                            "description": "ready, downloading, error, evicted (its last copy was removed to keep a cache under its limit: not a failure, it can be downloaded again), delete_failed (a deletion that stopped)…; later states may be added."
                          },
                          "download_progress": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "download_error": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "download_error_fix": {
                            "description": "The fix-target key of download_error, when its failure named the place that cures it.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "local_path": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "is_private": {
                            "type": "boolean",
                            "description": "Its weights never leave the cluster."
                          },
                          "has_manifest": {
                            "type": "boolean"
                          },
                          "manifest_root": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "redownloadable": {
                            "type": "boolean",
                            "description": "Whether a set-up model provider can download it again; false: its last copy is never evicted."
                          },
                          "copy_source_available": {
                            "type": "boolean",
                            "description": "Whether a copy of its weights can be fetched somewhere (advisory)."
                          },
                          "worker_downloadable": {
                            "type": "boolean",
                            "description": "Whether a worker can download it itself."
                          },
                          "staged": {
                            "type": "boolean",
                            "description": "Whether its exact version is held on this cluster: only then can a new recipe be made on it."
                          },
                          "last_launched_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "When one of its recipes last started; null means never seen started."
                          },
                          "evicted_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "When the controller last approved removing one of its copies to free cache space."
                          },
                          "node_launches": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "node_id": {
                                  "type": "string"
                                },
                                "last_launched_at": {
                                  "type": "string",
                                  "format": "date-time"
                                }
                              },
                              "required": [
                                "node_id",
                                "last_launched_at"
                              ],
                              "additionalProperties": false
                            },
                            "description": "When one of its recipes last started on each node that ran it."
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "hf_repo",
                          "model_version",
                          "source",
                          "architecture",
                          "base_weights",
                          "quantization",
                          "quant_selection",
                          "diffusers_variant",
                          "parameter_count",
                          "params_b",
                          "context_length",
                          "num_attention_heads",
                          "num_key_value_heads",
                          "max_position_embeddings",
                          "hidden_size",
                          "num_hidden_layers",
                          "torch_dtype",
                          "estimated_weight_bytes",
                          "exact_download_bytes",
                          "estimated_ram_bytes",
                          "estimated_vram_bytes",
                          "task_type",
                          "task_type_detected",
                          "task_type_override",
                          "capabilities",
                          "capabilities_detected",
                          "capabilities_override",
                          "voices",
                          "voices_read",
                          "download_status",
                          "download_progress",
                          "download_error",
                          "download_error_fix",
                          "local_path",
                          "is_private",
                          "has_manifest",
                          "manifest_root",
                          "redownloadable",
                          "copy_source_available",
                          "worker_downloadable",
                          "staged",
                          "last_launched_at",
                          "evicted_at",
                          "node_launches",
                          "created_at"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "models",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-67"
        ]
      }
    },
    "/api/v1/models/{id}": {
      "get": {
        "operationId": "getModel",
        "summary": "Read one model",
        "tags": [
          "models"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "model": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "name": {
                          "type": "string"
                        },
                        "hf_repo": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_version": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "source": {
                          "type": "string",
                          "description": "huggingface, modelscope, local…; later sources may be added."
                        },
                        "architecture": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "base_weights": {
                          "description": "The weights its quantizations share.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quantization": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quant_selection": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "group_key": {
                                  "type": "string"
                                },
                                "label": {
                                  "type": "string"
                                },
                                "files": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  }
                                },
                                "weight_bytes": {
                                  "type": "number"
                                }
                              },
                              "required": [
                                "group_key",
                                "label",
                                "files",
                                "weight_bytes"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The GGUF quantization this row holds; null for a whole repository."
                        },
                        "diffusers_variant": {
                          "description": "The diffusers precision it downloaded.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "parameter_count": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d+$"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "An exact integer, as a decimal string; null when unknown."
                        },
                        "params_b": {
                          "description": "Billions of parameters.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "context_length": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "num_attention_heads": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "num_key_value_heads": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "max_position_embeddings": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "hidden_size": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "num_hidden_layers": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "torch_dtype": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "estimated_weight_bytes": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d+$"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "An exact integer, as a decimal string; null when unknown."
                        },
                        "exact_download_bytes": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d+$"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "An exact integer, as a decimal string; null when unknown."
                        },
                        "estimated_ram_bytes": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d+$"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "An exact integer, as a decimal string; null when unknown."
                        },
                        "estimated_vram_bytes": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d+$"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "An exact integer, as a decimal string; null when unknown."
                        },
                        "task_type": {
                          "description": "What it serves: a task type, other, or null when unknown; the override wins.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type_detected": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type_override": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "capabilities": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "What it does within its type; later capabilities may be added."
                        },
                        "capabilities_detected": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "capabilities_override": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "voices": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The voices an administrator listed for a speech model, the first being the default."
                        },
                        "voices_read": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The voices an engine of this model last listed; null when never read."
                        },
                        "download_status": {
                          "type": "string",
                          "description": "ready, downloading, error, evicted (its last copy was removed to keep a cache under its limit: not a failure, it can be downloaded again), delete_failed (a deletion that stopped)…; later states may be added."
                        },
                        "download_progress": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "download_error": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "download_error_fix": {
                          "description": "The fix-target key of download_error, when its failure named the place that cures it.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "local_path": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "is_private": {
                          "type": "boolean",
                          "description": "Its weights never leave the cluster."
                        },
                        "has_manifest": {
                          "type": "boolean"
                        },
                        "manifest_root": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "redownloadable": {
                          "type": "boolean",
                          "description": "Whether a set-up model provider can download it again; false: its last copy is never evicted."
                        },
                        "copy_source_available": {
                          "type": "boolean",
                          "description": "Whether a copy of its weights can be fetched somewhere (advisory)."
                        },
                        "worker_downloadable": {
                          "type": "boolean",
                          "description": "Whether a worker can download it itself."
                        },
                        "staged": {
                          "type": "boolean",
                          "description": "Whether its exact version is held on this cluster: only then can a new recipe be made on it."
                        },
                        "last_launched_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "When one of its recipes last started; null means never seen started."
                        },
                        "evicted_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "When the controller last approved removing one of its copies to free cache space."
                        },
                        "node_launches": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "node_id": {
                                "type": "string"
                              },
                              "last_launched_at": {
                                "type": "string",
                                "format": "date-time"
                              }
                            },
                            "required": [
                              "node_id",
                              "last_launched_at"
                            ],
                            "additionalProperties": false
                          },
                          "description": "When one of its recipes last started on each node that ran it."
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "hf_repo",
                        "model_version",
                        "source",
                        "architecture",
                        "base_weights",
                        "quantization",
                        "quant_selection",
                        "diffusers_variant",
                        "parameter_count",
                        "params_b",
                        "context_length",
                        "num_attention_heads",
                        "num_key_value_heads",
                        "max_position_embeddings",
                        "hidden_size",
                        "num_hidden_layers",
                        "torch_dtype",
                        "estimated_weight_bytes",
                        "exact_download_bytes",
                        "estimated_ram_bytes",
                        "estimated_vram_bytes",
                        "task_type",
                        "task_type_detected",
                        "task_type_override",
                        "capabilities",
                        "capabilities_detected",
                        "capabilities_override",
                        "voices",
                        "voices_read",
                        "download_status",
                        "download_progress",
                        "download_error",
                        "download_error_fix",
                        "local_path",
                        "is_private",
                        "has_manifest",
                        "manifest_root",
                        "redownloadable",
                        "copy_source_available",
                        "worker_downloadable",
                        "staged",
                        "last_launched_at",
                        "evicted_at",
                        "node_launches",
                        "created_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "model"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: model_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/node-connections": {
      "get": {
        "operationId": "listNodeConnections",
        "summary": "List the nodes' connected periods",
        "description": "Every node with a connection record in or before the window, with its connected periods over the last `hours` (24 by default, 720 at most).",
        "tags": [
          "nodes"
        ],
        "parameters": [
          {
            "name": "hours",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 720
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "window_hours": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "since": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "until": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "watching_since": {
                      "description": "When the controller now running started watching.",
                      "type": "string",
                      "format": "date-time"
                    },
                    "planned_restart_minutes": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991,
                      "description": "[GPU-210] How long a node may stay away after a restart its driver change asked for."
                    },
                    "nodes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "node_id": {
                            "type": "string"
                          },
                          "lost_links_24h": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "Lost links of the last 24 h, whatever the window ([GPU-169])."
                          },
                          "unstable": {
                            "type": "boolean",
                            "description": "It lost its link often enough in the last 24 h to be unstable ([GPU-169])."
                          },
                          "connected_share": {
                            "description": "Percent of the observed window it was connected, one decimal: the time before its first registration and the stretches nobody watched are left out. Null when nothing was observed.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "periods": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "from": {
                                  "description": "Start of the period, clipped to the window.",
                                  "type": "string",
                                  "format": "date-time"
                                },
                                "to": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "format": "date-time"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "End of the period; null while still connected."
                                },
                                "connected_cause": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "enum": [
                                        "first_registration",
                                        "stop_requested",
                                        "link_lost",
                                        "controller_stopped"
                                      ]
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "disconnected_cause": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "enum": [
                                        "first_registration",
                                        "stop_requested",
                                        "link_lost",
                                        "controller_stopped",
                                        "driver_change"
                                      ]
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "`controller_stopped`: the controller stopped watching; what followed is unknown. `driver_change`: a restart a driver change asked for ([GPU-210])."
                                },
                                "driver_target": {
                                  "description": "The driver a `driver_change` restart installs; null otherwise.",
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "clipped_start": {
                                  "type": "boolean",
                                  "description": "The period began before the window."
                                }
                              },
                              "required": [
                                "from",
                                "to",
                                "connected_cause",
                                "disconnected_cause",
                                "driver_target",
                                "clipped_start"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "node_id",
                          "lost_links_24h",
                          "unstable",
                          "connected_share",
                          "periods"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "window_hours",
                    "since",
                    "until",
                    "watching_since",
                    "planned_restart_minutes",
                    "nodes"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "GPU-168",
          "GPU-169",
          "GPU-170"
        ]
      }
    },
    "/api/v1/nodes": {
      "get": {
        "operationId": "listNodes",
        "summary": "List the fleet's nodes",
        "tags": [
          "nodes"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "nodes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "hostname": {
                            "type": "string"
                          },
                          "address": {
                            "description": "[GPU-238] The IP the worker connects from; null before it connects or on loopback.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "is_self": {
                            "type": "boolean"
                          },
                          "online": {
                            "type": "boolean",
                            "description": "[GPU-25] Whether the node is online: connected to this controller, or reported online with a heartbeat younger than 90 s. Every view reads this answer."
                          },
                          "status": {
                            "type": "string",
                            "description": "[GPU-25] The same answer as online, as online or offline."
                          },
                          "version": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "build_info": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "build_id": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "build_profile": {
                                    "type": "string",
                                    "enum": [
                                      "debug",
                                      "release"
                                    ]
                                  },
                                  "built_at": {
                                    "type": "string",
                                    "format": "date-time"
                                  },
                                  "commit": {
                                    "type": "string"
                                  },
                                  "dirty": {
                                    "type": "boolean"
                                  },
                                  "artifact_sha256": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "build_id",
                                  "build_profile",
                                  "built_at",
                                  "commit",
                                  "dirty",
                                  "artifact_sha256"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "labels": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string"
                            },
                            "additionalProperties": {
                              "type": "string"
                            }
                          },
                          "capabilities": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string"
                            },
                            "additionalProperties": {},
                            "description": "What the worker reported it can do, as it reported it."
                          },
                          "server_info": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The machine as the worker described it (CPU, memory, driver)."
                          },
                          "driver": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "version": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "branch": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "cuda_max": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "kernel_module": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "enum": [
                                          "open",
                                          "proprietary"
                                        ]
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "version",
                                  "branch",
                                  "cuda_max",
                                  "kernel_module"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[GPU-177] The loaded NVIDIA driver, as the worker last reported it; null without one."
                          },
                          "placement": {
                            "type": "string",
                            "enum": [
                              "in",
                              "out",
                              "freeing"
                            ],
                            "description": "[GPU-179] in: takes work; freeing: being freed; out: freed, takes no new work."
                          },
                          "placement_reason": {
                            "description": "Why the node stays out of placement.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "free": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "mode": {
                                    "type": "string",
                                    "enum": [
                                      "stop",
                                      "drain",
                                      "move"
                                    ]
                                  },
                                  "at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "[GPU-180] When a scheduled freeing starts."
                                  },
                                  "started_at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "overdue": {
                                    "type": "boolean",
                                    "description": "A drain past its timeout: nothing is killed."
                                  },
                                  "remaining": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "GPU containers still on the node."
                                  }
                                },
                                "required": [
                                  "mode",
                                  "at",
                                  "started_at",
                                  "overdue",
                                  "remaining"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "driver_change": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "state": {
                                    "type": "string",
                                    "enum": [
                                      "scheduled",
                                      "running"
                                    ]
                                  },
                                  "phase": {
                                    "type": "string",
                                    "description": "Where it is: scheduled, freeing, sending, preflight, installing, rebooting, verifying, rolling_back, unreachable; more may come."
                                  },
                                  "at": {
                                    "anyOf": [
                                      {
                                        "type": "string",
                                        "format": "date-time"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "When a scheduled change starts."
                                  }
                                },
                                "required": [
                                  "id",
                                  "state",
                                  "phase",
                                  "at"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[GPU-181] A driver change scheduled or under way on the node."
                          },
                          "is_external_rental": {
                            "type": "boolean"
                          },
                          "admission_method": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "version_refused": {
                            "type": "boolean"
                          },
                          "self_update_failure": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "signature",
                                  "unavailable",
                                  "download",
                                  "failed"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "gpu_error": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "release_error": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "worker_update": {
                            "anyOf": [
                              {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "available"
                                      },
                                      "reason": {
                                        "type": "null"
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "reason"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "current"
                                      },
                                      "reason": {
                                        "anyOf": [
                                          {
                                            "type": "string",
                                            "const": "worker_newer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "reason"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "unknown"
                                      },
                                      "reason": {
                                        "type": "string",
                                        "enum": [
                                          "no_offered_build",
                                          "offered_build_other_version"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "reason"
                                    ],
                                    "additionalProperties": false
                                  }
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[REG-201] Whether the worker build its controller offers is an update for this online worker: available; current (worker_newer: it runs a newer build, never moved back); unknown when the controller offers none or one of another version. Null when offline."
                          },
                          "worker_catch_up": {
                            "anyOf": [
                              {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "updating"
                                      }
                                    },
                                    "required": [
                                      "state"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "waiting"
                                      },
                                      "reason": {
                                        "type": "string",
                                        "enum": [
                                          "turn",
                                          "slot"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "reason"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "state": {
                                        "type": "string",
                                        "const": "failed"
                                      },
                                      "retry_at": {
                                        "type": "string",
                                        "format": "date-time"
                                      }
                                    },
                                    "required": [
                                      "state",
                                      "retry_at"
                                    ],
                                    "additionalProperties": false
                                  }
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[REG-463] The worker following its controller's build: updating, waiting for the node before it or for the update slot, or failed until its next try."
                          },
                          "last_heartbeat": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "hostname",
                          "address",
                          "is_self",
                          "online",
                          "status",
                          "version",
                          "build_info",
                          "labels",
                          "capabilities",
                          "server_info",
                          "driver",
                          "placement",
                          "placement_reason",
                          "free",
                          "driver_change",
                          "is_external_rental",
                          "admission_method",
                          "version_refused",
                          "self_update_failure",
                          "gpu_error",
                          "release_error",
                          "worker_update",
                          "worker_catch_up",
                          "last_heartbeat",
                          "created_at",
                          "updated_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "nodes"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-46"
        ]
      }
    },
    "/api/v1/nodes/{id}": {
      "get": {
        "operationId": "getNode",
        "summary": "Read one node",
        "tags": [
          "nodes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "node": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "hostname": {
                          "type": "string"
                        },
                        "address": {
                          "description": "[GPU-238] The IP the worker connects from; null before it connects or on loopback.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "is_self": {
                          "type": "boolean"
                        },
                        "online": {
                          "type": "boolean",
                          "description": "[GPU-25] Whether the node is online: connected to this controller, or reported online with a heartbeat younger than 90 s. Every view reads this answer."
                        },
                        "status": {
                          "type": "string",
                          "description": "[GPU-25] The same answer as online, as online or offline."
                        },
                        "version": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "build_info": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "build_id": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "build_profile": {
                                  "type": "string",
                                  "enum": [
                                    "debug",
                                    "release"
                                  ]
                                },
                                "built_at": {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                "commit": {
                                  "type": "string"
                                },
                                "dirty": {
                                  "type": "boolean"
                                },
                                "artifact_sha256": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "build_id",
                                "build_profile",
                                "built_at",
                                "commit",
                                "dirty",
                                "artifact_sha256"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "labels": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {
                            "type": "string"
                          }
                        },
                        "capabilities": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {},
                          "description": "What the worker reported it can do, as it reported it."
                        },
                        "server_info": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The machine as the worker described it (CPU, memory, driver)."
                        },
                        "driver": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "version": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "branch": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "cuda_max": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "kernel_module": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "enum": [
                                        "open",
                                        "proprietary"
                                      ]
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "version",
                                "branch",
                                "cuda_max",
                                "kernel_module"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[GPU-177] The loaded NVIDIA driver, as the worker last reported it; null without one."
                        },
                        "placement": {
                          "type": "string",
                          "enum": [
                            "in",
                            "out",
                            "freeing"
                          ],
                          "description": "[GPU-179] in: takes work; freeing: being freed; out: freed, takes no new work."
                        },
                        "placement_reason": {
                          "description": "Why the node stays out of placement.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "free": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "mode": {
                                  "type": "string",
                                  "enum": [
                                    "stop",
                                    "drain",
                                    "move"
                                  ]
                                },
                                "at": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "format": "date-time"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "[GPU-180] When a scheduled freeing starts."
                                },
                                "started_at": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "format": "date-time"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "overdue": {
                                  "type": "boolean",
                                  "description": "A drain past its timeout: nothing is killed."
                                },
                                "remaining": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "GPU containers still on the node."
                                }
                              },
                              "required": [
                                "mode",
                                "at",
                                "started_at",
                                "overdue",
                                "remaining"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "driver_change": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "state": {
                                  "type": "string",
                                  "enum": [
                                    "scheduled",
                                    "running"
                                  ]
                                },
                                "phase": {
                                  "type": "string",
                                  "description": "Where it is: scheduled, freeing, sending, preflight, installing, rebooting, verifying, rolling_back, unreachable; more may come."
                                },
                                "at": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "format": "date-time"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "When a scheduled change starts."
                                }
                              },
                              "required": [
                                "id",
                                "state",
                                "phase",
                                "at"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[GPU-181] A driver change scheduled or under way on the node."
                        },
                        "is_external_rental": {
                          "type": "boolean"
                        },
                        "admission_method": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "version_refused": {
                          "type": "boolean"
                        },
                        "self_update_failure": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "signature",
                                "unavailable",
                                "download",
                                "failed"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "gpu_error": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "release_error": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "worker_update": {
                          "anyOf": [
                            {
                              "oneOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "available"
                                    },
                                    "reason": {
                                      "type": "null"
                                    }
                                  },
                                  "required": [
                                    "state",
                                    "reason"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "current"
                                    },
                                    "reason": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "const": "worker_newer"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "required": [
                                    "state",
                                    "reason"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "unknown"
                                    },
                                    "reason": {
                                      "type": "string",
                                      "enum": [
                                        "no_offered_build",
                                        "offered_build_other_version"
                                      ]
                                    }
                                  },
                                  "required": [
                                    "state",
                                    "reason"
                                  ],
                                  "additionalProperties": false
                                }
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[REG-201] Whether the worker build its controller offers is an update for this online worker: available; current (worker_newer: it runs a newer build, never moved back); unknown when the controller offers none or one of another version. Null when offline."
                        },
                        "worker_catch_up": {
                          "anyOf": [
                            {
                              "oneOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "updating"
                                    }
                                  },
                                  "required": [
                                    "state"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "waiting"
                                    },
                                    "reason": {
                                      "type": "string",
                                      "enum": [
                                        "turn",
                                        "slot"
                                      ]
                                    }
                                  },
                                  "required": [
                                    "state",
                                    "reason"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "object",
                                  "properties": {
                                    "state": {
                                      "type": "string",
                                      "const": "failed"
                                    },
                                    "retry_at": {
                                      "type": "string",
                                      "format": "date-time"
                                    }
                                  },
                                  "required": [
                                    "state",
                                    "retry_at"
                                  ],
                                  "additionalProperties": false
                                }
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[REG-463] The worker following its controller's build: updating, waiting for the node before it or for the update slot, or failed until its next try."
                        },
                        "last_heartbeat": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "hostname",
                        "address",
                        "is_self",
                        "online",
                        "status",
                        "version",
                        "build_info",
                        "labels",
                        "capabilities",
                        "server_info",
                        "driver",
                        "placement",
                        "placement_reason",
                        "free",
                        "driver_change",
                        "is_external_rental",
                        "admission_method",
                        "version_refused",
                        "self_update_failure",
                        "gpu_error",
                        "release_error",
                        "worker_update",
                        "worker_catch_up",
                        "last_heartbeat",
                        "created_at",
                        "updated_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "node"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: node_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      }
    },
    "/api/v1/oidc/.well-known/openid-configuration": {
      "get": {
        "operationId": "getAppOidcConfiguration",
        "summary": "Read the OpenID Connect provider's discovery document",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "issuer": {
                      "type": "string"
                    },
                    "authorization_endpoint": {
                      "type": "string"
                    },
                    "token_endpoint": {
                      "type": "string"
                    },
                    "userinfo_endpoint": {
                      "type": "string"
                    },
                    "jwks_uri": {
                      "type": "string"
                    },
                    "response_types_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "code"
                      }
                    },
                    "response_modes_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "query"
                      }
                    },
                    "grant_types_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "authorization_code"
                      }
                    },
                    "subject_types_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "public"
                      }
                    },
                    "id_token_signing_alg_values_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "RS256"
                      }
                    },
                    "token_endpoint_auth_methods_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "client_secret_basic",
                          "client_secret_post"
                        ]
                      }
                    },
                    "code_challenge_methods_supported": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "const": "S256"
                      }
                    },
                    "scopes_supported": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "claims_supported": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "required": [
                    "issuer",
                    "authorization_endpoint",
                    "token_endpoint",
                    "userinfo_endpoint",
                    "jwks_uri",
                    "response_types_supported",
                    "response_modes_supported",
                    "grant_types_supported",
                    "subject_types_supported",
                    "id_token_signing_alg_values_supported",
                    "token_endpoint_auth_methods_supported",
                    "code_challenge_methods_supported",
                    "scopes_supported",
                    "claims_supported"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Error codes: oidc_provider_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-70",
          "EAU-71",
          "EAU-72"
        ]
      }
    },
    "/api/v1/oidc/authorize": {
      "get": {
        "operationId": "authorizeAppSignIn",
        "summary": "Authorize an application to sign a member in",
        "description": "The OAuth 2.0 authorization endpoint (code flow, PKCE S256). An unknown client or redirect URI is refused here; any other refusal goes back to the application as `error` and `error_description` query parameters.",
        "tags": [
          "authentication"
        ],
        "parameters": [
          {
            "name": "client_id",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "code_challenge",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "code_challenge_method",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "const": "S256"
            }
          },
          {
            "name": "nonce",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "prompt",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "redirect_uri",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "response_type",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "const": "code"
            }
          },
          {
            "name": "scope",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "state",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "To the application with a `code`, to the sign-in page without a session, or back with an error."
          },
          "400": {
            "description": "Error codes: oidc_redirect_uri_mismatch, oidc_unknown_client.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: oidc_provider_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "oauth",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-70",
          "EAU-71"
        ]
      }
    },
    "/api/v1/oidc/jwks": {
      "get": {
        "operationId": "getAppOidcKeys",
        "summary": "Read the OpenID Connect provider's signing keys",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "kty": {
                            "type": "string",
                            "const": "RSA"
                          },
                          "kid": {
                            "type": "string"
                          },
                          "use": {
                            "type": "string",
                            "const": "sig"
                          },
                          "alg": {
                            "type": "string",
                            "const": "RS256"
                          },
                          "n": {
                            "type": "string"
                          },
                          "e": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "kty",
                          "kid",
                          "use",
                          "alg",
                          "n",
                          "e"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Error codes: oidc_provider_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "read",
        "x-gpuk-protocol": "oidc",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-70",
          "EAU-72"
        ]
      }
    },
    "/api/v1/oidc/token": {
      "post": {
        "operationId": "exchangeAppSignInCode",
        "summary": "Exchange an authorization code for tokens",
        "description": "The OAuth 2.0 token endpoint, for the application's server. A refusal answers the OAuth 2.0 error object `{ error, error_description }`.",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "grant_type": {
                    "type": "string",
                    "const": "authorization_code"
                  },
                  "code": {
                    "type": "string"
                  },
                  "redirect_uri": {
                    "type": "string"
                  },
                  "code_verifier": {
                    "type": "string"
                  },
                  "client_id": {
                    "type": "string"
                  },
                  "client_secret": {
                    "type": "string"
                  }
                },
                "required": [
                  "grant_type",
                  "code",
                  "redirect_uri"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "access_token": {
                      "type": "string"
                    },
                    "token_type": {
                      "type": "string",
                      "const": "Bearer"
                    },
                    "expires_in": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "id_token": {
                      "type": "string"
                    },
                    "scope": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "access_token",
                    "token_type",
                    "expires_in",
                    "id_token",
                    "scope"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "oauth",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-70",
          "EAU-71"
        ]
      }
    },
    "/api/v1/oidc/userinfo": {
      "get": {
        "operationId": "readAppUserInfo",
        "summary": "Read the signed-in member's claims",
        "description": "The OpenID Connect userinfo endpoint, with the access token. A refusal answers the OAuth 2.0 error object `{ error, error_description }`.",
        "tags": [
          "authentication"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sub": {
                      "type": "string"
                    },
                    "email": {
                      "type": "string"
                    },
                    "email_verified": {
                      "type": "boolean"
                    },
                    "name": {
                      "type": "string"
                    },
                    "preferred_username": {
                      "type": "string"
                    },
                    "roles": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "admin",
                          "user"
                        ]
                      }
                    }
                  },
                  "required": [
                    "sub"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Error codes: oidc_provider_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "read",
        "x-gpuk-protocol": "oidc",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-71"
        ]
      },
      "post": {
        "operationId": "postAppUserInfo",
        "summary": "Read the signed-in member's claims with a form",
        "description": "The userinfo endpoint, the token in a form body. A refusal answers the OAuth 2.0 error object `{ error, error_description }`.",
        "tags": [
          "authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "access_token": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sub": {
                      "type": "string"
                    },
                    "email": {
                      "type": "string"
                    },
                    "email_verified": {
                      "type": "boolean"
                    },
                    "name": {
                      "type": "string"
                    },
                    "preferred_username": {
                      "type": "string"
                    },
                    "roles": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": [
                          "admin",
                          "user"
                        ]
                      }
                    }
                  },
                  "required": [
                    "sub"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Error codes: oidc_provider_unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [],
        "x-gpuk-access": "public",
        "x-gpuk-effect": "write",
        "x-gpuk-protocol": "oidc",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-71"
        ]
      }
    },
    "/api/v1/planning/dishes": {
      "get": {
        "operationId": "listPlanningDishes",
        "summary": "List the model setups available for reservation requests",
        "tags": [
          "planning"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "dishes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "plat_key": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "task_type": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "objectives": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "custom": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "plat_key",
                          "name",
                          "task_type",
                          "objectives",
                          "custom"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "dishes"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-56"
        ]
      }
    },
    "/api/v1/planning/teams/{teamId}/zones": {
      "get": {
        "operationId": "getPlanningTeamZones",
        "summary": "Read a team's zones and sub-zones",
        "tags": [
          "planning"
        ],
        "parameters": [
          {
            "name": "teamId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "timeZone": {
                      "type": "string"
                    },
                    "zones": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "editId": {
                            "type": "string",
                            "format": "uuid",
                            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
                          },
                          "lineageId": {
                            "type": "string"
                          },
                          "layer": {
                            "type": "string",
                            "enum": [
                              "template",
                              "team"
                            ]
                          },
                          "nodeId": {
                            "type": "string"
                          },
                          "gpuUids": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "usages": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "startMinute": {
                            "type": "number"
                          },
                          "durationMinutes": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "editId",
                          "lineageId",
                          "layer",
                          "nodeId",
                          "gpuUids",
                          "usages",
                          "startMinute",
                          "durationMinutes"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "subZones": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "editId": {
                            "type": "string",
                            "format": "uuid",
                            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
                          },
                          "lineageId": {
                            "type": "string"
                          },
                          "layer": {
                            "type": "string",
                            "enum": [
                              "template",
                              "team"
                            ]
                          },
                          "nodeId": {
                            "type": "string"
                          },
                          "gpuUids": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "usages": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "startMinute": {
                            "type": "number"
                          },
                          "durationMinutes": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "editId",
                          "lineageId",
                          "layer",
                          "nodeId",
                          "gpuUids",
                          "usages",
                          "startMinute",
                          "durationMinutes"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "canEdit": {
                      "type": "boolean"
                    },
                    "revision": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "timeZone",
                    "zones",
                    "subZones",
                    "canEdit",
                    "revision"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-25",
          "PLN-65",
          "API-48"
        ]
      },
      "put": {
        "operationId": "setPlanningTeamZones",
        "summary": "Replace a team's planning sub-zones",
        "tags": [
          "planning"
        ],
        "parameters": [
          {
            "name": "teamId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "expected_revision": {
                    "type": "string",
                    "minLength": 1
                  },
                  "zones": {
                    "maxItems": 500,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "edit_id": {
                          "type": "string",
                          "format": "uuid",
                          "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
                        },
                        "lineage_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "node_id": {
                          "type": "string",
                          "minLength": 1
                        },
                        "gpu_uids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "usages": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "start_minute": {
                          "type": "number"
                        },
                        "duration_minutes": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "edit_id",
                        "node_id",
                        "usages",
                        "start_minute",
                        "duration_minutes"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "expected_revision",
                  "zones"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "subZones": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "editId": {
                            "type": "string",
                            "format": "uuid",
                            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
                          },
                          "lineageId": {
                            "type": "string"
                          },
                          "layer": {
                            "type": "string",
                            "enum": [
                              "template",
                              "team"
                            ]
                          },
                          "nodeId": {
                            "type": "string"
                          },
                          "gpuUids": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "usages": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "startMinute": {
                            "type": "number"
                          },
                          "durationMinutes": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "editId",
                          "lineageId",
                          "layer",
                          "nodeId",
                          "gpuUids",
                          "usages",
                          "startMinute",
                          "durationMinutes"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "revision": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "subZones",
                    "revision"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-53",
          "PLN-65",
          "API-48"
        ]
      }
    },
    "/api/v1/production-reports": {
      "get": {
        "operationId": "listProductionReports",
        "summary": "List the production reports and who receives them",
        "description": "One report per elapsed week and month, newest first. Enterprise offer only.",
        "tags": [
          "production-reports"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reports": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "cadence": {
                            "type": "string",
                            "enum": [
                              "week",
                              "month"
                            ]
                          },
                          "period_start": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "period_end": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "produced_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "mailed_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "mail_error": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "partial": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "id",
                          "cadence",
                          "period_start",
                          "period_end",
                          "produced_at",
                          "mailed_at",
                          "mail_error",
                          "partial"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "recipients": {
                      "maxItems": 50,
                      "type": "array",
                      "items": {
                        "type": "string",
                        "maxLength": 320,
                        "format": "email",
                        "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                      }
                    },
                    "mail_configured": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "reports",
                    "recipients",
                    "mail_configured"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, enterprise_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "OBS-34",
          "OBS-35"
        ]
      }
    },
    "/api/v1/production-reports/{id}/pdf": {
      "get": {
        "operationId": "downloadProductionReport",
        "summary": "Download one production report as a PDF",
        "tags": [
          "production-reports"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The report.",
            "content": {
              "application/pdf": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, enterprise_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: report_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "OBS-34",
          "OBS-35"
        ]
      }
    },
    "/api/v1/production-reports/recipients": {
      "put": {
        "operationId": "setProductionReportRecipients",
        "summary": "Choose who receives the production reports by e-mail",
        "tags": [
          "production-reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "recipients": {
                    "maxItems": 50,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 320,
                      "format": "email",
                      "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                    }
                  }
                },
                "required": [
                  "recipients"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "recipients": {
                      "maxItems": 50,
                      "type": "array",
                      "items": {
                        "type": "string",
                        "maxLength": 320,
                        "format": "email",
                        "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                      }
                    }
                  },
                  "required": [
                    "recipients"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, enterprise_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "OBS-34",
          "OBS-35"
        ]
      }
    },
    "/api/v1/recipes": {
      "get": {
        "operationId": "listRecipes",
        "summary": "List the recipes",
        "description": "Sorted by `sort_by` (best throughput first) or newest first; paginated with `limit` and `cursor`. Recipes a template varies are left out unless `include_variations` is true.",
        "tags": [
          "recipes"
        ],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "include_variations",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          },
          {
            "name": "model_name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 256
            }
          },
          {
            "name": "runnable",
            "in": "query",
            "required": false,
            "description": "Only the recipes that would start now.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "sort_by",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "best_single_thread",
                "tokens_per_sec_multi",
                "max_context",
                "downloads"
              ]
            }
          },
          {
            "name": "task_type",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "text-generation",
                "embedding",
                "reranking",
                "classification",
                "asr",
                "tts",
                "speech-to-speech",
                "image-generation",
                "vision",
                "audio-generation",
                "video-generation",
                "custom"
              ]
            }
          },
          {
            "name": "tested_on_my_gpus",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "recipes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "recipe_fingerprint": {
                            "type": "string",
                            "description": "[VIS-01] The hash of its exact description: engine image, model files, arguments."
                          },
                          "plat_key": {
                            "description": "[VIS-16] [MOT-146] The model setup it produces; null until its first benchmark names it (an engine that sets its own context, none stated).",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "label": {
                            "type": "string",
                            "description": "[VIS-18] What a page calls it: its model setup, never a stored name; at most 40 characters."
                          },
                          "model_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "engine_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "params": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The engine parameters, by the engine's params_schema."
                          },
                          "notes": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "task_type": {
                            "type": "string",
                            "enum": [
                              "text-generation",
                              "embedding",
                              "reranking",
                              "classification",
                              "asr",
                              "tts",
                              "speech-to-speech",
                              "image-generation",
                              "vision",
                              "audio-generation",
                              "video-generation",
                              "custom"
                            ],
                            "description": "What the model does: text-generation, embeddings, image…"
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "fixed_args": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "max_parallel_requests": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "Requests the recipe is made to serve at once: its max_parallel_requests param, else 4."
                          },
                          "max_concurrent_requests": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author and frozen with the recipe; null for a catalog engine."
                          },
                          "declared_plat": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kv": {
                                    "type": "string"
                                  },
                                  "options": {
                                    "type": "string"
                                  },
                                  "context": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  }
                                },
                                "required": [
                                  "kv",
                                  "options",
                                  "context"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-119] The model setup an own image's author declares; null otherwise."
                          },
                          "forecast": {
                            "type": "object",
                            "properties": {
                              "gpu_count": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              "compute_capability": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "vram_per_gpu_gb": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              },
                              "vram_source": {
                                "type": "string",
                                "enum": [
                                  "estimate",
                                  "author",
                                  "budget"
                                ]
                              }
                            },
                            "required": [
                              "gpu_count",
                              "compute_capability",
                              "vram_per_gpu_gb",
                              "vram_source"
                            ],
                            "additionalProperties": false,
                            "description": "[VIS-02] Its GPU requirement, computed from its arguments, refined by its proofs."
                          },
                          "vram_measured_gb": {
                            "description": "[GPU-252] The highest peak its successful benchmarks measured on their fullest card (GB); null when none measured it.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_measured_attribution": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "attributed",
                                  "unattributed"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[OBJ-104] Whether the driver told that peak's engine memory apart; unattributed counts the card's whole use."
                          },
                          "vram_measured_pct": {
                            "description": "[GPU-252] That peak's share of its card's usable VRAM (%), of the same run; null when no card here forms its configuration.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_measured_card": {
                            "description": "[GPU-252] The card that share is of, by its short name (« B300 »).",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "kv_cache_measured_pct": {
                            "description": "[GPU-252] The highest fill of its KV cache those benchmarks saw (%); null when the engine does not publish it.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_measured_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[GPU-252] When the newest of those benchmarks ran."
                          },
                          "budget_usage": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "usage_pct": {
                                    "type": "number",
                                    "description": "How much of the VRAM it reserves (its budget, else its card's) the session used (%)."
                                  },
                                  "verdict": {
                                    "type": "string",
                                    "enum": [
                                      "ok",
                                      "notice",
                                      "no_proof"
                                    ],
                                    "description": "notice under 85 %, no_proof under 70 % (that session proved nothing)."
                                  },
                                  "target_gb": {
                                    "description": "Under 70 %: the highest proposed VRAM cap per GPU that would bring it to 70 % [GPU-290]; null otherwise, or when none does.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "places_needed": {
                                    "anyOf": [
                                      {
                                        "type": "integer",
                                        "minimum": -9007199254740991,
                                        "maximum": 9007199254740991
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ],
                                    "description": "Under 70 %: the fewest max parallel requests that would bring it to 70 %; null otherwise."
                                  },
                                  "benchmark_id": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "The session that made the verdict."
                                  }
                                },
                                "required": [
                                  "usage_pct",
                                  "verdict",
                                  "target_gb",
                                  "places_needed",
                                  "benchmark_id"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[OBJ-121] The budget verdict of the newest complete session of this bridable recipe; null when none made one."
                          },
                          "budget_overrun": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "peak_gb": {
                                    "description": "The highest attributed peak on a GPU (GB); null when no GPU memory was read.",
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  },
                                  "budget_gb": {
                                    "type": "number",
                                    "description": "The recipe's VRAM budget per GPU (GB)."
                                  },
                                  "benchmark_id": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "The session that held it."
                                  }
                                },
                                "required": [
                                  "peak_gb",
                                  "budget_gb",
                                  "benchmark_id"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-161] The newest session's engine held more than the budget on a GPU, or it read no GPU memory: that session proved nothing. Null otherwise."
                          },
                          "proofs": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "gpu_config": {
                                  "type": "string"
                                },
                                "driver_branch": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "origin": {
                                  "type": "string",
                                  "enum": [
                                    "local",
                                    "hub"
                                  ]
                                },
                                "correctness_check": {
                                  "description": "The check and contract version of the proving session; null for a hub proof.",
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "invalidated": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "gpu_config",
                                "driver_branch",
                                "origin",
                                "correctness_check",
                                "invalidated"
                              ],
                              "additionalProperties": false
                            },
                            "description": "[VIS-22] Where it is proven: configuration × driver branch, here or at the hub."
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "template_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "gguf_file": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "central_recipe_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The hub recipe it was imported from."
                          },
                          "share_code": {
                            "description": "That hub recipe's share code (GPU_KITCHEN_RECIPE_…, as the app shows it); null for a recipe the hub does not have.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "benchmarked": {
                            "type": "boolean",
                            "description": "[FRC-37] Proven on a configuration this farm forms, under a node's driver."
                          },
                          "proven_configs": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "[FRC-22] [GPU-260] The configurations this farm forms on which it serves: proven there, or on a similar configuration, under a node's driver, on cards that hold it."
                          },
                          "quality": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "score": {
                                    "type": "number",
                                    "description": "Mean pass rate, 0 to 1, of the task quality suites."
                                  },
                                  "suites": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "How many quality suites the score averages."
                                  },
                                  "evals": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991,
                                    "description": "[EVL-140] How many evaluations it rests on."
                                  },
                                  "source": {
                                    "type": "string",
                                    "enum": [
                                      "local",
                                      "hub"
                                    ],
                                    "description": "[REG-364] Run on this cluster, or shared by the community."
                                  }
                                },
                                "required": [
                                  "score",
                                  "suites",
                                  "evals",
                                  "source"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[REG-364] [EVL-140] The quality of its model setup: the suites run here, else the community's."
                          },
                          "best_single_thread": {
                            "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "best_multi_thread": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "performance": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "metrics": {
                                    "type": "object",
                                    "propertyNames": {
                                      "type": "string"
                                    },
                                    "additionalProperties": {
                                      "type": [
                                        "number",
                                        "null"
                                      ]
                                    }
                                  },
                                  "request_params": {
                                    "type": "object",
                                    "propertyNames": {
                                      "type": "string"
                                    },
                                    "additionalProperties": {}
                                  },
                                  "load_profile": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "suite": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "metrics",
                                  "request_params",
                                  "load_profile",
                                  "suite"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Task-specific measured performance from one comparable benchmark workload. A listing carries its figures; reading the recipe alone adds their power and energy evidence."
                          },
                          "model_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model_is_private": {
                            "type": "boolean"
                          },
                          "model_capabilities": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "What the model does within its type: keys of the capability vocabulary."
                          },
                          "model_size_bytes": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "quantization": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "engine_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "engine_version": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "docker_image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "own_image": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "image": {
                                    "type": "string",
                                    "description": "The pinned reference: repository@sha256:…"
                                  },
                                  "image_tag": {
                                    "type": "string",
                                    "description": "The reference as its author typed it."
                                  },
                                  "port": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  "health_path": {
                                    "type": "string"
                                  },
                                  "generation_route": {
                                    "type": "string",
                                    "enum": [
                                      "completions",
                                      "chat"
                                    ],
                                    "description": "[MOT-162] completions (POST /v1/completions) or chat (POST /v1/chat/completions)."
                                  },
                                  "env": {
                                    "type": "array",
                                    "items": {
                                      "anyOf": [
                                        {
                                          "type": "object",
                                          "properties": {
                                            "name": {
                                              "type": "string"
                                            },
                                            "value": {
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name",
                                            "value"
                                          ],
                                          "additionalProperties": false
                                        },
                                        {
                                          "type": "object",
                                          "properties": {
                                            "name": {
                                              "type": "string"
                                            },
                                            "secret": {
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name",
                                            "secret"
                                          ],
                                          "additionalProperties": false
                                        }
                                      ]
                                    }
                                  },
                                  "pull_anonymous": {
                                    "type": [
                                      "boolean",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "image",
                                  "image_tag",
                                  "port",
                                  "health_path",
                                  "generation_route",
                                  "env",
                                  "pull_anonymous"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-110] The image its author brought, else null (a catalog engine)."
                          },
                          "ram_requirement_gb": {
                            "description": "[VIS-29] The system RAM it needs, in GB: the most its valid proofs held on one configuration; null before a proof.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "gpu_available": {
                            "type": "boolean",
                            "description": "Whether it would start now (advisory)."
                          },
                          "gpu_match": {
                            "type": "string",
                            "enum": [
                              "ready",
                              "blocked",
                              "no_match"
                            ],
                            "description": "ready, blocked (try later) or no_match (no hardware here fits)."
                          },
                          "blocked_by": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "blocked_gpu": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "node_id": {
                                    "type": "string"
                                  },
                                  "gpu_index": {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  }
                                },
                                "required": [
                                  "node_id",
                                  "gpu_index"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "recipe_fingerprint",
                          "plat_key",
                          "label",
                          "model_id",
                          "engine_id",
                          "params",
                          "notes",
                          "task_type",
                          "description",
                          "fixed_args",
                          "max_parallel_requests",
                          "max_concurrent_requests",
                          "declared_plat",
                          "forecast",
                          "vram_measured_gb",
                          "vram_measured_attribution",
                          "vram_measured_pct",
                          "vram_measured_card",
                          "kv_cache_measured_pct",
                          "vram_measured_at",
                          "budget_usage",
                          "budget_overrun",
                          "proofs",
                          "created_at",
                          "updated_at",
                          "template_id",
                          "gguf_file",
                          "central_recipe_id",
                          "share_code",
                          "benchmarked",
                          "proven_configs",
                          "quality",
                          "best_single_thread",
                          "best_multi_thread",
                          "performance",
                          "model_name",
                          "model_is_private",
                          "model_capabilities",
                          "model_size_bytes",
                          "quantization",
                          "engine_name",
                          "engine_version",
                          "docker_image",
                          "own_image",
                          "ram_requirement_gb",
                          "gpu_available",
                          "gpu_match",
                          "blocked_by",
                          "blocked_gpu"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "recipes",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-67",
          "API-89"
        ]
      }
    },
    "/api/v1/recipes/{id}": {
      "delete": {
        "operationId": "deleteRecipe",
        "summary": "Delete a recipe",
        "tags": [
          "recipes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: recipe_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: benchmark_in_progress, recipe_in_use.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "API-65"
        ]
      },
      "get": {
        "operationId": "getRecipe",
        "summary": "Read one recipe",
        "tags": [
          "recipes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "recipe": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "recipe_fingerprint": {
                          "type": "string",
                          "description": "[VIS-01] The hash of its exact description: engine image, model files, arguments."
                        },
                        "plat_key": {
                          "description": "[VIS-16] [MOT-146] The model setup it produces; null until its first benchmark names it (an engine that sets its own context, none stated).",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "label": {
                          "type": "string",
                          "description": "[VIS-18] What a page calls it: its model setup, never a stored name; at most 40 characters."
                        },
                        "model_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "engine_id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "params": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The engine parameters, by the engine's params_schema."
                        },
                        "notes": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type": {
                          "type": "string",
                          "enum": [
                            "text-generation",
                            "embedding",
                            "reranking",
                            "classification",
                            "asr",
                            "tts",
                            "speech-to-speech",
                            "image-generation",
                            "vision",
                            "audio-generation",
                            "video-generation",
                            "custom"
                          ],
                          "description": "What the model does: text-generation, embeddings, image…"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "fixed_args": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "max_parallel_requests": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "Requests the recipe is made to serve at once: its max_parallel_requests param, else 4."
                        },
                        "max_concurrent_requests": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author and frozen with the recipe; null for a catalog engine."
                        },
                        "declared_plat": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kv": {
                                  "type": "string"
                                },
                                "options": {
                                  "type": "string"
                                },
                                "context": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                }
                              },
                              "required": [
                                "kv",
                                "options",
                                "context"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-119] The model setup an own image's author declares; null otherwise."
                        },
                        "forecast": {
                          "type": "object",
                          "properties": {
                            "gpu_count": {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            "compute_capability": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "vram_per_gpu_gb": {
                              "type": [
                                "number",
                                "null"
                              ]
                            },
                            "vram_source": {
                              "type": "string",
                              "enum": [
                                "estimate",
                                "author",
                                "budget"
                              ]
                            }
                          },
                          "required": [
                            "gpu_count",
                            "compute_capability",
                            "vram_per_gpu_gb",
                            "vram_source"
                          ],
                          "additionalProperties": false,
                          "description": "[VIS-02] Its GPU requirement, computed from its arguments, refined by its proofs."
                        },
                        "vram_measured_gb": {
                          "description": "[GPU-252] The highest peak its successful benchmarks measured on their fullest card (GB); null when none measured it.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_measured_attribution": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "attributed",
                                "unattributed"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[OBJ-104] Whether the driver told that peak's engine memory apart; unattributed counts the card's whole use."
                        },
                        "vram_measured_pct": {
                          "description": "[GPU-252] That peak's share of its card's usable VRAM (%), of the same run; null when no card here forms its configuration.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_measured_card": {
                          "description": "[GPU-252] The card that share is of, by its short name (« B300 »).",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "kv_cache_measured_pct": {
                          "description": "[GPU-252] The highest fill of its KV cache those benchmarks saw (%); null when the engine does not publish it.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_measured_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[GPU-252] When the newest of those benchmarks ran."
                        },
                        "budget_usage": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "usage_pct": {
                                  "type": "number",
                                  "description": "How much of the VRAM it reserves (its budget, else its card's) the session used (%)."
                                },
                                "verdict": {
                                  "type": "string",
                                  "enum": [
                                    "ok",
                                    "notice",
                                    "no_proof"
                                  ],
                                  "description": "notice under 85 %, no_proof under 70 % (that session proved nothing)."
                                },
                                "target_gb": {
                                  "description": "Under 70 %: the highest proposed VRAM cap per GPU that would bring it to 70 % [GPU-290]; null otherwise, or when none does.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "places_needed": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "Under 70 %: the fewest max parallel requests that would bring it to 70 %; null otherwise."
                                },
                                "benchmark_id": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "The session that made the verdict."
                                }
                              },
                              "required": [
                                "usage_pct",
                                "verdict",
                                "target_gb",
                                "places_needed",
                                "benchmark_id"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[OBJ-121] The budget verdict of the newest complete session of this bridable recipe; null when none made one."
                        },
                        "budget_overrun": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "peak_gb": {
                                  "description": "The highest attributed peak on a GPU (GB); null when no GPU memory was read.",
                                  "type": [
                                    "number",
                                    "null"
                                  ]
                                },
                                "budget_gb": {
                                  "type": "number",
                                  "description": "The recipe's VRAM budget per GPU (GB)."
                                },
                                "benchmark_id": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "The session that held it."
                                }
                              },
                              "required": [
                                "peak_gb",
                                "budget_gb",
                                "benchmark_id"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-161] The newest session's engine held more than the budget on a GPU, or it read no GPU memory: that session proved nothing. Null otherwise."
                        },
                        "proofs": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "gpu_config": {
                                "type": "string"
                              },
                              "driver_branch": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "origin": {
                                "type": "string",
                                "enum": [
                                  "local",
                                  "hub"
                                ]
                              },
                              "correctness_check": {
                                "description": "The check and contract version of the proving session; null for a hub proof.",
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "invalidated": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "gpu_config",
                              "driver_branch",
                              "origin",
                              "correctness_check",
                              "invalidated"
                            ],
                            "additionalProperties": false
                          },
                          "description": "[VIS-22] Where it is proven: configuration × driver branch, here or at the hub."
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "template_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "gguf_file": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "central_recipe_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The hub recipe it was imported from."
                        },
                        "share_code": {
                          "description": "That hub recipe's share code (GPU_KITCHEN_RECIPE_…, as the app shows it); null for a recipe the hub does not have.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "benchmarked": {
                          "type": "boolean",
                          "description": "[FRC-37] Proven on a configuration this farm forms, under a node's driver."
                        },
                        "proven_configs": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "[FRC-22] [GPU-260] The configurations this farm forms on which it serves: proven there, or on a similar configuration, under a node's driver, on cards that hold it."
                        },
                        "quality": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "score": {
                                  "type": "number",
                                  "description": "Mean pass rate, 0 to 1, of the task quality suites."
                                },
                                "suites": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "How many quality suites the score averages."
                                },
                                "evals": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991,
                                  "description": "[EVL-140] How many evaluations it rests on."
                                },
                                "source": {
                                  "type": "string",
                                  "enum": [
                                    "local",
                                    "hub"
                                  ],
                                  "description": "[REG-364] Run on this cluster, or shared by the community."
                                }
                              },
                              "required": [
                                "score",
                                "suites",
                                "evals",
                                "source"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[REG-364] [EVL-140] The quality of its model setup: the suites run here, else the community's."
                        },
                        "best_single_thread": {
                          "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "best_multi_thread": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "performance": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "metrics": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string"
                                  },
                                  "additionalProperties": {
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  }
                                },
                                "request_params": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string"
                                  },
                                  "additionalProperties": {}
                                },
                                "load_profile": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "suite": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "energy_coverage": {
                                  "type": "object",
                                  "properties": {
                                    "status": {
                                      "type": "string",
                                      "enum": [
                                        "complete",
                                        "partial",
                                        "unavailable"
                                      ]
                                    },
                                    "run_count": {
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 9007199254740991
                                    },
                                    "qualified_run_count": {
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 9007199254740991
                                    },
                                    "reasons": {
                                      "type": "array",
                                      "items": {
                                        "type": "string"
                                      }
                                    },
                                    "windows": {
                                      "type": "array",
                                      "items": {
                                        "type": "object",
                                        "properties": {
                                          "version": {
                                            "type": "number",
                                            "const": 1
                                          },
                                          "measured_at": {
                                            "type": [
                                              "string",
                                              "null"
                                            ]
                                          },
                                          "id": {
                                            "type": "string"
                                          },
                                          "context": {
                                            "type": "object",
                                            "properties": {
                                              "run_id": {
                                                "type": [
                                                  "string",
                                                  "null"
                                                ]
                                              },
                                              "recipe_id": {
                                                "type": [
                                                  "string",
                                                  "null"
                                                ]
                                              },
                                              "task_type": {
                                                "type": "string"
                                              },
                                              "load_profile": {
                                                "type": "string"
                                              },
                                              "request_params": {
                                                "type": "object",
                                                "propertyNames": {
                                                  "type": "string"
                                                },
                                                "additionalProperties": {}
                                              },
                                              "corpus_id": {
                                                "type": "string"
                                              },
                                              "gpu_ids": {
                                                "type": "array",
                                                "items": {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                }
                                              },
                                              "phase": {
                                                "type": "string"
                                              },
                                              "concurrency": {
                                                "type": "integer",
                                                "exclusiveMinimum": 0,
                                                "maximum": 9007199254740991
                                              },
                                              "attempt": {
                                                "type": "integer",
                                                "minimum": 0,
                                                "maximum": 9007199254740991
                                              }
                                            },
                                            "required": [
                                              "run_id",
                                              "recipe_id",
                                              "task_type",
                                              "load_profile",
                                              "request_params",
                                              "corpus_id",
                                              "gpu_ids",
                                              "phase",
                                              "concurrency",
                                              "attempt"
                                            ],
                                            "additionalProperties": false
                                          },
                                          "status": {
                                            "type": "string",
                                            "enum": [
                                              "complete",
                                              "partial",
                                              "unavailable"
                                            ]
                                          },
                                          "attribution": {
                                            "type": "string",
                                            "enum": [
                                              "exclusive",
                                              "uncertain"
                                            ]
                                          },
                                          "attribution_reasons": {
                                            "type": "array",
                                            "items": {
                                              "type": "string"
                                            }
                                          },
                                          "started_at_us": {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          "ended_at_us": {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          "duration_seconds": {
                                            "type": "number",
                                            "exclusiveMinimum": 0
                                          },
                                          "energy_j": {
                                            "anyOf": [
                                              {
                                                "type": "number",
                                                "minimum": 0
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "avg_power_w": {
                                            "anyOf": [
                                              {
                                                "type": "number",
                                                "minimum": 0
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "max_power_w": {
                                            "anyOf": [
                                              {
                                                "type": "number",
                                                "minimum": 0
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "work": {
                                            "type": "object",
                                            "properties": {
                                              "items_completed": {
                                                "anyOf": [
                                                  {
                                                    "type": "number",
                                                    "minimum": 0
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              },
                                              "output_tokens": {
                                                "anyOf": [
                                                  {
                                                    "type": "number",
                                                    "minimum": 0
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              },
                                              "audio_seconds": {
                                                "anyOf": [
                                                  {
                                                    "type": "number",
                                                    "minimum": 0
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "required": [
                                              "items_completed",
                                              "output_tokens",
                                              "audio_seconds"
                                            ],
                                            "additionalProperties": false
                                          },
                                          "gpus": {
                                            "type": "array",
                                            "items": {
                                              "type": "object",
                                              "properties": {
                                                "uuid": {
                                                  "type": [
                                                    "string",
                                                    "null"
                                                  ]
                                                },
                                                "power_limit_w": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "power_max_limit_w": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "power_default_limit_w": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "locked_sm_clock_mhz": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "clock_lock_state": {
                                                  "type": "string",
                                                  "enum": [
                                                    "locked",
                                                    "unlocked",
                                                    "unknown"
                                                  ]
                                                },
                                                "max_sm_clock_mhz": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "index": {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                "status": {
                                                  "type": "string",
                                                  "enum": [
                                                    "complete",
                                                    "partial",
                                                    "unavailable"
                                                  ]
                                                },
                                                "source": {
                                                  "type": "string"
                                                },
                                                "signal_kind": {
                                                  "type": "string",
                                                  "enum": [
                                                    "instantaneous",
                                                    "temporal_average",
                                                    "energy_counter",
                                                    "unavailable"
                                                  ]
                                                },
                                                "method": {
                                                  "anyOf": [
                                                    {
                                                      "type": "string",
                                                      "enum": [
                                                        "trapezoid",
                                                        "hardware_counter"
                                                      ]
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "valid_samples": {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                "missing_samples": {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                "gap_count": {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                "max_gap_seconds": {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                "covered_seconds": {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                "coverage_ratio": {
                                                  "type": "number",
                                                  "minimum": 0,
                                                  "maximum": 1
                                                },
                                                "first_sample_at_us": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "last_sample_at_us": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "energy_j": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "avg_power_w": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "max_power_w": {
                                                  "anyOf": [
                                                    {
                                                      "type": "number",
                                                      "minimum": 0
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "reasons": {
                                                  "type": "array",
                                                  "items": {
                                                    "type": "string"
                                                  }
                                                }
                                              },
                                              "required": [
                                                "uuid",
                                                "power_limit_w",
                                                "power_max_limit_w",
                                                "power_default_limit_w",
                                                "locked_sm_clock_mhz",
                                                "clock_lock_state",
                                                "max_sm_clock_mhz",
                                                "index",
                                                "status",
                                                "source",
                                                "signal_kind",
                                                "method",
                                                "valid_samples",
                                                "missing_samples",
                                                "gap_count",
                                                "max_gap_seconds",
                                                "covered_seconds",
                                                "coverage_ratio",
                                                "first_sample_at_us",
                                                "last_sample_at_us",
                                                "energy_j",
                                                "avg_power_w",
                                                "max_power_w",
                                                "reasons"
                                              ],
                                              "additionalProperties": false
                                            }
                                          }
                                        },
                                        "required": [
                                          "version",
                                          "measured_at",
                                          "id",
                                          "context",
                                          "status",
                                          "attribution",
                                          "attribution_reasons",
                                          "started_at_us",
                                          "ended_at_us",
                                          "duration_seconds",
                                          "energy_j",
                                          "avg_power_w",
                                          "max_power_w",
                                          "work",
                                          "gpus"
                                        ],
                                        "additionalProperties": false
                                      }
                                    }
                                  },
                                  "required": [
                                    "status",
                                    "run_count",
                                    "qualified_run_count",
                                    "reasons",
                                    "windows"
                                  ],
                                  "additionalProperties": false
                                },
                                "campaign_energy": {
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "started_at_us": {
                                        "type": "number",
                                        "minimum": 0
                                      },
                                      "ended_at_us": {
                                        "type": "number",
                                        "minimum": 0
                                      },
                                      "duration_seconds": {
                                        "type": "number",
                                        "minimum": 0
                                      },
                                      "status": {
                                        "type": "string",
                                        "enum": [
                                          "complete",
                                          "partial",
                                          "unavailable"
                                        ]
                                      },
                                      "energy_j": {
                                        "anyOf": [
                                          {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "observed_energy_j": {
                                        "anyOf": [
                                          {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "covered_seconds": {
                                        "type": "number",
                                        "minimum": 0
                                      },
                                      "avg_power_w": {
                                        "anyOf": [
                                          {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "max_power_w": {
                                        "anyOf": [
                                          {
                                            "type": "number",
                                            "minimum": 0
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "gpus": {
                                        "type": "array",
                                        "items": {
                                          "type": "object",
                                          "properties": {
                                            "uuid": {
                                              "type": [
                                                "string",
                                                "null"
                                              ]
                                            },
                                            "power_limit_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "power_max_limit_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "power_default_limit_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "locked_sm_clock_mhz": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "clock_lock_state": {
                                              "type": "string",
                                              "enum": [
                                                "locked",
                                                "unlocked",
                                                "unknown"
                                              ]
                                            },
                                            "max_sm_clock_mhz": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "index": {
                                              "type": "integer",
                                              "minimum": 0,
                                              "maximum": 9007199254740991
                                            },
                                            "status": {
                                              "type": "string",
                                              "enum": [
                                                "complete",
                                                "partial",
                                                "unavailable"
                                              ]
                                            },
                                            "source": {
                                              "type": "string"
                                            },
                                            "signal_kind": {
                                              "type": "string",
                                              "enum": [
                                                "instantaneous",
                                                "temporal_average",
                                                "energy_counter",
                                                "unavailable"
                                              ]
                                            },
                                            "method": {
                                              "anyOf": [
                                                {
                                                  "type": "string",
                                                  "enum": [
                                                    "trapezoid",
                                                    "hardware_counter"
                                                  ]
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "valid_samples": {
                                              "type": "integer",
                                              "minimum": 0,
                                              "maximum": 9007199254740991
                                            },
                                            "missing_samples": {
                                              "type": "integer",
                                              "minimum": 0,
                                              "maximum": 9007199254740991
                                            },
                                            "gap_count": {
                                              "type": "integer",
                                              "minimum": 0,
                                              "maximum": 9007199254740991
                                            },
                                            "max_gap_seconds": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "covered_seconds": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "coverage_ratio": {
                                              "type": "number",
                                              "minimum": 0,
                                              "maximum": 1
                                            },
                                            "first_sample_at_us": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "last_sample_at_us": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "energy_j": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "avg_power_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "max_power_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "reasons": {
                                              "type": "array",
                                              "items": {
                                                "type": "string"
                                              }
                                            }
                                          },
                                          "required": [
                                            "uuid",
                                            "power_limit_w",
                                            "power_max_limit_w",
                                            "power_default_limit_w",
                                            "locked_sm_clock_mhz",
                                            "clock_lock_state",
                                            "max_sm_clock_mhz",
                                            "index",
                                            "status",
                                            "source",
                                            "signal_kind",
                                            "method",
                                            "valid_samples",
                                            "missing_samples",
                                            "gap_count",
                                            "max_gap_seconds",
                                            "covered_seconds",
                                            "coverage_ratio",
                                            "first_sample_at_us",
                                            "last_sample_at_us",
                                            "energy_j",
                                            "avg_power_w",
                                            "max_power_w",
                                            "reasons"
                                          ],
                                          "additionalProperties": false
                                        }
                                      },
                                      "version": {
                                        "type": "number",
                                        "const": 1
                                      },
                                      "scope": {
                                        "type": "string",
                                        "const": "bench_process"
                                      },
                                      "measured_at": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "context": {
                                        "type": "object",
                                        "properties": {
                                          "run_id": {
                                            "type": [
                                              "string",
                                              "null"
                                            ]
                                          },
                                          "recipe_id": {
                                            "type": [
                                              "string",
                                              "null"
                                            ]
                                          },
                                          "task_type": {
                                            "type": "string"
                                          },
                                          "load_profile": {
                                            "type": "string"
                                          },
                                          "request_params": {
                                            "type": "object",
                                            "propertyNames": {
                                              "type": "string"
                                            },
                                            "additionalProperties": {}
                                          },
                                          "gpu_ids": {
                                            "type": "array",
                                            "items": {
                                              "type": "integer",
                                              "minimum": 0,
                                              "maximum": 9007199254740991
                                            }
                                          }
                                        },
                                        "required": [
                                          "run_id",
                                          "recipe_id",
                                          "task_type",
                                          "load_profile",
                                          "request_params",
                                          "gpu_ids"
                                        ],
                                        "additionalProperties": false
                                      },
                                      "completion": {
                                        "type": "string",
                                        "enum": [
                                          "finished",
                                          "truncated"
                                        ]
                                      },
                                      "attribution": {
                                        "type": "string",
                                        "enum": [
                                          "exclusive",
                                          "uncertain"
                                        ]
                                      },
                                      "attribution_reasons": {
                                        "type": "array",
                                        "items": {
                                          "type": "string"
                                        }
                                      },
                                      "omitted_phases": {
                                        "type": "integer",
                                        "minimum": 0,
                                        "maximum": 9007199254740991
                                      },
                                      "phases": {
                                        "maxItems": 256,
                                        "type": "array",
                                        "items": {
                                          "type": "object",
                                          "properties": {
                                            "started_at_us": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "ended_at_us": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "duration_seconds": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "status": {
                                              "type": "string",
                                              "enum": [
                                                "complete",
                                                "partial",
                                                "unavailable"
                                              ]
                                            },
                                            "energy_j": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "observed_energy_j": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "covered_seconds": {
                                              "type": "number",
                                              "minimum": 0
                                            },
                                            "avg_power_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "max_power_w": {
                                              "anyOf": [
                                                {
                                                  "type": "number",
                                                  "minimum": 0
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "gpus": {
                                              "type": "array",
                                              "items": {
                                                "type": "object",
                                                "properties": {
                                                  "uuid": {
                                                    "type": [
                                                      "string",
                                                      "null"
                                                    ]
                                                  },
                                                  "power_limit_w": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "power_max_limit_w": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "power_default_limit_w": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "locked_sm_clock_mhz": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "clock_lock_state": {
                                                    "type": "string",
                                                    "enum": [
                                                      "locked",
                                                      "unlocked",
                                                      "unknown"
                                                    ]
                                                  },
                                                  "max_sm_clock_mhz": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "index": {
                                                    "type": "integer",
                                                    "minimum": 0,
                                                    "maximum": 9007199254740991
                                                  },
                                                  "status": {
                                                    "type": "string",
                                                    "enum": [
                                                      "complete",
                                                      "partial",
                                                      "unavailable"
                                                    ]
                                                  },
                                                  "source": {
                                                    "type": "string"
                                                  },
                                                  "signal_kind": {
                                                    "type": "string",
                                                    "enum": [
                                                      "instantaneous",
                                                      "temporal_average",
                                                      "energy_counter",
                                                      "unavailable"
                                                    ]
                                                  },
                                                  "method": {
                                                    "anyOf": [
                                                      {
                                                        "type": "string",
                                                        "enum": [
                                                          "trapezoid",
                                                          "hardware_counter"
                                                        ]
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "valid_samples": {
                                                    "type": "integer",
                                                    "minimum": 0,
                                                    "maximum": 9007199254740991
                                                  },
                                                  "missing_samples": {
                                                    "type": "integer",
                                                    "minimum": 0,
                                                    "maximum": 9007199254740991
                                                  },
                                                  "gap_count": {
                                                    "type": "integer",
                                                    "minimum": 0,
                                                    "maximum": 9007199254740991
                                                  },
                                                  "max_gap_seconds": {
                                                    "type": "number",
                                                    "minimum": 0
                                                  },
                                                  "covered_seconds": {
                                                    "type": "number",
                                                    "minimum": 0
                                                  },
                                                  "coverage_ratio": {
                                                    "type": "number",
                                                    "minimum": 0,
                                                    "maximum": 1
                                                  },
                                                  "first_sample_at_us": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "last_sample_at_us": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "energy_j": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "avg_power_w": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "max_power_w": {
                                                    "anyOf": [
                                                      {
                                                        "type": "number",
                                                        "minimum": 0
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "reasons": {
                                                    "type": "array",
                                                    "items": {
                                                      "type": "string"
                                                    }
                                                  }
                                                },
                                                "required": [
                                                  "uuid",
                                                  "power_limit_w",
                                                  "power_max_limit_w",
                                                  "power_default_limit_w",
                                                  "locked_sm_clock_mhz",
                                                  "clock_lock_state",
                                                  "max_sm_clock_mhz",
                                                  "index",
                                                  "status",
                                                  "source",
                                                  "signal_kind",
                                                  "method",
                                                  "valid_samples",
                                                  "missing_samples",
                                                  "gap_count",
                                                  "max_gap_seconds",
                                                  "covered_seconds",
                                                  "coverage_ratio",
                                                  "first_sample_at_us",
                                                  "last_sample_at_us",
                                                  "energy_j",
                                                  "avg_power_w",
                                                  "max_power_w",
                                                  "reasons"
                                                ],
                                                "additionalProperties": false
                                              }
                                            },
                                            "phase": {
                                              "type": "string",
                                              "enum": [
                                                "warmup",
                                                "probe",
                                                "measurement",
                                                "overhead"
                                              ]
                                            },
                                            "measurement_phase": {
                                              "anyOf": [
                                                {
                                                  "type": "string",
                                                  "enum": [
                                                    "ladder",
                                                    "bisection",
                                                    "repeat"
                                                  ]
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "concurrency": {
                                              "anyOf": [
                                                {
                                                  "type": "integer",
                                                  "exclusiveMinimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "attempt": {
                                              "anyOf": [
                                                {
                                                  "type": "integer",
                                                  "minimum": 0,
                                                  "maximum": 9007199254740991
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "outcome": {
                                              "type": "string",
                                              "enum": [
                                                "succeeded",
                                                "failed",
                                                "unknown"
                                              ]
                                            }
                                          },
                                          "required": [
                                            "started_at_us",
                                            "ended_at_us",
                                            "duration_seconds",
                                            "status",
                                            "energy_j",
                                            "observed_energy_j",
                                            "covered_seconds",
                                            "avg_power_w",
                                            "max_power_w",
                                            "gpus",
                                            "phase",
                                            "measurement_phase",
                                            "concurrency",
                                            "attempt",
                                            "outcome"
                                          ],
                                          "additionalProperties": false
                                        }
                                      }
                                    },
                                    "required": [
                                      "started_at_us",
                                      "ended_at_us",
                                      "duration_seconds",
                                      "status",
                                      "energy_j",
                                      "observed_energy_j",
                                      "covered_seconds",
                                      "avg_power_w",
                                      "max_power_w",
                                      "gpus",
                                      "version",
                                      "scope",
                                      "measured_at",
                                      "context",
                                      "completion",
                                      "attribution",
                                      "attribution_reasons",
                                      "omitted_phases",
                                      "phases"
                                    ],
                                    "additionalProperties": false
                                  }
                                }
                              },
                              "required": [
                                "metrics",
                                "request_params",
                                "load_profile",
                                "suite",
                                "energy_coverage",
                                "campaign_energy"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "Task-specific measured performance from one comparable benchmark workload."
                        },
                        "model_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_is_private": {
                          "type": "boolean"
                        },
                        "model_capabilities": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "What the model does within its type: keys of the capability vocabulary."
                        },
                        "model_size_bytes": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "quantization": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "engine_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "engine_version": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "docker_image": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "own_image": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "image": {
                                  "type": "string",
                                  "description": "The pinned reference: repository@sha256:…"
                                },
                                "image_tag": {
                                  "type": "string",
                                  "description": "The reference as its author typed it."
                                },
                                "port": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                },
                                "health_path": {
                                  "type": "string"
                                },
                                "generation_route": {
                                  "type": "string",
                                  "enum": [
                                    "completions",
                                    "chat"
                                  ],
                                  "description": "[MOT-162] completions (POST /v1/completions) or chat (POST /v1/chat/completions)."
                                },
                                "env": {
                                  "type": "array",
                                  "items": {
                                    "anyOf": [
                                      {
                                        "type": "object",
                                        "properties": {
                                          "name": {
                                            "type": "string"
                                          },
                                          "value": {
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "value"
                                        ],
                                        "additionalProperties": false
                                      },
                                      {
                                        "type": "object",
                                        "properties": {
                                          "name": {
                                            "type": "string"
                                          },
                                          "secret": {
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "secret"
                                        ],
                                        "additionalProperties": false
                                      }
                                    ]
                                  }
                                },
                                "pull_anonymous": {
                                  "type": [
                                    "boolean",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "image",
                                "image_tag",
                                "port",
                                "health_path",
                                "generation_route",
                                "env",
                                "pull_anonymous"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-110] The image its author brought, else null (a catalog engine)."
                        },
                        "ram_requirement_gb": {
                          "description": "[VIS-29] The system RAM it needs, in GB: the most its valid proofs held on one configuration; null before a proof.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "gpu_available": {
                          "type": "boolean",
                          "description": "Whether it would start now (advisory)."
                        },
                        "gpu_match": {
                          "type": "string",
                          "enum": [
                            "ready",
                            "blocked",
                            "no_match"
                          ],
                          "description": "ready, blocked (try later) or no_match (no hardware here fits)."
                        },
                        "blocked_by": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "blocked_gpu": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "node_id": {
                                  "type": "string"
                                },
                                "gpu_index": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                }
                              },
                              "required": [
                                "node_id",
                                "gpu_index"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "plat": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "repo": {
                                  "type": "string"
                                },
                                "shape": {
                                  "type": "string",
                                  "enum": [
                                    "text",
                                    "input",
                                    "weights"
                                  ],
                                  "description": "[TMD-25] The parts its type carries: text generation all, embedding, reranking and classification the input length, any other the weights alone."
                                },
                                "weights": {
                                  "type": "string"
                                },
                                "kv": {
                                  "description": "[TMD-25] Null when its type carries no KV quant.",
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "options": {
                                  "type": "string",
                                  "description": "V vision, T tools, R reasoning, in that order."
                                },
                                "context": {
                                  "anyOf": [
                                    {
                                      "type": "integer",
                                      "minimum": -9007199254740991,
                                      "maximum": 9007199254740991
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "[TMD-25] Null when its type carries no context."
                                },
                                "envelope": {
                                  "anyOf": [
                                    {
                                      "type": "object",
                                      "properties": {
                                        "max_audio_seconds": {
                                          "type": "integer",
                                          "exclusiveMinimum": 0,
                                          "maximum": 9007199254740991
                                        },
                                        "max_text_chars": {
                                          "type": "integer",
                                          "exclusiveMinimum": 0,
                                          "maximum": 9007199254740991
                                        },
                                        "max_image_pixels": {
                                          "type": "integer",
                                          "exclusiveMinimum": 0,
                                          "maximum": 9007199254740991
                                        },
                                        "max_images_per_request": {
                                          "type": "integer",
                                          "exclusiveMinimum": 0,
                                          "maximum": 9007199254740991
                                        },
                                        "max_input_image_pixels": {
                                          "type": "integer",
                                          "exclusiveMinimum": 0,
                                          "maximum": 9007199254740991
                                        }
                                      },
                                      "additionalProperties": false
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ],
                                  "description": "[TMD-26] The maxima its inputs may grow to, each resolved: audio seconds for transcription, text characters for speech, generated image pixels and count, input image pixels with V. Null when its type carries none."
                                }
                              },
                              "required": [
                                "repo",
                                "shape",
                                "weights",
                                "kv",
                                "options",
                                "context",
                                "envelope"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-16] The model setup it produces, in parts; null for a custom recipe."
                        },
                        "measures": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "gpu_config": {
                                "type": "string"
                              },
                              "driver_branch": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": -9007199254740991,
                                    "maximum": 9007199254740991
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "suite": {
                                "type": "string"
                              },
                              "load_profile": {
                                "type": "string"
                              },
                              "objectives": {
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "enum": [
                                    "chat",
                                    "many-users",
                                    "long-documents",
                                    "batch",
                                    "efficiency"
                                  ]
                                },
                                "description": "[OBJ-19] The objectives of its task this load profile measures."
                              },
                              "power_level": {
                                "type": "string",
                                "enum": [
                                  "max",
                                  "low"
                                ]
                              },
                              "link": {
                                "type": "string",
                                "enum": [
                                  "nvlink",
                                  "pcie",
                                  "none"
                                ]
                              },
                              "origin": {
                                "type": "string",
                                "enum": [
                                  "local",
                                  "hub"
                                ]
                              },
                              "metrics": {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              "measured_at": {
                                "type": "string",
                                "format": "date-time"
                              }
                            },
                            "required": [
                              "gpu_config",
                              "driver_branch",
                              "suite",
                              "load_profile",
                              "objectives",
                              "power_level",
                              "link",
                              "origin",
                              "metrics",
                              "measured_at"
                            ],
                            "additionalProperties": false
                          },
                          "description": "[VIS-23] Its measures, per configuration, driver branch, power level and link."
                        },
                        "deployments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              "objective": {
                                "type": "string",
                                "enum": [
                                  "chat",
                                  "many-users",
                                  "long-documents",
                                  "batch",
                                  "efficiency"
                                ]
                              },
                              "gpu_config": {
                                "type": "string"
                              },
                              "recorded": {
                                "type": "boolean",
                                "description": "[VIS-32] It loads this recipe as its own recipe."
                              }
                            },
                            "required": [
                              "id",
                              "objective",
                              "gpu_config",
                              "recorded"
                            ],
                            "additionalProperties": false
                          },
                          "description": "[FRC-03] The deployments that load it now: as their own recipe, or ranking it best."
                        },
                        "ranks": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "gpu_config": {
                                "type": "string"
                              },
                              "objective": {
                                "type": "string",
                                "enum": [
                                  "chat",
                                  "many-users",
                                  "long-documents",
                                  "batch",
                                  "efficiency"
                                ]
                              },
                              "rank": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 9007199254740991,
                                "description": "1 for the best measured recipe of its model setup there."
                              },
                              "of": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 9007199254740991,
                                "description": "How many recipes of its model setup are measured there."
                              }
                            },
                            "required": [
                              "gpu_config",
                              "objective",
                              "rank",
                              "of"
                            ],
                            "additionalProperties": false
                          },
                          "description": "[BLD-368] Its rank per objective among its model setup's measured recipes, on each configuration where it is proven."
                        }
                      },
                      "required": [
                        "id",
                        "recipe_fingerprint",
                        "plat_key",
                        "label",
                        "model_id",
                        "engine_id",
                        "params",
                        "notes",
                        "task_type",
                        "description",
                        "fixed_args",
                        "max_parallel_requests",
                        "max_concurrent_requests",
                        "declared_plat",
                        "forecast",
                        "vram_measured_gb",
                        "vram_measured_attribution",
                        "vram_measured_pct",
                        "vram_measured_card",
                        "kv_cache_measured_pct",
                        "vram_measured_at",
                        "budget_usage",
                        "budget_overrun",
                        "proofs",
                        "created_at",
                        "updated_at",
                        "template_id",
                        "gguf_file",
                        "central_recipe_id",
                        "share_code",
                        "benchmarked",
                        "proven_configs",
                        "quality",
                        "best_single_thread",
                        "best_multi_thread",
                        "performance",
                        "model_name",
                        "model_is_private",
                        "model_capabilities",
                        "model_size_bytes",
                        "quantization",
                        "engine_name",
                        "engine_version",
                        "docker_image",
                        "own_image",
                        "ram_requirement_gb",
                        "gpu_available",
                        "gpu_match",
                        "blocked_by",
                        "blocked_gpu",
                        "plat",
                        "measures",
                        "deployments",
                        "ranks"
                      ],
                      "additionalProperties": false
                    },
                    "engine_params_schema": {
                      "anyOf": [
                        {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {}
                        },
                        {
                          "type": "null"
                        }
                      ],
                      "description": "The parameters its engine accepts, as JSON Schema."
                    }
                  },
                  "required": [
                    "recipe",
                    "engine_params_schema"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: recipe_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-89"
        ]
      }
    },
    "/api/v1/reservations": {
      "get": {
        "operationId": "listReservations",
        "summary": "List your own and your teams' reservations",
        "tags": [
          "reservations"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reservations": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "model",
                              "raw_gpu"
                            ]
                          },
                          "nodeId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpuUids": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "windowStart": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "windowEnd": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "title": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "note": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "ownerMemberId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "teamId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "statusReason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "platKey": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "objective": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpuConfig": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "constraints": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "concurrentUsers": {
                                    "type": "number"
                                  },
                                  "tokensPerUser": {
                                    "type": "number"
                                  }
                                },
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "planningAllocationId": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "ridingLineageId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "command": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "containerRunning": {
                            "type": "boolean"
                          },
                          "execution": {
                            "type": "object",
                            "properties": {
                              "state": {
                                "type": "string",
                                "enum": [
                                  "waiting",
                                  "preparing",
                                  "serving",
                                  "started",
                                  "unavailable",
                                  "finished"
                                ]
                              },
                              "reason": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "state",
                              "reason"
                            ],
                            "additionalProperties": false
                          },
                          "conflict": {
                            "type": "boolean"
                          },
                          "conflictReason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "seriesId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "extendsReservationId": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "createdBy": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "createdAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updatedAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "endedAt": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "kind",
                          "nodeId",
                          "gpuUids",
                          "windowStart",
                          "windowEnd",
                          "title",
                          "note",
                          "ownerMemberId",
                          "teamId",
                          "status",
                          "statusReason",
                          "platKey",
                          "objective",
                          "gpuConfig",
                          "constraints",
                          "planningAllocationId",
                          "ridingLineageId",
                          "image",
                          "command",
                          "containerRunning",
                          "execution",
                          "conflict",
                          "conflictReason",
                          "seriesId",
                          "extendsReservationId",
                          "createdBy",
                          "createdAt",
                          "updatedAt",
                          "endedAt"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "timeZone": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "reservations",
                    "timeZone"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-26",
          "API-48"
        ]
      },
      "post": {
        "operationId": "createReservation",
        "summary": "Request a model or raw GPUs for a time window",
        "tags": [
          "reservations"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "kind": {
                    "type": "string",
                    "enum": [
                      "model",
                      "raw_gpu"
                    ]
                  },
                  "window_start": {
                    "type": "string",
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                  },
                  "window_end": {
                    "type": "string",
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                  },
                  "team_id": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "title": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "note": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "plat_key": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "objective": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "chat",
                          "many-users",
                          "long-documents",
                          "batch",
                          "efficiency"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "constraints": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "concurrent_users": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "tokens_per_user": {
                            "type": [
                              "number",
                              "null"
                            ]
                          }
                        },
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "gpu_count": {
                    "type": [
                      "number",
                      "null"
                    ]
                  },
                  "gpu_model": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "min_vram_gb": {
                    "type": [
                      "number",
                      "null"
                    ]
                  },
                  "image": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "command": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "env": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string",
                      "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                    },
                    "additionalProperties": {
                      "type": "string"
                    }
                  },
                  "recurrence": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "weekdays": {
                            "minItems": 1,
                            "type": "array",
                            "items": {
                              "type": "integer",
                              "minimum": 0,
                              "maximum": 6
                            }
                          },
                          "until": {
                            "type": "string",
                            "format": "date-time",
                            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                          }
                        },
                        "required": [
                          "weekdays",
                          "until"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "kind",
                  "window_start",
                  "window_end"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reservations": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "model",
                              "raw_gpu"
                            ]
                          },
                          "nodeId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpuUids": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "windowStart": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "windowEnd": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "title": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "note": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "ownerMemberId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "teamId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "statusReason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "platKey": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "objective": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpuConfig": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "constraints": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "concurrentUsers": {
                                    "type": "number"
                                  },
                                  "tokensPerUser": {
                                    "type": "number"
                                  }
                                },
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "planningAllocationId": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "ridingLineageId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "command": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "containerRunning": {
                            "type": "boolean"
                          },
                          "execution": {
                            "type": "object",
                            "properties": {
                              "state": {
                                "type": "string",
                                "enum": [
                                  "waiting",
                                  "preparing",
                                  "serving",
                                  "started",
                                  "unavailable",
                                  "finished"
                                ]
                              },
                              "reason": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "state",
                              "reason"
                            ],
                            "additionalProperties": false
                          },
                          "conflict": {
                            "type": "boolean"
                          },
                          "conflictReason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "seriesId": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "extendsReservationId": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "createdBy": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "createdAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updatedAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "endedAt": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "kind",
                          "nodeId",
                          "gpuUids",
                          "windowStart",
                          "windowEnd",
                          "title",
                          "note",
                          "ownerMemberId",
                          "teamId",
                          "status",
                          "statusReason",
                          "platKey",
                          "objective",
                          "gpuConfig",
                          "constraints",
                          "planningAllocationId",
                          "ridingLineageId",
                          "image",
                          "command",
                          "containerRunning",
                          "execution",
                          "conflict",
                          "conflictReason",
                          "seriesId",
                          "extendsReservationId",
                          "createdBy",
                          "createdAt",
                          "updatedAt",
                          "endedAt"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "pendingReasons": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "stops": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "budget": {
                      "type": "object",
                      "properties": {
                        "scope": {
                          "type": "string",
                          "enum": [
                            "team",
                            "personal"
                          ]
                        },
                        "monthly": {
                          "type": "number"
                        },
                        "used": {
                          "type": "number"
                        },
                        "requested": {
                          "type": "number"
                        },
                        "remaining": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "scope",
                        "monthly",
                        "used",
                        "requested",
                        "remaining"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "reservations",
                    "pendingReasons",
                    "stops"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, management_key_read_only, not_a_member_of_team, team_membership_blocked.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-26",
          "PLN-27",
          "PLN-56",
          "PLN-62",
          "PLN-137",
          "API-67"
        ]
      }
    },
    "/api/v1/reservations/{id}": {
      "delete": {
        "operationId": "cancelReservation",
        "summary": "Cancel your reservation or preempt another member's reservation",
        "tags": [
          "reservations"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-28",
          "API-48",
          "API-67"
        ]
      },
      "get": {
        "operationId": "getReservation",
        "summary": "Read a reservation you can see",
        "tags": [
          "reservations"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reservation": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "model",
                            "raw_gpu"
                          ]
                        },
                        "nodeId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuUids": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "windowStart": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "windowEnd": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "title": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "ownerMemberId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "teamId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string"
                        },
                        "statusReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "platKey": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "objective": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuConfig": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "constraints": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "concurrentUsers": {
                                  "type": "number"
                                },
                                "tokensPerUser": {
                                  "type": "number"
                                }
                              },
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "planningAllocationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ridingLineageId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "image": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "command": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "containerRunning": {
                          "type": "boolean"
                        },
                        "execution": {
                          "type": "object",
                          "properties": {
                            "state": {
                              "type": "string",
                              "enum": [
                                "waiting",
                                "preparing",
                                "serving",
                                "started",
                                "unavailable",
                                "finished"
                              ]
                            },
                            "reason": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          },
                          "required": [
                            "state",
                            "reason"
                          ],
                          "additionalProperties": false
                        },
                        "conflict": {
                          "type": "boolean"
                        },
                        "conflictReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "seriesId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "extendsReservationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "createdBy": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "endedAt": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "kind",
                        "nodeId",
                        "gpuUids",
                        "windowStart",
                        "windowEnd",
                        "title",
                        "note",
                        "ownerMemberId",
                        "teamId",
                        "status",
                        "statusReason",
                        "platKey",
                        "objective",
                        "gpuConfig",
                        "constraints",
                        "planningAllocationId",
                        "ridingLineageId",
                        "image",
                        "command",
                        "containerRunning",
                        "execution",
                        "conflict",
                        "conflictReason",
                        "seriesId",
                        "extendsReservationId",
                        "createdBy",
                        "createdAt",
                        "updatedAt",
                        "endedAt"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "reservation"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-26",
          "API-48"
        ]
      }
    },
    "/api/v1/reservations/{id}/extend": {
      "post": {
        "operationId": "extendReservation",
        "summary": "Extend a reservation's time window",
        "tags": [
          "reservations"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "window_end": {
                    "type": "string",
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                  }
                },
                "required": [
                  "window_end"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reservation": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "model",
                            "raw_gpu"
                          ]
                        },
                        "nodeId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuUids": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "windowStart": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "windowEnd": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "title": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "ownerMemberId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "teamId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string"
                        },
                        "statusReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "platKey": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "objective": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuConfig": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "constraints": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "concurrentUsers": {
                                  "type": "number"
                                },
                                "tokensPerUser": {
                                  "type": "number"
                                }
                              },
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "planningAllocationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ridingLineageId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "image": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "command": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "containerRunning": {
                          "type": "boolean"
                        },
                        "execution": {
                          "type": "object",
                          "properties": {
                            "state": {
                              "type": "string",
                              "enum": [
                                "waiting",
                                "preparing",
                                "serving",
                                "started",
                                "unavailable",
                                "finished"
                              ]
                            },
                            "reason": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          },
                          "required": [
                            "state",
                            "reason"
                          ],
                          "additionalProperties": false
                        },
                        "conflict": {
                          "type": "boolean"
                        },
                        "conflictReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "seriesId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "extendsReservationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "createdBy": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "endedAt": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "kind",
                        "nodeId",
                        "gpuUids",
                        "windowStart",
                        "windowEnd",
                        "title",
                        "note",
                        "ownerMemberId",
                        "teamId",
                        "status",
                        "statusReason",
                        "platKey",
                        "objective",
                        "gpuConfig",
                        "constraints",
                        "planningAllocationId",
                        "ridingLineageId",
                        "image",
                        "command",
                        "containerRunning",
                        "execution",
                        "conflict",
                        "conflictReason",
                        "seriesId",
                        "extendsReservationId",
                        "createdBy",
                        "createdAt",
                        "updatedAt",
                        "endedAt"
                      ],
                      "additionalProperties": false
                    },
                    "pendingReasons": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "budget": {
                      "type": "object",
                      "properties": {
                        "scope": {
                          "type": "string",
                          "enum": [
                            "team",
                            "personal"
                          ]
                        },
                        "monthly": {
                          "type": "number"
                        },
                        "used": {
                          "type": "number"
                        },
                        "requested": {
                          "type": "number"
                        },
                        "remaining": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "scope",
                        "monthly",
                        "used",
                        "requested",
                        "remaining"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "reservation",
                    "pendingReasons"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_membership_blocked.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-27",
          "PLN-71",
          "API-48"
        ]
      }
    },
    "/api/v1/reservations/{id}/release": {
      "post": {
        "operationId": "releaseReservation",
        "summary": "Give back a reservation before it ends",
        "tags": [
          "reservations"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "reservation": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "model",
                            "raw_gpu"
                          ]
                        },
                        "nodeId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuUids": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "windowStart": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "windowEnd": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "title": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "note": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "ownerMemberId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "teamId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string"
                        },
                        "statusReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "platKey": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "objective": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpuConfig": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "constraints": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "concurrentUsers": {
                                  "type": "number"
                                },
                                "tokensPerUser": {
                                  "type": "number"
                                }
                              },
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "planningAllocationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "ridingLineageId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "image": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "command": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "containerRunning": {
                          "type": "boolean"
                        },
                        "execution": {
                          "type": "object",
                          "properties": {
                            "state": {
                              "type": "string",
                              "enum": [
                                "waiting",
                                "preparing",
                                "serving",
                                "started",
                                "unavailable",
                                "finished"
                              ]
                            },
                            "reason": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          },
                          "required": [
                            "state",
                            "reason"
                          ],
                          "additionalProperties": false
                        },
                        "conflict": {
                          "type": "boolean"
                        },
                        "conflictReason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "seriesId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "extendsReservationId": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "createdBy": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "endedAt": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "kind",
                        "nodeId",
                        "gpuUids",
                        "windowStart",
                        "windowEnd",
                        "title",
                        "note",
                        "ownerMemberId",
                        "teamId",
                        "status",
                        "statusReason",
                        "platKey",
                        "objective",
                        "gpuConfig",
                        "constraints",
                        "planningAllocationId",
                        "ridingLineageId",
                        "image",
                        "command",
                        "containerRunning",
                        "execution",
                        "conflict",
                        "conflictReason",
                        "seriesId",
                        "extendsReservationId",
                        "createdBy",
                        "createdAt",
                        "updatedAt",
                        "endedAt"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "reservation"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: conflict.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-flag": "planning.reservations",
        "x-gpuk-requirements": [
          "PLN-71",
          "API-48"
        ]
      }
    },
    "/api/v1/team-requests": {
      "get": {
        "operationId": "listTeamRequests",
        "summary": "List the requests of every team's leads",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "open",
                "accepted",
                "refused",
                "cancelled",
                "lapsed"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "requests": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "team_id": {
                            "type": "string"
                          },
                          "team_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "external_budget",
                              "gpu_hours",
                              "privilege",
                              "add_member",
                              "remove_member",
                              "enable_access_grid"
                            ]
                          },
                          "target": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "current_value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "message": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "open",
                              "accepted",
                              "refused",
                              "cancelled",
                              "lapsed"
                            ]
                          },
                          "requested_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "decided_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "decided_value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "reason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "decided_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "team_id",
                          "team_name",
                          "kind",
                          "target",
                          "value",
                          "current_value",
                          "message",
                          "status",
                          "requested_by",
                          "decided_by",
                          "decided_value",
                          "reason",
                          "created_at",
                          "decided_at"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "open_count": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "requests",
                    "open_count"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61",
          "QTA-62"
        ]
      }
    },
    "/api/v1/team-requests/{id}/accept": {
      "post": {
        "operationId": "acceptTeamRequest",
        "summary": "Accept a request and apply it, with the asked value or another",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "value": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "request": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "team_id": {
                          "type": "string"
                        },
                        "team_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "external_budget",
                            "gpu_hours",
                            "privilege",
                            "add_member",
                            "remove_member",
                            "enable_access_grid"
                          ]
                        },
                        "target": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "current_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "open",
                            "accepted",
                            "refused",
                            "cancelled",
                            "lapsed"
                          ]
                        },
                        "requested_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "decided_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "team_id",
                        "team_name",
                        "kind",
                        "target",
                        "value",
                        "current_value",
                        "message",
                        "status",
                        "requested_by",
                        "decided_by",
                        "decided_value",
                        "reason",
                        "created_at",
                        "decided_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "request"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invalid_request_value, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, enterprise_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: request_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: request_not_open.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61",
          "QTA-43",
          "EDI-32"
        ]
      }
    },
    "/api/v1/team-requests/{id}/refuse": {
      "post": {
        "operationId": "refuseTeamRequest",
        "summary": "Refuse a request, with an optional reason",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 2000
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "request": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "team_id": {
                          "type": "string"
                        },
                        "team_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "external_budget",
                            "gpu_hours",
                            "privilege",
                            "add_member",
                            "remove_member",
                            "enable_access_grid"
                          ]
                        },
                        "target": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "current_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "open",
                            "accepted",
                            "refused",
                            "cancelled",
                            "lapsed"
                          ]
                        },
                        "requested_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "decided_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "team_id",
                        "team_name",
                        "kind",
                        "target",
                        "value",
                        "current_value",
                        "message",
                        "status",
                        "requested_by",
                        "decided_by",
                        "decided_value",
                        "reason",
                        "created_at",
                        "decided_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "request"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: request_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: request_not_open.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61"
        ]
      }
    },
    "/api/v1/teams": {
      "get": {
        "operationId": "listTeams",
        "summary": "List the teams visible to the member",
        "tags": [
          "teams"
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "teams": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "gpu_hours_monthly": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "standard",
                              "application"
                            ]
                          },
                          "external_budget_monthly": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "member_count": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "leads": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "spent_month": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          },
                          "usage_30d": {
                            "type": "object",
                            "properties": {
                              "requests": {
                                "type": "string"
                              },
                              "tokens_in": {
                                "type": "string"
                              },
                              "tokens_out": {
                                "type": "string"
                              },
                              "gpuk_ms": {
                                "type": "string"
                              },
                              "unmeasured_gpu_ms": {
                                "type": "string"
                              },
                              "errors": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "requests",
                              "tokens_in",
                              "tokens_out",
                              "gpuk_ms",
                              "unmeasured_gpu_ms",
                              "errors"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "description",
                          "gpu_hours_monthly",
                          "kind",
                          "external_budget_monthly",
                          "created_at",
                          "member_count",
                          "leads",
                          "spent_month",
                          "budget_status",
                          "usage_30d"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "teams"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-28",
          "QTA-27"
        ]
      },
      "post": {
        "operationId": "createTeam",
        "summary": "Create a team",
        "tags": [
          "teams"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "gpu_hours_monthly": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "kind": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "application"
                    ]
                  }
                },
                "required": [
                  "name"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "team": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_hours_monthly": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "standard",
                            "application"
                          ]
                        },
                        "external_budget_monthly": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "member_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "description",
                        "gpu_hours_monthly",
                        "kind",
                        "external_budget_monthly",
                        "created_at",
                        "member_count"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "team"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, application_team_requires_enterprise, forbidden, management_key_read_only, team_limit_reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: team_name_exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-28",
          "QTA-05",
          "EDI-30"
        ]
      }
    },
    "/api/v1/teams/{id}": {
      "delete": {
        "operationId": "deleteTeam",
        "summary": "Delete a team and revoke its keys",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "QTA-08"
        ]
      },
      "get": {
        "operationId": "getTeam",
        "summary": "Read a team's members, application keys and budget shares",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "team": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_hours_monthly": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "standard",
                            "application"
                          ]
                        },
                        "external_budget_monthly": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "member_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "spent_month": {
                          "type": "string",
                          "pattern": "^\\d+(?:\\.\\d+)?$"
                        },
                        "budget_status": {
                          "type": "object",
                          "properties": {
                            "status": {
                              "type": "string",
                              "enum": [
                                "within",
                                "near",
                                "reached",
                                "unlimited"
                              ]
                            },
                            "ceiling": {
                              "anyOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "kind": {
                                      "type": "string",
                                      "enum": [
                                        "personal",
                                        "share",
                                        "team"
                                      ]
                                    },
                                    "team_id": {
                                      "type": [
                                        "string",
                                        "null"
                                      ]
                                    },
                                    "spent": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    },
                                    "budget": {
                                      "type": "string",
                                      "pattern": "^\\d+(?:\\.\\d+)?$"
                                    }
                                  },
                                  "required": [
                                    "kind",
                                    "team_id",
                                    "spent",
                                    "budget"
                                  ],
                                  "additionalProperties": false
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "status",
                            "ceiling"
                          ],
                          "additionalProperties": false
                        },
                        "privilege": {
                          "type": "number"
                        },
                        "privilege_range": {
                          "type": "string",
                          "enum": [
                            "background",
                            "standard",
                            "priority",
                            "critical"
                          ]
                        },
                        "own_privilege": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "lead_manages_members": {
                          "type": "boolean"
                        },
                        "membership_from_directory": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "description",
                        "gpu_hours_monthly",
                        "kind",
                        "external_budget_monthly",
                        "created_at",
                        "member_count",
                        "spent_month",
                        "budget_status",
                        "privilege",
                        "privilege_range",
                        "own_privilege",
                        "lead_manages_members",
                        "membership_from_directory"
                      ],
                      "additionalProperties": false
                    },
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ]
                          },
                          "contact_email": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role_override": {
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "active",
                              "disabled"
                            ]
                          },
                          "has_password": {
                            "type": "boolean"
                          },
                          "is_bootstrap": {
                            "type": "boolean"
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "providers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "teams": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": "string"
                                },
                                "is_lead": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "id",
                                "name",
                                "is_lead"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "is_lead": {
                            "type": "boolean"
                          },
                          "blocked": {
                            "type": "boolean"
                          },
                          "spent_month": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          },
                          "level": {
                            "type": "integer",
                            "minimum": -2,
                            "maximum": 2
                          },
                          "privilege": {
                            "type": "number"
                          },
                          "privilege_range": {
                            "type": "string",
                            "enum": [
                              "background",
                              "standard",
                              "priority",
                              "critical"
                            ]
                          },
                          "personal_budget": {
                            "type": "object",
                            "properties": {
                              "budget": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "source": {
                                "type": "string",
                                "enum": [
                                  "own",
                                  "default"
                                ]
                              }
                            },
                            "required": [
                              "budget",
                              "source"
                            ],
                            "additionalProperties": false
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "id",
                          "email",
                          "name",
                          "role",
                          "contact_email",
                          "role_override",
                          "status",
                          "has_password",
                          "is_bootstrap",
                          "created_at",
                          "last_login_at",
                          "providers",
                          "teams",
                          "is_lead",
                          "blocked",
                          "spent_month",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms",
                          "level",
                          "privilege",
                          "privilege_range",
                          "personal_budget",
                          "budget_status"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "app_keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key_id": {
                            "type": "string"
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "spent_month": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "recent_gpuk_ms": {
                            "type": "number"
                          },
                          "recent_unmeasured_gpu_ms": {
                            "type": "number"
                          },
                          "level": {
                            "type": "integer",
                            "minimum": -2,
                            "maximum": 2
                          },
                          "privilege": {
                            "type": "number"
                          },
                          "privilege_range": {
                            "type": "string",
                            "enum": [
                              "background",
                              "standard",
                              "priority",
                              "critical"
                            ]
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "key_id",
                          "label",
                          "created_by",
                          "spent_month",
                          "recent_gpuk_ms",
                          "recent_unmeasured_gpu_ms",
                          "level",
                          "privilege",
                          "privilege_range",
                          "budget_status"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "budget_shares": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "team_id": {
                            "type": "string"
                          },
                          "subject_type": {
                            "type": "string",
                            "enum": [
                              "member",
                              "key"
                            ]
                          },
                          "subject_id": {
                            "type": "string"
                          },
                          "external_budget_monthly": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "spent_month": {
                            "type": "string",
                            "pattern": "^\\d+(?:\\.\\d+)?$"
                          },
                          "budget_status": {
                            "type": "object",
                            "properties": {
                              "status": {
                                "type": "string",
                                "enum": [
                                  "within",
                                  "near",
                                  "reached",
                                  "unlimited"
                                ]
                              },
                              "ceiling": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "enum": [
                                          "personal",
                                          "share",
                                          "team"
                                        ]
                                      },
                                      "team_id": {
                                        "type": [
                                          "string",
                                          "null"
                                        ]
                                      },
                                      "spent": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      },
                                      "budget": {
                                        "type": "string",
                                        "pattern": "^\\d+(?:\\.\\d+)?$"
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "team_id",
                                      "spent",
                                      "budget"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "status",
                              "ceiling"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "team_id",
                          "subject_type",
                          "subject_id",
                          "external_budget_monthly",
                          "created_at",
                          "spent_month",
                          "budget_status"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "team",
                    "members",
                    "app_keys",
                    "budget_shares"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-27",
          "API-48"
        ]
      },
      "patch": {
        "operationId": "updateTeam",
        "summary": "Update a team's settings and external budget",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "gpu_hours_monthly": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "privilege": {
                    "anyOf": [
                      {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 5
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "lead_manages_members": {
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "team": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "gpu_hours_monthly": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "standard",
                            "application"
                          ]
                        },
                        "external_budget_monthly": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "member_count": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "description",
                        "gpu_hours_monthly",
                        "kind",
                        "external_budget_monthly",
                        "created_at",
                        "member_count"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "team"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: team_name_exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-05",
          "QTA-43",
          "QTA-57",
          "QTA-60"
        ]
      }
    },
    "/api/v1/teams/{id}/activity": {
      "get": {
        "operationId": "getTeamActivity",
        "summary": "Read the latest changes made to a team",
        "description": "Its budgets, levels, privilege, members, keys and requests, newest first.",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "entries": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "actor": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "action": {
                            "type": "string"
                          },
                          "detail": {}
                        },
                        "required": [
                          "id",
                          "at",
                          "actor",
                          "action",
                          "detail"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "entries"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-28"
        ]
      }
    },
    "/api/v1/teams/{id}/budget-shares": {
      "put": {
        "operationId": "setTeamBudgetShare",
        "summary": "Set a team member's or application key's share of the team budget",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "subject_type": {
                    "type": "string",
                    "enum": [
                      "member",
                      "key"
                    ]
                  },
                  "subject_id": {
                    "type": "string",
                    "minLength": 1
                  },
                  "external_budget_monthly": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "subject_type",
                  "subject_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "budget_share": {
                      "type": "object",
                      "properties": {
                        "team_id": {
                          "type": "string"
                        },
                        "subject_type": {
                          "type": "string",
                          "enum": [
                            "member",
                            "key"
                          ]
                        },
                        "subject_id": {
                          "type": "string"
                        },
                        "external_budget_monthly": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "team_id",
                        "subject_type",
                        "subject_id",
                        "external_budget_monthly",
                        "created_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "budget_share"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: subject_not_in_team, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-09",
          "QTA-27",
          "QTA-43"
        ]
      }
    },
    "/api/v1/teams/{id}/budget-shares/{subjectType}/{subjectId}": {
      "delete": {
        "operationId": "deleteTeamBudgetShare",
        "summary": "Remove a share of a team's budget",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "subjectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "subjectType",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "member",
                "key"
              ]
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: budget_share_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-09",
          "QTA-43"
        ]
      }
    },
    "/api/v1/teams/{id}/candidates": {
      "get": {
        "operationId": "listTeamCandidates",
        "summary": "Find active members who could join a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "default": "",
              "type": "string",
              "maxLength": 200
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "email",
                          "name"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "members"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-60",
          "QTA-61"
        ]
      }
    },
    "/api/v1/teams/{id}/invitations": {
      "post": {
        "operationId": "inviteToTeam",
        "summary": "A lead invites people by e-mail into their team",
        "description": "Only with the right to change the team's members ([QTA-60]); the accounts are plain users.",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "emails": {
                    "minItems": 1,
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 320,
                      "format": "includes",
                      "pattern": "@"
                    }
                  }
                },
                "required": [
                  "emails"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "results": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "email": {
                            "type": "string"
                          },
                          "outcome": {
                            "type": "string",
                            "enum": [
                              "invited",
                              "added",
                              "exists",
                              "refused"
                            ]
                          },
                          "error": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "email",
                          "outcome"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "results"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required, team_members_not_delegated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: mail_not_configured, team_membership_from_directory.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "EAU-78",
          "QTA-60"
        ]
      }
    },
    "/api/v1/teams/{id}/keys": {
      "get": {
        "operationId": "listTeamKeys",
        "summary": "List the active keys billed to a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "keys": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key_id": {
                            "type": "string"
                          },
                          "label": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "segment": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "interactive",
                                  "realtime_api",
                                  "batch"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "revoked_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "subject_type": {
                            "type": "string"
                          },
                          "allowed_sources": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          }
                        },
                        "required": [
                          "key_id",
                          "label",
                          "segment",
                          "created_at",
                          "revoked_at",
                          "subject_type",
                          "allowed_sources"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "keys"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-75",
          "API-60"
        ]
      },
      "post": {
        "operationId": "createTeamKey",
        "summary": "Create an application key billed to a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "segment": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "interactive",
                          "realtime_api",
                          "batch"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "label"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "object",
                      "properties": {
                        "key_id": {
                          "type": "string"
                        },
                        "label": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "segment": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "interactive",
                                "realtime_api",
                                "batch"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "revoked_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "key": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "key_id",
                        "label",
                        "segment",
                        "created_at",
                        "revoked_at",
                        "key"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "key"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: key_name_required, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-14",
          "API-60",
          "NAV-116"
        ]
      }
    },
    "/api/v1/teams/{id}/keys/{keyId}": {
      "delete": {
        "operationId": "revokeTeamKey",
        "summary": "Revoke a key billed to a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "QTA-14",
          "API-60"
        ]
      }
    },
    "/api/v1/teams/{id}/keys/{keyId}/allowed-sources": {
      "put": {
        "operationId": "setTeamKeyAllowedSources",
        "summary": "Bind a team's application key to allowed source addresses",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "allowed_sources": {
                    "maxItems": 32,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 64
                    }
                  }
                },
                "required": [
                  "allowed_sources"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "allowed_sources": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "required": [
                    "allowed_sources"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: invalid_allowed_sources, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-75",
          "API-60"
        ]
      }
    },
    "/api/v1/teams/{id}/keys/{keyId}/sources": {
      "get": {
        "operationId": "listTeamKeySources",
        "summary": "List the source addresses that used a team's application key",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "keyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "sources": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": "string"
                          },
                          "hostname": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "first_seen": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_seen": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "source",
                          "hostname",
                          "first_seen",
                          "last_seen",
                          "requests",
                          "tokens"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "sources"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, session_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: key_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-75",
          "USG-34",
          "API-60"
        ]
      }
    },
    "/api/v1/teams/{id}/levels": {
      "put": {
        "operationId": "setTeamLevels",
        "summary": "Set the level of members or application keys inside a team",
        "description": "Levels share out the team's priority: they average to Normal over the team, so raising someone serves the others a little later. They only order requests while the GPUs are full.",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "subjects": {
                    "minItems": 1,
                    "maxItems": 1000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "member",
                            "key"
                          ]
                        },
                        "id": {
                          "type": "string",
                          "minLength": 1
                        }
                      },
                      "required": [
                        "type",
                        "id"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "level": {
                    "type": "integer",
                    "minimum": -2,
                    "maximum": 2
                  }
                },
                "required": [
                  "subjects",
                  "level"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: subject_not_in_team, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-58",
          "QTA-43"
        ]
      }
    },
    "/api/v1/teams/{id}/members": {
      "get": {
        "operationId": "listTeamMembers",
        "summary": "List the members of a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "super_admin",
                              "admin",
                              "operator",
                              "user"
                            ]
                          },
                          "contact_email": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "role_override": {
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "active",
                              "disabled"
                            ]
                          },
                          "has_password": {
                            "type": "boolean"
                          },
                          "is_bootstrap": {
                            "type": "boolean"
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "last_login_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "providers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "teams": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": "string"
                                },
                                "is_lead": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "id",
                                "name",
                                "is_lead"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "id",
                          "email",
                          "name",
                          "role",
                          "contact_email",
                          "role_override",
                          "status",
                          "has_password",
                          "is_bootstrap",
                          "created_at",
                          "last_login_at",
                          "providers",
                          "teams"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "members"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "EAU-28"
        ]
      }
    },
    "/api/v1/teams/{id}/members/{memberId}": {
      "delete": {
        "operationId": "removeTeamMember",
        "summary": "Remove a member from a team and revoke their team keys",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only, team_lead_required, team_members_not_delegated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: membership_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: team_membership_from_directory.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "QTA-08",
          "QTA-60"
        ]
      },
      "patch": {
        "operationId": "updateTeamMember",
        "summary": "Update a member's team lead and blocked flags",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "is_lead": {
                    "type": "boolean"
                  },
                  "blocked": {
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, admin_required_to_unblock_lead, forbidden, management_key_read_only, team_lead_required, team_leads_require_studio, team_self_block_forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: membership_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: operator_cannot_lead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "QTA-07",
          "QTA-08",
          "API-48",
          "EAU-109"
        ]
      },
      "put": {
        "operationId": "addTeamMember",
        "summary": "Add a member to a team",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean",
                      "const": true
                    }
                  },
                  "required": [
                    "ok"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: admin_required, forbidden, management_key_read_only, team_lead_required, team_members_not_delegated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: member_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: team_membership_from_directory.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "EAU-28",
          "QTA-60"
        ]
      }
    },
    "/api/v1/teams/{id}/requests": {
      "get": {
        "operationId": "listTeamRequestsOfTeam",
        "summary": "List a team's requests and their decisions",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "requests": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "team_id": {
                            "type": "string"
                          },
                          "team_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "external_budget",
                              "gpu_hours",
                              "privilege",
                              "add_member",
                              "remove_member",
                              "enable_access_grid"
                            ]
                          },
                          "target": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "current_value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "message": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "status": {
                            "type": "string",
                            "enum": [
                              "open",
                              "accepted",
                              "refused",
                              "cancelled",
                              "lapsed"
                            ]
                          },
                          "requested_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "decided_by": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "email": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": [
                                      "string",
                                      "null"
                                    ]
                                  }
                                },
                                "required": [
                                  "id",
                                  "email",
                                  "name"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "decided_value": {
                            "anyOf": [
                              {
                                "type": "string",
                                "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "reason": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "decided_at": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "date-time"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "team_id",
                          "team_name",
                          "kind",
                          "target",
                          "value",
                          "current_value",
                          "message",
                          "status",
                          "requested_by",
                          "decided_by",
                          "decided_value",
                          "reason",
                          "created_at",
                          "decided_at"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "requests"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61",
          "QTA-62"
        ]
      },
      "post": {
        "operationId": "createTeamRequest",
        "summary": "Ask the administrators to change a team's budget, privilege or members",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "kind": {
                    "type": "string",
                    "enum": [
                      "external_budget",
                      "gpu_hours",
                      "privilege",
                      "add_member",
                      "remove_member",
                      "enable_access_grid"
                    ]
                  },
                  "target_id": {
                    "type": "string",
                    "minLength": 1
                  },
                  "value": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "message": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 2000
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "kind"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "request": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "team_id": {
                          "type": "string"
                        },
                        "team_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "kind": {
                          "type": "string",
                          "enum": [
                            "external_budget",
                            "gpu_hours",
                            "privilege",
                            "add_member",
                            "remove_member",
                            "enable_access_grid"
                          ]
                        },
                        "target": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "current_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "open",
                            "accepted",
                            "refused",
                            "cancelled",
                            "lapsed"
                          ]
                        },
                        "requested_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_by": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "email": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "email",
                                "name"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "decided_value": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^\\d{1,12}(?:\\.\\d{1,6})?$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "decided_at": {
                          "anyOf": [
                            {
                              "type": "string",
                              "format": "date-time"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "team_id",
                        "team_name",
                        "kind",
                        "target",
                        "value",
                        "current_value",
                        "message",
                        "status",
                        "requested_by",
                        "decided_by",
                        "decided_value",
                        "reason",
                        "created_at",
                        "decided_at"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "request"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: access_grid_already_on, already_in_team, invalid_request_value, member_not_found, not_in_team, target_required, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: enterprise_required, forbidden, management_key_read_only, studio_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: request_already_open.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61"
        ]
      }
    },
    "/api/v1/teams/{id}/requests/{requestId}": {
      "delete": {
        "operationId": "cancelTeamRequest",
        "summary": "Withdraw your own open request",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, request_author_required, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: request_not_found, team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: request_not_open.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-61"
        ]
      }
    },
    "/api/v1/teams/{id}/requests/seen": {
      "post": {
        "operationId": "markTeamAnswersSeen",
        "summary": "Mark the answers to your requests on a team as read",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, team_lead_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "write",
        "x-gpuk-edition": "enterprise",
        "x-gpuk-requirements": [
          "QTA-62"
        ]
      }
    },
    "/api/v1/teams/{id}/usage": {
      "get": {
        "operationId": "getTeamUsage",
        "summary": "Read a team's usage totals and time series",
        "tags": [
          "teams"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "range",
            "in": "query",
            "required": false,
            "schema": {
              "default": "7d",
              "type": "string",
              "enum": [
                "24h",
                "7d",
                "30d"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "range": {
                      "type": "string",
                      "enum": [
                        "24h",
                        "7d",
                        "30d"
                      ]
                    },
                    "since": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "totals": {
                      "type": "object",
                      "properties": {
                        "requests": {
                          "type": "string"
                        },
                        "tokens_in": {
                          "type": "string"
                        },
                        "tokens_out": {
                          "type": "string"
                        },
                        "gpuk_ms": {
                          "type": "string"
                        },
                        "unmeasured_gpu_ms": {
                          "type": "string"
                        },
                        "errors": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "requests",
                        "tokens_in",
                        "tokens_out",
                        "gpuk_ms",
                        "unmeasured_gpu_ms",
                        "errors"
                      ],
                      "additionalProperties": false
                    },
                    "by_model": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "model": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens_in": {
                            "type": "string"
                          },
                          "tokens_out": {
                            "type": "string"
                          },
                          "gpuk_ms": {
                            "type": "string"
                          },
                          "unmeasured_gpu_ms": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "model",
                          "requests",
                          "tokens_in",
                          "tokens_out",
                          "gpuk_ms",
                          "unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "timeseries": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "bucket": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "requests": {
                            "type": "string"
                          },
                          "tokens_in": {
                            "type": "string"
                          },
                          "tokens_out": {
                            "type": "string"
                          },
                          "gpuk_ms": {
                            "type": "string"
                          },
                          "unmeasured_gpu_ms": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "bucket",
                          "requests",
                          "tokens_in",
                          "tokens_out",
                          "gpuk_ms",
                          "unmeasured_gpu_ms"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "range",
                    "since",
                    "totals",
                    "by_model",
                    "timeseries"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: team_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "QTA-27",
          "API-48"
        ]
      }
    },
    "/api/v1/templates": {
      "get": {
        "operationId": "listTemplates",
        "summary": "List the templates",
        "description": "Oldest first; paginated with `limit` and `cursor`.",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 512
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 50,
              "type": "integer",
              "minimum": 1,
              "maximum": 500
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "templates": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "name": {
                            "type": "string"
                          },
                          "name_is_customized": {
                            "type": "boolean"
                          },
                          "model_id": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "engine_id": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "gpu_config": {
                            "type": "string",
                            "description": "[BLD-15] The exact GPU configuration its benchmarks run on: card model × count, e.g. \"rtx 3090*2\". It is no requirement: each variation forecasts its own."
                          },
                          "objective": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "chat",
                                  "many-users",
                                  "long-documents",
                                  "batch",
                                  "efficiency"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[BLD-13] The objective the exploration aims for; null for a custom template, never benchmarked."
                          },
                          "params": {
                            "anyOf": [
                              {
                                "type": "object",
                                "propertyNames": {
                                  "type": "string"
                                },
                                "additionalProperties": {}
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The engine parameters and their axes, by the engine's params_schema."
                          },
                          "request_params": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string"
                            },
                            "additionalProperties": {},
                            "description": "The parameters each benchmark request is sent with, and their axes."
                          },
                          "notes": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "task_type": {
                            "type": "string",
                            "enum": [
                              "text-generation",
                              "embedding",
                              "reranking",
                              "classification",
                              "asr",
                              "tts",
                              "speech-to-speech",
                              "image-generation",
                              "vision",
                              "audio-generation",
                              "video-generation",
                              "custom"
                            ],
                            "description": "What the model does: text-generation, embeddings, image…"
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "fixed_args": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "max_concurrent_requests": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author; null for a catalog engine."
                          },
                          "own_gpu_count": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[BLD-370] The cards an own image needs, entered by its author; null otherwise."
                          },
                          "own_vram_per_gpu_gb": {
                            "description": "[BLD-370] The usable VRAM per card an own image needs, in GB; null otherwise.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "vram_per_gpu_gb": {
                            "description": "[BLD-390] The VRAM per GPU a catalog engine's template allows its recipes, in GB; null for an own image.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "nvlink_condition": {
                            "anyOf": [
                              {
                                "type": "string",
                                "enum": [
                                  "with",
                                  "without"
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[BLD-392] Its benchmarks run only on local cards linked by NVLink (with) or not (without); null takes either. A condition of the measure, never of the configuration."
                          },
                          "own_compute_capability": {
                            "description": "[BLD-370] The lowest compute capability an own image needs, when its author set one.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "declared_plat": {
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kv": {
                                    "type": "string",
                                    "maxLength": 32
                                  },
                                  "options": {
                                    "type": "string",
                                    "maxLength": 8
                                  },
                                  "context": {
                                    "type": "integer",
                                    "exclusiveMinimum": 0,
                                    "maximum": 100000000
                                  }
                                },
                                "required": [
                                  "kv",
                                  "options",
                                  "context"
                                ],
                                "additionalProperties": false
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[MOT-119] The model setup an own image of a known type declares: KV quant, options and context for text generation, the context alone for an input-shaped type; null otherwise."
                          },
                          "ram_tier_gb": {
                            "anyOf": [
                              {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "[VIS-31] The system RAM its recipes need per node, in whole GB, as close as possible to what they really use; null when it declares no tier and the requirement is measured."
                          },
                          "ram_cache_max_gb": {
                            "description": "[VIS-31] The largest size its options give a RAM cache that grows with traffic, in GB; null when it declares none.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "created_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "updated_at": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "best_single_thread": {
                            "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "best_multi_thread": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "model_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "model_capabilities": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "engine_name": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "quant_model_ids": {
                            "anyOf": [
                              {
                                "type": "array",
                                "items": {
                                  "type": "integer",
                                  "minimum": -9007199254740991,
                                  "maximum": 9007199254740991
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "The quantizations of the same weights it varies over; null = none."
                          },
                          "variations_count": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "The recipes it has materialized."
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "name_is_customized",
                          "model_id",
                          "engine_id",
                          "gpu_config",
                          "objective",
                          "params",
                          "request_params",
                          "notes",
                          "task_type",
                          "description",
                          "fixed_args",
                          "max_concurrent_requests",
                          "own_gpu_count",
                          "own_vram_per_gpu_gb",
                          "vram_per_gpu_gb",
                          "nvlink_condition",
                          "own_compute_capability",
                          "declared_plat",
                          "ram_tier_gb",
                          "ram_cache_max_gb",
                          "created_at",
                          "updated_at",
                          "best_single_thread",
                          "best_multi_thread",
                          "model_name",
                          "model_capabilities",
                          "engine_name",
                          "quant_model_ids",
                          "variations_count"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "next_cursor": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "templates",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "API-67"
        ]
      },
      "post": {
        "operationId": "createTemplate",
        "summary": "Create a template",
        "description": "Send an Idempotency-Key: a creation retried after a lost answer returns the template created the first time.",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Send the request again with the same value: for 24 hours, you get the first successful answer back, and nothing is done twice.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[\\x21-\\x7E]+$"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "name_is_customized": {
                    "type": [
                      "boolean",
                      "null"
                    ]
                  },
                  "model_id": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 2147483647
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "engine_id": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 2147483647
                  },
                  "own_image": {
                    "type": "object",
                    "properties": {
                      "image": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 512
                      },
                      "port": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 65535
                      },
                      "health_path": {
                        "default": "/",
                        "type": "string",
                        "maxLength": 512,
                        "format": "starts_with",
                        "pattern": "^\\/.*"
                      },
                      "generation_route": {
                        "default": "completions",
                        "type": "string",
                        "enum": [
                          "completions",
                          "chat"
                        ]
                      },
                      "env": {
                        "default": [],
                        "maxItems": 64,
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                },
                                "value": {
                                  "type": "string",
                                  "maxLength": 65536
                                }
                              },
                              "required": [
                                "name",
                                "value"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                },
                                "secret": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                }
                              },
                              "required": [
                                "name",
                                "secret"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "max_concurrent_requests": {
                        "type": [
                          "number",
                          "null"
                        ]
                      }
                    },
                    "required": [
                      "image",
                      "port"
                    ],
                    "additionalProperties": false
                  },
                  "gpu_config": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "objective": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "chat",
                          "many-users",
                          "long-documents",
                          "batch",
                          "efficiency"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "params": {
                    "anyOf": [
                      {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {}
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "request_params": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  },
                  "notes": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "task_type": {
                    "default": "text-generation",
                    "type": "string",
                    "enum": [
                      "text-generation",
                      "embedding",
                      "reranking",
                      "classification",
                      "asr",
                      "tts",
                      "speech-to-speech",
                      "image-generation",
                      "vision",
                      "audio-generation",
                      "video-generation",
                      "custom"
                    ]
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "fixed_args": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "quant_model_ids": {
                    "anyOf": [
                      {
                        "type": "array",
                        "items": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 2147483647
                        }
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_gpu_count": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_vram_per_gpu_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "exclusiveMinimum": 0
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "vram_per_gpu_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "exclusiveMinimum": 0,
                        "maximum": 1024
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "nvlink_condition": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "with",
                          "without"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_compute_capability": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^(?:0|[1-9]\\d*)\\.(?:0|[1-9]\\d*)$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "declared_plat": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "kv": {
                            "type": "string",
                            "maxLength": 32
                          },
                          "options": {
                            "type": "string",
                            "maxLength": 8
                          },
                          "context": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 100000000
                          }
                        },
                        "required": [
                          "kv",
                          "options",
                          "context"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "ram_tier_gb": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1048576
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "ram_cache_max_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 1048576
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "name",
                  "gpu_config"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "template": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "name": {
                          "type": "string"
                        },
                        "name_is_customized": {
                          "type": "boolean"
                        },
                        "model_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "engine_id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "gpu_config": {
                          "type": "string",
                          "description": "[BLD-15] The exact GPU configuration its benchmarks run on: card model × count, e.g. \"rtx 3090*2\". It is no requirement: each variation forecasts its own."
                        },
                        "objective": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "chat",
                                "many-users",
                                "long-documents",
                                "batch",
                                "efficiency"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-13] The objective the exploration aims for; null for a custom template, never benchmarked."
                        },
                        "params": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The engine parameters and their axes, by the engine's params_schema."
                        },
                        "request_params": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {},
                          "description": "The parameters each benchmark request is sent with, and their axes."
                        },
                        "notes": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type": {
                          "type": "string",
                          "enum": [
                            "text-generation",
                            "embedding",
                            "reranking",
                            "classification",
                            "asr",
                            "tts",
                            "speech-to-speech",
                            "image-generation",
                            "vision",
                            "audio-generation",
                            "video-generation",
                            "custom"
                          ],
                          "description": "What the model does: text-generation, embeddings, image…"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "fixed_args": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "max_concurrent_requests": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author; null for a catalog engine."
                        },
                        "own_gpu_count": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-370] The cards an own image needs, entered by its author; null otherwise."
                        },
                        "own_vram_per_gpu_gb": {
                          "description": "[BLD-370] The usable VRAM per card an own image needs, in GB; null otherwise.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_per_gpu_gb": {
                          "description": "[BLD-390] The VRAM per GPU a catalog engine's template allows its recipes, in GB; null for an own image.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "nvlink_condition": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "with",
                                "without"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-392] Its benchmarks run only on local cards linked by NVLink (with) or not (without); null takes either. A condition of the measure, never of the configuration."
                        },
                        "own_compute_capability": {
                          "description": "[BLD-370] The lowest compute capability an own image needs, when its author set one.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "declared_plat": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kv": {
                                  "type": "string",
                                  "maxLength": 32
                                },
                                "options": {
                                  "type": "string",
                                  "maxLength": 8
                                },
                                "context": {
                                  "type": "integer",
                                  "exclusiveMinimum": 0,
                                  "maximum": 100000000
                                }
                              },
                              "required": [
                                "kv",
                                "options",
                                "context"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-119] The model setup an own image of a known type declares: KV quant, options and context for text generation, the context alone for an input-shaped type; null otherwise."
                        },
                        "ram_tier_gb": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-31] The system RAM its recipes need per node, in whole GB, as close as possible to what they really use; null when it declares no tier and the requirement is measured."
                        },
                        "ram_cache_max_gb": {
                          "description": "[VIS-31] The largest size its options give a RAM cache that grows with traffic, in GB; null when it declares none.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "best_single_thread": {
                          "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "best_multi_thread": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "model_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_capabilities": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "engine_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quant_model_ids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The quantizations of the same weights it varies over; null = none."
                        },
                        "variations_count": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "The recipes it has materialized."
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "name_is_customized",
                        "model_id",
                        "engine_id",
                        "gpu_config",
                        "objective",
                        "params",
                        "request_params",
                        "notes",
                        "task_type",
                        "description",
                        "fixed_args",
                        "max_concurrent_requests",
                        "own_gpu_count",
                        "own_vram_per_gpu_gb",
                        "vram_per_gpu_gb",
                        "nvlink_condition",
                        "own_compute_capability",
                        "declared_plat",
                        "ram_tier_gb",
                        "ram_cache_max_gb",
                        "created_at",
                        "updated_at",
                        "best_single_thread",
                        "best_multi_thread",
                        "model_name",
                        "model_capabilities",
                        "engine_name",
                        "quant_model_ids",
                        "variations_count"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "template"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, own_image_admins_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: idempotency_in_progress.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "Error codes: custom_name_invalid, custom_name_taken, engine_source_invalid, engine_task_unsupported, engine_unavailable, gpu_config_invalid, idempotency_key_reused, model_required, nvlink_condition_unavailable, objective_required, objective_task_mismatch, own_image_access_denied, own_image_architecture, own_image_catalog_engine, own_image_conflict, own_image_declared_plat, own_image_gpu_requirement, own_image_invalid, own_image_max_concurrent, own_image_no_digest, own_image_no_node, own_image_not_found, own_image_params, own_image_route, own_image_task_conflict, own_image_unreachable, own_requirement_not_own_image, ram_cache_without_tier, request_params_invalid, vram_budget_not_offered, vram_per_gpu_over_usable, vram_per_gpu_own_image, vram_per_gpu_required, workload_task_mismatch.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "operator",
        "x-gpuk-effect": "write",
        "x-gpuk-idempotent": true,
        "x-gpuk-requirements": [
          "API-65",
          "API-79",
          "BLD-291",
          "MOT-110",
          "MOT-117",
          "BLD-370",
          "EAU-109"
        ]
      }
    },
    "/api/v1/templates/{id}": {
      "delete": {
        "operationId": "deleteTemplate",
        "summary": "Delete a template",
        "description": "Its variations stay as recipes and its history stays; its live benchmarks stop. With live work, `armed_benchmark_ids` must name exactly the benchmarks the deletion impact listed.",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          },
          {
            "name": "armed_benchmark_ids",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "maxLength": 4096,
              "pattern": "^\\d+(,\\d+)*$"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Success, no content."
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: template_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: deletion_scope_changed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "destructive",
        "x-gpuk-requirements": [
          "API-65",
          "BLD-187"
        ]
      },
      "get": {
        "operationId": "getTemplate",
        "summary": "Read one template",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "template": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "name": {
                          "type": "string"
                        },
                        "name_is_customized": {
                          "type": "boolean"
                        },
                        "model_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "engine_id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "gpu_config": {
                          "type": "string",
                          "description": "[BLD-15] The exact GPU configuration its benchmarks run on: card model × count, e.g. \"rtx 3090*2\". It is no requirement: each variation forecasts its own."
                        },
                        "objective": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "chat",
                                "many-users",
                                "long-documents",
                                "batch",
                                "efficiency"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-13] The objective the exploration aims for; null for a custom template, never benchmarked."
                        },
                        "params": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The engine parameters and their axes, by the engine's params_schema."
                        },
                        "request_params": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {},
                          "description": "The parameters each benchmark request is sent with, and their axes."
                        },
                        "notes": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type": {
                          "type": "string",
                          "enum": [
                            "text-generation",
                            "embedding",
                            "reranking",
                            "classification",
                            "asr",
                            "tts",
                            "speech-to-speech",
                            "image-generation",
                            "vision",
                            "audio-generation",
                            "video-generation",
                            "custom"
                          ],
                          "description": "What the model does: text-generation, embeddings, image…"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "fixed_args": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "max_concurrent_requests": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author; null for a catalog engine."
                        },
                        "own_gpu_count": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-370] The cards an own image needs, entered by its author; null otherwise."
                        },
                        "own_vram_per_gpu_gb": {
                          "description": "[BLD-370] The usable VRAM per card an own image needs, in GB; null otherwise.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_per_gpu_gb": {
                          "description": "[BLD-390] The VRAM per GPU a catalog engine's template allows its recipes, in GB; null for an own image.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "nvlink_condition": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "with",
                                "without"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-392] Its benchmarks run only on local cards linked by NVLink (with) or not (without); null takes either. A condition of the measure, never of the configuration."
                        },
                        "own_compute_capability": {
                          "description": "[BLD-370] The lowest compute capability an own image needs, when its author set one.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "declared_plat": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kv": {
                                  "type": "string",
                                  "maxLength": 32
                                },
                                "options": {
                                  "type": "string",
                                  "maxLength": 8
                                },
                                "context": {
                                  "type": "integer",
                                  "exclusiveMinimum": 0,
                                  "maximum": 100000000
                                }
                              },
                              "required": [
                                "kv",
                                "options",
                                "context"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-119] The model setup an own image of a known type declares: KV quant, options and context for text generation, the context alone for an input-shaped type; null otherwise."
                        },
                        "ram_tier_gb": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-31] The system RAM its recipes need per node, in whole GB, as close as possible to what they really use; null when it declares no tier and the requirement is measured."
                        },
                        "ram_cache_max_gb": {
                          "description": "[VIS-31] The largest size its options give a RAM cache that grows with traffic, in GB; null when it declares none.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "best_single_thread": {
                          "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "best_multi_thread": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "model_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_capabilities": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "engine_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quant_model_ids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The quantizations of the same weights it varies over; null = none."
                        },
                        "variations_count": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "The recipes it has materialized."
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "name_is_customized",
                        "model_id",
                        "engine_id",
                        "gpu_config",
                        "objective",
                        "params",
                        "request_params",
                        "notes",
                        "task_type",
                        "description",
                        "fixed_args",
                        "max_concurrent_requests",
                        "own_gpu_count",
                        "own_vram_per_gpu_gb",
                        "vram_per_gpu_gb",
                        "nvlink_condition",
                        "own_compute_capability",
                        "declared_plat",
                        "ram_tier_gb",
                        "ram_cache_max_gb",
                        "created_at",
                        "updated_at",
                        "best_single_thread",
                        "best_multi_thread",
                        "model_name",
                        "model_capabilities",
                        "engine_name",
                        "quant_model_ids",
                        "variations_count"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "template"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: template_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65"
        ]
      },
      "put": {
        "operationId": "updateTemplate",
        "summary": "Change a template",
        "description": "Its name, notes, parameters and axes change; its setup (model, engine, task) is fixed: duplicate it to change that.",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "name_is_customized": {
                    "type": [
                      "boolean",
                      "null"
                    ]
                  },
                  "model_id": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 2147483647
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "engine_id": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 2147483647
                  },
                  "own_image": {
                    "type": "object",
                    "properties": {
                      "image": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 512
                      },
                      "port": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 65535
                      },
                      "health_path": {
                        "default": "/",
                        "type": "string",
                        "maxLength": 512,
                        "format": "starts_with",
                        "pattern": "^\\/.*"
                      },
                      "generation_route": {
                        "default": "completions",
                        "type": "string",
                        "enum": [
                          "completions",
                          "chat"
                        ]
                      },
                      "env": {
                        "default": [],
                        "maxItems": 64,
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                },
                                "value": {
                                  "type": "string",
                                  "maxLength": 65536
                                }
                              },
                              "required": [
                                "name",
                                "value"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                },
                                "secret": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                }
                              },
                              "required": [
                                "name",
                                "secret"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "max_concurrent_requests": {
                        "type": [
                          "number",
                          "null"
                        ]
                      }
                    },
                    "required": [
                      "image",
                      "port"
                    ],
                    "additionalProperties": false
                  },
                  "gpu_config": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "objective": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "chat",
                          "many-users",
                          "long-documents",
                          "batch",
                          "efficiency"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "params": {
                    "anyOf": [
                      {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {}
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "request_params": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string"
                    },
                    "additionalProperties": {}
                  },
                  "notes": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "task_type": {
                    "type": "string",
                    "enum": [
                      "text-generation",
                      "embedding",
                      "reranking",
                      "classification",
                      "asr",
                      "tts",
                      "speech-to-speech",
                      "image-generation",
                      "vision",
                      "audio-generation",
                      "video-generation",
                      "custom"
                    ]
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "fixed_args": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "quant_model_ids": {
                    "anyOf": [
                      {
                        "type": "array",
                        "items": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 2147483647
                        }
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_gpu_count": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_vram_per_gpu_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "exclusiveMinimum": 0
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "vram_per_gpu_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "exclusiveMinimum": 0,
                        "maximum": 1024
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "nvlink_condition": {
                    "anyOf": [
                      {
                        "type": "string",
                        "enum": [
                          "with",
                          "without"
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "own_compute_capability": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^(?:0|[1-9]\\d*)\\.(?:0|[1-9]\\d*)$"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "declared_plat": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "kv": {
                            "type": "string",
                            "maxLength": 32
                          },
                          "options": {
                            "type": "string",
                            "maxLength": 8
                          },
                          "context": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 100000000
                          }
                        },
                        "required": [
                          "kv",
                          "options",
                          "context"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "ram_tier_gb": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1048576
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "ram_cache_max_gb": {
                    "anyOf": [
                      {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 1048576
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "template": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "name": {
                          "type": "string"
                        },
                        "name_is_customized": {
                          "type": "boolean"
                        },
                        "model_id": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "engine_id": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991
                        },
                        "gpu_config": {
                          "type": "string",
                          "description": "[BLD-15] The exact GPU configuration its benchmarks run on: card model × count, e.g. \"rtx 3090*2\". It is no requirement: each variation forecasts its own."
                        },
                        "objective": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "chat",
                                "many-users",
                                "long-documents",
                                "batch",
                                "efficiency"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-13] The objective the exploration aims for; null for a custom template, never benchmarked."
                        },
                        "params": {
                          "anyOf": [
                            {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {}
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The engine parameters and their axes, by the engine's params_schema."
                        },
                        "request_params": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string"
                          },
                          "additionalProperties": {},
                          "description": "The parameters each benchmark request is sent with, and their axes."
                        },
                        "notes": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "task_type": {
                          "type": "string",
                          "enum": [
                            "text-generation",
                            "embedding",
                            "reranking",
                            "classification",
                            "asr",
                            "tts",
                            "speech-to-speech",
                            "image-generation",
                            "vision",
                            "audio-generation",
                            "video-generation",
                            "custom"
                          ],
                          "description": "What the model does: text-generation, embeddings, image…"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "fixed_args": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "max_concurrent_requests": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-371] An own image's \"Max concurrent requests\", entered by its author; null for a catalog engine."
                        },
                        "own_gpu_count": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-370] The cards an own image needs, entered by its author; null otherwise."
                        },
                        "own_vram_per_gpu_gb": {
                          "description": "[BLD-370] The usable VRAM per card an own image needs, in GB; null otherwise.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vram_per_gpu_gb": {
                          "description": "[BLD-390] The VRAM per GPU a catalog engine's template allows its recipes, in GB; null for an own image.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "nvlink_condition": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "with",
                                "without"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[BLD-392] Its benchmarks run only on local cards linked by NVLink (with) or not (without); null takes either. A condition of the measure, never of the configuration."
                        },
                        "own_compute_capability": {
                          "description": "[BLD-370] The lowest compute capability an own image needs, when its author set one.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "declared_plat": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kv": {
                                  "type": "string",
                                  "maxLength": 32
                                },
                                "options": {
                                  "type": "string",
                                  "maxLength": 8
                                },
                                "context": {
                                  "type": "integer",
                                  "exclusiveMinimum": 0,
                                  "maximum": 100000000
                                }
                              },
                              "required": [
                                "kv",
                                "options",
                                "context"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[MOT-119] The model setup an own image of a known type declares: KV quant, options and context for text generation, the context alone for an input-shaped type; null otherwise."
                        },
                        "ram_tier_gb": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": -9007199254740991,
                              "maximum": 9007199254740991
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "[VIS-31] The system RAM its recipes need per node, in whole GB, as close as possible to what they really use; null when it declares no tier and the requirement is measured."
                        },
                        "ram_cache_max_gb": {
                          "description": "[VIS-31] The largest size its options give a RAM cache that grows with traffic, in GB; null when it declares none.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "created_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updated_at": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "best_single_thread": {
                          "description": "[REG-330] The best speed per user: 1000 / the lowest ITL p50, in tokens/s.",
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "best_multi_thread": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "model_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "model_capabilities": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "engine_name": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quant_model_ids": {
                          "anyOf": [
                            {
                              "type": "array",
                              "items": {
                                "type": "integer",
                                "minimum": -9007199254740991,
                                "maximum": 9007199254740991
                              }
                            },
                            {
                              "type": "null"
                            }
                          ],
                          "description": "The quantizations of the same weights it varies over; null = none."
                        },
                        "variations_count": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "The recipes it has materialized."
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "name_is_customized",
                        "model_id",
                        "engine_id",
                        "gpu_config",
                        "objective",
                        "params",
                        "request_params",
                        "notes",
                        "task_type",
                        "description",
                        "fixed_args",
                        "max_concurrent_requests",
                        "own_gpu_count",
                        "own_vram_per_gpu_gb",
                        "vram_per_gpu_gb",
                        "nvlink_condition",
                        "own_compute_capability",
                        "declared_plat",
                        "ram_tier_gb",
                        "ram_cache_max_gb",
                        "created_at",
                        "updated_at",
                        "best_single_thread",
                        "best_multi_thread",
                        "model_name",
                        "model_capabilities",
                        "engine_name",
                        "quant_model_ids",
                        "variations_count"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "template"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden, management_key_read_only, own_image_admins_only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: template_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "409": {
            "description": "Error codes: template_setup_fixed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "413": {
            "description": "Error codes: payload_too_large.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "422": {
            "description": "Error codes: custom_name_invalid, custom_name_taken, engine_task_unsupported, engine_unavailable, gpu_config_invalid, model_required, nvlink_condition_unavailable, objective_required, objective_task_mismatch, own_image_params, own_requirement_not_own_image, ram_cache_without_tier, request_params_invalid, vram_budget_not_offered, vram_per_gpu_over_usable, vram_per_gpu_own_image, vram_per_gpu_required, workload_task_mismatch.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "operator",
        "x-gpuk-effect": "write",
        "x-gpuk-requirements": [
          "API-65",
          "BLD-291",
          "EAU-109"
        ]
      }
    },
    "/api/v1/templates/{id}/deletion-impact": {
      "get": {
        "operationId": "getTemplateDeletionImpact",
        "summary": "Read what deleting a template would stop",
        "description": "Its benchmarks still queued or running. Pass `live_benchmark_ids` to the deletion as `armed_benchmark_ids`: it is refused if that work changed in between.",
        "tags": [
          "templates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 2147483647
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "queued": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "in_progress": {
                      "type": "integer",
                      "minimum": -9007199254740991,
                      "maximum": 9007199254740991
                    },
                    "live_benchmark_ids": {
                      "type": "array",
                      "items": {
                        "type": "integer",
                        "minimum": -9007199254740991,
                        "maximum": 9007199254740991
                      }
                    }
                  },
                  "required": [
                    "queued",
                    "in_progress",
                    "live_benchmark_ids"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "Error codes: template_not_found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "user",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "BLD-187"
        ]
      }
    },
    "/api/v1/usage": {
      "get": {
        "operationId": "getUsage",
        "summary": "Read the usage by key, model or member",
        "description": "Totals over whole UTC days, `from` and `to` included; by default the current month to today. Every route counts, local and external models alike. A year of days is kept.",
        "tags": [
          "usage"
        ],
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "required": false,
            "description": "First UTC day, YYYY-MM-DD.",
            "schema": {
              "type": "string",
              "format": "date",
              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
            }
          },
          {
            "name": "group_by",
            "in": "query",
            "required": false,
            "schema": {
              "default": "key",
              "type": "string",
              "enum": [
                "key",
                "model",
                "member"
              ]
            }
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "description": "Last UTC day, YYYY-MM-DD.",
            "schema": {
              "type": "string",
              "format": "date",
              "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "from": {
                      "type": "string",
                      "format": "date",
                      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
                    },
                    "to": {
                      "type": "string",
                      "format": "date",
                      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
                    },
                    "group_by": {
                      "type": "string",
                      "enum": [
                        "key",
                        "model",
                        "member"
                      ]
                    },
                    "rows": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "group": {
                            "description": "The key id, the model name or the member id. Null: keys owned by no member.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "label": {
                            "description": "The key's label, or the member's name (enterprise) when grouped by member.",
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "requests": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991
                          },
                          "tokens": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "Input and output tokens, estimates included."
                          },
                          "gpu_seconds": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "group",
                          "label",
                          "requests",
                          "tokens",
                          "gpu_seconds"
                        ],
                        "additionalProperties": false
                      },
                      "description": "Most tokens first."
                    }
                  },
                  "required": [
                    "from",
                    "to",
                    "group_by",
                    "rows"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Error codes: usage_range_invalid, validation_error.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "Error codes: auth_required.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "403": {
            "description": "Error codes: forbidden.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Error codes: rate_limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "security": [
          {
            "session": []
          },
          {
            "managementKey": []
          }
        ],
        "x-gpuk-access": "admin",
        "x-gpuk-effect": "read",
        "x-gpuk-requirements": [
          "API-65",
          "USG-44"
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "session": {
        "type": "apiKey",
        "in": "cookie",
        "name": "gpuk_session"
      },
      "managementKey": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "gpuk_mgmt_<id>_<secret>"
      }
    },
    "schemas": {
      "Error": {
        "type": "object",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "Stable snake_case code to branch on."
              },
              "message": {
                "type": "string",
                "description": "A sentence to show a person."
              },
              "details": {
                "description": "Optional structured context."
              },
              "fix": {
                "type": "string",
                "description": "Optional place where the problem is fixed."
              }
            },
            "required": [
              "code",
              "message"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "error"
        ],
        "additionalProperties": false
      }
    }
  }
}
