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

lollipop-js-sdk

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lollipop-js-sdk

### [TypeScript Docs](https://sdk-docs-lollipop.vercel.app/)

  • 0.0.2
  • unpublished
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

lollipop-sdk package

TypeScript Docs

What's Lollipop?

Lollipop is a highly efficient multichain nft indexer.

This sdk provides methods for interaction with lollipop api and it’s solana contracts

The SDK allows interacting with lollipop, specifically:

  • getting user's fungible tokens.
  • getting user's nfts
  • preparing link/unlink transactions to a lollipop contracts

Installation

Yarn

$ yarn add lollipop-js-sdk

NPM

npm install lollipop-js-sdk

Usage

Lollipop API

// Create an instance of LollipopAPI class for interaction with API
import { LollipopAPI } from 'lollipop-js-sdk'

const userPublicKey = new PublicKey('YOUR PUBLIC KEY')
const lollipopAPI = new LollipopAPI()

const fetchedUserData = await lollipopApi.getUserData(
  userPublicKey.toString()
)

const userNFTs = await lollipopApi.getUserNFTs(
  userPublicKey.toString()
)

const userTokens = await lollipopApi.getUserFungibleTokens(
  userPublicKey.toString()
)

Lollipop Program

// Create an instance of LollipopProgram class for interaction with contracts
import { LollipopProgram } from 'lollipop-js-sdk'
import { useConnection, useWallet } from '@solana/wallet-adapter-react'

const { connection } = useConnection()
const { wallet } = useWallet()

const lollipopProgram = new LollipopProgram({
  connection,
  wallet
})

const linkTransaction = await lollipopProgram.getLinkTransaction(
  {
    coldWallet,
    hotWallet,
    txPayer
  }
)

const unlinkTransaction = await lollipopProgram.getUnlinkTransaction(
  {
    coldWallet,
    hotWallet,
    txPayer
  }
)

FAQs

Package last updated on 25 Dec 2022

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