You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Problem
The SDK for Web needed to be included in the mdbook documentation.
## How to Test
- Clone
- `cd docs`
- `mdbook serve`
- http://localhost:3000
Copy file name to clipboardExpand all lines: docs/src/SDK/Overview.md
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,7 @@ These guides will walk you through integrating the SIWF SDK into your **iOS** or
7
7
8
8
-[Android](Android.md)
9
9
-[iOS](iOS.md)
10
+
-[Web](Web.md)
10
11
11
12
---
12
13
@@ -26,7 +27,8 @@ You may also specify other options such as the button style (light/dark) and the
26
27
You will need to create a redirect handler to receive information from the Authorization (i.e. the redirect URL provided to the Signed Request Payload).
27
28
This redirect handler will receive information once the authorization is complete, which may then be sent and processed by your system’s backend to initiate the session.
28
29
29
-
See platform-specific details in the [Android](Android.md) or [iOS](iOS.md) sections for instructions for creating the callback handler
30
+
See platform-specific details in the [Android](Android.md) or [iOS](iOS.md) sections for instructions for creating the callback handler.
31
+
[Web](Web.md) requires your own callback processing to extract the `authorizationCode` from the URL parameters.
Simply include the SDK in your HTML from [jsDelivr](https://www.jsdelivr.com/package/npm/@projectlibertylabs/siwf-sdk-web) (update the version as needed):
`data-siwf-button` requires the [Signed Request Payload](../Actions/Start.html#step-1-generate-the-signed-request-payload) in `base64url` encoded form.
33
+
34
+
You can also use a [JavaScript render call](https://github.com/ProjectLibertyLabs/siwf/tree/main/libraries/sdk-web#option-b-javascript-implementation).
35
+
36
+
## 3. Handling Authorization Callbacks
37
+
38
+
You will need to handle the callback URL specified and extract the `authorizationCode` parameter from the callback and passing it to your backend service.
39
+
40
+
## 4. Process Authorization Code
41
+
42
+
On your backend service, process the authorization code and start your session.
43
+
44
+
Resources:
45
+
-[Documentation on Processing a Result](../Actions/Response.html)
0 commit comments