-
Notifications
You must be signed in to change notification settings - Fork 34
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
[feat] Native privy auth #51
Conversation
case 'eth_sendTransaction': | ||
case 'eth_signTransaction': | ||
// TODO: Implement | ||
return randomBytes(32).toString('hex'); // fake tx hash |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the implementation going to be here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tbd - currently only sendTransaction
is exposed via cross app connect, not a signTransaction
This only applies to transactions from the underlying cross connect EOA, not the AGW
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah gotcha
case 'eth_sign': | ||
throw new Error('eth_sign is unsafe and not supported'); | ||
case 'personal_sign': { | ||
console.log(params); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't need this if you've verified it works
Adds a new
AbstractPrivyProvider
under@abstract-foundation/agw-react/privy
This provider can be used to wrap the application instead of
AbstractWalletProvider
if the hosting application is using Privy for their own authentication.Also added is a convenience hook
useAbstractPrivyLogin
which allows for quick login/link of AGW account on the host applicationPR-Codex overview
This PR focuses on integrating a new
Privy
wallet connector into theagw-react
package, enhancing the login functionality and provider setup for abstract wallet connections.Detailed summary
id: 'xyz.abs.privy'
to the abstract wallet connector.AbstractPrivyProvider
anduseAbstractPrivyLogin
inprivy.ts
.useLoginWithAbstract
to useid
.InjectWagmiConnector
for handling wallet connections.AbstractPrivyProvider
for configuring thePrivy
provider.usePrivyCrossAppProvider
for managing cross-app accounts.package.json
to include@privy-io/react-auth
dependency.