Skip to content

How to call below curl using postman #77

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ZTAP0011 opened this issue Feb 2, 2021 · 3 comments
Closed

How to call below curl using postman #77

ZTAP0011 opened this issue Feb 2, 2021 · 3 comments

Comments

@ZTAP0011
Copy link

ZTAP0011 commented Feb 2, 2021

$ curl -u ${client_id}:${client_secret} -XPOST http://127.0.0.1:5000/oauth/token -F grant_type=password -F username=${username} -F password=valid -F scope=profile

I am not understanding what is -u option in curl.

@shimniok
Copy link
Contributor

shimniok commented Feb 2, 2021 via email

@ZTAP0011
Copy link
Author

ZTAP0011 commented Feb 3, 2021

-u is for supplying user credentials in the form username:password See https://www.mit.edu/afs.new/sipb/user/ssen/src/curl-7.11.1/docs/curl.html

On Tue, Feb 2, 2021, 6:51 AM ZTAP0011 @.***> wrote: $ curl -u ${client_id}:${client_secret} -XPOST http://127.0.0.1:5000/oauth/token -F grant_type=password -F username=${username} -F password=valid -F scope=profile I am not understanding what is -u option in curl. — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#77>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIDKMTGC7QHND2H3MXUMY3S477OVANCNFSM4W6VLXJQ .

Thank you @shimniok

@ZTAP0011
Copy link
Author

ZTAP0011 commented Feb 3, 2021

I am calling /oauth/token to generate the token by passing the code. I set OAUTH2_REFRESH_TOKEN_GENERATOR=True in my flask app config. But I only get access_token in the response but not refresh_token.

@ZTAP0011 ZTAP0011 closed this as completed Feb 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants