open-index/open-npm huggingface dataset:
npm package: @neo4j/browser-lambda-parser
Description: ## Installation ``` $ nvm use && npm ci ```
Latest version: 1.0.6

# lambda-parser

## Installation
```
$ nvm use && npm ci
```

## Testing
```
$ npm test
```

## Debug
```
$ npm run debug
```

## Play around
https://omrelli.ug/nearley-playground/  

**Note**, you'll need to remove the line with `@preprocessor esmodule` from the grammar when loading it into the playground.

## Generate railroad
```
$ npm run railroad
```

## View railroad
http://htmlpreview.github.io/?https://github.com/huboneo/lambda-parser/blob/master/railroad.html
npm package: @neo4j/code-signer
Description: A CLI tool for signing code
Author: Neo4j Inc.
Latest version: 1.1.4

# Code Signer

A CLI tool for signing code used by Neo4j Graph platform.
Creates a `signature.pem` file in the signed folder.
If verifies signatures locally and against Neo4j:s CRL server
for revoked certificates when online.

## Usage

Sign `my-graph-app` directory:

```bash

npx @neo4j/code-signer --app ./my-graph-app-folder \
  --private-key ./private-key.pem \
  --cert ./certificate.pem \
  --passphrase your-private-key-passphrase

```

Verify `my-graph-app`:

```bash

npx @neo4j/code-signer --verify \
  --app ./my-graph-app-folder \
  --root-cert ./rootCA.pem
```

You can also pass the `--skip-revocation-check` flag to skip the certificate revocation check against Neo4j:s CRL server.

## Common usage pattern

These steps are usually what's needed to sign a node application.

```
# build your app
npm run build

# pack you app
npm pack

# unpack your app
tar xvzf *.tgz

# sign unpacked app folder
npx @neo4j/code-signer --app ./package \
  --private-key ../private-key.pem \
  --cert ../certificate.pem \
  --passphrase your-private-key-passphrase

# pack app again, from inside package/ folder. Important!
cd package
npm pack

# publish, still inside package/ folder
npm publish *.tgz


```

## Development

- Build: `npm build`
- Test: `npm test`
- Package: `npm pack`
npm package: @neo4j/cypher-builder
Description: A programmatic API for building Cypher queries for Neo4j
Author: Neo4j Inc.
Latest version: 3.0.1

# Cypher Builder

