> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ragbuddy.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Endpoint Selection

> This section outlines the steps and best practices for integrating and utilizing RAG-Buddy within your RAG pipeline. The first step is to choose the right endpoint.

<Tip>Before integrating RAG-Buddy into your LLM pipeline, ensure you have [set up a project](/guidebook/setting-up) in the SaaS portal and have an API key ready.</Tip>

## API Endpoint types

This section will help you choose the right endpoint. RAG-Buddy currently offers two type of endpoints:

* Proxy Endpoints, start with `https://api.ragbuddy.ai/proxy`
* REST API Endpoints, start with `https://api.ragbuddy.ai`

## API Endpoints

As we currently support two use cases for integrating RAG-Buddy into your LLM pipeline, we offer two endpoints per endpoint type:

* Proxy endpoint for RAG+C: `https://api.ragbuddy.ai/proxy/ragc`
* REST API endpoint for RAG+C: `https://api.ragbuddy.ai/ragc`
* Proxy endpoint for Text-classification: `https://api.ragbuddy.ai/proxy/tc`
* REST API endpoint for Text-classification: `https://api.ragbuddy.ai/tc`

### Understanding the Differences

#### Proxy Endpoint

The Proxy Endpoint acts as a direct substitute for your existing LLM URL. It's designed to intercept calls to the LLM and augment them with RAG-Buddy capabilities.

#### REST API Endpoint

The REST API Endpoint is a more versatile and powerful interface. It allows explicit data handling and offers more control over how you interact with RAG-Buddy. The response from the endpoint is a JSON object with a predictable data structure.

### Pros and Cons

#### Proxy Endpoint

* **Pros**: Easy to implement, minimal changes required in existing setup.
* **Cons**: Less flexibility, reliant on the structure of the original LLM calls. More difficult to adhere to the required message template format.

#### REST API Endpoint

* **Pros**: Greater control, allows for more complex interactions and is less sensitive to LLM messages formatting.
* **Cons**: Requires more setup and understanding of the API.

### Recommended for Production

For production environments, we recommend using the REST API Endpoint. It offers a robust set of features and flexibility, allowing you to fully leverage the capabilities of RAG-Buddy in diverse scenarios.
