WinCL Auth API

Auth Controller

OpenAPI Specification

wincl-auth-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Wincl Admin Auth API
  version: '1.0'
  description: Admin Controller
servers:
- url: https://api.wincl.io:443
  description: Inferred Url
tags:
- name: Auth
  description: Auth Controller
paths:
  /api/v1/auth/check/email:
    post:
      tags:
      - Auth
      summary: 이메일 중복확인
      operationId: checkEmailUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CheckEmailRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«CheckEmailResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
        '940':
          description: INVALID_SOCIAL_EMAIL
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/check/loginid:
    post:
      tags:
      - Auth
      summary: 로그인 아이디 중복확인
      operationId: checkLoginIdUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CheckLoginIdRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«CheckLoginIdResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
        '919':
          description: INVALID_LOGIN_ID
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/check/nickname:
    post:
      tags:
      - Auth
      summary: 닉네임 중복확인
      operationId: checkNicknameUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CheckNicknameRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«CheckNicknameResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
        '920':
          description: INVALID_NICKNAME
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/jwt/create:
    post:
      tags:
      - Auth
      summary: 토큰 발급
      operationId: createJWTUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateJwtRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«CreateJwtResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/payco/accessToken:
    get:
      tags:
      - Auth
      summary: 페이코 AccessToken 발급
      operationId: createPaycoAccessTokenUsingGET
      parameters:
      - name: authCode
        in: query
        description: AuthCode
        required: false
        style: form
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                $ref: '#/components/schemas/WinclResponseData«PaycoAccessTokenResponse»'
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/signin:
    post:
      tags:
      - Auth
      summary: OAuth 로그인
      description: 유저가 존재하면 jwt 내려주고 존재하지않으면 임시회원가입시키고 id_temp_usr 를 내려줌
      operationId: oAuthSignInUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OAuthSignInRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«OAuthSignInResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
      security:
      - Bearer 토큰 값:
        - global
  /api/v1/auth/signup:
    post:
      tags:
      - Auth
      summary: 회원가입
      operationId: oAuthSignUpUsingPOST
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OAuthSignUpRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WinclResponseData«OAuthSignUpResponse»'
        '201':
          description: Created
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not Found
        '914':
          description: ALREADY_SIGNED_UP_USER
        '919':
          description: INVALID_LOGIN_ID
        '920':
          description: INVALID_NICKNAME
      security:
      - Bearer 토큰 값:
        - global
components:
  schemas:
    WinclResponseData«OAuthSignUpResponse»:
      title: WinclResponseData«OAuthSignUpResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/OAuthSignUpResponse'
        message:
          type: string
    WinclResponseData«OAuthSignInResponse»:
      title: WinclResponseData«OAuthSignInResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/OAuthSignInResponse'
        message:
          type: string
    CheckLoginIdResponse:
      title: CheckLoginIdResponse
      type: object
      properties:
        conflict:
          type: boolean
    CheckNicknameRequest:
      title: CheckNicknameRequest
      type: object
      properties:
        nickname:
          type: string
    CheckLoginIdRequest:
      title: CheckLoginIdRequest
      type: object
      properties:
        id_login:
          type: string
    CheckNicknameResponse:
      title: CheckNicknameResponse
      type: object
      properties:
        conflict:
          type: boolean
    OAuthSignUpRequest:
      title: OAuthSignUpRequest
      type: object
      properties:
        cd_country:
          type: string
          description: 거주국가 코드
        company_code:
          type: string
          description: '회사코드(예: BLC)'
        email:
          type: string
          description: 유저 이메일 (중복 불허)
        id_login:
          type: string
          description: 유저 아이디 (Deprecated)
        id_temp_usr:
          type: string
          description: 임시 유저 아이디
        nickname:
          type: string
          description: 유저 닉네임 (중복 불허)
        verifiedPhoneNumber:
          type: string
          description: '인증된 전화번호 (E.164 포맷. 예: +821012345678)'
    OAuthSignInResponse:
      title: OAuthSignInResponse
      type: object
      properties:
        access_token:
          type: string
          description: Access Token
        email_social:
          type: string
          description: 소셜로그인 에서 받아온 이메일
        id_temp_usr:
          type: string
          description: 임시 유저 아이디
        isEmailAlreadyRegistered:
          type: boolean
          description: 동일한 이메일로 이미 가입된 계정이 있는가
          example: false
        nickname:
          type: string
          description: 유저 닉네임
        refresh_token:
          type: string
          description: Refresh Token
        registeredSocialMediaType:
          type: string
          description: 동일한 이메일로 이미 가입된 소셜 미디어 종류
          enum:
          - FACEBOOK
          - GOOGLE
          - KAKAO
          - PAYCO
        token_type:
          type: string
          description: jwt 토큰 타입
        wincl_user:
          type: boolean
          description: ' wincl 가입자 유무, false 일때 회원가입 프로세스'
          example: false
    PaycoAccessTokenResponse:
      title: PaycoAccessTokenResponse
      type: object
      properties:
        access_token:
          type: string
        access_token_secret:
          type: string
        expires_in:
          type: string
        refresh_token:
          type: string
        state:
          type: string
        token_type:
          type: string
    WinclResponseData«CheckEmailResponse»:
      title: WinclResponseData«CheckEmailResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/CheckEmailResponse'
        message:
          type: string
    OAuthSignInRequest:
      title: OAuthSignInRequest
      type: object
      properties:
        auth_token:
          type: string
          description: 소셜로그인에서 준 토큰
        cd_corp:
          type: string
          description: 소셜로그인 회사 코드
          enum:
          - FACEBOOK
          - GOOGLE
          - KAKAO
          - PAYCO
    WinclResponseData«PaycoAccessTokenResponse»:
      title: WinclResponseData«PaycoAccessTokenResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/PaycoAccessTokenResponse'
        message:
          type: string
    CreateJwtRequest:
      title: CreateJwtRequest
      type: object
      properties:
        email:
          type: string
        id_corp:
          type: string
          enum:
          - FACEBOOK
          - GOOGLE
          - KAKAO
          - PAYCO
        phoneNumber:
          type: string
    WinclResponseData«CheckNicknameResponse»:
      title: WinclResponseData«CheckNicknameResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/CheckNicknameResponse'
        message:
          type: string
    WinclResponseData«CheckLoginIdResponse»:
      title: WinclResponseData«CheckLoginIdResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/CheckLoginIdResponse'
        message:
          type: string
    CheckEmailResponse:
      title: CheckEmailResponse
      type: object
      properties:
        conflict:
          type: boolean
    CheckEmailRequest:
      title: CheckEmailRequest
      type: object
      properties:
        email:
          type: string
    CreateJwtResponse:
      title: CreateJwtResponse
      type: object
      properties:
        accessToken:
          type: string
        refreshToken:
          type: string
    OAuthSignUpResponse:
      title: OAuthSignUpResponse
      type: object
      properties:
        access_token:
          type: string
        refresh_token:
          type: string
        token_type:
          type: string
          description: jwt 토큰 타입
    WinclResponseData«CreateJwtResponse»:
      title: WinclResponseData«CreateJwtResponse»
      type: object
      properties:
        code:
          type: string
        data:
          $ref: '#/components/schemas/CreateJwtResponse'
        message:
          type: string
  securitySchemes:
    Bearer 토큰 값:
      type: http
      scheme: bearer
      bearerFormat: JWT