apt_mobile_mcp_server

matr1xp/apt_mobile_mcp_server

3.1

If you are the rightful owner of apt_mobile_mcp_server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

The APTMobile MCP Server is a Model Context Protocol server that integrates AI assistants with APTMobile's inventory management system, enabling seamless interaction with product inventory for tasks like searching, updating, and reporting.

Tools
8
Resources
0
Prompts
0

APTMobile MCP Server

A Model Context Protocol (MCP) server that provides AI assistants with access to APTMobile's inventory management system. This allows AI tools like Claude Desktop to interact with your product inventory, perform searches, update quantities, and generate reports.

Features

🛠️ Tools Available

  • add_product - Add new products to inventory
  • update_product - Update existing product information
  • delete_product - Remove products from inventory
  • search_products - Search and filter products
  • update_quantity - Quickly update product quantities
  • update_price - Update product pricing
  • get_inventory_stats - Get comprehensive inventory statistics
  • get_product_set_summaries - View summaries by product category

📄 Resources Available

  • inventory_overview - Complete inventory overview with stats and summaries
  • product_details - Detailed information about specific products

Setup

1. Install Dependencies

cd mcp-server
npm install

2. Configure Environment

Copy the example environment file and configure your Firebase credentials:

cp .env.example .env

Edit .env with your Firebase project details:

FIREBASE_PROJECT_ID=your-firebase-project-id
FIREBASE_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\nYour private key here\n-----END PRIVATE KEY-----"
FIREBASE_CLIENT_EMAIL=your-service-account@your-project.iam.gserviceaccount.com
NODE_ENV=development

3. Build the Server

npm run build

4. Configure Claude Desktop

Add the MCP server to your Claude Desktop configuration. Edit your claude_desktop_config.json:

On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json On Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "aptmobile-inventory": {
      "command": "node",
      "args": ["/path/to/APTMobile/mcp-server/build/index.js"],
      "env": {
        "FIREBASE_PROJECT_ID": "your-firebase-project-id",
        "FIREBASE_PRIVATE_KEY": "-----BEGIN PRIVATE KEY-----\\nYour private key here\\n-----END PRIVATE KEY-----",
        "FIREBASE_CLIENT_EMAIL": "your-service-account@your-project.iam.gserviceaccount.com"
      }
    }
  }
}

Usage Examples

Adding a Product

Add a new product to my electronics inventory:
- Name: "iPhone 15 Pro"
- Description: "Latest iPhone model with Pro features"
- Price: 999.99
- Retail Price: 1199.99
- Quantity: 25
- Created by: john@example.com

Searching Products

Find all products in electronics category with quantity less than 10

Getting Inventory Stats

Show me overall inventory statistics including low stock items

Updating Quantities

Update the quantity of product ID "abc123" in electronics to 50 units

API Reference

Tools

add_product

Adds a new product to the inventory.

Parameters:

  • productSet (string) - Category/collection name
  • name (string) - Product name
  • description (string) - Product description
  • price (number) - Product price
  • retailPrice (number) - Retail price
  • priceSource (string) - Source of pricing information
  • currency (string) - Currency code (default: USD)
  • imageUrl (string, optional) - Product image URL
  • quantity (number) - Available quantity
  • metadata (string, optional) - Additional metadata
  • createdBy (string) - User email who created the product
search_products

Search and filter products in the inventory.

Parameters:

  • productSet (string, optional) - Filter by product category
  • name (string, optional) - Search by product name
  • priceRange (object, optional) - Filter by price range
    • min (number) - Minimum price
    • max (number) - Maximum price
  • quantityRange (object, optional) - Filter by quantity range
    • min (number) - Minimum quantity
    • max (number) - Maximum quantity
  • createdBy (string, optional) - Filter by creator
  • limit (number, optional) - Maximum results (default: 100)
update_product

Update an existing product's information.

Parameters:

  • productSet (string) - Product category
  • productId (string) - Product ID to update
  • updates (object) - Fields to update (partial ProductInventory)
  • updatedBy (string) - User email making the update

Resources

inventory://overview/{userEmail?}

Provides a comprehensive overview of the inventory including statistics and product set summaries.

product://{productSet}/{productId}

Returns detailed information about a specific product.

Development

Running in Development Mode

npm run dev

Testing the Server

You can test the server using the MCP Inspector:

npx @modelcontextprotocol/inspector node build/index.js

Product Sets

The server supports organizing products into different categories (product sets):

  • electronics
  • clothing
  • books
  • home-garden
  • toys-games
  • sports-outdoors
  • general-inventory

Security

  • All Firebase operations require proper authentication
  • User email tracking for audit trails
  • Input validation using Zod schemas
  • Environment variable configuration for sensitive data

Error Handling

The server includes comprehensive error handling for:

  • Firebase connection issues
  • Invalid input parameters
  • Missing products or collections
  • Authentication failures

Contributing

  1. Follow the existing code structure
  2. Add proper TypeScript types
  3. Include error handling
  4. Update documentation for new features
  5. Test with the MCP Inspector

License

MIT License - see the main APTMobile project for details.