public function ALProfilesAPI::getAuthHeader in Acquia Lift Connector 7
Same name and namespace in other branches
- 7.2 acquia_lift_profiles/includes/acquia_lift_profiles.classes.inc \ALProfilesAPI::getAuthHeader()
Returns a string to use for the 'Authorization' header.
Return value
string
3 calls to ALProfilesAPI::getAuthHeader()
- ALProfilesAPI::deleteEvent in acquia_lift_profiles/
includes/ acquia_lift_profiles.classes.inc - Deletes an event from Acquia Lift Profiles
- ALProfilesAPI::getSegments in acquia_lift_profiles/
includes/ acquia_lift_profiles.classes.inc - Fetches the available Segment IDs from Acquia Lift Profiles
- ALProfilesAPI::saveEvent in acquia_lift_profiles/
includes/ acquia_lift_profiles.classes.inc - Saves an event to Acquia Lift Profiles
File
- acquia_lift_profiles/
includes/ acquia_lift_profiles.classes.inc, line 290 - Provides an agent type for Acquia Lift Profiles
Class
- ALProfilesAPI
- @file Provides an agent type for Acquia Lift Profiles
Code
public function getAuthHeader($method, $path, $parameters = array(), $headers = array()) {
$canonical = $this
->canonicalizeRequest($method, $path, $parameters, $headers, is_a($this
->httpClient(), 'AcquiaLiftDrupalHttpClient'));
$hmac = base64_encode(hash_hmac('sha1', (string) $canonical, $this->secretKey, TRUE));
return 'HMAC ' . $this->accessKey . ':' . $hmac;
}