ProMql5/bunker-pricing-mcp
If you are the rightful owner of bunker-pricing-mcp 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 Bunker Fuel Pricing MCP Server is a serverless application designed to provide advanced bunker fuel pricing calculations and port management, integrated with OpenAI's Assistant for natural language interactions.
Bunker Fuel Pricing MCP Server
Vercel'de çalışan bunker yakıt fiyatlama sistemi için MCP (Model Context Protocol) server. OpenAI Assistant ile doğrudan entegrasyon.
🚀 Özellikler
- Bunker Fuel Pricing: Gelişmiş fiyat hesaplama algoritması
- Port Management: 20+ liman için detaylı ücret bilgileri
- Vehicle Optimization: TIR (25t) ve Kırkayak (20t) araç optimizasyonu
- MCP Protocol: AI assistant'lar ile doğal dil etkileşimi
- Serverless: Vercel Functions ile otomatik ölçeklendirme
- OpenAI Integration: Doğrudan OpenAI Assistant bağlantısı
📋 Gereksinimler
- Python 3.8+
- Vercel hesabınız
- OpenAI API erişimi
🛠 Kurulum ve Deploy
1. Repository'yi Hazırlayın
# Repository'yi klonla
git clone <your-repo-url>
cd bunker-pricing-mcp
# Dependencies yükle (local test için)
pip install -r requirements.txt
2. Vercel'e Deploy
# Vercel CLI kur (eğer yoksa)
npm install -g vercel
# Login
vercel login
# Deploy
vercel --prod
# Veya manual deploy için
vercel
3. OpenAI Assistant Entegrasyonu
Vercel deployment tamamlandıktan sonra, OpenAI Assistant'ınızda MCP server URL'ini kullanın:
https://your-project.vercel.app/api/mcp
Manuel Test
from bunker_pricer_simple import process_order
result = process_order("sipariş 60, port dikili, platts 655.25, kar 10, kur 40")
print(result)
🛠 Kullanılabilir Araçlar
1. calculate_bunker_price
Bunker yakıt fiyatı hesapla
Parametreler:
order_text
: Sipariş metni (örn: "sipariş 60, port dikili, platts 655.25, kar 10, kur 40")
2. get_port_info
Liman bilgilerini al
Parametreler:
port_name
: Liman adı (örn: dikili, kuşadası)
3. plan_vehicle_distribution
Araç planlama hesapla
Parametreler:
tonnage
: Toplam tonaj
📊 Hesaplama Detayları
Araç Kapasiteleri
- TIR: 25 ton
- Kırkayak: 20 ton
Premium Hesaplama
- ≤40 ton: 117 USD/ton
- >40 ton: 114 USD/ton
Örnek Hesaplama
# 60 ton, Dikili limanı, Platts 655.25 USD/ton, %10 kar, 40 TRY/USD
order = "sipariş 60, port dikili, platts 655.25, kar 10, kur 40"
result = process_order(order)
print(result)
Çıktı:
*Sipariş Detayları:*
- Tonaj: 60 ton
- Port: Dikili
- Platts Fiyatı: 655.25 USD/ton
- Kar Marjı: 10 USD/ton
- Döviz Kuru: 40 TRY/USD
*Hesaplama Detayları*
- Platts: 655,25 USD
- Premium: 114,00 USD
- Nakliye: 17,39 USD (2 TIR + 1 Kırkayak)
- Liman: 10,00 USD
- Kâr Marjı: 10,00 USD
- *Ton başına toplam fiyat:* *806,64 USD*
*OFFER*
---------------------------------
| Usd/Pmt | 807 |
| Delivery Method | Via Truck |
| Payment Term | 30 days |
| Delivery Port | Dikili |
---------------------------------
Note: the vessel should stay at port at least
2 days after berthing for healthy supply.
Subject to weather conditions and custom
permissions.
🔧 Yapılandırma
Environment Variables (Opsiyonel)
Vercel'de environment variable'lar otomatik olarak yüklenir:
# Port veri dosyası yolu (varsayılan: port-transport-fees.json)
PORT_DATA_PATH=port-transport-fees.json
OpenAI Assistant MCP Yapılandırması
OpenAI Assistant'ınızda MCP server'ı kullanmak için:
{
"mcpServers": {
"bunker-pricer": {
"url": "https://your-project.vercel.app/api/mcp"
}
}
}
📁 Proje Yapısı
bunker-pricing-mcp/
├── api/
│ ├── mcp.py # Vercel MCP API endpoint
│ └── health.py # Health check endpoint
├── bunker_pricer_simple.py # Ana hesaplama motoru
├── port-transport-fees.json # Liman ücretleri veritabanı
├── requirements.txt # Python dependencies
├── vercel.json # Vercel konfigürasyonu
└── README.md # Bu dosya
🤝 Katkıda Bulunma
- Fork edin
- Feature branch oluşturun (
git checkout -b feature/amazing-feature
) - Commit edin (
git commit -m 'Add amazing feature'
) - Push edin (
git push origin feature/amazing-feature
) - Pull Request oluşturun
📄 Lisans
Bu proje MIT lisansı altında lisanslanmıştır.