---
title: Refresh Access Token
slug: monitor/refresh-access-token
docTags: 
createdAt: 2025-04-09T08:34:44.988Z
---

:::ApiMethodV2
```json
{
  "name": "refresh",
  "method": "GET",
  "url": "https://api-sandbox.klavi.ai/monitor/v1/refresh",
  "description": "Refresh the access token",
  "tab": "examples",
  "examples": {
    "languages": [
      {
        "id": "_RnnDmqHKhhk1Hx-F0KGx",
        "language": "curl",
        "code": "curl --location 'https://api-sandbox.klavi.ai/monitor/v1/refresh' \\\n--header 'Authorization: string'",
        "customLabel": ""
      },
      {
        "id": "krF222oCgTTImjBvwAyQP",
        "language": "nodejs",
        "code": "var request = require('request');\nvar options = {\n   'method': 'GET',\n   'url': 'https://api-sandbox.klavi.ai/monitor/v1/refresh',\n   'headers': {\n      'Authorization': 'string'\n   }\n};\nrequest(options, function (error, response) {\n   if (error) throw new Error(error);\n   console.log(response.body);\n});\n",
        "customLabel": ""
      },
      {
        "id": "XT9GzU1RPMf6sR7iSciZP",
        "language": "javascript",
        "code": "var myHeaders = new Headers();\nmyHeaders.append(\"Authorization\", \"string\");\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"https://api-sandbox.klavi.ai/monitor/v1/refresh\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));",
        "customLabel": ""
      },
      {
        "id": "pAgev-uCrB9mZkuSovPGS",
        "language": "python",
        "code": "import requests\n\nurl = \"https://api-sandbox.klavi.ai/monitor/v1/refresh\"\n\npayload = {}\nheaders = {\n   'Authorization': 'string'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n",
        "customLabel": ""
      },
      {
        "id": "S6m2S4k-67lobLYStqzkM",
        "language": "ruby",
        "code": "require \"uri\"\nrequire \"net/http\"\n\nurl = URI(\"https://api-sandbox.klavi.ai/monitor/v1/refresh\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"Authorization\"] = \"string\"\n\nresponse = https.request(request)\nputs response.read_body\n",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "_RnnDmqHKhhk1Hx-F0KGx"
  },
  "results": {
    "languages": [
      {
        "id": "nv95bdK0hffIAqlEKszNN",
        "language": "200",
        "customLabel": "",
        "code": "{\n      \"accessToken\": \"JhbGciOiJFUzI1NiIs.QtYjAyOC1hN2ZhMWFjZGRjZjkiLCJ0.nlTqpAZHeq4P2xFD\",\n      \"expireIn\": 1800\n}"
      }
    ],
    "selectedLanguageId": "nv95bdK0hffIAqlEKszNN"
  },
  "request": {
    "pathParameters": [],
    "queryParameters": [],
    "headerParameters": [
      {
        "name": "Authorization",
        "kind": "required",
        "type": "string",
        "description": "Bearer access token, it returned by the /auth",
        "": "Bearer access token, it returned by the /auth"
      }
    ],
    "bodyDataParameters": [],
    "formDataParameters": []
  },
  "currentNewParameter": {
    "label": "Header Parameter",
    "value": "headerParameters"
  },
  "hasTryItOut": false,
  "response": [
    {
      "name": "accessToken",
      "kind": "optional",
      "type": "string",
      "description": "JWT token"
    },
    {
      "name": "expireIn",
      "kind": "optional",
      "type": "string",
      "description": "Token validity duration, default 1800 seconds",
      "children": []
    }
  ]
}
```
:::

