JSON Gradio chatbot POST request?

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • Hi,

    I installed this in conda:

    Please login to see this link.

    and its working fine. Now I just want to make a cool interface for in in Fusion. only problem is it is expecting some sort of JSON post method. its running a server locally just fine, but whenever I send a request to it with the text from a simple edit box with the Get object, it comes back that that method is not allowed / is wrong / different errors.
    i understand that I need to use the JSON object with this apparently, but I dont know anything about JSON, or how it works. does someone maybe have a good idea of how i can just send the edit box text to the local Gradio server the right way?

    any help would be so greatly appreciated. thank you in advance.

  • I just posted an answer to a similar question here:
    Please login to see this link.

    Fusion only handles key/values with the Get-object. So it puts an extra "=" behind your JSON if you add it in the key. I tried a lot with the headers but it doesn't work. In the end every POST is just a piece of readable text with some line breaks and syntax in it but when it's not possible to remove predefined "mistakes" in this generated string, then you're stuck.

    You can use my debug script for testing: Please login to see this link.
    It shows all header vars and the raw post data. I also added my testing mfa-file.

    Please login to see this attachment.

  • I just posted an answer to a similar question here:
    Please login to see this link.

    Fusion only handles key/values with the Get-object. So it puts an extra "=" behind your JSON if you add it in the key. I tried a lot with the headers but it doesn't work. In the end every POST is just a piece of readable text with some line breaks and syntax in it but when it's not possible to remove predefined "mistakes" in this generated string, then you're stuck.

    You can use my debug script for testing: Please login to see this link.
    It shows all header vars and the raw post data. I also added my testing mfa-file.

    Please login to see this attachment.

    Thank you very much, although it still doesn't work. It is a local server that it tries to send the JSON too. I also had to remove the window control stuff you put in there because that made it close right away. (I'm not sure if it needed that?) I do feel you're on to something, and I feel its very very close. I attached what it said about the API when you click the API thingie at the bottom. Again I have no idea how it works, all I know is that I want to send it, and then get the bots reply. I have fiddled around with chats and such in Fusion before and it would always work.

    If you could help me figure this thing out you have no idea how much that would mean to me, it would help a lot.

    Please login to see this attachment.

  • Unfortunately I'm afraid it doesn't work with Fusion, not with the Get object and not with other objects that I found.

    This would help, if anybody wants to code a new Fusion object:
    Please login to see this link.

    Before you need to prepare everything with InternetOpen, InternetConnect, HttpOpenRequest and HttpAddRequestHeaders and read the response with InternetReadFile

  • Unfortunately I'm afraid it doesn't work with Fusion, not with the Get object and not with other objects that I found.

    This would help, if anybody wants to code a new Fusion object:
    Please login to see this link.

    Before you need to prepare everything with InternetOpen, InternetConnect, HttpOpenRequest and HttpAddRequestHeaders and read the response with InternetReadFile

    Thats unfortunate, still though thank you very much for trying to help me out. Sincerely. I appreciate it a lot.

    Since we're on the subject I think Fusion also desperately needs a browser update. It would help a lot of we could somehow just use Chromium in there. The problem is always that java script doesn't seem to execute. Ironically I found the same problem even in github Visual Basic custom browsers. They just can't handle javascript and html5. It would be completely awesome if we could include a fully functional browser in our Fusion projects.

    If there will also be an extension capable of sending and receiving requests like the one you mentioned, i'd very much like that.

    Again, thank you.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!