PHPackages                             cang-ha/contacts-importer - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. cang-ha/contacts-importer

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

cang-ha/contacts-importer
=========================

Contact importer wrapper for Google, Outlook, Yahoo

v1.0.5(7y ago)0321MITPHP

Since Nov 20Pushed 7y ago1 watchersCompare

[ Source](https://github.com/cang-ha/contacts-importer)[ Packagist](https://packagist.org/packages/cang-ha/contacts-importer)[ Docs](https://github.com/cang-ha/contacts-importer)[ RSS](/packages/cang-ha-contacts-importer/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (1)Dependencies (5)Versions (2)Used By (0)

Contacts Importer
=================

[](#contacts-importer)

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

[](#installation)

To install, use composer:

```
composer require cang-ha/contacts-importer

```

Usage
-----

[](#usage)

```
$clientID = 'your_client_id';
$clientSecret = 'your_client_secret';
$redirectUri = 'your_redirect_url';

$googleImporter = new GoogleImporter($clientID, $clientSecret, $redirectUri);

try {
    $googleImporter->processCallback();
    $contactsGoogle = $googleImporter->getContacts();

    //store token for later use
    $tokenGoogle = [
        'accessToken' => $googleImporter->getAccessToken(),
        'refreshToken' => $googleImporter->getRefreshToken(),
        'expires' => $googleImporter->getExpires()
    ];
    $_SESSION['stored_google_token'] = serialize($tokenGoogle);

    // display the contacts
    foreach ($contactsGoogle as $contact) {
        echo ('Full name: '. $contact->getFullName());
        echo ('First name: '. $contact->getFirstName());
        echo ('Last name: '. $contact->getLastName());
        echo ('Email: '. $contact->getEmail());
    }

} catch (\ContactImporter\Exception\OAuth2\OAuth2InvalidAuthCodeException $e) {
    // handle case where use deny the oauth2 request

} catch (\GuzzleHttp\Exception\GuzzleException $e) {
    // handle restful api request error
}

```

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2779d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/18713510?v=4)[cang-ha](/maintainers/cang-ha)[@cang-ha](https://github.com/cang-ha)

---

Top Contributors

[![cang-ha](https://avatars.githubusercontent.com/u/18713510?v=4)](https://github.com/cang-ha "cang-ha (10 commits)")

---

Tags

googleemailmicrosoftcontactyahooOffice365gmailoutlook

### Embed Badge

![Health badge](/badges/cang-ha-contacts-importer/health.svg)

```
[![Health](https://phpackages.com/badges/cang-ha-contacts-importer/health.svg)](https://phpackages.com/packages/cang-ha-contacts-importer)
```

###  Alternatives

[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

751284.3k37](/packages/civicrm-civicrm-core)[tempest/framework

The PHP framework that gets out of your way.

2.2k31.1k12](/packages/tempest-framework)[dcblogdev/laravel-microsoft-graph

A Laravel Microsoft Graph API (Office365) package

171312.2k4](/packages/dcblogdev-laravel-microsoft-graph)[erag/laravel-disposable-email

A Laravel package to detect and block disposable email addresses.

252143.0k](/packages/erag-laravel-disposable-email)[javanile/php-imap2

PHP IMAP with OAUTH2

65248.6k1](/packages/javanile-php-imap2)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

252.5k](/packages/eslazarev-wildberries-sdk)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
