I am able to log in to Salesforce through the API in php. Brief Code:
define('USERNAME', getenv(<myuserkey>));
define('PASSWORD', getenv(<mypwkey));
define('SECURITY_TOKEN', getenv(mytokenkey));
$sfconn = new SforceEnterpriseClient();
$sfconn->createConnection('soap/sfwsdl.xml');
$sfconn->login(USERNAME,PASSWORD . SECURITY_TOKEN);
Later, I call a query like this:
$sfqry = "SELECT Id, QualifiedApiName, NamespacePrefix, DeveloperName, MasterLabel, Label, PluralLabel, DefaultCompactLayoutId, IsCustomizable, IsApexTriggerable, IsWorkflowEnabled, IsCompactLayoutable, KeyPrefix, IsQueryable from entitydefinition";
$response = $sfconn->query($sfqry);
I get data results back, the usual 'object' which has a 'records' property. But in looking at the list in records, EVERY single 'Id' value is the same - e.g. 000000000AAA (15 zeros, 3 A's). Other data looks fine (e.g. QualifiedApiName and other fields are different for each record). I have used the same query in the Salesforce SOQL page and Ids are definitely different - and the other fields match what I'm getting back through my PHP query.
I have queried other objects as well, and they too seem to be returning 00000000000AAA for the Id.
In the XML file I have set up, I see the base definition of SObject as this:
<!-- Base sObject (abstract) -->
<complexType name="sObject">
<sequence>
<element name="fieldsToNull" type="xsd:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
<element name="Id" type="tns:ID" nillable="true" />
</sequence>
</complexType>
And, of course, I see the other objects being based off that one.
I've been researching this for over 2 days. I'm afraid I may have missed something very basic since I can't find anyone else reporting this problem.