我用GET参数向站点发送请求
response = requests.get(f'http://localhost/botcontact&phonenumber={phonenumber}&user_id={user_id}')
urls.py 中的跟踪
path('botcontact/', views.botcontact)
我得到错误Not Found: / botcontact&phonenumber=+79162321578&user_id=228695396
如何在urls.py中不考虑get参数,并且可以通过path ('botcontact/', views.botcontact)
跟踪它?在这种情况下,必须在函数中获得GET参数
请求语句无效;它应该从?
开始
response = requests.get(f'http://localhost/botcontact?phonenumber={phonenumber}&user_id={user_id}')