Access Press-News.org data programmatically. Read operations are free and open. Write operations require an API key.
Returns paginated list of articles. Supports filtering by category and date range.
| Parameter | Type | Description |
|---|---|---|
page | int | Page number (default: 1) |
limit | int | Articles per page, max 100 (default: 25) |
category | string | Filter by category keyword |
sort | string | desc (default) or asc |
date_from | string | Start date (YYYY-MM-DD) |
date_to | string | End date (YYYY-MM-DD) |
GET /api/?action=list&page=1&limit=10&category=medicine
{
"data": [
{
"id": 160001,
"title": "New Cancer Treatment Shows Promise",
"excerpt": "Researchers at MIT have...",
"date": "2026-03-15",
"category": "Medicine",
"url": "https://press-news.org/160001-new-cancer-treatment.html",
"image": "https://press-news.org/img/n/abc123_s1.webp"
}
],
"pagination": {
"page": 1,
"limit": 10,
"total": 52340,
"total_pages": 5234,
"has_next": true,
"has_prev": false
}
}
Returns full article with body text, images, and contact info.
GET /api/?action=get&id=160001
{
"data": {
"id": 160001,
"title": "New Cancer Treatment Shows Promise",
"excerpt": "Researchers at MIT have...",
"subtitle": "Phase III trial results",
"press_info": "MIT News Office",
"body": "<p>Full HTML article text...</p>",
"date": "2026-03-15",
"category": "Medicine",
"url": "https://press-news.org/160001-new-cancer-treatment.html",
"images": [
{
"thumbnail": "https://press-news.org/img/n/abc_s1.webp",
"full": "https://press-news.org/img/n/abc_1.webp"
}
],
"contact": "press@mit.edu"
}
}
Full-text search across titles and excerpts. Minimum 3 characters.
| Parameter | Type | Description |
|---|---|---|
q | string | Search query (min 3 chars, required) |
page | int | Page number (default: 1) |
limit | int | Results per page, max 50 (default: 20) |
Returns article counts, date ranges, and available endpoints.
Returns all available categories with slugs, icons, and URLs.
Create a new article. Requires API key with write permission.
| Field | Type | Required | Description |
|---|---|---|---|
title | string | Yes | Article headline |
body | string | Yes | Full article HTML |
excerpt | string | No | Short summary |
subtitle | string | No | Subtitle / subheadline |
press_info | string | No | Source attribution |
contact | string | No | Contact info |
date | string | No | Date (default: now) |
POST /api/?action=create
Headers: X-API-Key: your-api-key
Content-Type: application/json
{
"title": "New Discovery in Quantum Physics",
"body": "<p>Scientists have discovered...</p>",
"excerpt": "A breakthrough in quantum computing",
"press_info": "Stanford University"
}
Update an existing article. Supports partial updates. Requires API key with write permission.
PUT /api/?action=update&id=160001
Headers: X-API-Key: your-api-key
Content-Type: application/json
{
"id": 160001,
"title": "Updated: New Discovery in Quantum Physics",
"excerpt": "Updated summary..."
}
Permanently delete an article. Requires API key with delete permission.
Read operations (list, get, search, stats, categories) are open and free.
Write operations (create, update, delete) require an API key. Send it via the X-API-Key header:
curl -X POST https://press-news.org/api/?action=create \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key-here" \
-d '{"title": "...", "body": "..."}'
To request an API key, contact us.
All errors return a JSON object with an error field:
{
"error": "Article not found"
}
HTTP Status Codes:
200 - Success
201 - Created
400 - Bad Request
401 - Unauthorized
404 - Not Found
405 - Method Not Allowed
429 - Rate Limited
500 - Server Error