← 返回
未分类 Key 中文

OpenAI

Manage OpenAI files, assistants, vector stores, batches, fine-tuning jobs, and model resources via the OpenAI API. Use this skill when users want to create o...
通过 OpenAI API 管理文件、助手、向量存储、批次、微调作业和模型资源。当用户需要创建或管理 OpenAI 资源时使用此技能。
hith3sh hith3sh 来源
未分类 clawhub v1.0.6 2 版本 99668.4 Key: 需要
★ 6
Stars
📥 1,383
下载
💾 1
安装
2
版本
#latest

概述

OpenAI

!OpenAI

Access OpenAI's platform API with API key authentication. Manage files, assistants, vector stores, batches, fine-tuning jobs, and model resources. Generate chat completions, images, audio, and video.

This skill uses ClawLink for hosted connection flows and credentials so you do not need to configure OpenAI API access yourself.

Setup in 3 Steps

Step 1: InstallStep 2: Pair AccountStep 3: Connect OpenAI
:---::---::---:
!Install!PairApp-specific connection GIF coming soon
Run the install command in OpenClawSign in and approve the deviceOpen the dashboard and connect OpenAI

How It Works

┌─────────────────┐     ┌──────────────┐     ┌──────────────────┐
│   OpenClaw      │────▶│   ClawLink   │────▶│   OpenAI API     │
│   (User Chat)   │     │   (API Key)  │     │                  │
└─────────────────┘     └──────────────┘     └──────────────────┘
          │                       │                       │
          │  1. Install Plugin   │                       │
          │  2. Pair Device      │                       │
          │3. Connect OpenAI   │                       │
          │                      │  4. Secure Proxy      │
          │                      │  5. API Requests      │
          │                      │                       │
          ▼                      ▼                       ▼
    ┌──────────┐           ┌──────────┐           ┌──────────┐
    │  SKILL   │           │ Dashboard│           │  OpenAI  │
    │  File    │           │ Auth     │           │ Platform │
    └──────────┘           └──────────┘           └──────────┘

Install

Install the verified ClawLink plugin from ClawHub. After the user confirms, complete the full setup so ClawLink tools are visible in the next OpenClaw chat.

openclaw plugins install clawhub:clawlink-plugin
openclaw config set tools.alsoAllow '["clawlink-plugin"]' --strict-json
openclaw gateway restart

Then tell the user: "OpenClaw has been restarted. Send /new as a standalone message to start a fresh chat, then ask for OpenAI again."

Quick Start

# List assistants
clawlink_call_tool --tool "openai_list_assistants" --params '{"limit": 10}'

# Create a chat completion
clawlink_call_tool --tool "openai_create_chat_completion" --params '{"model": "gpt-4o", "messages": [{"role": "user", "content": "Hello"}]}'

# List files
clawlink_call_tool --tool "openai_list_files" --params '{"purpose": "batch"}'

Authentication

All OpenAI tool calls are authenticated automatically by ClawLink using the user's OpenAI API key.

No API key is required in chat. ClawLink stores the API key securely and injects it into every OpenAI API request on the user's behalf.

Getting Connected

  1. Install the ClawLink plugin (see Install above).
  2. Pair the plugin with clawlink_begin_pairing if it is not configured yet.
  3. Open https://claw-link.dev/dashboard?add=openai and connect OpenAI.
  4. Call clawlink_list_integrations to verify the connection is active.

Connection Management

List Connections

clawlink_list_integrations

Response: Returns all connected integrations. Look for openai in the list.

Verify Connection

clawlink_list_tools --integration openai

Response: Returns the live tool catalog for OpenAI.

Reconnect

If OpenAI tools are missing or the connection shows an error:

  1. Direct the user to https://claw-link.dev/dashboard?add=openai
  2. After they confirm, call clawlink_list_integrations to verify
  3. Then call clawlink_list_tools --integration openai

Security& Permissions

  • Access is scoped to resources within the connected OpenAI organization and account.
  • All write operations require explicit user confirmation. Before executing any create, update, or delete call, confirm the target resource and intended effect with the user.
  • Destructive actions (delete file, delete assistant, cancel batch) must be confirmed.
  • Fine-tuning, batch jobs, and video generation are asynchronous — poll for completion.

Tool Reference

Assistants & Threads

ToolDescriptionMode
-------------------------
openai_list_assistantsList assistants to discover by name or metadataRead
openai_create_assistantCreate a new assistant with model and toolsWrite
openai_modify_assistantUpdate an existing assistantWrite
openai_delete_assistantDelete an assistant permanentlyWrite
openai_create_threadCreate a new conversation threadWrite
openai_create_messageAdd a message to a threadWrite
openai_create_runExecute an assistant on a threadWrite
openai_list_messagesList messages in a threadRead
openai_list_runsList runs for a threadRead
openai_cancel_runCancel an in-progress runWrite
openai_list_run_stepsList steps in a runRead
openai_get_run_stepGet details of a specific run stepRead

Files & Vector Stores

ToolDescriptionMode
-------------------------
openai_list_filesList uploaded filesRead
openai_upload_fileUpload a file to OpenAIWrite
openai_delete_fileDelete an uploaded fileWrite
openai_download_fileDownload file contentRead
openai_create_vector_storeCreate a vector storeWrite
openai_list_vector_storesList vector storesRead
openai_get_vector_storeGet vector store detailsRead
openai_delete_vector_storeDelete a vector storeWrite
openai_create_vector_store_fileAdd a file to a vector storeWrite
openai_list_vector_store_filesList files in a vector storeRead
openai_delete_vector_store_fileRemove a file from a vector storeWrite

Batches & Fine-Tuning

ToolDescriptionMode
-------------------------
openai_list_batchesList batch jobsRead
openai_create_batchCreate a batch from a JSONL fileWrite
openai_cancel_batchCancel an in-progress batchWrite
openai_list_fine_tunesList fine-tuning jobsRead
openai_create_fine_tuning_jobStart a fine-tuning jobWrite
openai_list_fine_tuning_eventsGet events for a fine-tuning jobRead
openai_list_fine_tuning_job_checkpointsList checkpoints from a fine-tuning jobRead

Generations & Completions

ToolDescriptionMode
-------------------------
openai_create_chat_completionCreate a chat completionRead
openai_create_completionCreate a text completion (legacy)Read
openai_create_responseCreate a response via Responses APIWrite
openai_create_embeddingsGenerate text embeddingsRead
openai_create_imageGenerate an imageWrite
openai_create_image_editEdit an existing imageWrite
openai_create_image_variationCreate an image variationWrite
openai_create_speechGenerate text-to-speech audioRead
openai_create_audio_transcriptionTranscribe audio to textRead
openai_create_audio_translationTranslate audio to EnglishRead
openai_create_videoGenerate a videoWrite
openai_list_videosList video generation jobsRead
openai_get_videoGet video generation statusRead
openai_download_videoDownload video contentRead
openai_create_moderationClassify content for policy violationsRead

Evaluations

ToolDescriptionMode
-------------------------
openai_list_evalsList evaluationsRead
openai_get_evalGet evaluation detailsRead
openai_create_evalCreate an evaluationWrite
openai_delete_evalDelete an evaluationWrite
openai_create_eval_runStart an evaluation runWrite
openai_get_eval_runGet evaluation run statusRead
openai_list_eval_runsList evaluation runsRead
openai_cancel_eval_runCancel an evaluation runWrite

Other Resources

ToolDescriptionMode
-------------------------
openai_list_modelsList available modelsRead
openai_list_enginesList available enginesRead
openai_get_input_token_countsCalculate token counts for a requestRead
openai_create_skillCreate a skill from filesWrite
openai_list_skillsList skillsRead
openai_delete_skillDelete a skillWrite
openai_create_containerCreate an isolated execution containerWrite
openai_list_containersList containersRead
openai_delete_containerDelete a containerWrite

Code Examples

Create a chat completion

clawlink_call_tool --tool "openai_create_chat_completion" \
  --params '{
    "model": "gpt-4o",
    "messages": [
      {"role": "system", "content": "You are a helpful assistant."},
      {"role": "user", "content": "Explain quantum computing in simple terms."}
    ],
    "max_tokens": 500
  }'

Create an assistant

clawlink_call_tool --tool "openai_create_assistant" \
  --params '{
    "name": "Code Reviewer",
    "model": "gpt-4o",
    "instructions": "You review code and suggest improvements.",
    "tools": [{"type": "code_interpreter"}]
  }'

Upload a file and create a vector store

clawlink_call_tool --tool "openai_upload_file" \
  --params '{
    "file": "@./knowledge.pdf",
    "purpose": "assistants"
  }'

clawlink_call_tool --tool "openai_create_vector_store_file" \
  --params '{
    "vector_store_id": "VS_ID",
    "file_id": "FILE_ID"
  }'

Create a batch job

clawlink_call_tool --tool "openai_create_batch" \
  --params '{
    "input_file_id": "FILE_ID",
    "endpoint": "chat/completions",
    "model": "gpt-4o-mini",
    "completion_window": "24h"
  }'

Generate an image

