Paper Endpoint

Fetches one paper by ID or slug, scoped to the API key's project.


Request

http
GET /dev/paper?id=<paper-id>
GET /dev/paper?slug=<paper-slug>
x-api-key: <your-api-key>

Base URL: https://whitepapper.antk.in/api

Pass exactly one of id or slug.


Response — 200 OK

typescript
interface PaperEndpointResponse {
  paper: PaperDoc
}

interface PaperDoc {
  paperId: string
  collectionId: string | null
  projectId: string | null
  ownerId: string | null          // masked in Dev API
  thumbnailUrl: string | null
  title: string
  slug: string
  body: string                    // Markdown content
  status: "draft" | "published" | "archived"
  metadata: PaperMetadata | null
  createdAt: string               // ISO 8601
  updatedAt: string               // ISO 8601
}

interface PaperMetadata {
  title: string
  metaDescription: string
  canonical: string
  robots: string
  ogTitle: string
  ogDescription: string
  ogImage: string
  ogImageWidth: number            // default 1200
  ogImageHeight: number           // default 630
  ogImageAlt: string
  ogLocale: string                // default "en_US"
  ogPublishedTime: string         // ISO 8601
  ogModifiedTime: string          // ISO 8601
  ogAuthorUrl: string
  ogTags: string[]
  twitterTitle: string
  twitterDescription: string
  twitterImage: string
  twitterImageAlt: string
  twitterCreator: string | null
  headline: string
  abstract: string
  keywords: string
  articleSection: string
  wordCount: number
  readingTimeMinutes: number
  inLanguage: string
  datePublished: string           // ISO 8601
  dateModified: string            // ISO 8601
  authorName: string
  authorHandle: string
  authorUrl: string
  authorId: string
  coverImageUrl: string
  publisherName: string
  publisherUrl: string
  isAccessibleForFree: boolean
  license: string
  keyTakeaways: string[] | null
  faq: Array<{ question: string; answer: string }> | null
  authorBio: string | null
  jsonLd: Record<string, any> | Record<string, any>[] | null
}

Errors

StatusDetail
400Provide exactly one of: id or slug.
401Missing x-api-key header.
403Paper does not belong to the API key project.
404Paper not found for id. or Paper not found for slug in this project.
429Monthly Dev API limit reached.

Notes

  • ownerId is always null in Dev API responses.
  • Only published papers are returned.
  • The full metadata object is included when present (omitted as null for drafts without metadata).
  • The canonical field inside metadata follows the pattern https://whitepapper.antk.in/{handle}/{paper-slug}.

Related

Whitepapper logo

Whitepapper

Whitepapper is a API first content platform for developers who want to publish once, distribute everywhere, and manage website content.