Skip to content
This repository has been archived by the owner on Jun 17, 2024. It is now read-only.

How to Fix Invoke Issue! #15

Open
bpark1994 opened this issue Aug 1, 2018 · 0 comments
Open

How to Fix Invoke Issue! #15

bpark1994 opened this issue Aug 1, 2018 · 0 comments

Comments

@bpark1994
Copy link

Hey guys,

After struggling for a few hours trying to get this script to work I realized the problem I was having was that when you copy the script from GitHub some of the dashes are double dashes and need to be changed to single dashes. Such a stupid thing but it eluded me for a bit.

So wherever you see the "Invoke-RestMethod" you will notice that before the Headers and before Method there is a double dash which needs to be changed to a single dash. Highlighted in bold below.

Invoke-RestMethod -Uri $uri **–**Headers $auth_header **–**Method POST -Body $body

I just did a replace all and it ran smoothly after that!

Also sorry for opening a new issue just didn't feel like commenting on everyone's issue since multiple people have been posting this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant