{"record":{"id":"29a101cb51d0c225","repo":"microsoft/semantic-kernel","slug":"no-argument-is-found-for-the-property-metadata-n","errorCode":null,"errorMessage":"No argument is found for the '{property_metadata.name}' payload property.","messagePattern":"No argument is found for the '(.+?)' payload property\\.","errorType":"exception","errorClass":"FunctionExecutionException","httpStatus":null,"severity":"error","filePath":"python/semantic_kernel/connectors/openapi_plugin/openapi_runner.py","lineNumber":102,"sourceCode":"\n        return argument, argument\n\n    def build_json_object(self, properties, arguments, property_namespace=None):\n        \"\"\"Build the JSON payload object.\"\"\"\n        result = {}\n\n        for property_metadata in properties:\n            argument_name = self.get_argument_name_for_payload(property_metadata.name, property_namespace)\n            if property_metadata.type == \"object\":\n                node = self.build_json_object(property_metadata.properties, arguments, argument_name)\n                result[property_metadata.name] = node\n                continue\n            property_value = arguments.get(argument_name)\n            if property_value is not None:\n                result[property_metadata.name] = property_value\n                continue\n            if property_metadata.is_required:\n                raise FunctionExecutionException(\n                    f\"No argument is found for the '{property_metadata.name}' payload property.\"\n                )\n        return result\n\n    def build_operation_payload(\n        self, operation: RestApiOperation, arguments: KernelArguments\n    ) -> tuple[str, str] | tuple[None, None]:\n        \"\"\"Build the operation payload.\"\"\"\n        if operation.request_body is None and self.payload_argument_name not in arguments:\n            return None, None\n\n        if operation.request_body is not None:\n            return self.build_json_payload(operation.request_body, arguments)\n\n        return None, None\n\n    def get_argument_name_for_payload(self, property_name, property_namespace=None):\n        \"\"\"Get argument name for the payload.\"\"\"","sourceCodeStart":84,"sourceCodeEnd":120,"githubUrl":"https://github.com/microsoft/semantic-kernel/blob/c028a0c7dc4f0814cdcbaba9d998f187a41197bf/python/semantic_kernel/connectors/openapi_plugin/openapi_runner.py#L84-L120","documentation":"Inside `build_json_object`, for each non-object payload property the runner looks up its argument by derived name; if the value is None and `property_metadata.is_required` is True, it raises `FunctionExecutionException` naming the property. Optional properties with no value are silently omitted.","triggerScenarios":"Dynamic payload building is on, and a required payload property has no matching argument (or is explicitly None). The argument name is derived via `get_argument_name_for_payload` which namespaces nested properties.","commonSituations":"Forgetting a required body field; passing it under the un-namespaced name when the property is nested; model/function-calling not surfacing the field; schema rename that changed the expected argument name.","solutions":["Provide the missing required property value under the argument name the runner expects (use `get_argument_name_for_payload` to compute it for nested props).","Mark the property as not required in the spec, or give it a default, if it is genuinely optional.","Inspect `payload_metadata.properties` to enumerate required fields and their expected argument names before invoking.","Switch to non-dynamic mode and pass the whole body as a JSON string if assembling fields is impractical."],"exampleFix":"# before\nargs = {}  # required 'name' missing -> raises 1498\nawait runner.run_operation(op, args, options)\n\n# after\nargs = {\"name\": \"Rex\"}\nawait runner.run_operation(op, args, options)","handlingStrategy":"validation","validationCode":"def required_payload_props(payload) -> list[str]:\n    out = []\n    for p in (payload.properties if payload else []):\n        if getattr(p, \"is_required\", False) and getattr(p, \"type\", None) != \"object\":\n            out.append(p.name)\n    return out\n\ndef missing_required_props(runner, payload, args) -> list[str]:\n    missing = []\n    for name in required_payload_props(payload):\n        arg_name = runner.get_argument_name_for_payload(name, None)\n        if args.get(arg_name) is None:\n            missing.append(name)\n    return missing\n\nmissing = missing_required_props(runner, op.payload, args)\nassert not missing, f\"Missing required payload props: {missing}\"","typeGuard":"def is_required_payload_property(p) -> bool:\n    return bool(getattr(p, \"is_required\", False))","tryCatchPattern":"from semantic_kernel.exceptions import FunctionExecutionException\n\ntry:\n    await runner.run_operation(op, args, options)\nexcept FunctionExecutionException as e:\n    if \"No argument is found for the\" in str(e) and \"payload property\" in str(e):\n        # extract property name, fill it, retry\n        raise\n    raise","preventionTips":["Enumerate required payload fields from `payload.properties` before invoking.","Compute argument names via `get_argument_name_for_payload` for nested props.","Make required fields optional or defaulted in the spec if they can be omitted.","Fall back to whole-body string mode if field assembly is fragile."],"tags":["openapi-plugin","payload","runtime","arguments","semantic-kernel"],"backgroundTag":null,"analyzedSha":"c028a0c7dc4f0814cdcbaba9d998f187a41197bf","analyzedAt":"2026-08-13T13:48:05.040Z","schemaVersion":2},"datasetVersion":"2026-08-13T14:17:21.547Z"}