Cleaned some files. Created DoorDash directory to test Braze Api calls.

This commit is contained in:
Norm Rasmussen
2024-09-18 18:48:17 -04:00
parent a9a7d0739e
commit 342557a4fe
3 changed files with 38 additions and 7 deletions

View File

@ -0,0 +1,19 @@
import requests
BRAPI = "da467de9-162a-47eb-9556-4609b543f005"
HEADERS = {"Content-Type": "application/json", "Authorization": f"Bearer {BRAPI}"}
URL = "https://rest.iad-06.braze.com"
PAYLOAD = {
"attributes": [
{
"email": "chris.wise@doordash.com",
"gainsightce_attempt_number": 1,
"gainsightce_course_progress": 75,
"gainsightce_course_name": "Fake Test Course",
"gainsightce_last_activity_completed": "DoorDash Is the Best!",
}
]
}
response = requests.post(f"{URL}/users/track", headers=HEADERS, json=PAYLOAD)
print(response.text)
print(response.status_code)