{
  "x402Version": 2,
  "id": 39148,
  "slug": "39148",
  "resource": "https://api.magentlab.com/api/calc/mayo_spn",
  "description": "Swensen 1997 Mayo Clinic logistic probability of malignancy for a 4-30 mm radiologically indeterminate solitary pulmonary nodule. Inputs: age, current or former smoking, extrathoracic cancer diagnosed ≥5 years before the nodule, largest diameter in mm, caller-assigned spiculation, and caller-assigned upper-lobe location. Returns logit x and P = e^x / (1 + e^x). magent does not read the film. Not Gould 2007, not Brock, not a diagnosis, not a biopsy order, and not a medical device.",
  "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,
                "cancer": false,
                "diameter_mm": 8,
                "smoke": false,
                "spiculation": false,
                "upper_lobe": false
              },
              {
                "age": 50,
                "cancer": false,
                "diameter_mm": 8,
                "smoke": false,
                "spiculation": false,
                "upper_lobe": false
              }
            ]
          },
          "method": "POST",
          "type": "http"
        },
        "output": {
          "example": {
            "count": 2,
            "items": [
              {
                "age_years": 50,
                "cancer": false,
                "citation": {
                  "authors": "Swensen SJ, Silverstein MD, Ilstrup DM, Schleck CD, Edell ES",
                  "doi": "10.1001/archinte.1997.00440290031002",
                  "id": "swensen-1997",
                  "pmid": "9129544",
                  "source": "Arch Intern Med. 1997;157(8):849-855",
                  "title": "The probability of malignancy in solitary pulmonary nodules. Application to small radiologically indeterminate nodules"
                },
                "diameter_mm": 8,
                "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.",
                "formula": "mayo_spn",
                "formula_expression": "P = e^x / (1 + e^x); x = -6.8272 + 0.0391*age + 0.7917*smoke + 1.3388*cancer + 0.1274*diameter_mm + 1.0407*spiculation + 0.7838*upper_lobe; smoke 1 = current or former, 0 = never; cancer 1 = extrathoracic cancer diagnosed ≥5 years before the nodule; spiculation 1/0; upper_lobe 1/0 (Swensen 1997)",
                "linear_predictor": -3.853,
                "probability": 0.0208,
                "smoke": false,
                "spiculation": false,
                "upper_lobe": false
              },
              {
                "age_years": 50,
                "cancer": false,
                "citation": {
                  "authors": "Swensen SJ, Silverstein MD, Ilstrup DM, Schleck CD, Edell ES",
                  "doi": "10.1001/archinte.1997.00440290031002",
                  "id": "swensen-1997",
                  "pmid": "9129544",
                  "source": "Arch Intern Med. 1997;157(8):849-855",
                  "title": "The probability of malignancy in solitary pulmonary nodules. Application to small radiologically indeterminate nodules"
                },
                "diameter_mm": 8,
                "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.",
                "formula": "mayo_spn",
                "formula_expression": "P = e^x / (1 + e^x); x = -6.8272 + 0.0391*age + 0.7917*smoke + 1.3388*cancer + 0.1274*diameter_mm + 1.0407*spiculation + 0.7838*upper_lobe; smoke 1 = current or former, 0 = never; cancer 1 = extrathoracic cancer diagnosed ≥5 years before the nodule; spiculation 1/0; upper_lobe 1/0 (Swensen 1997)",
                "linear_predictor": -3.853,
                "probability": 0.0208,
                "smoke": false,
                "spiculation": false,
                "upper_lobe": false
              }
            ],
            "path": "/api/calc/mayo_spn"
          },
          "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 (18-120). Swensen 1997 is an adult derivation; 18 is an implementation clamp.",
                          "type": "integer"
                        },
                        "cancer": {
                          "description": "Extrathoracic cancer diagnosed ≥5 years before the nodule (Swensen 1997). true scores 1; false scores 0. The derivation excluded cancer within 5 years. The caller assigns the history.",
                          "type": "boolean"
                        },
                        "diameter_mm": {
                          "description": "Largest nodule diameter in millimetres (4-30). Swensen 1997 derivation range. magent does not measure the film.",
                          "type": "number"
                        },
                        "smoke": {
                          "description": "Cigarette smoking as coded in Swensen 1997. true = current or former smoker (1); false = never (0). The caller assigns smoking history.",
                          "type": "boolean"
                        },
                        "spiculation": {
                          "description": "Spiculated edge as assigned by the caller (Swensen 1997). true or false. magent does not read the film.",
                          "type": "boolean"
                        },
                        "upper_lobe": {
                          "description": "Upper-lobe location as assigned by the caller (Swensen 1997). true or false. magent does not read the film.",
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "age",
                        "smoke",
                        "cancer",
                        "diameter_mm",
                        "spiculation",
                        "upper_lobe"
                      ],
                      "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": [
    "mayo-spn",
    "spn",
    "respiratory",
    "nodule",
    "calculator",
    "bazaar"
  ],
  "sourceHost": "api.magentlab.com",
  "lastUpdated": "2026-10-13T04:56:27.515Z",
  "quality": {
    "calls30d": 5,
    "uniquePayers30d": 2,
    "lastCalledAt": "2026-10-13T04:56:27.35Z"
  },
  "metadata": {
    "serviceName": "magent",
    "extensions": {
      "bazaar": {
        "info": {
          "iconUrl": "https://api.magentlab.com/favicon.ico",
          "input": {
            "body": {
              "items": [
                {
                  "age": 50,
                  "cancer": false,
                  "diameter_mm": 8,
                  "smoke": false,
                  "spiculation": false,
                  "upper_lobe": false
                },
                {
                  "age": 50,
                  "cancer": false,
                  "diameter_mm": 8,
                  "smoke": false,
                  "spiculation": false,
                  "upper_lobe": false
                }
              ]
            },
            "method": "POST",
            "type": "http"
          },
          "output": {
            "example": {
              "count": 2,
              "items": [
                {
                  "age_years": 50,
                  "cancer": false,
                  "citation": {
                    "authors": "Swensen SJ, Silverstein MD, Ilstrup DM, Schleck CD, Edell ES",
                    "doi": "10.1001/archinte.1997.00440290031002",
                    "id": "swensen-1997",
                    "pmid": "9129544",
                    "source": "Arch Intern Med. 1997;157(8):849-855",
                    "title": "The probability of malignancy in solitary pulmonary nodules. Application to small radiologically indeterminate nodules"
                  },
                  "diameter_mm": 8,
                  "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.",
                  "formula": "mayo_spn",
                  "formula_expression": "P = e^x / (1 + e^x); x = -6.8272 + 0.0391*age + 0.7917*smoke + 1.3388*cancer + 0.1274*diameter_mm + 1.0407*spiculation + 0.7838*upper_lobe; smoke 1 = current or former, 0 = never; cancer 1 = extrathoracic cancer diagnosed ≥5 years before the nodule; spiculation 1/0; upper_lobe 1/0 (Swensen 1997)",
                  "linear_predictor": -3.853,
                  "probability": 0.0208,
                  "smoke": false,
                  "spiculation": false,
                  "upper_lobe": false
                },
                {
                  "age_years": 50,
                  "cancer": false,
                  "citation": {
                    "authors": "Swensen SJ, Silverstein MD, Ilstrup DM, Schleck CD, Edell ES",
                    "doi": "10.1001/archinte.1997.00440290031002",
                    "id": "swensen-1997",
                    "pmid": "9129544",
                    "source": "Arch Intern Med. 1997;157(8):849-855",
                    "title": "The probability of malignancy in solitary pulmonary nodules. Application to small radiologically indeterminate nodules"
                  },
                  "diameter_mm": 8,
                  "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.",
                  "formula": "mayo_spn",
                  "formula_expression": "P = e^x / (1 + e^x); x = -6.8272 + 0.0391*age + 0.7917*smoke + 1.3388*cancer + 0.1274*diameter_mm + 1.0407*spiculation + 0.7838*upper_lobe; smoke 1 = current or former, 0 = never; cancer 1 = extrathoracic cancer diagnosed ≥5 years before the nodule; spiculation 1/0; upper_lobe 1/0 (Swensen 1997)",
                  "linear_predictor": -3.853,
                  "probability": 0.0208,
                  "smoke": false,
                  "spiculation": false,
                  "upper_lobe": false
                }
              ],
              "path": "/api/calc/mayo_spn"
            },
            "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 (18-120). Swensen 1997 is an adult derivation; 18 is an implementation clamp.",
                            "type": "integer"
                          },
                          "cancer": {
                            "description": "Extrathoracic cancer diagnosed ≥5 years before the nodule (Swensen 1997). true scores 1; false scores 0. The derivation excluded cancer within 5 years. The caller assigns the history.",
                            "type": "boolean"
                          },
                          "diameter_mm": {
                            "description": "Largest nodule diameter in millimetres (4-30). Swensen 1997 derivation range. magent does not measure the film.",
                            "type": "number"
                          },
                          "smoke": {
                            "description": "Cigarette smoking as coded in Swensen 1997. true = current or former smoker (1); false = never (0). The caller assigns smoking history.",
                            "type": "boolean"
                          },
                          "spiculation": {
                            "description": "Spiculated edge as assigned by the caller (Swensen 1997). true or false. magent does not read the film.",
                            "type": "boolean"
                          },
                          "upper_lobe": {
                            "description": "Upper-lobe location as assigned by the caller (Swensen 1997). true or false. magent does not read the film.",
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "age",
                          "smoke",
                          "cancer",
                          "diameter_mm",
                          "spiculation",
                          "upper_lobe"
                        ],
                        "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"
  }
}