PHPackages                             tangkoko/dynamics-sdk-php - 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. [API Development](/categories/api)
4. /
5. tangkoko/dynamics-sdk-php

ActiveLibrary[API Development](/categories/api)

tangkoko/dynamics-sdk-php
=========================

Saint Systems Microsoft Dynamics 365 SDK for PHP

0.1.0(5y ago)073MITPHPPHP &gt;=5.3.0

Since Mar 9Pushed 3y agoCompare

[ Source](https://github.com/nicoren-tangkoko/dynamics-sdk-php)[ Packagist](https://packagist.org/packages/tangkoko/dynamics-sdk-php)[ Docs](https://github.com/saintsystems/dynamics-sdk-php)[ RSS](/packages/tangkoko-dynamics-sdk-php/feed)WikiDiscussions master Synced 2d ago

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

Get started with the Saint Systems Microsoft Dynamics 365 SDK for PHP
=====================================================================

[](#get-started-with-the-saint-systems-microsoft-dynamics-365-sdk-for-php)

*This SDK is currently in preview. Please continue to provide [feedback](https://github.com/saintsystems/dynamics-sdk-php/issues/new) as we iterate towards a production-supported library.*

[![Build Status](https://camo.githubusercontent.com/d7fde074683f7f6600a3dc815f4492076664d1ba2c7720c6a930b1ba3b376435/68747470733a2f2f7472617669732d63692e6f72672f7361696e7473797374656d732f64796e616d6963732d73646b2d7068702e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/saintsystems/dynamics-sdk-php)

Install the SDK
---------------

[](#install-the-sdk)

You can install the PHP SDK with Composer.

```
{
    "require": {
        "Microsoft/Dynamics": "0.1.*"
    }
}

```

Get started with Microsoft Dynamics 365
---------------------------------------

[](#get-started-with-microsoft-dynamics-365)

### Register your application

[](#register-your-application)

Register your application to use the Microsoft Dynamics 365 API by using one of the following supported authentication portals:

- [Microsoft Azure Active Directory](https://manage.windowsazure.com): Register a new application in your tenant's Active Directory to support work or school users for your tenant, or multiple tenants.
- [Microsoft Application Registration Portal](https://apps.dev.microsoft.com) (**Coming Soon**): Register a new application that authenticates using the v2.0 authentication endpoint. This endpoint authenticates both personal (Microsoft) and work or school (Azure Active Directory) accounts.

### Authenticate with the Microsoft Graph service

[](#authenticate-with-the-microsoft-graph-service)

The Microsoft Dynamics 365 SDK for PHP does not include any default authentication implementations. Instead, you can authenticate with the library of your choice.

When authenticating, you simply need to request access to your Dynamics 365 instance URL using the `resource` parameter of Azure AD.

### Call Microsoft Dynamics 365

[](#call-microsoft-dynamics-365)

The following is an example that shows how to call Microsoft Dynamics 365 Web API.

```
use Microsoft\Dynamics\Dynamics;
use Microsoft\Dynamics\Model;

class UsageExample
{
    $instanceUrl = 'https://contoso.crm.dynamics.com';
    $accessToken = 'xxx';

    $dynamics = new Dynamics();
    $dynamics->setInstanceUrl($instanceUrl)
             ->setAccessToken($accessToken);

    $leads = $dynamics->createRequest("GET", "/leads")
                  ->setReturnType(Model\Lead::class)
                  ->execute();

    $lead = $leads[0];

    echo "Hello, I am $lead->getFirstName() ";

    // OR GET a specific lead by ID

    $lead = $dynamics->createRequest("GET", "/leads(xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)")
                  ->setReturnType(Model\Lead::class)
                  ->execute();

    echo "Hello, I am $lead->getFirstName() ";
}
```

Develop
-------

[](#develop)

### Run Tests

[](#run-tests)

Run `vendor/bin/phpunit` from the base directory.

Documentation and resources
---------------------------

[](#documentation-and-resources)

- [Documentation](https://github.com/saintsystems/dynamics-sdk-php/blob/master/docs/index.html)
- [Wiki](https://github.com/saintsystems/dynamics-sdk-php/wiki)
- [Examples](https://github.com/saintsystems/dynamics-sdk-php/wiki/Example-calls)
- [Microsoft Dynamics 365 website](https://www.microsoft.com/en-us/dynamics365)
- [Microsoft Dynamics 365 Web API Documentation](https://msdn.microsoft.com/library/mt593051.aspx#documentation)

Issues
------

[](#issues)

View or log issues on the [Issues](https://github.com/saintsystems/dynamics-sdk-php/issues) tab in the repo.

Copyright and license
---------------------

[](#copyright-and-license)

Copyright (c) Saint Systems, LLC. All Rights Reserved. Licensed under the MIT [license](LICENSE).

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

 Bus Factor1

Top contributor holds 84.8% 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

1889d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1cf0ef18e52853b26f1b8121f9712144043987e575dee701e66593c760ae8924?d=identicon)[nrenault.tangkoko](/maintainers/nrenault.tangkoko)

---

Top Contributors

[![anderly](https://avatars.githubusercontent.com/u/573151?v=4)](https://github.com/anderly "anderly (39 commits)")[![nicoren-tangkoko](https://avatars.githubusercontent.com/u/9478056?v=4)](https://github.com/nicoren-tangkoko "nicoren-tangkoko (7 commits)")

---

Tags

sdkcrmDynamics CRMDynamicsDynamics 365xrm

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/tangkoko-dynamics-sdk-php/health.svg)

```
[![Health](https://phpackages.com/badges/tangkoko-dynamics-sdk-php/health.svg)](https://phpackages.com/packages/tangkoko-dynamics-sdk-php)
```

###  Alternatives

[checkout/checkout-sdk-php

Checkout.com SDK for PHP

553.3M7](/packages/checkout-checkout-sdk-php)[vluzrmos/slack-api

Wrapper for Slack.com WEB API.

102589.1k3](/packages/vluzrmos-slack-api)[alexacrm/php-crm-toolkit

PHP Toolkit for Microsoft Dynamics CRM

109293.3k1](/packages/alexacrm-php-crm-toolkit)[smodav/mpesa

M-Pesa API implementation

16363.7k1](/packages/smodav-mpesa)

PHPackages © 2026

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