知识卡片
REST资源与操作
资源是客户端要访问的业务对象,例如一名用户。URI 标识资源,方法表达读取、创建、替换等操作。HTTP 是这些交换的通信协议,REST 还要求交互按约束组织;路径有名词这一点不足以判断整套接口的风格。
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- Introducing APIs and OpenAPI 1.6 What about REST? · 查看原书依据
One of the key ideas behind REST is that of a resource. Things such as user accounts, billing reminders, or even the weather in San Francisco are all resources, and each resource is identified by a URI. For a user’s account, we
参考来源
- 位置:《Designing APIs with Swagger and OpenAPI》第01章《Introducing APIs and OpenAPI》(来源项目 book-source:extracted/Designing APIs with Swagger and OpenAPI/_epub-src/OEBPS/Text/ch01.htm,阅读块 68)
- 结论依据:原文以 /users/123 说明 URI 标识一项资源并用 HTTP 方法操作。
- 原始内容:One of the key ideas behind REST is that of a resource. Things such as user accounts, billing reminders, or even the weather in San Francisco are all resources, and each resource is identified by a URI. For a user’s account, we