npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

ncent-sandbox-sdk

v2.3.1

Published

nCent Sandbox SDK

Readme

ncentSDK

Overview

ncentSDK is a Javascript library for communicating with the nCent API. It is used for building nCent applications either on Node.js or in the browser, as well as for accessing base-level features on the API.

It provides:

  • a networking layer for endpoints on the back-end API.
  • eventual facilities for building and signing transactions, for communicating with the backend API, and for submitting transactions or querying network history.

Install

To use as a module in a Node.js project

  1. Install it using npm:
npm i ncent-sandbox-sdk
  1. require/import it:
const nCentSDK = require('ncent-sandbox-sdk');

To develop and test the SDK:

  1. Clone the repo:
git clone https://github.com/ncent/ncent-SDK.js
  1. Install dependencies inside our ncentSDK folder:
cd ncent-SDK.js
npm install

Documentation

Constructor

new ncentSDK(ip_address)

Description:

Create an instance of the nCent SDK class, specifying the IP of the Sandbox instance with which you will communicate.

Parameters:

Name | Type | Description --- | --- | --- ip_address | String | Network on which to connect to the API. This defaults to the IP of the Sandbox hosted on AWS. If you are running the sandbox locally, pass http://localhost:8010/api


Methods


createWalletAddress

createWalletAddress()

Description:

Creates a KeyPair object.

Parameters:

None



getWallets

getWallets()

Description:

Retrieves all wallets

Parameters:

None



getWallet

getWallet(publicKey)

Description:

Retrieves a specific wallet

Parameters:

Name | Type | Description --- | --- | --- publicKey | String | Valid public key associated with a wallet



getWalletBalance

getWalletBalance(publicKey, tokenTypeUuid)

Description:

Retrieves a specific wallet's balance of a stamped TokenType

Parameters:

Name | Type | Description --- | --- | --- publicKey | String | Valid public key associated with a wallet tokenTypeUuid | String | UUID of a stamped TokenType



stampToken

stampToken(publicKey, tokenName, totalTokens, expiryDate)

Description:

Initiates a new token type and creates totalTokens amount of these tokens. Note: For development, one can stamp tokens out of nothing, and thus stampTokens can be used to instantiate new tokens for free. In the production version of our SDK, only ncnt will be allowed to be stamped into new tokens.

Parameters:

Name | Type | Description --- | --- | --- publicKey | String | public key of wallet stamping token tokenName | String | Name of token the user wants to create. numTokens | int | Number of tokens to create. expiryData | int | Date of expiration for token.



getTokenTypes

getTokenTypes()

Description:

returns all TokenTypes

Parameters:

none



getTokenTypeData

getTokenTypeData(tokenTypeUuid)

Description:

returns data and transactions of a tokenType

Parameters:

Name | Type | Description --- | --- | --- tokenTypeUuid | String | UUID of a stamped TokenType



getTransactions

getTransactions

Description:

returns all Transactions

Parameters:

none



createChallenge

createChallenge(senderKeyPair, tokenTypeUUid, amount)

Description:

Allows a TokenType sponsor to create a challenge. This challenge can be transferred to other wallets as a transaction

Parameters:

Name | Type | Description --- | --- | --- senderKeyPair | stellarKeyPair | Sender wallet with secretKey and public key tokenTypeUuid | String | UUID of owned TokenType amount | Integer | designated count of tokens to issue as part of challenge



shareChallenge

shareChallenge(senderKeyPair, transactionUuid, toAddress)

Description:

Allows the owner of a challenge (transaction) to transfer it

Parameters:

Name | Type | Description --- | --- | --- senderKeyPair | stellarKeyPair | Sender wallet with secretKey and public key transactionUuid | String | UUID of owned transaction (challenge) toAddress | String | public key to transfer ownership of challenge to



redeemChallenge

redeemChallenge(ownerKeyPair, transactionUuid)

Description:

Allows the owner of a TokenType to trigger redemption. This will create a transaction between the current challenge owner and Token Graveyard.

Parameters:

Name | Type | Description --- | --- | --- ownerKeyPair | stellarKeyPair | Owner wallet with secretKey and public key transactionUuid | String | UUID of owned transaction (challenge)



retrieveProvenanceChain

retrieveProvenanceChain(transactionUuid)

Description:

Gets the parents of a transaction recursively

Parameters:

Name | Type | Description --- | --- | --- transactionUuid | String | UUID of a transaction (challenge)



retrieveProvenanceChainFIFO

retrieveProvenanceChainFIFO(tokenTypeUUid, publicKey)

Description:

Gets the provenance of the oldest received transaction (challenge) of a specific TokenType that has not been shared.

Parameters:

Name | Type | Description --- | --- | --- publicKey| String | valid wallet public key tokenTypeUuid | String | UUID of a stamped TokenType



Usage

Check the examples folder for usage examples.

Contributing

For information on how to contribute, please email [email protected], [email protected], or [email protected]

License

SDK is licensed under ...