← Back to Storage domain

Storage.getStorageKey

Returns storage key for the given frame. If no frame ID is provided, the storage key of the target executing this command is returned.

Domain: Storage experimental

Parameters

NameTypeDescription
frameId (optional)Page.FrameId

Returns

NameTypeDescription
storageKeySerializedStorageKey

Example Request

{
  "id": 1,
  "method": "Storage.getStorageKey"
}

Example Response

{
  "id": 1,
  "result": {
    "storageKey": "storageKey-value"
  }
}

Usage in Node.js

const result = await send('Storage.getStorageKey');
console.log(result);
// {"storageKey": "storageKey-value"}