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 4w 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 46% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity62

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

2825d 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.

762297.9k52](/packages/civicrm-civicrm-core)[tempest/framework

The PHP framework that gets out of your way.

2.3k37.6k20](/packages/tempest-framework)[xeroapi/xero-php-oauth2

Xero official PHP SDK for oAuth2 generated with OpenAPI spec 3

1074.9M20](/packages/xeroapi-xero-php-oauth2)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

353.6k](/packages/eslazarev-wildberries-sdk)[mikopbx/core

Free PBX system for SMB based on Asterisk

5711.4k](/packages/mikopbx-core)

PHPackages © 2026

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