If there is, then it returns the acronym and it's definition. HTTP_200_OK )Įssentially what the Slack Bot does is takes in the request.data and checks it against the DRF API end point to see if there is a matching Acronym. HTTP_200_OK ) return Response ( status = status. as_view (], channel = channel ) return Response ( status = status. views import AcronymViewSet, AddAcronym, CountAcronyms, Events app_name = "api" user_list = AcronymViewSet. just 2 fields:įrom django.urls import include, path from. The initial implementation of the model was very simple. I ran into a few problems while working with my Django Cookie Cutter but I fixed them and then dove head first into writing the Slack Bot The model I felt equally ~overwhelmed~ by the prospect of trying FastAPI to create the API or Flask, because I am not as familiar with their deployment story.Īnother thing that was different now than before was that I had worked on a Django Cookie Cutter to use and that was 'good enough' to try it out. I just felt ~overwhelmed~ by the prospect. I'm familiar with Django, but going from 0 to something in production has a few steps and although I know how to do them. I think one of the problems I encountered was what backend / tech stack to use. I didn't really have anymore time now than I did over the holiday, but Bob asking and me answering pushed me to actually write the darned thing. I work in US Healthcare where there are a lot of Acronyms (many of which are used in tech but have different meaning), so my slack bot would allow a user to enter an acronym and return what it means, i.e., CMS = Centers for Medicare and Medicaid Services.- The B Is Silent February 2, 2022 If you were to build a Slack bot, what would it do?- Bob Belderbos February 2, 2022 I had hoped that I would be able to spend some time on it over the holidays, but I was never able to really find the time. I had added a project to my OmniFocus database in November of 2021 which was, "Build a Slackbot" after watching a Video by Mason Egger.
0 Comments
Leave a Reply. |