Comments (2)
If you need an example, I made a full custom implementation of an OAuth strategy for osu!
.
In the method for returning a profile from the API, I want to return the full API user instead of the one that extends OAuth2Profile, which like mentioned has properties that I will never need.
So in this example, I just want to write return await request.json()
instead of creating a new object.
from remix-auth-oauth2.
From the OAuth2Profile the only required field is the provider
, the rest are optional meaning you can add only what you need. But if you need something that the OAuth2Profile uses it would be ideal to return it, for example use displayName for the username.
The reason the OAuth2Profile exists is to allow strategy authors to normalize the data, if you install any OAuth2-based strategy you know the profile has an array of emails for example.
But if you're extending the OAuth2Strategy locally in your project feel free to return anything you need.
from remix-auth-oauth2.
Related Issues (20)
- Since upgrading to V2 from V1.11.1 verify-Callback is not called HOT 2
- Screen hint not working after 1.10.0
- remix-auth-oauth2 broken on main with current version of @oslojs/oauth2 HOT 2
- AuthorizationError: Missing or invalid 'refresh_token' field in v2.2.0 HOT 2
- 2.0 cloudflare compat?
- Breaking error in 1.11.0 - Asked for scope that doesn't exist on the resource HOT 4
- Custom state object HOT 9
- Unusable behind proxy HOT 2
- Redirecting the user to the callback URL results in SyntaxError: Unexpected end of JSON input HOT 1
- Verify function does not work HOT 2
- Dynamic callbackURL HOT 4
- Error: Missing state on session HOT 1
- Missing state on session HOT 1
- state value is not removed when cookie based session storage is used
- OneLogin ERR_TOO_MANY_REDIRECTS after update to v2.0.0 HOT 5
- Allow setting redirectURI based on request object HOT 2
- Missing `client_id` HOT 3
- Issue getting token from Cognito token endpoint since upgrading to V2 HOT 2
- Error when authorization redirect uses same domain as Remix app HOT 2
- Clean way to retrieve strategy (or call revokenToken indirectly) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from remix-auth-oauth2.