sienge-ecbiesek-mcp 1.2.1__tar.gz → 1.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of sienge-ecbiesek-mcp might be problematic. Click here for more details.
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/PKG-INFO +1 -1
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/pyproject.toml +1 -1
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/PKG-INFO +1 -1
- sienge_ecbiesek_mcp-1.2.2/src/sienge_mcp/__init__.py +9 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_mcp/server.py +55 -13
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_mcp/server2.py +55 -13
- sienge_ecbiesek_mcp-1.2.1/src/sienge_mcp/__init__.py +0 -9
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/COMO_TESTAR.md +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/GUIA_ATUALIZACAO.md +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/LICENSE +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/MANIFEST.in +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/PUBLICADO_PYPI.md +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/README.md +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/claude_desktop_config.template.json +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/requirements.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/setup.cfg +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/SOURCES.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/dependency_links.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/entry_points.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/requires.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/top_level.txt +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_mcp/metadata.py +0 -0
- {sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_mcp/utils/logger.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: sienge-ecbiesek-mcp
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.2
|
|
4
4
|
Summary: 🏗️ Model Context Protocol (MCP) server for Sienge API integration - Brazilian construction ERP system. Connect Claude AI to Sienge with 50+ powerful tools for comprehensive business management including financials, projects, and operations.
|
|
5
5
|
Author-email: ECBIESEK <ti@ecbiesek.com>
|
|
6
6
|
License: MIT
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "sienge-ecbiesek-mcp"
|
|
7
|
-
version = "1.2.
|
|
7
|
+
version = "1.2.2"
|
|
8
8
|
description = "🏗️ Model Context Protocol (MCP) server for Sienge API integration - Brazilian construction ERP system. Connect Claude AI to Sienge with 50+ powerful tools for comprehensive business management including financials, projects, and operations."
|
|
9
9
|
authors = [
|
|
10
10
|
{name = "ECBIESEK", email = "ti@ecbiesek.com"}
|
{sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: sienge-ecbiesek-mcp
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.2
|
|
4
4
|
Summary: 🏗️ Model Context Protocol (MCP) server for Sienge API integration - Brazilian construction ERP system. Connect Claude AI to Sienge with 50+ powerful tools for comprehensive business management including financials, projects, and operations.
|
|
5
5
|
Author-email: ECBIESEK <ti@ecbiesek.com>
|
|
6
6
|
License: MIT
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Sienge MCP Server Package
|
|
3
|
+
Model Context Protocol integration for Sienge API
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
__version__ = "1.2.2"
|
|
7
|
+
__author__ = "ECBIESEK"
|
|
8
|
+
__email__ = "ti@ecbiesek.com"
|
|
9
|
+
__description__ = "🏗️ Model Context Protocol (MCP) server for Sienge API integration - Brazilian construction ERP system"
|
|
@@ -2494,13 +2494,50 @@ async def search_sienge_financial_data(
|
|
|
2494
2494
|
}
|
|
2495
2495
|
|
|
2496
2496
|
|
|
2497
|
+
async def _svc_test_connection() -> Dict:
|
|
2498
|
+
"""Serviço interno: testar conexão com a API do Sienge"""
|
|
2499
|
+
try:
|
|
2500
|
+
# Usar serviço interno
|
|
2501
|
+
result = await _svc_get_customer_types()
|
|
2502
|
+
|
|
2503
|
+
if result["success"]:
|
|
2504
|
+
auth_method = "Bearer Token" if SIENGE_API_KEY else "Basic Auth"
|
|
2505
|
+
return {
|
|
2506
|
+
"success": True,
|
|
2507
|
+
"message": "✅ Conexão com API do Sienge estabelecida com sucesso!",
|
|
2508
|
+
"api_status": "Online",
|
|
2509
|
+
"auth_method": auth_method,
|
|
2510
|
+
"timestamp": datetime.now().isoformat(),
|
|
2511
|
+
"request_id": result.get("request_id"),
|
|
2512
|
+
"latency_ms": result.get("latency_ms"),
|
|
2513
|
+
"cache": result.get("cache")
|
|
2514
|
+
}
|
|
2515
|
+
else:
|
|
2516
|
+
return {
|
|
2517
|
+
"success": False,
|
|
2518
|
+
"message": "❌ Falha ao conectar com API do Sienge",
|
|
2519
|
+
"error": result.get("error"),
|
|
2520
|
+
"details": result.get("message"),
|
|
2521
|
+
"timestamp": datetime.now().isoformat(),
|
|
2522
|
+
"request_id": result.get("request_id")
|
|
2523
|
+
}
|
|
2524
|
+
except Exception as e:
|
|
2525
|
+
return {
|
|
2526
|
+
"success": False,
|
|
2527
|
+
"message": "❌ Erro ao testar conexão",
|
|
2528
|
+
"error": str(e),
|
|
2529
|
+
"timestamp": datetime.now().isoformat(),
|
|
2530
|
+
}
|
|
2531
|
+
|
|
2532
|
+
|
|
2497
2533
|
@mcp.tool
|
|
2498
|
-
async def
|
|
2499
|
-
"""
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2534
|
+
async def test_sienge_connection(_meta: Optional[Dict] = None) -> Dict:
|
|
2535
|
+
"""Testa a conexão com a API do Sienge"""
|
|
2536
|
+
return await _svc_test_connection()
|
|
2537
|
+
|
|
2538
|
+
|
|
2539
|
+
async def _svc_get_dashboard_summary() -> Dict:
|
|
2540
|
+
"""Serviço interno: obter resumo do dashboard"""
|
|
2504
2541
|
# Data atual e períodos
|
|
2505
2542
|
today = datetime.now()
|
|
2506
2543
|
current_month_start = today.replace(day=1).strftime("%Y-%m-%d")
|
|
@@ -2511,7 +2548,7 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2511
2548
|
|
|
2512
2549
|
# 1. Testar conexão
|
|
2513
2550
|
try:
|
|
2514
|
-
connection_test = await
|
|
2551
|
+
connection_test = await _svc_test_connection()
|
|
2515
2552
|
dashboard_data["connection"] = connection_test
|
|
2516
2553
|
except Exception as e:
|
|
2517
2554
|
errors.append(f"Teste de conexão: {str(e)}")
|
|
@@ -2519,16 +2556,14 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2519
2556
|
|
|
2520
2557
|
# 2. Contar clientes (amostra)
|
|
2521
2558
|
try:
|
|
2522
|
-
# CORRIGIDO: Usar serviço interno
|
|
2523
2559
|
customers_result = await _svc_get_customers(limit=1)
|
|
2524
|
-
dashboard_data["
|
|
2560
|
+
dashboard_data["customers_available"] = customers_result["success"]
|
|
2525
2561
|
except Exception as e:
|
|
2526
2562
|
errors.append(f"Clientes: {str(e)}")
|
|
2527
|
-
dashboard_data["
|
|
2563
|
+
dashboard_data["customers_available"] = False
|
|
2528
2564
|
|
|
2529
2565
|
# 3. Contar projetos (amostra)
|
|
2530
2566
|
try:
|
|
2531
|
-
# CORRIGIDO: Usar serviço interno
|
|
2532
2567
|
projects_result = await _svc_get_projects(limit=5)
|
|
2533
2568
|
if projects_result["success"]:
|
|
2534
2569
|
data = projects_result["data"]
|
|
@@ -2548,7 +2583,6 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2548
2583
|
|
|
2549
2584
|
# 4. Títulos a pagar do mês atual
|
|
2550
2585
|
try:
|
|
2551
|
-
# CORRIGIDO: Usar serviço interno
|
|
2552
2586
|
bills_result = await _svc_get_bills(
|
|
2553
2587
|
start_date=current_month_start,
|
|
2554
2588
|
end_date=current_month_end,
|
|
@@ -2572,7 +2606,6 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2572
2606
|
|
|
2573
2607
|
# 5. Tipos de clientes
|
|
2574
2608
|
try:
|
|
2575
|
-
# CORRIGIDO: Usar serviço interno
|
|
2576
2609
|
customer_types_result = await _svc_get_customer_types()
|
|
2577
2610
|
if customer_types_result["success"]:
|
|
2578
2611
|
data = customer_types_result["data"]
|
|
@@ -2609,6 +2642,15 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2609
2642
|
}
|
|
2610
2643
|
|
|
2611
2644
|
|
|
2645
|
+
@mcp.tool
|
|
2646
|
+
async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
2647
|
+
"""
|
|
2648
|
+
Obtém um resumo tipo dashboard com informações gerais do Sienge
|
|
2649
|
+
Útil para visão geral rápida do sistema
|
|
2650
|
+
"""
|
|
2651
|
+
return await _svc_get_dashboard_summary()
|
|
2652
|
+
|
|
2653
|
+
|
|
2612
2654
|
# ============ UTILITÁRIOS ============
|
|
2613
2655
|
|
|
2614
2656
|
|
|
@@ -2494,13 +2494,50 @@ async def search_sienge_financial_data(
|
|
|
2494
2494
|
}
|
|
2495
2495
|
|
|
2496
2496
|
|
|
2497
|
+
async def _svc_test_connection() -> Dict:
|
|
2498
|
+
"""Serviço interno: testar conexão com a API do Sienge"""
|
|
2499
|
+
try:
|
|
2500
|
+
# Usar serviço interno
|
|
2501
|
+
result = await _svc_get_customer_types()
|
|
2502
|
+
|
|
2503
|
+
if result["success"]:
|
|
2504
|
+
auth_method = "Bearer Token" if SIENGE_API_KEY else "Basic Auth"
|
|
2505
|
+
return {
|
|
2506
|
+
"success": True,
|
|
2507
|
+
"message": "✅ Conexão com API do Sienge estabelecida com sucesso!",
|
|
2508
|
+
"api_status": "Online",
|
|
2509
|
+
"auth_method": auth_method,
|
|
2510
|
+
"timestamp": datetime.now().isoformat(),
|
|
2511
|
+
"request_id": result.get("request_id"),
|
|
2512
|
+
"latency_ms": result.get("latency_ms"),
|
|
2513
|
+
"cache": result.get("cache")
|
|
2514
|
+
}
|
|
2515
|
+
else:
|
|
2516
|
+
return {
|
|
2517
|
+
"success": False,
|
|
2518
|
+
"message": "❌ Falha ao conectar com API do Sienge",
|
|
2519
|
+
"error": result.get("error"),
|
|
2520
|
+
"details": result.get("message"),
|
|
2521
|
+
"timestamp": datetime.now().isoformat(),
|
|
2522
|
+
"request_id": result.get("request_id")
|
|
2523
|
+
}
|
|
2524
|
+
except Exception as e:
|
|
2525
|
+
return {
|
|
2526
|
+
"success": False,
|
|
2527
|
+
"message": "❌ Erro ao testar conexão",
|
|
2528
|
+
"error": str(e),
|
|
2529
|
+
"timestamp": datetime.now().isoformat(),
|
|
2530
|
+
}
|
|
2531
|
+
|
|
2532
|
+
|
|
2497
2533
|
@mcp.tool
|
|
2498
|
-
async def
|
|
2499
|
-
"""
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2534
|
+
async def test_sienge_connection(_meta: Optional[Dict] = None) -> Dict:
|
|
2535
|
+
"""Testa a conexão com a API do Sienge"""
|
|
2536
|
+
return await _svc_test_connection()
|
|
2537
|
+
|
|
2538
|
+
|
|
2539
|
+
async def _svc_get_dashboard_summary() -> Dict:
|
|
2540
|
+
"""Serviço interno: obter resumo do dashboard"""
|
|
2504
2541
|
# Data atual e períodos
|
|
2505
2542
|
today = datetime.now()
|
|
2506
2543
|
current_month_start = today.replace(day=1).strftime("%Y-%m-%d")
|
|
@@ -2511,7 +2548,7 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2511
2548
|
|
|
2512
2549
|
# 1. Testar conexão
|
|
2513
2550
|
try:
|
|
2514
|
-
connection_test = await
|
|
2551
|
+
connection_test = await _svc_test_connection()
|
|
2515
2552
|
dashboard_data["connection"] = connection_test
|
|
2516
2553
|
except Exception as e:
|
|
2517
2554
|
errors.append(f"Teste de conexão: {str(e)}")
|
|
@@ -2519,16 +2556,14 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2519
2556
|
|
|
2520
2557
|
# 2. Contar clientes (amostra)
|
|
2521
2558
|
try:
|
|
2522
|
-
# CORRIGIDO: Usar serviço interno
|
|
2523
2559
|
customers_result = await _svc_get_customers(limit=1)
|
|
2524
|
-
dashboard_data["
|
|
2560
|
+
dashboard_data["customers_available"] = customers_result["success"]
|
|
2525
2561
|
except Exception as e:
|
|
2526
2562
|
errors.append(f"Clientes: {str(e)}")
|
|
2527
|
-
dashboard_data["
|
|
2563
|
+
dashboard_data["customers_available"] = False
|
|
2528
2564
|
|
|
2529
2565
|
# 3. Contar projetos (amostra)
|
|
2530
2566
|
try:
|
|
2531
|
-
# CORRIGIDO: Usar serviço interno
|
|
2532
2567
|
projects_result = await _svc_get_projects(limit=5)
|
|
2533
2568
|
if projects_result["success"]:
|
|
2534
2569
|
data = projects_result["data"]
|
|
@@ -2548,7 +2583,6 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2548
2583
|
|
|
2549
2584
|
# 4. Títulos a pagar do mês atual
|
|
2550
2585
|
try:
|
|
2551
|
-
# CORRIGIDO: Usar serviço interno
|
|
2552
2586
|
bills_result = await _svc_get_bills(
|
|
2553
2587
|
start_date=current_month_start,
|
|
2554
2588
|
end_date=current_month_end,
|
|
@@ -2572,7 +2606,6 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2572
2606
|
|
|
2573
2607
|
# 5. Tipos de clientes
|
|
2574
2608
|
try:
|
|
2575
|
-
# CORRIGIDO: Usar serviço interno
|
|
2576
2609
|
customer_types_result = await _svc_get_customer_types()
|
|
2577
2610
|
if customer_types_result["success"]:
|
|
2578
2611
|
data = customer_types_result["data"]
|
|
@@ -2609,6 +2642,15 @@ async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
|
2609
2642
|
}
|
|
2610
2643
|
|
|
2611
2644
|
|
|
2645
|
+
@mcp.tool
|
|
2646
|
+
async def get_sienge_dashboard_summary(_meta: Optional[Dict] = None) -> Dict:
|
|
2647
|
+
"""
|
|
2648
|
+
Obtém um resumo tipo dashboard com informações gerais do Sienge
|
|
2649
|
+
Útil para visão geral rápida do sistema
|
|
2650
|
+
"""
|
|
2651
|
+
return await _svc_get_dashboard_summary()
|
|
2652
|
+
|
|
2653
|
+
|
|
2612
2654
|
# ============ UTILITÁRIOS ============
|
|
2613
2655
|
|
|
2614
2656
|
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
"""
|
|
2
|
-
Sienge MCP Server Package
|
|
3
|
-
Model Context Protocol integration for Sienge API
|
|
4
|
-
"""
|
|
5
|
-
|
|
6
|
-
__version__ = "1.0.0"
|
|
7
|
-
__author__ = "Sienge MCP Contributors"
|
|
8
|
-
__email__ = "contributors@sienge-mcp.com"
|
|
9
|
-
__description__ = "Sienge MCP Server - Model Context Protocol integration for Sienge API"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sienge_ecbiesek_mcp-1.2.1 → sienge_ecbiesek_mcp-1.2.2}/src/sienge_ecbiesek_mcp.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|