Overview
Syllabus
Welcome & introduction
Taking a quick look at the Core Service APIs on SAP API Business Hub
Focusing in on the "Regions for Global Account" API endpoint
Looking at how my btplogin script works, making use of the 'pass' command
Examining what "btp list accounts/available-region" gives us
Skimming the access token documentation URL above
Finding what our CF API endpoint is, via the btp CLI
Logging in with cf login
Creating an instance of the Cloud Management Service cis with the appropriate service plan central
Creating a service key for that instance
Storing the service key details cleaning the cruft away with sed and examining them
Looking at the OAuth 2.0 "password grant" which is used to protect the resources and how to request a token using that flow
Writing a 'gettoken' script to request an access token via the password grant flow
Calling 'gettoken' and examining the results
Writing a 'callapi' script to use the access token to call the Core Service API endpoint
Calling 'callapi' and receiving the data center data we've asked for
Comparing the JSON output from this API call with the JSON output of the btp CLI call and seeing that they are the same!
Taught by
SAP Developers