pitchmuc / aepp

Adobe Experience Platform API for humans

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support stage environment

cmenguy opened this issue · comments

Right now everything seems to be hard-coded to use the prod environment. This includes:

  • The endpoints in config.py
  • The JWT authentication with IMS in connector.py

We should support additional environments like stage or int. Ideally it's something that could be added in the config.json file or directly via the aepp.configure call.

We will need to make changes to config.py and connector.py to fetch the environment at runtime and modify the URLs accordingly to IMS and experience platform to be respectively ims-na1-stg1.adobelogin.com and experience-stage.adobe.com

commented

As discussed in another ticket, I want to provide a way to save your credential into an instance of class named ConnectObject.
We could imagine that instance having multiple purposes, such as defining the environment.
if the only thing that changes is the hostname.
it can be found in the config endpoints dictionary.
We could add the different stages and set a "switchFlag" to modify the hostname at runtime for the HTTP method in the connector class depending that switchFlag value.
Every request pass through a connector instance, so it would seem the best option to handle that there.

Nevertheless, I am not familiar (neither have I access ) with the different test environments so I will let you have the lead on that.