Skip to content
This repository has been archived by the owner on Aug 27, 2021. It is now read-only.

Authentication #3751

Closed
AquaHippie808 opened this issue Jul 24, 2018 · 4 comments · Fixed by #3971
Closed

Authentication #3751

AquaHippie808 opened this issue Jul 24, 2018 · 4 comments · Fixed by #3971

Comments

@AquaHippie808
Copy link

https://sendgrid.com/docs/API_Reference/Web_API_v3/How_To_Use_The_Web_API_v3/authentication.html

Discovered the param -H 'on-behalf-of: subuser_username' \ is case sensitive. The header is ignored and returns the parent account stats instead of the subuser. I was able to get it to work with the snippet below, also provided a screenshot of the location.

curl "https://api.sendgrid.com/v3/stats?start_date=2018-07-01&end_date=2018-08-01&aggregated_by=month" \
     -H 'On-Behalf-Of: subuser_name' \
     -H 'Authorization: Bearer {api key}' \
     -H 'Content-Type: application/json'

Screenshot of doc location

@apigirl
Copy link
Contributor

apigirl commented Jul 25, 2018

@asi851 - this is a really good catch! Thanks for letting us know about it.

The to-do here is to double check all of the On-Behalf-Of parameter examples and make sure they are all capitalized. Also probably worth adding a note here specifically calling out that it's case sensitive.

@apigirl
Copy link
Contributor

apigirl commented Jul 25, 2018

I'll open this up to the community after our doc repo freeze is over!

@AquaHippie808
Copy link
Author

@ksigler7 thanks a bunch. Anything to help out the #grid.

@AbhyudayaSharma
Copy link
Contributor

Hi! I'd like to fix this.

AbhyudayaSharma added a commit to AbhyudayaSharma/docs that referenced this issue Oct 1, 2018
apigirl pushed a commit that referenced this issue Oct 2, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants