import { AcuityClient } from '../clients/acuity.js';

export const calendarTools = [
  {
    name: 'acuity_list_calendars',
    description: 'List all calendars',
    inputSchema: {
      type: 'object',
      properties: {},
    },
    handler: async (args: any, client: AcuityClient) => {
      const calendars = await client.getCalendars();
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(calendars, null, 2),
          },
        ],
      };
    },
  },
  {
    name: 'acuity_get_calendar',
    description: 'Get a specific calendar by ID',
    inputSchema: {
      type: 'object',
      properties: {
        id: {
          type: 'number',
          description: 'Calendar ID',
        },
      },
      required: ['id'],
    },
    handler: async (args: any, client: AcuityClient) => {
      const calendar = await client.getCalendar(args.id);
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(calendar, null, 2),
          },
        ],
      };
    },
  },
];
