File tree Expand file tree Collapse file tree
eSignature/examples/eg020_phone_authentication Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -120,16 +120,17 @@ def get_workflow(args):
120120 workflow_response = workflow_details .get_account_identity_verification (account_id = args ["account_id" ])
121121
122122 # Check that idv authentication is enabled
123- # The workflow ID is a hard-coded value which is unique to this phone authentication workflow
123+ # Find the workflow ID corresponding to the name "Phone Authentication"
124124 if workflow_response .identity_verification :
125- session ['workflow_id' ] = "c368e411-1592-4001-a3df-dca94ac539ae"
125+ for workflow in workflow_response .identity_verification :
126+ if workflow .default_name == "Phone Authentication" :
127+ session ['workflow_id' ] = workflow .workflow_id
128+
126129 return session ['workflow_id' ]
127130
128131 else :
129132 return None
130133
131134 except ApiException as err :
132135 return process_error (err )
133-
134-
135-
136+
Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ <h4>20. Require Phone Authentication for a Recipient</h4>
2424 View source file < a target ="_blank " href ="{{ source_url | safe }} "> {{ source_file }}</ a > on GitHub.
2525</ p >
2626
27+ {% if workflow_id %}
2728 < form class ="eg " action ="" method ="post " data-busy ="form ">
2829 < div class ="form-group ">
2930 < label for ="country_code "> Signer Country Code</ label >
@@ -52,5 +53,10 @@ <h4>20. Require Phone Authentication for a Recipient</h4>
5253 < input type ="hidden " name ="csrf_token " value ="{{ csrf_token() }} "/>
5354 < button type ="submit " class ="btn btn-docu "> Submit</ button >
5455 </ form >
56+ {% else %}
57+ < b > Phone Authentication is available to develop API integrations in the DocuSign Developer account,
58+ but is not enabled by default. To enable Phone Authentication in your Developer account and/or production account,
59+ contact < a target ='_blank ' href ='https://support.docusign.com '> Support</ a > .</ b >
60+ {% endif %}
5561
56- {% endblock %}
62+ {% endblock %}
Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ <h2>Problem: an error occurred</h2>
1212 < p > < pre > {{ err }}</ pre > </ p>
1313{% endif %}
1414
15-
1615< p > < a href ="/ "> Continue</ a > </ p >
1716
1817{% endblock %}
You can’t perform that action at this time.
0 commit comments