# js-kuknos-sdk

> js-kuknos-sdk is a library for working with the Kuknos Horizon server.

Latest version **1.0.0** (published 2021-10-17) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install js-kuknos-sdk
pnpm add js-kuknos-sdk
yarn add js-kuknos-sdk
bun add js-kuknos-sdk
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2021-10-17 |
| First published | 2020-04-30 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 16 |
| Unpacked size | 2.6 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Stellar Development Foundation |
| Maintainers | kuknosco |
| Keywords | stellar |

## Links

- npm: https://www.npmjs.com/package/js-kuknos-sdk
- Repository: https://github.com/KuknosOrg/js-kuknos-sdk
- Homepage: https://github.com/KuknosOrg/js-kuknos-sdk.git
- Issues: https://github.com/KuknosOrg/js-kuknos-sdk/issues
- npm.io page: https://npm.io/package/js-kuknos-sdk

## Dependencies (16)

- [toml](https://npm.io/package/toml.md) ^2.3.0
- [axios](https://npm.io/package/axios.md) ^0.19.0
- [tslib](https://npm.io/package/tslib.md) ^1.10.0
- [urijs](https://npm.io/package/urijs.md) ^1.19.2
- [lodash](https://npm.io/package/lodash.md) ^4.17.15
- [@types/node](https://npm.io/package/@types/node.md) >= 8
- [detect-node](https://npm.io/package/detect-node.md) ^2.0.4
- [es6-promise](https://npm.io/package/es6-promise.md) ^4.2.4
- [eventsource](https://npm.io/package/eventsource.md) ^1.0.7
- [randombytes](https://npm.io/package/randombytes.md) ^2.1.0
- [@types/urijs](https://npm.io/package/@types/urijs.md) ^1.19.6
- [bignumber.js](https://npm.io/package/bignumber.js.md) ^4.0.0
- [utility-types](https://npm.io/package/utility-types.md) ^3.7.0
- [js-kuknos-base](https://npm.io/package/js-kuknos-base.md) ^0.0.9
- [@types/eventsource](https://npm.io/package/@types/eventsource.md) ^1.1.2
- [@types/randombytes](https://npm.io/package/@types/randombytes.md) ^2.0.0

## Recent versions

- 1.0.0 (latest) — 2021-10-17
- 0.0.9 — 2020-06-16
- 0.0.8 — 2020-05-02
- 0.0.7 — 2020-04-30
- 0.0.5 — 2020-04-30

## README

# kuknos sdk

*js-kuknos-sdk* is a js-based library that enables software developers ,to easily build , submit and do things with kuknos transactions

# installation
just type 

> npm install js-kuknos-sdk

# sample
to create new transaction follow instructions bellow

```javascript
import sdk from 'js-kuknos-sdk'
//url example is horizon provided by your anchor
const server = new StellarSdk.Server(url);
const account = await server.loadAccount(sourcePublicKey);
const publicKey ="GAIRISXKPLOWZBMFRPU5XRGUUX3VMA3ZEWKBM5MSNRU3CHV6P4PYZ74D"
const sourceSecretKey='SCZANGBA5YHTNYVVV4C3U252E2B6P6F5T3U6MM63WBSBZATAQI3EBTQ4';

// Derive Keypair object and public key (that starts with a G) from the secret
const sourceKeypair = StellarSdk.Keypair.fromSecret(sourceSecretKey);
transaction = new StellarSdk.TransactionBuilder(account,{"fee":BaseFee, "networkPassphrase": sdk.Network.PUBLIC})//OR CAN BE HARDCODED
                    .addOperation(StellarSdk.Operation.createAccount({
                      destination: destinationId,
                      startingBalance: amount.toString(),
                      source: publicKey
                    }))
                    // A memo allows you to add your own metadata to a transaction. It's
                    // optional and does not affect how Stellar treats the transaction.
                    .addMemo(memoValue.length === 0 ? StellarSdk.Memo.none() : memoParam)
                    .setTimeout(60000)
                    .build();
 transaction.sign(sourceKeypair);
 const transactionResult = await server.submitTransaction(transaction);

```

---
_Source: https://npm.io/package/js-kuknos-sdk · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
