---
sidebar_position: 3
description: Refresh token and other functions to work with Dropbox in the Open Integration Package, a free open-source integration library for 1C:Enterprise 8, OneScript and CLI
keywords: [1C, 1С, 1С:Enterprise, 1С:Enterprise 8.3, API, Integration, Services, Exchange, OneScript, CLI, Dropbox]
---

import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

# Refresh token
 Gets a new token based on the refresh token



`Function RefreshToken(Val AppKey, Val AppSecret, Val RefreshToken) Export`

  | Parameter | CLI option | Type | Required | Description |
  |-|-|-|-|-|
  | AppKey | --appkey | String | &#x2714; | Application key |
  | AppSecret | --appsecret | String | &#x2714; | Application secret |
  | RefreshToken | --refresh | String | &#x2714; | Refresh token |

  
  Returns:  Map Of KeyAndValue - serialized JSON response from Dropbox



```bsl title="1C:Enterprise/OneScript code example"
    AppKey       = "oynqxds...";
    AppSecret    = "tk2oewn...";
    RefreshToken = "oZFWg3DmZ_IAAAAAAAAAAWilOA0M1SjV...";

    Result = OPI_Dropbox.RefreshToken(AppKey, AppSecret, RefreshToken);
```
 

 <Tabs>
  
    <TabItem value="bash" label="Bash" default>
        ```bash
            oint dropbox RefreshToken \
             --appkey "***" \
             --appsecret "***" \
             --refresh "***"
        ```
    </TabItem>
  
    <TabItem value="bat" label="CMD/Bat" default>
        ```batch
            oint dropbox RefreshToken ^
             --appkey "***" ^
             --appsecret "***" ^
             --refresh "***"
        ```
    </TabItem>
</Tabs>


```json title="Result"
{
  "access_token": "sl.B2M8yVLTS_ojO3UsFs2tRlXxkFh50RLOkroi3SLCwcjA2xX58JY__GXKh9vPGnGcfDkkTJJYB1Wn9tFvj6cRs3w04TnfaBQnJiOfUb58UHexTCAdck9xNFIBAQjuAQKUtkoht66bvsu4oh6Wl6gQpvU",
  "token_type": "bearer",
  "expires_in": 14400
  }
```
