Walmart Notes, offloading keys to ignore file

This commit is contained in:
Norm Rasmussen
2023-02-15 17:08:29 -05:00
parent cf3d29858c
commit 36a2f2c080
8 changed files with 34 additions and 14 deletions

View File

@ -1,22 +1,14 @@
import requests
import Apikeys
# apiKey = "SlpQlju219WnWogn94dQUT6Yt"
# apiKey = "3ia7mWFkdeALYQFYoB51yh6Ov"
# ForceManager
# apiKey = "2vfHw6ksqGfT1gUhPM8pXx2wW"
# Talkspace Core
apiKey = "HWxj6VTNPwbc3WghFTPzr7SjE"
# Wild Health
# url ="https://api.northpass.com/v2/groups/e6ef3e5f-b5a2-4b10-868b-8c165d76d263/learning_paths"
# "https://api.northpass.com/v1/media"
url = "https://api.northpass.com/v1/media"
# function = sys.argv[1]
apiKey = Apikeys.talkspace_core
# Get Group Memberships:
url = "https://api.northpass.com/v2/groups/504c4771-223a-447f-9ec6-08e51bc9ca23/memberships"
# url = "https://api.northpass.com/v2/groups/504c4771-223a-447f-9ec6-08e51bc9ca23/memberships"
def putTest(apiKey, url):
@ -37,11 +29,14 @@ def putTest(apiKey, url):
def getTest(apiKey, url):
print(url)
print(apiKey)
headers = {"accept": "application/json", "X-Api-Key": apiKey}
response = requests.get(url, headers=headers)
# print(response.text)
jsonResponse = response.json()
print(jsonResponse["included"][1]["attributes"]["email"])
print(jsonResponse)
# print(jsonResponse["included"][1]["attributes"]["email"])
# print(jsonResponse["data"][1]["attributes"])