# midu-superid-plugin

> ## Install

Latest version **1.3.22** (published 2019-10-09) · 0 weekly downloads

## Install

```sh
npm install midu-superid-plugin
pnpm add midu-superid-plugin
yarn add midu-superid-plugin
bun add midu-superid-plugin
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.3.22 |
| Published | 2019-10-09 |
| First published | 2019-05-08 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 48.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | erpanomer |

## Links

- npm: https://www.npmjs.com/package/midu-superid-plugin
- npm.io page: https://npm.io/package/midu-superid-plugin

## Recent versions

- 1.3.22 (latest) — 2019-10-09
- 1.3.21 — 2019-09-18
- 1.3.20 — 2019-09-18
- 1.3.19 — 2019-09-18
- 1.3.18 — 2019-09-18
- 1.3.17 — 2019-09-18
- 1.3.16 — 2019-09-11
- 1.3.15 — 2019-09-09
- 1.3.14 — 2019-09-09
- 1.3.13 — 2019-09-09
- 1.3.12 — 2019-09-06
- 1.3.11 — 2019-08-07
- 1.3.10 — 2019-08-07
- 1.3.9 — 2019-08-07
- 1.3.8 — 2019-08-07
- … 31 more at https://npm.io/package/midu-superid-plugin/versions

## README

# midu-superid-plugin

## Install

`npm i -S midu-superid-plugin`

## Import Plugin

```js
import SuperID from 'midu-superid-plugin'
// or
const SuperID = require('midu-superid-plugin')
```

## Use Plugin
```js
import SuperID from 'midu-superid-plugin'

const appID = 'Your Midu Chrome Extentions Appid'

const superid = await SuperID.connect(appID)
if (!superid) {
  return console.error('no Midu Chrome Extensions')
}

//  login Midu Extentions
const user = await superid.login()
//   returns user info
console.log(user)
```

## Plugin Api
> login 插件登陆

 - parameters (object)</br>
 `channelId`: 登陆的路径(企业邮箱，链空间等等) default: 1

 - returns</br>
 用户信息包括 Session

 - examples
```js
 //  login Midu Extentions
const user = await superid.login()
//   returns user info
console.log(user)
```

----------
> settingSuperID 设置Superid

 - parameters (object)</br>
 `superId`: 用户设置的superid (必填)

 - returns</br>
 成功信息

 - examples
 ```js
 superid.settingSuperID({ superId: 123 })
 ```

----------
> purchaseSuperID 购买超级用户名

 - parameters (object)</br>
 `loginName`: 用户需要购买的超级用户名 (必填)</br>
 `currentPrice`: 该用户名的价格 (必填)

 - returns</br>
 成功信息

 - examples
```js
superid.purchaseSuperID({
    loginName: 'midu888',
    currentPrice: '1000'
})
```

----------
> getPayOrderId 获取订单编号

 - parameters (object)</br>
 `orderId`: 支付 时发送的成功是返回的订单id (必填)

 - returns</br>
 成功信息

 - examples
```js
superid.getPayOrderId({
    orderId: '121345622551222'
})
```

## updating...

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