clawlink_call_tool --tool "openai_create_image" \
  --params '{
    "model": "dall-e-3",
    "prompt": "A minimalist diagram showing the OpenClaw to ClawLink to Provider flow",
    "size": "1024x1024",
    "n": 1
  }'

Discovery Workflow

  1. Call clawlink_list_integrations to confirm OpenAI is connected.
  2. Call clawlink_list_tools --integration openai to see the live catalog.
  3. Treat the returned list as the source of truth. Do not guess or assume what tools exist.
  4. If the user describes a capability but the exact tool is unclear, call clawlink_search_tools with a short query and integration openai.
  5. If no OpenAI tools appear, direct the user to https://claw-link.dev/dashboard?add=openai.

Execution Workflow

┌─────────────────────────────────────────────────────────────┐
│  READ OPERATIONS (Safe)                                     │
│  list → get → search → describe → call                      │
│                                                             │
│  Example: List models → Create completion → Return result   │
└─────────────────────────────────────────────────────────────┘
                              │
                              ▼
┌─────────────────────────────────────────────────────────────┐
│  WRITE OPERATIONS (Require Confirmation)                     │
│  list → get → describe → preview → confirm → call           │
│                                                             │
│  Example: Describe tool → Preview changes → User approves   │
│           → Execute update                                  │
└─────────────────────────────────────────────────────────────┘
  1. For unfamiliar tools, ambiguous requests, or any write action, call clawlink_describe_tool first.
  2. Use the returned guidance, schema, whenToUse, askBefore, safeDefaults, examples, and followups to shape the call.
  3. Prefer read, list, search, and get operations before writes when that reduces ambiguity.
  4. For writes or anything marked as requiring confirmation, call clawlink_preview_tool first.
  5. Execute with clawlink_call_tool. Pass confirmation only after the preview matches the user's intent.
  6. If the tool call fails, report the real error. Do not invent results or restate the failure as a missing capability unless the live catalog supports that conclusion.

Notes

  • Use model IDs exactly as returned by openai_list_models — misspelled or unsupported IDs cause validation errors.
  • Asynchronous operations (batch, fine-tune, video) return a job ID — poll get endpoints to check completion.
  • Thread IDs must be persisted after creation and passed to all subsequent calls.
  • Files uploaded for batch processing must have purpose: "batch"; files for assistants must have purpose: "assistants".
  • Video generation is asynchronous — poll openai_get_video until status is completed.

Error Handling

Status / ErrorMeaning
-------------------------
Tool not foundThe tool name does not exist in the current catalog. Verify with clawlink_list_tools --integration openai.
Missing connectionOpenAI is not connected. Direct the user to https://claw-link.dev/dashboard?add=openai.
invalid_request_errorInvalid parameter or model not available. Verify model ID with openai_list_models.
RateLimitErrorToo many requests. Wait and retry with exponential backoff.
authentication_errorInvalid API key. Reconnect OpenAI at the dashboard.
Write rejectedUser did not confirm a write action. Always confirm before executing writes.

Troubleshooting: Tools Not Visible

  1. Check that the ClawLink plugin is installed:

```bash

openclaw plugins list

```

  1. If the plugin is installed but tools are missing, tell the user to send /new as a standalone message to reload the catalog.
  2. If a fresh chat does not help, run:

```bash

openclaw config set tools.alsoAllow '["clawlink-plugin"]' --strict-json

openclaw gateway restart

```

  1. After restart, tell the user to send /new again and retry.

Troubleshooting: Invalid Tool Call

  1. Ensure the integration slug is exactly openai.
  2. Use clawlink_describe_tool to verify parameter names and types before calling.
  3. For write operations, always call clawlink_preview_tool first.

Resources

Related Skills

  • OpenAI — For this skill's native documentation

Powered by ClawLink — an integration hub for OpenClaw

!ClawLink Logo

版本历史

共 2 个版本

  • v1.0.6 当前
    2026-06-09 16:21 安全 安全
  • v0.1.0
    2026-05-21 15:32 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

Notion Assistant

hith3sh
搜索页面和数据库、更新内容、管理 Notion 工作区数据,支持从聊天中读取、创建或修改 Notion 页面...
★ 8 📥 1,854

GitHub

hith3sh
通过 GitHub REST 和GraphQL API 与仓库、议题、拉取请求、提交、分支、发布和工作流进行交互。在需要时使用此技能。
★ 6 📥 1,865

OneDrive Files

hith3sh
通过 Microsoft Graph 浏览、搜索、下载和共享 OneDrive 文件,创建文件夹,上传文件以及管理文件操作。当用户需要这些功能时使用此技能。
★ 6 📥 1,804