Showing results for 
Show  only  | Search instead for 
Did you mean: 

AppD Inventory Website



I would like to create an AppD inventory Website with the following details.

EAI, Application Name, Agent Type, Agent Version, Environment (PROD,QA, INT & DEV). 


What are the best practices to create this? Do we have any scripts or plugins to do that? I'm thinking about doing it on WordPress by automating the data from CSV or excel. 






Hi. Not sure if you can post json data to WordPress? If so I can share a pythyon script I use for pushing stuff to elastic to get you started.

Yes Please Share it along with the process and any additional steps I need to do. Thanks for your help.

Replace in all places

replace uid and pwd in "usage statment"

replace prodserver and testserver with your controllers

replace (if using elastic) esuid and espwd


You need python 3


Produces output like this for each node:


{'appAgentVersion': 'Server Agent # v4.5.7 GA compatible with radaa5f09cafb67679c435337aa86ecda35877078 master', 'machineAgentVersion': '', 'agentType': 'APP_AGENT', 'type': 'Other', 'machineName': 'sso73-openshift-customiz-47-tzc9c', 'appAgentPresent': True, 'nodeUniqueLocalId': '', 'machineId': 271232, 'machineOSType': 'Linux', 'tierId': 2727, 'tierName': 'CD_DEV_sso', 'machineAgentPresent': False, 'name': 'CD_DEV_sso73-openshift-customiz-47-tzc9c', 'ipAddresses': None, 'id': 586157, 'application': 'CD_DEV_sso', 'date': '2019-10-31T13:09:33.468978', 'description': ''}





import requests
import json
from requests.utils import requote_uri
import string
import urllib.parse
from ast import literal_eval
import datetime
import urllib3
import sys

function to loop through all applications based on it's ID
def load(appl):
ID = str(appl['id'])
# use the global variable!
global app_name
global description
app_name = appl['name']
description = appl['description']
url = f"https://{controller}{ID}/nodes?output=json"
r = requests.get(url, auth=(uid, pwd), verify=False)
tiers = r.json()

for data in tiers:

loop throough json array as datatype dict
def loop_tiers(data):
global app_name
global description
#add stuff to the dictionary
data['application'] = app_name
data['date'] = datetime.datetime.utcnow().isoformat()
data['description'] = description
# Post it off to elastic
year = str(

esuid = 'elastic'
espwd = 'my_elasticpwd'
esurl = f""
headers = {'content-type': 'application/json'}, data=json.dumps(data), auth=(esuid, espwd), headers=headers, verify=False)

usage stement
#set up incoming arguments
if len(sys.argv) != 2:
print(f"\n To few or to many arguments expects either prod or test as first argumet \n Usage: python {(sys.argv[0])} prod|test")
env = str.lower(sys.argv[1])
if env == 'prod':
controller = ''
uid = 'uid@customer1'
pwd = 'mypwd'
elif env == 'test':
controller = ''
uid = 'uid@customer1'
pwd = 'mypwd'
print('\n first argument must be either prod or test \n')

Get all applications and their ID
url = f"https://{controller}"
app_name = ''
description = ''
r = requests.get(url, auth=(uid, pwd), verify=False)
applications = r.json()
# Call load function for each application's ID
for a_name in applications: