{"url_pattern":"^https?://m\\.okjike\\.com(/.*)?$","site_name":"jike","allowed_domains":["m.okjike.com","web.okjike.com"],"tools":[{"name":"jike_post","description":"即刻帖子详情及评论","inputSchema":{"type":"object","properties":{"id":{"type":"string","description":"Post ID (from post URL)"}},"required":["id"]},"handler":"(params) => {\n  const args = Object.assign({}, params || {});\n  let data = null;\n  let __wbContextUrl = globalThis.location?.href || '';\n  let __wbContextDocument = globalThis.document || null;\n    const __wbDefault = (value, fallback) => (value === undefined || value === null || value === '' ? fallback : value);\n    const __wbJoin = (value, separator) => Array.isArray(value) ? value.join(separator) : (value ?? '');\n    const __wbGet = (value, path) => {\n      if (!path) return value;\n      return String(path).split('.').reduce((acc, part) => (acc == null ? undefined : acc[part]), value);\n    };\n    const __wbBaseUrl = () => (__wbContextUrl || globalThis.location?.href || '');\n    const __wbResolve = (target, base) => {\n      if (target == null) return '';\n      const text = String(target);\n      try {\n        if (/^https?:/i.test(text)) return text;\n        const resolvedBase = base || __wbBaseUrl();\n        return resolvedBase ? new URL(text, resolvedBase).toString() : text;\n      } catch (_error) {\n        return text;\n      }\n    };\n    const __wbFetch = async (target, options) => {\n      const url = __wbResolve(target, __wbBaseUrl());\n      const resp = await globalThis.fetch(url, Object.assign({ credentials: 'include' }, options || {}));\n      if (!resp.ok) {\n        throw new Error(`HTTP ${resp.status} for ${url}`);\n      }\n      const text = await resp.text();\n      try {\n        return { url, text, data: JSON.parse(text) };\n      } catch (_error) {\n        return { url, text, data: text };\n      }\n    };\n  return (async () => {\n    {\n      const __wbResp = await __wbFetch(`https://m.okjike.com/originalPosts/${args.id}`);\n      __wbContextUrl = __wbResp.url;\n      __wbContextDocument = new DOMParser().parseFromString(__wbResp.text, 'text/html');\n      data = __wbContextDocument;\n    }\n    {\n      const document = __wbContextDocument || globalThis.document;\n      const location = new URL(__wbBaseUrl());\n      const window = { document, location };\n      const fetch = (target, options) => globalThis.fetch(__wbResolve(target, __wbBaseUrl()), Object.assign({ credentials: 'include' }, options || {}));\n      data = await (((() => {\n  try {\n    const el = document.querySelector('script[type=\"application/json\"]');\n    if (!el) return [];\n    const data = JSON.parse(el.textContent);\n    const pageProps = data?.props?.pageProps || {};\n    const post = pageProps.post || {};\n    const comments = pageProps.comments || [];\n\n    const result = [{\n      type: 'post',\n      author: post.user?.screenName || '',\n      content: post.content || '',\n      likes: post.likeCount || 0,\n      time: post.createdAt || '',\n    }];\n\n    for (const c of comments) {\n      result.push({\n        type: 'comment',\n        author: c.user?.screenName || '',\n        content: (c.content || '').replace(/\\n/g, ' '),\n        likes: c.likeCount || 0,\n        time: c.createdAt || '',\n      });\n    }\n\n    return result;\n  } catch (e) {\n    return [];\n  }\n})())());\n    }\n    {\n      const source = Array.isArray(data) ? data : (data == null ? [] : [data]);\n      data = source.map((item, index) => ({\n        \"type\": item.type,\n        \"author\": item.author,\n        \"content\": item.content,\n        \"likes\": item.likes,\n        \"time\": item.time,\n      }));\n    }\n    return data;\n  })();\n}"},{"name":"jike_topic","description":"即刻话题/圈子帖子","inputSchema":{"type":"object","properties":{"id":{"type":"string","description":"Topic ID (from topic URL, e.g. 553870e8e4b0cafb0a1bef68)"},"limit":{"type":"number","description":"Number of posts","default":20}},"required":["id"]},"handler":"(params) => {\n  const args = Object.assign({\"limit\": 20}, params || {});\n  let data = null;\n  let __wbContextUrl = globalThis.location?.href || '';\n  let __wbContextDocument = globalThis.document || null;\n    const __wbDefault = (value, fallback) => (value === undefined || value === null || value === '' ? fallback : value);\n    const __wbJoin = (value, separator) => Array.isArray(value) ? value.join(separator) : (value ?? '');\n    const __wbGet = (value, path) => {\n      if (!path) return value;\n      return String(path).split('.').reduce((acc, part) => (acc == null ? undefined : acc[part]), value);\n    };\n    const __wbBaseUrl = () => (__wbContextUrl || globalThis.location?.href || '');\n    const __wbResolve = (target, base) => {\n      if (target == null) return '';\n      const text = String(target);\n      try {\n        if (/^https?:/i.test(text)) return text;\n        const resolvedBase = base || __wbBaseUrl();\n        return resolvedBase ? new URL(text, resolvedBase).toString() : text;\n      } catch (_error) {\n        return text;\n      }\n    };\n    const __wbFetch = async (target, options) => {\n      const url = __wbResolve(target, __wbBaseUrl());\n      const resp = await globalThis.fetch(url, Object.assign({ credentials: 'include' }, options || {}));\n      if (!resp.ok) {\n        throw new Error(`HTTP ${resp.status} for ${url}`);\n      }\n      const text = await resp.text();\n      try {\n        return { url, text, data: JSON.parse(text) };\n      } catch (_error) {\n        return { url, text, data: text };\n      }\n    };\n  return (async () => {\n    {\n      const __wbResp = await __wbFetch(`https://m.okjike.com/topics/${args.id}`);\n      __wbContextUrl = __wbResp.url;\n      __wbContextDocument = new DOMParser().parseFromString(__wbResp.text, 'text/html');\n      data = __wbContextDocument;\n    }\n    {\n      const document = __wbContextDocument || globalThis.document;\n      const location = new URL(__wbBaseUrl());\n      const window = { document, location };\n      const fetch = (target, options) => globalThis.fetch(__wbResolve(target, __wbBaseUrl()), Object.assign({ credentials: 'include' }, options || {}));\n      data = await (((() => {\n  try {\n    const el = document.querySelector('script[type=\"application/json\"]');\n    if (!el) return [];\n    const data = JSON.parse(el.textContent);\n    const pageProps = data?.props?.pageProps || {};\n    const posts = pageProps.posts || [];\n    return posts.map(p => ({\n      content: (p.content || '').replace(/\\n/g, ' ').slice(0, 80),\n      author: p.user?.screenName || '',\n      likes: p.likeCount || 0,\n      comments: p.commentCount || 0,\n      time: p.actionTime || p.createdAt || '',\n      id: p.id || '',\n    }));\n  } catch (e) {\n    return [];\n  }\n})())());\n    }\n    {\n      const source = Array.isArray(data) ? data : (data == null ? [] : [data]);\n      data = source.map((item, index) => ({\n        \"content\": item.content,\n        \"author\": item.author,\n        \"likes\": item.likes,\n        \"comments\": item.comments,\n        \"time\": item.time,\n        \"url\": `https://web.okjike.com/originalPost/${item.id}`,\n      }));\n    }\n    if (Array.isArray(data)) data = data.slice(0, Number(args.limit) || 0);\n    return data;\n  })();\n}"},{"name":"jike_user","description":"即刻用户动态","inputSchema":{"type":"object","properties":{"username":{"type":"string","description":"Username from profile URL (e.g. wenhao1996)"},"limit":{"type":"number","description":"Number of posts","default":20}},"required":["username"]},"handler":"(params) => {\n  const args = Object.assign({\"limit\": 20}, params || {});\n  let data = null;\n  let __wbContextUrl = globalThis.location?.href || '';\n  let __wbContextDocument = globalThis.document || null;\n    const __wbDefault = (value, fallback) => (value === undefined || value === null || value === '' ? fallback : value);\n    const __wbJoin = (value, separator) => Array.isArray(value) ? value.join(separator) : (value ?? '');\n    const __wbGet = (value, path) => {\n      if (!path) return value;\n      return String(path).split('.').reduce((acc, part) => (acc == null ? undefined : acc[part]), value);\n    };\n    const __wbBaseUrl = () => (__wbContextUrl || globalThis.location?.href || '');\n    const __wbResolve = (target, base) => {\n      if (target == null) return '';\n      const text = String(target);\n      try {\n        if (/^https?:/i.test(text)) return text;\n        const resolvedBase = base || __wbBaseUrl();\n        return resolvedBase ? new URL(text, resolvedBase).toString() : text;\n      } catch (_error) {\n        return text;\n      }\n    };\n    const __wbFetch = async (target, options) => {\n      const url = __wbResolve(target, __wbBaseUrl());\n      const resp = await globalThis.fetch(url, Object.assign({ credentials: 'include' }, options || {}));\n      if (!resp.ok) {\n        throw new Error(`HTTP ${resp.status} for ${url}`);\n      }\n      const text = await resp.text();\n      try {\n        return { url, text, data: JSON.parse(text) };\n      } catch (_error) {\n        return { url, text, data: text };\n      }\n    };\n  return (async () => {\n    {\n      const __wbResp = await __wbFetch(`https://m.okjike.com/users/${args.username}`);\n      __wbContextUrl = __wbResp.url;\n      __wbContextDocument = new DOMParser().parseFromString(__wbResp.text, 'text/html');\n      data = __wbContextDocument;\n    }\n    {\n      const document = __wbContextDocument || globalThis.document;\n      const location = new URL(__wbBaseUrl());\n      const window = { document, location };\n      const fetch = (target, options) => globalThis.fetch(__wbResolve(target, __wbBaseUrl()), Object.assign({ credentials: 'include' }, options || {}));\n      data = await (((() => {\n  try {\n    const el = document.querySelector('script[type=\"application/json\"]');\n    if (!el) return [];\n    const data = JSON.parse(el.textContent);\n    const posts = data?.props?.pageProps?.posts || [];\n    return posts.map(p => ({\n      content: (p.content || '').replace(/\\n/g, ' ').slice(0, 80),\n      type: p.type === 'ORIGINAL_POST' ? 'post' : p.type === 'REPOST' ? 'repost' : p.type || '',\n      likes: p.likeCount || 0,\n      comments: p.commentCount || 0,\n      time: p.actionTime || p.createdAt || '',\n      id: p.id || '',\n    }));\n  } catch (e) {\n    return [];\n  }\n})())());\n    }\n    {\n      const source = Array.isArray(data) ? data : (data == null ? [] : [data]);\n      data = source.map((item, index) => ({\n        \"content\": item.content,\n        \"type\": item.type,\n        \"likes\": item.likes,\n        \"comments\": item.comments,\n        \"time\": item.time,\n        \"url\": `https://web.okjike.com/originalPost/${item.id}`,\n      }));\n    }\n    if (Array.isArray(data)) data = data.slice(0, Number(args.limit) || 0);\n    return data;\n  })();\n}"}]}