闲社服务运行正常AI智能体自动化平台
f

获取URL

技能标识:fetch-url

Use this when you need the raw HTTP response for non-HTML content or APIs. Examples: JSON, XML, RSS/Atom, CSV, plain text, files, or downloads. If the target is a human-readable web page (HTML) that should be converted to markdown, use fetch-webpage instead.

作者:admin | 来源记录:ClawHub
登记来源
ClawHub
版本
V 1.0.0
检测标记
后台标记通过
免费
免费获取
0
收藏
来源与检测标记为平台登记信息,并不代表已展示可复核的检测报告。使用前请核对版本、依赖和所需权限,建议先在隔离环境中运行。
概述
安装方式
版本历史

获取URL

获取URL

从URL获取原始HTTP响应。支持多个URL和自定义请求头。

用法

bash

单个URL


node {baseDir}/scripts/fetch.mjs https://api.example.com/data

多个URL

node {baseDir}/scripts/fetch.mjs [https://api.example.com/data1, https://api.example.com/data2]

带自定义请求头(按URL设置)

node {baseDir}/scripts/fetch.mjs [https://api.example.com/json, https://api.example.com/text] [{accept:application/json}, {accept:text/plain}]

带超时设置

node {baseDir}/scripts/fetch.mjs https://api.example.com/data --timeout 60000

示例

JSON API

bash

GitHub API - 获取仓库信息

node {baseDir}/scripts/fetch.mjs https://api.github.com/repos/microsoft/vscode {accept:application/json,user-agent:Mozilla/5.0}

XML

bash

SOAP服务或XML端点

node {baseDir}/scripts/fetch.mjs https://api.example.com/soap {accept:application/xml}

站点地图

node {baseDir}/scripts/fetch.mjs https://example.com/sitemap.xml

RSS / Atom 订阅源

bash

RSS 2.0 订阅源

node {baseDir}/scripts/fetch.mjs https://example.com/rss.xml {accept:application/rss+xml}

Atom 订阅源

node {baseDir}/scripts/fetch.mjs https://example.com/atom.xml {accept:application/atom+xml}

CSV / 纯文本

bash

CSV数据

node {baseDir}/scripts/fetch.mjs https://example.com/data.csv {accept:text/csv}

纯文本

node {baseDir}/scripts/fetch.mjs https://example.com/robots.txt {accept:text/plain}

多种格式

bash

并行获取JSON和XML

node {baseDir}/scripts/fetch.mjs [https://api.example.com/data.json, https://api.example.com/data.xml] [{accept:application/json}, {accept:application/xml}]

选项

  • - urlsjson:URL的JSON数组或单个URL字符串
  • headersjson:可选的请求头对象JSON数组(长度需与URL数组一致)
  • --timeout <毫秒>:请求超时时间(毫秒,默认值:30000)

注意:

  • - 返回原始HTTP响应体
  • 对于多个URL,返回结果的JSON数组
  • 需要Node.js 18+(原生fetch支持)

标签

skill ai

通过对话安装

以下为平台配置的接入选项,并非逐项实测通过。能否安装取决于客户端支持、技能来源和运行环境:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 fetch-url-1776063850 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 fetch-url-1776063850 技能

通过命令行安装

skillhub install fetch-url-1776063850

下载

⬇ 下载 fetch-url v1.0.0(免费)

文件大小: 3.64 KB | 发布时间: 2026-4-14 10:55

v1.0.0 最新 2026-4-14 10:55
- Initial release of the fetch-url skill.
- Fetches raw HTTP responses from URLs, supporting JSON, XML, RSS/Atom, CSV, plain text, files, and downloads.
- Allows fetching from multiple URLs in parallel and supports custom headers per URL.
- Supports request timeout configuration.
- Designed for non-HTML content; for HTML-to-markdown conversion, use fetch-webpage.
返回顶部