为什么api响应正文未显示在postman应用程序生成的文档中?

时间:2019-12-23 08:09:04

标签: api postman api-doc

我正在right连续测试apis,然后使用postman应用生成 api文档

但是问题是文档没有显示我在postman中收到的api response。这是我收到的大部分postman console

的回复

enter image description here

如何在我的api文档中获取响应正文?

1 个答案:

答案 0 :(得分:1)

如果请求已保存到集合中,则可以使用位于响应正文右上角的Save as example功能。这将打开example构建器,并将其保存后,将在API文档中根据请求显示此响应正文。

enter image description here

有关其工作原理的更多详细信息,请参见:

https://learning.getpostman.com/docs/postman/collections/examples/#how-your-examples-appear-in-postman-documentation