Skip to content

Latest commit

 

History

History
174 lines (169 loc) · 45 KB

API 명세서.md

File metadata and controls

174 lines (169 loc) · 45 KB

API 명세서

API명세서 Notion에서 보기 : Link


PAGE[와이어프레임 페이지 아이디]분류메서드요청주소인풋 데이터인풋 데이터 타입아웃풋 데이터아웃풋 데이터 타입담당구현여부비고우선순위
#041공연 생성POST/performance/createRequestBody { title: (String), user_id : (metamask address), start_time : (datetime), end_time : (datatime), location: (String), price: (double), max_seats: (int), poster : (ipfs url), desc: (String), etc : (String) }application/json{ status_code : (int) message : (String) body : { performance_id: (int) left_minute_perform : (int) } } Json스프링
낮음
#021티켓 예매 홈GET/performance/home/{userId}PathVariable { user_id: (String) }String{ status_code: (int) message: (String) body : { like_performance: (array), 공연dto user_nickname: (String) open_soon : (array) , 공연dto perform_soon : (array) , 공연dto } }Json/list스프링
(오픈예정 공연 목록, 공연임박 홈화면, 좋아요 홈화면)

오픈 예정 공연목록 : 오픈 예정 이미지 해시값, 공연id 전송 공연임박 홈화면 : 공연 임박 이미지 해시값, 공연 id 전송 좋아요한 홈화면 : 좋아요한 공연 이미지 해시값, 공연 id 전송

status_code : 사용자 정의 코드 message : 사용자 정의 메시지 body : 아웃풋 데이터

필수
#028전체 공연 목록GET/performance/list/{cursorId}PathVariable { cursor_id: (Int) }

Int{ status_code : (int) message : (String) body : { cursor_id : (Int), performance_list : (array), 공연dto } }Json/list스프링
Front : 처음 Request 시 1을 보내주고 다음 스크롤 때 Request 부터 BackEnd 에서 Response 해준 cursorId 를 보냄필수
#029찜 목록 전체 보기 (유저가 좋아요 한 공연 전체 목록)GET/performance/likelist/{userId}/{cursorId}PathVariable { user_id: (String) cursor_id: (Int) ]String, Int{ status_code: (int) message: (String) body: { user_like_list: (array), 공연dto cursor_id: (Int) } }Json/list스프링
- 처음 로딩할 때 FE에서 0을 보내달라고 요청할 것 - 추가적으로 전달할 데이터가 없을 때 필수
#022공연 상세보기 (좋아요 여부 표시)GET/performance/{userId}/{performanceId}PathVariable { user_id: (String) performance_id: (Int) } String , Int{ status_code: (int) message: (String) body: { is_user_like : (boolean) performance_dto: (공연dto) can_reserve : (boolean) } }Json스프링
필수
#022좋아요 클릭PUT/performance/like/{userId}/{performanceId}PathVariable { user_id: (String) performance_id: (Int) }String , Int{ status_code: (int) message: (String) body : (boolean) }Json스프링
좋아요 여부 확인 후 진행 - 이미 클릭이 되었다면 → 취소 - 클릭된 적이 없다면 → 좋아요낮음
#023예매하기 버튼 클릭GET/performance/reserve/{performanceId}PathVariable{ performance_id: (Int) }Int{ status_code: (int) message: (String) body: { seats_state: (array), statusEnum perform : (공연dto) } }Json스프링
상세보기에서 예매하기 버튼을 눌렀을 시 / 좌석 정보를 다시 갱신해오고 싶을 때

👉 좌석별 예매가능여부 확인

필수
#023좌석 상태 변경PUT/perfomance/{performanceId}/{seatId}/{code}PathVariable { performance_id: (Int) seat_id: (Int) code: (int) }Int, Int, Int{ status_code: (int) message: (String) body : statusEnum }Json스프링
프론트에서 임의의 코드를 보내면 좌석 상태를 변경 (취소된 티켓을 스케줄러에 등록한 뒤에 일정시간뒤에 좌석상태를 예매 가능으로 돌림) ex) code 값 2 : 예약완료 상태로 바꾸기 3 : 구매중 상태로 바꾸기 5 : 취소 상태로 바꾸기 7 : EMPTY 상태로 바꾸기필수
#011티켓 취소PUT/ticket/cancel/{performanceId}/{seatId}performance_id: (Int) seat_id: (Int)Int , Int[{ status_code: (int) message: (String) }]솔리디티스프링
Spring : 공연+좌석번호 보내서 상태값 변경(구매 후 취소)필수
#001유저 로그인 체크GET/user/check/{userId}user_id : (String)String{     status_code: 200,     message: "기존유저",     body: null } or {     status_code: 400,     message: "회원가입 필요",     body: null }스프링
필수
#001닉네임 등록GET/user/make/{userId}/{nickname}user_id : (String) nickname : (String)String, String{ status_code: 200, message: "유저 입력 완료,   body: null }스프링
#023공연좌석 선택

GET/performance/reserve/{performanceId}/{seatId}performance_id: (Int) seat_id: (Int)Int, Int[{ status_code: (int) message: (String) body: [{ seat : (String) }] }]Json스프링
1인 1매만 가능 하므로 PathVariable로 처리 (Dto말고)필수
유저가 생성한 공연 목록GET/supervisor/list/{userId}user_id: (String)String{ status_code: 200,     message: ”유저가 생성한 공연”, body: user_created_list }Json/list
공연 입장 처리/
제목 없음
#041공연 이미지 입력 Web3제목 없음IPFS
필수
#041공연 생성Web3createPerformperformId : uint16 title : string description : string maxSeat : uint16 location : string price : uint256 day : uint256 hour : uint256 minute : uint256 poster : stringsend솔리디티
필수
#025티켓 민팅Web3createTicketperformId : uint16 userName : string seatNum : uint16payable솔리디티
필수
#012티켓 취소Web3cancleMyTickettokenId : uint256 performId : uint16payable솔리디티
#24환불 받는 금액 리턴Web3getNowRefundAmountperformId : uint16view
#025취소표 구매Web3buyCanceledTicketperformId: uint256 seatNum: uint16 userName : stringpayable솔리디티
#041비하인드 입력Web3insertPerformBehindperformId : uint16 behindAddress : stringsendIPFS솔리디티
#032비하인드 목록 Web3getBehindListperformId : uint16view솔리디티
필수
#002공연 전 티켓 목록Web3getBeforeTicketListview솔리디티
필수
#031공연 후 티켓 목록Web3getAfterTicketListview솔리디티
필수
다이어리 입력Web3insertTicketDiarytokenId : uint256 title : string subtitle : string content : string color : stringsend솔리디티
#032티켓 보관함 상세보기 리턴 (비하인드 리스트, Diary)Web3getTicketDetailstokenId : uint256 performId : uint16view솔리디티
#022해당공연티켓소유여부Web3isOwnerOfPerformperformId : uint16view솔리디티
티켓 포스터 주소Web3getTokenURLtokenId : uint256view솔리디티
티켓 정보 Web3getTicketInfotokenId : uint256view솔리디티
티켓 주인Web3getMintertokenId : uint256view솔리디티
계정 별 토큰 아이디들Web3getTicketsByAccountminter : addressview솔리디티
공연 정보Web3getPerformInfoperformId : uint16view솔리디티
공연 환불정보Web3getPerformRefundInfoperformId : uint16view솔리디티
공연 별 소유자들Web3getOwnersByPerformperformId : uint16view솔리디티
돈드립니다.Web3sendEtherpayable솔리디티