Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@rarible/biconomy-middleware

Package Overview
Dependencies
Maintainers
0
Versions
164
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rarible/biconomy-middleware

Middleware for biconomy integration

  • 0.13.70
  • latest
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Biconomy Provider Middleware

Usage

    import { Registry, withBiconomyMiddleware } from "@rarible/biconomy-middleware"

    const provider = ... // an web3 provider   
    
    // contract metadata provider see IContractRegistry
    const remoteTestRegistry = new Registry("https://example.com/registry.json") 

    // applying biconomy middleware to provider 
    const biconomyProvider = withBiconomyMiddleware(provider, testRegistry, {
        apiKey: "BICONOMY_API_KEY",
    })

    // use provider with biconomy for web3 instance
    const web3 = new Web3(biconomyProvider as any)

    // create contract and use methods normally
    const contract = web3.eth.Contract(abi, contractAddress)
    const tx = await contract.methods.setApprovalForAll(contractAddress, true).send()   

Complete usage example can also be seen in tests

Keywords

FAQs

Package last updated on 17 Dec 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc