Skip to main content
Glama
NetSuite MCP Server

NetSuite MCP Server

by MikeGrande

NetSuite MCP Server

A Model Context Protocol (MCP) server for querying NetSuite sales orders and invoices with filtering capabilities.

Features

  • Query sales orders and invoices

  • Filter by customer, item, or date range

  • Get summary statistics

  • Customer and item-specific analysis

  • Sample data for testing and development

Related MCP server: SQLite MCP Server

Installation

  1. Install dependencies:

pip install -e .

Usage

Running the Server

python main.py

Or using the installed script:

netsuite-mcp

Available Tools

1. Query Sales Orders

{
  "name": "query_sales_orders",
  "arguments": {
    "customer_id": "cust_001",
    "customer_name": "John Smith",
    "item_id": "item_001",
    "item_name": "Widget",
    "status": "Fulfilled",
    "start_date": "2024-01-01T00:00:00Z",
    "end_date": "2024-12-31T23:59:59Z",
    "include_summary": true
  }
}

2. Query Invoices

{
  "name": "query_invoices",
  "arguments": {
    "customer_id": "cust_001",
    "status": "Outstanding",
    "include_summary": true
  }
}

3. Get Customer Summary

{
  "name": "get_customer_summary",
  "arguments": {
    "customer_name": "Acme Corp"
  }
}

4. Get Item Summary

{
  "name": "get_item_summary",
  "arguments": {
    "item_name": "Widget A"
  }
}

Available Resources

  • netsuite://sales-orders - All sales orders

  • netsuite://invoices - All invoices

  • netsuite://customers - All customers

  • netsuite://items - All items/products

Sample Data

The server includes sample data for testing:

  • Customers: Acme Corp, TechStart Inc, Retail Plus

  • Items: Widget A, Widget B, Service Pack, Gadget Pro

  • Sales Orders: 3 sample orders with different statuses

  • Invoices: 3 sample invoices linked to sales orders

Filter Options

All query tools support the following filters:

  • customer_id: Exact customer ID match

  • customer_name: Partial customer name match (case-insensitive)

  • item_id: Exact item ID match

  • item_name: Partial item name match (case-insensitive)

  • status: Exact status match

  • start_date: Filter records created after this date

  • end_date: Filter records created before this date

  • include_summary: Include summary statistics in response

Development

Project Structure

netsuite-mcp/
├── netsuite_mcp/
│   ├── __init__.py
│   ├── server.py          # Main MCP server implementation
│   ├── models.py          # Pydantic data models
│   ├── data_service.py    # Data querying and filtering logic
│   └── sample_data.py     # Sample data for testing
├── main.py                # Entry point
├── pyproject.toml         # Project configuration
└── README.md

Extending the Server

To add new functionality:

  1. Add new data models to models.py

  2. Extend the data service in data_service.py

  3. Add new tools or resources to server.py

License

MIT License

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      C
      quality
      D
      maintenance
      A Model Context Protocol server enabling product searches across e-commerce platforms, price history tracking, and product specification-based searches using natural language prompts.
      2
      142 PyPI
      19
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that provides database interaction capabilities through SQLite, enabling users to run SQL queries, analyze business data, and automatically generate business insight memos.
      19
      MIT
    • A
      license
      B
      quality
      D
      maintenance
      A comprehensive Model Context Protocol server for SQL Server database operations that provides 10 powerful tools for database analysis, object discovery, and data manipulation.
      11
      542 npm
      15
      MIT