当前位置:网站首页>flask-restplus接口地址404问题
flask-restplus接口地址404问题
2022-08-10 10:48:00 【华为云】
问题:
书写 仪表盘的图表配置信息保存 操作的接口时,想通过querystring 的方式来获取id值,因此定义 的接口 路由是
/api/dashboard/chart/handle/?id=int:id
这样的 路由地址,其中 int:id 这里是必需要传递的一个value 值,通过这样的方式来获取到id值,但在使用过程中,请求该接口,一直返回404.
解决:
使用flask-restplus 书写接口,querystring 并不需要在路由中定义,只需要标识querystring 是必填的即可,同时需要注意 路由需要以 / 结尾 即修改成
/api/dashboard/chart/handle/
在请求接口时在后面添加上querystring key value 值即可。
边栏推荐
- "Data Strategy" Results-Driven Enterprise Data Strategy: Organization and Governance
- 【勇敢饭饭,不怕刷题之链表】链表倒数节点问题
- owl.carousel poster card Slider carousel switch
- 文本选中圆角样式border-radius
- Redis设计与实现
- HCIP ---- VLAN
- Redis(六)——Redis6的事务和锁机制(未完成,待补)
- 干货!ASSANet:让PointNet++更快更强
- Redis(三)——配置文件详解、发布和订阅、新数据类型
- 今天面了个腾讯拿38K出来的大佬,让我见识到了基础的天花板
猜你喜欢
runtime-core.esm-bundler.js?d2dd:218 Uncaught TypeError: formRef.value?.validate is not a function
《MySQL高级篇》六、索引的创建与设计原则
Kyligence 通过 SOC 2 Type II 审计,以可信赖的企业级产品服务全球客户
leetcode:334. 递增的三元子序列
「首席工程师」首席(Principal )工程师修炼之道
Introduction to cross-end development of Taro applet
【勇敢饭饭,不怕刷题之链表】链表中有环的问题
网络安全笔记6——数字证书与公钥基础设施
[Brave food, not afraid to write the linked list] The problem of the penultimate node of the linked list
金九银十跳槽旺季:阿里、百度、京东、美团等技术面试题及答案
随机推荐
bus event bus use
4 of huawei offer levels, incredibly side is easing the bit in the interview ali?
Redis (three) - detailed configuration file, publish and subscribe, new data types
内存问题难定位,那是因为你没用ASAN
Redis(三)——配置文件详解、发布和订阅、新数据类型
[Brave food, not afraid of the linked list of brushing questions] Merging of ordered linked lists
POJ 3101 Astronomy (数学)
AUTOCAD——减少样条曲线控制点数、CAD进阶练习(三)
HDU 1520 Anniversary party (tree dp)
GPU加速Pinterest推荐模型,参数量增加100倍,用户活跃度提高16%
【勇敢饭饭,不怕刷题之链表】链表倒数节点问题
第5章相似矩阵及二次型(4)
JWT 实现登录认证 + Token 自动续期方案
杭电多校-Loop-(不确定性贪心+线段树)
网络安全笔记6——数字证书与公钥基础设施
越折腾越好用的 3 款开源 APP
Double.doubleToLongBits() method uses
mysql appears: ERROR 1524 (HY000): Plugin '123' is not loaded
js guessing game source code
3 injured in 'electrical accident' at Google data center