DEV Community

q2408808
q2408808

Posted on

Brazilian MCP Server + AI Generation APIs: Tutorial for BR Developers

mcp-brasil just hit 373 stars in days on GitHub. Brazilian developers are building MCP servers at an incredible pace — and there's a powerful missing piece.

mcp-brasil wraps 27 Brazilian public APIs (CNPJ, CEP, IBGE, and more) for AI agents. It's great for fetching data. But what about generating content from that data?

That's where NexaAPI comes in — 56+ AI models, $0.003/image.

The Combination

  • mcp-brasil → Fetch city data from IBGE
  • NexaAPI → Generate a stunning AI image of that city
# pip install nexaapi
from nexaapi import NexaAPI

client = NexaAPI(api_key='YOUR_API_KEY')  # Free key: https://nexa-api.com

# Data fetched from mcp-brasil IBGE endpoint
city_name = 'São Paulo'

response = client.image.generate(
    model='flux-schnell',
    prompt=f'Beautiful aerial view of {city_name}, Brazil, vibrant colors, photorealistic, 4K',
    width=1024, height=1024
)
print(f'Image: {response.url} | Cost: $0.003')

# TTS in Brazilian Portuguese
audio = client.audio.tts(
    text=f'Bem-vindo a {city_name}! Esta cidade tem uma população incrível.',
    voice='pt-BR-female', language='pt-BR'
)
print(f'Audio: {audio.url}')
Enter fullscreen mode Exit fullscreen mode

JavaScript (Node.js)

// npm install nexaapi
import NexaAPI from 'nexaapi';
const client = new NexaAPI({ apiKey: 'YOUR_API_KEY' });

async function generateBrazilianContent({ city, state }) {
  const image = await client.image.generate({
    model: 'flux-schnell',
    prompt: `Stunning cityscape of ${city}, ${state}, Brazil, golden hour, photorealistic`,
    width: 1024, height: 1024
  });
  console.log(`Image: ${image.url} | Cost: $0.003`);

  const video = await client.video.generate({
    model: 'kling-v1',
    prompt: `Cinematic tour of ${city}, Brazil, drone footage, 4K`,
    duration: 5
  });
  console.log(`Video: ${video.url}`);
}

generateBrazilianContent({ city: 'Rio de Janeiro', state: 'RJ' });
Enter fullscreen mode Exit fullscreen mode

Why NexaAPI?

Feature NexaAPI Competitors
Price/image $0.003 $0.02-0.08
Models 56+ 1-5
Video gen ❌ most
Audio/TTS ❌ most
Free tier ✅ 100 calls Limited

Get Started

The Brazilian dev community is building fast. mcp-brasil + NexaAPI = complete stack. 🇧🇷🚀


Reference: github.com/jxnxts/mcp-brasil | Verified: 2026-03-27

Top comments (0)