[![npm version](https://badge.fury.io/js/@neo4j%2Fcypher-builder.svg)](https://www.npmjs.com/package/@neo4j/cypher-builder)
[![Test](https://github.com/neo4j/cypher-builder/actions/workflows/test.yml/badge.svg)](https://github.com/neo4j/cypher-builder/actions/workflows/test.yml)
[![Lint](https://github.com/neo4j/cypher-builder/actions/workflows/lint.yml/badge.svg)](https://github.com/neo4j/cypher-builder/actions/workflows/lint.yml)

Cypher Builder is a JavaScript programmatic API to create [Cypher](https://neo4j.com/docs/cypher-manual/current/) queries for [Neo4j](https://neo4j.com/).

- [Documentation](https://neo4j.com/docs/cypher-builder/current/)

```typescript
import Cypher from "@neo4j/cypher-builder";

const movieNode = new Cypher.Node();
const pattern = new Cypher.Pattern(movieNode, { labels: ["Movie"] });

const matchQuery = new Cypher.Match(pattern)
    .where(movieNode, {
        title: new Cypher.Param("The Matrix"),
    })
    .return(movieNode.property("title"));

const { cypher, params } = matchQuery.build();

console.log(cypher);
console.log(params);
```

_Cypher_

```cypher
MATCH (this0:Movie)
WHERE this0.title = $param0
RETURN this0.title
```

_Params_

```typescript
{
    "param0": "The Matrix",
}
```

# Contributing

See our [contributing guide](./CONTRIBUTING.md) for development instructions.

# Examples

You can find usage examples in the [examples](https://github.com/neo4j/cypher-builder/tree/main/examples) folder.

> This library is for JavaScript and TypeScript only. If you are using Java, check [Neo4j Cypher DSL](https://neo4j.github.io/cypher-dsl).
npm package: @neo4j/graph-introspection
Description: Library for introspecting Neo4j graph schemas
Latest version: 1.0.0-next.3

## Neo4j Schema Introspection

### Usage

```ts
import neo4j, { session } from "neo4j-driver";
import { model } from "@neo4j/graph-schema-utils";
import { introspect, sessionFactory } from "@neo4j/graph-introspection";

async function main() {
  const driver = neo4j.driver(
    "neo4j://localhost:7687",
    neo4j.auth.basic("neo4j", "password")
  );

  // We want a session factory here so we can work in multiple sessions
  const graphSchema = await introspect(sessionFactory(driver, session.READ));

  // Put it in the JSON representation wrapper
  // this is only required if the serialized representation is the end goal
  const wrappedSchema = new model.GraphSchemaRepresentation(
    "1.0.0",
    graphSchema
  );

  // outputs standard graph schema JSON representation
  console.log(wrappedSchema.toJson(2));

  await driver.close();
}

main();
```

### Testing

Running `npm run test:integration` will create a new database named `integration.tests` and delete it after the tests finish.  
This means you'd need Neo4j Enterprise to run the integration tests and put credentials in `.env` file.

To spin up a docker container for running tests, run this command:

```bash
docker run \
    --name testneo4j \
    --rm \
    -p7474:7474 -p7687:7687 \
    --env NEO4J_ACCEPT_LICENSE_AGREEMENT=eval \
    --env NEO4J_AUTH=neo4j/password \
    neo4j:enterprise
```
npm package: @neo4j/graph-schema-utils
Description: Utilities for Neo4j Graph Schema JSON representation
Latest version: 1.0.0-next.19

# Consume

## Install for consumption

```bash
npm install @neo4j/graph-schema-utils
```

## Use

### Validate

This function is needed to perform a validation on a graph schema. The validateSchema function compares the output against the JSON schema.

```js
import { validateSchema } from "@neo4j/graph-schema-utils";

validateSchema(jsonSchema, graphSchema);
```

### Model

You can also create a schema model programatically.
Example:

```js
import { model } from "@neo4j/graph-schema-utils";

const labels = [
  new model.NodeLabel("l1", "Person"),
  new model.NodeLabel("l1", "Movie"),
];

const relationshipTypes = [new model.RelationshipType("rt1", "ACTED_IN")];

const properties = [
  new model.Property("name", new model.PropertyBaseType("string"), true),
  new model.Property("title", new model.PropertyBaseType("string"), true),
  new model.Property(
    "roles",
    new model.PropertyArrayType(new model.PropertyBaseType("string")),
    false
  ),
];

const nodeObjectTypes = [
  new model.NodeObjectType("n1", [labels[0]], [properties[0]]), // (:Person {name}) node type
  new model.NodeObjectType("n2", [labels[1]], [properties[1]]), // (:Movie {title}) node type
];

const relationshipObjectTypes = [
  // (:Person {name})-[:ACTED_IN {roles}]->(:Movie {title})
  new model.RelationshipObjectType(
    "r1",
    relationshipTypes[0],
    nodeObjectTypes[0],
    nodeObjectTypes[1],
    [properties[2]]
  ),
];

const graphSchema = new model.GraphSchema(
  nodeObjectTypes,
  relationshipObjectTypes
);
```

# Develop / Contribute

## Install dependencies

```
npm install
```

## Run script

```
npm start
# or
node ./src/index.js
```
npm package: @neo4j/graphql-plugin-auth
Description: Auth decode plugins for @neo4j/graphql
Author: Neo4j Inc.
Latest version: 2.2.0

# @neo4j/graphql-plugin-auth

Auth decode plugins for @neo4j/graphql

1. [Documentation](https://neo4j.com/docs/graphql-manual/current/auth/)

## Installation

```
$ npm install @neo4j/graphql-plugin-auth
```

## Usage

### `Neo4jGraphQLAuthJWTPlugin`

```ts
import { Neo4jGraphQL } from "@neo4j/graphql";
import { Neo4jGraphQLAuthJWTPlugin } from "@neo4j/graphql-plugin-auth";

const neoSchema = new Neo4jGraphQL({
    typeDefs,
    plugins: {
        auth: new Neo4jGraphQLAuthJWTPlugin({
            secret: "super-secret",
        }),
    },
});

// Or you can initiate the secret with a function which will run to retrieve the secret when the request comes in

const neoSchema = new Neo4jGraphQL({
    typeDefs,
    plugins: {
        auth: new Neo4jGraphQLAuthJWTPlugin({
            secret: (req) => {
                return "super-secret";
            },
        }),
    },
});
```

### `Neo4jGraphQLAuthJWKSPlugin`

```ts
import { Neo4jGraphQL } from "@neo4j/graphql";
import { Neo4jGraphQLAuthJWKSPlugin } from "@neo4j/graphql-plugin-auth";

const neoSchema = new Neo4jGraphQL({
    typeDefs,
    plugins: {
        auth: new Neo4jGraphQLAuthJWKSPlugin({
            jwksEndpoint: "https://YOUR_DOMAIN/well-known/jwks.json",
        }),
    },
});

//Or you can pass a function as jskwsEndpoint to compute the endpoint when the request comes in.

const neoSchema = new Neo4jGraphQL({
    typeDefs,
    plugins: {
        auth: new Neo4jGraphQLAuthJWKSPlugin({
            jwksEndpoint: (req) => {
                let url = "https://YOUR_DOMAIN/well-known/{file}.json";
                const fileHeader = req.headers["file"];
                url = url.replace("{file}", fileHeader);
                return url;
            },
        }),
    },
});
```

## Licence

[Apache 2.0](https://github.com/neo4j/graphql/blob/master/packages/graphql-plugin-auth/LICENSE.txt)
npm package: @neo4j/graphql-plugin-subscriptions-amqp
Description: Subscription plugin for @neo4j/graphql, supporting AMQP brokers such as RabbitMQ
Author: Neo4j Inc.
Latest version: 2.0.0

# @neo4j/graphql-plugin-subscriptions-amqp

Subscription plugin for `@neo4j/graphql`, currently supporting AMQP 0-9-1 brokers such as:

-   RabbitMQ
-   Apache Qpid
-   Apache ActiveMQ

[Documentation](https://neo4j.com/docs/graphql-manual/current/subscriptions/)

## Installation

```
npm install @neo4j/graphql-plugin-subscriptions-amqp
```

## Usage

```javascript
const { Neo4jGraphQLSubscriptionsAMQPPlugin } = require("@neo4j/graphql-plugin-subscriptions-amqp");

const plugin = new Neo4jGraphQLSubscriptionsAMQPPlugin({
    connection: {
        hostname: "localhost",
        username: "guest",
        password: "guest",
    },
});

const neoSchema = new Neo4jGraphQL({
    typeDefs,
    driver,
    plugins: {
        subscriptions: plugin,
    },
});
```

To close the connection with RabbitMQ:

```javascript
await plugin.close();
```

## Options

The following options are available in the plugin.

-   **connection**: [AMQP](https://www.npmjs.com/package/amqplib) connection options or amqp url (e.g. `amqp://localhost`).
-   **exchange**: (optional) Queue exchange, defaults to `neo4j.graphql.subscriptions.fx`.
-   **reconnectTimeout**: (optional) Timeout (in ms) between reconnection attempts. If not set, the plugin will not reconnect. Note that if the first connection fails, it will not attempt to reconnect.
-   **log**: (optional) Enable AMQP logs, defaults to `true`.
-   **amqpVersion**: (optional) AMQP version to use, only `0-9-1` supported at the moment.

## Running tests

-   `yarn test` to run unit tests
-   `yarn test:e2e` to run integration tests. These tests require a RabbitMQ instance running, and are not run by default
    -   Use `docker-compose up rabbitmq` to spin up a RabbitMQ container for testing
    -   Use `docker-compose up qpid` to spin up a Qpid container for testing

## Licence

[Apache 2.0](https://github.com/neo4j/graphql/blob/master/packages/graphql-plugin-auth/LICENSE.txt)