serverless.md

Serverless

Make your first serverless API call in under two minutes. Serverless gives you on-demand access to popular open-source models with no setup—just call the API and pay per token.

1. Get an API key

  1. Go to https://www.saas.parasail.io/keys.
  2. Click Create API Key.
  3. Copy the key—it's shown only once.

Store it in your environment:

export PARASAIL_API_KEY="your-api-key-here"

2. Install the OpenAI SDK

pip install openai

3. Make your first request

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.parasail.io/v1",
    api_key=os.environ["PARASAIL_API_KEY"],
)

chat_completion = client.chat.completions.create(
    model="parasail-deepseek-r1",
    messages=[{"role": "user", "content": "What is the capital of New York?"}]
)

print(chat_completion.choices[0].message.content)

4. List available models

curl https://api.parasail.io/v1/models \
  -H "Authorization: Bearer $PARASAIL_API_KEY"

Next steps