{"uid":"cap_LVgtocBR2Mp7nWekYAlkp","slug":"magent-rome-iv-biliary-sod-type-ii-functional-biliary-sphincter-of-84db822a","name":"magent Rome IV Biliary SOD (Type II / Functional Biliary Sphincter of Oddi Disorder)","description":"Cotton 2016 Rome IV E1b functional biliary SOD (former SOD type II). rome_iv_biliary_sod iff six E1 biliary-pain flags, enzymes XOR dilated bile duct, and no stones or other structural abnormalities. Type I (both findings) is organic stenosis, not this box. Type III (neither) is not this box. Supportive amylase/lipase, manometry, and scintigraphy are reported, not required. magent does not read labs, imaging, manometry, or ERCP. Not a diagnosis, not pancreatic SOD, not functional gallbladder.","url":"https://api.magentlab.com/api/calc/rome_iv_biliary_sod","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET","HEAD","DELETE"],"type":"string"},"headers":{"type":"object","additionalProperties":{"type":"string"}},"queryParams":{"type":"object","required":["epigastric_or_ruq_pain","builds_to_steady_level_lasts_30_min_or_longer","occurring_at_different_intervals_not_daily","severe_enough_to_interrupt_activities_or_ed_visit","not_significantly_related_to_bowel_movements","not_significantly_relieved_by_postural_change_or_acid_suppression","elevated_liver_enzymes","dilated_bile_duct","absence_of_bile_duct_stones_or_other_structural_abnormalities","normal_amylase_lipase","abnormal_sphincter_of_oddi_manometry","hepatobiliary_scintigraphy"],"properties":{"dilated_bile_duct":{"type":"boolean","description":"Dilated bile duct, as assigned (Cotton 2016 E1b). XOR with elevated_liver_enzymes: exactly one must be true. true or false as assigned by the caller. magent does not read imaging."},"normal_amylase_lipase":{"type":"boolean","description":"Normal amylase/lipase, a supportive criterion that is not required for rome_iv_biliary_sod (Cotton 2016 E1b). true or false as assigned by the caller. magent does not read labs."},"elevated_liver_enzymes":{"type":"boolean","description":"Elevated liver enzymes, as assigned (Cotton 2016 E1b). XOR with dilated_bile_duct: exactly one must be true. true or false as assigned by the caller. magent does not read labs."},"epigastric_or_ruq_pain":{"type":"boolean","description":"Episodes of pain located in the epigastrium and/or right upper quadrant (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not examine the patient."},"hepatobiliary_scintigraphy":{"type":"boolean","description":"Abnormal hepatobiliary scintigraphy, a supportive criterion that is not required for rome_iv_biliary_sod (Cotton 2016 E1b). true or false as assigned by the caller. magent does not read imaging."},"abnormal_sphincter_of_oddi_manometry":{"type":"boolean","description":"Abnormal sphincter of Oddi manometry, a supportive criterion that is not required for rome_iv_biliary_sod (Cotton 2016 E1b). true or false as assigned by the caller. magent does not read manometry."},"occurring_at_different_intervals_not_daily":{"type":"boolean","description":"Episodes occurring at different intervals (not daily) (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not take a history."},"not_significantly_related_to_bowel_movements":{"type":"boolean","description":"Pain not significantly related to bowel movements (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not take a history."},"builds_to_steady_level_lasts_30_min_or_longer":{"type":"boolean","description":"Pain builds up to a steady level lasting 30 minutes or longer (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not take a history."},"severe_enough_to_interrupt_activities_or_ed_visit":{"type":"boolean","description":"Pain severe enough to interrupt daily activities or lead to an emergency department visit (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not examine the patient."},"absence_of_bile_duct_stones_or_other_structural_abnormalities":{"type":"boolean","description":"Absence of bile duct stones or other structural abnormalities, as assigned (Cotton 2016 E1b). This is the structural flag; there is no separate cholecystectomy boolean. true or false as assigned by the caller. magent does not read imaging or ERCP."},"not_significantly_relieved_by_postural_change_or_acid_suppression":{"type":"boolean","description":"Pain not significantly relieved by postural change or acid suppression (Cotton 2016 E1 biliary pain). true or false as assigned by the caller. magent does not prescribe acid suppression."}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_nipiMQDg06XJO4JMLgt8r","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Evaluates Cotton 2016 Rome IV criteria to determine whether a patient meets the definition of functional biliary sphincter of Oddi disorder (formerly SOD type II / E1b), requiring six biliary pain flags plus exactly one of elevated liver enzymes or dilated bile duct, with no stones or structural abnormalities.","exampleAgentPrompt":"My patient has episodic RUQ pain that builds to a steady level lasting over 30 minutes, occurs at irregular intervals (not daily), is severe enough that she visited the ED, is not related to bowel movements, and is not relieved by postural changes or antacids — she has elevated liver enzymes but no dilated bile duct, and imaging shows no stones or structural abnormalities; does she meet Rome IV criteria for functional biliary sphincter of Oddi disorder?","exampleUseCases":[{"title":"Post-cholecystectomy biliary pain workup","prompt":"My patient had her gallbladder out six months ago and still has episodic RUQ pain lasting over 30 minutes, severe enough for an ED visit, not daily, not related to bowel movements, not relieved by position or antacids, with elevated liver enzymes but no dilated duct and no stones on imaging — does she qualify for Rome IV functional biliary SOD?"},{"title":"Ruling out organic biliary stenosis","prompt":"I have a patient with biliary pain meeting all six Rome IV E1 criteria, but he has both elevated liver enzymes AND a dilated bile duct — can you run the Rome IV biliary SOD calculator to confirm whether this is Type I organic stenosis and not functional SOD E1b?"},{"title":"GI fellow teaching case classification","prompt":"For a Rome IV teaching case: a patient has epigastric pain building steadily, lasting 45 minutes, occurring every few weeks, severe enough to interrupt daily activities, not linked to bowel movements or postural relief, normal amylase/lipase, dilated bile duct but normal liver enzymes, and no structural abnormalities — does this meet the Rome IV E1b functional biliary SOD definition?"}],"resultDescription":"Returns a boolean rome_iv_biliary_sod indicating whether the patient's criteria satisfy Cotton 2016 Rome IV E1b (functional biliary sphincter of Oddi disorder). Also reports supportive findings (normal amylase/lipase, abnormal manometry, hepatobiliary scintigraphy) as informational, not determinative. Does not produce a diagnosis and does not interpret labs, imaging, or manometry directly.","failureModes":["XOR constraint violated: both elevated_liver_enzymes and dilated_bile_duct are true (this is Type I / organic stenosis, not E1b — endpoint will not return true for SOD)","XOR constraint violated: neither elevated_liver_enzymes nor dilated_bile_duct is true (Type III, not this box)","Missing required biliary pain flags: if any of the six E1 pain criteria booleans are absent, the request will fail validation","Misuse: caller expects the endpoint to read or interpret actual lab values, imaging reports, or manometry tracings — it only accepts pre-assigned booleans","Misuse: caller attempts to use this endpoint for pancreatic SOD or functional gallbladder disorder — out of scope"],"whenToPreferThis":"Use this endpoint when you have already assigned the Rome IV E1 biliary pain flags and objective findings (enzyme elevation XOR ductal dilation, absence of stones) as booleans and need a structured, rule-based Rome IV E1b (functional biliary SOD) determination. Prefer it over general symptom checkers or LLM reasoning when you need a reproducible, criteria-faithful computation traceable to Cotton 2016. Do not use it for pancreatic SOD, functional gallbladder disorder, or when both or neither objective finding is present.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T07:10:08.200Z","isFirstParty":false}