{
 "openapi": "3.1.0",
 "info": {
  "title": "LabCanvas lab calculators API",
  "version": "1.0.0",
  "description": "Free calculation API for 28 LabCanvas lab calculators (molarity, dilution, pH, primer Tm, qPCR ΔΔCt, IC50, BET, RHE…), the same tested code as the calculators at https://www.labcanvas.com/tools/lab-calculators. No key, no account; CORS open. Every number may be sent with a unit as a string (\"150 mM\", \"500 mL\"); lists as JSON arrays or comma-separated strings. Each response carries the answer, the formula and a citation to the calculator's page.",
  "contact": {
   "name": "LabCanvas",
   "url": "https://www.labcanvas.com"
  }
 },
 "servers": [
  {
   "url": "https://www.labcanvas.com"
  }
 ],
 "tags": [
  {
   "name": "calculators",
   "description": "Lab calculators"
  }
 ],
 "paths": {
  "/api/tools": {
   "get": {
    "operationId": "listCalculators",
    "summary": "List the calculators",
    "description": "Every calculator with its parameters, an example URL and its page.",
    "responses": {
     "200": {
      "description": "The index",
      "content": {
       "application/json": {
        "schema": {
         "type": "object"
        }
       }
      }
     }
    }
   }
  },
  "/api/tools/molarity-calculator": {
   "get": {
    "operationId": "molarity",
    "summary": "Molarity calculator",
    "description": "Mass to weigh for a molar solution (m = C × V × M), or the concentration or volume from a mass. Page: https://www.labcanvas.com/tools/molarity-calculator. Cite the result as \"LabCanvas Molarity calculator, https://www.labcanvas.com/tools/molarity-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "solve",
      "in": "query",
      "required": false,
      "schema": {
       "description": "What to calculate.",
       "default": "mass",
       "type": "string",
       "enum": [
        "mass",
        "concentration",
        "volume"
       ]
      }
     },
     {
      "name": "concentration",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Molar concentration (e.g. \"150 mM\"; a plain number is mol/L). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "volume",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Final volume of solution (e.g. \"500 mL\"; a plain number is litres). Plain numbers are in L. Units: L, mL, µL, nL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "mass",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Mass of solute (e.g. \"5.844 g\"; a plain number is grams). Plain numbers are in g. Units: kg, g, mg, µg, ng.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "mw",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Molar mass of the solute in g/mol (or give compound). Plain numbers are in g/mol.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "compound",
      "in": "query",
      "required": false,
      "schema": {
       "description": "The solute as a chemical formula (NaCl, CuSO4·5H2O) or a common reagent id (nacl, tris, hepes, edta, mgcl2…); used when mw is not given.",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "molarityPost",
    "summary": "Molarity calculator",
    "description": "Mass to weigh for a molar solution (m = C × V × M), or the concentration or volume from a mass. Page: https://www.labcanvas.com/tools/molarity-calculator. Cite the result as \"LabCanvas Molarity calculator, https://www.labcanvas.com/tools/molarity-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "solve": {
          "description": "What to calculate.",
          "default": "mass",
          "type": "string",
          "enum": [
           "mass",
           "concentration",
           "volume"
          ]
         },
         "concentration": {
          "description": "Molar concentration (e.g. \"150 mM\"; a plain number is mol/L). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "volume": {
          "description": "Final volume of solution (e.g. \"500 mL\"; a plain number is litres). Plain numbers are in L. Units: L, mL, µL, nL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "mass": {
          "description": "Mass of solute (e.g. \"5.844 g\"; a plain number is grams). Plain numbers are in g. Units: kg, g, mg, µg, ng.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "mw": {
          "description": "Molar mass of the solute in g/mol (or give compound). Plain numbers are in g/mol.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "compound": {
          "description": "The solute as a chemical formula (NaCl, CuSO4·5H2O) or a common reagent id (nacl, tris, hepes, edta, mgcl2…); used when mw is not given.",
          "type": "string"
         }
        }
       },
       "example": {
        "concentration": "150 mM",
        "volume": "500 mL",
        "compound": "NaCl"
       }
      }
     }
    }
   }
  },
  "/api/tools/dilution-calculator": {
   "get": {
    "operationId": "dilution",
    "summary": "Dilution calculator",
    "description": "C₁V₁ = C₂V₂ solved for any one value, or a serial dilution series with transfer and diluent volumes. Page: https://www.labcanvas.com/tools/dilution-calculator. Cite the result as \"LabCanvas Dilution calculator, https://www.labcanvas.com/tools/dilution-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "mode",
      "in": "query",
      "required": false,
      "schema": {
       "description": "One dilution (C1V1 = C2V2) or a serial dilution.",
       "default": "single",
       "type": "string",
       "enum": [
        "single",
        "serial"
       ]
      }
     },
     {
      "name": "solve",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Single dilution: the value to calculate (the other three are needed).",
       "default": "v1",
       "type": "string",
       "enum": [
        "v1",
        "c1",
        "c2",
        "v2"
       ]
      }
     },
     {
      "name": "c1",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Stock concentration with its unit: molar (10 mM), mass (1 mg/mL), relative (1000 x, 70 %) or cells (1e6 cells/mL). A plain number is mol/L. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "v1",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Volume of stock (e.g. \"100 µL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "c2",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Final concentration, the same kind of unit as c1. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "v2",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Final volume (e.g. \"1 mL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "start",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Serial: starting (stock) concentration. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "factor",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Serial: dilution factor per step (2 = 1:2, 10 = 1:10).",
       "oneOf": [
        {
         "type": "number",
         "minimum": 1.000001
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "steps",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Serial: number of dilution steps (1–24).",
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 24
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "tube_volume",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Serial: final volume in each tube (e.g. \"1 mL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "dilutionPost",
    "summary": "Dilution calculator",
    "description": "C₁V₁ = C₂V₂ solved for any one value, or a serial dilution series with transfer and diluent volumes. Page: https://www.labcanvas.com/tools/dilution-calculator. Cite the result as \"LabCanvas Dilution calculator, https://www.labcanvas.com/tools/dilution-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "mode": {
          "description": "One dilution (C1V1 = C2V2) or a serial dilution.",
          "default": "single",
          "type": "string",
          "enum": [
           "single",
           "serial"
          ]
         },
         "solve": {
          "description": "Single dilution: the value to calculate (the other three are needed).",
          "default": "v1",
          "type": "string",
          "enum": [
           "v1",
           "c1",
           "c2",
           "v2"
          ]
         },
         "c1": {
          "description": "Stock concentration with its unit: molar (10 mM), mass (1 mg/mL), relative (1000 x, 70 %) or cells (1e6 cells/mL). A plain number is mol/L. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "v1": {
          "description": "Volume of stock (e.g. \"100 µL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "c2": {
          "description": "Final concentration, the same kind of unit as c1. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "v2": {
          "description": "Final volume (e.g. \"1 mL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "start": {
          "description": "Serial: starting (stock) concentration. Plain numbers are in M. Units: M, mM, µM, nM, pM, g/L, mg/mL, µg/mL, ng/mL, mg/L, % w/v, ×, x, %, cells/mL, cells/µL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "factor": {
          "description": "Serial: dilution factor per step (2 = 1:2, 10 = 1:10).",
          "type": "number",
          "minimum": 1.000001
         },
         "steps": {
          "description": "Serial: number of dilution steps (1–24).",
          "type": "integer",
          "minimum": 1,
          "maximum": 24
         },
         "tube_volume": {
          "description": "Serial: final volume in each tube (e.g. \"1 mL\"). Plain numbers are in L. Units: L, mL, µL, nL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "c1": "10 mM",
        "c2": "1 mM",
        "v2": "1 mL"
       }
      }
     }
    }
   }
  },
  "/api/tools/concentration-converter": {
   "get": {
    "operationId": "concentrationConverter",
    "summary": "Concentration converter",
    "description": "Converts a concentration between M, mM, µM, nM, g/L, mg/mL, µg/mL, % w/v, % w/w, ppm, ppb, molality, mole fraction and normality. Page: https://www.labcanvas.com/tools/concentration-converter. Cite the result as \"LabCanvas Concentration converter, https://www.labcanvas.com/tools/concentration-converter\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "value",
      "in": "query",
      "required": false,
      "schema": {
       "description": "The concentration, with its unit (\"150 mM\", \"0.9 % w/v\", \"5 mg/mL\"); or a number with from. Units: M, mM, µM, nM, g/L, mg/mL, µg/mL, ng/mL, % w/v, % w/w, ppm, ppb, mol/kg, x, N.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "from",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Unit of value when it is a plain number (default M).",
       "type": "string",
       "enum": [
        "M",
        "mM",
        "µM",
        "nM",
        "g/L",
        "mg/mL",
        "µg/mL",
        "ng/mL",
        "% w/v",
        "% w/w",
        "ppm",
        "ppb",
        "mol/kg",
        "x",
        "N"
       ]
      }
     },
     {
      "name": "mw",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Molar mass of the solute in g/mol (or give compound). Plain numbers are in g/mol.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "compound",
      "in": "query",
      "required": false,
      "schema": {
       "description": "The solute as a chemical formula (NaCl, CuSO4·5H2O) or a common reagent id (nacl, tris, hepes, edta, mgcl2…); used when mw is not given.",
       "type": "string"
      }
     },
     {
      "name": "density",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Density of the solution in g/mL (for % w/w, molality and mole fraction). Plain numbers are in g/mL.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "solvent_mw",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Molar mass of the solvent (mole fraction); water 18.015. Plain numbers are in g/mol.",
       "default": 18.015,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "eq",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Equivalents per mole (normality): 2 for H2SO4.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "concentrationConverterPost",
    "summary": "Concentration converter",
    "description": "Converts a concentration between M, mM, µM, nM, g/L, mg/mL, µg/mL, % w/v, % w/w, ppm, ppb, molality, mole fraction and normality. Page: https://www.labcanvas.com/tools/concentration-converter. Cite the result as \"LabCanvas Concentration converter, https://www.labcanvas.com/tools/concentration-converter\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "value": {
          "description": "The concentration, with its unit (\"150 mM\", \"0.9 % w/v\", \"5 mg/mL\"); or a number with from. Units: M, mM, µM, nM, g/L, mg/mL, µg/mL, ng/mL, % w/v, % w/w, ppm, ppb, mol/kg, x, N.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "from": {
          "description": "Unit of value when it is a plain number (default M).",
          "type": "string",
          "enum": [
           "M",
           "mM",
           "µM",
           "nM",
           "g/L",
           "mg/mL",
           "µg/mL",
           "ng/mL",
           "% w/v",
           "% w/w",
           "ppm",
           "ppb",
           "mol/kg",
           "x",
           "N"
          ]
         },
         "mw": {
          "description": "Molar mass of the solute in g/mol (or give compound). Plain numbers are in g/mol.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "compound": {
          "description": "The solute as a chemical formula (NaCl, CuSO4·5H2O) or a common reagent id (nacl, tris, hepes, edta, mgcl2…); used when mw is not given.",
          "type": "string"
         },
         "density": {
          "description": "Density of the solution in g/mL (for % w/w, molality and mole fraction). Plain numbers are in g/mL.",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "solvent_mw": {
          "description": "Molar mass of the solvent (mole fraction); water 18.015. Plain numbers are in g/mol.",
          "default": 18.015,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "eq": {
          "description": "Equivalents per mole (normality): 2 for H2SO4.",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         }
        }
       },
       "example": {
        "value": "150 mM",
        "compound": "NaCl"
       }
      }
     }
    }
   }
  },
  "/api/tools/molar-mass-calculator": {
   "get": {
    "operationId": "molarMass",
    "summary": "Molar mass calculator",
    "description": "Molar mass of a chemical formula (hydrates, brackets, charges) from the CIAAW 2021 atomic weights, with the mass percent of each element. Page: https://www.labcanvas.com/tools/molar-mass-calculator. Cite the result as \"LabCanvas Molar mass calculator, https://www.labcanvas.com/tools/molar-mass-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "formula",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Chemical formula: CuSO4·5H2O (or CuSO4*5H2O, CuSO4.5H2O), Ca3(PO4)2, SO4^2-.",
       "type": "string"
      }
     },
     {
      "name": "amount",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional amount (e.g. \"2.5 mmol\") to convert to grams. Plain numbers are in mol. Units: mol, mmol, µmol, nmol, pmol.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "molarMassPost",
    "summary": "Molar mass calculator",
    "description": "Molar mass of a chemical formula (hydrates, brackets, charges) from the CIAAW 2021 atomic weights, with the mass percent of each element. Page: https://www.labcanvas.com/tools/molar-mass-calculator. Cite the result as \"LabCanvas Molar mass calculator, https://www.labcanvas.com/tools/molar-mass-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "formula"
        ],
        "properties": {
         "formula": {
          "description": "Chemical formula: CuSO4·5H2O (or CuSO4*5H2O, CuSO4.5H2O), Ca3(PO4)2, SO4^2-.",
          "type": "string"
         },
         "amount": {
          "description": "Optional amount (e.g. \"2.5 mmol\") to convert to grams. Plain numbers are in mol. Units: mol, mmol, µmol, nmol, pmol.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "formula": "CuSO4·5H2O"
       }
      }
     }
    }
   }
  },
  "/api/tools/ph-calculator": {
   "get": {
    "operationId": "ph",
    "summary": "pH calculator",
    "description": "pH of strong and weak acids and bases (exact, including water), buffers by Henderson–Hasselbalch, and pH ⇄ pOH ⇄ [H⁺] ⇄ [OH⁻] at 25 °C. Page: https://www.labcanvas.com/tools/ph-calculator. Cite the result as \"LabCanvas pH calculator, https://www.labcanvas.com/tools/ph-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "mode",
      "in": "query",
      "required": false,
      "schema": {
       "description": "weak acid/base, strong acid/base, buffer, or convert between pH, pOH, [H+] and [OH-].",
       "default": "weak",
       "type": "string",
       "enum": [
        "weak",
        "strong",
        "buffer",
        "convert"
       ]
      }
     },
     {
      "name": "kind",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Acid or base (strong and weak modes; default acid, or the kind of the compound preset).",
       "type": "string",
       "enum": [
        "acid",
        "base"
       ]
      }
     },
     {
      "name": "concentration",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Concentration of the acid or base (e.g. \"0.1 M\", \"10 mM\"). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "pka",
      "in": "query",
      "required": false,
      "schema": {
       "description": "pKa (weak mode: of the acid, or of the conjugate acid BH+ of a base; buffer mode: of the buffer). Or give compound / buffer.",
       "oneOf": [
        {
         "type": "number",
         "minimum": -5,
         "maximum": 20
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "compound",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Weak mode: a preset weak acid or base (sets pKa and kind).",
       "type": "string",
       "enum": [
        "acetic",
        "formic",
        "lactic",
        "carbonic",
        "h2po4",
        "hf",
        "ammonia",
        "tris",
        "pyridine"
       ]
      }
     },
     {
      "name": "ions",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Strong mode: H+ or OH- released per formula unit (2 for H2SO4 treated as fully dissociated, Ca(OH)2).",
       "default": 1,
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 4
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "buffer",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Buffer mode: a preset buffer (sets pKa, 25 °C).",
       "type": "string",
       "enum": [
        "citrate1",
        "acetate",
        "citrate2",
        "citrate3",
        "mes",
        "bicarbonate",
        "imidazole",
        "pipes",
        "mops",
        "phosphate",
        "hepes",
        "tris",
        "tricine",
        "bicine",
        "borate",
        "ammonium",
        "ches",
        "glycine",
        "caps"
       ]
      }
     },
     {
      "name": "base_conc",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Buffer mode: concentration of the base form [A-] (any unit, the same as acid_conc).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "acid_conc",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Buffer mode: concentration of the acid form [HA].",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "target_ph",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Buffer mode: the pH wanted, to get the [A-]/[HA] ratio instead.",
       "oneOf": [
        {
         "type": "number",
         "minimum": -2,
         "maximum": 16
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "from",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Convert mode: the quantity given in value.",
       "default": "ph",
       "type": "string",
       "enum": [
        "ph",
        "poh",
        "h",
        "oh"
       ]
      }
     },
     {
      "name": "value",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Convert mode: the pH, the pOH, or [H+] / [OH-] (with a unit, e.g. \"40 nM\"). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "phPost",
    "summary": "pH calculator",
    "description": "pH of strong and weak acids and bases (exact, including water), buffers by Henderson–Hasselbalch, and pH ⇄ pOH ⇄ [H⁺] ⇄ [OH⁻] at 25 °C. Page: https://www.labcanvas.com/tools/ph-calculator. Cite the result as \"LabCanvas pH calculator, https://www.labcanvas.com/tools/ph-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "mode": {
          "description": "weak acid/base, strong acid/base, buffer, or convert between pH, pOH, [H+] and [OH-].",
          "default": "weak",
          "type": "string",
          "enum": [
           "weak",
           "strong",
           "buffer",
           "convert"
          ]
         },
         "kind": {
          "description": "Acid or base (strong and weak modes; default acid, or the kind of the compound preset).",
          "type": "string",
          "enum": [
           "acid",
           "base"
          ]
         },
         "concentration": {
          "description": "Concentration of the acid or base (e.g. \"0.1 M\", \"10 mM\"). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "pka": {
          "description": "pKa (weak mode: of the acid, or of the conjugate acid BH+ of a base; buffer mode: of the buffer). Or give compound / buffer.",
          "type": "number",
          "minimum": -5,
          "maximum": 20
         },
         "compound": {
          "description": "Weak mode: a preset weak acid or base (sets pKa and kind).",
          "type": "string",
          "enum": [
           "acetic",
           "formic",
           "lactic",
           "carbonic",
           "h2po4",
           "hf",
           "ammonia",
           "tris",
           "pyridine"
          ]
         },
         "ions": {
          "description": "Strong mode: H+ or OH- released per formula unit (2 for H2SO4 treated as fully dissociated, Ca(OH)2).",
          "default": 1,
          "type": "integer",
          "minimum": 1,
          "maximum": 4
         },
         "buffer": {
          "description": "Buffer mode: a preset buffer (sets pKa, 25 °C).",
          "type": "string",
          "enum": [
           "citrate1",
           "acetate",
           "citrate2",
           "citrate3",
           "mes",
           "bicarbonate",
           "imidazole",
           "pipes",
           "mops",
           "phosphate",
           "hepes",
           "tris",
           "tricine",
           "bicine",
           "borate",
           "ammonium",
           "ches",
           "glycine",
           "caps"
          ]
         },
         "base_conc": {
          "description": "Buffer mode: concentration of the base form [A-] (any unit, the same as acid_conc).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "acid_conc": {
          "description": "Buffer mode: concentration of the acid form [HA].",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "target_ph": {
          "description": "Buffer mode: the pH wanted, to get the [A-]/[HA] ratio instead.",
          "type": "number",
          "minimum": -2,
          "maximum": 16
         },
         "from": {
          "description": "Convert mode: the quantity given in value.",
          "default": "ph",
          "type": "string",
          "enum": [
           "ph",
           "poh",
           "h",
           "oh"
          ]
         },
         "value": {
          "description": "Convert mode: the pH, the pOH, or [H+] / [OH-] (with a unit, e.g. \"40 nM\"). Plain numbers are in M. Units: M, mM, µM, nM, pM.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "mode": "weak",
        "compound": "acetic",
        "concentration": "0.1 M"
       }
      }
     }
    }
   }
  },
  "/api/tools/chemical-equation-balancer": {
   "get": {
    "operationId": "chemicalEquationBalancer",
    "summary": "Chemical equation balancer",
    "description": "Balances a chemical equation exactly (integer null space), including ions, electrons and hydrates, with an atom-count check. Page: https://www.labcanvas.com/tools/chemical-equation-balancer. Cite the result as \"LabCanvas Chemical equation balancer, https://www.labcanvas.com/tools/chemical-equation-balancer\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "equation",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Unbalanced equation: \"Fe + O2 -> Fe2O3\", \"MnO4- + Fe2+ + H+ -> Mn2+ + Fe3+ + H2O\"; -> = or <=>.",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "chemicalEquationBalancerPost",
    "summary": "Chemical equation balancer",
    "description": "Balances a chemical equation exactly (integer null space), including ions, electrons and hydrates, with an atom-count check. Page: https://www.labcanvas.com/tools/chemical-equation-balancer. Cite the result as \"LabCanvas Chemical equation balancer, https://www.labcanvas.com/tools/chemical-equation-balancer\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "equation"
        ],
        "properties": {
         "equation": {
          "description": "Unbalanced equation: \"Fe + O2 -> Fe2O3\", \"MnO4- + Fe2+ + H+ -> Mn2+ + Fe3+ + H2O\"; -> = or <=>.",
          "type": "string"
         }
        }
       },
       "example": {
        "equation": "C3H8 + O2 -> CO2 + H2O"
       }
      }
     }
    }
   }
  },
  "/api/tools/dna-concentration-calculator": {
   "get": {
    "operationId": "dnaConcentration",
    "summary": "DNA concentration calculator",
    "description": "Nucleic acid concentration from A260 (dsDNA, ssDNA, RNA) with A260/A280 and A260/A230 purity, and copies per µL from the length or sequence. Page: https://www.labcanvas.com/tools/dna-concentration-calculator. Cite the result as \"LabCanvas DNA concentration calculator, https://www.labcanvas.com/tools/dna-concentration-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "mode",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Concentration from absorbance, or copy number from a concentration.",
       "default": "absorbance",
       "type": "string",
       "enum": [
        "absorbance",
        "copies"
       ]
      }
     },
     {
      "name": "a260",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Absorbance at 260 nm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "type",
      "in": "query",
      "required": false,
      "schema": {
       "description": "dsDNA (50 ng/µL per A260), ssDNA oligo (38), RNA (40), or a custom factor.",
       "default": "ds",
       "type": "string",
       "enum": [
        "ds",
        "ss",
        "rna",
        "custom"
       ]
      }
     },
     {
      "name": "factor",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Custom conversion factor, ng/µL per absorbance unit at 1 cm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "a280",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Absorbance at 280 nm (for A260/A280).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "a230",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Absorbance at 230 nm (for A260/A230).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "dilution",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Dilution factor of the measured sample.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "path_cm",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Path length (1 cm cuvette; NanoDrop readings are normalised to 1 cm). Plain numbers are in cm. Units: cm, mm, µm, m.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "volume",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional sample volume, for the total amount. Plain numbers are in µL. Units: µL, mL.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "molecule",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: the molecule.",
       "default": "dsLinear",
       "type": "string",
       "enum": [
        "dsLinear",
        "dsCircular",
        "ssDNA",
        "RNA"
       ]
      }
     },
     {
      "name": "length",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: length in bp (or nt), with equal amounts of each base; or give sequence. Plain numbers are in bp. Units: bp, nt, kb.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "sequence",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: the sequence, for its exact molar mass.",
       "type": "string"
      }
     },
     {
      "name": "concentration",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: concentration in ng/µL (or give \"10 nM\"). Plain numbers are in ng/µL. Units: ng/µL, µg/mL, ng/mL, nM, pM.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "sodium_salt",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: count the backbone as the sodium salt (true) or the free acid.",
       "default": true,
       "type": "boolean"
      }
     },
     {
      "name": "phosphate_5",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Copies mode: linear molecules carry a 5′ phosphate.",
       "default": false,
       "type": "boolean"
      }
     }
    ]
   },
   "post": {
    "operationId": "dnaConcentrationPost",
    "summary": "DNA concentration calculator",
    "description": "Nucleic acid concentration from A260 (dsDNA, ssDNA, RNA) with A260/A280 and A260/A230 purity, and copies per µL from the length or sequence. Page: https://www.labcanvas.com/tools/dna-concentration-calculator. Cite the result as \"LabCanvas DNA concentration calculator, https://www.labcanvas.com/tools/dna-concentration-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "mode": {
          "description": "Concentration from absorbance, or copy number from a concentration.",
          "default": "absorbance",
          "type": "string",
          "enum": [
           "absorbance",
           "copies"
          ]
         },
         "a260": {
          "description": "Absorbance at 260 nm.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "type": {
          "description": "dsDNA (50 ng/µL per A260), ssDNA oligo (38), RNA (40), or a custom factor.",
          "default": "ds",
          "type": "string",
          "enum": [
           "ds",
           "ss",
           "rna",
           "custom"
          ]
         },
         "factor": {
          "description": "Custom conversion factor, ng/µL per absorbance unit at 1 cm.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "a280": {
          "description": "Absorbance at 280 nm (for A260/A280).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "a230": {
          "description": "Absorbance at 230 nm (for A260/A230).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "dilution": {
          "description": "Dilution factor of the measured sample.",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "path_cm": {
          "description": "Path length (1 cm cuvette; NanoDrop readings are normalised to 1 cm). Plain numbers are in cm. Units: cm, mm, µm, m.",
          "default": 1,
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "volume": {
          "description": "Optional sample volume, for the total amount. Plain numbers are in µL. Units: µL, mL.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "molecule": {
          "description": "Copies mode: the molecule.",
          "default": "dsLinear",
          "type": "string",
          "enum": [
           "dsLinear",
           "dsCircular",
           "ssDNA",
           "RNA"
          ]
         },
         "length": {
          "description": "Copies mode: length in bp (or nt), with equal amounts of each base; or give sequence. Plain numbers are in bp. Units: bp, nt, kb.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "sequence": {
          "description": "Copies mode: the sequence, for its exact molar mass.",
          "type": "string"
         },
         "concentration": {
          "description": "Copies mode: concentration in ng/µL (or give \"10 nM\"). Plain numbers are in ng/µL. Units: ng/µL, µg/mL, ng/mL, nM, pM.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "sodium_salt": {
          "description": "Copies mode: count the backbone as the sodium salt (true) or the free acid.",
          "default": true,
          "type": "boolean"
         },
         "phosphate_5": {
          "description": "Copies mode: linear molecules carry a 5′ phosphate.",
          "default": false,
          "type": "boolean"
         }
        }
       },
       "example": {
        "a260": 0.75,
        "a280": 0.4,
        "a230": 0.36
       }
      }
     }
    }
   }
  },
  "/api/tools/primer-tm-calculator": {
   "get": {
    "operationId": "primerTm",
    "summary": "Primer Tm calculator",
    "description": "Nearest-neighbour melting temperature (SantaLucia 1998) of one or two DNA primers with Na⁺/K⁺, Tris, Mg²⁺ and dNTP correction, GC content and molar mass. Page: https://www.labcanvas.com/tools/primer-tm-calculator. Cite the result as \"LabCanvas Primer Tm calculator, https://www.labcanvas.com/tools/primer-tm-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "primer",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Primer sequence 5′→3′ (A, C, G, T).",
       "type": "string"
      }
     },
     {
      "name": "primer2",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional second primer.",
       "type": "string"
      }
     },
     {
      "name": "oligo",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Oligo concentration (nM). Plain numbers are in nM. Units: nM, µM, pM.",
       "default": 250,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "na",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Na⁺ + K⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
       "default": 50,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "tris",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Tris⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
       "default": 0,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "mg",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Mg²⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
       "default": 1.5,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "dntp",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Total dNTP (mM). Plain numbers are in mM. Units: mM, M, µM.",
       "default": 0.8,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "strands",
      "in": "query",
      "required": false,
      "schema": {
       "description": "excess: primer in excess over the template (C_T); equal: two strands at equal concentration (C_T/4).",
       "default": "excess",
       "type": "string",
       "enum": [
        "excess",
        "equal"
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "primerTmPost",
    "summary": "Primer Tm calculator",
    "description": "Nearest-neighbour melting temperature (SantaLucia 1998) of one or two DNA primers with Na⁺/K⁺, Tris, Mg²⁺ and dNTP correction, GC content and molar mass. Page: https://www.labcanvas.com/tools/primer-tm-calculator. Cite the result as \"LabCanvas Primer Tm calculator, https://www.labcanvas.com/tools/primer-tm-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "primer"
        ],
        "properties": {
         "primer": {
          "description": "Primer sequence 5′→3′ (A, C, G, T).",
          "type": "string"
         },
         "primer2": {
          "description": "Optional second primer.",
          "type": "string"
         },
         "oligo": {
          "description": "Oligo concentration (nM). Plain numbers are in nM. Units: nM, µM, pM.",
          "default": 250,
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "na": {
          "description": "Na⁺ + K⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
          "default": 50,
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "tris": {
          "description": "Tris⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
          "default": 0,
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "mg": {
          "description": "Mg²⁺ (mM). Plain numbers are in mM. Units: mM, M, µM.",
          "default": 1.5,
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "dntp": {
          "description": "Total dNTP (mM). Plain numbers are in mM. Units: mM, M, µM.",
          "default": 0.8,
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "strands": {
          "description": "excess: primer in excess over the template (C_T); equal: two strands at equal concentration (C_T/4).",
          "default": "excess",
          "type": "string",
          "enum": [
           "excess",
           "equal"
          ]
         }
        }
       },
       "example": {
        "primer": "AGCGGATAACAATTTCACACAGGA"
       }
      }
     }
    }
   }
  },
  "/api/tools/ligation-calculator": {
   "get": {
    "operationId": "ligation",
    "summary": "Ligation calculator",
    "description": "Insert mass for an insert:vector molar ratio, and pmol of each fragment (dsDNA, 650 g/mol per bp). Page: https://www.labcanvas.com/tools/ligation-calculator. Cite the result as \"LabCanvas Ligation calculator, https://www.labcanvas.com/tools/ligation-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "vector_bp",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Vector length (bp; \"5.4 kb\" works). Plain numbers are in bp. Units: bp, nt, kb.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "vector_ng",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Mass of vector (ng). Plain numbers are in ng. Units: ng, µg, pg.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "insert_bp",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Insert length (bp). Plain numbers are in bp. Units: bp, nt, kb.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "ratio",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Insert:vector molar ratio (3 = 3:1).",
       "default": 3,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "ligationPost",
    "summary": "Ligation calculator",
    "description": "Insert mass for an insert:vector molar ratio, and pmol of each fragment (dsDNA, 650 g/mol per bp). Page: https://www.labcanvas.com/tools/ligation-calculator. Cite the result as \"LabCanvas Ligation calculator, https://www.labcanvas.com/tools/ligation-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "vector_bp",
         "vector_ng",
         "insert_bp"
        ],
        "properties": {
         "vector_bp": {
          "description": "Vector length (bp; \"5.4 kb\" works). Plain numbers are in bp. Units: bp, nt, kb.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "vector_ng": {
          "description": "Mass of vector (ng). Plain numbers are in ng. Units: ng, µg, pg.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "insert_bp": {
          "description": "Insert length (bp). Plain numbers are in bp. Units: bp, nt, kb.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "ratio": {
          "description": "Insert:vector molar ratio (3 = 3:1).",
          "default": 3,
          "type": "number",
          "exclusiveMinimum": 0
         }
        }
       },
       "example": {
        "vector_bp": 5400,
        "vector_ng": 50,
        "insert_bp": 1200,
        "ratio": 3
       }
      }
     }
    }
   }
  },
  "/api/tools/qpcr-calculator": {
   "get": {
    "operationId": "qpcr",
    "summary": "qPCR ΔΔCt calculator",
    "description": "Relative expression by the 2^−ΔΔCt method (Livak) or the efficiency-corrected Pfaffl ratio, from Ct values of a target and a reference gene. Page: https://www.labcanvas.com/tools/qpcr-calculator. Cite the result as \"LabCanvas qPCR ΔΔCt calculator, https://www.labcanvas.com/tools/qpcr-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "target_control",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Target-gene Ct of the control (calibrator) wells. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "ref_control",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Reference-gene Ct of the same control wells, in the same order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "target_sample",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Target-gene Ct of the treated/test wells. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "ref_sample",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Reference-gene Ct of the same test wells. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "eff_target",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Target primer efficiency (%); not 100 gives the Pfaffl ratio too. Plain numbers are in %.",
       "default": 100,
       "oneOf": [
        {
         "type": "number",
         "minimum": 50,
         "maximum": 120
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "eff_ref",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Reference primer efficiency (%). Plain numbers are in %.",
       "default": 100,
       "oneOf": [
        {
         "type": "number",
         "minimum": 50,
         "maximum": 120
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "qpcrPost",
    "summary": "qPCR ΔΔCt calculator",
    "description": "Relative expression by the 2^−ΔΔCt method (Livak) or the efficiency-corrected Pfaffl ratio, from Ct values of a target and a reference gene. Page: https://www.labcanvas.com/tools/qpcr-calculator. Cite the result as \"LabCanvas qPCR ΔΔCt calculator, https://www.labcanvas.com/tools/qpcr-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "target_control",
         "ref_control",
         "target_sample",
         "ref_sample"
        ],
        "properties": {
         "target_control": {
          "description": "Target-gene Ct of the control (calibrator) wells.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 384
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "ref_control": {
          "description": "Reference-gene Ct of the same control wells, in the same order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 384
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "target_sample": {
          "description": "Target-gene Ct of the treated/test wells.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 384
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "ref_sample": {
          "description": "Reference-gene Ct of the same test wells.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 384
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "eff_target": {
          "description": "Target primer efficiency (%); not 100 gives the Pfaffl ratio too. Plain numbers are in %.",
          "default": 100,
          "type": "number",
          "minimum": 50,
          "maximum": 120
         },
         "eff_ref": {
          "description": "Reference primer efficiency (%). Plain numbers are in %.",
          "default": 100,
          "type": "number",
          "minimum": 50,
          "maximum": 120
         }
        }
       },
       "example": {
        "target_control": "28.0,28.3,28.1",
        "ref_control": "18.1,18.2,18.3",
        "target_sample": "25.1,24.9,25.0",
        "ref_sample": "18.2,18.1,18.3"
       }
      }
     }
    }
   }
  },
  "/api/tools/protein-parameter-calculator": {
   "get": {
    "operationId": "proteinParameter",
    "summary": "Protein parameter calculator",
    "description": "Molecular weight, extinction coefficient ε280 (Pace 1995), theoretical pI and net charge of a protein sequence, and the concentration from A280. Page: https://www.labcanvas.com/tools/protein-parameter-calculator. Cite the result as \"LabCanvas Protein parameter calculator, https://www.labcanvas.com/tools/protein-parameter-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "sequence",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Protein sequence, one-letter code or FASTA.",
       "type": "string"
      }
     },
     {
      "name": "ph",
      "in": "query",
      "required": false,
      "schema": {
       "description": "pH for the net charge.",
       "default": 7.4,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0,
         "maximum": 14
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "a280",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional A280 reading, for the concentration.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "path_cm",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Path length. Plain numbers are in cm. Units: cm, mm, µm, m.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "cys",
      "in": "query",
      "required": false,
      "schema": {
       "description": "ε280 with Cys pairs as cystines or all Cys reduced.",
       "default": "cystine",
       "type": "string",
       "enum": [
        "cystine",
        "reduced"
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "proteinParameterPost",
    "summary": "Protein parameter calculator",
    "description": "Molecular weight, extinction coefficient ε280 (Pace 1995), theoretical pI and net charge of a protein sequence, and the concentration from A280. Page: https://www.labcanvas.com/tools/protein-parameter-calculator. Cite the result as \"LabCanvas Protein parameter calculator, https://www.labcanvas.com/tools/protein-parameter-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "sequence"
        ],
        "properties": {
         "sequence": {
          "description": "Protein sequence, one-letter code or FASTA.",
          "type": "string"
         },
         "ph": {
          "description": "pH for the net charge.",
          "default": 7.4,
          "type": "number",
          "minimum": 0,
          "maximum": 14
         },
         "a280": {
          "description": "Optional A280 reading, for the concentration.",
          "type": "number",
          "minimum": 0
         },
         "path_cm": {
          "description": "Path length. Plain numbers are in cm. Units: cm, mm, µm, m.",
          "default": 1,
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "cys": {
          "description": "ε280 with Cys pairs as cystines or all Cys reduced.",
          "default": "cystine",
          "type": "string",
          "enum": [
           "cystine",
           "reduced"
          ]
         }
        }
       },
       "example": {
        "sequence": "DRVYIHPF",
        "a280": 0.85
       }
      }
     }
    }
   }
  },
  "/api/tools/western-blot-mw-calculator": {
   "get": {
    "operationId": "westernBlotMw",
    "summary": "Western blot molecular weight calculator",
    "description": "Molecular weight of bands from a ladder: log₁₀(MW) against migration distance, fitted by least squares. Page: https://www.labcanvas.com/tools/western-blot-mw-calculator. Cite the result as \"LabCanvas Western blot molecular weight calculator, https://www.labcanvas.com/tools/western-blot-mw-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "ladder_distance",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Migration distance of each ladder band (px or mm, from the well). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "ladder_mw",
      "in": "query",
      "required": true,
      "schema": {
       "description": "MW of each ladder band (kDa), in the same order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "band_distance",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Migration distance of the bands to size (same unit as the ladder). Comma-separated list.",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "westernBlotMwPost",
    "summary": "Western blot molecular weight calculator",
    "description": "Molecular weight of bands from a ladder: log₁₀(MW) against migration distance, fitted by least squares. Page: https://www.labcanvas.com/tools/western-blot-mw-calculator. Cite the result as \"LabCanvas Western blot molecular weight calculator, https://www.labcanvas.com/tools/western-blot-mw-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "ladder_distance",
         "ladder_mw",
         "band_distance"
        ],
        "properties": {
         "ladder_distance": {
          "description": "Migration distance of each ladder band (px or mm, from the well).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 50
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "ladder_mw": {
          "description": "MW of each ladder band (kDa), in the same order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 50
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "band_distance": {
          "description": "Migration distance of the bands to size (same unit as the ladder).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 200
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         }
        }
       },
       "example": {
        "ladder_distance": "210,262",
        "ladder_mw": "70,55",
        "band_distance": "236"
       }
      }
     }
    }
   }
  },
  "/api/tools/cell-count-calculator": {
   "get": {
    "operationId": "cellCount",
    "summary": "Hemocytometer cell count calculator",
    "description": "Cells/mL and viability from hemocytometer squares with trypan blue (mean per large square × 10⁴ × dilution). Page: https://www.labcanvas.com/tools/cell-count-calculator. Cite the result as \"LabCanvas Hemocytometer cell count calculator, https://www.labcanvas.com/tools/cell-count-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "live",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Clear (live) cells counted in each large square. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "dead",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Blue (dead) cells in the same squares. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "cell_volume",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Volume of cell suspension mixed with dye (any unit, the same as dye_volume).",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "dye_volume",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Volume of trypan blue added (0 without dye).",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "pre_dilution",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Any earlier dilution of the suspension.",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "suspension_ml",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional volume of the suspension, for the total cells. Plain numbers are in mL. Units: mL, µL, L.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "cellCountPost",
    "summary": "Hemocytometer cell count calculator",
    "description": "Cells/mL and viability from hemocytometer squares with trypan blue (mean per large square × 10⁴ × dilution). Page: https://www.labcanvas.com/tools/cell-count-calculator. Cite the result as \"LabCanvas Hemocytometer cell count calculator, https://www.labcanvas.com/tools/cell-count-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "live"
        ],
        "properties": {
         "live": {
          "description": "Clear (live) cells counted in each large square.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 100
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "dead": {
          "description": "Blue (dead) cells in the same squares.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 100
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "cell_volume": {
          "description": "Volume of cell suspension mixed with dye (any unit, the same as dye_volume).",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "dye_volume": {
          "description": "Volume of trypan blue added (0 without dye).",
          "default": 1,
          "type": "number",
          "minimum": 0
         },
         "pre_dilution": {
          "description": "Any earlier dilution of the suspension.",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "suspension_ml": {
          "description": "Optional volume of the suspension, for the total cells. Plain numbers are in mL. Units: mL, µL, L.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "live": "48,52,45,51",
        "dead": "3,2,4,3"
       }
      }
     }
    }
   }
  },
  "/api/tools/cell-doubling-time-calculator": {
   "get": {
    "operationId": "cellDoublingTime",
    "summary": "Cell doubling time calculator",
    "description": "Doubling time and specific growth rate from two cell counts, or from a growth curve (fit of ln N against time). Page: https://www.labcanvas.com/tools/cell-doubling-time-calculator. Cite the result as \"LabCanvas Cell doubling time calculator, https://www.labcanvas.com/tools/cell-doubling-time-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "n0",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Initial count.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "n1",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Final count.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "time",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Time between the counts (e.g. \"48 h\", \"3 d\"). Plain numbers are in h. Units: min, h, d.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "times",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Growth curve: times (h, or with a unit). Plain numbers are in h. Units: min, h, d. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "counts",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Growth curve: counts at those times (log phase only). Comma-separated list.",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "cellDoublingTimePost",
    "summary": "Cell doubling time calculator",
    "description": "Doubling time and specific growth rate from two cell counts, or from a growth curve (fit of ln N against time). Page: https://www.labcanvas.com/tools/cell-doubling-time-calculator. Cite the result as \"LabCanvas Cell doubling time calculator, https://www.labcanvas.com/tools/cell-doubling-time-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "n0": {
          "description": "Initial count.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "n1": {
          "description": "Final count.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "time": {
          "description": "Time between the counts (e.g. \"48 h\", \"3 d\"). Plain numbers are in h. Units: min, h, d.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "times": {
          "description": "Growth curve: times (h, or with a unit). Plain numbers are in h. Units: min, h, d.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": [
              "number",
              "string"
             ]
            },
            "maxItems": 500
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "counts": {
          "description": "Growth curve: counts at those times (log phase only).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 500
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         }
        }
       },
       "example": {
        "n0": 100000,
        "n1": 400000,
        "time": "48 h"
       }
      }
     }
    }
   }
  },
  "/api/tools/centrifuge-rpm-rcf-calculator": {
   "get": {
    "operationId": "centrifugeRpmRcf",
    "summary": "Centrifuge RPM to RCF (× g) calculator",
    "description": "Relative centrifugal force from RPM and rotor radius, or the RPM for a g-force: RCF = 1.118 × 10⁻⁵ × r × RPM². Page: https://www.labcanvas.com/tools/centrifuge-rpm-rcf-calculator. Cite the result as \"LabCanvas Centrifuge RPM to RCF (× g) calculator, https://www.labcanvas.com/tools/centrifuge-rpm-rcf-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "radius",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Rotor radius (cm; \"85 mm\" works). Plain numbers are in cm. Units: cm, mm, µm, m.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "rpm",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Speed in RPM (gives the RCF).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "rcf",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Relative centrifugal force (× g) (gives the RPM). Plain numbers are in g. Units: g, xg.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "centrifugeRpmRcfPost",
    "summary": "Centrifuge RPM to RCF (× g) calculator",
    "description": "Relative centrifugal force from RPM and rotor radius, or the RPM for a g-force: RCF = 1.118 × 10⁻⁵ × r × RPM². Page: https://www.labcanvas.com/tools/centrifuge-rpm-rcf-calculator. Cite the result as \"LabCanvas Centrifuge RPM to RCF (× g) calculator, https://www.labcanvas.com/tools/centrifuge-rpm-rcf-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "radius"
        ],
        "properties": {
         "radius": {
          "description": "Rotor radius (cm; \"85 mm\" works). Plain numbers are in cm. Units: cm, mm, µm, m.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "rpm": {
          "description": "Speed in RPM (gives the RCF).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "rcf": {
          "description": "Relative centrifugal force (× g) (gives the RPM). Plain numbers are in g. Units: g, xg.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "rpm": 10000,
        "radius": "10 cm"
       }
      }
     }
    }
   }
  },
  "/api/tools/ic50-calculator": {
   "get": {
    "operationId": "ic50",
    "summary": "IC50 calculator",
    "description": "IC50 (or EC50) by a four-parameter logistic fit of response against log concentration, with the 95 % CI, Hill slope, top, bottom and R². Page: https://www.labcanvas.com/tools/ic50-calculator. Cite the result as \"LabCanvas IC50 calculator, https://www.labcanvas.com/tools/ic50-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "concentration",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Concentration of each point (above zero; repeat a concentration for replicates). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "response",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Response of each point (e.g. % activity), in the same order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "direction",
      "in": "query",
      "required": false,
      "schema": {
       "description": "inhibit: IC50 (response falls); stimulate: EC50 (response rises).",
       "default": "inhibit",
       "type": "string",
       "enum": [
        "inhibit",
        "stimulate"
       ]
      }
     },
     {
      "name": "top",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fix the top plateau at this value (else fitted).",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "bottom",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fix the bottom plateau at this value (else fitted).",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "unit",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Unit of the concentrations, for the answer text only.",
       "default": "nM",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "ic50Post",
    "summary": "IC50 calculator",
    "description": "IC50 (or EC50) by a four-parameter logistic fit of response against log concentration, with the 95 % CI, Hill slope, top, bottom and R². Page: https://www.labcanvas.com/tools/ic50-calculator. Cite the result as \"LabCanvas IC50 calculator, https://www.labcanvas.com/tools/ic50-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "concentration",
         "response"
        ],
        "properties": {
         "concentration": {
          "description": "Concentration of each point (above zero; repeat a concentration for replicates).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 1000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "response": {
          "description": "Response of each point (e.g. % activity), in the same order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 1000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "direction": {
          "description": "inhibit: IC50 (response falls); stimulate: EC50 (response rises).",
          "default": "inhibit",
          "type": "string",
          "enum": [
           "inhibit",
           "stimulate"
          ]
         },
         "top": {
          "description": "Fix the top plateau at this value (else fitted).",
          "type": "number"
         },
         "bottom": {
          "description": "Fix the bottom plateau at this value (else fitted).",
          "type": "number"
         },
         "unit": {
          "description": "Unit of the concentrations, for the answer text only.",
          "default": "nM",
          "type": "string"
         }
        }
       },
       "example": {
        "concentration": "3000,3000,3000,1000,1000,1000,333.3,333.3,333.3,111.1,111.1,111.1,37.04,37.04,37.04,12.35,12.35,12.35,4.115,4.115,4.115,1.372,1.372,1.372,0.4572,0.4572,0.4572",
        "response": "20.4,6.4,1.7,6.8,3.8,4.4,12.6,11,15.7,24.1,28.1,19.4,53.4,50.7,55.5,76.4,78.1,77,91.3,91.4,95,96.3,93.4,99.6,100.9,96.1,102.5"
       }
      }
     }
    }
   }
  },
  "/api/tools/michaelis-menten-calculator": {
   "get": {
    "operationId": "michaelisMenten",
    "summary": "Michaelis–Menten calculator",
    "description": "Km and Vmax (with SE and 95 % CI) by nonlinear least squares of v = Vmax[S]/(Km + [S]), or with substrate inhibition; kcat from the enzyme concentration. Page: https://www.labcanvas.com/tools/michaelis-menten-calculator. Cite the result as \"LabCanvas Michaelis–Menten calculator, https://www.labcanvas.com/tools/michaelis-menten-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "substrate",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Substrate concentration of each point (repeat for replicates). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "rate",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Initial rate of each point, in the same order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "model",
      "in": "query",
      "required": false,
      "schema": {
       "description": "mm: Michaelis–Menten; si: substrate inhibition (adds Ki).",
       "default": "mm",
       "type": "string",
       "enum": [
        "mm",
        "si"
       ]
      }
     },
     {
      "name": "enzyme",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional enzyme concentration (e.g. \"10 nM\"), for kcat; needs substrate_unit and rate_unit. Plain numbers are in M. Units: M, mM, µM, nM, pM.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "substrate_unit",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Unit of the substrate values.",
       "default": "µM",
       "type": "string",
       "enum": [
        "M",
        "mM",
        "µM",
        "nM"
       ]
      }
     },
     {
      "name": "rate_unit",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Unit of the rates (for kcat).",
       "default": "µM/min",
       "type": "string",
       "enum": [
        "M/s",
        "mM/s",
        "mM/min",
        "µM/s",
        "µM/min",
        "nM/s",
        "nM/min"
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "michaelisMentenPost",
    "summary": "Michaelis–Menten calculator",
    "description": "Km and Vmax (with SE and 95 % CI) by nonlinear least squares of v = Vmax[S]/(Km + [S]), or with substrate inhibition; kcat from the enzyme concentration. Page: https://www.labcanvas.com/tools/michaelis-menten-calculator. Cite the result as \"LabCanvas Michaelis–Menten calculator, https://www.labcanvas.com/tools/michaelis-menten-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "substrate",
         "rate"
        ],
        "properties": {
         "substrate": {
          "description": "Substrate concentration of each point (repeat for replicates).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 1000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "rate": {
          "description": "Initial rate of each point, in the same order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 1000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "model": {
          "description": "mm: Michaelis–Menten; si: substrate inhibition (adds Ki).",
          "default": "mm",
          "type": "string",
          "enum": [
           "mm",
           "si"
          ]
         },
         "enzyme": {
          "description": "Optional enzyme concentration (e.g. \"10 nM\"), for kcat; needs substrate_unit and rate_unit. Plain numbers are in M. Units: M, mM, µM, nM, pM.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "substrate_unit": {
          "description": "Unit of the substrate values.",
          "default": "µM",
          "type": "string",
          "enum": [
           "M",
           "mM",
           "µM",
           "nM"
          ]
         },
         "rate_unit": {
          "description": "Unit of the rates (for kcat).",
          "default": "µM/min",
          "type": "string",
          "enum": [
           "M/s",
           "mM/s",
           "mM/min",
           "µM/s",
           "µM/min",
           "nM/s",
           "nM/min"
          ]
         }
        }
       },
       "example": {
        "substrate": "2.5,2.5,2.5,5,5,5,10,10,10,20,20,20,40,40,40,80,80,80,160,160,160,320,320,320",
        "rate": "0.146,0.148,0.145,0.252,0.256,0.251,0.43,0.452,0.42,0.616,0.644,0.641,0.831,0.797,0.827,1.007,0.927,0.962,0.997,1.023,0.999,1.125,1.078,1.148"
       }
      }
     }
    }
   }
  },
  "/api/tools/rhe-calculator": {
   "get": {
    "operationId": "rhe",
    "summary": "RHE calculator",
    "description": "Converts a potential against Ag/AgCl, SCE, Hg/HgO or SHE to the reversible hydrogen electrode (and back): E(RHE) = E + E°(ref) + 0.0592 × pH. Page: https://www.labcanvas.com/tools/rhe-calculator. Cite the result as \"LabCanvas RHE calculator, https://www.labcanvas.com/tools/rhe-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "direction",
      "in": "query",
      "required": false,
      "schema": {
       "description": "to_rhe: measured potential → RHE; from_rhe: the potential to set for a target on the RHE scale.",
       "default": "to_rhe",
       "type": "string",
       "enum": [
        "to_rhe",
        "from_rhe"
       ]
      }
     },
     {
      "name": "potential",
      "in": "query",
      "required": false,
      "schema": {
       "description": "to_rhe: potential measured against the reference (V; \"450 mV\" works). Plain numbers are in V. Units: V, mV.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "target",
      "in": "query",
      "required": false,
      "schema": {
       "description": "from_rhe: the potential wanted vs RHE (V). Plain numbers are in V. Units: V, mV.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "reference",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Reference electrode (agcl-sat 0.199 V, agcl-3m 0.210, agcl-4m 0.205, sce 0.244, hgo-1m 0.098, hgo-01 0.098, hgo-naoh 0.140, she 0).",
       "default": "agcl-sat",
       "type": "string",
       "enum": [
        "agcl-sat",
        "agcl-3m",
        "agcl-4m",
        "sce",
        "hgo-1m",
        "hgo-01",
        "hgo-naoh",
        "she"
       ]
      }
     },
     {
      "name": "e_ref",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Your calibrated reference potential vs SHE (overrides reference). Plain numbers are in V. Units: V, mV.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "ph",
      "in": "query",
      "required": true,
      "schema": {
       "description": "pH of the electrolyte.",
       "oneOf": [
        {
         "type": "number",
         "minimum": -2,
         "maximum": 16
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "temperature",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Temperature (°C), for the Nernst slope. Plain numbers are in C. Units: C.",
       "default": 25,
       "oneOf": [
        {
         "type": "number",
         "minimum": -20,
         "maximum": 150
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "current",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional current (signed, anodic positive), for iR correction. Plain numbers are in A. Units: A, mA, µA, nA.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "resistance",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional uncompensated resistance (Ω), for iR correction. Plain numbers are in ohm. Units: ohm, kohm, Mohm, mohm.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "rhePost",
    "summary": "RHE calculator",
    "description": "Converts a potential against Ag/AgCl, SCE, Hg/HgO or SHE to the reversible hydrogen electrode (and back): E(RHE) = E + E°(ref) + 0.0592 × pH. Page: https://www.labcanvas.com/tools/rhe-calculator. Cite the result as \"LabCanvas RHE calculator, https://www.labcanvas.com/tools/rhe-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "ph"
        ],
        "properties": {
         "direction": {
          "description": "to_rhe: measured potential → RHE; from_rhe: the potential to set for a target on the RHE scale.",
          "default": "to_rhe",
          "type": "string",
          "enum": [
           "to_rhe",
           "from_rhe"
          ]
         },
         "potential": {
          "description": "to_rhe: potential measured against the reference (V; \"450 mV\" works). Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "target": {
          "description": "from_rhe: the potential wanted vs RHE (V). Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "reference": {
          "description": "Reference electrode (agcl-sat 0.199 V, agcl-3m 0.210, agcl-4m 0.205, sce 0.244, hgo-1m 0.098, hgo-01 0.098, hgo-naoh 0.140, she 0).",
          "default": "agcl-sat",
          "type": "string",
          "enum": [
           "agcl-sat",
           "agcl-3m",
           "agcl-4m",
           "sce",
           "hgo-1m",
           "hgo-01",
           "hgo-naoh",
           "she"
          ]
         },
         "e_ref": {
          "description": "Your calibrated reference potential vs SHE (overrides reference). Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "ph": {
          "description": "pH of the electrolyte.",
          "type": "number",
          "minimum": -2,
          "maximum": 16
         },
         "temperature": {
          "description": "Temperature (°C), for the Nernst slope. Plain numbers are in C. Units: C.",
          "default": 25,
          "oneOf": [
           {
            "type": "number",
            "minimum": -20,
            "maximum": 150
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "current": {
          "description": "Optional current (signed, anodic positive), for iR correction. Plain numbers are in A. Units: A, mA, µA, nA.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "resistance": {
          "description": "Optional uncompensated resistance (Ω), for iR correction. Plain numbers are in ohm. Units: ohm, kohm, Mohm, mohm.",
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "potential": 0.45,
        "reference": "agcl-sat",
        "ph": 14
       }
      }
     }
    }
   }
  },
  "/api/tools/tafel-slope-calculator": {
   "get": {
    "operationId": "tafelSlope",
    "summary": "Tafel slope calculator",
    "description": "Tafel slope (mV/dec), exchange current density j₀ and α·n from a polarisation curve: least squares of η = a + b·log₁₀|j| over a chosen |η| range. Page: https://www.labcanvas.com/tools/tafel-slope-calculator. Cite the result as \"LabCanvas Tafel slope calculator, https://www.labcanvas.com/tools/tafel-slope-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "potential",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Potential of each point: V vs RHE (iR-corrected), or the overpotential when reaction = overpotential. Plain numbers are in V. Units: V, mV. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "current",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Current density of each point (any unit; j₀ is given in the same unit). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "reaction",
      "in": "query",
      "required": false,
      "schema": {
       "description": "oer (η = E − 1.23 V), her (η = E), custom (η = E − equilibrium), or overpotential (the potentials are η already).",
       "default": "oer",
       "type": "string",
       "enum": [
        "oer",
        "her",
        "custom",
        "overpotential"
       ]
      }
     },
     {
      "name": "equilibrium",
      "in": "query",
      "required": false,
      "schema": {
       "description": "custom: the equilibrium potential vs RHE. Plain numbers are in V. Units: V, mV.",
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "eta_min",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fit only points with |η| at or above this (mV). Plain numbers are in mV.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "eta_max",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fit only points with |η| at or below this (mV). Plain numbers are in mV.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "temperature",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Temperature (°C), for α·n. Plain numbers are in C. Units: C.",
       "default": 25,
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "tafelSlopePost",
    "summary": "Tafel slope calculator",
    "description": "Tafel slope (mV/dec), exchange current density j₀ and α·n from a polarisation curve: least squares of η = a + b·log₁₀|j| over a chosen |η| range. Page: https://www.labcanvas.com/tools/tafel-slope-calculator. Cite the result as \"LabCanvas Tafel slope calculator, https://www.labcanvas.com/tools/tafel-slope-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "potential",
         "current"
        ],
        "properties": {
         "potential": {
          "description": "Potential of each point: V vs RHE (iR-corrected), or the overpotential when reaction = overpotential. Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": [
              "number",
              "string"
             ]
            },
            "maxItems": 20000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "current": {
          "description": "Current density of each point (any unit; j₀ is given in the same unit).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 20000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "reaction": {
          "description": "oer (η = E − 1.23 V), her (η = E), custom (η = E − equilibrium), or overpotential (the potentials are η already).",
          "default": "oer",
          "type": "string",
          "enum": [
           "oer",
           "her",
           "custom",
           "overpotential"
          ]
         },
         "equilibrium": {
          "description": "custom: the equilibrium potential vs RHE. Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "eta_min": {
          "description": "Fit only points with |η| at or above this (mV). Plain numbers are in mV.",
          "type": "number",
          "minimum": 0
         },
         "eta_max": {
          "description": "Fit only points with |η| at or below this (mV). Plain numbers are in mV.",
          "type": "number",
          "minimum": 0
         },
         "temperature": {
          "description": "Temperature (°C), for α·n. Plain numbers are in C. Units: C.",
          "default": 25,
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "potential": "1.45,1.47,1.49,1.51,1.53,1.55,1.57,1.59,1.61",
        "current": "0.42,0.95,1.9,3.6,6.4,10.8,17.0,24.5,32.0",
        "eta_min": 260,
        "eta_max": 320
       }
      }
     }
    }
   }
  },
  "/api/tools/faradaic-efficiency-calculator": {
   "get": {
    "operationId": "faradaicEfficiency",
    "summary": "Faradaic efficiency calculator",
    "description": "Faradaic efficiency of an electrolysis product from its moles and the charge (FE = z·n·F/Q), or of a gas product from on-line GC (z·F·x·v·p / R·T·I). Page: https://www.labcanvas.com/tools/faradaic-efficiency-calculator. Cite the result as \"LabCanvas Faradaic efficiency calculator, https://www.labcanvas.com/tools/faradaic-efficiency-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "mode",
      "in": "query",
      "required": false,
      "schema": {
       "description": "moles: product amount and charge; gas: GC volume fraction in a flowing outlet.",
       "default": "moles",
       "type": "string",
       "enum": [
        "moles",
        "gas"
       ]
      }
     },
     {
      "name": "product",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Product (sets z): h2 2, o2 4, co 2, hcooh 2, ch4 8, nh3 8.",
       "type": "string",
       "enum": [
        "h2",
        "o2",
        "co",
        "hcooh",
        "ch4",
        "nh3"
       ]
      }
     },
     {
      "name": "z",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Electrons per molecule (overrides product).",
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 100
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "amount",
      "in": "query",
      "required": false,
      "schema": {
       "description": "moles: amount of product (e.g. \"120 µmol\"). Plain numbers are in mol. Units: mol, mmol, µmol, nmol, pmol.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "charge",
      "in": "query",
      "required": false,
      "schema": {
       "description": "moles: charge passed (C); or give current and time. Plain numbers are in C. Units: C, mC, mAh.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "current",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Current (A; \"10 mA\" works): with time (moles mode) or the total current (gas mode). Plain numbers are in A. Units: A, mA, µA, nA.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "time",
      "in": "query",
      "required": false,
      "schema": {
       "description": "moles: electrolysis time (s; \"1 h\" works). Plain numbers are in s. Units: s, min, h.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "fraction",
      "in": "query",
      "required": false,
      "schema": {
       "description": "gas: volume fraction of the product in the outlet gas (ppm, or \"1.8 %\"). Plain numbers are in ppm. Units: ppm, %.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "flow",
      "in": "query",
      "required": false,
      "schema": {
       "description": "gas: outlet flow rate (mL/min). Plain numbers are in mL/min. Units: mL/min, L/min, mL/s.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "pressure",
      "in": "query",
      "required": false,
      "schema": {
       "description": "gas: pressure (kPa). Plain numbers are in kPa. Units: kPa, bar, atm, Pa.",
       "default": 101.325,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "temperature",
      "in": "query",
      "required": false,
      "schema": {
       "description": "gas: temperature (°C). Plain numbers are in C. Units: C.",
       "default": 25,
       "oneOf": [
        {
         "type": "number"
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "faradaicEfficiencyPost",
    "summary": "Faradaic efficiency calculator",
    "description": "Faradaic efficiency of an electrolysis product from its moles and the charge (FE = z·n·F/Q), or of a gas product from on-line GC (z·F·x·v·p / R·T·I). Page: https://www.labcanvas.com/tools/faradaic-efficiency-calculator. Cite the result as \"LabCanvas Faradaic efficiency calculator, https://www.labcanvas.com/tools/faradaic-efficiency-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "mode": {
          "description": "moles: product amount and charge; gas: GC volume fraction in a flowing outlet.",
          "default": "moles",
          "type": "string",
          "enum": [
           "moles",
           "gas"
          ]
         },
         "product": {
          "description": "Product (sets z): h2 2, o2 4, co 2, hcooh 2, ch4 8, nh3 8.",
          "type": "string",
          "enum": [
           "h2",
           "o2",
           "co",
           "hcooh",
           "ch4",
           "nh3"
          ]
         },
         "z": {
          "description": "Electrons per molecule (overrides product).",
          "type": "integer",
          "minimum": 1,
          "maximum": 100
         },
         "amount": {
          "description": "moles: amount of product (e.g. \"120 µmol\"). Plain numbers are in mol. Units: mol, mmol, µmol, nmol, pmol.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "charge": {
          "description": "moles: charge passed (C); or give current and time. Plain numbers are in C. Units: C, mC, mAh.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "current": {
          "description": "Current (A; \"10 mA\" works): with time (moles mode) or the total current (gas mode). Plain numbers are in A. Units: A, mA, µA, nA.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "time": {
          "description": "moles: electrolysis time (s; \"1 h\" works). Plain numbers are in s. Units: s, min, h.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "fraction": {
          "description": "gas: volume fraction of the product in the outlet gas (ppm, or \"1.8 %\"). Plain numbers are in ppm. Units: ppm, %.",
          "oneOf": [
           {
            "type": "number",
            "minimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "flow": {
          "description": "gas: outlet flow rate (mL/min). Plain numbers are in mL/min. Units: mL/min, L/min, mL/s.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "pressure": {
          "description": "gas: pressure (kPa). Plain numbers are in kPa. Units: kPa, bar, atm, Pa.",
          "default": 101.325,
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "temperature": {
          "description": "gas: temperature (°C). Plain numbers are in C. Units: C.",
          "default": 25,
          "oneOf": [
           {
            "type": "number"
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "product": "h2",
        "amount": "120 µmol",
        "current": "10 mA",
        "time": "1 h"
       }
      }
     }
    }
   }
  },
  "/api/tools/supercapacitor-calculator": {
   "get": {
    "operationId": "supercapacitor",
    "summary": "Supercapacitor calculator",
    "description": "Specific capacitance from a galvanostatic discharge (C = I·Δt / m·ΔV), with energy and power density of a symmetric cell, and a battery C-rate current. Page: https://www.labcanvas.com/tools/supercapacitor-calculator. Cite the result as \"LabCanvas Supercapacitor calculator, https://www.labcanvas.com/tools/supercapacitor-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "current",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Discharge current (A; \"1 mA\" works). Plain numbers are in A. Units: A, mA, µA, nA.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "discharge_time",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Discharge time Δt (s). Plain numbers are in s. Units: s, min, h.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "voltage_window",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Voltage window ΔV with the IR drop removed (V). Plain numbers are in V. Units: V, mV.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "mass",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Active mass (g; \"2 mg\" works): both electrodes for a cell, one for an electrode. Plain numbers are in g. Units: kg, g, mg, µg, ng.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "setup",
      "in": "query",
      "required": false,
      "schema": {
       "description": "cell: symmetric two-electrode cell (gives per-electrode C, energy and power); electrode: three-electrode measurement.",
       "default": "cell",
       "type": "string",
       "enum": [
        "cell",
        "electrode"
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "supercapacitorPost",
    "summary": "Supercapacitor calculator",
    "description": "Specific capacitance from a galvanostatic discharge (C = I·Δt / m·ΔV), with energy and power density of a symmetric cell, and a battery C-rate current. Page: https://www.labcanvas.com/tools/supercapacitor-calculator. Cite the result as \"LabCanvas Supercapacitor calculator, https://www.labcanvas.com/tools/supercapacitor-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "current",
         "discharge_time",
         "voltage_window",
         "mass"
        ],
        "properties": {
         "current": {
          "description": "Discharge current (A; \"1 mA\" works). Plain numbers are in A. Units: A, mA, µA, nA.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "discharge_time": {
          "description": "Discharge time Δt (s). Plain numbers are in s. Units: s, min, h.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "voltage_window": {
          "description": "Voltage window ΔV with the IR drop removed (V). Plain numbers are in V. Units: V, mV.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "mass": {
          "description": "Active mass (g; \"2 mg\" works): both electrodes for a cell, one for an electrode. Plain numbers are in g. Units: kg, g, mg, µg, ng.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "setup": {
          "description": "cell: symmetric two-electrode cell (gives per-electrode C, energy and power); electrode: three-electrode measurement.",
          "default": "cell",
          "type": "string",
          "enum": [
           "cell",
           "electrode"
          ]
         }
        }
       },
       "example": {
        "current": "1 mA",
        "discharge_time": 100,
        "voltage_window": 0.95,
        "mass": "2 mg"
       }
      }
     }
    }
   }
  },
  "/api/tools/coulombic-efficiency-calculator": {
   "get": {
    "operationId": "coulombicEfficiency",
    "summary": "Coulombic efficiency calculator",
    "description": "Coulombic efficiency per cycle, first-cycle loss, average CE and capacity retention from charge and discharge capacities. Page: https://www.labcanvas.com/tools/coulombic-efficiency-calculator. Cite the result as \"LabCanvas Coulombic efficiency calculator, https://www.labcanvas.com/tools/coulombic-efficiency-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "charge",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Charge capacity of each cycle (mAh/g or any one unit). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "discharge",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Discharge capacity of each cycle, in the same unit and order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "cell",
      "in": "query",
      "required": false,
      "schema": {
       "description": "cathode (or full cell): CE = discharge / charge; anode half-cell (lithiation on discharge): CE = charge / discharge.",
       "default": "cathode",
       "type": "string",
       "enum": [
        "cathode",
        "anode"
       ]
      }
     },
     {
      "name": "reference_cycle",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Cycle whose output capacity is 100 % retention.",
       "default": 1,
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "coulombicEfficiencyPost",
    "summary": "Coulombic efficiency calculator",
    "description": "Coulombic efficiency per cycle, first-cycle loss, average CE and capacity retention from charge and discharge capacities. Page: https://www.labcanvas.com/tools/coulombic-efficiency-calculator. Cite the result as \"LabCanvas Coulombic efficiency calculator, https://www.labcanvas.com/tools/coulombic-efficiency-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "charge",
         "discharge"
        ],
        "properties": {
         "charge": {
          "description": "Charge capacity of each cycle (mAh/g or any one unit).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 10000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "discharge": {
          "description": "Discharge capacity of each cycle, in the same unit and order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 10000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "cell": {
          "description": "cathode (or full cell): CE = discharge / charge; anode half-cell (lithiation on discharge): CE = charge / discharge.",
          "default": "cathode",
          "type": "string",
          "enum": [
           "cathode",
           "anode"
          ]
         },
         "reference_cycle": {
          "description": "Cycle whose output capacity is 100 % retention.",
          "default": 1,
          "type": "integer",
          "minimum": 1
         }
        }
       },
       "example": {
        "charge": "228.4,203.5,202.1,201.0",
        "discharge": "201.6,201.2,200.4,199.6"
       }
      }
     }
    }
   }
  },
  "/api/tools/ionic-conductivity-calculator": {
   "get": {
    "operationId": "ionicConductivity",
    "summary": "Ionic conductivity calculator",
    "description": "Ionic conductivity of a pellet or membrane from its bulk resistance (EIS), thickness and area: σ = L / (R·A). Page: https://www.labcanvas.com/tools/ionic-conductivity-calculator. Cite the result as \"LabCanvas Ionic conductivity calculator, https://www.labcanvas.com/tools/ionic-conductivity-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "thickness",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Sample thickness L (cm; \"1.05 mm\" works). Plain numbers are in cm. Units: cm, mm, µm, m.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "resistance",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Bulk resistance R from the impedance spectrum (Ω). Plain numbers are in ohm. Units: ohm, kohm, Mohm, mohm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "area",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Electrode area A (cm²); or give diameter. Plain numbers are in cm². Units: cm², mm².",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "diameter",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Electrode diameter (cm; \"10 mm\" works), for a round electrode. Plain numbers are in cm. Units: cm, mm, µm, m.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "ionicConductivityPost",
    "summary": "Ionic conductivity calculator",
    "description": "Ionic conductivity of a pellet or membrane from its bulk resistance (EIS), thickness and area: σ = L / (R·A). Page: https://www.labcanvas.com/tools/ionic-conductivity-calculator. Cite the result as \"LabCanvas Ionic conductivity calculator, https://www.labcanvas.com/tools/ionic-conductivity-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "thickness",
         "resistance"
        ],
        "properties": {
         "thickness": {
          "description": "Sample thickness L (cm; \"1.05 mm\" works). Plain numbers are in cm. Units: cm, mm, µm, m.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "resistance": {
          "description": "Bulk resistance R from the impedance spectrum (Ω). Plain numbers are in ohm. Units: ohm, kohm, Mohm, mohm.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "area": {
          "description": "Electrode area A (cm²); or give diameter. Plain numbers are in cm². Units: cm², mm².",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "diameter": {
          "description": "Electrode diameter (cm; \"10 mm\" works), for a round electrode. Plain numbers are in cm. Units: cm, mm, µm, m.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         }
        }
       },
       "example": {
        "thickness": "1.05 mm",
        "resistance": 357.04,
        "diameter": "10 mm"
       }
      }
     }
    }
   }
  },
  "/api/tools/xrd-scherrer-calculator": {
   "get": {
    "operationId": "xrdScherrer",
    "summary": "XRD Scherrer calculator",
    "description": "Crystallite size by the Scherrer equation (D = Kλ / β cos θ) and d-spacing by Bragg’s law for one peak or a list, with instrumental broadening removed. Page: https://www.labcanvas.com/tools/xrd-scherrer-calculator. Cite the result as \"LabCanvas XRD Scherrer calculator, https://www.labcanvas.com/tools/xrd-scherrer-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "two_theta",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Peak position(s) 2θ in degrees. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "fwhm",
      "in": "query",
      "required": true,
      "schema": {
       "description": "FWHM of each peak in degrees 2θ. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "wavelength",
      "in": "query",
      "required": false,
      "schema": {
       "description": "X-ray wavelength (Å); Cu Kα1 1.54056. Plain numbers are in Å. Units: Å, A, nm.",
       "default": 1.54056,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "k",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Shape factor K (0.9 common, 0.94 spheres).",
       "default": 0.9,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "instrumental",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Instrumental FWHM (degrees), removed in quadrature.",
       "default": 0,
       "oneOf": [
        {
         "type": "number",
         "minimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "xrdScherrerPost",
    "summary": "XRD Scherrer calculator",
    "description": "Crystallite size by the Scherrer equation (D = Kλ / β cos θ) and d-spacing by Bragg’s law for one peak or a list, with instrumental broadening removed. Page: https://www.labcanvas.com/tools/xrd-scherrer-calculator. Cite the result as \"LabCanvas XRD Scherrer calculator, https://www.labcanvas.com/tools/xrd-scherrer-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "two_theta",
         "fwhm"
        ],
        "properties": {
         "two_theta": {
          "description": "Peak position(s) 2θ in degrees.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 200
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "fwhm": {
          "description": "FWHM of each peak in degrees 2θ.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 200
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "wavelength": {
          "description": "X-ray wavelength (Å); Cu Kα1 1.54056. Plain numbers are in Å. Units: Å, A, nm.",
          "default": 1.54056,
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "k": {
          "description": "Shape factor K (0.9 common, 0.94 spheres).",
          "default": 0.9,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "instrumental": {
          "description": "Instrumental FWHM (degrees), removed in quadrature.",
          "default": 0,
          "type": "number",
          "minimum": 0
         }
        }
       },
       "example": {
        "two_theta": 36.3,
        "fwhm": 0.4
       }
      }
     }
    }
   }
  },
  "/api/tools/bet-surface-area-calculator": {
   "get": {
    "operationId": "betSurfaceArea",
    "summary": "BET surface area calculator",
    "description": "BET specific surface area from an adsorption isotherm, with the fitting range chosen by the Rouquerol consistency criteria (ISO 9277). Page: https://www.labcanvas.com/tools/bet-surface-area-calculator. Cite the result as \"LabCanvas BET surface area calculator, https://www.labcanvas.com/tools/bet-surface-area-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "p_p0",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Relative pressure p/p₀ of each point. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "amount",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Amount adsorbed at each point (per gram), in amount_unit. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "amount_unit",
      "in": "query",
      "required": false,
      "schema": {
       "description": "cm3 (cm³ STP/g), mmol (mmol/g) or mg (mg/g).",
       "default": "cm3",
       "type": "string",
       "enum": [
        "cm3",
        "mmol",
        "mg"
       ]
      }
     },
     {
      "name": "adsorbate",
      "in": "query",
      "required": false,
      "schema": {
       "description": "N₂ at 77 K (σ 0.162 nm²), Ar at 87 K (0.142 nm²), or custom.",
       "default": "n2",
       "type": "string",
       "enum": [
        "n2",
        "ar",
        "custom"
       ]
      }
     },
     {
      "name": "sigma",
      "in": "query",
      "required": false,
      "schema": {
       "description": "custom: cross-sectional area (nm²). Plain numbers are in nm².",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "molar_mass",
      "in": "query",
      "required": false,
      "schema": {
       "description": "custom with mg/g: molar mass of the adsorbate. Plain numbers are in g/mol.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "range_min",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fit p/p₀ from this value (with range_max); else the range is chosen automatically.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0,
         "maximum": 1
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "range_max",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Fit p/p₀ up to this value.",
       "oneOf": [
        {
         "type": "number",
         "minimum": 0,
         "maximum": 1
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "betSurfaceAreaPost",
    "summary": "BET surface area calculator",
    "description": "BET specific surface area from an adsorption isotherm, with the fitting range chosen by the Rouquerol consistency criteria (ISO 9277). Page: https://www.labcanvas.com/tools/bet-surface-area-calculator. Cite the result as \"LabCanvas BET surface area calculator, https://www.labcanvas.com/tools/bet-surface-area-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "p_p0",
         "amount"
        ],
        "properties": {
         "p_p0": {
          "description": "Relative pressure p/p₀ of each point.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 2000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "amount": {
          "description": "Amount adsorbed at each point (per gram), in amount_unit.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 2000
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "amount_unit": {
          "description": "cm3 (cm³ STP/g), mmol (mmol/g) or mg (mg/g).",
          "default": "cm3",
          "type": "string",
          "enum": [
           "cm3",
           "mmol",
           "mg"
          ]
         },
         "adsorbate": {
          "description": "N₂ at 77 K (σ 0.162 nm²), Ar at 87 K (0.142 nm²), or custom.",
          "default": "n2",
          "type": "string",
          "enum": [
           "n2",
           "ar",
           "custom"
          ]
         },
         "sigma": {
          "description": "custom: cross-sectional area (nm²). Plain numbers are in nm².",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "molar_mass": {
          "description": "custom with mg/g: molar mass of the adsorbate. Plain numbers are in g/mol.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "range_min": {
          "description": "Fit p/p₀ from this value (with range_max); else the range is chosen automatically.",
          "type": "number",
          "minimum": 0,
          "maximum": 1
         },
         "range_max": {
          "description": "Fit p/p₀ up to this value.",
          "type": "number",
          "minimum": 0,
          "maximum": 1
         }
        }
       },
       "example": {
        "p_p0": "0.05,0.075,0.1,0.125,0.15,0.175,0.2,0.225,0.25,0.275,0.3",
        "amount": "99.1331,107.8547,114.2406,119.7009,124.7764,129.7267,134.6995,139.7914,145.0744,150.6087,156.4495"
       }
      }
     }
    }
   }
  },
  "/api/tools/astm-grain-size-calculator": {
   "get": {
    "operationId": "astmGrainSize",
    "summary": "ASTM grain size calculator",
    "description": "ASTM E112 grain size number G from the mean lineal intercept, grains per mm², mean grain area or grains per square inch at 100×, and everything G stands for. Page: https://www.labcanvas.com/tools/astm-grain-size-calculator. Cite the result as \"LabCanvas ASTM grain size calculator, https://www.labcanvas.com/tools/astm-grain-size-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "intercept",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Mean lineal intercept length ℓ̄ (mm; \"20 µm\" works). Plain numbers are in mm. Units: mm, µm, nm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "grains_per_mm2",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Grains per mm² at 1× (N_A).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "mean_area",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Mean grain area (mm²; \"500 µm²\" works). Plain numbers are in mm². Units: mm², µm², nm².",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "grains_per_in2_100x",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Grains per square inch at 100× (N).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "g",
      "in": "query",
      "required": false,
      "schema": {
       "description": "A grain size number, to get what it stands for.",
       "oneOf": [
        {
         "type": "number",
         "minimum": -5,
         "maximum": 20
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "astmGrainSizePost",
    "summary": "ASTM grain size calculator",
    "description": "ASTM E112 grain size number G from the mean lineal intercept, grains per mm², mean grain area or grains per square inch at 100×, and everything G stands for. Page: https://www.labcanvas.com/tools/astm-grain-size-calculator. Cite the result as \"LabCanvas ASTM grain size calculator, https://www.labcanvas.com/tools/astm-grain-size-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "intercept": {
          "description": "Mean lineal intercept length ℓ̄ (mm; \"20 µm\" works). Plain numbers are in mm. Units: mm, µm, nm.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "grains_per_mm2": {
          "description": "Grains per mm² at 1× (N_A).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "mean_area": {
          "description": "Mean grain area (mm²; \"500 µm²\" works). Plain numbers are in mm². Units: mm², µm², nm².",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "grains_per_in2_100x": {
          "description": "Grains per square inch at 100× (N).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "g": {
          "description": "A grain size number, to get what it stands for.",
          "type": "number",
          "minimum": -5,
          "maximum": 20
         }
        }
       },
       "example": {
        "intercept": "0.020 mm"
       }
      }
     }
    }
   }
  },
  "/api/tools/microscope-pixel-size-calculator": {
   "get": {
    "operationId": "microscopePixelSize",
    "summary": "Microscope pixel size calculator",
    "description": "Pixel size in the specimen from the camera pixel, objective, extra magnification and binning, or from a calibration; field of view and Nyquist sampling. Page: https://www.labcanvas.com/tools/microscope-pixel-size-calculator. Cite the result as \"LabCanvas Microscope pixel size calculator, https://www.labcanvas.com/tools/microscope-pixel-size-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "camera_pixel",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Camera (sensor) pixel size (µm). Plain numbers are in µm. Units: nm, µm, mm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "objective",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Objective magnification (e.g. 20, 63).",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "extra",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Further magnification between objective and camera (camera adapter, 1 when none).",
       "default": 1,
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "binning",
      "in": "query",
      "required": false,
      "schema": {
       "description": "On-chip binning (1, 2, 4…).",
       "default": 1,
       "oneOf": [
        {
         "type": "integer",
         "minimum": 1,
         "maximum": 16
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "known_length",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Calibration: a known length (e.g. \"100 µm\" of a stage micrometer). Plain numbers are in µm. Units: nm, µm, mm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number with a unit, e.g. \"5 mM\""
        }
       ]
      }
     },
     {
      "name": "pixels",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Calibration: the number of pixels that length spans.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "sensor_width_px",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional sensor width in pixels, for the field of view.",
       "oneOf": [
        {
         "type": "integer",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "sensor_height_px",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional sensor height in pixels.",
       "oneOf": [
        {
         "type": "integer",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "wavelength",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional emission wavelength (nm), with na, for Nyquist sampling. Plain numbers are in nm.",
       "oneOf": [
        {
         "type": "number",
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     },
     {
      "name": "na",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Optional numerical aperture of the objective.",
       "oneOf": [
        {
         "type": "number",
         "maximum": 1.7,
         "exclusiveMinimum": 0
        },
        {
         "type": "string",
         "description": "A number"
        }
       ]
      }
     }
    ]
   },
   "post": {
    "operationId": "microscopePixelSizePost",
    "summary": "Microscope pixel size calculator",
    "description": "Pixel size in the specimen from the camera pixel, objective, extra magnification and binning, or from a calibration; field of view and Nyquist sampling. Page: https://www.labcanvas.com/tools/microscope-pixel-size-calculator. Cite the result as \"LabCanvas Microscope pixel size calculator, https://www.labcanvas.com/tools/microscope-pixel-size-calculator\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {
         "camera_pixel": {
          "description": "Camera (sensor) pixel size (µm). Plain numbers are in µm. Units: nm, µm, mm.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "objective": {
          "description": "Objective magnification (e.g. 20, 63).",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "extra": {
          "description": "Further magnification between objective and camera (camera adapter, 1 when none).",
          "default": 1,
          "type": "number",
          "exclusiveMinimum": 0
         },
         "binning": {
          "description": "On-chip binning (1, 2, 4…).",
          "default": 1,
          "type": "integer",
          "minimum": 1,
          "maximum": 16
         },
         "known_length": {
          "description": "Calibration: a known length (e.g. \"100 µm\" of a stage micrometer). Plain numbers are in µm. Units: nm, µm, mm.",
          "oneOf": [
           {
            "type": "number",
            "exclusiveMinimum": 0
           },
           {
            "type": "string",
            "description": "A number with a unit, e.g. \"5 mM\""
           }
          ]
         },
         "pixels": {
          "description": "Calibration: the number of pixels that length spans.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "sensor_width_px": {
          "description": "Optional sensor width in pixels, for the field of view.",
          "type": "integer",
          "exclusiveMinimum": 0
         },
         "sensor_height_px": {
          "description": "Optional sensor height in pixels.",
          "type": "integer",
          "exclusiveMinimum": 0
         },
         "wavelength": {
          "description": "Optional emission wavelength (nm), with na, for Nyquist sampling. Plain numbers are in nm.",
          "type": "number",
          "exclusiveMinimum": 0
         },
         "na": {
          "description": "Optional numerical aperture of the objective.",
          "type": "number",
          "maximum": 1.7,
          "exclusiveMinimum": 0
         }
        }
       },
       "example": {
        "camera_pixel": 6.5,
        "objective": 20
       }
      }
     }
    }
   }
  },
  "/api/tools/protein-assay-standard-curve": {
   "get": {
    "operationId": "proteinAssayStandardCurve",
    "summary": "Protein assay standard curve (BCA, Bradford)",
    "description": "Protein concentration of samples from a BCA or Bradford standard curve: blank subtraction, linear or quadratic least-squares fit, dilution factors and range flags. Page: https://www.labcanvas.com/tools/protein-assay-standard-curve. Cite the result as \"LabCanvas Protein assay standard curve (BCA, Bradford), https://www.labcanvas.com/tools/protein-assay-standard-curve\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "standards",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Standard concentration of each standard well (repeat for replicates; include 0 for the blank). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "standard_abs",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Absorbance of each standard well, in the same order. Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "sample_abs",
      "in": "query",
      "required": true,
      "schema": {
       "description": "Absorbance of each sample (one value per sample; average replicates first). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "dilution",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Dilution factor of each sample (default 1). Comma-separated list.",
       "type": "string"
      }
     },
     {
      "name": "model",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Curve: quadratic (BCA over a wide range) or linear.",
       "default": "quadratic",
       "type": "string",
       "enum": [
        "quadratic",
        "linear"
       ]
      }
     },
     {
      "name": "blank",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Subtract the mean absorbance of the 0 standard from every well.",
       "default": true,
       "type": "boolean"
      }
     },
     {
      "name": "unit",
      "in": "query",
      "required": false,
      "schema": {
       "description": "Unit of the standards (answer text only).",
       "default": "µg/mL",
       "type": "string"
      }
     }
    ]
   },
   "post": {
    "operationId": "proteinAssayStandardCurvePost",
    "summary": "Protein assay standard curve (BCA, Bradford)",
    "description": "Protein concentration of samples from a BCA or Bradford standard curve: blank subtraction, linear or quadratic least-squares fit, dilution factors and range flags. Page: https://www.labcanvas.com/tools/protein-assay-standard-curve. Cite the result as \"LabCanvas Protein assay standard curve (BCA, Bradford), https://www.labcanvas.com/tools/protein-assay-standard-curve\".",
    "tags": [
     "calculators"
    ],
    "responses": {
     "200": {
      "description": "The result",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Result"
        }
       }
      }
     },
     "400": {
      "description": "Invalid input",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "type": "object",
        "additionalProperties": false,
        "required": [
         "standards",
         "standard_abs",
         "sample_abs"
        ],
        "properties": {
         "standards": {
          "description": "Standard concentration of each standard well (repeat for replicates; include 0 for the blank).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 200
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "standard_abs": {
          "description": "Absorbance of each standard well, in the same order.",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 200
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "sample_abs": {
          "description": "Absorbance of each sample (one value per sample; average replicates first).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 500
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "dilution": {
          "description": "Dilution factor of each sample (default 1).",
          "oneOf": [
           {
            "type": "array",
            "items": {
             "type": "number"
            },
            "maxItems": 500
           },
           {
            "type": "string",
            "description": "Comma-separated list"
           },
           {
            "type": "number",
            "description": "A single value"
           }
          ]
         },
         "model": {
          "description": "Curve: quadratic (BCA over a wide range) or linear.",
          "default": "quadratic",
          "type": "string",
          "enum": [
           "quadratic",
           "linear"
          ]
         },
         "blank": {
          "description": "Subtract the mean absorbance of the 0 standard from every well.",
          "default": true,
          "type": "boolean"
         },
         "unit": {
          "description": "Unit of the standards (answer text only).",
          "default": "µg/mL",
          "type": "string"
         }
        }
       },
       "example": {
        "standards": "0,25,125,250,500,750,1000,1500,2000",
        "standard_abs": "0.095,0.130,0.235,0.375,0.640,0.890,1.120,1.560,1.950",
        "sample_abs": "0.700,1.200",
        "dilution": "5,1"
       }
      }
     }
    }
   }
  }
 },
 "components": {
  "schemas": {
   "Value": {
    "type": "object",
    "properties": {
     "label": {
      "type": "string"
     },
     "value": {
      "type": [
       "number",
       "string",
       "boolean",
       "null"
      ]
     },
     "unit": {
      "type": "string"
     }
    },
    "required": [
     "label",
     "value"
    ]
   },
   "Result": {
    "type": "object",
    "required": [
     "ok",
     "tool",
     "inputs",
     "result",
     "answer",
     "formula",
     "page",
     "citation"
    ],
    "properties": {
     "ok": {
      "const": true
     },
     "tool": {
      "type": "string",
      "description": "The calculator slug"
     },
     "title": {
      "type": "string"
     },
     "inputs": {
      "type": "object",
      "description": "The inputs as used, normalised, with units",
      "additionalProperties": {
       "type": "object",
       "properties": {
        "value": {},
        "unit": {
         "type": "string"
        }
       }
      }
     },
     "result": {
      "type": "object",
      "additionalProperties": {
       "$ref": "#/components/schemas/Value"
      }
     },
     "answer": {
      "type": "string",
      "description": "The answer in one sentence"
     },
     "formula": {
      "type": "string"
     },
     "table": {
      "type": "object",
      "properties": {
       "columns": {
        "type": "array",
        "items": {
         "type": "string"
        }
       },
       "rows": {
        "type": "array",
        "items": {
         "type": "array"
        }
       }
      }
     },
     "notes": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "page": {
      "type": "string",
      "format": "uri"
     },
     "markdown": {
      "type": "string",
      "format": "uri"
     },
     "citation": {
      "type": "string"
     }
    }
   },
   "Error": {
    "type": "object",
    "required": [
     "ok",
     "error",
     "message"
    ],
    "properties": {
     "ok": {
      "const": false
     },
     "error": {
      "type": "string"
     },
     "message": {
      "type": "string"
     },
     "param": {
      "type": "string"
     },
     "params": {
      "type": "array",
      "items": {
       "type": "object"
      }
     },
     "example": {
      "type": "string"
     }
    }
   }
  }
 }
}