This program facilitates the automation of various tasks, undertaken by the Service Analysts team, that pertain to interactions with Sitebuilder.
The following is a list of tasks that can be completed with use of the terminal program: -
- ACL creation
- Impact factors updates
- Rankings updates
- PPV updates
- TrendMD widget creation
All but ACL Creations require a supplementary data csv to be provided to inform what values need to be changed for which site. The file data structures are as follows.
if.csv
url_shortcode | One year | Five year |
---|---|---|
brain | 11.1 | 12.592 |
sleep | 123 | 4.56 |
etc | etc | etc |
ranking.csv
url_shortcode | Ranking Category | Ranking |
---|---|---|
brain | Ranking 1 | 0 out of 0 |
sleep | Ranking 1 | 0 out of 0 |
sleep | Ranking 2 | 0 out of 0 |
etc | etc | etc |
ppv.csv
url_shortcode | GBP | EUR | USD |
---|---|---|---|
brain | 100 | 100 | 100 |
sleep | 100 | 100 | 100 |
etc | etc | etc | etc |
trendmd.csv
url_shortcode | id |
---|---|
brain | 43567 |
sleep | 12345 |
Use these steps to set up the console program for use: -
Anaconda
- Download and install Anaconda
- Open Anaconda prompt
- Change directory to the root location of the script
cd "C:\your\script\location
- Create a new virtual environment and activate it
conda create --name your-environment-name python=3.7
conda activate your-environment-name
- Add the required dependencies from the "requirements.txt" file
pip install -r requirements.txt
- Create a file called "sitebuilder_secrets.py" and edit it to contain you sitebuilder login credentials (see "secrets_template.py")
- Install the local modules
python install -e .
- Start the script with "run.py"
python run.py
All of the various interactions can only be run while off of the network. This also goes for when you are installing dependencies and creating virtual environments with Conda.
This code is meant for demonstation purposes only, as such, the code here will not run due to essential, identifiable, information being removed.