Euler
    HomeIntegrationsProductContact

    API Documentation

    Integrate Euler's AI-powered shopping assistant into your e-commerce platform.

    Preview. Available today: the embeddable chat widget (/api/widget) and the Chat API (/api/chat). The Search, Compare, and Cart APIs, the @euler/react package, and the API-key dashboard are on our roadmap and not yet generally available.

    Getting Started

    Euler provides a set of APIs that allow you to integrate our AI-powered shopping assistant into your e-commerce platform. Our APIs are RESTful and return JSON responses.

    To get started, you'll need an API key. You can obtain one by signing up for an account on our website and navigating to the API section of your dashboard.

    Authorization: Bearer YOUR_API_KEY

    Chat API

    The Chat API allows you to interact with our AI-powered shopping assistant. You can send messages and receive responses that help users find products, answer questions, and provide recommendations.

    POST /api/chat

    Request Body

    {
      "messages": [
        { "role": "user", "content": "Show me black boots under $200" }
      ]
    }

    Response

    {
      "id": "a1b2c3d4-5e6f-7890-abcd-ef1234567890",
      "role": "assistant",
      "content": "Here are a few black boots under $200 to consider..."
    }

    Integration Guide

    Integrating Euler into your e-commerce platform is easy. You can either use our pre-built components or build your own using our APIs.

    Option 1: Embed Script

    The easiest way to integrate Euler is to use our embed script. Simply add the following code to your website:

    <script>
      (function(w,d,s,o,f,js,fjs){
        w['EulerWidget']=o;w[o]=w[o]||function(){(w[o].q=w[o].q||[]).push(arguments)};
        js=d.createElement(s),fjs=d.getElementsByTagName(s)[0];
        js.id=o;js.src=f;js.async=1;fjs.parentNode.insertBefore(js,fjs);
      }(window,document,'script','euler','https://www.eulerai.app/api/widget'));
      euler('init', { apiKey: 'YOUR_API_KEY' });
    </script>

    Option 2: React Component

    If you're using React, you can use our React component:

    import { EulerChat } from '@euler/react';
    
    function App() {
      return (
        <div>
          <h1>My E-commerce Store</h1>
          <EulerChat apiKey="YOUR_API_KEY" />
        </div>
      );
    }

    Option 3: Custom Integration

    If you want more control over the integration, you can use our APIs directly:

    // Example: Sending a message to the Chat API
    async function sendMessage(message) {
      const response = await fetch('https://api.eulerai.app/chat', {
        method: 'POST',
        headers: {
          'Content-Type': 'application/json',
          'Authorization': 'Bearer YOUR_API_KEY'
        },
        body: JSON.stringify({ message })
      });
      
      return response.json();
    }

    Rate Limits

    Our API has rate limits to ensure fair usage and maintain service quality. The limits vary based on your subscription plan:

    • Free: 100 requests per day
    • Basic: 1,000 requests per day
    • Pro: 10,000 requests per day
    • Enterprise: Custom limits

    If you exceed your rate limit, you'll receive a 429 Too Many Requests response. The response will include a Retry-After header indicating how long you should wait before making another request.

    Error Handling

    Our API uses standard HTTP status codes to indicate the success or failure of a request. In case of an error, the response will include an error object with a message and code:

    {
      "error": {
        "code": "invalid_request",
        "message": "The request was invalid. Please check your parameters and try again."
      }
    }

    Common error codes include:

    • invalid_request: The request was malformed or missing required parameters
    • authentication_error: Invalid or missing API key
    • rate_limit_exceeded: You've exceeded your rate limit
    • server_error: An internal server error occurred

    Support

    If you have any questions or need help with our API, please contact our support team at api-support@eulerai.app or visit our contact page.

    © 2026 Euler AI. All rights reserved.