Skip to content
PowerShell Function To Display WordPress.com Blog Post Data From The API
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Images
Get-Blogs.ps1
README.md

README.md

PowerShell Function - WordPress.com retrieve blog data using API

A quick PowerShell Function to retrieve blog post data from my blog site - added to Github as may be useful for others!

Run this function easily by:

Get-Blogs -BlogSiteName "thomasthornton.cloud"

Output: alt text

If you require further Output data from the used api, you can run

$WPBlogRetrieve = Invoke-RestMethod -uri "https://public-api.wordpress.com/rest/v1/sites/$BlogSiteName/posts/?number=100"
$WPBlogRetrieve.posts

Further info on WordPress.com API

You can’t perform that action at this time.