open-index/open-npm huggingface dataset:
npm package: @safecoin/lpl-token-metadata
Description: MPL Token Metadata JavaScript API.
Author: Metaplex Maintainers
Latest version: 2.8.6

# lpl-token-metadata

This package contains the token vault contract SDK code.

## API Docs

Find the [token-metadata API docs published here](https://metaplex-foundation.github.io/metaplex-program-library/docs/token-metadata/index.html).

## Installation

```shell
npm install @safecoin/lpl-token-metadata --save
```

This will use the new auto-generated API. If you want to use the old deprecated API, you can use the following:

```shell
npm install @safecoin/lpl-token-metadata@^1.2 --save
```

Alternatively, if you'd like to start using the new API but still have access to the deprecated one, you may use the following:

```sh
npm install @safecoin/lpl-token-metadata@~2.0 --save
```

And use the deprecated API explicitly like so:

```ts
import { deprecated } from "@safecoin/lpl-token-metadata";
```

## Developing

In order to update the generated SDK when the rust contract was updated please run:

```
yarn api:gen
```

and then update the wrapper code and tests.

## LICENSE

Apache v2.0
npm package: @safecoin/prove-safecoin-wallet
Description: Prove ownership of a Solana wallet.
Author: Daniel Kelleher
Latest version: 0.3.1

# Prove-Solana-Wallet

This library proves ownership of a [Solana](https://solana.com) wallet to off-chain verifiers.

It is compatible with standard browser wallet adapters, such as 
[sol-wallet-adapter](https://github.com/project-serum/sol-wallet-adapter), 
and can be extended to others.

## Install

```sh
npm install @identity.com/prove-solana-wallet
```

or 

```sh
yarn add @identity.com/prove-solana-wallet
```

## Usage

Prove ownership of a keypair

Prover side: 
```js
const {prove} = require('@identity.com/prove-solana-wallet');
const proof = await prove(myKeypair);
```

Verifier side:
```js
const {verify} = require('@identity.com/prove-solana-wallet');
await verify(proof, expectedPublicKey);
```

Prove ownership of an external wallet (e.g. sol-wallet-adapter).
See [here](https://github.com/project-serum/sol-wallet-adapter) for more details.

Prover side:
```js
const {prove} = require('@identity.com/prove-solana-wallet');
import Wallet from "@project-serum/sol-wallet-adapter";

const providerUrl = 'https://www.sollet.io';
const wallet = new Wallet(providerUrl);
wallet.on('connect', async (publicKey) => {
  // once the wallet is connected, we can prove ownership
  const signer = (transaction:Transaction) => wallet.signTransaction(transaction);

  const proof = await prove(myKeypair);
});
```

Verifier side:
```js
const {verify} = require('@identity.com/prove-solana-wallet');
await verify(proof, expectedPublicKey);
```

## Details

The prove() function generates a zero-value transaction, and
signs it with the wallet private key. For the transaction to be verified
by the verify() function, it must:

- have ony one instruction: SystemProgram.transfer
- be zero-value
- be self-to-self (i.e the sender and recipient are the same)
- have a recent blockhash on mainnet
- but not be broadcast to mainnet

These measures increase the security by reducing the likelihood
that an attacker can either coerce the wallet owner to sign
a transaction or intercept a broadcast one.

## Configuration

The prove and verify functions can be configured as follows:

### `cluster`

Default: `mainnet-beta`

The cluster that should be used when generating and verifying proofs

### `commitment`

Default: `confirmed`

When checking that a proof transaction has not been transmitted, the commitment to be used, i.e. the degree to which the transaction is finalised by the network

### `supportedClusterUrls`

Optional
Default: empty

If the cluster is not a standard solana public cluster, this map provides
the cluster URL to connect to. Use this when the proof may contain a cluster that is
not recognised by solana's clusterApiUrl function.