MGZon Logo

About MGZon AI by Mark Al-Asfar

MGZon Chatbot API Documentation

Integrate MGZon Chatbot's AI-powered features into your applications. Learn how to use our APIs for code generation, web search, and e-commerce solutions.

Explore the MGZon Chatbot API for seamless integration of AI-powered code generation, text generation, and e-commerce automation. Built by Mark Al-Asfar using FastAPI and Hugging Face AI.

Get API Key

API Overview

The MGZon Chatbot API provides endpoints for code generation, real-time web search, and e-commerce functionalities. Built with FastAPI, it offers secure and scalable integration.

Base URL: https://mgzon-mgzon-app.hf.space/api

Authentication

Use JWT tokens for authentication. Register or login to obtain a token.


curl -X POST "https://mgzon-mgzon-app.hf.space/auth/jwt/login" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "username=your_email&password=your_password"
          

Endpoints

/chat (POST)

Interact with the AI chatbot for code generation or queries.


curl -X POST "https://mgzon-mgzon-app.hf.space/chat" \
  -H "Authorization: Bearer your_token" \
  -H "Content-Type: application/json" \
  -d '{"message": "Generate a Python function"}'
            

/web_search (POST)

Perform real-time web searches.


curl -X POST "https://mgzon-mgzon-app.hf.space/web_search" \
  -H "Authorization: Bearer your_token" \
  -H "Content-Type: application/json" \
  -d '{"query": "AI trends 2025"}'
            

Getting Started

1. Register at /register.

2. Obtain your API key from xAI API.

3. Use the endpoints above to integrate MGZon Chatbot into your application.