Get started

Get up and running with our API in minutes.

The Lune API is a RESTful API that is built on top of LLM providers like OpenAI and Anthropic that allows you to access Lunes and Tycho Agent through HTTP requests.

Information:

The API is in beta, and only available for Pro users.

API Keys

The LuneAI API uses API keys for authentication.

1: Getting your keys

Navigate to your profile and click Generate to get your API key.

2: Include your API key in your header

Make sure all API requests have the following Authorization header:

Authorization: Bearer LUNE_API_KEY

Example Request

curl https://api.lune.dev/chat/completions \
   -H "Content-Type: application/json" \
   -H "Authorization: Bearer $LUNE_API_KEY" \
   -d '{
         "messages": [
           {"role": "user", "content": "What is the format of the AIMessageChunk object in Langchain?"}
         ],
         "model": "tycho",
         "stream": true
       }'