Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagec#
titleSample WCF C# Method


AuthServerResponseEnrollUser resp = EnrollUser("accountLogin", 
                              "accountKey",
                               "Mandy",
                               "Last",
                               "Mandy",
                               "M@5ndy58!",
                               Mandy5@myco.com,
                               "+1(407)555-1212,
                               02,         // desktop token
                               1,         // time based otp 
                               6,         // otp digits
                               30,        // timewindow
                               false,     // add user and this device 
                               0);
Code Block
languagec#
titleSample WCF C# Repsonse
 if (resp.ErrorCode != 0)  {      
       message.Text = resp.ErrorMsg;
       return false;
 }

...

REST parameterdata typedescription
spAccountLoginNamestringSurePassId account login name
spAccountLoginKeystringSurePassId account login key
usernamestringUser account login name
typestringadd_oath_user
firstNamestringFirst name
lastNamestringLast name
emailstringUser email. Used for sending email notifications nd temporary pass codes.
pwstringUsers password. If omitted one will be generated. If using Active Directory on the server this parameter is ignored.
mobilestringUsers mobile phone Used for sending voice or sms messages
notificationMethodshort

send welcome message to user.  0 = none, 1=email, 2=sms

Code Block
languagejs
titleSample REST/Json Method
 {
  "username": "Mandy",
  "spAccountLoginName": "accountLogin",
  "spAccountLoginKey": "accountKey",
  "type": "add_oath_user",
  "firstName": "Mandy5",
  "lastName": "Mandy5",
  "email": "Mandy5",
  "pw": "Mandy5",
  "mobile": "407-555-1212",
  "notificationMethod": 0 
}

Code Block
languagejs
titleSample REST/Json Response
 {  
  "errorCode": 0,
  "errorMessage": "OK",
  "type": "add_oath_user"
}

...