ResetUniversalIdPasswordAdvanced
Advanced universalId password reset using templates.
Service | Operation |
---|---|
authenticationV2 | RESET_UNIVERSAL_ID_PASSWORD_ADVANCED |
Method Parameters
Parameter | Description |
---|---|
universalId | The universalId to send the reset email to. |
serviceParams | Set of parameters dependant on the mail service configured. |
Usage
http://localhost:3000
- C#
- C++
- Objective-C
- Java
- JavaScript
- Dart
- Cloud Code
- Raw
string universalId = "universalId";
string serviceParams = "{\"templateId\": \"d-template-id-guid\", \"dynamicData\": {\"aKey\": \"aValue\"}, \"categories\": [\"category1\", \"category2\"]}";
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};
_bc.AuthenticationService.ResetUniversalIdPasswordAdvanced (dynamic template)(universalId, serviceParams, successCallback, failureCallback);
const char *universalId = "universalId";
const char *serviceParams = "{\"templateId\": \"d-template-id-guid\", \"dynamicData\": {\"aKey\": \"aValue\"}, \"categories\": [\"category1\", \"category2\"]}";
_bc.getAuthenticationService().resetUniversalIdPasswordAdvanced (dynamic template)(universalId, serviceParams, this);
NSString *universalId = @"universalId";
NSString *serviceParams = @"{\"templateId\": \"d-template-id-guid\", \"dynamicData\": {\"aKey\": \"aValue\"}, \"categories\": [\"category1\", \"category2\"]}";
BCCompletionBlock successBlock; // define callback
BCErrorCompletionBlock failureBlock; // define callback
[[_bc authenticationService] resetUniversalIdPasswordAdvanced (dynamic template):
universalId:universalId
serviceParams:serviceParams
completionBlock:successBlock
errorCompletionBlock:failureBlock
cbObject:nil]
String universalId = "universalId";
String serviceParams = "{\"templateId\": \"d-template-id-guid\", \"dynamicData\": {\"aKey\": \"aValue\"}, \"categories\": [\"category1\", \"category2\"]}";
this; // implements IServerCallback
_bc.getAuthenticationService.resetUniversalIdPasswordAdvanced (dynamic template)(universalId, serviceParams, this);
public void serverCallback(ServiceName serviceName, ServiceOperation serviceOperation, JSONObject jsonData)
{
System.out.print(String.format("Success | %s", jsonData.toString()));
}
public void serverError(ServiceName serviceName, ServiceOperation serviceOperation, int statusCode, int reasonCode, String jsonError)
{
System.out.print(String.format("Failed | %d %d %s", statusCode, reasonCode, jsonError.toString()));
}
var universalId = "universalId";
var serviceParams = {
"templateId": "d-template-id-guid",
"dynamicData": {
"aKey": "aValue"
},
"categories": [
"category1",
"category2"
]
};
_bc.authentication.resetUniversalIdPasswordAdvanced (universalId, serviceParams, result =>
{
var status = result.status;
console.log(status + " : " + JSON.stringify(result, null, 2));
});
var universalId = "universalId";
var serviceParams = {
"templateId": "d-template-id-guid",
"dynamicData": {
"aKey": "aValue"
},
"categories": [
"category1",
"category2"
]
};
ServerResponse result = await _bc.authenticationService.resetUniversalIdPasswordAdvanced(universalId:universalId, serviceParams:serviceParams);
if (result.statusCode == 200) {
print("Success");
} else {
print("Failed ${result.error['status_message'] ?? result.error}");
}
var universalId = "universalId";
var serviceParams = {
"templateId": "d-template-id-guid",
"dynamicData": {
"aKey": "aValue"
},
"categories": [
"category1",
"category2"
]
};
var authenticationProxy = bridge.getAuthenticationServiceProxy();
var postResult = authenticationProxy.resetUniversalIdPasswordAdvanced(universalId, serviceParams);
if (postResult.status == 200) {
// Success!
}
{
"service":"authenticationV2",
"operation":"RESET_UNIVERSAL_ID_PASSWORD_ADVANCED",
"data":{
"universalId":"universalId",
"serviceParams":{
"templateId":"d-template-id-guid",
"dynamicData":{
"aKey":"aValue"
},
"categories":[
"category1",
"category2"
]
}
}
}
JSON Response
{
"status": 200,
"data": null
}