Data API Quickstart

Three steps to your first API response.

Step 1: Get your API key

Use the Get your key link in the top right to request access. We will set up your account and provide your subscription key. Include it in every request as a header:

Ocp-Apim-Subscription-Key: sk_live_abc123...

Step 2: Search European law

Make your first search request. The keyword search endpoint accepts a query string and returns matching legal documents across your chosen jurisdictions.

curl -X POST 'https://api.moonlit.ai/v1.1/search/keyword_search' \
  -H 'Ocp-Apim-Subscription-Key: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "query": "data protection",
    "jurisdictions": ["European Union"],
    "num_results": 5
  }'

Step 3: Retrieve a full document

Use the identifier from your search results to retrieve the full text, metadata, and AI-generated summary via a GET request with a query parameter.

curl "https://api.moonlit.ai/v1.1/document/retrieve_document?DocumentIdentifier=62018CJ0311" \
  -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY"
Response Preview
title

Data Protection Commissioner v Facebook Ireland Limited and Maximillian Schrems (Schrems II)

text

"In those circumstances, the referring court considers that the validity of Decision 2010/87, read in the light of Articles 7, 8 and 47 of the Charter..."

summary

The Court of Justice invalidated the EU-US Privacy Shield and upheld the validity of standard contractual clauses, subject to additional safeguards...

referenced

165

sourceUrl

https://curia.europa.eu/...

Next steps

Open the API reference for every endpoint, parameter, and response schema, generated from the live OpenAPI spec. Browse use cases for integration patterns. If you want a Claude-native flow instead of REST, see the MCP server.