Guest User

Untitled

a guest
Apr 23rd, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. Invoke-WebRequest -Uri ("https://contoso.com/rest/api/content/123789") -Method Get -Headers $Credentials -ContentType "application/json; charset=utf-8"
  2.  
  3. $r = invoke-webrequest http://foobar.com
  4. $r.Headers
  5.  
  6. Invoke-WebRequest http://foorbar.com -outfile .test.txt
  7. $content = get-content .test.txt -Encoding utf8 -raw
  8.  
  9. [system.Text.Encoding]::UTF8.GetString((Invoke-WebRequest "https://www.solution.com").RawContentStream.ToArray())
Add Comment
Please, Sign In to add comment