当前位置:网站首页>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 值即可。
边栏推荐
- Some tips for using Unsafe
- Double.doubleToLongBits() method uses
- 8月份DB-Engines 数据库排行榜最新战况
- 4 of huawei offer levels, incredibly side is easing the bit in the interview ali?
- CodeChef STRMRG String Merging (dp)
- Unsafe的一些使用技巧
- 从产品维度来看 我们为什么不能完全信任Layer2?
- POJ 1026 Cipher (置换群)
- 《MySQL高级篇》六、索引的创建与设计原则
- SQL与NoSQL最终会走向融合吗?
猜你喜欢
第3章-线性方程组(3)
Unsafe的一些使用技巧
Memory problems difficult to locate, it is because you do not use ASAN
Network Security Note 6 - Digital Certificates and Public Key Infrastructure
ISO9001在讲什么?过程方法和风险思维
MongoDB database notes
振弦传感器及核心VM系列振弦采集模块
PPT | 「课件」企业中高层人员安全管理培训(118页)
Gold, nine, silver and ten job-hopping seasons: technical interview questions and answers on Alibaba, Baidu, JD.com, and Meituan
动作捕捉系统用于室内组合定位技术研究
随机推荐
SQL与NoSQL最终会走向融合吗?
"Scalability" extensibility best practices: lessons from eBay
[Brave food, not afraid to write the linked list] The problem of the penultimate node of the linked list
mysql出现:ERROR 1524 (HY000): Plugin ‘123‘ is not loaded
STM32 encapsulation ESP8266 a key configuration function: implementations of AP mode and the STA mode switch, server and the client to create
【勇敢饭饭,不怕刷题之链表】链表倒数节点问题
ECCV 2022 | 视频理解新框架X-CLIP:仅用微调的成本,达到预训练的全能
Short video software development - how to break the platform homogenization
企业如何判断数据治理是否成功?
关于json转换器缺失的问题,报错内容:No converter found for return value of type
第二十二章 源代码文件 REST API 参考(四)
Codeforces 814 C. An impassioned circulation of affection (dp)
"Data Strategy" Results-Driven Enterprise Data Strategy: Organization and Governance
Will SQL and NoSQL eventually converge?
第3章-线性方程组(3)
"Time Series Database" uses cassandra to scan time series data
Network Security Note 6 - Digital Certificates and Public Key Infrastructure
chart.js horizontal column chart plugin
From the product dimension, why can't we fully trust Layer2?
OSSCore 开源解决方案介绍