Track has the same behavior on the server as it has from the client. The only difference is that you must specify the "user_id" when track is called from the server. Use the ID field from your database, the same you would in an identify call.


JSON expected

All Attribution server-side endpoints expect JSON

If you don't have user_id but still want to track event for anonymous user from server-side you need to pass cookie_id property which will contain anonymous user id. You can get from JavaScript by calling:


A note on Auth headers

Attribution app uses a HTTP Auth for all server-side functions.

Your HTTPS request header should have a blank password and the username must be your "Project ID" from Attribution app settings

Click Try It! to start a request and see the response here!