PHPackages                             doitcloudconsulting/salesforce - 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. doitcloudconsulting/salesforce

ActiveProject[API Development](/categories/api)

doitcloudconsulting/salesforce
==============================

Salesforce ToolKit for Laravel maked by DoIT Cloud Consulting

0.0.2(7y ago)017LGPL-2.0-onlyPHPPHP &gt;=5.6.4

Since Apr 29Pushed 6y ago1 watchersCompare

[ Source](https://github.com/DoITCloudConsulting/Salesforce-PHP)[ Packagist](https://packagist.org/packages/doitcloudconsulting/salesforce)[ RSS](/packages/doitcloudconsulting-salesforce/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependencies (2)Versions (4)Used By (0)

Toolkit force
=============

[](#toolkit-force)

Salesforce ToolKit for Laravel maked by DoIT Cloud Consulting

Getting Started
---------------

[](#getting-started)

Thank you so much for the interest on the package, is very interesting to us keep a community open source to Salesforce integrations. The work on the package is sponsored by **DoIT Cloud Consulting** and to company is importatn get your feedback, please contact us throught the [official page ](http://www.doitcloud.consulting/) to duds or questions.

### Prerequisites

[](#prerequisites)

In this tutorial we take for granted that you have installed PHP and composer. Create a laravel project, run the next commands:

```
$ composer create-project --prefer-dist laravel/laravel SalesforceConnectionProject

```

```
$ cd SalesforceConnectionProject

```

### Installing

[](#installing)

After you have a laravel project you will need run the command to install our package:

```
composer require doitcloudconsulting/salesforce

```

Wait a moment and you see on the composer.json a new element:

```
 "require": {
     ....
        "doitcloudconsulting/salesforce": "^0.0.0",
     ....
    }

```

Now is necessary add the service providers, go to config/app.php and add the next line in the providers array:

```
 DoITCloudConsulting\Salesforce\SalesforceServiceProvider::class,

```

To init session is neccesary add some parameters and a file wsdl, set the credentials on the config file app/SalesforceConfig.php . You will must run the next command to see the file on the config folder.

```
$ php artisan vendor:publish --tag=config

####### Result #######

Copied File [/myProject/DoITCloudConsulting/Salesforce/src/config/SalesforceConfig.php] To [/config/SalesforceConfig.php]

```

Set the credentials

```
return [

	/*
    |--------------------------------------------------------------------------
    | Data Access
    |--------------------------------------------------------------------------
    |
    | Set credenctials to login on salesforce platform.
    |
    */

	'Username' => '********@doitcloud.consulting',
	'Password' => '**********',
	'Token' => '******************************',

```

Now export the demo file to connect through a wsdl. It will show a file wsdl into config/partner.wsdl.xml, just you need replace it. Run the next command:

```
$ php artisan vendor:publish --tag=wsdlconfig

```

Go to Settings &gt;\[find box write\] API &gt; Download Partner / Enterprise then you will download a file xml that must be replaced inside of config/partner.wsdl.xml

Depending of connection type selected, in **config/SalesforceConfig.php** you must set what type connection you want use.

```

    /*
    |--------------------------------------------------------------------------
    | WSDL
    |--------------------------------------------------------------------------
    |
    | To connect to salesforce definition objects is necessary set a connect
    | mode, partner or enterprise is the options. Download the WSDL from
    | Salesforce > Settings > API. Click on the option that you need and
    | replace the files demo on the package.
    |
    */

    'Mode' => 'partner',

```

Running some examples:
----------------------

[](#running-some-examples)

Insert

```
$salesforce = new Salesforce();
$salesforce->insert(array('Name' => 'DoIT Acc FROM ToolKit'), 'Account');

```

Update

```
$salesforce = new Salesforce();
$salesforce->update(array('Name' => 'DoIT Acc ', 'id' => '001f400000yNY0LAAW'), 'Account');

```

Delete

```
$salesforce = new Salesforce();
$salesforce->delete(array('001f400000yNY0LAAW', '001f400130TMY0L5AW', ...));

```

Undelete

```
$salesforce = new Salesforce();
$salesforce->delete(array('001f400000yNY0LAAW', '001f400130TMY0L5AW', ...));

```

Upsert

```
$salesforce = new Salesforce();
$salesforce->upsert(array(
	array('Name' => 'Acc1'),
	array('Name' => 'Acc2'),
	array('Name' => 'Acc2', 'Phone' => 192837465, 'id' => '001f400000yNY0LAAW'),
	), 'Account');

```

Query

```
$salesforce = new Salesforce();
$salesforce->query('select Id, Name from Account limit 10');

```

Search / SOSL

```
$salesforce = new Salesforce();
$salesforce->sosl('Find {doit} Returning Account(name), lead(name, phone)');

```

Convert Lead

```
$salesforce = new Salesforce();

$lead = $salesforce->insert(
        array('lastname' => 'Homerito Hernández',
              'Email' => 'homerito@doitcloud.mx',
              'Phone' => 1234588892,
              'Company' => 'DoIT Cloud Consulting'
          ), 'Lead');

$salesforce->convertLead($lead->id, 'Closed - Converted');

```

Describe Global (sObject of objects custom and standard with properties).

```
$salesforce = new Salesforce();
$salesforce->describeGlobal();

```

Describe layout

```
$salesforce = new Salesforce();
$salesforce->describeLayout('Account');

```

Describe SObject

```
$salesforce = new Salesforce();
$salesforce->describeSObject('Account');

```

Get me all updated

```
$salesforce = new Salesforce();
$salesforce->getMeAllUpdated('Case', '08-04-2019', '30-04-2019');

```

Get me all Deleted

```
$salesforce = new Salesforce();
$salesforce->getMeAllDeleted('Case', '08-04-2019', '30-04-2019');

```

Built With
----------

[](#built-with)

- [Carbon](https://carbon.nesbot.com/docs/) - A simple PHP API extension for DateTime.
- [Sublime Text](https://www.sublimetext.com/) - A sophisticated text editor for code, markup and prose
- [PHP Toolkit Salesforce](https://developer.salesforce.com/index.php?title=Getting_Started_with_the_Force.com_Toolkit_for_PHP&oldid=51397) - The Force.com PHP Toolkit provides an easy-to-use wrapper for the Force.com
- [PHP](https://php.net/) - PHP is a popular general-purpose scripting language that is especially suited to web development.
- [SOAP Project](https://www.php.net/manual/es/book.soap.php) - Web Service

Authors
-------

[](#authors)

- **Hugo Hernández** - *Initial work* - [Linkedin](https://www.linkedin.com/in/hugo-hern%C3%A1ndez-65921080/)

See also the list of [contributors](https://github.com/your/project/contributors) who participated in this project.

License
-------

[](#license)

This project is licensed under the LGPL-2.0-only License - see the [LICENSE.md](LICENSE.md) file for details

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

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

Every ~0 days

Total

3

Last Release

2571d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1db1b61820729ad581078c3b557ca6eff5dac584be258f5cebd48939bf26c067?d=identicon)[hugohernandez](/maintainers/hugohernandez)

---

Tags

salesforceSalescloudforms salesforceDoITCloudConsultingDoIT Cloud Consulting

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/doitcloudconsulting-salesforce/health.svg)

```
[![Health](https://phpackages.com/badges/doitcloudconsulting-salesforce/health.svg)](https://phpackages.com/packages/doitcloudconsulting-salesforce)
```

###  Alternatives

[phpforce/soap-client

A PHP client for the Salesforce SOAP API

831.9M1](/packages/phpforce-soap-client)[davispeixoto/laravel5-salesforce

Laravel 5 Salesforce Force.com PHP Toolkit port

47142.8k1](/packages/davispeixoto-laravel5-salesforce)[mcorrigan/salesforce-rest-api-php-wrapper

SalesForce REST API PHP Wrapper

12235.4k](/packages/mcorrigan-salesforce-rest-api-php-wrapper)[ddeboer/salesforce-mapper-bundle

A Salesforce API mapper

2835.2k](/packages/ddeboer-salesforce-mapper-bundle)[davispeixoto/laravel-salesforce

Laravel 4 Salesforce Force.com PHP Toolkit port

1433.1k](/packages/davispeixoto-laravel-salesforce)

PHPackages © 2026

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