# @rhlsthrm/grpc-mock-server

> gRPC mock server written on typescript

Latest version **1.1.8** (published 2021-01-22) · MIT license · 0 weekly downloads

## Install

```sh
npm install @rhlsthrm/grpc-mock-server
pnpm add @rhlsthrm/grpc-mock-server
yarn add @rhlsthrm/grpc-mock-server
bun add @rhlsthrm/grpc-mock-server
```

## Health

**Score 35/100 (D)** — status: abandoned.

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

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.1.8 |
| Published | 2021-01-22 |
| First published | 2021-01-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 8 |
| Unpacked size | 7.4 KB |
| Known vulnerabilities | 0 (+11 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 22 |
| Author | Yevdo Abramov |
| Maintainers | rhlsthrm |
| Keywords | grpc, mock, server, typescript |

## Links

- npm: https://www.npmjs.com/package/@rhlsthrm/grpc-mock-server
- Repository: https://github.com/alenon/grpc-mock-server
- Homepage: https://github.com/alenon/grpc-mock-server#readme
- Issues: https://github.com/alenon/grpc-mock-server/issues
- npm.io page: https://npm.io/package/@rhlsthrm/grpc-mock-server

## Dependencies (8)

- [grpc](https://npm.io/package/grpc.md) ^1.24.2
- [debug](https://npm.io/package/debug.md) ^4.1.1
- [protobufjs](https://npm.io/package/protobufjs.md) ^6.9.0
- [@types/node](https://npm.io/package/@types/node.md) ^11.15.12
- [@types/debug](https://npm.io/package/@types/debug.md) ^4.1.5
- [google-protobuf](https://npm.io/package/google-protobuf.md) ^3.11.4
- [@types/protobufjs](https://npm.io/package/@types/protobufjs.md) ^6.0.0
- [@types/google-protobuf](https://npm.io/package/@types/google-protobuf.md) ^3.7.2

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.1.8 (latest) — 2021-01-22

## README

# grpc-mock-server
gRPC mock server for tests with typescript definitions.

![NPM CI](https://github.com/alenon/grpc-mock-server/workflows/NPM%20CI/badge.svg)

Usage example:
```typescript
private static readonly PROTO_PATH: string = __dirname + "example.proto";
private static readonly PKG_NAME: string = "com.alenon.example";
private static readonly SERVICE_NAME: string = "ExampleService";

...
    
const implementations = {
    ex1: (call: any, callback: any) => {
        const response: any =
            new this.proto.ExampleResponse.constructor({msg: "the response message"});
        callback(null, response);
    },
};

this.server.addService(PROTO_PATH, PKG_NAME, SERVICE_NAME, implementations);
this.server.start();
```

---
_Source: https://npm.io/package/@rhlsthrm/grpc-mock-server · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
