diff --git "a/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..f8abd39a --- /dev/null +++ "b/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\202\255\354\240\234.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 게시글 삭제Request { + // TODO: Define request type +} + +const 게시글 삭제 = async (): Promise<게시글 삭제Response> => { + const res = await axiosInstance.delete<게시글 삭제Response>( + `{` + ); + return res.data; +}; + +const use게시글 삭제 = () => { + return useMutation<게시글 삭제Response, AxiosError, 게시글 삭제Request>({ + mutationFn: (data) => 게시글 삭제({ data }), + }); +}; + +export default use게시글 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..b3e20747 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" @@ -0,0 +1,27 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 게시글 좋아요 삭제Request { + // TODO: Define request type +} + +export interface 게시글 좋아요 삭제Response { + likeCount: number; + isLiked: boolean; +} + +const 게시글 좋아요 삭제 = async (): Promise<게시글 좋아요 삭제Response> => { + const res = await axiosInstance.delete<게시글 좋아요 삭제Response>( + `{` + ); + return res.data; +}; + +const use게시글 좋아요 삭제 = () => { + return useMutation<게시글 좋아요 삭제Response, AxiosError, 게시글 좋아요 삭제Request>({ + mutationFn: (data) => 게시글 좋아요 삭제({ data }), + }); +}; + +export default use게시글 좋아요 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\353\214\223\352\270\200 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\353\214\223\352\270\200 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..d7c0adc0 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\353\214\223\352\270\200 \354\202\255\354\240\234.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 댓글 삭제Request { + // TODO: Define request type +} + +const 댓글 삭제 = async (): Promise<댓글 삭제Response> => { + const res = await axiosInstance.delete<댓글 삭제Response>( + `{` + ); + return res.data; +}; + +const use댓글 삭제 = () => { + return useMutation<댓글 삭제Response, AxiosError, 댓글 삭제Request>({ + mutationFn: (data) => 댓글 삭제({ data }), + }); +}; + +export default use댓글 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..1da2fdd4 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\202\255\354\240\234.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 소식지 삭제Request { + // TODO: Define request type +} + +const 소식지 삭제 = async (): Promise<소식지 삭제Response> => { + const res = await axiosInstance.delete<소식지 삭제Response>( + `{` + ); + return res.data; +}; + +const use소식지 삭제 = () => { + return useMutation<소식지 삭제Response, AxiosError, 소식지 삭제Request>({ + mutationFn: (data) => 소식지 삭제({ data }), + }); +}; + +export default use소식지 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..f62ba404 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\202\255\354\240\234.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 소식지 좋아요 삭제Request { + // TODO: Define request type +} + +const 소식지 좋아요 삭제 = async (): Promise<소식지 좋아요 삭제Response> => { + const res = await axiosInstance.delete<소식지 좋아요 삭제Response>( + `{` + ); + return res.data; +}; + +const use소식지 좋아요 삭제 = () => { + return useMutation<소식지 좋아요 삭제Response, AxiosError, 소식지 좋아요 삭제Request>({ + mutationFn: (data) => 소식지 좋아요 삭제({ data }), + }); +}; + +export default use소식지 좋아요 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\202\255\354\240\234.ts" "b/src/apis/Solid Connection/delete-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\202\255\354\240\234.ts" new file mode 100644 index 00000000..764236a2 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\202\255\354\240\234.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 위시 학교 삭제Request { + // TODO: Define request type +} + +const 위시 학교 삭제 = async (): Promise<위시 학교 삭제Response> => { + const res = await axiosInstance.delete<위시 학교 삭제Response>( + `{` + ); + return res.data; +}; + +const use위시 학교 삭제 = () => { + return useMutation<위시 학교 삭제Response, AxiosError, 위시 학교 삭제Request>({ + mutationFn: (data) => 위시 학교 삭제({ data }), + }); +}; + +export default use위시 학교 삭제; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\354\234\240\354\240\200 \354\260\250\353\213\250 \354\267\250\354\206\214.ts" "b/src/apis/Solid Connection/delete-\354\234\240\354\240\200 \354\260\250\353\213\250 \354\267\250\354\206\214.ts" new file mode 100644 index 00000000..ec451830 --- /dev/null +++ "b/src/apis/Solid Connection/delete-\354\234\240\354\240\200 \354\260\250\353\213\250 \354\267\250\354\206\214.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 유저 차단 취소Request { + // TODO: Define request type +} + +const 유저 차단 취소 = async (): Promise<유저 차단 취소Response> => { + const res = await axiosInstance.delete<유저 차단 취소Response>( + `{` + ); + return res.data; +}; + +const use유저 차단 취소 = () => { + return useMutation<유저 차단 취소Response, AxiosError, 유저 차단 취소Request>({ + mutationFn: (data) => 유저 차단 취소({ data }), + }); +}; + +export default use유저 차단 취소; \ No newline at end of file diff --git "a/src/apis/Solid Connection/delete-\355\232\214\354\233\220 \355\203\210\355\207\264.ts" "b/src/apis/Solid Connection/delete-\355\232\214\354\233\220 \355\203\210\355\207\264.ts" new file mode 100644 index 00000000..b4ee853e --- /dev/null +++ "b/src/apis/Solid Connection/delete-\355\232\214\354\233\220 \355\203\210\355\207\264.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 회원 탈퇴Request { + // TODO: Define request type +} + +const 회원 탈퇴 = async (): Promise<회원 탈퇴Response> => { + const res = await axiosInstance.delete<회원 탈퇴Response>( + `{` + ); + return res.data; +}; + +const use회원 탈퇴 = () => { + return useMutation<회원 탈퇴Response, AxiosError, 회원 탈퇴Request>({ + mutationFn: (data) => 회원 탈퇴({ data }), + }); +}; + +export default use회원 탈퇴; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\352\262\214\354\213\234\352\270\200 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\352\270\200 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..57a38ff3 --- /dev/null +++ "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\352\270\200 \354\241\260\355\232\214.ts" @@ -0,0 +1,49 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface PostFindCommentResponsesItem { + id: number; + parentId: null; + content: string; + isOwner: boolean; + createdAt: string; + updatedAt: string; + postFindSiteUserResponse: PostFindSiteUserResponse; +} + +export interface 게시글 조회Response { + id: number; + title: string; + content: string; + isQuestion: boolean; + likeCount: number; + viewCount: number; + commentCount: number; + postCategory: string; + isOwner: boolean; + isLiked: boolean; + createdAt: string; + updatedAt: string; + postFindBoardResponse: PostFindBoardResponse; + postFindSiteUserResponse: PostFindSiteUserResponse; + postFindCommentResponses: PostFindCommentResponsesItem[]; + postFindPostImageResponses: any[]; +} + +const 게시글 조회 = async (params: { params?: Record }): Promise<게시글 조회Response> => { + const res = await axiosInstance.get<게시글 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use게시글 조회 = (params?: Record) => { + return useQuery<게시글 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.게시글 조회, params], + queryFn: () => 게시글 조회({ params }), + }); +}; + +export default use게시글 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..5b26f068 --- /dev/null +++ "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 게시판 목록 조회 = async (params: { params?: Record }): Promise<게시판 목록 조회Response> => { + const res = await axiosInstance.get<게시판 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use게시판 목록 조회 = (params?: Record) => { + return useQuery<게시판 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.게시판 목록 조회, params], + queryFn: () => 게시판 목록 조회({ params }), + }); +}; + +export default use게시판 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..e96db62f --- /dev/null +++ "b/src/apis/Solid Connection/get-\352\262\214\354\213\234\355\214\220 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 게시판 조회 = async (params: { params?: Record }): Promise<게시판 조회Response> => { + const res = await axiosInstance.get<게시판 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use게시판 조회 = (params?: Record) => { + return useQuery<게시판 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.게시판 조회, params], + queryFn: () => 게시판 조회({ params }), + }); +}; + +export default use게시판 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\352\266\214\354\227\255\352\265\255\352\260\200\354\227\220 \355\225\264\353\213\271\355\225\230\353\212\224 \354\240\204\354\262\264 \353\214\200\355\225\231.ts" "b/src/apis/Solid Connection/get-\352\266\214\354\227\255\352\265\255\352\260\200\354\227\220 \355\225\264\353\213\271\355\225\230\353\212\224 \354\240\204\354\262\264 \353\214\200\355\225\231.ts" new file mode 100644 index 00000000..cb12b14f --- /dev/null +++ "b/src/apis/Solid Connection/get-\352\266\214\354\227\255\352\265\255\352\260\200\354\227\220 \355\225\264\353\213\271\355\225\230\353\212\224 \354\240\204\354\262\264 \353\214\200\355\225\231.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 권역국가에 해당하는 전체 대학 = async (params: { params?: Record }): Promise<권역국가에 해당하는 전체 대학Response> => { + const res = await axiosInstance.get<권역국가에 해당하는 전체 대학Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use권역국가에 해당하는 전체 대학 = (params?: Record) => { + return useQuery<권역국가에 해당하는 전체 대학Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.권역국가에 해당하는 전체 대학, params], + queryFn: () => 권역국가에 해당하는 전체 대학({ params }), + }); +}; + +export default use권역국가에 해당하는 전체 대학; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..dcb79374 --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\241\260\355\232\214.ts" @@ -0,0 +1,39 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface ChannelsItem { + type: string; + url: string; +} + +export interface 나의 멘토 페이지 조회Response { + id: number; + profileImageUrl: null; + nickname: string; + country: string; + universityName: string; + term: string; + menteeCount: number; + hasBadge: boolean; + introduction: string; + passTip: string; + channels: ChannelsItem[]; +} + +const 나의 멘토 페이지 조회 = async (params: { params?: Record }): Promise<나의 멘토 페이지 조회Response> => { + const res = await axiosInstance.get<나의 멘토 페이지 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use나의 멘토 페이지 조회 = (params?: Record) => { + return useQuery<나의 멘토 페이지 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.나의 멘토 페이지 조회, params], + queryFn: () => 나의 멘토 페이지 조회({ params }), + }); +}; + +export default use나의 멘토 페이지 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\202\230\354\235\230 \354\247\200\354\233\220\352\263\274 \353\217\231\354\235\274\355\225\234 \354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\353\202\230\354\235\230 \354\247\200\354\233\220\352\263\274 \353\217\231\354\235\274\355\225\234 \354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..370e8005 --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\202\230\354\235\230 \354\247\200\354\233\220\352\263\274 \353\217\231\354\235\274\355\225\234 \354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 나의 지원과 동일한 지원자 현황 조회 = async (params: { params?: Record }): Promise<나의 지원과 동일한 지원자 현황 조회Response> => { + const res = await axiosInstance.get<나의 지원과 동일한 지원자 현황 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use나의 지원과 동일한 지원자 현황 조회 = (params?: Record) => { + return useQuery<나의 지원과 동일한 지원자 현황 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.나의 지원과 동일한 지원자 현황 조회, params], + queryFn: () => 나의 지원과 동일한 지원자 현황 조회({ params }), + }); +}; + +export default use나의 지원과 동일한 지원자 현황 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\202\264 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\353\202\264 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..b84a195b --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\202\264 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" @@ -0,0 +1,32 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 내 정보 조회Response { + likedUniversityCount: number; + nickname: string; + profileImageUrl: string; + role: string; + authType: string; + email: string; + likedPostCount: number; + likedMentorCount: number; + interestedCountries: string[]; +} + +const 내 정보 조회 = async (params: { params?: Record }): Promise<내 정보 조회Response> => { + const res = await axiosInstance.get<내 정보 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use내 정보 조회 = (params?: Record) => { + return useQuery<내 정보 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.내 정보 조회, params], + queryFn: () => 내 정보 조회({ params }), + }); +}; + +export default use내 정보 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\213\211\353\204\244\354\236\204 \354\244\221\353\263\265 \352\262\200\354\246\235.ts" "b/src/apis/Solid Connection/get-\353\213\211\353\204\244\354\236\204 \354\244\221\353\263\265 \352\262\200\354\246\235.ts" new file mode 100644 index 00000000..10a28539 --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\213\211\353\204\244\354\236\204 \354\244\221\353\263\265 \352\262\200\354\246\235.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 닉네임 중복 검증 = async (params: { params?: Record }): Promise<닉네임 중복 검증Response> => { + const res = await axiosInstance.get<닉네임 중복 검증Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use닉네임 중복 검증 = (params?: Record) => { + return useQuery<닉네임 중복 검증Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.닉네임 중복 검증, params], + queryFn: () => 닉네임 중복 검증({ params }), + }); +}; + +export default use닉네임 중복 검증; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\247\244\354\271\255\353\220\234 \353\251\230\355\206\240 \353\252\251\353\241\235.ts" "b/src/apis/Solid Connection/get-\353\247\244\354\271\255\353\220\234 \353\251\230\355\206\240 \353\252\251\353\241\235.ts" new file mode 100644 index 00000000..7c4295f1 --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\247\244\354\271\255\353\220\234 \353\251\230\355\206\240 \353\252\251\353\241\235.ts" @@ -0,0 +1,40 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface ContentItem { + id: number; + roomId: number; + nickname: string; + profileImageUrl: string; + country: string; + universityName: string; + term: string; + menteeCount: number; + hasBadge: boolean; + introduction: string; + channels: any[]; + isApplied: boolean; +} + +export interface 매칭된 멘토 목록Response { + content: ContentItem[]; + nextPageNumber: number; +} + +const 매칭된 멘토 목록 = async (params: { params?: Record }): Promise<매칭된 멘토 목록Response> => { + const res = await axiosInstance.get<매칭된 멘토 목록Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use매칭된 멘토 목록 = (params?: Record) => { + return useQuery<매칭된 멘토 목록Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.매칭된 멘토 목록, params], + queryFn: () => 매칭된 멘토 목록({ params }), + }); +}; + +export default use매칭된 멘토 목록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\251\230\355\206\240 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\353\251\230\355\206\240 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..0f58224d --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\251\230\355\206\240 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 멘토 목록 조회 = async (params: { params?: Record }): Promise<멘토 목록 조회Response> => { + const res = await axiosInstance.get<멘토 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use멘토 목록 조회 = (params?: Record) => { + return useQuery<멘토 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.멘토 목록 조회, params], + queryFn: () => 멘토 목록 조회({ params }), + }); +}; + +export default use멘토 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\353\251\230\355\206\240 \354\203\201\354\204\270 \355\216\230\354\235\264\354\247\200.ts" "b/src/apis/Solid Connection/get-\353\251\230\355\206\240 \354\203\201\354\204\270 \355\216\230\354\235\264\354\247\200.ts" new file mode 100644 index 00000000..804097c9 --- /dev/null +++ "b/src/apis/Solid Connection/get-\353\251\230\355\206\240 \354\203\201\354\204\270 \355\216\230\354\235\264\354\247\200.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 멘토 상세 페이지 = async (params: { params?: Record }): Promise<멘토 상세 페이지Response> => { + const res = await axiosInstance.get<멘토 상세 페이지Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use멘토 상세 페이지 = (params?: Record) => { + return useQuery<멘토 상세 페이지Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.멘토 상세 페이지, params], + queryFn: () => 멘토 상세 페이지({ params }), + }); +}; + +export default use멘토 상세 페이지; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 id \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 id \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..b10666ac --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 id \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,24 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 사용자 id 목록 조회Response { + // TODO: Define response type +} + +const 사용자 id 목록 조회 = async (params: { params?: Record }): Promise<사용자 id 목록 조회Response> => { + const res = await axiosInstance.get<사용자 id 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use사용자 id 목록 조회 = (params?: Record) => { + return useQuery<사용자 id 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.사용자 id 목록 조회, params], + queryFn: () => 사용자 id 목록 조회({ params }), + }); +}; + +export default use사용자 id 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 \353\247\236\354\266\244 \353\214\200\355\225\231 \354\266\224\354\262\234.ts" "b/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 \353\247\236\354\266\244 \353\214\200\355\225\231 \354\266\224\354\262\234.ts" new file mode 100644 index 00000000..f81d5ce4 --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\202\254\354\232\251\354\236\220 \353\247\236\354\266\244 \353\214\200\355\225\231 \354\266\224\354\262\234.ts" @@ -0,0 +1,24 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 사용자 맞춤 대학 추천Response { + // TODO: Define response type +} + +const 사용자 맞춤 대학 추천 = async (params: { params?: Record }): Promise<사용자 맞춤 대학 추천Response> => { + const res = await axiosInstance.get<사용자 맞춤 대학 추천Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use사용자 맞춤 대학 추천 = (params?: Record) => { + return useQuery<사용자 맞춤 대학 추천Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.사용자 맞춤 대학 추천, params], + queryFn: () => 사용자 맞춤 대학 추천({ params }), + }); +}; + +export default use사용자 맞춤 대학 추천; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\206\214\354\213\235\354\247\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\206\214\354\213\235\354\247\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..ff71139e --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\206\214\354\213\235\354\247\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 소식지 목록 조회 = async (params: { params?: Record }): Promise<소식지 목록 조회Response> => { + const res = await axiosInstance.get<소식지 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use소식지 목록 조회 = (params?: Record) => { + return useQuery<소식지 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.소식지 목록 조회, params], + queryFn: () => 소식지 목록 조회({ params }), + }); +}; + +export default use소식지 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\213\240\354\262\255\353\260\233\354\235\200 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" "b/src/apis/Solid Connection/get-\354\213\240\354\262\255\353\260\233\354\235\200 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" new file mode 100644 index 00000000..e009b9be --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\213\240\354\262\255\353\260\233\354\235\200 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" @@ -0,0 +1,34 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface ContentItem { + mentoringId: number; + profileImageUrl: null; + nickname: string; + isChecked: boolean; + verifyStatus: string; + createdAt: string; +} + +export interface 신청받은 멘토링 목록Response { + content: ContentItem[]; + nextPageNumber: number; +} + +const 신청받은 멘토링 목록 = async (params: { params?: Record }): Promise<신청받은 멘토링 목록Response> => { + const res = await axiosInstance.get<신청받은 멘토링 목록Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use신청받은 멘토링 목록 = (params?: Record) => { + return useQuery<신청받은 멘토링 목록Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.신청받은 멘토링 목록, params], + queryFn: () => 신청받은 멘토링 목록({ params }), + }); +}; + +export default use신청받은 멘토링 목록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\213\240\354\262\255\355\225\234 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" "b/src/apis/Solid Connection/get-\354\213\240\354\262\255\355\225\234 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" new file mode 100644 index 00000000..d1c530bf --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\213\240\354\262\255\355\225\234 \353\251\230\355\206\240\353\247\201 \353\252\251\353\241\235.ts" @@ -0,0 +1,34 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface ContentItem { + mentoringId: number; + profileImageUrl: null; + nickname: string; + isChecked: boolean; + createdAt: string; + chatRoomId: number; +} + +export interface 신청한 멘토링 목록Response { + content: ContentItem[]; + nextPageNumber: number; +} + +const 신청한 멘토링 목록 = async (params: { params?: Record }): Promise<신청한 멘토링 목록Response> => { + const res = await axiosInstance.get<신청한 멘토링 목록Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use신청한 멘토링 목록 = (params?: Record) => { + return useQuery<신청한 멘토링 목록Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.신청한 멘토링 목록, params], + queryFn: () => 신청한 멘토링 목록({ params }), + }); +}; + +export default use신청한 멘토링 목록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\204\261\354\240\201 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\204\261\354\240\201 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..ce4201bd --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\204\261\354\240\201 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 어학 성적 조회 = async (params: { params?: Record }): Promise<어학 성적 조회Response> => { + const res = await axiosInstance.get<어학 성적 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use어학 성적 조회 = (params?: Record) => { + return useQuery<어학 성적 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.어학 성적 조회, params], + queryFn: () => 어학 성적 조회({ params }), + }); +}; + +export default use어학 성적 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..c2f40d4d --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\226\264\355\225\231 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 어학 조회 = async (params: { params?: Record }): Promise<어학 조회Response> => { + const res = await axiosInstance.get<어학 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use어학 조회 = (params?: Record) => { + return useQuery<어학 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.어학 조회, params], + queryFn: () => 어학 조회({ params }), + }); +}; + +export default use어학 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..fe3cea05 --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 위시 학교 목록 조회 = async (params: { params?: Record }): Promise<위시 학교 목록 조회Response> => { + const res = await axiosInstance.get<위시 학교 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use위시 학교 목록 조회 = (params?: Record) => { + return useQuery<위시 학교 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.위시 학교 목록 조회, params], + queryFn: () => 위시 학교 목록 조회({ params }), + }); +}; + +export default use위시 학교 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220\354\235\270\354\247\200 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220\354\235\270\354\247\200 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..0463957e --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\234\204\354\213\234 \355\225\231\352\265\220\354\235\270\354\247\200 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 위시 학교인지 조회 = async (params: { params?: Record }): Promise<위시 학교인지 조회Response> => { + const res = await axiosInstance.get<위시 학교인지 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use위시 학교인지 조회 = (params?: Record) => { + return useQuery<위시 학교인지 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.위시 학교인지 조회, params], + queryFn: () => 위시 학교인지 조회({ params }), + }); +}; + +export default use위시 학교인지 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\240\225\353\263\264 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\240\225\353\263\264 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..6231e24f --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\240\225\353\263\264 \354\241\260\355\232\214.ts" @@ -0,0 +1,24 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 정보 조회Response { + // TODO: Define response type +} + +const 정보 조회 = async (params: { params?: Record }): Promise<정보 조회Response> => { + const res = await axiosInstance.get<정보 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use정보 조회 = (params?: Record) => { + return useQuery<정보 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.정보 조회, params], + queryFn: () => 정보 조회({ params }), + }); +}; + +export default use정보 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..f53a0e96 --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\247\200\354\233\220\354\236\220 \355\230\204\355\231\251 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 지원자 현황 조회 = async (params: { params?: Record }): Promise<지원자 현황 조회Response> => { + const res = await axiosInstance.get<지원자 현황 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use지원자 현황 조회 = (params?: Record) => { + return useQuery<지원자 현황 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.지원자 현황 조회, params], + queryFn: () => 지원자 현황 조회({ params }), + }); +}; + +export default use지원자 현황 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\260\250\353\213\250\355\225\234 \354\234\240\354\240\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\260\250\353\213\250\355\225\234 \354\234\240\354\240\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..5cdf4e2d --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\260\250\353\213\250\355\225\234 \354\234\240\354\240\200 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,32 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface ContentItem { + id: number; + blockedId: number; + nickname: string; + createdAt: string; +} + +export interface 차단한 유저 목록 조회Response { + content: ContentItem[]; + nextPageNumber: number; +} + +const 차단한 유저 목록 조회 = async (params: { params?: Record }): Promise<차단한 유저 목록 조회Response> => { + const res = await axiosInstance.get<차단한 유저 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use차단한 유저 목록 조회 = (params?: Record) => { + return useQuery<차단한 유저 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.차단한 유저 목록 조회, params], + queryFn: () => 차단한 유저 목록 조회({ params }), + }); +}; + +export default use차단한 유저 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\261\204\355\214\205 \353\202\264\354\227\255 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\261\204\355\214\205 \353\202\264\354\227\255 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..24169d8a --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\261\204\355\214\205 \353\202\264\354\227\255 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 채팅 내역 조회 = async (params: { params?: Record }): Promise<채팅 내역 조회Response> => { + const res = await axiosInstance.get<채팅 내역 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use채팅 내역 조회 = (params?: Record) => { + return useQuery<채팅 내역 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.채팅 내역 조회, params], + queryFn: () => 채팅 내역 조회({ params }), + }); +}; + +export default use채팅 내역 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..df8296c3 --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \353\252\251\353\241\235 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 채팅방 목록 조회 = async (params: { params?: Record }): Promise<채팅방 목록 조회Response> => { + const res = await axiosInstance.get<채팅방 목록 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use채팅방 목록 조회 = (params?: Record) => { + return useQuery<채팅방 목록 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.채팅방 목록 조회, params], + queryFn: () => 채팅방 목록 조회({ params }), + }); +}; + +export default use채팅방 목록 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \355\214\214\355\212\270\353\204\210 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \355\214\214\355\212\270\353\204\210 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..161fb0f5 --- /dev/null +++ "b/src/apis/Solid Connection/get-\354\261\204\355\214\205\353\260\251 \355\214\214\355\212\270\353\204\210 \354\241\260\355\232\214.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 채팅방 파트너 조회Response { + partnerId: number; + nickname: string; + profileUrl: string; +} + +const 채팅방 파트너 조회 = async (params: { params?: Record }): Promise<채팅방 파트너 조회Response> => { + const res = await axiosInstance.get<채팅방 파트너 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use채팅방 파트너 조회 = (params?: Record) => { + return useQuery<채팅방 파트너 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.채팅방 파트너 조회, params], + queryFn: () => 채팅방 파트너 조회({ params }), + }); +}; + +export default use채팅방 파트너 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\225\231\352\265\220 \354\203\201\354\204\270 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \354\203\201\354\204\270 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..222cac14 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \354\203\201\354\204\270 \354\240\225\353\263\264 \354\241\260\355\232\214.ts" @@ -0,0 +1,54 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface LanguageRequirementsItem { + languageTestType: string; + minScore: string; +} + +export interface 학교 상세 정보 조회Response { + id: number; + term: string; + koreanName: string; + englishName: string; + formatName: string; + region: string; + country: string; + homepageUrl: string; + logoImageUrl: string; + backgroundImageUrl: string; + detailsForLocal: string; + studentCapacity: number; + tuitionFeeType: string; + semesterAvailableForDispatch: string; + languageRequirements: LanguageRequirementsItem[]; + detailsForLanguage: string; + gpaRequirement: string; + gpaRequirementCriteria: string; + semesterRequirement: string; + detailsForApply: null; + detailsForMajor: string; + detailsForAccommodation: null; + detailsForEnglishCourse: null; + details: string; + accommodationUrl: string; + englishCourseUrl: string; +} + +const 학교 상세 정보 조회 = async (params: { params?: Record }): Promise<학교 상세 정보 조회Response> => { + const res = await axiosInstance.get<학교 상세 정보 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use학교 상세 정보 조회 = (params?: Record) => { + return useQuery<학교 상세 정보 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.학교 상세 정보 조회, params], + queryFn: () => 학교 상세 정보 조회({ params }), + }); +}; + +export default use학교 상세 정보 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\205\215\354\212\244\355\212\270 \352\262\200\354\203\211.ts" "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\205\215\354\212\244\355\212\270 \352\262\200\354\203\211.ts" new file mode 100644 index 00000000..5e8fe549 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\205\215\354\212\244\355\212\270 \352\262\200\354\203\211.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 학교 텍스트 검색 = async (params: { params?: Record }): Promise<학교 텍스트 검색Response> => { + const res = await axiosInstance.get<학교 텍스트 검색Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use학교 텍스트 검색 = (params?: Record) => { + return useQuery<학교 텍스트 검색Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.학교 텍스트 검색, params], + queryFn: () => 학교 텍스트 검색({ params }), + }); +}; + +export default use학교 텍스트 검색; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\225\204\355\204\260 \352\262\200\354\203\211.ts" "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\225\204\355\204\260 \352\262\200\354\203\211.ts" new file mode 100644 index 00000000..21cefd47 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\225\231\352\265\220 \355\225\204\355\204\260 \352\262\200\354\203\211.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 학교 필터 검색 = async (params: { params?: Record }): Promise<학교 필터 검색Response> => { + const res = await axiosInstance.get<학교 필터 검색Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use학교 필터 검색 = (params?: Record) => { + return useQuery<학교 필터 검색Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.학교 필터 검색, params], + queryFn: () => 학교 필터 검색({ params }), + }); +}; + +export default use학교 필터 검색; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\225\231\354\240\220 \354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\355\225\231\354\240\220 \354\241\260\355\232\214.ts" new file mode 100644 index 00000000..e63efc55 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\225\231\354\240\220 \354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 학점 조회 = async (params: { params?: Record }): Promise<학점 조회Response> => { + const res = await axiosInstance.get<학점 조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use학점 조회 = (params?: Record) => { + return useQuery<학점 조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.학점 조회, params], + queryFn: () => 학점 조회({ params }), + }); +}; + +export default use학점 조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\225\231\354\240\220\354\241\260\355\232\214.ts" "b/src/apis/Solid Connection/get-\355\225\231\354\240\220\354\241\260\355\232\214.ts" new file mode 100644 index 00000000..117e5636 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\225\231\354\240\220\354\241\260\355\232\214.ts" @@ -0,0 +1,20 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +const 학점조회 = async (params: { params?: Record }): Promise<학점조회Response> => { + const res = await axiosInstance.get<학점조회Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use학점조회 = (params?: Record) => { + return useQuery<학점조회Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.학점조회, params], + queryFn: () => 학점조회({ params }), + }); +}; + +export default use학점조회; \ No newline at end of file diff --git "a/src/apis/Solid Connection/get-\355\231\225\354\235\270\355\225\230\354\247\200 \354\225\212\354\235\200 \353\251\230\355\206\240\353\247\201 \354\210\230.ts" "b/src/apis/Solid Connection/get-\355\231\225\354\235\270\355\225\230\354\247\200 \354\225\212\354\235\200 \353\251\230\355\206\240\353\247\201 \354\210\230.ts" new file mode 100644 index 00000000..d7f47e10 --- /dev/null +++ "b/src/apis/Solid Connection/get-\355\231\225\354\235\270\355\225\230\354\247\200 \354\225\212\354\235\200 \353\251\230\355\206\240\353\247\201 \354\210\230.ts" @@ -0,0 +1,24 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { QueryKeys } from "../queryKeys"; +import { useQuery } from "@tanstack/react-query"; + +export interface 확인하지 않은 멘토링 수Response { + uncheckedCount: number; +} + +const 확인하지 않은 멘토링 수 = async (params: { params?: Record }): Promise<확인하지 않은 멘토링 수Response> => { + const res = await axiosInstance.get<확인하지 않은 멘토링 수Response>( + `{`, { params: params?.params } + ); + return res.data; +}; + +const use확인하지 않은 멘토링 수 = (params?: Record) => { + return useQuery<확인하지 않은 멘토링 수Response, AxiosError>({ + queryKey: [QueryKeys.solid Connection.확인하지 않은 멘토링 수, params], + queryFn: () => 확인하지 않은 멘토링 수({ params }), + }); +}; + +export default use확인하지 않은 멘토링 수; \ No newline at end of file diff --git a/src/apis/Solid Connection/index.ts b/src/apis/Solid Connection/index.ts new file mode 100644 index 00000000..0e7ff839 --- /dev/null +++ b/src/apis/Solid Connection/index.ts @@ -0,0 +1,77 @@ +export { default as delete-게시글 삭제 } from './delete-게시글 삭제'; +export { default as delete-게시글 좋아요 삭제 } from './delete-게시글 좋아요 삭제'; +export { default as delete-댓글 삭제 } from './delete-댓글 삭제'; +export { default as delete-소식지 삭제 } from './delete-소식지 삭제'; +export { default as delete-소식지 좋아요 삭제 } from './delete-소식지 좋아요 삭제'; +export { default as delete-위시 학교 삭제 } from './delete-위시 학교 삭제'; +export { default as delete-유저 차단 취소 } from './delete-유저 차단 취소'; +export { default as delete-회원 탈퇴 } from './delete-회원 탈퇴'; +export { default as get-게시글 조회 } from './get-게시글 조회'; +export { default as get-게시판 목록 조회 } from './get-게시판 목록 조회'; +export { default as get-게시판 조회 } from './get-게시판 조회'; +export { default as get-권역국가에 해당하는 전체 대학 } from './get-권역국가에 해당하는 전체 대학'; +export { default as get-나의 멘토 페이지 조회 } from './get-나의 멘토 페이지 조회'; +export { default as get-나의 지원과 동일한 지원자 현황 조회 } from './get-나의 지원과 동일한 지원자 현황 조회'; +export { default as get-내 정보 조회 } from './get-내 정보 조회'; +export { default as get-닉네임 중복 검증 } from './get-닉네임 중복 검증'; +export { default as get-매칭된 멘토 목록 } from './get-매칭된 멘토 목록'; +export { default as get-멘토 목록 조회 } from './get-멘토 목록 조회'; +export { default as get-멘토 상세 페이지 } from './get-멘토 상세 페이지'; +export { default as get-사용자 id 목록 조회 } from './get-사용자 id 목록 조회'; +export { default as get-사용자 맞춤 대학 추천 } from './get-사용자 맞춤 대학 추천'; +export { default as get-소식지 목록 조회 } from './get-소식지 목록 조회'; +export { default as get-신청받은 멘토링 목록 } from './get-신청받은 멘토링 목록'; +export { default as get-신청한 멘토링 목록 } from './get-신청한 멘토링 목록'; +export { default as get-어학 성적 조회 } from './get-어학 성적 조회'; +export { default as get-어학 조회 } from './get-어학 조회'; +export { default as get-위시 학교 목록 조회 } from './get-위시 학교 목록 조회'; +export { default as get-위시 학교인지 조회 } from './get-위시 학교인지 조회'; +export { default as get-정보 조회 } from './get-정보 조회'; +export { default as get-지원자 현황 조회 } from './get-지원자 현황 조회'; +export { default as get-차단한 유저 목록 조회 } from './get-차단한 유저 목록 조회'; +export { default as get-채팅 내역 조회 } from './get-채팅 내역 조회'; +export { default as get-채팅방 목록 조회 } from './get-채팅방 목록 조회'; +export { default as get-채팅방 파트너 조회 } from './get-채팅방 파트너 조회'; +export { default as get-학교 상세 정보 조회 } from './get-학교 상세 정보 조회'; +export { default as get-학교 텍스트 검색 } from './get-학교 텍스트 검색'; +export { default as get-학교 필터 검색 } from './get-학교 필터 검색'; +export { default as get-학점 조회 } from './get-학점 조회'; +export { default as get-학점조회 } from './get-학점조회'; +export { default as get-확인하지 않은 멘토링 수 } from './get-확인하지 않은 멘토링 수'; +export { default as patch-게시글 수정 } from './patch-게시글 수정'; +export { default as patch-관심 권역국가 변경 } from './patch-관심 권역국가 변경'; +export { default as patch-내 정보 수정 } from './patch-내 정보 수정'; +export { default as patch-댓글 수정 } from './patch-댓글 수정'; +export { default as patch-멘토링 수락거절 } from './patch-멘토링 수락거절'; +export { default as patch-멘토링 확인 } from './patch-멘토링 확인'; +export { default as patch-비밀번호 변경 } from './patch-비밀번호 변경'; +export { default as post-게시글 작성 } from './post-게시글 작성'; +export { default as post-게시글 좋아요 등록 } from './post-게시글 좋아요 등록'; +export { default as post-댓글 작성 } from './post-댓글 작성'; +export { default as post-로그아웃 } from './post-로그아웃'; +export { default as post-멘토링 신청 } from './post-멘토링 신청'; +export { default as post-소식지 좋아요 추가 } from './post-소식지 좋아요 추가'; +export { default as post-소식지 추가 } from './post-소식지 추가'; +export { default as post-슬랙 알림 } from './post-슬랙 알림'; +export { default as post-신고하기 } from './post-신고하기'; +export { default as post-애플 인증 (로그인 or 가입 코드 발급) } from './post-애플 인증 (로그인 or 가입 코드 발급)'; +export { default as post-어학 성적 등록 } from './post-어학 성적 등록'; +export { default as post-어학 성적표 업로드 } from './post-어학 성적표 업로드'; +export { default as post-엑세스 토큰 재발급 } from './post-엑세스 토큰 재발급'; +export { default as post-연결 끊기 } from './post-연결 끊기'; +export { default as post-위시 학교 추가 } from './post-위시 학교 추가'; +export { default as post-유저 차단 } from './post-유저 차단'; +export { default as post-이메일 로그인 } from './post-이메일 로그인'; +export { default as post-이메일 인증 (가입 코드 발급) } from './post-이메일 인증 (가입 코드 발급)'; +export { default as post-지원서 제출 } from './post-지원서 제출'; +export { default as post-카카오 인증 (로그인 or 가입 코드 발급) } from './post-카카오 인증 (로그인 or 가입 코드 발급)'; +export { default as post-프로필 사진 업로드 (가입 전) } from './post-프로필 사진 업로드 (가입 전)'; +export { default as post-프로필 사진 업로드 (가입 후) } from './post-프로필 사진 업로드 (가입 후)'; +export { default as post-학적 성적표 업로드 } from './post-학적 성적표 업로드'; +export { default as post-학점 등록 } from './post-학점 등록'; +export { default as post-회원가입 } from './post-회원가입'; +export { default as put-나의 멘토 페이지 수정 } from './put-나의 멘토 페이지 수정'; +export { default as put-소식지 수정 } from './put-소식지 수정'; +export { default as put-어학 검증 및 수정 } from './put-어학 검증 및 수정'; +export { default as put-채팅방 읽음 처리 } from './put-채팅방 읽음 처리'; +export { default as put-학점 검증 및 수정 } from './put-학점 검증 및 수정'; diff --git "a/src/apis/Solid Connection/patch-\352\262\214\354\213\234\352\270\200 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/patch-\352\262\214\354\213\234\352\270\200 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..59f28edb --- /dev/null +++ "b/src/apis/Solid Connection/patch-\352\262\214\354\213\234\352\270\200 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 게시글 수정Request { + // TODO: Define request type +} + +const 게시글 수정 = async (params: { data?: 게시글 수정Request }): Promise<게시글 수정Response> => { + const res = await axiosInstance.patch<게시글 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use게시글 수정 = () => { + return useMutation<게시글 수정Response, AxiosError, 게시글 수정Request>({ + mutationFn: (data) => 게시글 수정({ data }), + }); +}; + +export default use게시글 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\352\264\200\354\213\254 \352\266\214\354\227\255\352\265\255\352\260\200 \353\263\200\352\262\275.ts" "b/src/apis/Solid Connection/patch-\352\264\200\354\213\254 \352\266\214\354\227\255\352\265\255\352\260\200 \353\263\200\352\262\275.ts" new file mode 100644 index 00000000..bfe788f8 --- /dev/null +++ "b/src/apis/Solid Connection/patch-\352\264\200\354\213\254 \352\266\214\354\227\255\352\265\255\352\260\200 \353\263\200\352\262\275.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 관심 권역국가 변경Request { + // TODO: Define request type +} + +const 관심 권역국가 변경 = async (params: { data?: 관심 권역국가 변경Request }): Promise<관심 권역국가 변경Response> => { + const res = await axiosInstance.patch<관심 권역국가 변경Response>( + `{`, params?.data + ); + return res.data; +}; + +const use관심 권역국가 변경 = () => { + return useMutation<관심 권역국가 변경Response, AxiosError, 관심 권역국가 변경Request>({ + mutationFn: (data) => 관심 권역국가 변경({ data }), + }); +}; + +export default use관심 권역국가 변경; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\353\202\264 \354\240\225\353\263\264 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/patch-\353\202\264 \354\240\225\353\263\264 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..0c1574b9 --- /dev/null +++ "b/src/apis/Solid Connection/patch-\353\202\264 \354\240\225\353\263\264 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 내 정보 수정Request { + // TODO: Define request type +} + +const 내 정보 수정 = async (params: { data?: 내 정보 수정Request }): Promise<내 정보 수정Response> => { + const res = await axiosInstance.patch<내 정보 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use내 정보 수정 = () => { + return useMutation<내 정보 수정Response, AxiosError, 내 정보 수정Request>({ + mutationFn: (data) => 내 정보 수정({ data }), + }); +}; + +export default use내 정보 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\353\214\223\352\270\200 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/patch-\353\214\223\352\270\200 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..9756091f --- /dev/null +++ "b/src/apis/Solid Connection/patch-\353\214\223\352\270\200 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 댓글 수정Request { + // TODO: Define request type +} + +const 댓글 수정 = async (params: { data?: 댓글 수정Request }): Promise<댓글 수정Response> => { + const res = await axiosInstance.patch<댓글 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use댓글 수정 = () => { + return useMutation<댓글 수정Response, AxiosError, 댓글 수정Request>({ + mutationFn: (data) => 댓글 수정({ data }), + }); +}; + +export default use댓글 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \354\210\230\353\235\275\352\261\260\354\240\210.ts" "b/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \354\210\230\353\235\275\352\261\260\354\240\210.ts" new file mode 100644 index 00000000..72b3b0c0 --- /dev/null +++ "b/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \354\210\230\353\235\275\352\261\260\354\240\210.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 멘토링 수락거절Request { + // TODO: Define request type +} + +export interface 멘토링 수락거절Response { + mentoringId: number; +} + +const 멘토링 수락거절 = async (params: { data?: 멘토링 수락거절Request }): Promise<멘토링 수락거절Response> => { + const res = await axiosInstance.patch<멘토링 수락거절Response>( + `{`, params?.data + ); + return res.data; +}; + +const use멘토링 수락거절 = () => { + return useMutation<멘토링 수락거절Response, AxiosError, 멘토링 수락거절Request>({ + mutationFn: (data) => 멘토링 수락거절({ data }), + }); +}; + +export default use멘토링 수락거절; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \355\231\225\354\235\270.ts" "b/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \355\231\225\354\235\270.ts" new file mode 100644 index 00000000..f499ba08 --- /dev/null +++ "b/src/apis/Solid Connection/patch-\353\251\230\355\206\240\353\247\201 \355\231\225\354\235\270.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 멘토링 확인Request { + // TODO: Define request type +} + +export interface 멘토링 확인Response { + checkedMentoringIds: number[]; +} + +const 멘토링 확인 = async (params: { data?: 멘토링 확인Request }): Promise<멘토링 확인Response> => { + const res = await axiosInstance.patch<멘토링 확인Response>( + `{`, params?.data + ); + return res.data; +}; + +const use멘토링 확인 = () => { + return useMutation<멘토링 확인Response, AxiosError, 멘토링 확인Request>({ + mutationFn: (data) => 멘토링 확인({ data }), + }); +}; + +export default use멘토링 확인; \ No newline at end of file diff --git "a/src/apis/Solid Connection/patch-\353\271\204\353\260\200\353\262\210\355\230\270 \353\263\200\352\262\275.ts" "b/src/apis/Solid Connection/patch-\353\271\204\353\260\200\353\262\210\355\230\270 \353\263\200\352\262\275.ts" new file mode 100644 index 00000000..9ee54623 --- /dev/null +++ "b/src/apis/Solid Connection/patch-\353\271\204\353\260\200\353\262\210\355\230\270 \353\263\200\352\262\275.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 비밀번호 변경Request { + // TODO: Define request type +} + +const 비밀번호 변경 = async (params: { data?: 비밀번호 변경Request }): Promise<비밀번호 변경Response> => { + const res = await axiosInstance.patch<비밀번호 변경Response>( + `{`, params?.data + ); + return res.data; +}; + +const use비밀번호 변경 = () => { + return useMutation<비밀번호 변경Response, AxiosError, 비밀번호 변경Request>({ + mutationFn: (data) => 비밀번호 변경({ data }), + }); +}; + +export default use비밀번호 변경; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\236\221\354\204\261.ts" "b/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\236\221\354\204\261.ts" new file mode 100644 index 00000000..8c148387 --- /dev/null +++ "b/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\236\221\354\204\261.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 게시글 작성Request { + // TODO: Define request type +} + +const 게시글 작성 = async (params: { data?: 게시글 작성Request }): Promise<게시글 작성Response> => { + const res = await axiosInstance.post<게시글 작성Response>( + `{`, params?.data + ); + return res.data; +}; + +const use게시글 작성 = () => { + return useMutation<게시글 작성Response, AxiosError, 게시글 작성Request>({ + mutationFn: (data) => 게시글 작성({ data }), + }); +}; + +export default use게시글 작성; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \353\223\261\353\241\235.ts" "b/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \353\223\261\353\241\235.ts" new file mode 100644 index 00000000..65567dcb --- /dev/null +++ "b/src/apis/Solid Connection/post-\352\262\214\354\213\234\352\270\200 \354\242\213\354\225\204\354\232\224 \353\223\261\353\241\235.ts" @@ -0,0 +1,27 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 게시글 좋아요 등록Request { + // TODO: Define request type +} + +export interface 게시글 좋아요 등록Response { + likeCount: number; + isLiked: boolean; +} + +const 게시글 좋아요 등록 = async (params: { data?: 게시글 좋아요 등록Request }): Promise<게시글 좋아요 등록Response> => { + const res = await axiosInstance.post<게시글 좋아요 등록Response>( + `{`, params?.data + ); + return res.data; +}; + +const use게시글 좋아요 등록 = () => { + return useMutation<게시글 좋아요 등록Response, AxiosError, 게시글 좋아요 등록Request>({ + mutationFn: (data) => 게시글 좋아요 등록({ data }), + }); +}; + +export default use게시글 좋아요 등록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\353\214\223\352\270\200 \354\236\221\354\204\261.ts" "b/src/apis/Solid Connection/post-\353\214\223\352\270\200 \354\236\221\354\204\261.ts" new file mode 100644 index 00000000..075e1e83 --- /dev/null +++ "b/src/apis/Solid Connection/post-\353\214\223\352\270\200 \354\236\221\354\204\261.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 댓글 작성Request { + // TODO: Define request type +} + +const 댓글 작성 = async (params: { data?: 댓글 작성Request }): Promise<댓글 작성Response> => { + const res = await axiosInstance.post<댓글 작성Response>( + `{`, params?.data + ); + return res.data; +}; + +const use댓글 작성 = () => { + return useMutation<댓글 작성Response, AxiosError, 댓글 작성Request>({ + mutationFn: (data) => 댓글 작성({ data }), + }); +}; + +export default use댓글 작성; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\353\241\234\352\267\270\354\225\204\354\233\203.ts" "b/src/apis/Solid Connection/post-\353\241\234\352\267\270\354\225\204\354\233\203.ts" new file mode 100644 index 00000000..7cd8cee1 --- /dev/null +++ "b/src/apis/Solid Connection/post-\353\241\234\352\267\270\354\225\204\354\233\203.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 로그아웃Request { + // TODO: Define request type +} + +const 로그아웃 = async (params: { data?: 로그아웃Request }): Promise<로그아웃Response> => { + const res = await axiosInstance.post<로그아웃Response>( + `{`, params?.data + ); + return res.data; +}; + +const use로그아웃 = () => { + return useMutation<로그아웃Response, AxiosError, 로그아웃Request>({ + mutationFn: (data) => 로그아웃({ data }), + }); +}; + +export default use로그아웃; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\353\251\230\355\206\240\353\247\201 \354\213\240\354\262\255.ts" "b/src/apis/Solid Connection/post-\353\251\230\355\206\240\353\247\201 \354\213\240\354\262\255.ts" new file mode 100644 index 00000000..30aa69e0 --- /dev/null +++ "b/src/apis/Solid Connection/post-\353\251\230\355\206\240\353\247\201 \354\213\240\354\262\255.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 멘토링 신청Request { + // TODO: Define request type +} + +export interface 멘토링 신청Response { + mentoringId: number; +} + +const 멘토링 신청 = async (params: { data?: 멘토링 신청Request }): Promise<멘토링 신청Response> => { + const res = await axiosInstance.post<멘토링 신청Response>( + `{`, params?.data + ); + return res.data; +}; + +const use멘토링 신청 = () => { + return useMutation<멘토링 신청Response, AxiosError, 멘토링 신청Request>({ + mutationFn: (data) => 멘토링 신청({ data }), + }); +}; + +export default use멘토링 신청; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\266\224\352\260\200.ts" "b/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\266\224\352\260\200.ts" new file mode 100644 index 00000000..22fd8b36 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\242\213\354\225\204\354\232\224 \354\266\224\352\260\200.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 소식지 좋아요 추가Request { + // TODO: Define request type +} + +const 소식지 좋아요 추가 = async (params: { data?: 소식지 좋아요 추가Request }): Promise<소식지 좋아요 추가Response> => { + const res = await axiosInstance.post<소식지 좋아요 추가Response>( + `{`, params?.data + ); + return res.data; +}; + +const use소식지 좋아요 추가 = () => { + return useMutation<소식지 좋아요 추가Response, AxiosError, 소식지 좋아요 추가Request>({ + mutationFn: (data) => 소식지 좋아요 추가({ data }), + }); +}; + +export default use소식지 좋아요 추가; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\266\224\352\260\200.ts" "b/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\266\224\352\260\200.ts" new file mode 100644 index 00000000..f0efcb6d --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\206\214\354\213\235\354\247\200 \354\266\224\352\260\200.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 소식지 추가Request { + // TODO: Define request type +} + +const 소식지 추가 = async (params: { data?: 소식지 추가Request }): Promise<소식지 추가Response> => { + const res = await axiosInstance.post<소식지 추가Response>( + `{`, params?.data + ); + return res.data; +}; + +const use소식지 추가 = () => { + return useMutation<소식지 추가Response, AxiosError, 소식지 추가Request>({ + mutationFn: (data) => 소식지 추가({ data }), + }); +}; + +export default use소식지 추가; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\212\254\353\236\231 \354\225\214\353\246\274.ts" "b/src/apis/Solid Connection/post-\354\212\254\353\236\231 \354\225\214\353\246\274.ts" new file mode 100644 index 00000000..c3b0a1d1 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\212\254\353\236\231 \354\225\214\353\246\274.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 슬랙 알림Request { + // TODO: Define request type +} + +export interface 슬랙 알림Response { + // TODO: Define response type +} + +const 슬랙 알림 = async (params: { data?: 슬랙 알림Request }): Promise<슬랙 알림Response> => { + const res = await axiosInstance.post<슬랙 알림Response>( + `{`, params?.data + ); + return res.data; +}; + +const use슬랙 알림 = () => { + return useMutation<슬랙 알림Response, AxiosError, 슬랙 알림Request>({ + mutationFn: (data) => 슬랙 알림({ data }), + }); +}; + +export default use슬랙 알림; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\213\240\352\263\240\355\225\230\352\270\260.ts" "b/src/apis/Solid Connection/post-\354\213\240\352\263\240\355\225\230\352\270\260.ts" new file mode 100644 index 00000000..cf7e1c72 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\213\240\352\263\240\355\225\230\352\270\260.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 신고하기Request { + // TODO: Define request type +} + +const 신고하기 = async (params: { data?: 신고하기Request }): Promise<신고하기Response> => { + const res = await axiosInstance.post<신고하기Response>( + `{`, params?.data + ); + return res.data; +}; + +const use신고하기 = () => { + return useMutation<신고하기Response, AxiosError, 신고하기Request>({ + mutationFn: (data) => 신고하기({ data }), + }); +}; + +export default use신고하기; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\225\240\355\224\214 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" "b/src/apis/Solid Connection/post-\354\225\240\355\224\214 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" new file mode 100644 index 00000000..816b39af --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\225\240\355\224\214 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" @@ -0,0 +1,30 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 애플 인증 (로그인 or 가입 코드 발급)Request { + // TODO: Define request type +} + +export interface 애플 인증 (로그인 or 가입 코드 발급)Response { + isRegistered: boolean; + nickname: null; + email: string; + profileImageUrl: null; + signUpToken: string; +} + +const 애플 인증 (로그인 or 가입 코드 발급) = async (params: { data?: 애플 인증 (로그인 or 가입 코드 발급)Request }): Promise<애플 인증 (로그인 or 가입 코드 발급)Response> => { + const res = await axiosInstance.post<애플 인증 (로그인 or 가입 코드 발급)Response>( + `{`, params?.data + ); + return res.data; +}; + +const use애플 인증 (로그인 or 가입 코드 발급) = () => { + return useMutation<애플 인증 (로그인 or 가입 코드 발급)Response, AxiosError, 애플 인증 (로그인 or 가입 코드 발급)Request>({ + mutationFn: (data) => 애플 인증 (로그인 or 가입 코드 발급)({ data }), + }); +}; + +export default use애플 인증 (로그인 or 가입 코드 발급); \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201 \353\223\261\353\241\235.ts" "b/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201 \353\223\261\353\241\235.ts" new file mode 100644 index 00000000..02732b3b --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201 \353\223\261\353\241\235.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 어학 성적 등록Request { + // TODO: Define request type +} + +const 어학 성적 등록 = async (params: { data?: 어학 성적 등록Request }): Promise<어학 성적 등록Response> => { + const res = await axiosInstance.post<어학 성적 등록Response>( + `{`, params?.data + ); + return res.data; +}; + +const use어학 성적 등록 = () => { + return useMutation<어학 성적 등록Response, AxiosError, 어학 성적 등록Request>({ + mutationFn: (data) => 어학 성적 등록({ data }), + }); +}; + +export default use어학 성적 등록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" "b/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" new file mode 100644 index 00000000..d8b0deef --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\226\264\355\225\231 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 어학 성적표 업로드Request { + // TODO: Define request type +} + +export interface 어학 성적표 업로드Response { + fileUrl: string; +} + +const 어학 성적표 업로드 = async (params: { data?: 어학 성적표 업로드Request }): Promise<어학 성적표 업로드Response> => { + const res = await axiosInstance.post<어학 성적표 업로드Response>( + `{`, params?.data + ); + return res.data; +}; + +const use어학 성적표 업로드 = () => { + return useMutation<어학 성적표 업로드Response, AxiosError, 어학 성적표 업로드Request>({ + mutationFn: (data) => 어학 성적표 업로드({ data }), + }); +}; + +export default use어학 성적표 업로드; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\227\221\354\204\270\354\212\244 \355\206\240\355\201\260 \354\236\254\353\260\234\352\270\211.ts" "b/src/apis/Solid Connection/post-\354\227\221\354\204\270\354\212\244 \355\206\240\355\201\260 \354\236\254\353\260\234\352\270\211.ts" new file mode 100644 index 00000000..70b4a035 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\227\221\354\204\270\354\212\244 \355\206\240\355\201\260 \354\236\254\353\260\234\352\270\211.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 엑세스 토큰 재발급Request { + // TODO: Define request type +} + +export interface 엑세스 토큰 재발급Response { + accessToken: string; +} + +const 엑세스 토큰 재발급 = async (params: { data?: 엑세스 토큰 재발급Request }): Promise<엑세스 토큰 재발급Response> => { + const res = await axiosInstance.post<엑세스 토큰 재발급Response>( + `{`, params?.data + ); + return res.data; +}; + +const use엑세스 토큰 재발급 = () => { + return useMutation<엑세스 토큰 재발급Response, AxiosError, 엑세스 토큰 재발급Request>({ + mutationFn: (data) => 엑세스 토큰 재발급({ data }), + }); +}; + +export default use엑세스 토큰 재발급; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\227\260\352\262\260 \353\201\212\352\270\260.ts" "b/src/apis/Solid Connection/post-\354\227\260\352\262\260 \353\201\212\352\270\260.ts" new file mode 100644 index 00000000..23cb8ac5 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\227\260\352\262\260 \353\201\212\352\270\260.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 연결 끊기Request { + // TODO: Define request type +} + +export interface 연결 끊기Response { + // TODO: Define response type +} + +const 연결 끊기 = async (params: { data?: 연결 끊기Request }): Promise<연결 끊기Response> => { + const res = await axiosInstance.post<연결 끊기Response>( + `{`, params?.data + ); + return res.data; +}; + +const use연결 끊기 = () => { + return useMutation<연결 끊기Response, AxiosError, 연결 끊기Request>({ + mutationFn: (data) => 연결 끊기({ data }), + }); +}; + +export default use연결 끊기; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\266\224\352\260\200.ts" "b/src/apis/Solid Connection/post-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\266\224\352\260\200.ts" new file mode 100644 index 00000000..62d1ea1d --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\234\204\354\213\234 \355\225\231\352\265\220 \354\266\224\352\260\200.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 위시 학교 추가Request { + // TODO: Define request type +} + +const 위시 학교 추가 = async (params: { data?: 위시 학교 추가Request }): Promise<위시 학교 추가Response> => { + const res = await axiosInstance.post<위시 학교 추가Response>( + `{`, params?.data + ); + return res.data; +}; + +const use위시 학교 추가 = () => { + return useMutation<위시 학교 추가Response, AxiosError, 위시 학교 추가Request>({ + mutationFn: (data) => 위시 학교 추가({ data }), + }); +}; + +export default use위시 학교 추가; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\234\240\354\240\200 \354\260\250\353\213\250.ts" "b/src/apis/Solid Connection/post-\354\234\240\354\240\200 \354\260\250\353\213\250.ts" new file mode 100644 index 00000000..91988e6e --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\234\240\354\240\200 \354\260\250\353\213\250.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 유저 차단Request { + // TODO: Define request type +} + +const 유저 차단 = async (params: { data?: 유저 차단Request }): Promise<유저 차단Response> => { + const res = await axiosInstance.post<유저 차단Response>( + `{`, params?.data + ); + return res.data; +}; + +const use유저 차단 = () => { + return useMutation<유저 차단Response, AxiosError, 유저 차단Request>({ + mutationFn: (data) => 유저 차단({ data }), + }); +}; + +export default use유저 차단; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \353\241\234\352\267\270\354\235\270.ts" "b/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \353\241\234\352\267\270\354\235\270.ts" new file mode 100644 index 00000000..14343d6d --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \353\241\234\352\267\270\354\235\270.ts" @@ -0,0 +1,27 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 이메일 로그인Request { + // TODO: Define request type +} + +export interface 이메일 로그인Response { + accessToken: string; + refreshToken: string; +} + +const 이메일 로그인 = async (params: { data?: 이메일 로그인Request }): Promise<이메일 로그인Response> => { + const res = await axiosInstance.post<이메일 로그인Response>( + `{`, params?.data + ); + return res.data; +}; + +const use이메일 로그인 = () => { + return useMutation<이메일 로그인Response, AxiosError, 이메일 로그인Request>({ + mutationFn: (data) => 이메일 로그인({ data }), + }); +}; + +export default use이메일 로그인; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \354\235\270\354\246\235 (\352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" "b/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \354\235\270\354\246\235 (\352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" new file mode 100644 index 00000000..26329c95 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\235\264\353\251\224\354\235\274 \354\235\270\354\246\235 (\352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 이메일 인증 (가입 코드 발급)Request { + // TODO: Define request type +} + +export interface 이메일 인증 (가입 코드 발급)Response { + signUpToken: string; +} + +const 이메일 인증 (가입 코드 발급) = async (params: { data?: 이메일 인증 (가입 코드 발급)Request }): Promise<이메일 인증 (가입 코드 발급)Response> => { + const res = await axiosInstance.post<이메일 인증 (가입 코드 발급)Response>( + `{`, params?.data + ); + return res.data; +}; + +const use이메일 인증 (가입 코드 발급) = () => { + return useMutation<이메일 인증 (가입 코드 발급)Response, AxiosError, 이메일 인증 (가입 코드 발급)Request>({ + mutationFn: (data) => 이메일 인증 (가입 코드 발급)({ data }), + }); +}; + +export default use이메일 인증 (가입 코드 발급); \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\247\200\354\233\220\354\204\234 \354\240\234\354\266\234.ts" "b/src/apis/Solid Connection/post-\354\247\200\354\233\220\354\204\234 \354\240\234\354\266\234.ts" new file mode 100644 index 00000000..5261ec87 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\247\200\354\233\220\354\204\234 \354\240\234\354\266\234.ts" @@ -0,0 +1,28 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 지원서 제출Request { + // TODO: Define request type +} + +export interface 지원서 제출Response { + totalApplyCount: number; + applyCount: number; + appliedUniversities: AppliedUniversities; +} + +const 지원서 제출 = async (params: { data?: 지원서 제출Request }): Promise<지원서 제출Response> => { + const res = await axiosInstance.post<지원서 제출Response>( + `{`, params?.data + ); + return res.data; +}; + +const use지원서 제출 = () => { + return useMutation<지원서 제출Response, AxiosError, 지원서 제출Request>({ + mutationFn: (data) => 지원서 제출({ data }), + }); +}; + +export default use지원서 제출; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\354\271\264\354\271\264\354\230\244 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" "b/src/apis/Solid Connection/post-\354\271\264\354\271\264\354\230\244 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" new file mode 100644 index 00000000..9364d0d7 --- /dev/null +++ "b/src/apis/Solid Connection/post-\354\271\264\354\271\264\354\230\244 \354\235\270\354\246\235 (\353\241\234\352\267\270\354\235\270 or \352\260\200\354\236\205 \354\275\224\353\223\234 \353\260\234\352\270\211).ts" @@ -0,0 +1,30 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 카카오 인증 (로그인 or 가입 코드 발급)Request { + // TODO: Define request type +} + +export interface 카카오 인증 (로그인 or 가입 코드 발급)Response { + isRegistered: boolean; + nickname: string; + email: string; + profileImageUrl: string; + signUpToken: string; +} + +const 카카오 인증 (로그인 or 가입 코드 발급) = async (params: { data?: 카카오 인증 (로그인 or 가입 코드 발급)Request }): Promise<카카오 인증 (로그인 or 가입 코드 발급)Response> => { + const res = await axiosInstance.post<카카오 인증 (로그인 or 가입 코드 발급)Response>( + `{`, params?.data + ); + return res.data; +}; + +const use카카오 인증 (로그인 or 가입 코드 발급) = () => { + return useMutation<카카오 인증 (로그인 or 가입 코드 발급)Response, AxiosError, 카카오 인증 (로그인 or 가입 코드 발급)Request>({ + mutationFn: (data) => 카카오 인증 (로그인 or 가입 코드 발급)({ data }), + }); +}; + +export default use카카오 인증 (로그인 or 가입 코드 발급); \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \354\240\204).ts" "b/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \354\240\204).ts" new file mode 100644 index 00000000..82ee3cfb --- /dev/null +++ "b/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \354\240\204).ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 프로필 사진 업로드 (가입 전)Request { + // TODO: Define request type +} + +export interface 프로필 사진 업로드 (가입 전)Response { + fileUrl: string; +} + +const 프로필 사진 업로드 (가입 전) = async (params: { data?: 프로필 사진 업로드 (가입 전)Request }): Promise<프로필 사진 업로드 (가입 전)Response> => { + const res = await axiosInstance.post<프로필 사진 업로드 (가입 전)Response>( + `{`, params?.data + ); + return res.data; +}; + +const use프로필 사진 업로드 (가입 전) = () => { + return useMutation<프로필 사진 업로드 (가입 전)Response, AxiosError, 프로필 사진 업로드 (가입 전)Request>({ + mutationFn: (data) => 프로필 사진 업로드 (가입 전)({ data }), + }); +}; + +export default use프로필 사진 업로드 (가입 전); \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \355\233\204).ts" "b/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \355\233\204).ts" new file mode 100644 index 00000000..57d1ffaf --- /dev/null +++ "b/src/apis/Solid Connection/post-\355\224\204\353\241\234\355\225\204 \354\202\254\354\247\204 \354\227\205\353\241\234\353\223\234 (\352\260\200\354\236\205 \355\233\204).ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 프로필 사진 업로드 (가입 후)Request { + // TODO: Define request type +} + +export interface 프로필 사진 업로드 (가입 후)Response { + fileUrl: string; +} + +const 프로필 사진 업로드 (가입 후) = async (params: { data?: 프로필 사진 업로드 (가입 후)Request }): Promise<프로필 사진 업로드 (가입 후)Response> => { + const res = await axiosInstance.post<프로필 사진 업로드 (가입 후)Response>( + `{`, params?.data + ); + return res.data; +}; + +const use프로필 사진 업로드 (가입 후) = () => { + return useMutation<프로필 사진 업로드 (가입 후)Response, AxiosError, 프로필 사진 업로드 (가입 후)Request>({ + mutationFn: (data) => 프로필 사진 업로드 (가입 후)({ data }), + }); +}; + +export default use프로필 사진 업로드 (가입 후); \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\355\225\231\354\240\201 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" "b/src/apis/Solid Connection/post-\355\225\231\354\240\201 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" new file mode 100644 index 00000000..7c611966 --- /dev/null +++ "b/src/apis/Solid Connection/post-\355\225\231\354\240\201 \354\204\261\354\240\201\355\221\234 \354\227\205\353\241\234\353\223\234.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 학적 성적표 업로드Request { + // TODO: Define request type +} + +export interface 학적 성적표 업로드Response { + fileUrl: string; +} + +const 학적 성적표 업로드 = async (params: { data?: 학적 성적표 업로드Request }): Promise<학적 성적표 업로드Response> => { + const res = await axiosInstance.post<학적 성적표 업로드Response>( + `{`, params?.data + ); + return res.data; +}; + +const use학적 성적표 업로드 = () => { + return useMutation<학적 성적표 업로드Response, AxiosError, 학적 성적표 업로드Request>({ + mutationFn: (data) => 학적 성적표 업로드({ data }), + }); +}; + +export default use학적 성적표 업로드; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\355\225\231\354\240\220 \353\223\261\353\241\235.ts" "b/src/apis/Solid Connection/post-\355\225\231\354\240\220 \353\223\261\353\241\235.ts" new file mode 100644 index 00000000..69fa7454 --- /dev/null +++ "b/src/apis/Solid Connection/post-\355\225\231\354\240\220 \353\223\261\353\241\235.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 학점 등록Request { + // TODO: Define request type +} + +const 학점 등록 = async (params: { data?: 학점 등록Request }): Promise<학점 등록Response> => { + const res = await axiosInstance.post<학점 등록Response>( + `{`, params?.data + ); + return res.data; +}; + +const use학점 등록 = () => { + return useMutation<학점 등록Response, AxiosError, 학점 등록Request>({ + mutationFn: (data) => 학점 등록({ data }), + }); +}; + +export default use학점 등록; \ No newline at end of file diff --git "a/src/apis/Solid Connection/post-\355\232\214\354\233\220\352\260\200\354\236\205.ts" "b/src/apis/Solid Connection/post-\355\232\214\354\233\220\352\260\200\354\236\205.ts" new file mode 100644 index 00000000..8ea9f708 --- /dev/null +++ "b/src/apis/Solid Connection/post-\355\232\214\354\233\220\352\260\200\354\236\205.ts" @@ -0,0 +1,27 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 회원가입Request { + // TODO: Define request type +} + +export interface 회원가입Response { + accessToken: string; + refreshToken: string; +} + +const 회원가입 = async (params: { data?: 회원가입Request }): Promise<회원가입Response> => { + const res = await axiosInstance.post<회원가입Response>( + `{`, params?.data + ); + return res.data; +}; + +const use회원가입 = () => { + return useMutation<회원가입Response, AxiosError, 회원가입Request>({ + mutationFn: (data) => 회원가입({ data }), + }); +}; + +export default use회원가입; \ No newline at end of file diff --git "a/src/apis/Solid Connection/put-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/put-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..e5f86bca --- /dev/null +++ "b/src/apis/Solid Connection/put-\353\202\230\354\235\230 \353\251\230\355\206\240 \355\216\230\354\235\264\354\247\200 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 나의 멘토 페이지 수정Request { + // TODO: Define request type +} + +const 나의 멘토 페이지 수정 = async (params: { data?: 나의 멘토 페이지 수정Request }): Promise<나의 멘토 페이지 수정Response> => { + const res = await axiosInstance.put<나의 멘토 페이지 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use나의 멘토 페이지 수정 = () => { + return useMutation<나의 멘토 페이지 수정Response, AxiosError, 나의 멘토 페이지 수정Request>({ + mutationFn: (data) => 나의 멘토 페이지 수정({ data }), + }); +}; + +export default use나의 멘토 페이지 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/put-\354\206\214\354\213\235\354\247\200 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/put-\354\206\214\354\213\235\354\247\200 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..7f1fd988 --- /dev/null +++ "b/src/apis/Solid Connection/put-\354\206\214\354\213\235\354\247\200 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 소식지 수정Request { + // TODO: Define request type +} + +const 소식지 수정 = async (params: { data?: 소식지 수정Request }): Promise<소식지 수정Response> => { + const res = await axiosInstance.put<소식지 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use소식지 수정 = () => { + return useMutation<소식지 수정Response, AxiosError, 소식지 수정Request>({ + mutationFn: (data) => 소식지 수정({ data }), + }); +}; + +export default use소식지 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/put-\354\226\264\355\225\231 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/put-\354\226\264\355\225\231 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..20487acd --- /dev/null +++ "b/src/apis/Solid Connection/put-\354\226\264\355\225\231 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" @@ -0,0 +1,22 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 어학 검증 및 수정Request { + // TODO: Define request type +} + +const 어학 검증 및 수정 = async (params: { data?: 어학 검증 및 수정Request }): Promise<어학 검증 및 수정Response> => { + const res = await axiosInstance.put<어학 검증 및 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use어학 검증 및 수정 = () => { + return useMutation<어학 검증 및 수정Response, AxiosError, 어학 검증 및 수정Request>({ + mutationFn: (data) => 어학 검증 및 수정({ data }), + }); +}; + +export default use어학 검증 및 수정; \ No newline at end of file diff --git "a/src/apis/Solid Connection/put-\354\261\204\355\214\205\353\260\251 \354\235\275\354\235\214 \354\262\230\353\246\254.ts" "b/src/apis/Solid Connection/put-\354\261\204\355\214\205\353\260\251 \354\235\275\354\235\214 \354\262\230\353\246\254.ts" new file mode 100644 index 00000000..4a5260e2 --- /dev/null +++ "b/src/apis/Solid Connection/put-\354\261\204\355\214\205\353\260\251 \354\235\275\354\235\214 \354\262\230\353\246\254.ts" @@ -0,0 +1,26 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 채팅방 읽음 처리Request { + // TODO: Define request type +} + +export interface 채팅방 읽음 처리Response { + // TODO: Define response type +} + +const 채팅방 읽음 처리 = async (params: { data?: 채팅방 읽음 처리Request }): Promise<채팅방 읽음 처리Response> => { + const res = await axiosInstance.put<채팅방 읽음 처리Response>( + `{`, params?.data + ); + return res.data; +}; + +const use채팅방 읽음 처리 = () => { + return useMutation<채팅방 읽음 처리Response, AxiosError, 채팅방 읽음 처리Request>({ + mutationFn: (data) => 채팅방 읽음 처리({ data }), + }); +}; + +export default use채팅방 읽음 처리; \ No newline at end of file diff --git "a/src/apis/Solid Connection/put-\355\225\231\354\240\220 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" "b/src/apis/Solid Connection/put-\355\225\231\354\240\220 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" new file mode 100644 index 00000000..7188c854 --- /dev/null +++ "b/src/apis/Solid Connection/put-\355\225\231\354\240\220 \352\262\200\354\246\235 \353\260\217 \354\210\230\354\240\225.ts" @@ -0,0 +1,30 @@ +import { AxiosError } from "axios"; +import { axiosInstance } from "@/utils/axiosInstance"; +import { useMutation } from "@tanstack/react-query"; + +export interface 학점 검증 및 수정Request { + // TODO: Define request type +} + +export interface 학점 검증 및 수정Response { + id: number; + gpa: number; + gpaCriteria: number; + verifyStatus: string; + rejectedReason: null; +} + +const 학점 검증 및 수정 = async (params: { data?: 학점 검증 및 수정Request }): Promise<학점 검증 및 수정Response> => { + const res = await axiosInstance.put<학점 검증 및 수정Response>( + `{`, params?.data + ); + return res.data; +}; + +const use학점 검증 및 수정 = () => { + return useMutation<학점 검증 및 수정Response, AxiosError, 학점 검증 및 수정Request>({ + mutationFn: (data) => 학점 검증 및 수정({ data }), + }); +}; + +export default use학점 검증 및 수정; \ No newline at end of file diff --git a/src/apis/queryKeys.ts b/src/apis/queryKeys.ts new file mode 100644 index 00000000..1e632c67 --- /dev/null +++ b/src/apis/queryKeys.ts @@ -0,0 +1,92 @@ +/** + * React Query Keys + * Bruno 폴더 구조를 기반으로 자동 생성됨 + */ + +export const QueryKeys = { + Solid Connection: { + folder: 'Solid Connection.folder' as const, + 로그아웃: 'Solid Connection.로그아웃' as const, + 애플 인증 (로그인 or 가입 코드 발급): 'Solid Connection.애플 인증 (로그인 or 가입 코드 발급)' as const, + 엑세스 토큰 재발급: 'Solid Connection.엑세스 토큰 재발급' as const, + 이메일 로그인: 'Solid Connection.이메일 로그인' as const, + 이메일 인증 (가입 코드 발급): 'Solid Connection.이메일 인증 (가입 코드 발급)' as const, + 카카오 인증 (로그인 or 가입 코드 발급): 'Solid Connection.카카오 인증 (로그인 or 가입 코드 발급)' as const, + 회원 탈퇴: 'Solid Connection.회원 탈퇴' as const, + 회원가입: 'Solid Connection.회원가입' as const, + 소식지 목록 조회: 'Solid Connection.소식지 목록 조회' as const, + 소식지 삭제: 'Solid Connection.소식지 삭제' as const, + 소식지 수정: 'Solid Connection.소식지 수정' as const, + 소식지 좋아요 삭제: 'Solid Connection.소식지 좋아요 삭제' as const, + 소식지 좋아요 추가: 'Solid Connection.소식지 좋아요 추가' as const, + 소식지 추가: 'Solid Connection.소식지 추가' as const, + 신고하기: 'Solid Connection.신고하기' as const, + 채팅 내역 조회: 'Solid Connection.채팅 내역 조회' as const, + 채팅방 목록 조회: 'Solid Connection.채팅방 목록 조회' as const, + 채팅방 읽음 처리: 'Solid Connection.채팅방 읽음 처리' as const, + 채팅방 파트너 조회: 'Solid Connection.채팅방 파트너 조회' as const, + 사용자 맞춤 대학 추천: 'Solid Connection.사용자 맞춤 대학 추천' as const, + 위시 학교 목록 조회: 'Solid Connection.위시 학교 목록 조회' as const, + 위시 학교 삭제: 'Solid Connection.위시 학교 삭제' as const, + 위시 학교 추가: 'Solid Connection.위시 학교 추가' as const, + 위시 학교인지 조회: 'Solid Connection.위시 학교인지 조회' as const, + 학교 상세 정보 조회: 'Solid Connection.학교 상세 정보 조회' as const, + 학교 텍스트 검색: 'Solid Connection.학교 텍스트 검색' as const, + 학교 필터 검색: 'Solid Connection.학교 필터 검색' as const, + 권역국가에 해당하는 전체 대학: 'Solid Connection.권역국가에 해당하는 전체 대학' as const, + 관심 권역국가 변경: 'Solid Connection.관심 권역국가 변경' as const, + 내 정보 수정: 'Solid Connection.내 정보 수정' as const, + 내 정보 조회: 'Solid Connection.내 정보 조회' as const, + 비밀번호 변경: 'Solid Connection.비밀번호 변경' as const, + 나의 지원과 동일한 지원자 현황 조회: 'Solid Connection.나의 지원과 동일한 지원자 현황 조회' as const, + 지원서 제출: 'Solid Connection.지원서 제출' as const, + 지원자 현황 조회: 'Solid Connection.지원자 현황 조회' as const, + 게시글 삭제: 'Solid Connection.게시글 삭제' as const, + 게시글 수정: 'Solid Connection.게시글 수정' as const, + 게시글 작성: 'Solid Connection.게시글 작성' as const, + 게시글 조회: 'Solid Connection.게시글 조회' as const, + 게시글 좋아요 등록: 'Solid Connection.게시글 좋아요 등록' as const, + 게시글 좋아요 삭제: 'Solid Connection.게시글 좋아요 삭제' as const, + 게시판 목록 조회: 'Solid Connection.게시판 목록 조회' as const, + 게시판 조회: 'Solid Connection.게시판 조회' as const, + 댓글 삭제: 'Solid Connection.댓글 삭제' as const, + 댓글 수정: 'Solid Connection.댓글 수정' as const, + 댓글 작성: 'Solid Connection.댓글 작성' as const, + 어학 성적 등록: 'Solid Connection.어학 성적 등록' as const, + 어학 성적 조회: 'Solid Connection.어학 성적 조회' as const, + 학점 등록: 'Solid Connection.학점 등록' as const, + 학점 조회: 'Solid Connection.학점 조회' as const, + 어학 검증 및 수정: 'Solid Connection.어학 검증 및 수정' as const, + 어학 조회: 'Solid Connection.어학 조회' as const, + 학점 검증 및 수정: 'Solid Connection.학점 검증 및 수정' as const, + 학점조회: 'Solid Connection.학점조회' as const, + 닉네임 중복 검증: 'Solid Connection.닉네임 중복 검증' as const, + 유저 차단 취소: 'Solid Connection.유저 차단 취소' as const, + 유저 차단: 'Solid Connection.유저 차단' as const, + 차단한 유저 목록 조회: 'Solid Connection.차단한 유저 목록 조회' as const, + 멘토 목록 조회: 'Solid Connection.멘토 목록 조회' as const, + 멘토 상세 페이지: 'Solid Connection.멘토 상세 페이지' as const, + 나의 멘토 페이지 수정: 'Solid Connection.나의 멘토 페이지 수정' as const, + 나의 멘토 페이지 조회: 'Solid Connection.나의 멘토 페이지 조회' as const, + 멘토링 수락거절: 'Solid Connection.멘토링 수락거절' as const, + 멘토링 확인: 'Solid Connection.멘토링 확인' as const, + 신청받은 멘토링 목록: 'Solid Connection.신청받은 멘토링 목록' as const, + 확인하지 않은 멘토링 수: 'Solid Connection.확인하지 않은 멘토링 수' as const, + 매칭된 멘토 목록: 'Solid Connection.매칭된 멘토 목록' as const, + 멘토링 신청: 'Solid Connection.멘토링 신청' as const, + 신청한 멘토링 목록: 'Solid Connection.신청한 멘토링 목록' as const, + 사용자 id 목록 조회: 'Solid Connection.사용자 id 목록 조회' as const, + 연결 끊기: 'Solid Connection.연결 끊기' as const, + 정보 조회: 'Solid Connection.정보 조회' as const, + 슬랙 알림: 'Solid Connection.슬랙 알림' as const, + 어학 성적표 업로드: 'Solid Connection.어학 성적표 업로드' as const, + 프로필 사진 업로드 (가입 전): 'Solid Connection.프로필 사진 업로드 (가입 전)' as const, + 프로필 사진 업로드 (가입 후): 'Solid Connection.프로필 사진 업로드 (가입 후)' as const, + 학적 성적표 업로드: 'Solid Connection.학적 성적표 업로드' as const, + collection: 'Solid Connection.collection' as const, + dev: 'Solid Connection.dev' as const, + local: 'Solid Connection.local' as const, + }, +} as const; + +export type QueryKey = typeof QueryKeys[keyof typeof QueryKeys]; \ No newline at end of file