Skip to content

카드 전체 조회

Haely edited this page Dec 29, 2019 · 26 revisions

카드 전체 조회(/cards/)

Request

URL

[GET] ~/cards/

Header

메소드 파라미터 설명
Content-Type application/json
token {token} access token값

Response

SUCCESS

{
    "success": true,
    "message": "카드 전체 조회 성공",
    "data": [
        {
            "cardIdx": 12,
            "title": "first title",
            "content": "first content",
            "image": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577350104200.png",
            "record": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577350104201.MP3",
            "count": 0,
            "visible": 0,
            "serialNum": "z1bh8909s",
            "sequence": 1
        },
        {
            "cardIdx": 14,
            "title": "title4",
            "content": "content4",
            "image": "[object Object]",
            "record": "[object Object]",
            "count": 0,
            "visible": 1,
            "serialNum": "hhw38joe3u",
            "sequence": 2
        },
        {
            "cardIdx": 33,
            "title": "sample title update",
            "content": "sample content update",
            "image": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577514701790.jpg",
            "record": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577514701798.MP3",
            "count": 0,
            "visible": 0,
            "serialNum": "h0ojyqtjd",
            "sequence": 5
        },
        {
            "cardIdx": 48,
            "title": "abababab",
            "content": "abababab",
            "image": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577638879429.png",
            "record": "https://s3sopt25.s3.ap-northeast-2.amazonaws.com/1577638879445.png",
            "count": 0,
            "visible": 1,
            "serialNum": "o7jatlku7h",
            "sequence": 22
        }
    ]
}

FAIL : 해당 사용자가 가진 카드가 없는 경우

{
    "success": false,
    "message": "존재하지 않는 카드입니다."
}

FAIL : 토큰이 존재하지 않는 경우

{
    "success": false,
    "message": "토큰이 없습니다"
}

FAIL : 토큰의 형식이 잘못된 경우

{
    "success": false,
    "message": "유효하지 않은 토큰입니다"
}

FAIL : 서버 내부 에러의 경우

{
    "success": false,
    "message": "서버 내부 오류"
}