Skip to Main Content

Analytics Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

ODI Restful Service - Submit data in POST Method

User_F42ZQMay 17 2019 — edited May 20 2019

Hi,

I am trying to download Google Analytics data using ODI 12c.

Using Google API Page (at developers.google.com), there is an option to try the API results using Parameters and Request Body options. See attached screenshot.

How do we use the Request Body option in ODI 'odiInvokeRestfulService' command? This is to be used to Post or Submit the data. For example: --data option in cURL command shown below.

curl --request POST \

  'https://analyticsreporting.googleapis.com/v4/reports:batchGet?key=[YOUR_API_KEY]' \

  --header 'Authorization: Bearer [YOUR_ACCESS_TOKEN]' \

  --header 'Accept: application/json' \

  --header 'Content-Type: application/json' \

  --data '{"reportRequests":[{"dateRanges":[{"endDate":"2019-05-12","startDate":"2019-05-06"}],"dimensions":[{"name":"ga:city"}],"metrics":[{"expression":"ga:newUsers"}]}],"useResourceQuotas":false}' \

  --compressed

In ODI, there is a box for 'Request Content'. Would that be the area to give the --data options? See the ODI screenshot attached.

Thanks

Sri

Comments