Skip to main content
Toggle navigation
Friendica
Search
2023-04-05 06:12:24
2023-04-03 19:26:22
2023-04-03 19:25:50
1492584
Marco R.
2 years ago from Friendiqa
•
Marco R.
2 years ago from Friendiqa
•
@
Friendica Support
How does the OAuth workflow work? With /api/v1/apps I get a client_id and a client_secret? How do I get the OAuth token?
@
Friendica Support
More
Languages
Share via ...
Michael 🇺🇦
2 years ago
•
See here:
https://docs.joinmastodon.org/methods/oauth/
More
Languages
Share via ...
Marco R.
2 years ago from Friendiqa
•
With the following code I get an empty string:
 xhr.setApi("/oauth/authorize");
 xhr.clearParams();
 xhr.setParam("response_type","code");
 xhr.setParam("redirect_uri","urn:ietf:wg:oauth:2.0:oob");
 xhr.setParam("client_id",app.client_id);
 xhr.setParam("force_login",true)
 xhr.get();

Am I supposed to give username and password with this API? I can't show the website in the app, that would require a dependency to Qt Webengine...
More
Languages
Share via ...
Michael 🇺🇦
2 years ago
•
I guess that there is no way around showing the site in a browser component, because that's how OAuth is normally used.
More
Languages
Share via ...
Nordnick :verified:
2 years ago
•
@
heluecht
The process requires multiple steps.
E.g. registering an application.
E.g. authorizing an user.
And no, you don't use an user name or password with the #
API
.
Tokens are used.
Getting started with the API
https://docs.joinmastodon.org/client/intro/
Getting started with the API
A primer on REST APIs, HTTP requests and responses, and parameters.
docs.joinmastodon.org
#
API
@
Michael 🇺🇦
More
Languages
Share via ...
⇧
Michael 🇺🇦
•Marco R.
•Michael 🇺🇦
•Nordnick :verified:
•The process requires multiple steps.
E.g. registering an application.
E.g. authorizing an user.
And no, you don't use an user name or password with the #API.
Tokens are used.
Getting started with the API
https://docs.joinmastodon.org/client/intro/
Getting started with the API
docs.joinmastodon.org