Openapi.check: def of ezmcp@0.1.0.0 Import: import ezmcp@0.1.0.0/src/openapi.bend as Openapi Lines 1492-1499 of ezmcp@0.1.0.0/src/openapi.bend: https://jend.leeeet.dev/read.txt?path=ezmcp@0.1.0.0/src/openapi.bend&start_line=1492&end_line=1499 import Base import emerging-ezjson@1.2.0.0/main.bend as Json import emerging-ezjson@1.2.0.0/src/value.bend as Value # what is wrong with a call's arguments, when anything is: a required name # they do not have (`missing`), else a property they have whose value does # not fit its schema (`bad`); none when neither def check(oper: Op, +args: Value.Json) -> Maybe<&2, String>: match oper: case Op{name, description, +input, method, path, params, media}: check.of(name, first(missing(Json.items(Json.get(input, "required")), args), bad(members(Json.get(input, "properties")), args))) Uses (11): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=emerging-ezjson@1.3.0.0/main.bend&name=get https://jend.leeeet.dev/definition.txt?path=emerging-ezjson@1.3.0.0/main.bend&name=items https://jend.leeeet.dev/definition.txt?path=emerging-ezjson@1.3.0.0/src/value.bend&name=Json https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=Op https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=bad https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=check.of https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=first https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=members https://jend.leeeet.dev/definition.txt?path=ezmcp@0.1.0.0/src/openapi.bend&name=missing