Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jpmonette/req-ts
A JavaScript client library for accessing the Registre des entreprises du Québec. 🏢🇨🇦
https://github.com/jpmonette/req-ts
api-client opendata quebec registry
Last synced: 19 days ago
JSON representation
A JavaScript client library for accessing the Registre des entreprises du Québec. 🏢🇨🇦
- Host: GitHub
- URL: https://github.com/jpmonette/req-ts
- Owner: jpmonette
- License: mit
- Created: 2017-11-26T17:35:22.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-09T08:20:06.000Z (about 2 years ago)
- Last Synced: 2024-04-15T00:16:20.969Z (9 months ago)
- Topics: api-client, opendata, quebec, registry
- Language: TypeScript
- Size: 872 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 14
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
@jpmonette/req
@jpmonette/req
- a JavaScript client library for accessing the Registre des entreprises du Québec.# Getting Started
## Installation
```sh
$ yarn add @jpmonette/req
```## Usage
### Import
#### Using Node
```ts
import REQ from "req";
```#### Using Deno
```ts
import REQ from "https://deno.land/x/[email protected]/src/index.ts";
```### Search a NEQ
```ts
const client = new REQ();
const company = await client.getNEQ("1143920115");
console.log(company.SectionInformationsGenerales.SousSecIdentification.NomEntreprise);
// Output: BOMBARDIER INC.
```### Search the registry
```ts
const client = new REQ();
const companies = await client.search({ keywords: "mrc" });companies.ListeEntreprises.map((company) => {
console.log(`(${company.NumeroDossier}) ${company.Nom}`);
});
// Output:
// (1165737934) M.R.C.
// (2260227451) M.R.C.
// (1161426722) MRC CARE
// (1142443804) MRC GROUP
// ...
```## Roadmap
This library is being initially developed for one of my internal project,
so API methods will likely be implemented in the order that they are
needed by my project. Eventually, I would like to cover the entire API,
so contributions are of course [always welcome][contributing]. The
calling pattern is pretty well established, so adding new methods is relatively
straightforward.[contributing]: CONTRIBUTING.md
## License
This library is distributed under the MIT license found in the [LICENSE](./LICENSE)
file.