# tsoposki-ptokens-peos

> repo holding the code for interacting with pEOS

Latest version **0.2.1-alpha.0** (published 2020-02-18) · ISC license · 0 weekly downloads

## Install

```sh
npm install tsoposki-ptokens-peos
pnpm add tsoposki-ptokens-peos
yarn add tsoposki-ptokens-peos
bun add tsoposki-ptokens-peos
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.1-alpha.0 |
| Published | 2020-02-18 |
| First published | 2020-02-18 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 8 |
| Unpacked size | 174.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | alle.manfredi@gmail.com @provable-things |
| Maintainers | cryptorobot |

## Links

- npm: https://www.npmjs.com/package/tsoposki-ptokens-peos
- npm.io page: https://npm.io/package/tsoposki-ptokens-peos

## Dependencies (8)

- [chai](https://npm.io/package/chai.md) ^4.2.0
- [web3](https://npm.io/package/web3.md) ^1.2.2
- [eosjs](https://npm.io/package/eosjs.md) ^20.0.0
- [text-encoding](https://npm.io/package/text-encoding.md) ^0.7.0
- [@babel/runtime](https://npm.io/package/@babel/runtime.md) ^7.3.1
- [web3-core-promievent](https://npm.io/package/web3-core-promievent.md) ^1.2.1
- [tsoposki-ptokens-utils](https://npm.io/package/tsoposki-ptokens-utils.md) ^0.2.1-alpha.0
- [tsoposki-ptokens-enclave](https://npm.io/package/tsoposki-ptokens-enclave.md) ^0.2.1-alpha.0

## Recent versions

- 0.2.1-alpha.0 (latest) — 2020-02-18

## README

# ptokens-peos

Module for interacting only with pEOS.

&nbsp;

***

&nbsp;

### Installation:

```
npm install ptokens-peos
```

&nbsp;

***

&nbsp;

### Usage:

```js
const pEOS = require('ptokens-peos')

const peos = new pEOS({
  ethPrivateKey: 'Eth private key',
  ethProvider: 'Eth provider',
  eosPrivateKey: 'EOS private key',
  eosRpc: 'EOS RPC Address'
  eosSignatureProvider: 'An EOS Signature Provider'  //if the private key is not passed
})
```
It is possible to pass a standard Ethereum Provider as the __`ethProvider`__ value, such as the one injected 
into the content script of each web page by Metamask(__`window.web3.currentProvider`__).

```js
const pEOS = require('ptokens-peos')

if (window.web3) {
  
  const peos = new pEOS({
    ethProvider: window.web3.currentProvider,
  })
} else {
  console.log('No web3 detected')
}
```

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