use of org.whispersystems.signalservice.api.account.ChangePhoneNumberRequest in project Signal-Android by signalapp.
the class PushServiceSocket method changeNumber.
public VerifyAccountResponse changeNumber(String code, String e164NewNumber, String registrationLock) throws IOException {
ChangePhoneNumberRequest changePhoneNumberRequest = new ChangePhoneNumberRequest(e164NewNumber, code, registrationLock);
String requestBody = JsonUtil.toJson(changePhoneNumberRequest);
String responseBody = makeServiceRequest(CHANGE_NUMBER_PATH, "PUT", requestBody);
return JsonUtil.fromJson(responseBody, VerifyAccountResponse.class);
}
use of org.whispersystems.signalservice.api.account.ChangePhoneNumberRequest in project Signal-Android by WhisperSystems.
the class PushServiceSocket method changeNumber.
public VerifyAccountResponse changeNumber(String code, String e164NewNumber, String registrationLock) throws IOException {
ChangePhoneNumberRequest changePhoneNumberRequest = new ChangePhoneNumberRequest(e164NewNumber, code, registrationLock);
String requestBody = JsonUtil.toJson(changePhoneNumberRequest);
String responseBody = makeServiceRequest(CHANGE_NUMBER_PATH, "PUT", requestBody);
return JsonUtil.fromJson(responseBody, VerifyAccountResponse.class);
}
Aggregations