2017 © Pedro Peláez
 

library salesforce-bundle

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

image

genesis-global/salesforce-bundle

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  • Thursday, January 11, 2018
  • by SiliconMind
  • Repository
  • 5 Watchers
  • 3 Stars
  • 3,268 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 5 Forks
  • 2 Open issues
  • 42 Versions
  • 31 % Grown

The README.md

Salesforce-bundle

Symfony bundle for Salesforce REST client which is base on username,password authentication, (*1)

Package instalation with composer

$ composer require genesis-global/salesforce-bundle

Enable bundle

Then, enable the bundle by adding it to the list of registered bundles in the app/AppKernel.php file of your project:, (*2)

<?php
// app/AppKernel.php

// ...
class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            // ...

            new GenesisGlobal\Salesforce\SalesforceBundle\SalesforceBundle(),
        );

        // ...
    }

    // ...
}

Required configuration:

salesforce:
    authentication:
        endpoint: "https://login.salesforce.com/"
        client_id: "id"
        client_secret: "secret"
        username: "name"
        password: "pass",
        security_token: '22s2sd233e3'
    rest:
        version: "v35.0"
        endpoint: "https://yourinstance.salesforce.com"

Use in controller:

CREATE RECORD

// custom class which implements SobjectInterface
$case = new Sobject();
$case->setName('Case');
$case->setContent(['someField' => 'someValue']);

$result = $this->get('salesforce.service')->create($case);  

// get salesforce id
$id = $result->getId();

UPDATE RECORD


try { $this->get('salesforce.service')->update('Account', '001D000000INjVe', [ 'someField' => 'someValue' ]); } catch (UpdateSobjectException $e) { // update failed echo $e->getMessage(); }

UPSERT RECORD

// account object
$account = new \stdClass();
$account->Current_Balance__c = '21023';
$account->Current_Count_of_Deposit__c = 0;
$account->Number_of_Active_Days__c = 12;

// account sObject ready to send to salesforce
$accountSobject = new Sobject();
$accountSobject->setName('Account');
$accountSobject->setContent($account);

$result = $this->get('salesforce.service')->upsert($sObject, 'Player_Account__c', '123132');

GET METADATA

$metaData = $this->get('salesforce.service')->getMetaDataForSobject('Account');

The Versions

11/01 2018

dev-master

9999999-dev

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

The Development Requires

salesforce

29/12 2017

1.2.1

1.2.1.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

The Development Requires

salesforce

29/12 2017

1.2.0

1.2.0.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

The Development Requires

salesforce

29/11 2017

dev-old-symfony

dev-old-symfony

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

29/11 2017

0.2.5

0.2.5.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/11 2017

0.2.4

0.2.4.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/11 2017

0.2.3

0.2.3.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

05/09 2017

1.1.5

1.1.5.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

The Development Requires

salesforce

16/08 2017

1.1.4

1.1.4.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

The Development Requires

salesforce

16/08 2017

1.1.3

1.1.3.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

08/08 2017

0.2.2

0.2.2.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

28/07 2017

1.1.2

1.1.2.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

12/07 2017

dev-pre-response

dev-pre-response

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

12/07 2017

1.0.15

1.0.15.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

06/07 2017

0.2.1

0.2.1.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

06/07 2017

1.1.1

1.1.1.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

28/06 2017

1.0.14

1.0.14.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

27/06 2017

0.2.0

0.2.0.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

27/06 2017

1.1.0

1.1.0.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

27/06 2017

0.1.9

0.1.9.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

27/06 2017

1.0.13

1.0.13.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

14/06 2017

0.1.8

0.1.8.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

14/06 2017

1.0.12

1.0.12.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

14/06 2017

0.1.7

0.1.7.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

14/06 2017

1.0.11

1.0.11.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

14/06 2017

1.0.10

1.0.10.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

13/06 2017

1.0.9

1.0.9.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

13/06 2017

0.1.6

0.1.6.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

08/06 2017

0.1.5

0.1.5.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

08/06 2017

1.0.8

1.0.8.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

07/06 2017

0.1.4

0.1.4.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

07/06 2017

1.0.7

1.0.7.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

30/05 2017

0.1.3

0.1.3.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

30/05 2017

1.0.5

1.0.5.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/05 2017

1.0.4

1.0.4.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/05 2017

0.1.2

0.1.2.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/05 2017

0.1.1

0.1.1.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

23/05 2017

1.0.3

1.0.3.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

22/05 2017

0.1.0

0.1.0.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

22/05 2017

1.0.2

1.0.2.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

22/05 2017

1.0.1

1.0.1.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce

19/05 2017

1.0.0

1.0.0.0

Symfony bundle that provides OAuth2 authentication and exposes Salesforce REST API methods in OOP friendly way.

  Sources   Download

MIT

The Requires

 

salesforce