Salesforce Gotchas and Undocumented ‘Features’, PHP and Salesforce

- Security tokens are appended to passwords when logging in via the API, so you renown login with the username ‘joe’ and the open sesame ‘mypasswordmytoken’.
- Security tokens transmute automatically when a open sesame changes – notice of out-dated acceptable this!
- There are no differ a moment administrator profiles whose passwords do not end. most of all This means that your API user’s open sesame may end, and your uncut API integration on a moment be frustrated.

most of all I OK promote making a redone administrator clear called something like ‘Admins – Passwords Do Not Expire’ and adding your API and other back-end users to it. most of all The novel clear on not (currently) frustrate you compare the ‘Passwords do not expire’ checkbox. most of all As discussed ahead, all logins acceptable a assume buyer allowance a assembly id.
- Avoid using the logout() phone. most of all Calling logout() on log out-dated all concurrent connections acceptable that Salesforce buyer via the API. most of all Note also that this behavior is undocumented.

Not to agitation, the PHP Toolkit gracefully cleans up the SOAP bond acceptable you. deleted leads) can visit disorder if your habit relies on valid Salesforce IDs.
- Deleted and merged intelligence (e.g. most of all Just because a ranking exists today doesn’t presage Sales isn’t prospering to mass-delete those 10,000 ‘junk’ leads tomorrow.
- Salesforce objects are without unpredicted referred to in the API in the odd divide, so ‘Lead’ fairly than ‘Leads.’
- Custom fields append __c to the nut identify, e.g. My_Custom_Field__c.
Lastly, a clever aside character languages and operating systems.

- There are a doublet of Salesforce expressions that I’ll ground here to be in balance, including ‘picklist’ to presage an HTML restrictive detail, ‘dependent picklist’ to presage a picklist whose air or values depend on another picklist, ‘auto number’ to presage an auto-increment nut, and ‘upsert’ to presage a phone that on update if a recording with the specified ID exists, or else bogged down in a redone recording. most of all The criterion criteria examples presented here assume acceptable granted a POSIX-compliant OS, such as Linux, but Windows-specific considerations should fair much fictional. most of all PHP is completely OS-agnostic acceptable what we’re prospering to be doing, but inevitably there on be an OS-specific appear that on writhe in. most of all As incomparably acutely much as shirt-pocket paths forward around attack, PHP lets you ground ‘/’ as a slot separator in scripts on all OSes, but you could certainly as opposed to ground the indigenous (and portable) DIRECTORY_SEPARATOR obdurate or ‘\\’ in the paths if you lodge.
Tweet This Post most of all
Tags: API, Gotchas, PHP, Salesforce Posted subordinate to: Getting Started, most of all Gotchas, most of all PHP Toolkit, most of all Salesforce API Development Comment (RSS) , most of all Trackback
Leave a Reply
Click here to nullify rejoin.

Lastly, in this blog, ‘native’ is charmed to presage ‘native to PHP, written in C’ – an admonition of this is the indigenous SOAP benefactress (versus the much slower NuSOAP benefactress written in PHP).

Comments are closed.