{
  "x402Version": 2,
  "id": 39269,
  "slug": "39269",
  "resource": "https://api.magentlab.com/api/calc/cambridge_diabetes",
  "description": "Griffin 2000 Cambridge logistic risk of undetected type 2 diabetes. p = 1/(1+e^(-λ)); λ = -6.322 - 0.879 if female + 1.222 antihypertensive + 2.191 steroids + 0.063×age + BMI band (<25 0; 25 to <27.5 0.699; 27.5 to <30 1.97; ≥30 2.518) + family (parent or sibling 0.728; parent and sibling 0.753) + smoking (former -0.218; current 0.855). Age 40-64. Probability 0-1. Not FINDRISC, not ADA, not a glucose assay, not a diagnosis.",
  "type": "http",
  "serviceName": "magent",
  "resourceType": "Agent Service",
  "accepts": [
    {
      "scheme": "exact",
      "network": "eip155:8453",
      "payTo": "0x836Be278f1739fB4308091cD1852F7971Bc19Ee2",
      "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "amount": "5000",
      "amountUsd": 0.005,
      "maxTimeoutSeconds": 600
    }
  ],
  "outputSchema": {
    "properties": {
      "example": {
        "type": "object"
      },
      "type": {
        "type": "string"
      }
    },
    "required": [
      "type"
    ],
    "type": "object"
  },
  "extensions": {
    "bazaar": {
      "info": {
        "iconUrl": "https://api.magentlab.com/favicon.ico",
        "input": {
          "body": {
            "items": [
              {
                "age": 50,
                "antihypertensive": false,
                "bmi_kg_m2": 24,
                "family_history": "none",
                "sex": "male",
                "smoking": "never",
                "steroids": false
              },
              {
                "age": 50,
                "antihypertensive": false,
                "bmi_kg_m2": 24,
                "family_history": "none",
                "sex": "male",
                "smoking": "never",
                "steroids": false
              }
            ]
          },
          "method": "POST",
          "type": "http"
        },
        "output": {
          "example": {
            "count": 2,
            "items": [
              {
                "age_years": 50,
                "antihypertensive": false,
                "bmi_kg_m2": 24,
                "citation": {
                  "authors": "Griffin SJ, Little PS, Hales CN, Kinmonth AL, Wareham NJ",
                  "doi": "10.1002/1520-7560(200005/06)16:3<164::AID-DMRR103>3.0.CO;2-R",
                  "id": "griffin-2000",
                  "pmid": "10867715",
                  "source": "Diabetes Metab Res Rev. 2000;16(3):164-171",
                  "title": "Diabetes risk score: towards earlier detection of type 2 diabetes in general practice"
                },
                "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
                "family_history": "none",
                "formula": "cambridge_diabetes",
                "formula_expression": "p = 1/(1+e^(-λ)); λ = -6.322 -0.879*(sex=female) + 1.222*antihypertensive + 2.191*steroids + 0.063*age + bmi + family + smoking; BMI <25 -> 0, >=25 and <27.5 -> 0.699, >=27.5 and <30 -> 1.97, >=30 -> 2.518; family none 0, parent_or_sibling 0.728, parent_and_sibling 0.753; smoking never 0, former -0.218, current 0.855; Griffin 2000 logistic risk of undetected type 2 diabetes; age 40-64",
                "linear_predictor": -3.172,
                "probability": 0.0402,
                "sex": "male",
                "smoking": "never",
                "steroids": false
              },
              {
                "age_years": 50,
                "antihypertensive": false,
                "bmi_kg_m2": 24,
                "citation": {
                  "authors": "Griffin SJ, Little PS, Hales CN, Kinmonth AL, Wareham NJ",
                  "doi": "10.1002/1520-7560(200005/06)16:3<164::AID-DMRR103>3.0.CO;2-R",
                  "id": "griffin-2000",
                  "pmid": "10867715",
                  "source": "Diabetes Metab Res Rev. 2000;16(3):164-171",
                  "title": "Diabetes risk score: towards earlier detection of type 2 diabetes in general practice"
                },
                "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
                "family_history": "none",
                "formula": "cambridge_diabetes",
                "formula_expression": "p = 1/(1+e^(-λ)); λ = -6.322 -0.879*(sex=female) + 1.222*antihypertensive + 2.191*steroids + 0.063*age + bmi + family + smoking; BMI <25 -> 0, >=25 and <27.5 -> 0.699, >=27.5 and <30 -> 1.97, >=30 -> 2.518; family none 0, parent_or_sibling 0.728, parent_and_sibling 0.753; smoking never 0, former -0.218, current 0.855; Griffin 2000 logistic risk of undetected type 2 diabetes; age 40-64",
                "linear_predictor": -3.172,
                "probability": 0.0402,
                "sex": "male",
                "smoking": "never",
                "steroids": false
              }
            ],
            "path": "/api/calc/cambridge_diabetes"
          },
          "type": "json"
        }
      },
      "schema": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "properties": {
          "input": {
            "additionalProperties": false,
            "properties": {
              "body": {
                "additionalProperties": false,
                "properties": {
                  "items": {
                    "items": {
                      "properties": {
                        "age": {
                          "description": "Age in years. Griffin 2000 derivation was ages 40-64; magent accepts that published range only. Continuous linear predictor at 0.063 per year.",
                          "type": "integer"
                        },
                        "antihypertensive": {
                          "description": "Prescribed antihypertensive medication as assigned by the caller (Griffin 2000). true adds 1.222; false adds 0. magent does not read a medication list.",
                          "type": "boolean"
                        },
                        "bmi_kg_m2": {
                          "description": "Body-mass index in kg/m^2 (10-80, magent clamp). Caller-supplied; magent does not compute BMI from height and weight. Griffin 2000: <25 -> 0; >=25 and <27.5 -> 0.699; >=27.5 and <30 -> 1.97; >=30 -> 2.518.",
                          "type": "number"
                        },
                        "family_history": {
                          "description": "First-degree family history of diabetes (Griffin 2000). none 0; parent_or_sibling 0.728 (parent or sibling, not both); parent_and_sibling 0.753 (parent and sibling). magent does not take a pedigree.",
                          "enum": [
                            "none",
                            "parent_or_sibling",
                            "parent_and_sibling"
                          ],
                          "type": "string"
                        },
                        "sex": {
                          "description": "female or male. Griffin 2000 female coefficient is -0.879; male is the reference (0).",
                          "enum": [
                            "female",
                            "male"
                          ],
                          "type": "string"
                        },
                        "smoking": {
                          "description": "Smoking history (Griffin 2000). never (nonsmoker) 0; former (ex-smoker) -0.218; current 0.855. magent does not take a smoking history.",
                          "enum": [
                            "never",
                            "former",
                            "current"
                          ],
                          "type": "string"
                        },
                        "steroids": {
                          "description": "Prescribed steroids as assigned by the caller (Griffin 2000). true adds 2.191; false adds 0. magent does not read a medication list.",
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "age",
                        "sex",
                        "bmi_kg_m2",
                        "antihypertensive",
                        "steroids",
                        "family_history",
                        "smoking"
                      ],
                      "type": "object"
                    },
                    "maxItems": 25,
                    "minItems": 1,
                    "type": "array"
                  }
                },
                "required": [
                  "items"
                ],
                "type": "object"
              },
              "headers": {
                "additionalProperties": {
                  "type": "string"
                },
                "type": "object"
              },
              "method": {
                "const": "POST",
                "type": "string"
              },
              "type": {
                "const": "http",
                "type": "string"
              }
            },
            "required": [
              "type",
              "method"
            ],
            "type": "object"
          },
          "output": {
            "properties": {
              "example": {
                "type": "object"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "type": "object"
          }
        },
        "required": [
          "input"
        ],
        "type": "object"
      }
    }
  },
  "tags": [
    "cambridge-diabetes",
    "diabetes-risk",
    "glucose",
    "calculator",
    "bazaar"
  ],
  "sourceHost": "api.magentlab.com",
  "lastUpdated": "2026-10-13T00:56:41.871Z",
  "quality": {
    "calls30d": 5,
    "uniquePayers30d": 2,
    "lastCalledAt": "2026-10-13T00:56:41.703Z"
  },
  "metadata": {
    "serviceName": "magent",
    "extensions": {
      "bazaar": {
        "info": {
          "iconUrl": "https://api.magentlab.com/favicon.ico",
          "input": {
            "body": {
              "items": [
                {
                  "age": 50,
                  "antihypertensive": false,
                  "bmi_kg_m2": 24,
                  "family_history": "none",
                  "sex": "male",
                  "smoking": "never",
                  "steroids": false
                },
                {
                  "age": 50,
                  "antihypertensive": false,
                  "bmi_kg_m2": 24,
                  "family_history": "none",
                  "sex": "male",
                  "smoking": "never",
                  "steroids": false
                }
              ]
            },
            "method": "POST",
            "type": "http"
          },
          "output": {
            "example": {
              "count": 2,
              "items": [
                {
                  "age_years": 50,
                  "antihypertensive": false,
                  "bmi_kg_m2": 24,
                  "citation": {
                    "authors": "Griffin SJ, Little PS, Hales CN, Kinmonth AL, Wareham NJ",
                    "doi": "10.1002/1520-7560(200005/06)16:3<164::AID-DMRR103>3.0.CO;2-R",
                    "id": "griffin-2000",
                    "pmid": "10867715",
                    "source": "Diabetes Metab Res Rev. 2000;16(3):164-171",
                    "title": "Diabetes risk score: towards earlier detection of type 2 diabetes in general practice"
                  },
                  "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
                  "family_history": "none",
                  "formula": "cambridge_diabetes",
                  "formula_expression": "p = 1/(1+e^(-λ)); λ = -6.322 -0.879*(sex=female) + 1.222*antihypertensive + 2.191*steroids + 0.063*age + bmi + family + smoking; BMI <25 -> 0, >=25 and <27.5 -> 0.699, >=27.5 and <30 -> 1.97, >=30 -> 2.518; family none 0, parent_or_sibling 0.728, parent_and_sibling 0.753; smoking never 0, former -0.218, current 0.855; Griffin 2000 logistic risk of undetected type 2 diabetes; age 40-64",
                  "linear_predictor": -3.172,
                  "probability": 0.0402,
                  "sex": "male",
                  "smoking": "never",
                  "steroids": false
                },
                {
                  "age_years": 50,
                  "antihypertensive": false,
                  "bmi_kg_m2": 24,
                  "citation": {
                    "authors": "Griffin SJ, Little PS, Hales CN, Kinmonth AL, Wareham NJ",
                    "doi": "10.1002/1520-7560(200005/06)16:3<164::AID-DMRR103>3.0.CO;2-R",
                    "id": "griffin-2000",
                    "pmid": "10867715",
                    "source": "Diabetes Metab Res Rev. 2000;16(3):164-171",
                    "title": "Diabetes risk score: towards earlier detection of type 2 diabetes in general practice"
                  },
                  "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
                  "family_history": "none",
                  "formula": "cambridge_diabetes",
                  "formula_expression": "p = 1/(1+e^(-λ)); λ = -6.322 -0.879*(sex=female) + 1.222*antihypertensive + 2.191*steroids + 0.063*age + bmi + family + smoking; BMI <25 -> 0, >=25 and <27.5 -> 0.699, >=27.5 and <30 -> 1.97, >=30 -> 2.518; family none 0, parent_or_sibling 0.728, parent_and_sibling 0.753; smoking never 0, former -0.218, current 0.855; Griffin 2000 logistic risk of undetected type 2 diabetes; age 40-64",
                  "linear_predictor": -3.172,
                  "probability": 0.0402,
                  "sex": "male",
                  "smoking": "never",
                  "steroids": false
                }
              ],
              "path": "/api/calc/cambridge_diabetes"
            },
            "type": "json"
          }
        },
        "schema": {
          "$schema": "https://json-schema.org/draft/2020-12/schema",
          "properties": {
            "input": {
              "additionalProperties": false,
              "properties": {
                "body": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "properties": {
                          "age": {
                            "description": "Age in years. Griffin 2000 derivation was ages 40-64; magent accepts that published range only. Continuous linear predictor at 0.063 per year.",
                            "type": "integer"
                          },
                          "antihypertensive": {
                            "description": "Prescribed antihypertensive medication as assigned by the caller (Griffin 2000). true adds 1.222; false adds 0. magent does not read a medication list.",
                            "type": "boolean"
                          },
                          "bmi_kg_m2": {
                            "description": "Body-mass index in kg/m^2 (10-80, magent clamp). Caller-supplied; magent does not compute BMI from height and weight. Griffin 2000: <25 -> 0; >=25 and <27.5 -> 0.699; >=27.5 and <30 -> 1.97; >=30 -> 2.518.",
                            "type": "number"
                          },
                          "family_history": {
                            "description": "First-degree family history of diabetes (Griffin 2000). none 0; parent_or_sibling 0.728 (parent or sibling, not both); parent_and_sibling 0.753 (parent and sibling). magent does not take a pedigree.",
                            "enum": [
                              "none",
                              "parent_or_sibling",
                              "parent_and_sibling"
                            ],
                            "type": "string"
                          },
                          "sex": {
                            "description": "female or male. Griffin 2000 female coefficient is -0.879; male is the reference (0).",
                            "enum": [
                              "female",
                              "male"
                            ],
                            "type": "string"
                          },
                          "smoking": {
                            "description": "Smoking history (Griffin 2000). never (nonsmoker) 0; former (ex-smoker) -0.218; current 0.855. magent does not take a smoking history.",
                            "enum": [
                              "never",
                              "former",
                              "current"
                            ],
                            "type": "string"
                          },
                          "steroids": {
                            "description": "Prescribed steroids as assigned by the caller (Griffin 2000). true adds 2.191; false adds 0. magent does not read a medication list.",
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "age",
                          "sex",
                          "bmi_kg_m2",
                          "antihypertensive",
                          "steroids",
                          "family_history",
                          "smoking"
                        ],
                        "type": "object"
                      },
                      "maxItems": 25,
                      "minItems": 1,
                      "type": "array"
                    }
                  },
                  "required": [
                    "items"
                  ],
                  "type": "object"
                },
                "headers": {
                  "additionalProperties": {
                    "type": "string"
                  },
                  "type": "object"
                },
                "method": {
                  "const": "POST",
                  "type": "string"
                },
                "type": {
                  "const": "http",
                  "type": "string"
                }
              },
              "required": [
                "type",
                "method"
              ],
              "type": "object"
            },
            "output": {
              "properties": {
                "example": {
                  "type": "object"
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "type"
              ],
              "type": "object"
            }
          },
          "required": [
            "input"
          ],
          "type": "object"
        }
      }
    }
  },
  "liveness": {
    "reliability": null
  },
  "verified": false,
  "featured": false,
  "provider": {
    "host": "api.magentlab.com",
    "manifest_name": "api.magentlab.com",
    "source": "cdp-mirror",
    "source_manifest_url": "https://api.cdp.coinbase.com/platform/v2/x402/discovery/resources",
    "submitted_at": "2026-10-14T01:15:01.050Z"
  },
  "exampleResponse": {
    "example": {},
    "type": "string"
  }
}