-ok( $data->{'user'}->{'ha1'} =~ m/[a-z0-9]{16,}/, 'user/get ha1 hash generated');
-undef $response; undef $data;
-
-$response = $g_ua->get( $api_base . "user/gen_pw");
-ok( $response->content =~ m/[a-z0-9]{24}/, 'user/gen_pw format OK');
-$temp = $response->content;
-undef $response; undef $data;
-
-$response = $g_ua->get( $api_base . "user/change_pw?user=" . $test_username . "\@" . $test_domain . "&password=" . $temp );
-$data = decode_json( $response->content);
+ok( $data->{'user'}->{'ha1'} =~ m/[a-z0-9]{16,}/, 'user/get ha1 hash generated');
+undef $data;
+
+$data = exec_apinode("user/gen_pw", undef);
+ok( $data =~ m/[a-zA-Z0-9]{24}/, 'user/gen_pw format OK');
+$temp = $data;
+undef $data;
+
+$data = exec_apinode("user/change_pw", {
+ "user" => $test_username . "\@" . $test_domain,
+ "password" => $temp,
+} );