Update API key

Update API key

This endpoint updates an API key

import requests
 
response = requests.patch(
    "https://proxy.webshare.io/api/v2/apikey/<ID>/",
    json={
        "label":"new label"
    },
    headers={"Authorization": "Token APIKEY"}
)
response.json()
curl "https://proxy.webshare.io/api/v2/apikey/<ID>/" \
  -X PATCH \
  -d "{\"label\": \"new label\"}" \
  -H "Content-Type: application/json" \
  -H "Authorization: Token APIKEY"

The above command returns JSON structured like this:

{
  "id": 1337,
  "key": "abc1234...zzz",
  "label": "new label",
  "created_at": "2022-06-14T11:58:10.246406-07:00",
  "updated_at": "2022-06-14T11:58:10.246406-07:00"
}

HTTP request

PATCH https://proxy.webshare.io/api/v2/apikey/<ID>/