Skip to main content

Talk-To-My-Org-Chart: CLI MCP server for org chart queries.

Project description

Talk to My Org Chart - MCP Server

This is the MCP (Model Context Protocol) server for the "Talk to My Org Chart" service. It allows AI assistants to query organizational data through a set of standardized tools.

Overview

The MCP server provides a set of tools for querying organizational data, including:

  • Looking up employees by name or alias
  • Finding direct and indirect reports
  • Searching for employees by various criteria
  • Getting organizational metrics

Setup

Prerequisites

  • Python 3.9+
  • Azure AD tenant (for authentication)
  • Access to an organizational data source

Installation

pip install ttmoc

With environment variables:

  • WHO_NEXT_API_URL: The URL of your API server (e.g., http://localhost:8000)
  • AAD_TENANT_ID: Your Azure Active Directory tenant ID

Available Tools (API Functions)

Once the server is running, it exposes several tools for querying org chart data:

  • lookup_employee_by_name_or_alias: Look up employees by display name or alias.
  • lookup_direct_reports: Get direct reports for a manager.
  • find_all_reports_by_alias: Get all reports (direct and indirect) for a manager, with optional filtering. Note this will usually return a lot of results, so it's recommended to use limit to limit the number of results.
  • find_employees: Find employees across the entire organization by criteria (name, title, cost center, etc.). Note this will usually return a lot of results, so it's recommended to use limit to limit the number of results.
  • get_span_of_control_by_alias: Get span of control metrics for a manager. Span of control describes on average how many employees a manager has in the organization.
  • get_org_depth_by_alias: Get organizational depth metrics for an employee.
  • count_all_reports_by_alias: Count all reports (direct and indirect) for a manager, with optional filtering.
  • count_employees: Count employees by criteria across the entire organization.

Usage Examples

Looking up an Employee

result = await lookup_employee_by_name_or_alias(name_or_alias="John Doe")

Finding Direct Reports

reports = await lookup_direct_reports(alias="johndoe", limit=20)

Finding All Reports with Filtering

all_reports = await find_all_reports_by_alias(
    alias="johndoe",
    title="Software Engineer",
    limit=100
)

Counting Employees by Criteria

count = await count_employees(
    title="Product Manager",
    is_manager=True
)

Getting Organizational Metrics

span = await get_span_of_control_by_alias(alias="johndoe")
depth = await get_org_depth_by_alias(alias="johndoe")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ttmoc-0.1.8.tar.gz (12.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ttmoc-0.1.8-py3-none-any.whl (12.6 kB view details)

Uploaded Python 3

File details

Details for the file ttmoc-0.1.8.tar.gz.

File metadata

  • Download URL: ttmoc-0.1.8.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for ttmoc-0.1.8.tar.gz
Algorithm Hash digest
SHA256 9851d3fdc04179b74a308e7fc2e532d9d4afd99c4da762412f9e63a175f69b96
MD5 f19e99ef975de505bb62670787f0396c
BLAKE2b-256 c8874ad8a46efbccd564ed2c0fd2362bfaab4ab6d8cd24e361aaa1f637c4ed1f

See more details on using hashes here.

File details

Details for the file ttmoc-0.1.8-py3-none-any.whl.

File metadata

  • Download URL: ttmoc-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 12.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for ttmoc-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 2b6fd7d4b533e86c54083a272d3d00b8d26ff1ac4b07d8f9d2242a425d7864fc
MD5 e30f9264812d53dde7cf181fcb100762
BLAKE2b-256 51bc1758235efc317a6d6d771bef661cc9fa1ab56e48c5dd65160c5796082c6a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page