الانتقال إلى المحتوى الرئيسي

مساحات العمل

إدارة مساحات العمل وعضوياتها. تستخدم الأمثلة وضع الكود في A2A. يتيح MCP وضع الكود نفسه عبر أداة execute.

الوظائف

workspaces.add

workspaces.add(account_id: str, name: str) -> Workspace
مساحات العمل: workspaces.add.
الخاصيةالقيمةالخاصيةالقيمة
الإذن المطلوبworkspace.manageالمصادقة مطلوبةنعم
وضع التنفيذsyncالصلاحيةworkspace.manage
نوع الموردaccountحقل معرف الموردaccount_id
مسار API العامPOST /v1/public/accounts/{account_id}/workspaces
الاسمالنوعمطلوب
account_idstrنعم
namestrنعم
الحقلالنوعمطلوب
account_idstrنعم
idstrنعم
namestrنعم
created_atstr | nullلا
statusstrلا
updated_atstr | nullلا
الطلب:
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "workspaces.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", name=\"<string>\")"
}
الاستجابة:
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": "<string>"
  },
  "responses": [
    {
      "index": 0,
      "function": "workspaces.add",
      "status": "completed",
      "result": "<string>"
    }
  ],
  "complexity_score": 1
}
الطلب:
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "workspaces.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", name=\"<string>\")"
    }
  }
}
الاستجابة:
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"workspaces.add\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}

workspaces.delete

workspaces.delete(account_id: str, workspace_id: str) -> {}
مساحات العمل: workspaces.delete.
الخاصيةالقيمةالخاصيةالقيمة
الإذن المطلوبworkspace.manageالمصادقة مطلوبةنعم
وضع التنفيذsyncالصلاحيةworkspace.manage
نوع الموردaccountحقل معرف الموردaccount_id
مسار API العامDELETE /v1/public/accounts/{account_id}/workspaces/{workspace_id}
الاسمالنوعمطلوب
account_idstrنعم
workspace_idstrنعم
الحقلالنوعمطلوب
result{}نعم
الطلب:
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "workspaces.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
}
الاستجابة:
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": {}
  },
  "responses": [
    {
      "index": 0,
      "function": "workspaces.delete",
      "status": "completed",
      "result": {}
    }
  ],
  "complexity_score": 1
}
الطلب:
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "workspaces.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
  }
}
الاستجابة:
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {}\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"workspaces.delete\",\n      \"status\": \"completed\",\n      \"result\": {}\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}

workspaces.get

workspaces.get(account_id: str, workspace_id: str) -> Workspace
مساحات العمل: workspaces.get.
الخاصيةالقيمةالخاصيةالقيمة
الإذن المطلوبworkspace.viewالمصادقة مطلوبةنعم
وضع التنفيذsyncالصلاحيةworkspace.view
نوع الموردaccountحقل معرف الموردaccount_id
مسار API العامGET /v1/public/accounts/{account_id}/workspaces/{workspace_id}
الاسمالنوعمطلوب
account_idstrنعم
workspace_idstrنعم
الحقلالنوعمطلوب
account_idstrنعم
idstrنعم
namestrنعم
created_atstr | nullلا
statusstrلا
updated_atstr | nullلا
الطلب:
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "workspaces.get(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
}
الاستجابة:
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": "<string>"
  },
  "responses": [
    {
      "index": 0,
      "function": "workspaces.get",
      "status": "completed",
      "result": "<string>"
    }
  ],
  "complexity_score": 1
}
الطلب:
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "workspaces.get(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
  }
}
الاستجابة:
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"workspaces.get\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}

workspaces.list

workspaces.list(account_id: str, page?: int, page_size?: int) -> Page[Workspace]
مساحات العمل: workspaces.list.
الخاصيةالقيمةالخاصيةالقيمة
الإذن المطلوبworkspace.viewالمصادقة مطلوبةنعم
وضع التنفيذsyncالصلاحيةworkspace.view
نوع الموردaccountحقل معرف الموردaccount_id
مسار API العامGET /v1/public/accounts/{account_id}/workspaces
الاسمالنوعمطلوب
account_idstrنعم
pageintلا
page_sizeintلا
الحقلالنوعمطلوب
items[{"account_id": str, "id": str, "name": str, "created_at"?: str | null, "status"?: str, "updated_at"?: str | null}]نعم
pageintنعم
page_sizeintنعم
totalintنعم
الطلب:
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "workspaces.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
}
الاستجابة:
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": "<string>"
  },
  "responses": [
    {
      "index": 0,
      "function": "workspaces.list",
      "status": "completed",
      "result": "<string>"
    }
  ],
  "complexity_score": 1
}
الطلب:
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "workspaces.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
    }
  }
}
الاستجابة:
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"workspaces.list\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}

workspaces.update

workspaces.update(account_id: str, workspace_id: str, name: str) -> Workspace
مساحات العمل: workspaces.update.
الخاصيةالقيمةالخاصيةالقيمة
الإذن المطلوبworkspace.manageالمصادقة مطلوبةنعم
وضع التنفيذsyncالصلاحيةworkspace.manage
نوع الموردaccountحقل معرف الموردaccount_id
مسار API العامPATCH /v1/public/accounts/{account_id}/workspaces/{workspace_id}
الاسمالنوعمطلوب
account_idstrنعم
workspace_idstrنعم
namestrنعم
الحقلالنوعمطلوب
account_idstrنعم
idstrنعم
namestrنعم
created_atstr | nullلا
statusstrلا
updated_atstr | nullلا
الطلب:
{
  "request_id": "example",
  "session_id": "session_123",
  "code": "workspaces.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", name=\"<string>\")"
}
الاستجابة:
{
  "request_id": "example",
  "status": "completed",
  "result": {
    "last_value": "<string>"
  },
  "responses": [
    {
      "index": 0,
      "function": "workspaces.update",
      "status": "completed",
      "result": "<string>"
    }
  ],
  "complexity_score": 1
}
الطلب:
{
  "jsonrpc": "2.0",
  "id": "example",
  "method": "tools/call",
  "params": {
    "name": "hybridbox_execute",
    "arguments": {
      "code": "workspaces.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", workspace_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", name=\"<string>\")"
    }
  }
}
الاستجابة:
{
  "jsonrpc": "2.0",
  "id": "example",
  "result": {
    "content": [
      {
        "type": "text",
        "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"workspaces.update\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
      }
    ],
    "isError": false
  }
}