I am trying to run get_payments method of wallet rpc.

Got this error

Warning: Binary output can mess up your terminal. Use "--output -" to tell Warning: curl to output it to your terminal anyway, or consider "--output Warning: " to save to a file.

Then I tried to run it from .net like this:

var str = "{\"jsonrpc\":\"2.0\",\"id\":\"0\",\"method\":\"get_payments\",\"params\":{\"payment_id\":\"60900e5603bf96e3\"}}";

        var httpWebRequest = (HttpWebRequest) WebRequest.Create ("");
        httpWebRequest.ContentType = "application/json";
        httpWebRequest.Method = "POST";

        using (var streamWriter = new StreamWriter (httpWebRequest.GetRequestStream ())) {
            string json = str;

            streamWriter.Write (json);
        string result;
        var httpResponse = (HttpWebResponse) httpWebRequest.GetResponse ();
        using (var streamReader = new StreamReader (httpResponse.GetResponseStream ())) {
            result = streamReader.ReadToEnd ();
            System.Console.WriteLine (result);


        //string final = JsonConvert.DeserializeObject(result, new JsonSerializerSettings { Formatting = Formatting.Indented });
        var x = result.ToString ();
        string resultfinal = x.Replace ("\\n", string.Empty).Replace ("\\", "");

        string j = JsonConvert.SerializeObject (result);

        return resultfinal;

And got Internal Server Error.

WebException: The operation has timed out.

I have payment Id, how do I get payment information?

  • 18082 that port correct? Have you tried using curl?
    – jtgrassie
    Oct 24, 2019 at 4:04
  • /json also should be /json_rpc.
    – jtgrassie
    Oct 24, 2019 at 4:05
  • @jtgrassie I did try curl. The Warning message mentioned in my post is the message I got from curl message. I also tried json_rpc and the result is still the same
    – Guga Todua
    Oct 24, 2019 at 7:04
  • @jtgrassie port is also correct. At least it is same as on official website web.getmonero.org/resources/developer-guides/…
    – Guga Todua
    Oct 24, 2019 at 12:34
  • @jtgrassie found out that problem was digest authentication. I can't get wallet information when I am not authorized. So I am trying to check whether monero-wallet-rpc is running to input username and password for authentication
    – Guga Todua
    Oct 24, 2019 at 13:20


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.