From 15717cb80b74abdc9338d79c9f9043f5a35270a1 Mon Sep 17 00:00:00 2001 From: Jeon Eonseok Date: Sat, 30 Nov 2024 09:39:46 +0900 Subject: [PATCH 1/5] =?UTF-8?q?feat:=20=EB=9D=BC=EC=9D=B4=EB=B8=8C?= =?UTF-8?q?=EB=9F=AC=EB=A6=AC=20=EC=84=A4=EC=B9=98=20=EB=B0=8F=20=EB=AA=85?= =?UTF-8?q?=EB=A0=B9=EC=96=B4=20=EC=9E=91=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 9 +- yarn.lock | 276 ++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 277 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index 659e15f..2b3d629 100644 --- a/package.json +++ b/package.json @@ -4,13 +4,15 @@ "private": true, "scripts": { "dev": "next dev", - "build": "next build && yarn openapi-typescript", + "build": "next build", "start": "next start", "lint": "next lint", "storybook": "storybook dev -p 6006", "build-storybook": "storybook build", "test": "jest --watch", - "openapi-typescript": "npx openapi-typescript https://api-dev.sopt.org/v2/api-docs.yaml -o ./src/__generated__/api.d.ts" + "openapi-typescript": "npx openapi-typescript https://api-dev.sopt.org/v2/api-docs.yaml -o ./src/__generated__/api.d.ts", + "swagger-typescript-api": "swagger-typescript-api -p https://api-dev.sopt.org/v2/api-docs.yaml -r -o ./src/__generated__/org-types --modular -d --extract-request-body --extract-response-body --extract-response-error", + "api-spec": "yarn openapi-typescript && yarn swagger-typescript-api" }, "engines": { "node": ">=20.18.0 <21" @@ -37,6 +39,7 @@ "react-query": "^3.39.3", "recoil": "^0.7.7", "recoil-persist": "^5.1.0", + "swagger-typescript-api": "^13.0.23", "typescript": "^5.4.4", "use-immer": "^0.9.0" }, @@ -77,4 +80,4 @@ "webpack": "^5.95.0" }, "packageManager": "yarn@4.5.0" -} +} \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index 8a44484..899b613 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2022,6 +2022,13 @@ __metadata: languageName: node linkType: hard +"@exodus/schemasafe@npm:^1.0.0-rc.2": + version: 1.3.0 + resolution: "@exodus/schemasafe@npm:1.3.0" + checksum: 10c0/e19397c14db76342154c32a9088536149babfd9b18ecae815add0b2f911d9aa292aa51c6ab33b857b4b6bb371a74ebde845e6f17b2824e73b4e307230f23f86a + languageName: node + linkType: hard + "@fal-works/esbuild-plugin-global-externals@npm:^2.1.2": version: 2.1.2 resolution: "@fal-works/esbuild-plugin-global-externals@npm:2.1.2" @@ -4748,6 +4755,13 @@ __metadata: languageName: node linkType: hard +"@types/swagger-schema-official@npm:^2.0.25": + version: 2.0.25 + resolution: "@types/swagger-schema-official@npm:2.0.25" + checksum: 10c0/688669a509d8e6c93aa8bf99ce1a02fd6429e6e4e0948be2e08528b1a2c9b710e9d40051b7620da80cc80783219f1d6808012c9738be02664cc5c4af3db1d26b + languageName: node + linkType: hard + "@types/tough-cookie@npm:*": version: 4.0.5 resolution: "@types/tough-cookie@npm:4.0.5" @@ -6475,6 +6489,13 @@ __metadata: languageName: node linkType: hard +"call-me-maybe@npm:^1.0.1": + version: 1.0.2 + resolution: "call-me-maybe@npm:1.0.2" + checksum: 10c0/8eff5dbb61141ebb236ed71b4e9549e488bcb5451c48c11e5667d5c75b0532303788a1101e6978cafa2d0c8c1a727805599c2741e3e0982855c9f1d78cd06c9f + languageName: node + linkType: hard + "callsites@npm:^3.0.0": version: 3.1.0 resolution: "callsites@npm:3.1.0" @@ -7076,6 +7097,23 @@ __metadata: languageName: node linkType: hard +"cosmiconfig@npm:^9.0.0": + version: 9.0.0 + resolution: "cosmiconfig@npm:9.0.0" + dependencies: + env-paths: "npm:^2.2.1" + import-fresh: "npm:^3.3.0" + js-yaml: "npm:^4.1.0" + parse-json: "npm:^5.2.0" + peerDependencies: + typescript: ">=4.9.5" + peerDependenciesMeta: + typescript: + optional: true + checksum: 10c0/1c1703be4f02a250b1d6ca3267e408ce16abfe8364193891afc94c2d5c060b69611fdc8d97af74b7e6d5d1aac0ab2fb94d6b079573146bc2d756c2484ce5f0ee + languageName: node + linkType: hard + "create-ecdh@npm:^4.0.0": version: 4.0.4 resolution: "create-ecdh@npm:4.0.4" @@ -7691,6 +7729,13 @@ __metadata: languageName: node linkType: hard +"didyoumean@npm:^1.2.2": + version: 1.2.2 + resolution: "didyoumean@npm:1.2.2" + checksum: 10c0/95d0b53d23b851aacff56dfadb7ecfedce49da4232233baecfeecb7710248c4aa03f0aa8995062f0acafaf925adf8536bd7044a2e68316fd7d411477599bc27b + languageName: node + linkType: hard + "diff-sequences@npm:^29.6.3": version: 29.6.3 resolution: "diff-sequences@npm:29.6.3" @@ -8038,7 +8083,7 @@ __metadata: languageName: node linkType: hard -"env-paths@npm:^2.2.0": +"env-paths@npm:^2.2.0, env-paths@npm:^2.2.1": version: 2.2.1 resolution: "env-paths@npm:2.2.1" checksum: 10c0/285325677bf00e30845e330eec32894f5105529db97496ee3f598478e50f008c5352a41a30e5e72ec9de8a542b5a570b85699cd63bd2bc646dbcb9f311d83bc4 @@ -8235,6 +8280,13 @@ __metadata: languageName: node linkType: hard +"es6-promise@npm:^3.2.1": + version: 3.3.1 + resolution: "es6-promise@npm:3.3.1" + checksum: 10c0/b4fc87cb8509c001f62f860f97b05d1fd3f87220c8b832578e6a483c719ca272b73a77f2231cb26395fa865e1cab2fd4298ab67786b69e97b8d757b938f4fc1f + languageName: node + linkType: hard + "esbuild-plugin-alias@npm:^0.2.1": version: 0.2.1 resolution: "esbuild-plugin-alias@npm:0.2.1" @@ -8738,6 +8790,13 @@ __metadata: languageName: node linkType: hard +"eta@npm:^2.2.0": + version: 2.2.0 + resolution: "eta@npm:2.2.0" + checksum: 10c0/643b54d9539d2761bf6c5f4f48df1a5ea2d46c7f5a5fdc47a7d4802a8aa2b6262d4d61f724452e226c18cf82db02d48e65293fcc548f26a3f9d75a5ba7c3b859 + languageName: node + linkType: hard + "etag@npm:~1.8.1": version: 1.8.1 resolution: "etag@npm:1.8.1" @@ -8932,6 +8991,13 @@ __metadata: languageName: node linkType: hard +"fast-safe-stringify@npm:^2.0.7": + version: 2.1.1 + resolution: "fast-safe-stringify@npm:2.1.1" + checksum: 10c0/d90ec1c963394919828872f21edaa3ad6f1dddd288d2bd4e977027afff09f5db40f94e39536d4646f7e01761d704d72d51dce5af1b93717f3489ef808f5f4e4d + languageName: node + linkType: hard + "fast-uri@npm:^3.0.1": version: 3.0.1 resolution: "fast-uri@npm:3.0.1" @@ -9952,6 +10018,13 @@ __metadata: languageName: node linkType: hard +"http2-client@npm:^1.2.5": + version: 1.3.5 + resolution: "http2-client@npm:1.3.5" + checksum: 10c0/4974f10f5c8b5b7b9e23771190471d02690e9a22c22e028d84715b7ecdcda05017fc9e565476558da3bdf0ba642d24186a94818d0b9afee706ccf9874034be73 + languageName: node + linkType: hard + "http2-wrapper@npm:^1.0.0-beta.5.2": version: 1.0.3 resolution: "http2-wrapper@npm:1.0.3" @@ -12322,6 +12395,15 @@ __metadata: languageName: node linkType: hard +"node-fetch-h2@npm:^2.3.0": + version: 2.3.0 + resolution: "node-fetch-h2@npm:2.3.0" + dependencies: + http2-client: "npm:^1.2.5" + checksum: 10c0/10f117c5aa1d475fff05028dddd617a61606083e4d6c4195dd5f5b03c973182e0d125e804771e6888d04f7d92b5c9c27a6149d1beedd6af1e0744f163e8a02d9 + languageName: node + linkType: hard + "node-fetch-native@npm:^1.6.3": version: 1.6.4 resolution: "node-fetch-native@npm:1.6.4" @@ -12405,6 +12487,15 @@ __metadata: languageName: node linkType: hard +"node-readfiles@npm:^0.2.0": + version: 0.2.0 + resolution: "node-readfiles@npm:0.2.0" + dependencies: + es6-promise: "npm:^3.2.1" + checksum: 10c0/9de2f741baae29f2422b22ef4399b5f7cb6c20372d4e88447a98d00a92cf1a35efdf942d24eee153a87d885aa7e7442b4bc6de33d4b91c47ba9da501780c76a1 + languageName: node + linkType: hard + "node-releases@npm:^2.0.18": version: 2.0.18 resolution: "node-releases@npm:2.0.18" @@ -12499,6 +12590,64 @@ __metadata: languageName: node linkType: hard +"oas-kit-common@npm:^1.0.8": + version: 1.0.8 + resolution: "oas-kit-common@npm:1.0.8" + dependencies: + fast-safe-stringify: "npm:^2.0.7" + checksum: 10c0/5619a0bd19a07b52af1afeff26e44601002c0fd558d0020fdb720cb3723b60c83b80efede3a62110ce315f15b971751fb46396760e0e507fb8fd412cdc3808dd + languageName: node + linkType: hard + +"oas-linter@npm:^3.2.2": + version: 3.2.2 + resolution: "oas-linter@npm:3.2.2" + dependencies: + "@exodus/schemasafe": "npm:^1.0.0-rc.2" + should: "npm:^13.2.1" + yaml: "npm:^1.10.0" + checksum: 10c0/5a8ea3d8a0bf185b676659d1e1c0b9b50695aeff53ccd5c264c8e99b4a7c0021f802b937913d76f0bc1a6a2b8ae151df764d95302b0829063b9b26f8c436871c + languageName: node + linkType: hard + +"oas-resolver@npm:^2.5.6": + version: 2.5.6 + resolution: "oas-resolver@npm:2.5.6" + dependencies: + node-fetch-h2: "npm:^2.3.0" + oas-kit-common: "npm:^1.0.8" + reftools: "npm:^1.1.9" + yaml: "npm:^1.10.0" + yargs: "npm:^17.0.1" + bin: + resolve: resolve.js + checksum: 10c0/cfba5ba3f7ea6673a840836cf194a80ba7f77e6d1ee005aa35cc838cad56d7e455fa53753ae7cc38810c96405b8606e675098ea7023639cf546cb10343f180f9 + languageName: node + linkType: hard + +"oas-schema-walker@npm:^1.1.5": + version: 1.1.5 + resolution: "oas-schema-walker@npm:1.1.5" + checksum: 10c0/8ba6bd2a9a8ede2c5574f217653a9e2b889a7c5be69c664a57e293591c58952e8510f4f9e2a82fd5f52491c859ce5c2b68342e9b971e9667f6b811e7fb56fd54 + languageName: node + linkType: hard + +"oas-validator@npm:^5.0.8": + version: 5.0.8 + resolution: "oas-validator@npm:5.0.8" + dependencies: + call-me-maybe: "npm:^1.0.1" + oas-kit-common: "npm:^1.0.8" + oas-linter: "npm:^3.2.2" + oas-resolver: "npm:^2.5.6" + oas-schema-walker: "npm:^1.1.5" + reftools: "npm:^1.1.9" + should: "npm:^13.2.1" + yaml: "npm:^1.10.0" + checksum: 10c0/16bb722042dcba93892c50db2201df6aeea9c3dd60e2f7bc18b36f23c610d136f52a5946908817f6fdd4139219fa4b177f952b9831039078b4c8730fa026b180 + languageName: node + linkType: hard + "object-assign@npm:^4.1.1": version: 4.1.1 resolution: "object-assign@npm:4.1.1" @@ -13283,7 +13432,7 @@ __metadata: languageName: node linkType: hard -"prettier@npm:^3.1.1, prettier@npm:^3.2.5": +"prettier@npm:^3.1.1, prettier@npm:^3.2.5, prettier@npm:~3.3.3": version: 3.3.3 resolution: "prettier@npm:3.3.3" bin: @@ -13953,6 +14102,13 @@ __metadata: languageName: node linkType: hard +"reftools@npm:^1.1.9": + version: 1.1.9 + resolution: "reftools@npm:1.1.9" + checksum: 10c0/4b44c9e75d6e5328b43b974de08776ee1718a0b48f24e033b2699f872cc9a698234a4aa0553b9e1a766b828aeb9834e4aa988410f0279e86179edb33b270da6c + languageName: node + linkType: hard + "regenerate-unicode-properties@npm:^10.1.0": version: 10.1.1 resolution: "regenerate-unicode-properties@npm:10.1.1" @@ -14588,6 +14744,62 @@ __metadata: languageName: node linkType: hard +"should-equal@npm:^2.0.0": + version: 2.0.0 + resolution: "should-equal@npm:2.0.0" + dependencies: + should-type: "npm:^1.4.0" + checksum: 10c0/b375e1da2586671e2b9442ac5b700af508f56438af9923f69123b1fe4e02ccddc9a8a3eb803447a6df91e616cec236c41d6f28fdaa100467f9fdb81651089538 + languageName: node + linkType: hard + +"should-format@npm:^3.0.3": + version: 3.0.3 + resolution: "should-format@npm:3.0.3" + dependencies: + should-type: "npm:^1.3.0" + should-type-adaptors: "npm:^1.0.1" + checksum: 10c0/ef2a31148d79a3fabd0dc6c1c1b10f90d9e071ad8e1f99452bd01e8aceaca62985b43974cf8103185fa1a3ade85947c6f664e44ca9af253afd1ce93c223bd8e4 + languageName: node + linkType: hard + +"should-type-adaptors@npm:^1.0.1": + version: 1.1.0 + resolution: "should-type-adaptors@npm:1.1.0" + dependencies: + should-type: "npm:^1.3.0" + should-util: "npm:^1.0.0" + checksum: 10c0/cf127f8807f69ace9db04dbec3f274330a854405feef9821b5fa525748961da65747869cca36c813132b98757bd3e42d53541579cb16630ccf3c0dd9c0082320 + languageName: node + linkType: hard + +"should-type@npm:^1.3.0, should-type@npm:^1.4.0": + version: 1.4.0 + resolution: "should-type@npm:1.4.0" + checksum: 10c0/50cb50d776ee117b151068367c09ec12ac8e6f5fe2bd4d167413972813f06e930fe8624232a56c335846d3afcb784455f9a9690baa4350b3919bd001f0c4c94b + languageName: node + linkType: hard + +"should-util@npm:^1.0.0": + version: 1.0.1 + resolution: "should-util@npm:1.0.1" + checksum: 10c0/1790719e05eae9edae86e44cbbad98529bd333df3f7cdfd63ea80acb6af718990e70abbc173aa9ccb93fff5ab6ee08d38412d707ff4003840be2256a278a61f3 + languageName: node + linkType: hard + +"should@npm:^13.2.1": + version: 13.2.3 + resolution: "should@npm:13.2.3" + dependencies: + should-equal: "npm:^2.0.0" + should-format: "npm:^3.0.3" + should-type: "npm:^1.4.0" + should-type-adaptors: "npm:^1.0.1" + should-util: "npm:^1.0.0" + checksum: 10c0/99581d8615f6fb27cd23c9f431cfacef58d118a90d0cccf58775b90631a47441397cfbdcbe6379e2718e9e60f293e3dfc0e87857f4b5a36fe962814e46ab05fa + languageName: node + linkType: hard + "side-channel@npm:^1.0.4, side-channel@npm:^1.0.6": version: 1.0.6 resolution: "side-channel@npm:1.0.6" @@ -14749,6 +14961,7 @@ __metadata: recoil: "npm:^0.7.7" recoil-persist: "npm:^5.1.0" storybook: "npm:8.0.4" + swagger-typescript-api: "npm:^13.0.23" ts-jest: "npm:^29.0.5" ts-node: "npm:^10.9.1" typescript: "npm:^5.4.4" @@ -15279,6 +15492,59 @@ __metadata: languageName: node linkType: hard +"swagger-schema-official@npm:2.0.0-bab6bed": + version: 2.0.0-bab6bed + resolution: "swagger-schema-official@npm:2.0.0-bab6bed" + checksum: 10c0/58d1f8302aaa14fc64658b2821d70a6d06883a5270c71c210e8b6e5655ee2d7e01543383ddb2948ada368b51a22d71a9f9fcc0b903041719897f866b9c65d201 + languageName: node + linkType: hard + +"swagger-typescript-api@npm:^13.0.23": + version: 13.0.23 + resolution: "swagger-typescript-api@npm:13.0.23" + dependencies: + "@types/swagger-schema-official": "npm:^2.0.25" + consola: "npm:^3.2.3" + cosmiconfig: "npm:^9.0.0" + didyoumean: "npm:^1.2.2" + eta: "npm:^2.2.0" + js-yaml: "npm:^4.1.0" + lodash: "npm:^4.17.21" + nanoid: "npm:^3.3.7" + prettier: "npm:~3.3.3" + swagger-schema-official: "npm:2.0.0-bab6bed" + swagger2openapi: "npm:^7.0.8" + typescript: "npm:~5.5.4" + bin: + sta: ./dist/cli.js + swagger-typescript-api: ./dist/cli.js + checksum: 10c0/b322bbc264a7f4a078961a93692e4adace0b1c34bc3a912211404ea799ebcd4cc2a586dc4cc9fc0f9404cbe90a6137aab2341f6a10239602972740c979c51ade + languageName: node + linkType: hard + +"swagger2openapi@npm:^7.0.8": + version: 7.0.8 + resolution: "swagger2openapi@npm:7.0.8" + dependencies: + call-me-maybe: "npm:^1.0.1" + node-fetch: "npm:^2.6.1" + node-fetch-h2: "npm:^2.3.0" + node-readfiles: "npm:^0.2.0" + oas-kit-common: "npm:^1.0.8" + oas-resolver: "npm:^2.5.6" + oas-schema-walker: "npm:^1.1.5" + oas-validator: "npm:^5.0.8" + reftools: "npm:^1.1.9" + yaml: "npm:^1.10.0" + yargs: "npm:^17.0.1" + bin: + boast: boast.js + oas-validate: oas-validate.js + swagger2openapi: swagger2openapi.js + checksum: 10c0/441a4d3a7d353f99395b14a0c8d6124be6390f2f8aa53336905e7314a7f80b66f5f2a40ac0dc2dbe2f7bc01f52a223a94f54a2ece345095fd3ad8ae8b03d688b + languageName: node + linkType: hard + "symbol-tree@npm:^3.2.4": version: 3.2.4 resolution: "symbol-tree@npm:3.2.4" @@ -15923,7 +16189,7 @@ __metadata: languageName: node linkType: hard -"typescript@npm:^5.4.4": +"typescript@npm:^5.4.4, typescript@npm:~5.5.4": version: 5.5.4 resolution: "typescript@npm:5.5.4" bin: @@ -15933,7 +16199,7 @@ __metadata: languageName: node linkType: hard -"typescript@patch:typescript@npm%3A^5.4.4#optional!builtin": +"typescript@patch:typescript@npm%3A^5.4.4#optional!builtin, typescript@patch:typescript@npm%3A~5.5.4#optional!builtin": version: 5.5.4 resolution: "typescript@patch:typescript@npm%3A5.5.4#optional!builtin::version=5.5.4&hash=379a07" bin: @@ -16773,7 +17039,7 @@ __metadata: languageName: node linkType: hard -"yargs@npm:^17.3.1": +"yargs@npm:^17.0.1, yargs@npm:^17.3.1": version: 17.7.2 resolution: "yargs@npm:17.7.2" dependencies: From 3dfb219669085c89996b623d5c945a0a0021b37e Mon Sep 17 00:00:00 2001 From: Jeon Eonseok Date: Sat, 30 Nov 2024 09:40:05 +0900 Subject: [PATCH 2/5] =?UTF-8?q?feat:=20type=20=EC=83=9D=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/__generated__/org-admin.json | 2242 ----------------- src/__generated__/org-types/Admin.ts | 162 ++ src/__generated__/org-types/Health.ts | 32 + src/__generated__/org-types/Homepage.ts | 63 + src/__generated__/org-types/Notification.ts | 71 + src/__generated__/org-types/Projects.ts | 61 + src/__generated__/org-types/Semesters.ts | 44 + src/__generated__/org-types/data-contracts.ts | 1246 +++++++++ src/__generated__/org-types/http-client.ts | 254 ++ 9 files changed, 1933 insertions(+), 2242 deletions(-) delete mode 100644 src/__generated__/org-admin.json create mode 100644 src/__generated__/org-types/Admin.ts create mode 100644 src/__generated__/org-types/Health.ts create mode 100644 src/__generated__/org-types/Homepage.ts create mode 100644 src/__generated__/org-types/Notification.ts create mode 100644 src/__generated__/org-types/Projects.ts create mode 100644 src/__generated__/org-types/Semesters.ts create mode 100644 src/__generated__/org-types/data-contracts.ts create mode 100644 src/__generated__/org-types/http-client.ts diff --git a/src/__generated__/org-admin.json b/src/__generated__/org-admin.json deleted file mode 100644 index d131ee5..0000000 --- a/src/__generated__/org-admin.json +++ /dev/null @@ -1,2242 +0,0 @@ -{ - "openapi": "3.0.1", - "info": { - "title": "SOPT 공식홈페이지", - "description": "Spring V2 API 문서" - }, - "servers": [ - { - "url": "/v2" - } - ], - "paths": { - "/notification/register": { - "post": { - "tags": ["Notification"], - "operationId": "registerNotification", - "parameters": [ - { - "name": "generation", - "in": "query", - "description": "활동 기수", - "required": true, - "schema": { - "type": "string", - "description": "활동 기수", - "example": 34 - }, - "example": 34 - }, - { - "name": "email", - "in": "query", - "description": "이메일", - "required": true, - "schema": { - "type": "string", - "description": "이메일", - "example": "example@naver.com" - }, - "example": "example@naver.com" - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/RegisterNotificationResponseDto" - } - } - } - } - } - } - }, - "/admin": { - "get": { - "tags": ["Admin"], - "summary": "어드민 메인 데이터 조회", - "description": "어드민 메인 데이터를 조회합니다", - "operationId": "getMain", - "parameters": [ - { - "name": "generation", - "in": "query", - "description": "기수", - "required": true, - "schema": { - "type": "string", - "description": "기수", - "example": 35 - }, - "example": 35 - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetAdminResponseDto" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - }, - "post": { - "tags": ["Admin"], - "summary": "어드민 메인 데이터 배포", - "description": "어드민 메인 데이터를 배포합니다", - "operationId": "addMain", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AddAdminRequestDto" - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/AddAdminResponseDto" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - } - }, - "/admin/news": { - "get": { - "tags": ["Admin"], - "summary": "최신소식 조회", - "description": "최신소식을 조회합니다", - "operationId": "getMainNews", - "parameters": [ - { - "name": "id", - "in": "query", - "description": "최신소식 ID", - "required": true, - "schema": { - "type": "string", - "description": "최신소식 ID" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetAdminNewsResponseDto" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - }, - "post": { - "tags": ["Admin"], - "summary": "최신소식 추가", - "description": "최신소식을 추가합니다", - "operationId": "addMainNews", - "requestBody": { - "content": { - "multipart/form-data": { - "schema": { - "$ref": "#/components/schemas/AddAdminNewsRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "type": "string" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - }, - "delete": { - "tags": ["Admin"], - "summary": "최신소식 삭제", - "description": "최신소식을 삭제합니다", - "operationId": "deleteMainNews", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteAdminNewsRequestDto" - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "type": "string" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - } - }, - "/admin/confirm": { - "post": { - "tags": ["Admin"], - "summary": "어드민 메인 데이터 배포 확인", - "description": "어드민 메인 데이터 배포를 확인합니다", - "operationId": "addMainConfirm", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AddAdminConfirmRequestDto" - } - } - }, - "required": true - }, - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "type": "string" - } - } - } - } - }, - "security": [ - { - "Authorization": [] - } - ] - } - }, - "/semesters": { - "get": { - "tags": ["Semester"], - "operationId": "getSemesters", - "parameters": [ - { - "name": "limit", - "in": "query", - "required": true, - "schema": { - "type": "integer", - "format": "int32" - } - }, - { - "name": "page", - "in": "query", - "required": false, - "schema": { - "type": "integer", - "format": "int32", - "default": 1 - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/SemestersListResponse" - } - } - } - } - } - } - }, - "/projects": { - "get": { - "tags": ["Project"], - "operationId": "getAllProject", - "parameters": [ - { - "name": "filter", - "in": "query", - "description": "프로젝트 타입", - "required": false, - "schema": { - "type": "string", - "enum": [ - "APPJAM", - "SOPKATHON", - "SOPTERM", - "STUDY", - "JOINTSEMINAR", - "ETC" - ] - } - }, - { - "name": "platform", - "in": "query", - "description": "서비스 플랫폼", - "required": false, - "schema": { - "type": "string", - "enum": ["WEB", "APP"] - } - }, - { - "name": "pageNo", - "in": "query", - "description": "페이지", - "required": false, - "schema": { - "minimum": 1, - "type": "integer", - "format": "int32" - }, - "example": 1 - }, - { - "name": "limit", - "in": "query", - "description": "페이지별 데이터 개수", - "required": false, - "schema": { - "minimum": 1, - "type": "integer", - "format": "int32" - }, - "example": 10 - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/PaginateResponseProjectResponse" - } - } - } - } - } - } - }, - "/notification/list": { - "get": { - "tags": ["Notification"], - "operationId": "getAllProject_1", - "parameters": [ - { - "name": "generation", - "in": "query", - "description": "기수", - "required": false, - "schema": { - "type": "integer", - "format": "int32" - } - } - ], - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetNotificationListResponseDto" - } - } - } - } - } - } - }, - "/homepage": { - "get": { - "tags": ["Homepage"], - "summary": "메인 페이지 조회", - "description": "메인 페이지 데이터를 조회합니다", - "operationId": "getMainPage", - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetMainPageResponseDto" - } - } - } - } - } - } - }, - "/homepage/recruit": { - "get": { - "tags": ["Homepage"], - "summary": "지원하기 페이지 조회", - "description": "지원하기 페이지 데이터를 조회합니다", - "operationId": "get", - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetRecruitingPageResponseDto" - } - } - } - } - } - } - }, - "/homepage/about": { - "get": { - "tags": ["Homepage"], - "summary": "소개 페이지 조회", - "description": "소개 페이지 데이터를 조회합니다", - "operationId": "getAboutPage", - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/GetAboutPageResponseDto" - } - } - } - } - } - } - }, - "/health": { - "get": { - "tags": ["HealthCheck"], - "operationId": "healthCheck", - "responses": { - "200": { - "description": "OK", - "content": { - "*/*": { - "schema": { - "type": "string" - } - } - } - } - } - } - } - }, - "components": { - "schemas": { - "RegisterNotificationResponseDto": { - "required": ["createdAt", "email", "generation", "id"], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "Notification ID", - "format": "int32" - }, - "generation": { - "type": "integer", - "description": "기수 (Generation)", - "format": "int32" - }, - "email": { - "type": "string", - "description": "이메일 (Email)" - }, - "createdAt": { - "type": "string", - "description": "생성일자 (Creation Date)", - "format": "date-time" - } - } - }, - "AddAdminBrandingColorRequestDto": { - "required": ["high", "low", "main", "point"], - "type": "object", - "properties": { - "main": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "메인 컬러", - "example": "#FF0000" - }, - "low": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "로우 톤 컬러", - "example": "#CC0000" - }, - "high": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "하이 톤 컬러", - "example": "#FF3333" - }, - "point": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "포인트 컬러", - "example": "#FF9999" - } - }, - "description": "브랜딩 컬러" - }, - "AddAdminCoreValueRequestDto": { - "required": ["description", "imageFileName", "value"], - "type": "object", - "properties": { - "value": { - "type": "string", - "description": "핵심 가치", - "example": "용기" - }, - "description": { - "type": "string", - "description": "핵심 가치 설명", - "example": "새로운 도전을 위해 과감히 용기내는 사람" - }, - "imageFileName": { - "type": "string", - "description": "핵심 가치 이미지 파일명", - "example": "image.png" - } - }, - "description": "핵심 가치" - }, - "AddAdminCurriculumWeekRequestDto": { - "required": ["description", "week"], - "type": "object", - "properties": { - "week": { - "maximum": 8, - "minimum": 1, - "type": "integer", - "description": "주차", - "format": "int32", - "example": 1 - }, - "description": { - "type": "string", - "description": "커리큘럼 설명", - "example": "Android 기초 학습" - } - }, - "description": "주차별 커리큘럼 정보" - }, - "AddAdminIntroductionRequestDto": { - "required": ["content", "preference"], - "type": "object", - "properties": { - "content": { - "type": "string", - "description": "내용", - "example": "Android 앱 개발" - }, - "preference": { - "type": "string", - "description": "우대사항", - "example": "Kotlin 개발 경험" - } - }, - "description": "소개글 정보" - }, - "AddAdminMainButtonRequestDto": { - "required": ["keyColor", "subColor", "text"], - "type": "object", - "properties": { - "text": { - "type": "string", - "description": "버튼 텍스트", - "example": "지원하기" - }, - "keyColor": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "주요 컬러", - "example": "#FF0000" - }, - "subColor": { - "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$", - "type": "string", - "description": "보조 컬러", - "example": "#CC0000" - } - }, - "description": "메인 버튼 스타일" - }, - "AddAdminMemberRequestDto": { - "required": [ - "affiliation", - "introduction", - "name", - "profileImageFileName", - "role", - "sns" - ], - "type": "object", - "properties": { - "role": { - "type": "string", - "description": "역할", - "example": "회장" - }, - "name": { - "type": "string", - "description": "이름", - "example": "홍길동" - }, - "affiliation": { - "type": "string", - "description": "소속", - "example": "SOPT" - }, - "introduction": { - "type": "string", - "description": "한줄 소개", - "example": "안녕하세요!" - }, - "sns": { - "$ref": "#/components/schemas/AddAdminSnsLinksRequestDto" - }, - "profileImageFileName": { - "type": "string", - "description": "프로필 이미지 파일명", - "example": "image.png" - } - }, - "description": "멤버 정보" - }, - "AddAdminPartCurriculumRequestDto": { - "required": ["part", "weeks"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "weeks": { - "type": "array", - "description": "주차별 커리큘럼", - "items": { - "$ref": "#/components/schemas/AddAdminCurriculumWeekRequestDto" - } - } - }, - "description": "파트별 커리큘럼" - }, - "AddAdminPartIntroductionRequestDto": { - "required": ["description", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "description": { - "type": "string", - "description": "파트 설명", - "example": "Android 앱 개발" - } - }, - "description": "파트 소개" - }, - "AddAdminQuestionRequestDto": { - "required": ["answer", "question"], - "type": "object", - "properties": { - "question": { - "type": "string", - "description": "질문", - "example": "몇명 뽑나요?" - }, - "answer": { - "type": "string", - "description": "답변", - "example": "10명 뽑아요." - } - }, - "description": "질문과 답변" - }, - "AddAdminRecruitPartCurriculumRequestDto": { - "required": ["introduction", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "introduction": { - "$ref": "#/components/schemas/AddAdminIntroductionRequestDto" - } - }, - "description": "모집 파트 커리큘럼" - }, - "AddAdminRecruitQuestionRequestDto": { - "required": ["part", "questions"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "questions": { - "type": "array", - "description": "질문 리스트", - "items": { - "$ref": "#/components/schemas/AddAdminQuestionRequestDto" - } - } - }, - "description": "모집 질문" - }, - "AddAdminRecruitScheduleRequestDto": { - "required": ["schedule", "type"], - "type": "object", - "properties": { - "type": { - "pattern": "^(OB|YB)$", - "type": "string", - "description": "타입", - "example": "OB", - "enum": ["OB", "YB"] - }, - "schedule": { - "$ref": "#/components/schemas/AddAdminScheduleRequestDto" - } - }, - "description": "모집 일정" - }, - "AddAdminRequestDto": { - "required": [ - "generation", - "headerImageFileName", - "name", - "recruitHeaderImageFileName" - ], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "name": { - "type": "string", - "description": "기수명", - "example": "SOPT" - }, - "recruitSchedule": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminRecruitScheduleRequestDto" - } - }, - "brandingColor": { - "$ref": "#/components/schemas/AddAdminBrandingColorRequestDto" - }, - "mainButton": { - "$ref": "#/components/schemas/AddAdminMainButtonRequestDto" - }, - "partIntroduction": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminPartIntroductionRequestDto" - } - }, - "headerImageFileName": { - "type": "string", - "description": "헤더 이미지 파일명", - "example": "header.png" - }, - "coreValue": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminCoreValueRequestDto" - } - }, - "partCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminPartCurriculumRequestDto" - } - }, - "member": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminMemberRequestDto" - } - }, - "recruitHeaderImageFileName": { - "type": "string", - "description": "지원하기 헤더 이미지 파일명", - "example": "recruit_header.png" - }, - "recruitPartCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminRecruitPartCurriculumRequestDto" - } - }, - "recruitQuestion": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddAdminRecruitQuestionRequestDto" - } - } - }, - "description": "어드민 배포하기" - }, - "AddAdminScheduleRequestDto": { - "required": [ - "applicationEndTime", - "applicationResultTime", - "applicationStartTime", - "finalResultTime", - "interviewEndTime", - "interviewStartTime" - ], - "type": "object", - "properties": { - "applicationStartTime": { - "type": "string", - "description": "지원 시작 시간", - "example": "2024-01-01 09:00:00" - }, - "applicationEndTime": { - "type": "string", - "description": "지원 종료 시간", - "example": "2024-01-31 18:00:00" - }, - "applicationResultTime": { - "type": "string", - "description": "지원 결과 발표 시간", - "example": "2024-02-01 12:00:00" - }, - "interviewStartTime": { - "type": "string", - "description": "면접 시작 시간", - "example": "2024-02-05 09:00:00" - }, - "interviewEndTime": { - "type": "string", - "description": "면접 종료 시간", - "example": "2024-02-05 18:00:00" - }, - "finalResultTime": { - "type": "string", - "description": "최종 결과 발표 시간", - "example": "2024-02-10 12:00:00" - } - }, - "description": "상세 일정" - }, - "AddAdminSnsLinksRequestDto": { - "type": "object", - "properties": { - "email": { - "type": "string", - "description": "이메일", - "example": "example@sopt.org" - }, - "linkedin": { - "pattern": "^https?://.*", - "type": "string", - "description": "링크드인 URL", - "example": "https://www.linkedin.com/in/example" - }, - "github": { - "pattern": "^https?://.*", - "type": "string", - "description": "깃허브 URL", - "example": "https://github.com/example" - }, - "behance": { - "pattern": "^https?://.*", - "type": "string", - "description": "비핸스 URL", - "example": "https://www.behance.net/example" - } - }, - "description": "SNS 링크 정보" - }, - "AddAdminCoreValueResponseRecordDto": { - "required": ["image", "value"], - "type": "object", - "properties": { - "value": { - "type": "string", - "description": "핵심 가치", - "example": "용기" - }, - "image": { - "type": "string", - "description": "핵심가치 이미지 PresgiendUrl" - } - }, - "description": "핵심가치 이미지 S3 PresigneUrl 정보" - }, - "AddAdminMemberResponseRecordDto": { - "required": ["name", "profileImage", "role"], - "type": "object", - "properties": { - "role": { - "type": "string", - "description": "역할", - "example": "회장" - }, - "name": { - "type": "string", - "description": "이름", - "example": "홍길동" - }, - "profileImage": { - "type": "string", - "description": "프로필 이미지 PresgiendUrl" - } - }, - "description": "멤버 프로필 이미지 S3 PresigneUrl 정보" - }, - "AddAdminResponseDto": { - "required": [ - "coreValues", - "generation", - "headerImage", - "members", - "recruitHeaderImage" - ], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "headerImage": { - "type": "string", - "description": "헤더 이미지 S3 PresignedUrl", - "example": "https://image.url" - }, - "coreValues": { - "type": "array", - "description": "핵심가치 이미지 S3 PresigneUrl 정보", - "items": { - "$ref": "#/components/schemas/AddAdminCoreValueResponseRecordDto" - } - }, - "members": { - "type": "array", - "description": "멤버 프로필 이미지 S3 PresigneUrl 정보", - "items": { - "$ref": "#/components/schemas/AddAdminMemberResponseRecordDto" - } - }, - "recruitHeaderImage": { - "type": "string", - "description": "지원하기 헤더 이미지 S3 PresignedUrl", - "example": "https://image.url" - } - }, - "description": "어드민 메인정보 추가" - }, - "AddAdminNewsRequestDto": { - "required": ["image", "link", "title"], - "type": "object", - "properties": { - "image": { - "type": "string", - "format": "binary" - }, - "title": { - "type": "string", - "description": "제목", - "example": "MIND 23" - }, - "link": { - "type": "string", - "description": "링크", - "example": "https://disquiet.io/product/mind-23-%EC%98%A4%EB%8A%98%EB%8F%84-%EB%A9%88%EC%B6%94%EC%A7%80-%EC%95%8A%EB%8A%94-it%EC%9D%B8%EB%93%A4" - } - }, - "description": "최신소식 추가하기" - }, - "AddAdminConfirmRequestDto": { - "required": ["generation"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - } - }, - "description": "어드민 배포 확인" - }, - "SemestersListResponse": { - "type": "object", - "properties": { - "page": { - "type": "integer", - "description": "페이지네이션 조회 조건 페이지 수", - "format": "int32" - }, - "limit": { - "type": "integer", - "description": "페이지네이션 조회로 기수 정보 가져올 갯수", - "format": "int32" - }, - "total": { - "type": "integer", - "description": "조회한 기수 리스트 수", - "format": "int64" - }, - "semesters": { - "type": "array", - "description": "기수 대표 정보", - "nullable": true, - "items": { - "$ref": "#/components/schemas/SemestersResponse" - } - } - } - }, - "SemestersResponse": { - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "역대 기수", - "format": "int32" - }, - "color": { - "type": "string", - "description": "기수에 사용했던 컬러", - "nullable": true - }, - "logo": { - "type": "string", - "description": "기수에 사용했던 로고" - }, - "background": { - "type": "string", - "description": "기수에 사용했던 백그라운드 이미지", - "nullable": true - }, - "name": { - "type": "string", - "description": "기수에 사용했던 테마명", - "nullable": true - }, - "year": { - "type": "string", - "description": "기수 활동 기간" - } - }, - "description": "기수 대표 정보", - "nullable": true - }, - "Category": { - "required": ["project"], - "type": "object", - "properties": { - "project": { - "type": "string", - "enum": [ - "APPJAM", - "SOPKATHON", - "SOPTERM", - "STUDY", - "JOINTSEMINAR", - "ETC" - ] - } - }, - "description": "프로젝트의 카테고리" - }, - "Link": { - "required": ["title", "url"], - "type": "object", - "properties": { - "title": { - "type": "string", - "description": "웹사이트, 구글 플레이스토어, 앱스토어, Github, 발표영상 등 프로젝트에 관련된 링크의 종류", - "example": "website", - "enum": [ - "website", - "googlePlay", - "appStore", - "github", - "media", - "instagram" - ] - }, - "url": { - "type": "string", - "description": "링크의 url 주소", - "example": "https://example.com" - } - }, - "description": "프로젝트 링크" - }, - "PaginateResponseProjectResponse": { - "required": [ - "currentPage", - "hasNextPage", - "hasPrevPage", - "limit", - "totalCount", - "totalPage" - ], - "type": "object", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ProjectResponse" - } - }, - "hasNextPage": { - "type": "boolean", - "description": "다음 페이지가 있는지 여부를 나타냄." - }, - "hasPrevPage": { - "type": "boolean", - "description": "이전 페이지가 있는지 여부를 나타냄." - }, - "totalCount": { - "type": "integer", - "description": "총 data 들의 갯수", - "format": "int32" - }, - "totalPage": { - "type": "integer", - "description": "총 페이지 카운트", - "format": "int32" - }, - "currentPage": { - "type": "integer", - "description": "현재 페이지", - "format": "int32" - }, - "limit": { - "type": "integer", - "description": "item을 몇개까지 가져올지에 대한 카운트", - "format": "int32" - } - } - }, - "ProjectResponse": { - "required": [ - "category", - "detail", - "generation", - "id", - "isAvailable", - "isFounding", - "links", - "logoImage", - "name", - "serviceType", - "summary", - "thumbnailImage" - ], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "프로젝트의 Id", - "format": "int64" - }, - "name": { - "type": "string", - "description": "프로젝트의 이름" - }, - "generation": { - "type": "integer", - "description": "프로젝트가 진행된 기수", - "format": "int32" - }, - "category": { - "$ref": "#/components/schemas/Category" - }, - "serviceType": { - "type": "array", - "description": "서비스 형태", - "items": { - "type": "string", - "description": "서비스 형태", - "enum": ["WEB", "APP"] - } - }, - "summary": { - "type": "string", - "description": "프로젝트 한줄소개" - }, - "detail": { - "type": "string", - "description": "프로젝트 설명" - }, - "logoImage": { - "type": "string", - "description": "프로젝트 로고 이미지 URL" - }, - "thumbnailImage": { - "type": "string", - "description": "프로젝트 썸네일 이미지 URL" - }, - "isAvailable": { - "type": "boolean", - "description": "서비스 이용 가능 여부" - }, - "isFounding": { - "type": "boolean", - "description": "창업중인지 여부" - }, - "links": { - "type": "array", - "description": "프로젝트 링크", - "items": { - "$ref": "#/components/schemas/Link" - } - } - } - }, - "GetNotificationListResponseDto": { - "required": ["emailList", "generation"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "emailList": { - "type": "array", - "description": "모집알림 신청한 이메일 리스트", - "example": [ - "example@naver.com", - "example2@naver.com", - "example3@naver.com" - ], - "items": { - "type": "string", - "description": "모집알림 신청한 이메일 리스트", - "example": "[\"example@naver.com\",\"example2@naver.com\",\"example3@naver.com\"]" - } - } - } - }, - "GetMainBrandingColorResponseRecordDto": { - "required": ["high", "low", "main", "point"], - "type": "object", - "properties": { - "main": { - "type": "string", - "description": "메인 컬러", - "example": "#FF0000" - }, - "low": { - "type": "string", - "description": "로우 톤 컬러", - "example": "#CC0000" - }, - "high": { - "type": "string", - "description": "하이 톤 컬러", - "example": "#FF3333" - }, - "point": { - "type": "string", - "description": "포인트 컬러", - "example": "#FF9999" - } - }, - "description": "브랜딩 컬러 정보" - }, - "GetMainLatestNewsResponseRecordDto": { - "required": ["id", "image", "link", "title"], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "최신소식 ID", - "format": "int32", - "example": 1 - }, - "title": { - "type": "string", - "description": "최신소식 제목", - "example": "Mind 23" - }, - "image": { - "type": "string", - "description": "최신소식 이미지 링크", - "example": "https://image.url" - }, - "link": { - "type": "string", - "description": "최신소식 링크", - "example": "https://news.url" - } - }, - "description": "최신소식" - }, - "GetMainMainButtonResponseRecordDto": { - "required": ["keyColor", "subColor", "text"], - "type": "object", - "properties": { - "text": { - "type": "string", - "description": "버튼 텍스트", - "example": "지원하기" - }, - "keyColor": { - "type": "string", - "description": "주요 컬러", - "example": "#FF0000" - }, - "subColor": { - "type": "string", - "description": "보조 컬러", - "example": "#CC0000" - } - }, - "description": "메인 버튼 스타일" - }, - "GetMainPageResponseDto": { - "required": ["generation", "name"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "name": { - "type": "string", - "description": "기수명", - "example": "SOPT" - }, - "brandingColor": { - "$ref": "#/components/schemas/GetMainBrandingColorResponseRecordDto" - }, - "mainButton": { - "$ref": "#/components/schemas/GetMainMainButtonResponseRecordDto" - }, - "partIntroduction": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainPartIntroductionResponseRecordDto" - } - }, - "latestNews": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainLatestNewsResponseRecordDto" - } - } - }, - "description": "메인 페이지 데이터 조회하기" - }, - "GetMainPartIntroductionResponseRecordDto": { - "required": ["description", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "description": { - "type": "string", - "description": "파트 설명", - "example": "Android 앱 개발" - } - }, - "description": "파트 소개 정보" - }, - "GetMainIntroductionResponseRecordDto": { - "required": ["content", "preference"], - "type": "object", - "properties": { - "content": { - "type": "string", - "description": "내용", - "example": "Android 앱 개발" - }, - "preference": { - "type": "string", - "description": "우대사항", - "example": "Kotlin 개발 경험" - } - }, - "description": "소개글 정보" - }, - "GetMainQuestionResponseRecordDto": { - "required": ["answer", "question"], - "type": "object", - "properties": { - "question": { - "type": "string", - "description": "질문", - "example": "몇명 뽑나요?" - }, - "answer": { - "type": "string", - "description": "답변", - "example": "10명 뽑아요." - } - }, - "description": "질문과 답변 정보" - }, - "GetMainRecruitPartCurriculumResponseRecordDto": { - "required": ["introduction", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "introduction": { - "$ref": "#/components/schemas/GetMainIntroductionResponseRecordDto" - } - }, - "description": "모집 파트 커리큘럼 정보" - }, - "GetMainRecruitQuestionResponseRecordDto": { - "required": ["part", "questions"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "questions": { - "type": "array", - "description": "질문 리스트", - "items": { - "$ref": "#/components/schemas/GetMainQuestionResponseRecordDto" - } - } - }, - "description": "모집 질문 정보" - }, - "GetMainRecruitScheduleResponseRecordDto": { - "required": ["schedule", "type"], - "type": "object", - "properties": { - "type": { - "type": "string", - "description": "타입", - "example": "OB", - "enum": ["OB", "YB"] - }, - "schedule": { - "$ref": "#/components/schemas/GetMainScheduleResponseRecordDto" - } - }, - "description": "모집 일정 정보" - }, - "GetMainScheduleResponseRecordDto": { - "required": [ - "applicationEndTime", - "applicationResultTime", - "applicationStartTime", - "finalResultTime", - "interviewEndTime", - "interviewStartTime" - ], - "type": "object", - "properties": { - "applicationStartTime": { - "type": "string", - "description": "지원 시작 시간", - "example": "2024-01-01 09:00:00" - }, - "applicationEndTime": { - "type": "string", - "description": "지원 종료 시간", - "example": "2024-01-31 18:00:00" - }, - "applicationResultTime": { - "type": "string", - "description": "지원 결과 발표 시간", - "example": "2024-02-01 12:00:00" - }, - "interviewStartTime": { - "type": "string", - "description": "면접 시작 시간", - "example": "2024-02-05 09:00:00" - }, - "interviewEndTime": { - "type": "string", - "description": "면접 종료 시간", - "example": "2024-02-05 18:00:00" - }, - "finalResultTime": { - "type": "string", - "description": "최종 결과 발표 시간", - "example": "2024-02-10 12:00:00" - } - }, - "description": "상세 일정 정보" - }, - "GetRecruitingPageResponseDto": { - "required": ["generation", "name", "recruitHeaderImage"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "name": { - "type": "string", - "description": "기수명", - "example": "SOPT" - }, - "recruitHeaderImage": { - "type": "string", - "description": "지원하기 헤더 이미지 링크", - "example": "https://recruit_header.png" - }, - "brandingColor": { - "$ref": "#/components/schemas/GetMainBrandingColorResponseRecordDto" - }, - "recruitSchedule": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainRecruitScheduleResponseRecordDto" - } - }, - "recruitPartCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainRecruitPartCurriculumResponseRecordDto" - } - }, - "recruitQuestion": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainRecruitQuestionResponseRecordDto" - } - } - }, - "description": "지원하기 페이지 데이터 조회하기" - }, - "GetAboutPageResponseDto": { - "required": ["generation", "headerImage", "name"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "name": { - "type": "string", - "description": "기수명", - "example": "SOPT" - }, - "headerImage": { - "type": "string", - "description": "헤더 이미지 링크", - "example": "https://header.png" - }, - "brandingColor": { - "$ref": "#/components/schemas/GetMainBrandingColorResponseRecordDto" - }, - "coreValue": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainCoreValueResponseRecordDto" - } - }, - "partCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainPartCurriculumResponseRecordDto" - } - }, - "member": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetMainMemberResponseRecordDto" - } - } - }, - "description": "소개 페이지 데이터 조회하기" - }, - "GetMainCoreValueResponseRecordDto": { - "required": ["description", "image", "value"], - "type": "object", - "properties": { - "value": { - "type": "string", - "description": "핵심 가치", - "example": "용기" - }, - "description": { - "type": "string", - "description": "핵심 가치 설명", - "example": "새로운 도전을 위해 과감히 용기내는 사람" - }, - "image": { - "type": "string", - "description": "핵심 가치 이미지 링크", - "example": "https://corevalue.png" - } - }, - "description": "핵심 가치 정보" - }, - "GetMainCurriculumWeekResponseRecordDto": { - "required": ["description", "week"], - "type": "object", - "properties": { - "week": { - "maximum": 8, - "minimum": 1, - "type": "integer", - "description": "주차", - "format": "int32", - "example": 1 - }, - "description": { - "type": "string", - "description": "커리큘럼 설명", - "example": "Android 기초 학습" - } - }, - "description": "주차별 커리큘럼 정보" - }, - "GetMainMemberResponseRecordDto": { - "required": [ - "affiliation", - "introduction", - "name", - "profileImage", - "role", - "sns" - ], - "type": "object", - "properties": { - "role": { - "type": "string", - "description": "역할", - "example": "회장" - }, - "name": { - "type": "string", - "description": "이름", - "example": "홍길동" - }, - "affiliation": { - "type": "string", - "description": "소속", - "example": "SOPT" - }, - "introduction": { - "type": "string", - "description": "한줄 소개", - "example": "안녕하세요!" - }, - "profileImage": { - "type": "string", - "description": "프로필 이미지 링크", - "example": "https://profile.png" - }, - "sns": { - "$ref": "#/components/schemas/GetMainSnsLinksResponseRecordDto" - } - }, - "description": "멤버 정보" - }, - "GetMainPartCurriculumResponseRecordDto": { - "required": ["part", "weeks"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "weeks": { - "type": "array", - "description": "주차별 커리큘럼", - "items": { - "$ref": "#/components/schemas/GetMainCurriculumWeekResponseRecordDto" - } - } - }, - "description": "파트별 커리큘럼 정보" - }, - "GetMainSnsLinksResponseRecordDto": { - "type": "object", - "properties": { - "email": { - "type": "string", - "description": "이메일", - "example": "example@sopt.org" - }, - "linkedin": { - "type": "string", - "description": "링크드인 URL", - "example": "https://www.linkedin.com/in/example" - }, - "github": { - "type": "string", - "description": "깃허브 URL", - "example": "https://github.com/example" - }, - "behance": { - "type": "string", - "description": "비핸스 URL", - "example": "https://www.behance.net/example" - } - }, - "description": "SNS 링크 정보" - }, - "GetAdminBrandingColorResponseRecordDto": { - "required": ["high", "low", "main", "point"], - "type": "object", - "properties": { - "main": { - "type": "string", - "description": "메인 컬러", - "example": "#FF0000" - }, - "low": { - "type": "string", - "description": "로우 톤 컬러", - "example": "#CC0000" - }, - "high": { - "type": "string", - "description": "하이 톤 컬러", - "example": "#FF3333" - }, - "point": { - "type": "string", - "description": "포인트 컬러", - "example": "#FF9999" - } - }, - "description": "브랜딩 컬러 정보" - }, - "GetAdminCoreValueResponseRecordDto": { - "required": ["description", "image", "value"], - "type": "object", - "properties": { - "value": { - "type": "string", - "description": "핵심 가치", - "example": "용기" - }, - "description": { - "type": "string", - "description": "핵심 가치 설명", - "example": "새로운 도전을 위해 과감히 용기내는 사람" - }, - "image": { - "type": "string", - "description": "핵심 가치 이미지 링크", - "example": "https://corevalue.png" - } - }, - "description": "핵심 가치 정보" - }, - "GetAdminCurriculumWeekResponseRecordDto": { - "required": ["description", "week"], - "type": "object", - "properties": { - "week": { - "maximum": 8, - "minimum": 1, - "type": "integer", - "description": "주차", - "format": "int32", - "example": 1 - }, - "description": { - "type": "string", - "description": "커리큘럼 설명", - "example": "Android 기초 학습" - } - }, - "description": "주차별 커리큘럼 정보" - }, - "GetAdminIntroductionResponseRecordDto": { - "required": ["content", "preference"], - "type": "object", - "properties": { - "content": { - "type": "string", - "description": "내용", - "example": "Android 앱 개발" - }, - "preference": { - "type": "string", - "description": "우대사항", - "example": "Kotlin 개발 경험" - } - }, - "description": "소개글 정보" - }, - "GetAdminLatestNewsResponseRecordDto": { - "required": ["id", "title"], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "최신소식 ID", - "format": "int32", - "example": 1 - }, - "title": { - "type": "string", - "description": "최신소식 제목", - "example": "Mind 23" - } - }, - "description": "최신소식" - }, - "GetAdminMainButtonResponseRecordDto": { - "required": ["keyColor", "subColor", "text"], - "type": "object", - "properties": { - "text": { - "type": "string", - "description": "버튼 텍스트", - "example": "지원하기" - }, - "keyColor": { - "type": "string", - "description": "주요 컬러", - "example": "#FF0000" - }, - "subColor": { - "type": "string", - "description": "보조 컬러", - "example": "#CC0000" - } - }, - "description": "메인 버튼 스타일" - }, - "GetAdminMemberResponseRecordDto": { - "required": [ - "affiliation", - "introduction", - "name", - "profileImage", - "role", - "sns" - ], - "type": "object", - "properties": { - "role": { - "type": "string", - "description": "역할", - "example": "회장" - }, - "name": { - "type": "string", - "description": "이름", - "example": "홍길동" - }, - "affiliation": { - "type": "string", - "description": "소속", - "example": "SOPT" - }, - "introduction": { - "type": "string", - "description": "한줄 소개", - "example": "안녕하세요!" - }, - "profileImage": { - "type": "string", - "description": "프로필 이미지 링크", - "example": "https://profile.png" - }, - "sns": { - "$ref": "#/components/schemas/GetAdminSnsLinksResponseRecordDto" - } - }, - "description": "멤버 정보" - }, - "GetAdminPartCurriculumResponseRecordDto": { - "required": ["part", "weeks"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "weeks": { - "type": "array", - "description": "주차별 커리큘럼", - "items": { - "$ref": "#/components/schemas/GetAdminCurriculumWeekResponseRecordDto" - } - } - }, - "description": "파트별 커리큘럼 정보" - }, - "GetAdminPartIntroductionResponseRecordDto": { - "required": ["description", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "description": { - "type": "string", - "description": "파트 설명", - "example": "Android 앱 개발" - } - }, - "description": "파트 소개 정보" - }, - "GetAdminQuestionResponseRecordDto": { - "required": ["answer", "question"], - "type": "object", - "properties": { - "question": { - "type": "string", - "description": "질문", - "example": "몇명 뽑나요?" - }, - "answer": { - "type": "string", - "description": "답변", - "example": "10명 뽑아요." - } - }, - "description": "질문과 답변 정보" - }, - "GetAdminRecruitPartCurriculumResponseRecordDto": { - "required": ["introduction", "part"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "introduction": { - "$ref": "#/components/schemas/GetAdminIntroductionResponseRecordDto" - } - }, - "description": "모집 파트 커리큘럼 정보" - }, - "GetAdminRecruitQuestionResponseRecordDto": { - "required": ["part", "questions"], - "type": "object", - "properties": { - "part": { - "type": "string", - "description": "파트명", - "example": "안드로이드" - }, - "questions": { - "type": "array", - "description": "질문 리스트", - "items": { - "$ref": "#/components/schemas/GetAdminQuestionResponseRecordDto" - } - } - }, - "description": "모집 질문 정보" - }, - "GetAdminRecruitScheduleResponseRecordDto": { - "required": ["schedule", "type"], - "type": "object", - "properties": { - "type": { - "type": "string", - "description": "타입", - "example": "OB", - "enum": ["OB", "YB"] - }, - "schedule": { - "$ref": "#/components/schemas/GetAdminScheduleResponseRecordDto" - } - }, - "description": "모집 일정 정보" - }, - "GetAdminResponseDto": { - "required": ["generation", "headerImage", "name", "recruitHeaderImage"], - "type": "object", - "properties": { - "generation": { - "type": "integer", - "description": "기수", - "format": "int32", - "example": 34 - }, - "name": { - "type": "string", - "description": "기수명", - "example": "SOPT" - }, - "recruitSchedule": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminRecruitScheduleResponseRecordDto" - } - }, - "brandingColor": { - "$ref": "#/components/schemas/GetAdminBrandingColorResponseRecordDto" - }, - "mainButton": { - "$ref": "#/components/schemas/GetAdminMainButtonResponseRecordDto" - }, - "partIntroduction": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminPartIntroductionResponseRecordDto" - } - }, - "latestNews": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminLatestNewsResponseRecordDto" - } - }, - "headerImage": { - "type": "string", - "description": "헤더 이미지 링크", - "example": "https://header.png" - }, - "coreValue": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminCoreValueResponseRecordDto" - } - }, - "partCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminPartCurriculumResponseRecordDto" - } - }, - "member": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminMemberResponseRecordDto" - } - }, - "recruitHeaderImage": { - "type": "string", - "description": "지원하기 헤더 이미지 링크", - "example": "https://recruit_header.png" - }, - "recruitPartCurriculum": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminRecruitPartCurriculumResponseRecordDto" - } - }, - "recruitQuestion": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetAdminRecruitQuestionResponseRecordDto" - } - } - }, - "description": "어드민 데이터 조회하기" - }, - "GetAdminScheduleResponseRecordDto": { - "required": [ - "applicationEndTime", - "applicationResultTime", - "applicationStartTime", - "finalResultTime", - "interviewEndTime", - "interviewStartTime" - ], - "type": "object", - "properties": { - "applicationStartTime": { - "type": "string", - "description": "지원 시작 시간", - "example": "2024-01-01 09:00:00" - }, - "applicationEndTime": { - "type": "string", - "description": "지원 종료 시간", - "example": "2024-01-31 18:00:00" - }, - "applicationResultTime": { - "type": "string", - "description": "지원 결과 발표 시간", - "example": "2024-02-01 12:00:00" - }, - "interviewStartTime": { - "type": "string", - "description": "면접 시작 시간", - "example": "2024-02-05 09:00:00" - }, - "interviewEndTime": { - "type": "string", - "description": "면접 종료 시간", - "example": "2024-02-05 18:00:00" - }, - "finalResultTime": { - "type": "string", - "description": "최종 결과 발표 시간", - "example": "2024-02-10 12:00:00" - } - }, - "description": "상세 일정 정보" - }, - "GetAdminSnsLinksResponseRecordDto": { - "type": "object", - "properties": { - "email": { - "type": "string", - "description": "이메일", - "example": "example@sopt.org" - }, - "linkedin": { - "type": "string", - "description": "링크드인 URL", - "example": "https://www.linkedin.com/in/example" - }, - "github": { - "type": "string", - "description": "깃허브 URL", - "example": "https://github.com/example" - }, - "behance": { - "type": "string", - "description": "비핸스 URL", - "example": "https://www.behance.net/example" - } - }, - "description": "SNS 링크 정보" - }, - "GetAdminNewsResponseDto": { - "required": ["id", "image", "link", "title"], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "이미지 ID", - "format": "int32", - "example": 1 - }, - "image": { - "type": "string", - "description": "이미지 링크", - "example": "https://image.url" - }, - "title": { - "type": "string", - "description": "제목", - "example": "MIND 23" - }, - "link": { - "type": "string", - "description": "링크", - "example": "https://disquiet.io/product/mind-23-%EC%98%A4%EB%8A%98%EB%8F%84-%EB%A9%88%EC%B6%94%EC%A7%80-%EC%95%8A%EB%8A%94-it%EC%9D%B8%EB%93%A4" - } - }, - "description": "최신소식 조회하기" - }, - "DeleteAdminNewsRequestDto": { - "required": ["id"], - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "최신소식 ID", - "format": "int32" - } - }, - "description": "최신소식 삭제하기" - } - }, - "securitySchemes": { - "Authorization": { - "type": "apiKey", - "name": "Authorization", - "in": "header" - } - } - } -} diff --git a/src/__generated__/org-types/Admin.ts b/src/__generated__/org-types/Admin.ts new file mode 100644 index 0000000..a18af47 --- /dev/null +++ b/src/__generated__/org-types/Admin.ts @@ -0,0 +1,162 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { + AddAdminConfirmRequestDto, + AddAdminNewsRequestDto, + AddAdminRequestDto, + AddMainConfirmData, + AddMainData, + AddMainNewsData, + DeleteAdminNewsRequestDto, + DeleteMainNewsData, + GetMainData, + GetMainNewsData, +} from './data-contracts'; +import { ContentType, HttpClient, RequestParams } from './http-client'; + +export class Admin< + SecurityDataType = unknown, +> extends HttpClient { + /** + * @description 어드민 메인 데이터를 조회합니다 + * + * @tags Admin + * @name GetMain + * @summary 어드민 메인 데이터 조회 + * @request GET:/admin + * @secure + * @response `200` `GetMainData` OK + */ + getMain = ( + query: { + /** + * 기수 + * @example 35 + */ + generation: string; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/admin`, + method: 'GET', + query: query, + secure: true, + ...params, + }); + /** + * @description 어드민 메인 데이터를 배포합니다 + * + * @tags Admin + * @name AddMain + * @summary 어드민 메인 데이터 배포 + * @request POST:/admin + * @secure + * @response `200` `AddMainData` OK + */ + addMain = (data: AddAdminRequestDto, params: RequestParams = {}) => + this.request({ + path: `/admin`, + method: 'POST', + body: data, + secure: true, + type: ContentType.Json, + ...params, + }); + /** + * @description 최신소식을 조회합니다 + * + * @tags Admin + * @name GetMainNews + * @summary 최신소식 조회 + * @request GET:/admin/news + * @secure + * @response `200` `GetMainNewsData` OK + */ + getMainNews = ( + query: { + /** 최신소식 ID */ + id: string; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/admin/news`, + method: 'GET', + query: query, + secure: true, + ...params, + }); + /** + * @description 최신소식을 추가합니다 + * + * @tags Admin + * @name AddMainNews + * @summary 최신소식 추가 + * @request POST:/admin/news + * @secure + * @response `200` `AddMainNewsData` OK + */ + addMainNews = (data: AddAdminNewsRequestDto, params: RequestParams = {}) => + this.request({ + path: `/admin/news`, + method: 'POST', + body: data, + secure: true, + type: ContentType.FormData, + ...params, + }); + /** + * @description 최신소식을 삭제합니다 + * + * @tags Admin + * @name DeleteMainNews + * @summary 최신소식 삭제 + * @request POST:/admin/news/delete + * @secure + * @response `200` `DeleteMainNewsData` OK + */ + deleteMainNews = ( + data: DeleteAdminNewsRequestDto, + params: RequestParams = {}, + ) => + this.request({ + path: `/admin/news/delete`, + method: 'POST', + body: data, + secure: true, + type: ContentType.Json, + ...params, + }); + /** + * @description 어드민 메인 데이터 배포를 확인합니다 + * + * @tags Admin + * @name AddMainConfirm + * @summary 어드민 메인 데이터 배포 확인 + * @request POST:/admin/confirm + * @secure + * @response `200` `AddMainConfirmData` OK + */ + addMainConfirm = ( + data: AddAdminConfirmRequestDto, + params: RequestParams = {}, + ) => + this.request({ + path: `/admin/confirm`, + method: 'POST', + body: data, + secure: true, + type: ContentType.Json, + ...params, + }); +} diff --git a/src/__generated__/org-types/Health.ts b/src/__generated__/org-types/Health.ts new file mode 100644 index 0000000..ef32eb9 --- /dev/null +++ b/src/__generated__/org-types/Health.ts @@ -0,0 +1,32 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { HealthCheckData } from './data-contracts'; +import { HttpClient, RequestParams } from './http-client'; + +export class Health< + SecurityDataType = unknown, +> extends HttpClient { + /** + * No description + * + * @tags HealthCheck + * @name HealthCheck + * @request GET:/health + * @response `200` `HealthCheckData` OK + */ + healthCheck = (params: RequestParams = {}) => + this.request({ + path: `/health`, + method: 'GET', + ...params, + }); +} diff --git a/src/__generated__/org-types/Homepage.ts b/src/__generated__/org-types/Homepage.ts new file mode 100644 index 0000000..313bae1 --- /dev/null +++ b/src/__generated__/org-types/Homepage.ts @@ -0,0 +1,63 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { GetAboutPageData, GetData, GetMainPageData } from './data-contracts'; +import { HttpClient, RequestParams } from './http-client'; + +export class Homepage< + SecurityDataType = unknown, +> extends HttpClient { + /** + * @description 메인 페이지 데이터를 조회합니다 + * + * @tags Homepage + * @name GetMainPage + * @summary 메인 페이지 조회 + * @request GET:/homepage + * @response `200` `GetMainPageData` OK + */ + getMainPage = (params: RequestParams = {}) => + this.request({ + path: `/homepage`, + method: 'GET', + ...params, + }); + /** + * @description 지원하기 페이지 데이터를 조회합니다 + * + * @tags Homepage + * @name Get + * @summary 지원하기 페이지 조회 + * @request GET:/homepage/recruit + * @response `200` `GetData` OK + */ + get = (params: RequestParams = {}) => + this.request({ + path: `/homepage/recruit`, + method: 'GET', + ...params, + }); + /** + * @description 소개 페이지 데이터를 조회합니다 + * + * @tags Homepage + * @name GetAboutPage + * @summary 소개 페이지 조회 + * @request GET:/homepage/about + * @response `200` `GetAboutPageData` OK + */ + getAboutPage = (params: RequestParams = {}) => + this.request({ + path: `/homepage/about`, + method: 'GET', + ...params, + }); +} diff --git a/src/__generated__/org-types/Notification.ts b/src/__generated__/org-types/Notification.ts new file mode 100644 index 0000000..5f72d76 --- /dev/null +++ b/src/__generated__/org-types/Notification.ts @@ -0,0 +1,71 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { GetAllProject1Data, RegisterNotificationData } from './data-contracts'; +import { HttpClient, RequestParams } from './http-client'; + +export class Notification< + SecurityDataType = unknown, +> extends HttpClient { + /** + * No description + * + * @tags Notification + * @name RegisterNotification + * @request POST:/notification/register + * @response `200` `RegisterNotificationData` OK + */ + registerNotification = ( + query: { + /** + * 활동 기수 + * @example 34 + */ + generation: string; + /** + * 이메일 + * @example "example@naver.com" + */ + email: string; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/notification/register`, + method: 'POST', + query: query, + ...params, + }); + /** + * No description + * + * @tags Notification + * @name GetAllProject1 + * @request GET:/notification/list + * @response `200` `GetAllProject1Data` OK + */ + getAllProject1 = ( + query?: { + /** + * 기수 + * @format int32 + */ + generation?: number; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/notification/list`, + method: 'GET', + query: query, + ...params, + }); +} diff --git a/src/__generated__/org-types/Projects.ts b/src/__generated__/org-types/Projects.ts new file mode 100644 index 0000000..cd02ba9 --- /dev/null +++ b/src/__generated__/org-types/Projects.ts @@ -0,0 +1,61 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { GetAllProjectData } from './data-contracts'; +import { HttpClient, RequestParams } from './http-client'; + +export class Projects< + SecurityDataType = unknown, +> extends HttpClient { + /** + * No description + * + * @tags Project + * @name GetAllProject + * @request GET:/projects + * @response `200` `GetAllProjectData` OK + */ + getAllProject = ( + query?: { + /** 프로젝트 타입 */ + filter?: + | 'APPJAM' + | 'SOPKATHON' + | 'SOPTERM' + | 'STUDY' + | 'JOINTSEMINAR' + | 'ETC'; + /** 서비스 플랫폼 */ + platform?: 'WEB' | 'APP'; + /** + * 페이지 + * @format int32 + * @min 1 + * @example 1 + */ + pageNo?: number; + /** + * 페이지별 데이터 개수 + * @format int32 + * @min 1 + * @example 10 + */ + limit?: number; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/projects`, + method: 'GET', + query: query, + ...params, + }); +} diff --git a/src/__generated__/org-types/Semesters.ts b/src/__generated__/org-types/Semesters.ts new file mode 100644 index 0000000..cfae6db --- /dev/null +++ b/src/__generated__/org-types/Semesters.ts @@ -0,0 +1,44 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +import { GetSemestersData } from './data-contracts'; +import { HttpClient, RequestParams } from './http-client'; + +export class Semesters< + SecurityDataType = unknown, +> extends HttpClient { + /** + * No description + * + * @tags Semester + * @name GetSemesters + * @request GET:/semesters + * @response `200` `GetSemestersData` OK + */ + getSemesters = ( + query: { + /** @format int32 */ + limit: number; + /** + * @format int32 + * @default 1 + */ + page?: number; + }, + params: RequestParams = {}, + ) => + this.request({ + path: `/semesters`, + method: 'GET', + query: query, + ...params, + }); +} diff --git a/src/__generated__/org-types/data-contracts.ts b/src/__generated__/org-types/data-contracts.ts new file mode 100644 index 0000000..f886b25 --- /dev/null +++ b/src/__generated__/org-types/data-contracts.ts @@ -0,0 +1,1246 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +export interface RegisterNotificationResponseDto { + /** + * Notification ID + * @format int32 + */ + id: number; + /** + * 기수 (Generation) + * @format int32 + */ + generation: number; + /** 이메일 (Email) */ + email: string; + /** + * 생성일자 (Creation Date) + * @format date-time + */ + createdAt: string; +} + +/** 브랜딩 컬러 */ +export interface AddAdminBrandingColorRequestDto { + /** + * 메인 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#FF0000" + */ + main: string; + /** + * 로우 톤 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#CC0000" + */ + low: string; + /** + * 하이 톤 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#FF3333" + */ + high: string; + /** + * 포인트 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#FF9999" + */ + point: string; +} + +/** 핵심 가치 */ +export interface AddAdminCoreValueRequestDto { + /** + * 핵심 가치 + * @example "용기" + */ + value: string; + /** + * 핵심 가치 설명 + * @example "새로운 도전을 위해 과감히 용기내는 사람" + */ + description: string; + /** + * 핵심 가치 이미지 파일명 + * @example "image.png" + */ + imageFileName: string; +} + +/** 소개글 정보 */ +export interface AddAdminIntroductionRequestDto { + /** + * 내용 + * @example "Android 앱 개발" + */ + content: string; + /** + * 우대사항 + * @example "Kotlin 개발 경험" + */ + preference: string; +} + +/** 메인 버튼 스타일 */ +export interface AddAdminMainButtonRequestDto { + /** + * 버튼 텍스트 + * @example "지원하기" + */ + text: string; + /** + * 주요 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#FF0000" + */ + keyColor: string; + /** + * 보조 컬러 + * @pattern ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$ + * @example "#CC0000" + */ + subColor: string; +} + +/** 멤버 정보 */ +export interface AddAdminMemberRequestDto { + /** + * 역할 + * @example "회장" + */ + role: string; + /** + * 이름 + * @example "홍길동" + */ + name: string; + /** + * 소속 + * @example "SOPT" + */ + affiliation: string; + /** + * 한줄 소개 + * @example "안녕하세요!" + */ + introduction: string; + /** SNS 링크 정보 */ + sns: AddAdminSnsLinksRequestDto; + /** + * 프로필 이미지 파일명 + * @example "image.png" + */ + profileImageFileName: string; +} + +/** 파트별 커리큘럼 */ +export interface AddAdminPartCurriculumRequestDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 주차별 커리큘럼 (배열 순서 = 주차 순서) */ + curriculums: string[]; +} + +/** 파트 소개 */ +export interface AddAdminPartIntroductionRequestDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** + * 파트 설명 + * @example "Android 앱 개발" + */ + description: string; +} + +/** 질문과 답변 */ +export interface AddAdminQuestionRequestDto { + /** + * 질문 + * @example "몇명 뽑나요?" + */ + question: string; + /** + * 답변 + * @example "10명 뽑아요." + */ + answer: string; +} + +/** 모집 파트 커리큘럼 */ +export interface AddAdminRecruitPartCurriculumRequestDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 소개글 정보 */ + introduction: AddAdminIntroductionRequestDto; +} + +/** 모집 질문 */ +export interface AddAdminRecruitQuestionRequestDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 질문 리스트 */ + questions: AddAdminQuestionRequestDto[]; +} + +/** 모집 일정 */ +export interface AddAdminRecruitScheduleRequestDto { + /** + * 타입 + * @pattern ^(OB|YB)$ + * @example "OB" + */ + type: 'OB' | 'YB'; + /** 상세 일정 */ + schedule: AddAdminScheduleRequestDto; +} + +/** 어드민 배포하기 */ +export interface AddAdminRequestDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 기수명 + * @example "SOPT" + */ + name: string; + recruitSchedule?: AddAdminRecruitScheduleRequestDto[]; + /** 브랜딩 컬러 */ + brandingColor?: AddAdminBrandingColorRequestDto; + /** 메인 버튼 스타일 */ + mainButton?: AddAdminMainButtonRequestDto; + partIntroduction?: AddAdminPartIntroductionRequestDto[]; + /** + * 헤더 이미지 파일명 + * @example "header.png" + */ + headerImageFileName: string; + coreValue?: AddAdminCoreValueRequestDto[]; + partCurriculum?: AddAdminPartCurriculumRequestDto[]; + member?: AddAdminMemberRequestDto[]; + /** + * 지원하기 헤더 이미지 파일명 + * @example "recruit_header.png" + */ + recruitHeaderImageFileName: string; + recruitPartCurriculum?: AddAdminRecruitPartCurriculumRequestDto[]; + recruitQuestion?: AddAdminRecruitQuestionRequestDto[]; +} + +/** 상세 일정 */ +export interface AddAdminScheduleRequestDto { + /** + * 지원 시작 시간 + * @example "2024-01-01T09:00:00.000Z" + */ + applicationStartTime: string; + /** + * 지원 종료 시간 + * @example "2024-01-31T18:00:00.000Z" + */ + applicationEndTime: string; + /** + * 지원 결과 발표 시간 + * @example "2024-02-01T12:00:00.000Z" + */ + applicationResultTime: string; + /** + * 면접 시작 시간 + * @example "2024-02-05T09:00:00.000Z" + */ + interviewStartTime: string; + /** + * 면접 종료 시간 + * @example "2024-02-05T18:00:00.000Z" + */ + interviewEndTime: string; + /** + * 최종 결과 발표 시간 + * @example "2024-02-10T12:00:00.000Z" + */ + finalResultTime: string; +} + +/** SNS 링크 정보 */ +export interface AddAdminSnsLinksRequestDto { + /** + * 이메일 + * @example "example@sopt.org" + */ + email?: string; + /** + * 링크드인 URL + * @pattern ^https?://.* + * @example "https://www.linkedin.com/in/example" + */ + linkedin?: string; + /** + * 깃허브 URL + * @pattern ^https?://.* + * @example "https://github.com/example" + */ + github?: string; + /** + * 비핸스 URL + * @pattern ^https?://.* + * @example "https://www.behance.net/example" + */ + behance?: string; +} + +/** 핵심가치 이미지 S3 PresigneUrl 정보 */ +export interface AddAdminCoreValueResponseRecordDto { + /** + * 핵심 가치 + * @example "용기" + */ + value: string; + /** 핵심가치 이미지 PresgiendUrl */ + image: string; +} + +/** 멤버 프로필 이미지 S3 PresigneUrl 정보 */ +export interface AddAdminMemberResponseRecordDto { + /** + * 역할 + * @example "회장" + */ + role: string; + /** + * 이름 + * @example "홍길동" + */ + name: string; + /** 프로필 이미지 PresgiendUrl */ + profileImage: string; +} + +/** 어드민 메인정보 추가 */ +export interface AddAdminResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 헤더 이미지 S3 PresignedUrl + * @example "https://image.url" + */ + headerImage: string; + /** 핵심가치 이미지 S3 PresigneUrl 정보 */ + coreValues: AddAdminCoreValueResponseRecordDto[]; + /** 멤버 프로필 이미지 S3 PresigneUrl 정보 */ + members: AddAdminMemberResponseRecordDto[]; + /** + * 지원하기 헤더 이미지 S3 PresignedUrl + * @example "https://image.url" + */ + recruitHeaderImage: string; +} + +/** 최신소식 추가하기 */ +export interface AddAdminNewsRequestDto { + /** @format binary */ + image: File; + /** + * 제목 + * @example "MIND 23" + */ + title: string; + /** + * 링크 + * @example "https://disquiet.io/product/mind-23-%EC%98%A4%EB%8A%98%EB%8F%84-%EB%A9%88%EC%B6%94%EC%A7%80-%EC%95%8A%EB%8A%94-it%EC%9D%B8%EB%93%A4" + */ + link: string; +} + +/** 최신 소식 추가 */ +export interface AddAdminNewsResponseDto { + /** + * 성공 메세지 + * @example "success" + */ + message: string; +} + +/** 최신소식 삭제하기 */ +export interface DeleteAdminNewsRequestDto { + /** + * 최신소식 ID + * @format int32 + */ + id: number; +} + +/** 최신소식 삭제 */ +export interface DeleteAdminNewsResponseDto { + /** + * 성공 메세지 + * @example "success" + */ + message: string; +} + +/** 어드민 배포 확인 */ +export interface AddAdminConfirmRequestDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; +} + +/** 어드민 메인정보 파일 업로드 확인 */ +export interface AddAdminConfirmResponseDto { + /** + * 성공 메세지 + * @example "success" + */ + message: string; +} + +export interface SemestersListResponse { + /** + * 페이지네이션 조회 조건 페이지 수 + * @format int32 + */ + page?: number; + /** + * 페이지네이션 조회로 기수 정보 가져올 갯수 + * @format int32 + */ + limit?: number; + /** + * 조회한 기수 리스트 수 + * @format int64 + */ + total?: number; + /** 기수 대표 정보 */ + semesters?: SemestersResponse[] | null; +} + +/** 기수 대표 정보 */ +export type SemestersResponse = { + /** + * 역대 기수 + * @format int32 + */ + id?: number; + /** 기수에 사용했던 컬러 */ + color?: string | null; + /** 기수에 사용했던 로고 */ + logo?: string; + /** 기수에 사용했던 백그라운드 이미지 */ + background?: string | null; + /** 기수에 사용했던 테마명 */ + name?: string | null; + /** 기수 활동 기간 */ + year?: string; +}; + +/** 프로젝트의 카테고리 */ +export interface Category { + project: + | 'APPJAM' + | 'SOPKATHON' + | 'SOPTERM' + | 'STUDY' + | 'JOINTSEMINAR' + | 'ETC'; +} + +/** 프로젝트 링크 */ +export interface Link { + /** + * 웹사이트, 구글 플레이스토어, 앱스토어, Github, 발표영상 등 프로젝트에 관련된 링크의 종류 + * @example "website" + */ + title: + | 'website' + | 'googlePlay' + | 'appStore' + | 'github' + | 'media' + | 'instagram'; + /** + * 링크의 url 주소 + * @example "https://example.com" + */ + url: string; +} + +export interface PaginateResponseProjectResponse { + data?: ProjectResponse[]; + /** 다음 페이지가 있는지 여부를 나타냄. */ + hasNextPage: boolean; + /** 이전 페이지가 있는지 여부를 나타냄. */ + hasPrevPage: boolean; + /** + * 총 data 들의 갯수 + * @format int32 + */ + totalCount: number; + /** + * 총 페이지 카운트 + * @format int32 + */ + totalPage: number; + /** + * 현재 페이지 + * @format int32 + */ + currentPage: number; + /** + * item을 몇개까지 가져올지에 대한 카운트 + * @format int32 + */ + limit: number; +} + +export interface ProjectResponse { + /** + * 프로젝트의 Id + * @format int64 + */ + id: number; + /** 프로젝트의 이름 */ + name: string; + /** + * 프로젝트가 진행된 기수 + * @format int32 + */ + generation: number; + /** 프로젝트의 카테고리 */ + category: Category; + /** 서비스 형태 */ + serviceType: ('WEB' | 'APP')[]; + /** 프로젝트 한줄소개 */ + summary: string; + /** 프로젝트 설명 */ + detail: string; + /** 프로젝트 로고 이미지 URL */ + logoImage: string; + /** 프로젝트 썸네일 이미지 URL */ + thumbnailImage: string; + /** 서비스 이용 가능 여부 */ + isAvailable: boolean; + /** 창업중인지 여부 */ + isFounding: boolean; + /** 프로젝트 링크 */ + links: Link[]; +} + +export interface GetNotificationListResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 모집알림 신청한 이메일 리스트 + * @example ["example@naver.com","example2@naver.com","example3@naver.com"] + */ + emailList: string[]; +} + +/** 브랜딩 컬러 정보 */ +export interface GetMainBrandingColorResponseRecordDto { + /** + * 메인 컬러 + * @example "#FF0000" + */ + main: string; + /** + * 로우 톤 컬러 + * @example "#CC0000" + */ + low: string; + /** + * 하이 톤 컬러 + * @example "#FF3333" + */ + high: string; + /** + * 포인트 컬러 + * @example "#FF9999" + */ + point: string; +} + +/** 최신소식 */ +export interface GetMainLatestNewsResponseRecordDto { + /** + * 최신소식 ID + * @format int32 + * @example 1 + */ + id: number; + /** + * 최신소식 제목 + * @example "Mind 23" + */ + title: string; + /** + * 최신소식 이미지 링크 + * @example "https://image.url" + */ + image: string; + /** + * 최신소식 링크 + * @example "https://news.url" + */ + link: string; +} + +/** 메인 버튼 스타일 */ +export interface GetMainMainButtonResponseRecordDto { + /** + * 버튼 텍스트 + * @example "지원하기" + */ + text: string; + /** + * 주요 컬러 + * @example "#FF0000" + */ + keyColor: string; + /** + * 보조 컬러 + * @example "#CC0000" + */ + subColor: string; +} + +/** 메인 페이지 데이터 조회하기 */ +export interface GetMainPageResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 기수명 + * @example "SOPT" + */ + name: string; + /** 브랜딩 컬러 정보 */ + brandingColor?: GetMainBrandingColorResponseRecordDto; + /** 메인 버튼 스타일 */ + mainButton?: GetMainMainButtonResponseRecordDto; + partIntroduction?: GetMainPartIntroductionResponseRecordDto[]; + latestNews?: GetMainLatestNewsResponseRecordDto[]; +} + +/** 파트 소개 정보 */ +export interface GetMainPartIntroductionResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** + * 파트 설명 + * @example "Android 앱 개발" + */ + description: string; +} + +/** 소개글 정보 */ +export interface GetMainIntroductionResponseRecordDto { + /** + * 내용 + * @example "Android 앱 개발" + */ + content: string; + /** + * 우대사항 + * @example "Kotlin 개발 경험" + */ + preference: string; +} + +/** 질문과 답변 정보 */ +export interface GetMainQuestionResponseRecordDto { + /** + * 질문 + * @example "몇명 뽑나요?" + */ + question: string; + /** + * 답변 + * @example "10명 뽑아요." + */ + answer: string; +} + +/** 모집 파트 커리큘럼 정보 */ +export interface GetMainRecruitPartCurriculumResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 소개글 정보 */ + introduction: GetMainIntroductionResponseRecordDto; +} + +/** 모집 질문 정보 */ +export interface GetMainRecruitQuestionResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 질문 리스트 */ + questions: GetMainQuestionResponseRecordDto[]; +} + +/** 모집 일정 정보 */ +export interface GetMainRecruitScheduleResponseRecordDto { + /** + * 타입 + * @example "OB" + */ + type: 'OB' | 'YB'; + /** 상세 일정 정보 */ + schedule: GetMainScheduleResponseRecordDto; +} + +/** 상세 일정 정보 */ +export interface GetMainScheduleResponseRecordDto { + /** + * 지원 시작 시간 + * @example "2024-01-01T09:00:00.000Z" + */ + applicationStartTime: string; + /** + * 지원 종료 시간 + * @example "2024-01-31T18:00:00.000Z" + */ + applicationEndTime: string; + /** + * 지원 결과 발표 시간 + * @example "2024-02-01T12:00:00.000Z" + */ + applicationResultTime: string; + /** + * 면접 시작 시간 + * @example "2024-02-05T09:00:00.000Z" + */ + interviewStartTime: string; + /** + * 면접 종료 시간 + * @example "2024-02-05T18:00:00.000Z" + */ + interviewEndTime: string; + /** + * 최종 결과 발표 시간 + * @example "2024-02-10T12:00:00.000Z" + */ + finalResultTime: string; +} + +/** 지원하기 페이지 데이터 조회하기 */ +export interface GetRecruitingPageResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 기수명 + * @example "SOPT" + */ + name: string; + /** + * 지원하기 헤더 이미지 링크 + * @example "https://recruit_header.png" + */ + recruitHeaderImage: string; + /** 브랜딩 컬러 정보 */ + brandingColor?: GetMainBrandingColorResponseRecordDto; + recruitSchedule?: GetMainRecruitScheduleResponseRecordDto[]; + recruitPartCurriculum?: GetMainRecruitPartCurriculumResponseRecordDto[]; + recruitQuestion?: GetMainRecruitQuestionResponseRecordDto[]; +} + +/** 소개 페이지 데이터 조회하기 */ +export interface GetAboutPageResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 기수명 + * @example "SOPT" + */ + name: string; + /** + * 헤더 이미지 링크 + * @example "https://header.png" + */ + headerImage: string; + /** 브랜딩 컬러 정보 */ + brandingColor?: GetMainBrandingColorResponseRecordDto; + coreValue?: GetMainCoreValueResponseRecordDto[]; + partCurriculum?: GetMainPartCurriculumResponseRecordDto[]; + member?: GetMainMemberResponseRecordDto[]; +} + +/** 핵심 가치 정보 */ +export interface GetMainCoreValueResponseRecordDto { + /** + * 핵심 가치 + * @example "용기" + */ + value: string; + /** + * 핵심 가치 설명 + * @example "새로운 도전을 위해 과감히 용기내는 사람" + */ + description: string; + /** + * 핵심 가치 이미지 링크 + * @example "https://corevalue.png" + */ + image: string; +} + +/** 멤버 정보 */ +export interface GetMainMemberResponseRecordDto { + /** + * 역할 + * @example "회장" + */ + role: string; + /** + * 이름 + * @example "홍길동" + */ + name: string; + /** + * 소속 + * @example "SOPT" + */ + affiliation: string; + /** + * 한줄 소개 + * @example "안녕하세요!" + */ + introduction: string; + /** + * 프로필 이미지 링크 + * @example "https://profile.png" + */ + profileImage: string; + /** SNS 링크 정보 */ + sns: GetMainSnsLinksResponseRecordDto; +} + +/** 파트별 커리큘럼 정보 */ +export interface GetMainPartCurriculumResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 주차별 커리큘럼 */ + curriculums: string[]; +} + +/** SNS 링크 정보 */ +export interface GetMainSnsLinksResponseRecordDto { + /** + * 이메일 + * @example "example@sopt.org" + */ + email?: string; + /** + * 링크드인 URL + * @example "https://www.linkedin.com/in/example" + */ + linkedin?: string; + /** + * 깃허브 URL + * @example "https://github.com/example" + */ + github?: string; + /** + * 비핸스 URL + * @example "https://www.behance.net/example" + */ + behance?: string; +} + +/** 브랜딩 컬러 정보 */ +export interface GetAdminBrandingColorResponseRecordDto { + /** + * 메인 컬러 + * @example "#FF0000" + */ + main: string; + /** + * 로우 톤 컬러 + * @example "#CC0000" + */ + low: string; + /** + * 하이 톤 컬러 + * @example "#FF3333" + */ + high: string; + /** + * 포인트 컬러 + * @example "#FF9999" + */ + point: string; +} + +/** 핵심 가치 정보 */ +export interface GetAdminCoreValueResponseRecordDto { + /** + * 핵심 가치 + * @example "용기" + */ + value: string; + /** + * 핵심 가치 설명 + * @example "새로운 도전을 위해 과감히 용기내는 사람" + */ + description: string; + /** + * 핵심 가치 이미지 링크 + * @example "https://corevalue.png" + */ + image: string; +} + +/** 소개글 정보 */ +export interface GetAdminIntroductionResponseRecordDto { + /** + * 내용 + * @example "Android 앱 개발" + */ + content: string; + /** + * 우대사항 + * @example "Kotlin 개발 경험" + */ + preference: string; +} + +/** 최신소식 */ +export interface GetAdminLatestNewsResponseRecordDto { + /** + * 최신소식 ID + * @format int32 + * @example 1 + */ + id: number; + /** + * 최신소식 제목 + * @example "Mind 23" + */ + title: string; +} + +/** 메인 버튼 스타일 */ +export interface GetAdminMainButtonResponseRecordDto { + /** + * 버튼 텍스트 + * @example "지원하기" + */ + text: string; + /** + * 주요 컬러 + * @example "#FF0000" + */ + keyColor: string; + /** + * 보조 컬러 + * @example "#CC0000" + */ + subColor: string; +} + +/** 멤버 정보 */ +export interface GetAdminMemberResponseRecordDto { + /** + * 역할 + * @example "회장" + */ + role: string; + /** + * 이름 + * @example "홍길동" + */ + name: string; + /** + * 소속 + * @example "SOPT" + */ + affiliation: string; + /** + * 한줄 소개 + * @example "안녕하세요!" + */ + introduction: string; + /** + * 프로필 이미지 링크 + * @example "https://profile.png" + */ + profileImage: string; + /** SNS 링크 정보 */ + sns: GetAdminSnsLinksResponseRecordDto; +} + +/** 파트별 커리큘럼 정보 */ +export interface GetAdminPartCurriculumResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 주차별 커리큘럼 */ + curriculums: string[]; +} + +/** 파트 소개 정보 */ +export interface GetAdminPartIntroductionResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** + * 파트 설명 + * @example "Android 앱 개발" + */ + description: string; +} + +/** 질문과 답변 정보 */ +export interface GetAdminQuestionResponseRecordDto { + /** + * 질문 + * @example "몇명 뽑나요?" + */ + question: string; + /** + * 답변 + * @example "10명 뽑아요." + */ + answer: string; +} + +/** 모집 파트 커리큘럼 정보 */ +export interface GetAdminRecruitPartCurriculumResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 소개글 정보 */ + introduction: GetAdminIntroductionResponseRecordDto; +} + +/** 모집 질문 정보 */ +export interface GetAdminRecruitQuestionResponseRecordDto { + /** + * 파트명 + * @example "안드로이드" + */ + part: string; + /** 질문 리스트 */ + questions: GetAdminQuestionResponseRecordDto[]; +} + +/** 모집 일정 정보 */ +export interface GetAdminRecruitScheduleResponseRecordDto { + /** + * 타입 + * @example "OB" + */ + type: 'OB' | 'YB'; + /** 상세 일정 정보 */ + schedule: GetAdminScheduleResponseRecordDto; +} + +/** 어드민 데이터 조회하기 */ +export interface GetAdminResponseDto { + /** + * 기수 + * @format int32 + * @example 34 + */ + generation: number; + /** + * 기수명 + * @example "SOPT" + */ + name: string; + recruitSchedule?: GetAdminRecruitScheduleResponseRecordDto[]; + /** 브랜딩 컬러 정보 */ + brandingColor?: GetAdminBrandingColorResponseRecordDto; + /** 메인 버튼 스타일 */ + mainButton?: GetAdminMainButtonResponseRecordDto; + partIntroduction?: GetAdminPartIntroductionResponseRecordDto[]; + latestNews?: GetAdminLatestNewsResponseRecordDto[]; + /** + * 헤더 이미지 링크 + * @example "https://header.png" + */ + headerImage: string; + coreValue?: GetAdminCoreValueResponseRecordDto[]; + partCurriculum?: GetAdminPartCurriculumResponseRecordDto[]; + member?: GetAdminMemberResponseRecordDto[]; + /** + * 지원하기 헤더 이미지 링크 + * @example "https://recruit_header.png" + */ + recruitHeaderImage: string; + recruitPartCurriculum?: GetAdminRecruitPartCurriculumResponseRecordDto[]; + recruitQuestion?: GetAdminRecruitQuestionResponseRecordDto[]; +} + +/** 상세 일정 정보 */ +export interface GetAdminScheduleResponseRecordDto { + /** + * 지원 시작 시간 + * @example "2024-01-01T09:00:00.000Z" + */ + applicationStartTime: string; + /** + * 지원 종료 시간 + * @example "2024-01-31T18:00:00.000Z" + */ + applicationEndTime: string; + /** + * 지원 결과 발표 시간 + * @example "2024-02-01T12:00:00.000Z" + */ + applicationResultTime: string; + /** + * 면접 시작 시간 + * @example "2024-02-05T09:00:00.000Z" + */ + interviewStartTime: string; + /** + * 면접 종료 시간 + * @example "2024-02-05T18:00:00.000Z" + */ + interviewEndTime: string; + /** + * 최종 결과 발표 시간 + * @example "2024-02-10T12:00:00.000Z" + */ + finalResultTime: string; +} + +/** SNS 링크 정보 */ +export interface GetAdminSnsLinksResponseRecordDto { + /** + * 이메일 + * @example "example@sopt.org" + */ + email?: string; + /** + * 링크드인 URL + * @example "https://www.linkedin.com/in/example" + */ + linkedin?: string; + /** + * 깃허브 URL + * @example "https://github.com/example" + */ + github?: string; + /** + * 비핸스 URL + * @example "https://www.behance.net/example" + */ + behance?: string; +} + +/** 최신소식 조회하기 */ +export interface GetAdminNewsResponseDto { + /** + * 이미지 ID + * @format int32 + * @example 1 + */ + id: number; + /** + * 이미지 링크 + * @example "https://image.url" + */ + image: string; + /** + * 제목 + * @example "MIND 23" + */ + title: string; + /** + * 링크 + * @example "https://disquiet.io/product/mind-23-%EC%98%A4%EB%8A%98%EB%8F%84-%EB%A9%88%EC%B6%94%EC%A7%80-%EC%95%8A%EB%8A%94-it%EC%9D%B8%EB%93%A4" + */ + link: string; +} + +export type RegisterNotificationData = RegisterNotificationResponseDto; + +export type GetMainData = GetAdminResponseDto; + +export type AddMainData = AddAdminResponseDto; + +export type GetMainNewsData = GetAdminNewsResponseDto; + +export type AddMainNewsData = AddAdminNewsResponseDto; + +export type DeleteMainNewsData = DeleteAdminNewsResponseDto; + +export type AddMainConfirmData = AddAdminConfirmResponseDto; + +export type GetSemestersData = SemestersListResponse; + +export type GetAllProjectData = PaginateResponseProjectResponse; + +export type GetAllProject1Data = GetNotificationListResponseDto; + +export type GetMainPageData = GetMainPageResponseDto; + +export type GetData = GetRecruitingPageResponseDto; + +export type GetAboutPageData = GetAboutPageResponseDto; + +export type HealthCheckData = string; diff --git a/src/__generated__/org-types/http-client.ts b/src/__generated__/org-types/http-client.ts new file mode 100644 index 0000000..581b8ff --- /dev/null +++ b/src/__generated__/org-types/http-client.ts @@ -0,0 +1,254 @@ +/* eslint-disable */ +/* tslint:disable */ +/* + * --------------------------------------------------------------- + * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## + * ## ## + * ## AUTHOR: acacode ## + * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## + * --------------------------------------------------------------- + */ + +export type QueryParamsType = Record; +export type ResponseFormat = keyof Omit; + +export interface FullRequestParams extends Omit { + /** set parameter to `true` for call `securityWorker` for this request */ + secure?: boolean; + /** request path */ + path: string; + /** content type of request body */ + type?: ContentType; + /** query params */ + query?: QueryParamsType; + /** format of response (i.e. response.json() -> format: "json") */ + format?: ResponseFormat; + /** request body */ + body?: unknown; + /** base url */ + baseUrl?: string; + /** request cancellation token */ + cancelToken?: CancelToken; +} + +export type RequestParams = Omit< + FullRequestParams, + 'body' | 'method' | 'query' | 'path' +>; + +export interface ApiConfig { + baseUrl?: string; + baseApiParams?: Omit; + securityWorker?: ( + securityData: SecurityDataType | null, + ) => Promise | RequestParams | void; + customFetch?: typeof fetch; +} + +export interface HttpResponse + extends Response { + data: D; + error: E; +} + +type CancelToken = Symbol | string | number; + +export enum ContentType { + Json = 'application/json', + FormData = 'multipart/form-data', + UrlEncoded = 'application/x-www-form-urlencoded', + Text = 'text/plain', +} + +export class HttpClient { + public baseUrl: string = '/v2'; + private securityData: SecurityDataType | null = null; + private securityWorker?: ApiConfig['securityWorker']; + private abortControllers = new Map(); + private customFetch = (...fetchParams: Parameters) => + fetch(...fetchParams); + + private baseApiParams: RequestParams = { + credentials: 'same-origin', + headers: {}, + redirect: 'follow', + referrerPolicy: 'no-referrer', + }; + + constructor(apiConfig: ApiConfig = {}) { + Object.assign(this, apiConfig); + } + + public setSecurityData = (data: SecurityDataType | null) => { + this.securityData = data; + }; + + protected encodeQueryParam(key: string, value: any) { + const encodedKey = encodeURIComponent(key); + return `${encodedKey}=${encodeURIComponent(typeof value === 'number' ? value : `${value}`)}`; + } + + protected addQueryParam(query: QueryParamsType, key: string) { + return this.encodeQueryParam(key, query[key]); + } + + protected addArrayQueryParam(query: QueryParamsType, key: string) { + const value = query[key]; + return value.map((v: any) => this.encodeQueryParam(key, v)).join('&'); + } + + protected toQueryString(rawQuery?: QueryParamsType): string { + const query = rawQuery || {}; + const keys = Object.keys(query).filter( + (key) => 'undefined' !== typeof query[key], + ); + return keys + .map((key) => + Array.isArray(query[key]) + ? this.addArrayQueryParam(query, key) + : this.addQueryParam(query, key), + ) + .join('&'); + } + + protected addQueryParams(rawQuery?: QueryParamsType): string { + const queryString = this.toQueryString(rawQuery); + return queryString ? `?${queryString}` : ''; + } + + private contentFormatters: Record any> = { + [ContentType.Json]: (input: any) => + input !== null && (typeof input === 'object' || typeof input === 'string') + ? JSON.stringify(input) + : input, + [ContentType.Text]: (input: any) => + input !== null && typeof input !== 'string' + ? JSON.stringify(input) + : input, + [ContentType.FormData]: (input: any) => + Object.keys(input || {}).reduce((formData, key) => { + const property = input[key]; + formData.append( + key, + property instanceof Blob + ? property + : typeof property === 'object' && property !== null + ? JSON.stringify(property) + : `${property}`, + ); + return formData; + }, new FormData()), + [ContentType.UrlEncoded]: (input: any) => this.toQueryString(input), + }; + + protected mergeRequestParams( + params1: RequestParams, + params2?: RequestParams, + ): RequestParams { + return { + ...this.baseApiParams, + ...params1, + ...(params2 || {}), + headers: { + ...(this.baseApiParams.headers || {}), + ...(params1.headers || {}), + ...((params2 && params2.headers) || {}), + }, + }; + } + + protected createAbortSignal = ( + cancelToken: CancelToken, + ): AbortSignal | undefined => { + if (this.abortControllers.has(cancelToken)) { + const abortController = this.abortControllers.get(cancelToken); + if (abortController) { + return abortController.signal; + } + return void 0; + } + + const abortController = new AbortController(); + this.abortControllers.set(cancelToken, abortController); + return abortController.signal; + }; + + public abortRequest = (cancelToken: CancelToken) => { + const abortController = this.abortControllers.get(cancelToken); + + if (abortController) { + abortController.abort(); + this.abortControllers.delete(cancelToken); + } + }; + + public request = async ({ + body, + secure, + path, + type, + query, + format, + baseUrl, + cancelToken, + ...params + }: FullRequestParams): Promise> => { + const secureParams = + ((typeof secure === 'boolean' ? secure : this.baseApiParams.secure) && + this.securityWorker && + (await this.securityWorker(this.securityData))) || + {}; + const requestParams = this.mergeRequestParams(params, secureParams); + const queryString = query && this.toQueryString(query); + const payloadFormatter = this.contentFormatters[type || ContentType.Json]; + const responseFormat = format || requestParams.format; + + return this.customFetch( + `${baseUrl || this.baseUrl || ''}${path}${queryString ? `?${queryString}` : ''}`, + { + ...requestParams, + headers: { + ...(requestParams.headers || {}), + ...(type && type !== ContentType.FormData + ? { 'Content-Type': type } + : {}), + }, + signal: + (cancelToken + ? this.createAbortSignal(cancelToken) + : requestParams.signal) || null, + body: + typeof body === 'undefined' || body === null + ? null + : payloadFormatter(body), + }, + ).then(async (response) => { + const r = response.clone() as HttpResponse; + r.data = null as unknown as T; + r.error = null as unknown as E; + + const data = !responseFormat + ? r + : await response[responseFormat]() + .then((data) => { + if (r.ok) { + r.data = data; + } else { + r.error = data; + } + return r; + }) + .catch((e) => { + r.error = e; + return r; + }); + + if (cancelToken) { + this.abortControllers.delete(cancelToken); + } + + if (!response.ok) throw data; + return data; + }); + }; +} From 37bc432ce4d5eba4950d7aa782a63a3a20449eb4 Mon Sep 17 00:00:00 2001 From: Jeon Eonseok Date: Sat, 30 Nov 2024 09:45:49 +0900 Subject: [PATCH 3/5] =?UTF-8?q?fix:=20type=20error=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/org/OrgAdmin/api.ts | 9 +++++---- src/components/org/OrgAdmin/hooks.ts | 22 +++++++++++++++++++--- src/components/org/OrgAdmin/index.tsx | 18 ++++++++++++------ 3 files changed, 36 insertions(+), 13 deletions(-) diff --git a/src/components/org/OrgAdmin/api.ts b/src/components/org/OrgAdmin/api.ts index 3b04cc4..74f295e 100644 --- a/src/components/org/OrgAdmin/api.ts +++ b/src/components/org/OrgAdmin/api.ts @@ -1,6 +1,7 @@ import createFetch from 'openapi-fetch'; import { paths } from '@/__generated__/api'; +import { AddAdminRequestDto } from '@/__generated__/org-types/data-contracts'; import { getToken } from '@/utils/auth'; export const fetcher = createFetch({ @@ -10,15 +11,15 @@ export const fetcher = createFetch({ }, }); -export const sendData = async (data: any) => { +export const sendData = async (data: AddAdminRequestDto) => { const res = await fetcher.POST('/admin', { body: data, }); - return res; + return res.data; }; -export const sendPresignedURL = async (url: string, data: any) => { +export const sendPresignedURL = async (url: string, data: BodyInit) => { const res = await fetch(url, { method: 'POST', body: data, @@ -27,7 +28,7 @@ export const sendPresignedURL = async (url: string, data: any) => { return res; }; -export const sendDataConfirm = async (data: any) => { +export const sendDataConfirm = async (data: { generation: number }) => { const res = await fetcher.POST('/admin/confirm', { body: data, }); diff --git a/src/components/org/OrgAdmin/hooks.ts b/src/components/org/OrgAdmin/hooks.ts index 6789050..ac583f4 100644 --- a/src/components/org/OrgAdmin/hooks.ts +++ b/src/components/org/OrgAdmin/hooks.ts @@ -1,5 +1,10 @@ import { useMutation } from 'react-query'; +import { + AddAdminRequestDto, + AddAdminResponseDto, +} from '@/__generated__/org-types/data-contracts'; + import { sendData, sendDataConfirm, sendPresignedURL } from './api'; interface UseMutateSendDataProps { @@ -42,15 +47,26 @@ const useMutateSendData = ({ recruitHeaderImageFile, }: UseMutateSendDataProps) => { const { mutate: sendMutate, isLoading: sendIsLoading } = useMutation({ - mutationFn: (data) => sendData(data), - onSuccess: async (res: any) => { + mutationFn: ( + data: AddAdminRequestDto, + ): Promise => sendData(data), + onSuccess: async (res) => { const { generation, coreValues, headerImage: headerImageURL, members, recruitHeaderImage: recruitHeaderImageURL, - } = res.data; + } = res || {}; + + if ( + !generation || + !coreValues || + !headerImageURL || + !members || + !recruitHeaderImageURL + ) + return; try { await Promise.all([ diff --git a/src/components/org/OrgAdmin/index.tsx b/src/components/org/OrgAdmin/index.tsx index faf3b55..4e18b72 100644 --- a/src/components/org/OrgAdmin/index.tsx +++ b/src/components/org/OrgAdmin/index.tsx @@ -1,6 +1,12 @@ import { useState } from 'react'; -import { FormProvider, useForm } from 'react-hook-form'; +import { + type FieldValues, + FormProvider, + type SubmitHandler, + useForm, +} from 'react-hook-form'; +import type { AddAdminRequestDto } from '@/__generated__/org-types/data-contracts'; import { StListHeader } from '@/components/attendanceAdmin/session/SessionList/style'; import FilterButton from '@/components/common/FilterButton'; import { @@ -18,7 +24,7 @@ import HomeSection from './home/HomeSection'; import useMutateSendData from './hooks'; import RecruitSection from './RecruitSection'; import { StSubmitButton, StSubmitText } from './style'; -import { Group } from './types'; +import type { Group } from './types'; function OrgAdmin() { const [selectedPart, setSelectedPart] = useState('공통'); @@ -26,7 +32,7 @@ function OrgAdmin() { const [curriculumPart, setCurriculumPart] = useState('기획'); const [fnaPart, setFnaPart] = useState('기획'); - const methods = useForm>({ mode: 'onBlur' }); + const methods = useForm({ mode: 'onBlur' }); const { handleSubmit, getValues } = methods; const { sendMutate, sendIsLoading } = useMutateSendData({ @@ -115,7 +121,7 @@ function OrgAdmin() { return true; }; - const onSubmit = (data: any) => { + const onSubmit: SubmitHandler = (data) => { const isScheduleValid = validateSchedule(); const isCurriculumValid = validateCurriculum(); const isFnaValid = validateFna(); @@ -198,7 +204,7 @@ function OrgAdmin() { } = data; const 임원진 = [...임원진_LIST, ...PART_LIST]; - const sendingData = { + const sendingData: AddAdminRequestDto = { generation, name, recruitSchedule: [ @@ -441,7 +447,7 @@ function OrgAdmin() { }; console.log('>>sendingData', sendingData); - sendMutate(sendingData as any); + sendMutate(sendingData); } }; From 921e9ce2acd8b36c397c730ebeb017e955acfbd2 Mon Sep 17 00:00:00 2001 From: Jeon Eonseok Date: Sat, 30 Nov 2024 10:07:20 +0900 Subject: [PATCH 4/5] =?UTF-8?q?chore:=20console=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/org/OrgAdmin/index.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/org/OrgAdmin/index.tsx b/src/components/org/OrgAdmin/index.tsx index 4e18b72..6666a7d 100644 --- a/src/components/org/OrgAdmin/index.tsx +++ b/src/components/org/OrgAdmin/index.tsx @@ -446,7 +446,6 @@ function OrgAdmin() { ], }; - console.log('>>sendingData', sendingData); sendMutate(sendingData); } }; From 7257a4742e75888524f6a77e4192473ade13d817 Mon Sep 17 00:00:00 2001 From: Jeon Eonseok Date: Sat, 30 Nov 2024 11:16:35 +0900 Subject: [PATCH 5/5] =?UTF-8?q?feat:=20presigned=20url=20=EB=B3=B4?= =?UTF-8?q?=EB=82=B4=EA=B8=B0=20=EC=9C=84=ED=95=9C=20=EB=8D=B0=EC=9D=B4?= =?UTF-8?q?=ED=84=B0=20=EC=97=86=EC=9D=84=20=EC=8B=9C=20=EC=97=90=EB=9F=AC?= =?UTF-8?q?=20=EC=B2=98=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/org/OrgAdmin/hooks.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/org/OrgAdmin/hooks.ts b/src/components/org/OrgAdmin/hooks.ts index ac583f4..ff7bfc1 100644 --- a/src/components/org/OrgAdmin/hooks.ts +++ b/src/components/org/OrgAdmin/hooks.ts @@ -66,7 +66,7 @@ const useMutateSendData = ({ !members || !recruitHeaderImageURL ) - return; + throw new Error('presigned url put 준비 과정에 에러가 발생함.'); try { await Promise.all([