PortOne Token API

The Token API from PortOne — 1 operation(s) for token.

OpenAPI Specification

portone-token-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: PortOne B2b Token API
  version: 1.16.0
servers:
- url: https://api.portone.io
  description: 운영환경 서버
tags:
- name: Token
paths:
  /token/refresh:
    post:
      summary: 토큰 갱신
      description: '토큰 갱신


        리프레시 토큰을 사용해 유효기간이 연장된 새로운 토큰을 재발급합니다.'
      operationId: refreshToken
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RefreshTokenBody'
            example:
              refreshToken: previous-refresh-token
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RefreshTokenResponse'
              example:
                accessToken: new-access-token
                refreshToken: new-refresh-token
        '400':
          description: '* `InvalidRequestError`: 요청된 입력 정보가 유효하지 않은 경우'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RefreshTokenError'
        '401':
          description: '* `UnauthorizedError`: 인증 정보가 올바르지 않은 경우'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RefreshTokenError'
      x-portone-category: auth
      x-portone-title: 토큰 갱신
      x-portone-description: 리프레시 토큰을 사용해 유효기간이 연장된 새로운 토큰을 재발급합니다.
      x-portone-error:
        $ref: '#/components/schemas/RefreshTokenError'
      tags:
      - Token
components:
  schemas:
    InvalidRequestError:
      title: 요청된 입력 정보가 유효하지 않은 경우
      description: '요청된 입력 정보가 유효하지 않은 경우


        허가되지 않은 값, 올바르지 않은 형식의 요청 등이 모두 해당됩니다.'
      type: object
      required:
      - type
      properties:
        type:
          type: string
        message:
          type: string
      x-portone-title: 요청된 입력 정보가 유효하지 않은 경우
      x-portone-description: 허가되지 않은 값, 올바르지 않은 형식의 요청 등이 모두 해당됩니다.
      x-portone-status-code: 400
    RefreshTokenError:
      title: RefreshTokenError
      oneOf:
      - $ref: '#/components/schemas/InvalidRequestError'
      - $ref: '#/components/schemas/UnauthorizedError'
      discriminator:
        propertyName: type
        mapping:
          INVALID_REQUEST: '#/components/schemas/InvalidRequestError'
          UNAUTHORIZED: '#/components/schemas/UnauthorizedError'
    UnauthorizedError:
      title: 인증 정보가 올바르지 않은 경우
      description: 인증 정보가 올바르지 않은 경우
      type: object
      required:
      - type
      properties:
        type:
          type: string
        message:
          type: string
      x-portone-title: 인증 정보가 올바르지 않은 경우
      x-portone-status-code: 401
    RefreshTokenResponse:
      title: 토큰 재발급 성공 응답
      description: 토큰 재발급 성공 응답
      type: object
      required:
      - accessToken
      - refreshToken
      properties:
        accessToken:
          type: string
          title: 인증에 사용하는 엑세스 토큰
          description: 30분의 유효기간을 가지고 있습니다.
        refreshToken:
          type: string
          title: 토큰 재발급 및 유효기간 연장을 위해 사용하는 리프레시 토큰
          description: '하루의 유효기간을 가지고 있으며, 리프레시 토큰을 통해 유효기간이 연장된 새로운 엑세스 토큰을 발급받을 수 있습니다.

            동일한 유저가 로그인 또는 토큰 재발급을 진행할 때마다 기존에 발급된 리프레시 토큰은 즉시 만료되므로 API 사용에 유의해주세요.'
      x-portone-title: 토큰 재발급 성공 응답
    RefreshTokenBody:
      title: 토큰 재발급을 위한 입력 정보
      description: 토큰 재발급을 위한 입력 정보
      type: object
      required:
      - refreshToken
      properties:
        refreshToken:
          type: string
          title: 리프레시 토큰
      x-portone-title: 토큰 재발급을 위한 입력 정보
  securitySchemes:
    bearerJwt:
      type: http
      description: 'Authorization: Bearer `엑세스 토큰`'
      scheme: bearer
    portOne:
      type: http
      description: 'Authorization: PortOne `발급된 API 시크릿`'
      scheme: portone
