Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Call C# functions from anywhere using URL (HTTP server)
#19
Can you create a JSON return type? GPT-3.5's API calls only support returning JSON strings.
Currently, I'm piecing together JSON strings in the following way,
 
Code:
Copy      Help
string jsonPath = $$"""
{
    "Path": "D:\{{fileName}}.pdf"
}
""";
        //print.it(jsonPath);
        return jsonPath;

but it seems to be missing some necessary properties,
such as code, success, and data (the function's return value seems like it should become part of the data).
Is there any simpler solution?

It would be great if custom functions could automatically generate API configuration files that comply with OpenAPI 3.0.
https://spec.openapis.org/oas/v3.0.3.html


Messages In This Thread
RE: Call C# functions from anywhere using URL (HTTP server) - by Davider - 05-09-2024, 12:15 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)