Pular para o conteúdo

API Documentation

Integrate PlatPhorm Dictionary into your applications with our REST API.

Base URL
All API requests should be made to:
https://dictionary.platphormnews.com/api/v1
API Endpoints
Available REST endpoints
GET/api/v1/terms

List all approved terms with pagination

Params: locale, limit, offset, sort

GET/api/v1/terms/[slug]

Get a specific term by slug

Params: locale

GET/api/v1/terms/random

Get a random term

Params: locale

GET/api/v1/search

Search terms by query

Params: q, locale, limit

POST/api/v1/definitions

Submit a new definition

Params: term, definition, example_usage, author_handle, locale, tags

POST/api/v1/definitions/[id]/vote

Vote on a definition

Params: vote_type (up/down)

Example: Submit a Definition
curl -X POST https://dictionary.platphormnews.com/api/v1/definitions \
  -H "Content-Type: application/json" \
  -d '{
    "term": "Vibe Check",
    "definition": "An assessment of someone'"'"'s mood or energy...",
    "example_usage": "Let me do a quick vibe check.",
    "author_handle": "yourusername",
    "locale": "en",
    "tags": ["slang", "social"]
  }'