Skip to content

게시물 수정

HwangJaeSuk edited this page Sep 3, 2019 · 3 revisions

게시물 수정 (/post/{postIdx})

postIdx는 수정하고 싶은 게시물의 id값입니다.

Request

URL

[PUT] ~/post/{postIdx}

Header

Key Value 설명
Content-Type multipart/form-data
token {user token} 토큰값

Body

변수 타입 설명
title String 게시물 제목
content String 게시물 내용
deadline String 마감 기한
areaCategory String 자치구 필터
ageCategory String 나이 필터
clothCategory String 카테고리 필터
postImages Files 게시물 사진들

※title, content, deadline, areaCategory, ageCategory, clothCategory, postImages는 선택해서 보내도 됩니다.


Response

Body

SUCCESS

{
    "status": 200,
    "success": true,
    "message": "게시물 수정 성공"
}

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

{
    "status": 400,
    "success": false,
    "message": "토큰값이 존재하지 않습니다."
}

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

{
    "status": 401,
    "success": false,
    "message": "잘못된 형식의 토큰입니다."
}

FAIL : 토큰값이 만료된 경우

{
    "status": 401,
    "success": false,
    "message": "만료된 토큰입니다."
}

FAIL : 서버 내부 에러의 경우

{
    "status": 600,
    "success": false,
    "message": "게시물 수정 실패"
}
Clone this wiki locally