Json: cannot unmarshal string into Go value of type map[string]json.RawMessage

#1

POST /txs

Request:

{
  "tx": {
    "msg": [
      {
        "type": "cosmos-sdk/Send",
        "value": {
          "inputs": [
            {
              "address": "cosmos1j0mtcj3g56hvlz66k3eatdvqffrwyl5rche78q",
              "coins": [
                {
                  "denom": "muon",
                  "amount": "1000000.0000000000000000"
                }
              ]
            }
          ],
          "outputs": [
            {
              "address": "cosmos1c83r235lg8g9l4zd6lec3cut8zk2dlejc6rpc5",
              "coins": [
                {
                  "denom": "muon",
                  "amount": "1000000.0000000000000000"
                }
              ]
            }
          ]
        }
      }
    ],
    "fee": {
      "gas": "200000",
      "amount": [
        {
          "denom": "muon",
          "amount": "5000"
        }
      ]
    },
    "memo": "",
    "signatures": [
      {
        "signature": "iZwioRobBkfsJ+fy3kOyix7EF8XTRn08qwNOzE6ozXd7JYu83rqNJOtshH8BLV2jxrtlFlTkNr6GLOwh8Bip4Q==",
        "account_number": "992",
        "sequence": "0",
        "pub_key": {
          "type": "tendermint/PubKeySecp256k1",
          "value": "Axu138C4cdUhsKuOXLLmowRnIv3yAzn0eAn+4X69OzBt"
        }
      }
    ]
  },
  "return": "block"
}

Response:

{"error":"json: cannot unmarshal string into Go value of type map[string]json.RawMessage"}

What’s wrong?

0 Likes