"Ask a Question" form on frontend to interact with the bot via /faq endpoint
Feature:
Add a simple HTML form that lets users ask a question about GSSoC directly from the browser. This form should send a POST request to the /faq API endpoint and display the bot's answer below it.
Implementation:
- Create a new file:
public/index.html - Add:
- An input box for the question
- A submit button
- A container to show the bot's response
- Use JavaScript
fetch()to POST the question to/faqand show the result. - Optional: Add some CSS styling.
Why:
- Improves user experience
- Allows interaction with the bot from a web interface (not just Telegram)
- Great for contributors and non-technical users to test the bot
I would like to work on this issue as a first-time contributor! 💻
Checklist: Please confirm the following checks when submitting the pull request
It help us ensure the completeness of the project. (These checks are mandatory, your PR will be rejected if you fail even one of these) :
- [ ] Attach Proof of Work - Include at least one screenshot or short video showing the implementation and changes made.
- [ ] What problem you are solving, Explain Your Approach In your PR description
- [ ] PR links to the issue (e.g., Closes #)
My Suggestion/Corrections:
- This is a discord bot so there is actually no
/faqendpoint . Those are simple commands and prefixes to use on discord. - You can modify the approach this way: Show suggestion as dropdown when ever user types. user select that que and get answers form file
faqs.json - Study the codebase. I have a
components.jsfile which have logic for the chat section. the questions and all animations are contained inviews/index.jsfile. - You do not have to actually make new
public/index.html. simply implement it on/views/index.htmlfile section 2.
@Swasthiga-0618 I have assigned you the issue, You can start working.
@piyushpatelcodes is this issue open to work as it will open for a lot of time I don't see any progress can I give it a try ?
@VANSH3104 Yes I have assigned you the issue and you can start working. Remember to follow above checklist
Is someone currently working on this issue, can it be assigned to me under GSSOC'25