Skip to main content
Glama
baskcart

W3Ship MCP Server

by baskcart

get_available_slots

Find available time slots for booking services at a specific location and date, displaying times, capacity, pricing, and activity types.

Instructions

Get available session time slots for a location on a given date. Returns times, capacity, pricing, and activity type. Works for any bookable service (VR, fitness, dining, salon, etc.).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
locationIdYesLocation ID (e.g. loc_downtown, loc_mall)
dateYesDate in YYYY-MM-DD format
activityIdNoOptional activity/service ID to filter slots

Implementation Reference

  • Implementation of the get_available_slots tool handler, which forwards the request to the W3Ship API.
    case 'get_available_slots': {
        const locationId = args?.locationId as string;
        const date = args?.date as string;
        const activityId = (args?.activityId || args?.gameId) as string | undefined;
    
        if (!locationId || !date) {
            return { content: [{ type: 'text', text: 'Error: locationId and date are required.' }], isError: true };
        }
    
        // Map activityId to gameId for the W3Ship API
        const slotsUrl = `${W3SHIP_API}/api/slots?locationId=${locationId}&date=${date}${activityId ? `&gameId=${activityId}` : ''}`;
        const slotsRes = await fetch(slotsUrl);
        const slotsData = await slotsRes.json();
    
        return { content: [{ type: 'text', text: JSON.stringify(slotsData, null, 2) }] };
    }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/baskcart/w3ship-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server