Defining the current user

We've updated our API docs with information on how to designate a different user as the "creator" or "editor" within certain endpoints.

In order to designate a different CompanyCam User as the creator or editor, you can send that User's CompanyCam email in the request header of your API call. The request field should include X_COMPANYCAM_USER with the valid email of the User in CompanyCam.

cURL

curl --location "https://api.companycam.com/v2/projects" \
--header "X_COMPANYCAM_USER: [email protected]" \  
--header "Content-Type: application/json" \
--header "Authorization: Bearer {TOKEN}" \    
--header "Cookie: \_production_companycam_session={SESSION_TOKEN}' \
--data '{  
    "name": "Project for Roof Job 4132",  
    "address": {  
        "street_address_1": "4132 Pleasant St",  
        "city": "Lincoln",  
        "state": "NE",  
        "postal_code": "68508",  
        "country": "US"  
    }  
}'

You can find more info about that here: <https://docs.companycam.com/docs/defining-the-current-user>