장점
단점
REST의 기본적인 규칙
1. URI 자원 표현하는데 집중
2. 행위에 대한 정의는 HTTP 메소드
// URI에 동사 표현 -> 지양
GET students/find/100
// 수정
GET students/100
// 등록, 삭제 URI에 포함 -> X
GET students/insert/100
GET students/delete/100
// 수정
POST students/100
DELETE students/100
// 마지막 슬래시 -> X
GET students/insert/100/
// 수정
GET students/insert/100
GET http://restapi.com/school/classroom/3-3
// URI에 밑줄 사용 - bad
GET http://restapi.com/school/classroom/3_3
// 수정
GET http://restapi.com/school/classroom/3-3
// 아래 리소스와 다른 리소스
GET http://restapi.com/School/Classroom/3-3
// 소문자로만 작성한 URI
GET http://restapi.com/school/classroom/3-3
// URI 경로에 확장자 표기 - bad
GET http://restapi.com/school/students/photo.jpg
// 수정
GET http://restapi.com/school/students/photo
HTTP/1.1 HOST:restapi.com Accept:image/jpg
참고자료
https://restfulapi.net/http-methods/