# french-phone-api

> Get information about any French phone numbers.

Latest version **1.0.13** (published 2021-05-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install french-phone-api
pnpm add french-phone-api
yarn add french-phone-api
bun add french-phone-api
```

## Health

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

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

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.13 |
| Published | 2021-05-15 |
| First published | 2018-09-29 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | >=8.0.0 |
| Dependencies | 4 |
| Unpacked size | 8.5 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Damien Marchand |
| Maintainers | damienmarchandfr |
| Keywords | phone, french, information |

## Links

- npm: https://www.npmjs.com/package/french-phone-api
- Repository: https://github.com/damienmarchandfr/french-phone-api
- npm.io page: https://npm.io/package/french-phone-api

## Dependencies (4)

- [cheerio](https://npm.io/package/cheerio.md) ^1.0.0-rc.9
- [request](https://npm.io/package/request.md) ^2.88.2
- [request-promise](https://npm.io/package/request-promise.md) ^4.2.6
- [awesome-phonenumber](https://npm.io/package/awesome-phonenumber.md) ^2.51.1

## Recent versions

- 1.0.13 (latest) — 2021-05-15
- 1.0.12 — 2020-06-08
- 1.0.11 — 2020-06-08
- 1.0.10 — 2019-12-28
- 1.0.9 — 2019-12-28
- 1.0.8 — 2019-10-05
- 1.0.7 — 2019-10-05
- 1.0.6 — 2018-11-08
- 1.0.5 — 2018-10-01
- 1.0.4 — 2018-10-01
- 1.0.3 — 2018-09-29
- 1.0.2 — 2018-09-29
- 1.0.1 — 2018-09-29

## README

# FRENCH PHONE API

This small JavaScript library returns information about any French phone numbers from this [website](https://www.recherche-inverse.com/) in a JSON format.

[![Build Status](https://travis-ci.com/damienmarchandfr/french-phone-api.svg?branch=master)](https://travis-ci.com/damienmarchandfr/french-phone-api)

**It works with FRENCH phone numbers ONLY.**

## Installation

    yarn add french-phone-api

or

    npm i french-phone-api --save

## Use

**With JavaScript**

    var F = require('french-phone-api')
    new F.FrenchPhoneInfoGetter('0782301616')
    	.getInformation()
    	.then((result)=>{
    		console.log(result)
    	})
    	.catch(err=>{
    		console.log(err)
    	})

**Or with TypeScript**

    import {FrenchPhoneInfoGetter} from  'french-phone-api'

    try {
    	const  result  =  await  new  FrenchPhoneInfoGetter('0782301615').getInformation()
    	console.log(result)
    } catch (error) {
    	console.log(error)
    }

## Response

    {
    	input: '0778453625',
       	formatted: '+33778453625',
    	isMobile: true,
    	danger: 0,
    	operator: 'free'
    }

## Test

To run tests

    yarn run test

or

    npm run test

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