I am using the REST api to sync data from my wordpress site to salesforce. I am looking to see in a report from where the api calls are originating and i found that i can use the client id in the "CallOptions" header.
My reference: https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/headers_calloptions.html
from that page:
Field name
Sforce-Call-Options
Field values
client—A string that identifies a client.
defaultNamespace—A string that identifies a developer ...
My question is, how do i write the headers array (correct syntax) to contain the call options header with only "client" with a value.
i tried 'headers' => array('Sforce-Call-Options' => 'My-Client-Name')
But the client id doesn't show in the report.
Also, is there maybe something i need to do in the salesforce environment because this is REST? i managed to add this in SOAP (using "setCallOptions" method)