openclaw - ✅(Solved) Fix Feature request: feishu_calendar tool — create events, invite attendees, book meeting rooms [1 pull requests, 1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#43696Fetched 2026-04-08 00:17:03
View on GitHub
Comments
1
Participants
2
Timeline
2
Reactions
0
Timeline (top)
commented ×1cross-referenced ×1

Add a feishu_calendar tool to the Feishu extension, enabling the agent to create calendar events, invite attendees, and book meeting rooms via natural language.

Root Cause

Currently the bot cannot do this because there is no calendar tool. The agent has to reply with manual instructions.

Fix Action

Fixed

PR fix notes

PR #43713: feat(feishu): add feishu_calendar tool for calendar event management

Description (problem / solution / changelog)

Summary

  • Add feishu_calendar tool to the Feishu extension, enabling agents to manage calendar events via natural language
  • Supports 5 actions: create_event, add_attendees, list_events, get_event, delete_event
  • Follows the same patterns as existing tools (feishu_chat, feishu_doc, feishu_bitable)
  • Enabled by default in tools-config.ts, controllable via account-level tools.calendar config

Motivation

Users in Feishu group chats want to schedule meetings naturally, e.g.:

"邀请群里的所有人,预定一个2点的会议,标题:周会"

The agent can now combine feishu_chat (get members) + feishu_calendar (create event + add attendees) to fulfill this.

Related feature request: #43696

Changes

FileChange
extensions/feishu/src/calendar-schema.tsNew — TypeBox schema for tool parameters
extensions/feishu/src/calendar.tsNew — Tool implementation (5 actions, ~280 lines)
extensions/feishu/index.tsRegister registerFeishuCalendarTools
extensions/feishu/src/tools-config.tsAdd calendar: true default
extensions/feishu/src/types.tsAdd calendar?: boolean to FeishuToolsConfig

Requirements

  • Feishu bot must have calendar:calendar permission enabled in the developer console
  • Uses "primary" as the default calendar ID (bot's own calendar)

Test plan

  • Verified tool registers successfully on gateway startup
  • Tested create_event with ISO 8601 and unix timestamp inputs
  • Tested add_attendees with group member open_ids from feishu_chat
  • Tested end-to-end flow: "@bot 预定一个2点的会议,邀请群里所有人"

🤖 Generated with Claude Code

Changed files

  • CHANGELOG.md (modified, +6/-106)
  • extensions/feishu/index.ts (modified, +2/-0)
  • extensions/feishu/src/calendar-schema.ts (added, +67/-0)
  • extensions/feishu/src/calendar.ts (added, +291/-0)
  • extensions/feishu/src/config-schema.ts (modified, +1/-0)
  • extensions/feishu/src/tool-account.ts (modified, +6/-0)
  • extensions/feishu/src/tools-config.ts (modified, +4/-1)
  • extensions/feishu/src/types.ts (modified, +3/-0)
RAW_BUFFERClick to expand / collapse

Summary

Add a feishu_calendar tool to the Feishu extension, enabling the agent to create calendar events, invite attendees, and book meeting rooms via natural language.

Use case

Users in Feishu group chats want to say things like:

邀请群里的所有人,预定一个2点的会议,标题:test

Currently the bot cannot do this because there is no calendar tool. The agent has to reply with manual instructions.

Proposed actions

ActionFeishu APIDescription
create_eventPOST /calendar/v4/calendars/:id/eventsCreate a calendar event with title, time, description
add_attendeesPOST /calendar/v4/calendars/:id/events/:id/attendeesInvite attendees by open_id/user_id
list_eventsGET /calendar/v4/calendars/:id/eventsList upcoming events
delete_eventDELETE /calendar/v4/calendars/:id/events/:idCancel an event
get_eventGET /calendar/v4/calendars/:id/events/:idGet event details

Implementation notes

  • Follow the same pattern as feishu_chat, feishu_doc, feishu_bitable etc.
  • The Lark SDK (@larksuiteoapi/node-sdk) already has client.calendar.calendarEvent.create() and related methods
  • Required Feishu bot permissions: calendar:calendar, calendar:calendar:readonly
  • Could combine with feishu_chat members action to resolve "invite everyone in the group" → get members → add as attendees
  • Register as feishu_calendar tool, controlled by tools.calendar in account config

Example flow

  1. User: "帮我预定明天下午3点的会议,邀请群里所有人,标题:周会"
  2. Agent calls feishu_chatmembers to get group member list
  3. Agent calls feishu_calendarcreate_event with title, time
  4. Agent calls feishu_calendaradd_attendees with member open_ids
  5. Agent replies: "已创建「周会」,时间:明天 15:00,已邀请 8 位群成员"

Environment

  • OpenClaw version: 2026.3.8
  • Feishu extension path: extensions/feishu/

extent analysis

Fix Plan

To implement the feishu_calendar tool, follow these steps:

  1. Install required dependencies: Ensure @larksuiteoapi/node-sdk is installed in your project.
  2. Create a new tool file: Create a new file feishu_calendar.js in the extensions/feishu/tools directory.
  3. Implement tool functions: Implement the required functions for the feishu_calendar tool, such as createEvent, addAttendees, listEvents, deleteEvent, and getEvent.

Example code for feishu_calendar.js:

const { Client } = require('@larksuiteoapi/node-sdk');

class FeishuCalendar {
  async createEvent(calendarId, title, time) {
    const client = new Client();
    const response = await client.calendar.calendarEvent.create({
      calendarId,
      summary: title,
      startTime: time,
      endTime: time,
    });
    return response.data;
  }

  async addAttendees(calendarId, eventId, attendeeOpenIds) {
    const client = new Client();
    const response = await client.calendar.calendarEvent.addAttendees({
      calendarId,
      eventId,
      attendees: attendeeOpenIds.map((openId) => ({ openId })),
    });
    return response.data;
  }

  // Implement other functions (listEvents, deleteEvent, getEvent) similarly
}

module.exports = FeishuCalendar;
  1. Register the tool: Register the feishu_calendar tool in the tools directory by adding a new file index.js with the following content:
module.exports = {
  calendar: require('./feishu_calendar'),
};
  1. Update account config: Update the account config to include the tools.calendar configuration.

Verification

To verify that the fix worked, test the feishu_calendar tool by creating a new calendar event and inviting attendees using the createEvent and addAttendees functions.

Example test code:

const FeishuCalendar = require('./feishu_calendar');

const calendarId = 'your_calendar_id';
const title = 'Test Event';
const time = '2026-03-16T15:00:00';
const attendeeOpenIds = ['attendee1_open_id', 'attendee2_open_id'];

const feishuCalendar = new FeishuCalendar();
feishuCalendar.createEvent(calendarId, title, time).then((eventId) => {
  feishuCalendar.addAttendees(calendarId, eventId, attendeeOpenIds).then(() => {
    console.log('Event created and attendees added successfully');
  });
});

Extra Tips

  • Ensure that the Feishu bot has the required permissions (calendar:calendar, calendar:calendar:readonly) to create and manage calendar events

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING