Current Functionality

Allow adding custom events through REST API

  • 11 May 2021
  • 6 replies
  • 81 views

Currently, the only way to add actual custom event data is through the Web SDK, and even that requires a window object. It would be good if we could actually add rows through other means, primarily the REST API. If it were added there, it would be possible to do in any language.

 

I discovered this through a lot of trial and error, as it looks easy to do already. There is a “Custom Event API”, there is a Java SDK, there is a python script called a data loader. Customer support took me through these options and more, and I left no stone unturned, implemented each one--but it turns out, none of them can actually add data, despite good auth credentials. All these can do is either update existing data, add new definitions for custom events, or most commonly just read existing data. Adding this feature seems to be a no-brainer.

 

Adding data for all events should be possible too, not just custom ones. As far as I know, it’s not possible to add data for these either, but I didn’t look deeply into those.


6 replies

Userlevel 5

Custom Event creation is currently supported using the PX REST API, details here.

NOTE: The python script, data loader tool you mentioned, does use the REST API to perform its functionality (which includes creating Custom Events).

Userlevel 7
Badge

Thanks for posting to PX Community @buhlerm !

 

Our PX REST API and PX Data Loader, plus our Web, Mobile, .Net. and Java SDKs, can all be used to create new PX Custom Events for PX Users.  It seems like it would be best  to continue this conversation with our PX Support team.

 

Below are some example links that could be useful:

 

https://support.gainsight.com/PX/API_for_Developers/01About/Gainsight_PX_Data_Loader#Use_Cases_for_Using_PX_Data_Loader

https://aptrinsic.docs.apiary.io/#reference/custom-events/v1eventscustom/create-custom-event

https://support.gainsight.com/PX/API_for_Developers/SDKs/Gainsight_PX_C%23_SDK#Event_Tracking

 

Nope--here is a direct quote from the support team:

 

“Yes, currently it is not possible to upload new custom events outside of the Web SDK. But, that is a great Idea and I would suggest you to raise a community request, our Product managers are very active on our community and they review the ideas that come up on community.”

 

@angelo: if you are referring to the endpoint “POST https://api.aptrinsic.com/v1/events/custom”, I can assure you this doesn’t work. All this does is define a new Custom Event--you can’t actually load data with it. I’ve researched all these links already and none of them work, I assure you.

Userlevel 3
Badge

Hi @buhlerm,

 We are able to create new Custom Events through API.

 

Please refer to the video link explaining about how we can create a new custom event through API.
https://share.getcloudapp.com/wbuw4JDY

Regards,

R Satheesh
 

No--all you can do is define or update a custom event. Actual rows can only get sent through the Web SDK. Another quote from customer support: “there is no concept like updating the custom event data. The custom event will be triggered with given attributes everytime a custom event is triggered via API or in real time app.”

Userlevel 3
Badge

Hi @buhlerm ,

I hope a call will clear all the queries regarding custom events. I have followed up on the ticket which you created for your available timings. Please provide your available timings on the ticket so I will schedule a call and send out an invite.

Regards,
R Satheesh

Reply