x-portone-categories:
- id: payment
  title: 결제 관련 API
  description: 결제와 관련된 API 기능을 제공합니다.
  children:
  - id: payment.paymentSchedule
    title: 결제 예약 관련 API
    description: 결제 예약과 관련된 API 기능을 제공합니다.
  - id: payment.billingKey
    title: 빌링키 관련 API
    description: 빌링키와 관련된 API 기능을 제공합니다.
  - id: payment.cashReceipt
    title: 현금 영수증 관련 API
    description: 현금 영수증과 관련된 API 기능을 제공합니다.
  - id: payment.promotion
    title: 프로모션 관련 API
    description: 프로모션과 관련된 API 기능을 제공합니다.
  - id: payment.additionalFeature
    title: 결제 부가기능 관련 API
    description: 결제 부가기능과 관련된 API 기능을 제공합니다.
- id: identityVerification
  title: 본인인증 관련 API
  description: 본인인증과 관련된 API 기능을 제공합니다.
- id: pgSpecific
  title: 특정 PG사 관련 API
  description: 특정 PG사에 국한된 API 기능을 제공합니다.
- id: reconciliation
  title: 대사 서비스 API
  description: 거래 대사 및 정산 대사 관련 API 기능을 제공합니다.
- id: b2b
  title: 세금계산서 API
  description: 세금계산서 API 기능을 제공합니다.
  children:
  - id: b2b.counterparty
    title: 거래처 관련 API
    description: 거래처 관련 API 기능을 제공합니다.
  - id: b2b.taxInvoice
    title: 세금계산서 발행 관련 API
    description: 세금계산서 발행 관련 API 기능을 제공합니다.
- id: platform
  title: 파트너 정산 관련 API
  description: 파트너 정산 서비스 API 기능을 제공합니다.
  children:
  - id: platform.policy
    title: 정책 관련 API
    description: 파트너 정산에 적용할 정책에 관한 API 입니다.
  - id: platform.partner
    title: 파트너 관련 API
    description: 파트너 정산에 적용할 파트너에 관한 API 입니다.
  - id: platform.transfer
    title: 정산 상세내역 관련 API
    description: 파트너 정산 서비스의 정산 상세내역과 관련된 API 입니다.
  - id: platform.account
    title: 계좌 관련 API
    description: 파트너 정산 서비스의 계좌와 관련된 API 입니다.
  - id: platform.partnerSettlement
    title: 정산 내역 관련 API
    description: 파트너 정산 서비스의 정산 내역과 관련된 API 입니다.
  - id: platform.payout
    title: 지급 내역 관련 API
    description: 파트너 정산 서비스의 지급 내역과 관련된 API 입니다.
  - id: platform.bulkPayout
    title: 일괄 지급 내역 관련 API
    description: 파트너 정산 서비스의 일괄 지급 내역과 관련된 API 입니다.
  - id: platform.accountTransfer
    title: 이체 내역 관련 API
    description: 파트너 정산 서비스의 이체 내역과 관련된 API 입니다.
  - id: platform.bulkAccountTransfer
    title: 일괄 이체 내역 관련 API
    description: 파트너 정산 서비스의 일괄 이체 내역과 관련된 API 입니다.
  - id: platform.company
    title: 사업자 관련 API
    description: 파트너 정산 서비스의 사업자와 관련된 API 입니다.
- id: auth
  title: 인증 관련 API
  description: '인증과 관련된 API 기능을 제공합니다.

    접근 토큰 방식으로 인증하기를 원하는 경우, API 시크릿을 통해 토큰을 발급받은 후 Authorization 헤더에 `Bearer ACCESS_TOKEN` 형식으로 전달합니다.'
- id: paymentSession
  title: 결제 세션 API
  description: 결제 세션 생성 및 관리 API. 호스티드 체크아웃에 사용됩니다.
- id: checkoutProfile
  title: 체크아웃 프로필 API
  description: 체크아웃 프로필에서 결제 수단 목록을 조회하기 위한 API.
- id: ap
  title: AP API
  description: AP 기능을 제공합니다.
- id: common
  title: 공통 API
  description: 공통 API 기능을 제공합니다.