SALT messages are encoded with a library called msgpack, the Python implementation of MessagePack. How can we read them?

Here’s an example message I want to decode:

†£jid´20250602114126621578¦return£tcp§retcode¢idABC-LAPTOP-02£funªconfig.get¨fun_args‘©transport

We can do that with the same library:

import msgpack

with open('return.p', 'rb') as f:
  unp = msgpack.unpackb(f.read())
  print(unp)

Make sure you install msgpack:

pip install msgpack

This will print something we can read (newlines added by me):

{
  'jid': '20250602114126621578', 
  'return': 'tcp', 
  'retcode': 0, 
  'id': 'ABC-LAPTOP-02', 
  'fun': 'config.get', 
  'fun_args': ['transport']
}