Skip to Content
Author's profile photo Tom Flanagan

SAP River: Accessing with Python – Data and Actions

Philip Mugglestone from the SAP HANA Academy examines how to do post and pull requests for SAP River applications in Python.

Philip stresses the importance of using a CSRFtoken when making any sort of a request in Python besides a get. Using the CSRFtoken in the header ensures that a unique id is generated and used in subsequent requests. This way the sever recognizes the id and prevents impersonations. 

Philip details the aspects of his python query. Philip’s explains how adding the CSRFtoken value into the first header variable enables the identification token to be passed in for all future subsequent requests.

Philip shows how to add a new user with a post.  After entering the CSRFtoken in the header and the proper URL, Philip uses a JSON payload to insert the new data for the user.

Next, Philip shows how to use a put to update the data for an entity. Philip details the code needed to run an action in the application and shows how to call a delete.

Philip then examines what is returned after running the action in Python including the different HTTP return codes.

Philip’s tutorial video explains how to enter and change data and run actions for SAP River applications in Python.

Screen Shot 2014-02-22 at 1.09.26 PM.png

View other tutorials on SAP River at the SAP HANA Academy.

SAP HANA Academy – over 500 free tutorial technical videos on using SAP HANA.

-Tom Flanagan

SAP HANA Academy

Follow @saphanaacademy

Assigned Tags

      Be the first to leave a comment
      You must be Logged on to comment or reply to a post.