Getting GIT tips online

by Aug 8, 2016

Here is an example that illustrates how you access a REST API online. The script retrieves GIT tips. GIT is an open-source control system. Even if you are not particularly interested in GIT, the code may still be valuable to access other similar REST APIs available on the internet:

#requires -Version 3 

$url = 'https://raw.githubusercontent.com/git-tips/tips/master/tips.json'
$tips = Invoke-RestMethod -Uri $url 
$tips | Out-GridView -Title 'Tips from git-tips' -OutputMode Multiple

Twitter This Tip! ReTweet this Tip!