This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
developers:integration:wsa [2018/06/27 14:27] tjotov |
developers:integration:wsa [2019/08/01 10:07] tjotov removed |
||
---|---|---|---|
Line 4: | Line 4: | ||
* [[developers: | * [[developers: | ||
* [[integration-api: | * [[integration-api: | ||
- | * | + | |
For detailed methods / classes / types description see [[http:// | For detailed methods / classes / types description see [[http:// | ||
Line 31: | Line 31: | ||
This page starts authentication request. | This page starts authentication request. | ||
- | <code csharp> | + | <sxh csharp> |
var aducid = new AducidApiJsonServiceClient(); | var aducid = new AducidApiJsonServiceClient(); | ||
string host = " | string host = " | ||
Line 51: | Line 51: | ||
//parse and store authId | //parse and store authId | ||
dynamic responseObj = JsonConvert.DeserializeObject(response); | dynamic responseObj = JsonConvert.DeserializeObject(response); | ||
- | //store authId | + | //store authId |
context.Session[" | context.Session[" | ||
context.Response.ContentType = " | context.Response.ContentType = " | ||
//send response | //send response | ||
context.Response.Write(response); | context.Response.Write(response); | ||
- | </code> | + | </sxh> |
OperationArgument is a simple object | OperationArgument is a simple object | ||
- | <code csharp> | + | <sxh csharp> |
public class OperationArgument | public class OperationArgument | ||
{ | { | ||
Line 68: | Line 68: | ||
public Boolean generateQrCodePicture { get; set; } | public Boolean generateQrCodePicture { get; set; } | ||
} | } | ||
- | </code> | + | </sxh> |
=== Create WSA proxy === | === Create WSA proxy === | ||
Just simple " | Just simple " | ||
- | <code csharp> | + | <sxh csharp> |
var aducid = new AducidApiJsonServiceClient(); | var aducid = new AducidApiJsonServiceClient(); | ||
string host = " | string host = " | ||
Line 77: | Line 77: | ||
context.Response.ContentType = " | context.Response.ContentType = " | ||
context.Response.Write(response); | context.Response.Write(response); | ||
- | </code> | + | </sxh> |
=== Create check Url === | === Create check Url === | ||
Line 83: | Line 83: | ||
There are two basic results – authentication is OK or an error is thrown: | There are two basic results – authentication is OK or an error is thrown: | ||
- | <code csharp> | + | <sxh csharp> |
var aducid = new AducidApiJsonServiceClient(); | var aducid = new AducidApiJsonServiceClient(); | ||
//read authId from you session | //read authId from you session | ||
Line 101: | Line 101: | ||
//send response | //send response | ||
context.Response.Write(response); | context.Response.Write(response); | ||
- | </code> | + | </sxh> |
=== Prepare a web page === | === Prepare a web page === | ||
This page should contain [[integration-api: | This page should contain [[integration-api: | ||
- | Provide start, check and proxy Url. | + | Provide start, check and proxy Url. |
- | | + | <sxh> |
- | | + | aducid.setStartOperationUrl(" |
- | | + | |
+ | | ||
+ | </ | ||
+ | Override what should be done after authentication / operation: | ||
+ | <sxh> | ||
+ | | ||
+ | if (result.status == " | ||
+ | alert(" | ||
+ | // | ||
+ | } | ||
+ | else { | ||
+ | alert(" | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | And create some HTML elements: | ||
+ | |||
+ | <sxh html> | ||
+ | < | ||
+ | <div class=" | ||
+ | <div class=" | ||
+ | |||
+ | <div class=" | ||
+ | <div class=" | ||
+ | <div id=" | ||
+ | </ | ||
+ | </ | ||
+ | <div class=" | ||
+ | <img id=" | ||
+ | </ | ||
+ | |||
+ | <div class=" | ||
+ | <div id=" | ||
+ | <div id=" | ||
+ | </ | ||
+ | <div id=" | ||
+ | < | ||
+ | <a class=' | ||
+ | <br /> | ||
+ | <div class=' | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | </ |