You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@stacklabdigital/chatwoot-mcp

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stacklabdigital/chatwoot-mcp - npm Package Compare versions

Comparing version

to
1.0.1

21

build/index.js

@@ -218,12 +218,15 @@ #!/usr/bin/env node

const config = {};
for (let i = 0; i < args.length; i += 2) {
for (let i = 0; i < args.length; i++) {
const flag = args[i];
const value = args[i + 1];
switch (flag) {
case '--url':
if (flag === '--stdio') {
config.stdio = true;
continue;
}
if (flag === '--url' || flag === '--token') {
const value = args[i + 1];
if (flag === '--url')
config.baseUrl = value;
break;
case '--token':
if (flag === '--token')
config.apiKey = value;
break;
i++; // Skip next argument as it's the value
}

@@ -237,4 +240,4 @@ }

if (!config.baseUrl || !config.apiKey) {
console.error('Uso: npx @seu-usuario/chatwoot-mcp --url <URL_BASE> --token <API_TOKEN>');
console.error('Exemplo: npx @seu-usuario/chatwoot-mcp --url https://app.chatwoot.com --token seu-token-api');
console.error('Uso: npx @stacklabdigital/chatwoot-mcp --url <URL_BASE> --token <API_TOKEN> [--stdio]');
console.error('Exemplo: npx @stacklabdigital/chatwoot-mcp --url https://app.chatwoot.com --token seu-token-api --stdio');
process.exit(1);

@@ -241,0 +244,0 @@ }

{
"name": "@stacklabdigital/chatwoot-mcp",
"version": "1.0.0",
"version": "1.0.1",
"description": "Servidor MCP para interagir com a API do Chatwoot",

@@ -5,0 +5,0 @@ "main": "build/index.js",

@@ -259,16 +259,18 @@ #!/usr/bin/env node

const args = process.argv.slice(2);
const config: Partial<ChatwootConfig> = {};
const config: Partial<ChatwootConfig> & { stdio?: boolean } = {};
for (let i = 0; i < args.length; i += 2) {
for (let i = 0; i < args.length; i++) {
const flag = args[i];
const value = args[i + 1];
switch (flag) {
case '--url':
config.baseUrl = value;
break;
case '--token':
config.apiKey = value;
break;
if (flag === '--stdio') {
config.stdio = true;
continue;
}
if (flag === '--url' || flag === '--token') {
const value = args[i + 1];
if (flag === '--url') config.baseUrl = value;
if (flag === '--token') config.apiKey = value;
i++; // Skip next argument as it's the value
}
}

@@ -284,4 +286,4 @@

if (!config.baseUrl || !config.apiKey) {
console.error('Uso: npx @seu-usuario/chatwoot-mcp --url <URL_BASE> --token <API_TOKEN>');
console.error('Exemplo: npx @seu-usuario/chatwoot-mcp --url https://app.chatwoot.com --token seu-token-api');
console.error('Uso: npx @stacklabdigital/chatwoot-mcp --url <URL_BASE> --token <API_TOKEN> [--stdio]');
console.error('Exemplo: npx @stacklabdigital/chatwoot-mcp --url https://app.chatwoot.com --token seu-token-api --stdio');
process.exit(1);

@@ -288,0 +290,0 @@ }