Skip to content

Instantly share code, notes, and snippets.

@NielsGregers
Last active January 24, 2021 16:36
Show Gist options
  • Save NielsGregers/4ad87319750eaf04c361a53a17be3f98 to your computer and use it in GitHub Desktop.
Save NielsGregers/4ad87319750eaf04c361a53a17be3f98 to your computer and use it in GitHub Desktop.
Getting Matts blog post out of WebFlow
$hexatown = Start-Hexatown $myInvocation # Start the framework
$webflow = API webflow login # Load API and sign in
$site = API $webflow first sites # Set a Site reference
$collections = API $webflow $site list collections # Load all collections
Each $collections { # Show name of each collection
write-host $item.name
}
$collection = $collections | # Find a collection
Where-Object { $_.name -eq "Blog Posts" } # named "Blog Post"
$items = API $webflow $collection list items # Read all items
$items.items | Format-Table # Show all items in a table
Stop-Hexatown $hexatown # Stop the framework
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment