open-index/open-npm huggingface dataset:
npm package: @monaco-auth/adapter-prisma
Description: Prisma database adapter for Monaco
Author: pilcrowOnPaper
Latest version: 0.0.2

# `@monaco-auth/adapter-prisma`

## Installation

```
npm install @monaco-auth/adapter-prisma
```

## Usage

```ts
import { PrismaAdapter } from "@monaco-auth/adapter-prisma";
import { PrismaClient } from "@prisma/client";

const client = new PrismaClient();

const adapter = new PrismaAdapter(client);
```

```prisma
model User {
  id            String    @id
  username      String
  email         String?
  emailVerified Boolean
  oauthId       String    @unique
  profileImage  String?
  sessions      Session[]
}

model Session {
  id        String   @id
  expiresAt DateTime
  userId    String
  user      User     @relation(fields: [userId], references: [id])
}
```
npm package: @monaco-auth/core
Description: The basic OAuth library
Author: pilcrowOnPaper
Latest version: 0.0.2

# `@monaco-auth/core`

## Installation

```ts
npm install @monaco-auth/core
```

## Providers

### GitHub

- Login URL: `/login/github`
- Callback URL: `/login/github/callback` (e.g. `https://example.com/login/github/callback`)

```ts
import { GitHubProvider } from "@monaco-auth/core/providers";

const githubProvider = new GitHubProvider(clientId, clientSecret);
```

### Google

- Login URL: `/login/google`
- Callback URL: `/login/google/callback` (e.g. `https://example.com/login/google/callback`)

```ts
import { GoogleProvider } from "@monaco-auth/core/providers";

const googleProvider = new GoogleProvider(clientId, clientSecret);
```
npm package: @monaco-auth/sveltekit
Description: SvelteKit integration for Monaco
Author: pilcrowOnPaper
Latest version: 0.1.1

# `@monaco-auth/sveltekit`

SvelteKit integration for Monaco. For a full list of OAuth providers, see [`@monaco-auth/core`](https://github.com/pilcrowOnPaper/monaco/tree/main/packages/core).

See the [SvelteKit example](https://github.com/pilcrowOnPaper/monaco/tree/main/examples/sveltekit) for details.

## Installation

Install the integration with the core package:

```
npm install @monaco-auth/sveltekit @monaco-auth/core
```

Make sure to install an adapter as well:

```
npm install @monaco-auth/adapter-prisma
```

## Setup

### `.env`

Define the app url. If you define a path, all auth routes will be defined within it (e.g. `/auth/login/github`).

```bash
MONACO_BASE_URL="http://localhost:5173"
```

### Hooks

```ts
// src/hooks.server.ts
import { PrismaAdapter } from "@monaco-auth/adapter-prisma";
import { monaco } from "@monaco-auth/sveltekit";
import { GitHubProvider } from "@monaco-auth/core/providers";
import { PrismaClient } from "@prisma/client";
import { dev } from "$app/environment";
import { GITHUB_CLIENT_ID, GITHUB_CLIENT_SECRET } from "$env/static/private";

import type { Handle } from "@sveltejs/kit";

const client = new PrismaClient();

export const handle: Handle = monaco(new PrismaAdapter(client), {
	dev, // IMPORTANT!
	providers: [new GitHubProvider(GITHUB_CLIENT_ID, GITHUB_CLIENT_SECRET)]
});
```

### Local types

```ts
// src/app.d.ts
declare global {
	namespace App {
		interface Locals {
			user: import("@monaco-auth/core").User | null;
		}
	}
}

export {};
```

### Login page

Create a login page in `src/routes/login/+page.svelte`.

See [`@monaco-auth/core` providers section](https://github.com/pilcrowOnPaper/monaco/tree/main/packages/core#providers) for each provider's login URL.

```svelte
<h1>Sign in</h1>
<a href="/login/github">Sign in with Github</a>
```

### Logout page

A logout endpoint is automatically created.

```svelte
<form method="post" action="/logout"  >
	<button>Sign out</button>
</form>
```

## Usage

You can access the current user in the server with `event.locals.user`.

```ts
// +page.server.ts
import { redirect } from "@sveltejs/kit";
import type { PageServerLoad } from "./$types";

export const load: PageServerLoad = async (event) => {
	if (!event.locals.user) throw redirect(302, "/login");
	return {
		user: event.locals.user
	};
};
```
npm package: @monaco-ex/bitcore-message
Description: Bitcoin Messages for Bitcore
Author: BitPay
Latest version: 1.0.3-500-beta1

<img src="http://bitcore.io/css/images/module-message.png" alt="bitcore message" height="35">
# Bitcoin Message Verification and Signing for Bitcore


[![NPM Package](https://img.shields.io/npm/v/bitcore-message.svg?style=flat-square)](https://www.npmjs.org/package/bitcore-message)
[![Build Status](https://img.shields.io/travis/bitpay/bitcore-message.svg?branch=master&style=flat-square)](https://travis-ci.org/bitpay/bitcore-message)
[![Coverage Status](https://img.shields.io/coveralls/bitpay/bitcore-message.svg?style=flat-square)](https://coveralls.io/r/bitpay/bitcore-message?branch=master)

bitcore-message adds support for verifying and signing bitcoin messages in [Node.js](http://nodejs.org/) and web browsers.

See [the main bitcore repo](https://github.com/bitpay/bitcore) for more information.

## Getting Started

```sh
npm install bitcore-message
```

```sh
bower install bitcore-message
```

To sign a message:

```javascript
var bitcore = require('bitcore-lib');
var Message = require('bitcore-message');

var privateKey = bitcore.PrivateKey.fromWIF('cPBn5A4ikZvBTQ8D7NnvHZYCAxzDZ5Z2TSGW2LkyPiLxqYaJPBW4');
var signature = Message('hello, world').sign(privateKey);
```

To verify a message:

```javascript
var address = 'n1ZCYg9YXtB5XCZazLxSmPDa8iwJRZHhGx';
var signature = 'H/DIn8uA1scAuKLlCx+/9LnAcJtwQQ0PmcPrJUq90aboLv3fH5fFvY+vmbfOSFEtGarznYli6ShPr9RXwY9UrIY=';
var verified = Message('hello, world').verify(address, signature);
```

## Contributing

See [CONTRIBUTING.md](https://github.com/bitpay/bitcore/blob/master/CONTRIBUTING.md) on the main bitcore repo for information about how to contribute.

## License

Code released under [the MIT license](https://github.com/bitpay/bitcore/blob/master/LICENSE).

Copyright 2013-2015 BitPay, Inc. Bitcore is a trademark maintained by BitPay, Inc.
npm package: @monaco-ex/coininfo
Description: JavaScript component for crypto currency specific information.
Latest version: 2.2.0-monacoex-1

coininfo
========

[![build status](https://api.travis-ci.org/cryptocoinjs/coininfo.svg)](http://travis-ci.org/cryptocoinjs/coininfo)

JavaScript component for crypto currency specific information such as version numbers, DNS seeds, etc.
Works in Node.js and the browser.


Installation
------------

    npm i --save coininfo


Usage
-----

```js
var coininfo = require('coininfo')

console.dir(coininfo('LTC')) //use LTC-TEST for testnet
// =>
/*
{ versions:
   { public: 48,
     private: 176,
     scripthash: 5,
     bip32: { public: 27108450, private: 27106558 } } }
*/
```

Could also:

```js
var litecoin = coininfo.litecoin.main
var litecoinTest = coininfo.litecoin.test
```

Useful to use in conjunction with [coinkey](https://github.com/cryptocoinjs/coinkey) and [coinstring](https://github.com/cryptocoinjs/coinstring).


Want to Use With Bitcore or bitconjs-lib?
-----------------------------------------

**bitcoinjs-lib example:**

```js
var coininfo = require('coininfo')
var bitcoin = coininfo.bitcoin.main
var bitcoinBitcoinJSLib = bitcoin.toBitcoinJS()
```

**Bitcore example:**

```js
var coininfo = require('coininfo')
var bitcoin = coininfo.bitcoin.main
var bitcoinBitcoreLib = bitcoin.toBitcore()
```


Pull requests?
--------------

Follow the canonical example:

https://github.com/cryptocoinjs/coininfo/blob/master/lib/coins/btc.js


License
-------

MIT
npm package: @monaco-ex/hubot-twitter-userstream
Description: hubot-twitter-userstream is an adapter for Hubot that allows you to use the hubot with Twitter on user TL.
Author: hoo89
Latest version: 0.0.3

# hubot-twitter-userstream

hubot-twitter-userstream is an adapter for [Hubot](https://hubot.github.com/) that allows you to use the hubot with Twitter on user TL.

It differs from [hubot-twitter](https://github.com/MathildeLemee/hubot-twitter)...
* It can watch user timeline.
* It can receive and send direct message.
* It can follow and remove users.
* It can receive some events(favorited, followed, ...).

## Installation
    $ hubot --create myhubot
    $ cd myhubot
    $ npm install hubot-twitter-userstream --save && npm install

## Usage
At first, you will need to set some API keys.

    $ export HUBOT_TWITTER_KEY="key"
    $ export HUBOT_TWITTER_SECRET="secret"
    $ export HUBOT_TWITTER_TOKEN="token"
    $ export HUBOT_TWITTER_TOKEN_SECRET="secret"

## Messages
Properties of received message.

    {
    	id: <status_id>,
    	user: {id: <user_id>, name: <screen_name>, room: <"Twitter" or "TwitterDirectMessage"> },
    	text: <body of message>,
    	data: <raw object of tweet or direct message>
    }

## Events

    favorited - {user: <user object of favorited user>, tweet: <favorited tweet>}
    unfavorited - {user: <user object of unfavorited user>, tweet: <unfavorited tweet>}
    followed - {user: <user object of followed user>}
    unfollowed - {user: <user object of followed user>}

## Copyright
Copyright(c) 2014 hoo89 http://hoo89.hatenablog.com/ hoo89@me.com

This source licensed under the MIT license.