Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webhook support #11

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

webhook support #11

wants to merge 1 commit into from

Conversation

j4ck4l-24
Copy link

  • Created two new files webhook_wrapper.py and AIChatAutomation.py:

    1. AIChatAutomation.py:

      • Contains the code to set up the connection to the host and send messages to the host.
      • This file handles the websocket connections, and message sending/receiving functions.
    2. webhook_wrapper.py:

      • Acts as a wrapper to manage the connection, send messages, and receive responses.
      • Uses the connect function to set up the connection by using the AIChatAutomation class from AIChatAutomation.py.
      • The send_message function sends messages to the host and waits for the response.
      • The handle_response function is called when a response is received, processing and returning it to whistleblower.py.
  • Changed two files: whistleblower.py and ui/app.py:

    1. whistleblower.py:

      • Adjusted to correctly receive responses using webhook_wrapper.py.
      • Removed the request body and response body handling that was previously used for direct API calls.
      • Integrated webhook_wrapper.py to manage the webhook setup and ensure the connection is correctly established before sending messages.
    2. ui/app.py:

      • No major changes just removed the request and response body for the specific case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant