Updated a few scripts, mostly of Talkspace. Added some notes for big ideas. Began on Blacklane's signup page.
This commit is contained in:
@ -0,0 +1,99 @@
|
||||
<main class="np-box-container np-open-access">
|
||||
<div class="np-box">
|
||||
{% include "header_minimal" %}
|
||||
<div class="np-box-content-container">
|
||||
<form class="np-form np-box-content" action="{{ form.url }}" method="get" novalidate>
|
||||
{% form_authenticity_token %}
|
||||
<div class="np-form-headline">
|
||||
{% t shared.welcome_to_school, school_name: current_school.name %}
|
||||
</div>
|
||||
<div class="np-form-subheadline">
|
||||
{% t .headline, key: current_school.course_vocabulary %}
|
||||
</div>
|
||||
<div class="np-form-field">
|
||||
<label class="np-input-label" for="learner_first_name">
|
||||
{% t shared.first_name %}
|
||||
</label>
|
||||
<input
|
||||
class="np-input"
|
||||
autofocus="autofocus"
|
||||
type="text"
|
||||
name="first_name"
|
||||
id="learner_first_name"
|
||||
value="{{ form.first_name | escape }}"
|
||||
/>
|
||||
</div>
|
||||
<div class="np-form-field">
|
||||
<label class="np-input-label" for="learner_last_name">
|
||||
{% t shared.last_name %}
|
||||
</label>
|
||||
<input
|
||||
class="np-input"
|
||||
type="text"
|
||||
name="last_name"
|
||||
id="learner_last_name"
|
||||
value="{{ form.last_name | escape }}"
|
||||
/>
|
||||
</div>
|
||||
<div class="np-form-field">
|
||||
<label class="np-input-label" for="learner_email">
|
||||
{% t shared.email_address %}
|
||||
</label>
|
||||
<input
|
||||
class="np-input"
|
||||
type="text"
|
||||
name="email"
|
||||
id="learner_email"
|
||||
value="{{ form.email | escape }}"
|
||||
/>
|
||||
</div>
|
||||
<input
|
||||
type="submit"
|
||||
name="commit"
|
||||
value="{% t shared.enter %}"
|
||||
class="np-button np-button-big np-form-action"
|
||||
/>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
<script>
|
||||
|
||||
let submitData = async () => {
|
||||
if(
|
||||
($(".sign-up-follow-up-store-name")[0].value.length > 0) && $(".sign-up-follow-up-city")[0].value.length > 0 && $("#sign-up-state-dropdown")[0].value.length != 0
|
||||
){
|
||||
|
||||
function webhookCaller(){
|
||||
return new Promise(function(res, rej) {
|
||||
let xhr = new XMLHttpRequest();
|
||||
url = "https://webhooks.workato.com/webhooks/rest/4c162498-2fc6-4d3f-b5ea-6b98218b2c39/sign-up-follow-up";
|
||||
|
||||
xhr.addEventListener("load", e => {
|
||||
window.location.replace('/app/waiting-room');
|
||||
//window.location.replace('/app');
|
||||
});
|
||||
xhr.open("POST", url, true);
|
||||
xhr.send(JSON.stringify({
|
||||
email: '{{ current_person.email }}',
|
||||
name: "{{ current_person.first_name }} {{ current_person.last_name }}",
|
||||
user_id: '{{ current_person.id }}',
|
||||
user_city: $(".sign-up-follow-up-city")[0].value,
|
||||
user_state: $("#sign-up-state-dropdown")[0].value,
|
||||
user_store_name: $(".sign-up-follow-up-store-name")[0].value
|
||||
}))
|
||||
})
|
||||
}
|
||||
|
||||
try {
|
||||
await webhookCaller()
|
||||
.then((res) => {
|
||||
window.location.replace('/app/dashboard')
|
||||
})
|
||||
} catch(err) {
|
||||
console.log(err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
@ -392,3 +392,20 @@ DONE: Get Sophia a marketing number on usage increase between embedded and non-e
|
||||
* In the past they took way too long
|
||||
* Numbers need to be in by December
|
||||
|
||||
|
||||
## 11/16/2023
|
||||
|
||||
### Understanding Communities/Education
|
||||
|
||||
What is the most segmented vs integrated experience?
|
||||
|
||||
Big Ideas App > Click Northpass > How do they then navigate to community from there?
|
||||
|
||||
**They want to embed a single community/post/section into a single Activity!**
|
||||
|
||||
Chris and Courtney are at the "prove it" phase. They are interested but unsure how it will work. We need a prototype.
|
||||
|
||||
Other question from Sophia:
|
||||
|
||||
* Can we print from the quiz as both instructor and student.
|
||||
* If Learners put things in a course - like quiz submissions.
|
||||
|
||||
@ -18,3 +18,4 @@ ZENJOB = "LIXqtHXEqcXHyN0EtezngnpzA"
|
||||
DATASNIPPER = "098Odf9CIkk4aQA1lW7tsa9k8"
|
||||
CHUBB = "m6ZEBesXzpWx2vmp11rEHxrMY"
|
||||
BIRCHSTREET = "WpMV3jF4q9Om5FjUsrzZifduE"
|
||||
G2 = "JRDpCGQ7vSRiva6t5OkWDr5eJ"
|
||||
|
||||
Binary file not shown.
@ -4,8 +4,8 @@ from pathlib import Path
|
||||
import Apikeys
|
||||
import os
|
||||
|
||||
basefile = "/Users/normrasmussen/Downloads/Mizuno_Completions.csv"
|
||||
api_key = Apikeys.mizuno
|
||||
basefile = "/Users/normrasmussen/Downloads/TS1099-coursecompletions.csv"
|
||||
api_key = Apikeys.TALKSPACE_1099
|
||||
uuid_url = "https://api.northpass.com/v2/people?filter[email][eq]="
|
||||
prop_url = "https://api.northpass.com/v2/properties/people/"
|
||||
headers = {
|
||||
@ -24,9 +24,9 @@ def load_file(basefile):
|
||||
if os.path.isfile(basefile):
|
||||
print(f"File found! Importing {basefile}")
|
||||
for email in completions.itertuples():
|
||||
row_num = email[0]
|
||||
row_num = email[1]
|
||||
row_dict = {"row_num": row_num}
|
||||
email = email[3]
|
||||
email = email[4]
|
||||
url = uuid_url + f"{email}"
|
||||
response = requests.get(url, headers=headers)
|
||||
if response.status_code == 200:
|
||||
@ -35,23 +35,22 @@ def load_file(basefile):
|
||||
url2 = prop_url + f"{uuid}"
|
||||
response = requests.get(url2, headers=headers)
|
||||
data = response.json()
|
||||
pgaid = (data["data"]
|
||||
["attributes"]["properties"]["account_number"])
|
||||
row_dict["pgaid"] = pgaid
|
||||
userid = data["data"]["attributes"]["properties"]["user_id"]
|
||||
row_dict["userid"] = userid
|
||||
dict_list.append(row_dict)
|
||||
print("No errors! Passing along the dictionary!")
|
||||
except KeyError as e:
|
||||
print(e)
|
||||
print(f"{e} and the rest")
|
||||
finally:
|
||||
for info in dict_list:
|
||||
row = info["row_num"]
|
||||
pid = info["pgaid"]
|
||||
completions.loc[completions.index[row], "PGA ID"] = pid
|
||||
completions = completions[completions["PGA ID"] != "0"]
|
||||
pid = info["userid"]
|
||||
completions.loc[completions.index[row], "userid"] = pid
|
||||
completions = completions[completions["userid"] != "0"]
|
||||
# completions = completions.iloc[:, 0:]
|
||||
print(completions)
|
||||
completions.to_csv(
|
||||
"/Users/normrasmussen/Downloads/Mizuno-10.23-Completions_with_PGAIDs.csv",
|
||||
"/Users/normrasmussen/Downloads/Talkspace1099-Completions-All-IDS.csv",
|
||||
index=False,
|
||||
)
|
||||
|
||||
|
||||
15
Scripts/send-grid-request.py
Normal file
15
Scripts/send-grid-request.py
Normal file
@ -0,0 +1,15 @@
|
||||
import sys
|
||||
sys.path.insert(0, "./API_Tests/")
|
||||
import requests
|
||||
import Apikeys
|
||||
apikey = Apikeys.G2
|
||||
|
||||
url = "https://api.northpass.com/v2/email_domains"
|
||||
header = { "x-api-key": apikey, "Content-Type": "application/json" }
|
||||
payload = {"domain": "g2.com", "custom_dkim_selector": "n"}
|
||||
|
||||
response = requests.post(url, headers=header, json=payload)
|
||||
|
||||
print(response.json())
|
||||
print(response.text)
|
||||
print(response.status_code)
|
||||
Reference in New Issue
Block a user