사용자 보유 패스포트 - 스탬프 목록 조회
SMTOWN 회원의 보유 Passport 목록을 제공합니다.
passport scope가 필요합니다.
변경사항
- 버전 endpoint 제공 : v1/me/stamps , 기존 api 주소 me/stamps 도 사용 가능 (2022-07-13)
GET https://openapi.smtown.com/api/v1/me/stamps?page=1&size=10
Authorization: Bearer 2a324609ec94f18d614d4bc425de754
| 파라메타 |
필수여부 |
설명 |
Authorization |
Header 필수 |
인증 섹션에서 받은 Bearer token 입니다. |
page |
옵션-QueryString |
요청 page 번호, 기본값 1 |
size |
옵션-QueryString |
페이지당 아이템 갯수, 기본값 10, 최대 50 (50보다 클 경우 50으로 자동 조정됩니다) |
성공 응답
HTTP/1.1 200
Content-Type: application/json;charset=UTF-8
{
"page": 1,
"size": 10,
"totalItems": 1253,
"items": [
{
"idx": 1364,
"passport_idx": 22,
"name": "Stamp Name",
"issuedAt": "2022-05-27T02:44:24.000Z",
"image": {
"url": "https://path.of.image/image_name.jpg",
"width": 996,
"height": 996
}
},
{
"idx": 1365,
"passport_idx": 22,
"name": "Stamp Name",
"issuedAt": "2022-05-27T02:44:24.000Z",
"image": {
"url": "https://path.of.image/image_name.jpg",
"width": 996,
"height": 996
}
},
........
]
}
| 파라메타 |
타입 |
설명 |
page |
Integer |
현재 페이지 번호 |
size |
Integer |
페이지당 item 수 |
totalItems |
Integer |
item의 전체 갯수 |
items |
Object |
item 목록 |
ㄴ idx |
Integer |
스탬프 고유번호 |
ㄴ passport_idx |
Integer |
상위 패스포트 고유번호 |
ㄴ name |
String |
스탬프 이름 |
ㄴ issuedAt |
String |
발급 일자 (yyyy-MM-ddTHH:mm:ss.SSSXXX => 2022-05-27T02:55:50.000Z) |
ㄴ image |
Object |
이미지 정보 |
ㄴ url |
String |
이미지 URL |
ㄴ width |
Integer |
이미지 가로 |
ㄴ height |
Integer |
이미지 세로 |
실패 응답 - Invalid token
HTTP/1.1 401
Content-Type: application/json;charset=UTF-8
{
"path": "https://openapi.smtown.com/api/me",
"error": "Invalid Token",
"message": "2a324609ec94f==invalid token value==",
"timestamp": "2022-04-23T23:16:03.114Z",
"status": 401
}
실패 응답 - 사용자가 허용하지 않음
HTTP/1.1 401
Content-Type: application/json;charset=UTF-8
{
"path": "https://openapi.smtown.com/api/me",
"error": "Access Denied",
"message": "Insufficient scope for this resource",
"timestamp": "2022-06-22T20:19:55.653+0000",
"status": 403
}