New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

nft-openaction-kit

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nft-openaction-kit - npm Package Compare versions

Comparing version 1.0.12 to 1.0.13

29

dist/index.d.ts
import { Chain } from 'viem';
interface DetectAndReturnCalldataParams {
contentURI: string;
publishingClientProfileId: string;
}
interface ActionDataFromPostParams {
post: PublicationInfo;
profileId: string;
profileOwnerAddress: string;
senderAddress: string;
srcChainId: string;
quantity: number;
paymentToken: string;
executingClientProfileId: string;
mirrorerProfileId?: string;
mirrorPubId?: string;
}
interface INftOpenActionKit {
detectAndReturnCalldata(contentURI: string): Promise<string | undefined>;
actionDataFromPost(post: PublicationInfo, profileId: string, profileOwnerAddress: string, senderAddress: string, srcChainId: string, quantity: bigint, paymentToken: string): Promise<ActionData>;
detectAndReturnCalldata({ contentURI, publishingClientProfileId, }: DetectAndReturnCalldataParams): Promise<string | undefined>;
actionDataFromPost({ post, profileId, profileOwnerAddress, senderAddress, srcChainId, quantity, paymentToken, mirrorerProfileId, mirrorPubId, executingClientProfileId, }: ActionDataFromPostParams): Promise<ActionData>;
}

@@ -106,6 +122,7 @@

* Detects NFT details from URL and returns calldata for minting
* @param contentURI URL of the NFT
* @param contentURI URI of the publication
* @param publishingClientProfileId profileId of application where publication is created
* @returns calldata for minting
*/
detectAndReturnCalldata(contentURI: string): Promise<string | undefined>;
detectAndReturnCalldata({ contentURI, publishingClientProfileId, }: DetectAndReturnCalldataParams): Promise<string | undefined>;
/**

@@ -121,3 +138,3 @@ * Fetches action data from post

*/
actionDataFromPost(post: PublicationInfo, profileId: string, profileOwnerAddress: string, senderAddress: string, srcChainId: string, quantity: bigint, paymentToken: string): Promise<ActionData>;
actionDataFromPost({ post, profileId, profileOwnerAddress, senderAddress, srcChainId, quantity, paymentToken, executingClientProfileId, mirrorerProfileId, mirrorPubId, }: ActionDataFromPostParams): Promise<ActionData>;
private calldataGenerator;

@@ -127,2 +144,2 @@ private fetchParams;

export { type ActionData, type ChainConfig, type INftOpenActionKit, type NFTExtraction, type NFTPlatform, NftOpenActionKit, type NftPlatformConfig, type PlatformServiceConstructor, type PublicationInfo, type SdkConfig, type ServiceConfig, type UIData };
export { type ActionData, type ActionDataFromPostParams, type ChainConfig, type DetectAndReturnCalldataParams, type INftOpenActionKit, type NFTExtraction, type NFTPlatform, NftOpenActionKit, type NftPlatformConfig, type PlatformServiceConstructor, type PublicationInfo, type SdkConfig, type ServiceConfig, type UIData };
{
"name": "nft-openaction-kit",
"version": "1.0.12",
"version": "1.0.13",
"description": "Seamless integration of NFT platforms into the Lens protocol by enabling automatic detection and handling of NFT links within Lens publications.",

@@ -5,0 +5,0 @@ "main": "./dist/index.js",

@@ -62,6 +62,7 @@ # nft-openaction-kit

raribleApiKey: process.env.RARIBLE_API_KEY,
openSeaApiKey: process.env.OPENSEA_API_KEY,
});
```
> Only the `decentApiKey` is required. The `raribleApiKey` is optional, which would make the Rarible detection available.
> Only the `decentApiKey` is required. The `raribleApiKey` and `openSeaApiKey` are optional, which would make the detection available for these platforms.

@@ -73,3 +74,6 @@ 3. Use `detectAndReturnCalldata`

try {
const result = await nftOpenActionKit.detectAndReturnCalldata(url);
const result = await nftOpenActionKit.detectAndReturnCalldata({
contentURI: url,
publishingClientProfileId: "10",
});
console.log(result || "No calldata found");

@@ -94,9 +98,14 @@ } catch (err) {

// Call the async function and pass the link
const result: ActionData = await nftOpenActionKit.actionDataFromPost(
publication,
const result: ActionData = await nftOpenActionKit.actionDataFromPost({
post: publication,
profileId,
profileOwnerAddress,
senderAddress,
srcChainId,
quantity
);
quantity,
paymentToken,
executingClientProfileId,
mirrorerProfileId,
mirrorPubId,
});
} catch (error) {

@@ -117,2 +126,3 @@ console.log(error);

raribleApiKey?: string,
openSeaApiKey?: string,
};

@@ -119,0 +129,0 @@ ```

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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