Skip to content

Commit faf21a0

Browse files
committed
SDK-1129: Add clientSdkId to index.html for example projects
1 parent 8e5a698 commit faf21a0

File tree

4 files changed

+8
-2
lines changed

4 files changed

+8
-2
lines changed

examples/yoti_example_django/yoti_example/templates/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ <h3 class="yoti-sponsor-app-header">The Yoti app is free to download and use:</h
7070
window.Yoti.Share.init({
7171
"elements": [{
7272
"domId": "yoti-share-button",
73+
"clientSdkId": "{{client_sdk_id}}",
7374
"scenarioId": "{{scenario_id}}",
7475
"button": {
7576
"label": "Use Yoti"

examples/yoti_example_django/yoti_example/views.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ class IndexView(TemplateView):
2222
template_name = "index.html"
2323

2424
def get(self, request, *args, **kwargs):
25-
return self.render_to_response({"scenario_id": YOTI_SCENARIO_ID})
25+
return self.render_to_response(
26+
{"scenario_id": YOTI_SCENARIO_ID, "client_sdk_id": YOTI_CLIENT_SDK_ID}
27+
)
2628

2729

2830
class DynamicShareView(TemplateView):

examples/yoti_example_flask/app.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ def save_image(selfie_data):
2727

2828
@app.route("/")
2929
def index():
30-
return render_template("index.html", scenario_id=YOTI_SCENARIO_ID)
30+
return render_template(
31+
"index.html", scenario_id=YOTI_SCENARIO_ID, client_sdk_id=YOTI_CLIENT_SDK_ID
32+
)
3133

3234

3335
@app.route("/dynamic-share")

examples/yoti_example_flask/templates/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ <h3 class="yoti-sponsor-app-header">The Yoti app is free to download and use:</h
7070
window.Yoti.Share.init({
7171
"elements": [{
7272
"domId": "yoti-share-button",
73+
"clientSdkId": "{{client_sdk_id}}",
7374
"scenarioId": "{{scenario_id}}",
7475
"button": {
7576
"label": "Use Yoti"

0 commit comments

Comments
 (0)