> ## Documentation Index
> Fetch the complete documentation index at: https://www.octoparse.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# リフレッシュトークン

> 取得済みのrefresh_tokenを使用してアクセストークンを更新します。

**必要プラン:** 全ユーザー。

<Info>
  リクエスト例、cURL、パラメータ、レスポンススキーマは、下部のAPIパネルに自動生成されます。このページでは、このエンドポイントの用途と使いどころを簡潔に説明します。
</Info>

既存の`refresh_token`を使用して、新しいアクセストークンを取得します。`access_token`の有効期限が切れた場合は、このエンドポイントで更新してください。

更新後は、新しく発行された`access_token`を後続のAPI呼び出しで使用します。


## OpenAPI

````yaml jp/api/refresh-token.openapi.json POST /token
openapi: 3.0.1
info:
  title: Octoparse Refresh Token API
  version: 1.0.0
servers:
  - url: https://openapi.octoparse.com
    description: Octoparse APIサーバー
security: []
paths:
  /token:
    post:
      tags:
        - アクセストークン
      summary: リフレッシュトークン
      description: |-
        **必要プラン:** 全ユーザー。

        アクセストークンの有効期限が切れた場合は、初回のトークンリクエストで取得した`refresh_token`を使用して更新できます。
      operationId: refreshToken
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - refresh_token
                - grant_type
              properties:
                refresh_token:
                  type: string
                  description: 最初のトークンレスポンスで取得したリフレッシュトークン
                grant_type:
                  type: string
                  description: '`refresh_token`を指定してください。'
                  example: refresh_token
      responses:
        '200':
          description: トークンの更新に成功しました
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      access_token:
                        type: string
                      expires_in:
                        type: integer
                      token_type:
                        type: string
                      refresh_token:
                        type: string
                  requestId:
                    type: string

````