Add header for API calls
Remove duplicate code and put the header in one single place
Merge pull request #11 from owncloud/OC-3152_library_SAML_Shared

Add header for API calls