docs: Update software updates API documentation for structured changelogs
This commit is contained in:
@@ -59,7 +59,19 @@ POST /wp-json/woonoow/v1/software/check
|
||||
},
|
||||
"current_version": "1.0.0",
|
||||
"latest_version": "1.2.0",
|
||||
"changelog": "## What's New\n- Added feature X\n- Fixed bug Y",
|
||||
"changelog": {
|
||||
"narrative": "Here the new features coming",
|
||||
"points": [
|
||||
{
|
||||
"type": "ADD",
|
||||
"text": "Added feature X"
|
||||
},
|
||||
{
|
||||
"type": "FIX",
|
||||
"text": "Fixed bug Y"
|
||||
}
|
||||
]
|
||||
},
|
||||
"release_date": "2026-02-01 12:00:00",
|
||||
"download_url": "https://your-store.com/wp-json/woonoow/v1/software/download?token=..."
|
||||
}
|
||||
@@ -96,6 +108,34 @@ GET /wp-json/woonoow/v1/software/changelog?slug=<slug>&version=<version>
|
||||
|
||||
Returns version history with changelogs.
|
||||
|
||||
**Response:**
|
||||
|
||||
```json
|
||||
{
|
||||
"slug": "my-plugin",
|
||||
"versions": [
|
||||
{
|
||||
"version": "1.1.2",
|
||||
"release_date": "2026-06-03 20:52:35",
|
||||
"changelog": {
|
||||
"narrative": "Here the new features coming",
|
||||
"points": [
|
||||
{
|
||||
"type": "ADD",
|
||||
"text": "Feature 1"
|
||||
},
|
||||
{
|
||||
"type": "FIX",
|
||||
"text": "Feature 2 Stable"
|
||||
}
|
||||
]
|
||||
},
|
||||
"download_count": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## WordPress Client Integration
|
||||
|
||||
Include the updater class in your plugin or theme to enable automatic updates:
|
||||
|
||||
Reference in New Issue
Block a user