`parameters` property isn't optional as they've mentioned in doc

I’ve tried declaring a function without the parameter property and ended up with an openai.error.InvalidRequestError: 'parameters' is a required property - 'functions.0' error.

I tried to declare with an empty parameters property like below and found it working as expected.

    functions=
    [
        {
            "name": "<function_name>",
            "parameters": { "type": "object", "properties": {}}
        }
    ]

Output

"message": {
        "role": "assistant",
        "content": null,
        "function_call": {
          "name": "get_app_id",
          "arguments": "{}"
        }
      },

But the documentation says the parameters as optional.

Has anyone tried and found different results?

Same, had to do what you did to get it to work. Specifying null as the parameter type didn’t work either.