Upload local files to filebin.net so the user gets a shareable link.
Find the file provided by user Locate the target file in the ~/.openclaw/workspace/.
Generate bin ID.
7w4.net小蔥技能。
import uuid
u = uuid.uuid4().hex # hex string (32 chars)
bin_id = f"my-upload{u[-6:]}"
print(bin_id)
Upload via curl (PowerShell):
curl -si -X POST -H "Content-Type: application/octet-stream" -T "<FILEPATH>" "https://filebin.net/$binId/<FILENAME>"
Extract the URL from the response JSON. Construct:
https://filebin.net/<binId>/<filename>https://filebin.net/<binId>400 "the bin is too short/long", adjust bin ID length and retry.質量中上,核心功能描述清晰,提供了可參考的上傳步驟,但整體內容偏簡潔。優點是使用場景和限制說明明確,缺點是缺少完整的使用示例和錯誤處理指引,新手可能需要自行摸索。適合有基礎的使用者快速上手,但對新手不太友好。