{
  "schemaVersion": "1.0",
  "item": {
    "slug": "ms-graph-calendar",
    "name": "Ms Graph Calendar",
    "source": "tencent",
    "type": "skill",
    "category": "效率提升",
    "sourceUrl": "https://clawhub.ai/ARTISONG/ms-graph-calendar",
    "canonicalUrl": "https://clawhub.ai/ARTISONG/ms-graph-calendar",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/ms-graph-calendar",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=ms-graph-calendar",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "nicknames.md",
      "SKILL.md",
      "scripts/resolve-nicknames.js",
      "scripts/list-users.js",
      "scripts/find-meeting-times.js",
      "scripts/setup.js"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-23T16:43:11.935Z",
      "expiresAt": "2026-04-30T16:43:11.935Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
        "contentDisposition": "attachment; filename=\"4claw-imageboard-1.0.1.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/ms-graph-calendar"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/ms-graph-calendar",
    "agentPageUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent",
    "manifestUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Microsoft Graph Calendar — Find Free Slots",
        "body": "Use this skill when the user wants to:\n\nFind a time when multiple employees are all free\nCheck if a specific person is available at a given time\nList upcoming meetings / busy blocks for one or more people\nSuggest meeting slots across the company"
      },
      {
        "title": "Setup (ทำครั้งแรกครั้งเดียว)",
        "body": "ถ้าผู้ใช้ยังไม่เคย setup หรือระบบแจ้งว่าขาด credentials ให้ทำดังนี้:\n\nถามผู้ใช้ 3 ค่านี้ทีละค่า:\n\nAZURE_TENANT_ID (Azure Portal → Azure Active Directory → Overview)\nAZURE_CLIENT_ID (App registrations → your app → Application (client) ID)\nAZURE_CLIENT_SECRET (App registrations → your app → Certificates & secrets)\n\n\n\nเมื่อได้ครบแล้ว รันคำสั่ง:\n\nnode skills/ms-graph-calendar/scripts/setup.js \\\n  --tenant-id <AZURE_TENANT_ID> \\\n  --client-id <AZURE_CLIENT_ID> \\\n  --client-secret <AZURE_CLIENT_SECRET>\n\nค่าจะถูกบันทึกไว้ที่ ~/.openclaw/ms-graph-calendar.json (permission 600) และจะถูกโหลดอัตโนมัติทุกครั้งที่ใช้ skill\n\nทดสอบด้วย:\n\nnode skills/ms-graph-calendar/scripts/get-token.js\n\nถ้าได้ \"✅ Token acquired\" แปลว่าพร้อมใช้งานแล้ว\n\nApp Registration ต้องมี Application Permissions:\n\nCalendars.Read — read all users' calendars\nUser.Read.All — list employees\nAdmin ต้อง Grant consent ก่อน"
      },
      {
        "title": "Configuration",
        "body": "Authentication is cached after first login. No environment variables required for device code flow.\n\nFor headless/automated operation, set these environment variables:\n\nAZURE_CLIENT_ID - Azure AD app client ID\nAZURE_CLIENT_SECRET - Azure AD app secret\nAZURE_TENANT_ID - Tenant ID (use \"consumers\" for personal accounts)"
      },
      {
        "title": "Tools",
        "body": "This skill runs Node.js scripts via bash. Files:\n\nscripts/ — Node.js scripts\nnicknames.md — ตาราง mapping ชื่อเล่น → email (แก้ไขได้เลย)"
      },
      {
        "title": "Step 1 — Get Access Token",
        "body": "Before any Graph API call, get an app-only token:\n\nnode skills/ms-graph-calendar/scripts/get-token.js\n\nStore the token in a temp variable for subsequent calls."
      },
      {
        "title": "Step 2 — Parse the User's Request",
        "body": "Extract from the user's message:\n\nWho: names or emails of attendees (e.g. \"Alice and Bob\", \"the marketing team\")\nWhen: date range to search (e.g. \"this week\", \"next Monday\", \"March 5–7\")\nDuration: how long the meeting should be (default 60 minutes)\nTimezone: default to Asia/Bangkok if not specified\n\nIf any info is missing, ask the user before proceeding."
      },
      {
        "title": "Step 3 — Resolve Employee Emails",
        "body": "3a. ลองแปลงชื่อเล่นก่อน (เร็วกว่า ไม่ต้องเรียก API):\n\nnode skills/ms-graph-calendar/scripts/resolve-nicknames.js --names \"แบงค์,มิ้ว,โบ้\"\n\nอ่านจาก nicknames.md ในโฟลเดอร์ skill — แก้ไขได้ตรงนั้นเลย\n\n3b. ถ้าหาไม่เจอใน nicknames.md ให้ fallback ไปค้น Graph API:\n\nnode skills/ms-graph-calendar/scripts/list-users.js --search \"ชื่อ\"\n\nConfirm กับ user ถ้ามีคนชื่อเดียวกันหลายคน"
      },
      {
        "title": "Step 4 — Find Free Slots (choose one method)",
        "body": "Method A — findMeetingTimes (best for small groups, ≤10 people):\n\nnode skills/ms-graph-calendar/scripts/find-meeting-times.js \\\n  --attendees \"alice@company.com,bob@company.com\" \\\n  --start \"2025-03-01T08:00:00\" \\\n  --end \"2025-03-01T18:00:00\" \\\n  --duration 60 \\\n  --timezone \"Asia/Bangkok\" \\\n  --max 5\n\nMethod B — getSchedule (best for large groups or viewing free/busy blocks):\n\nnode skills/ms-graph-calendar/scripts/get-schedule.js \\\n  --emails \"alice@company.com,bob@company.com,carol@company.com\" \\\n  --start \"2025-03-01T00:00:00\" \\\n  --end \"2025-03-07T00:00:00\" \\\n  --timezone \"Asia/Bangkok\" \\\n  --interval 30"
      },
      {
        "title": "Step 5 — Present Results",
        "body": "Format the available slots clearly:\n\n📅 Available slots where everyone is free:\n\n1. Monday 3 Mar · 10:00–11:00\n2. Tuesday 4 Mar · 14:00–15:00\n3. Wednesday 5 Mar · 09:00–10:00\n\nWhich slot works best?\n\nIf no slots are found, widen the search window and try again, or report that no common availability exists in that period."
      },
      {
        "title": "Example Conversations",
        "body": "User: \"Find a 1-hour slot this week where Alice, Bob, and Carol are all free\"\nAgent:\n\nResolves emails for Alice, Bob, Carol\nRuns find-meeting-times.js with date range = this Mon–Fri\nReturns top 3 available slots\n\nUser: \"Is John free tomorrow afternoon?\"\nAgent:\n\nResolves John's email\nRuns get-schedule.js for tomorrow 12:00–18:00\nReports free/busy blocks\n\nUser: \"Show me everyone in the marketing team's availability next week\"\nAgent:\n\nLists users in the Marketing group via list-users.js --group \"Marketing\"\nRuns get-schedule.js for all their emails\nPresents a visual free/busy summary"
      },
      {
        "title": "Error Handling",
        "body": "ErrorCauseFix401 UnauthorizedToken expired or wrong credentialsRe-run get-token.js, check env vars403 ForbiddenMissing Admin ConsentAsk IT admin to grant consent in Azure Portal404 Not FoundUser email doesn't existVerify email via list-users.jsNo slots foundEveryone is busyWiden time range or reduce attendees"
      },
      {
        "title": "Security Notes",
        "body": "Credentials are read from env vars only — never log or echo them\nThis skill has read-only access to calendars (Calendars.Read)\nIt cannot create, edit, or delete any events\nTo restrict which mailboxes the app can read, ask your IT admin to set an App Access Policy in Exchange Online:\nNew-ApplicationAccessPolicy -AppId <ClientId> -PolicyScopeGroupId <GroupId> -AccessRight RestrictAccess"
      }
    ],
    "body": "Microsoft Graph Calendar — Find Free Slots\n\nUse this skill when the user wants to:\n\nFind a time when multiple employees are all free\nCheck if a specific person is available at a given time\nList upcoming meetings / busy blocks for one or more people\nSuggest meeting slots across the company\nSetup (ทำครั้งแรกครั้งเดียว)\n\nถ้าผู้ใช้ยังไม่เคย setup หรือระบบแจ้งว่าขาด credentials ให้ทำดังนี้:\n\nถามผู้ใช้ 3 ค่านี้ทีละค่า:\n\nAZURE_TENANT_ID (Azure Portal → Azure Active Directory → Overview)\nAZURE_CLIENT_ID (App registrations → your app → Application (client) ID)\nAZURE_CLIENT_SECRET (App registrations → your app → Certificates & secrets)\n\nเมื่อได้ครบแล้ว รันคำสั่ง:\n\nnode skills/ms-graph-calendar/scripts/setup.js \\\n  --tenant-id <AZURE_TENANT_ID> \\\n  --client-id <AZURE_CLIENT_ID> \\\n  --client-secret <AZURE_CLIENT_SECRET>\n\n\nค่าจะถูกบันทึกไว้ที่ ~/.openclaw/ms-graph-calendar.json (permission 600) และจะถูกโหลดอัตโนมัติทุกครั้งที่ใช้ skill\n\nทดสอบด้วย:\nnode skills/ms-graph-calendar/scripts/get-token.js\n\n\nถ้าได้ \"✅ Token acquired\" แปลว่าพร้อมใช้งานแล้ว\n\nApp Registration ต้องมี Application Permissions:\n\nCalendars.Read — read all users' calendars\nUser.Read.All — list employees\nAdmin ต้อง Grant consent ก่อน\nConfiguration\n\nAuthentication is cached after first login. No environment variables required for device code flow.\n\nFor headless/automated operation, set these environment variables:\n\nAZURE_CLIENT_ID - Azure AD app client ID\nAZURE_CLIENT_SECRET - Azure AD app secret\nAZURE_TENANT_ID - Tenant ID (use \"consumers\" for personal accounts)\nTools\n\nThis skill runs Node.js scripts via bash. Files:\n\nscripts/ — Node.js scripts\nnicknames.md — ตาราง mapping ชื่อเล่น → email (แก้ไขได้เลย)\nInstructions\nStep 1 — Get Access Token\n\nBefore any Graph API call, get an app-only token:\n\nnode skills/ms-graph-calendar/scripts/get-token.js\n\n\nStore the token in a temp variable for subsequent calls.\n\nStep 2 — Parse the User's Request\n\nExtract from the user's message:\n\nWho: names or emails of attendees (e.g. \"Alice and Bob\", \"the marketing team\")\nWhen: date range to search (e.g. \"this week\", \"next Monday\", \"March 5–7\")\nDuration: how long the meeting should be (default 60 minutes)\nTimezone: default to Asia/Bangkok if not specified\n\nIf any info is missing, ask the user before proceeding.\n\nStep 3 — Resolve Employee Emails\n\n3a. ลองแปลงชื่อเล่นก่อน (เร็วกว่า ไม่ต้องเรียก API):\n\nnode skills/ms-graph-calendar/scripts/resolve-nicknames.js --names \"แบงค์,มิ้ว,โบ้\"\n\n\nอ่านจาก nicknames.md ในโฟลเดอร์ skill — แก้ไขได้ตรงนั้นเลย\n\n3b. ถ้าหาไม่เจอใน nicknames.md ให้ fallback ไปค้น Graph API:\n\nnode skills/ms-graph-calendar/scripts/list-users.js --search \"ชื่อ\"\n\n\nConfirm กับ user ถ้ามีคนชื่อเดียวกันหลายคน\n\nStep 4 — Find Free Slots (choose one method)\n\nMethod A — findMeetingTimes (best for small groups, ≤10 people):\n\nnode skills/ms-graph-calendar/scripts/find-meeting-times.js \\\n  --attendees \"alice@company.com,bob@company.com\" \\\n  --start \"2025-03-01T08:00:00\" \\\n  --end \"2025-03-01T18:00:00\" \\\n  --duration 60 \\\n  --timezone \"Asia/Bangkok\" \\\n  --max 5\n\n\nMethod B — getSchedule (best for large groups or viewing free/busy blocks):\n\nnode skills/ms-graph-calendar/scripts/get-schedule.js \\\n  --emails \"alice@company.com,bob@company.com,carol@company.com\" \\\n  --start \"2025-03-01T00:00:00\" \\\n  --end \"2025-03-07T00:00:00\" \\\n  --timezone \"Asia/Bangkok\" \\\n  --interval 30\n\nStep 5 — Present Results\n\nFormat the available slots clearly:\n\n📅 Available slots where everyone is free:\n\n1. Monday 3 Mar · 10:00–11:00\n2. Tuesday 4 Mar · 14:00–15:00\n3. Wednesday 5 Mar · 09:00–10:00\n\nWhich slot works best?\n\n\nIf no slots are found, widen the search window and try again, or report that no common availability exists in that period.\n\nExample Conversations\n\nUser: \"Find a 1-hour slot this week where Alice, Bob, and Carol are all free\" Agent:\n\nResolves emails for Alice, Bob, Carol\nRuns find-meeting-times.js with date range = this Mon–Fri\nReturns top 3 available slots\n\nUser: \"Is John free tomorrow afternoon?\" Agent:\n\nResolves John's email\nRuns get-schedule.js for tomorrow 12:00–18:00\nReports free/busy blocks\n\nUser: \"Show me everyone in the marketing team's availability next week\" Agent:\n\nLists users in the Marketing group via list-users.js --group \"Marketing\"\nRuns get-schedule.js for all their emails\nPresents a visual free/busy summary\nError Handling\nError\tCause\tFix\n401 Unauthorized\tToken expired or wrong credentials\tRe-run get-token.js, check env vars\n403 Forbidden\tMissing Admin Consent\tAsk IT admin to grant consent in Azure Portal\n404 Not Found\tUser email doesn't exist\tVerify email via list-users.js\nNo slots found\tEveryone is busy\tWiden time range or reduce attendees\nSecurity Notes\nCredentials are read from env vars only — never log or echo them\nThis skill has read-only access to calendars (Calendars.Read)\nIt cannot create, edit, or delete any events\nTo restrict which mailboxes the app can read, ask your IT admin to set an App Access Policy in Exchange Online:\nNew-ApplicationAccessPolicy -AppId <ClientId> -PolicyScopeGroupId <GroupId> -AccessRight RestrictAccess"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/ARTISONG/ms-graph-calendar",
    "publisherUrl": "https://clawhub.ai/ARTISONG/ms-graph-calendar",
    "owner": "ARTISONG",
    "version": "1.0.2",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/ms-graph-calendar",
    "downloadUrl": "https://openagent3.xyz/downloads/ms-graph-calendar",
    "agentUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent",
    "manifestUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/ms-graph-calendar/agent.md"
  }
}