菜单

清除本地缓存

清除指定店铺在本机外壳中的本地缓存,可选同步清除 Cookie。

基本信息

Path: /clearEnvCache

Method: POST

请求参数

参数类型必填说明
storeId / idnumber/string店铺 ID。
clearCookieboolean是否在清除本地缓存后同时清除 Cookie,默认 false
cookieOptionsobject清除 Cookie 的附加参数,会透传给 clearStoreCookie

补充说明

该能力依赖外壳提供 managerClearStoreCache,不支持时返回 managerClearStoreCache is not supported

clearCookie=true 时,cookieOptions 会覆盖默认 Cookie 参数。

请求示例

{
  "method": "clearEnvCache",
  "storeId": 10001,
  "clearCookie": true,
  "cookieOptions": {
    "urls": [],
    "cookieContext": "",
    "type": "extension"
  }
}

成功返回示例

{
  "method": "clearEnvCache",
  "response": {
    "code": 200,
    "msg": "success",
    "clearCookie": true,
    "data": {
      "code": 200,
      "message": "success"
    }
  }
}

返回字段

字段类型说明
response.codenumber200 表示清除成功。
response.clearCookieboolean是否执行了 Cookie 清除。
response.dataany外壳返回的原始结果。

失败返回示例

{
  "method": "clearEnvCache",
  "status": "error",
  "code": "400",
  "msg": "managerClearStoreCache is not supported"
}
上一个
编辑店铺信息
下一个
清除 Cookie
最近修改: 2026-06-03Powered by