# Logistics OTIF Calculator AI Agent Connect

> Logistics OTIF Calculator MCP gives your AI client the ability to calculate On-Time In-Full performance for your supply chain. It compares delivery dates against promises and checks if the quantity received matches what was ordered, while respecting your specific tolerance windows for time and volume.

## Overview
- **Category:** supply-chain
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_pqM2AG9zu2tnIQ1SjtNhJMKLWh0UP0fvTJzFV81O/ai-agent-connect
- **Tags:** otif, logistics, supply-chain, performance, metrics

## Description

You can stop manually auditing delivery logs to find where your supply chain is failing. This MCP lets your AI agent handle the math for On-Time In-Full (OTIF) metrics, which is the standard for measuring if a shipment arrived when it was supposed to and with the right amount of product. Instead of digging through spreadsheets, you just give your agent the order data and your preferred tolerance levels. It handles the logic of whether a shipment is considered "on time" based on your specific time windows or "in full" based on your quantity thresholds. It also catches data errors that would otherwise mess up your reporting. You can look at a single order, run a summary for a whole batch of shipments, or pull a specific report on where you are seeing shortages. It turns raw logistics data into clear performance numbers.

## Tools

### check_order_ambiguity
This tool checks if an order's data contains logical contradictions. It ensures your delivery dates and quantities make sense before you run calculations.

### get_batch_otif_summary
This tool aggregates performance metrics across a collection of orders. Use it to see how a group of shipments performed as a whole.

### get_shortage_report
This tool provides a detailed breakdown of orders that failed the In-Full requirement. It identifies exactly where quantity deficits occurred.

### get_order_otif_performance
This tool calculates the complete OTIF performance profile for a specific order. It evaluates both timing and quantity accuracy for a single shipment.

## Prompt Examples

**Prompt:** 
```
Calculate the OTIF performance for order ORD-123. It was promised for 2024-05-01, delivered on 2024-05-02, ordered 100 units, and 95 were delivered. Use a 2-day tolerance and 5% quantity tolerance.
```

**Response:** 
```
The order ORD-123 was On-Time and In-Full. The OTIF rate is 100% because the delivery was within the 2-day tolerance and the 5% quantity tolerance.
```

**Prompt:** 
```
Give me a summary of OTIF performance for orders ORD-001, ORD-002, and ORD-003.
```

**Response:** 
```
The batch summary for the requested orders shows a total of 3 orders processed with an average OTIF rate of 66.67%.
```

**Prompt:** 
```
Check if the data for an order with promised date 2024-06-01 and actual delivery 2024-05-20 is valid.
```

**Response:** 
```
The data is valid and consistent for calculation.
```

## Capabilities

### OTIF Calculation
Your agent calculates if orders meet both timing and quantity requirements.

### Tolerance Management
The AI applies custom time and quantity windows to determine pass/fail status.

### Batch Aggregation
Your agent summarizes performance across multiple orders at once.

### Data Validation
The agent checks for logical contradictions in order data before processing.

### Shortage Identification
The AI generates reports specifically for orders that missed quantity targets.

## Use Cases

### Carrier Performance Review
Analyze a batch of orders to see which carriers are meeting their delivery windows.

### Inventory Shortage Analysis
Use shortage reports to see how often suppliers are failing to deliver full quantities.

### Data Integrity Audits
Run ambiguity checks to ensure shipment records don't have conflicting dates or amounts.

### Daily KPI Reporting
Ask your agent to calculate the daily OTIF rate based on the last 24 hours of deliveries.

## Benefits

- Automates the math for time and quantity tolerance windows.
- Identifies specific quantity deficits through shortage reporting.
- Validates order data to prevent calculation errors.
- Aggregates individual order data into batch summaries.

## How It Works

Connect your client to Vinkius and start querying your logistics data immediately.

1. Connect your MCP-compatible client to Vinkius.
2. Provide your order data or shipment logs to your AI agent.
3. Define your specific time and quantity tolerance windows.
4. The agent uses the MCP tools to calculate metrics or generate reports.

## Frequently Asked Questions

**How does this MCP handle delivery delays?**
It compares the actual delivery date against the promised date using a configurable tolerance window you define in your prompt.

**Can I calculate OTIF for a single order?**
Yes, you can use the get_order_otif_performance tool to get a full performance profile for one specific order.

**What happens if my order data is inconsistent?**
The check_order_ambiguity tool identifies logical contradictions in your data to ensure your calculations remain accurate.

**How do I see which orders had missing items?**
You can use the get_shortage_report tool to get a detailed breakdown of orders that failed the In-Full requirement.

**Does this work with Claude or Cursor?**
Yes, this MCP is ready to use with any MCP-compatible client like Claude, Cursor, or Windsurf.

**What is OTIF?**
OTIF stands for On-Time In-Full. It is a key performance indicator that measures whether a delivery arrived on the promised date and contained the correct quantity.

**How are tolerance windows handled?**
You can provide `toleranceDays` to allow for minor delays or `quantityTolerancePercent` to allow for minor quantity deviations before an order is flagged as late or short.

**Can I analyze multiple orders at once?**
Yes, use the `get_batch_otif_summary` tool to aggregate performance metrics like average OTIF and total shortages across a list of order IDs.
