Parallèle Docs
Api

API Overview

Overview of the Parallèle public API endpoints.

API Overview

The Parallèle API provides RESTful endpoints for fetching content from your workspace.

Base URL

All API requests should be made to:

https://parallele.ai/api/public

Authentication

All endpoints require the x-api-key header with your workspace API key:

curl https://parallele.ai/api/public/content?locale=en \
  -H "x-api-key: prl_your_api_key"

Available Endpoints

EndpointDescription
GET /contentFetch content strings
GET /content/previewPreview content strings (with drafts)
GET /pagesList published pages
GET /pages/:slugGet a single page
GET /collectionsList all collections
GET /collections/:slugList items in a collection
GET /collections/:slug/:itemSlugGet a single collection item
GET /blogList published blog posts
GET /blog/:slugGet a single blog post
GET /menus/:slugGet a navigation menu

Common Parameters

Locale Filtering

Most endpoints accept a locale parameter:

# Fetch French content
GET /api/public/content?locale=fr
 
# Fetch English pages
GET /api/public/pages?locale=en

If not specified, the workspace's default locale is used.

All Locales

Some endpoints support fetching content in all locales:

# Get pages in all locales
GET /api/public/pages?allLocales=true

Pagination

Collection and blog endpoints support pagination:

# Get 10 items, starting from offset 20
GET /api/public/collections/testimonials?limit=10&offset=20

Response Format

All responses are JSON objects. Successful responses include the requested data:

{
  "content": {
    "hero.title": "Welcome",
    "hero.subtitle": "Build faster"
  },
  "locale": "en",
  "count": 2
}

Error responses include an error field:

{
  "error": "Collection not found"
}

HTTP Status Codes

CodeDescription
200Success
400Bad request (invalid parameters)
401Unauthorized (invalid or missing API key)
404Not found
429Rate limit exceeded
500Server error

Site Metadata

Many endpoints include site metadata in the response:

{
  "site": {
    "name": "My Website",
    "domain": "example.com",
    "defaultLocale": "fr",
    "locales": [
      { "code": "fr", "name": "French", "nativeName": "Français", "isDefault": true },
      { "code": "en", "name": "English", "nativeName": "English", "isDefault": false }
    ]
  }
}

This is useful for building locale switchers and navigation.

On this page