Home > DeveloperSection > Forums > Can Autobahn use a custom json encoder?
Madam Walker
Madam Walker

Total Post:22

Posted on    June-20-2013 3:50 AM


 1 Reply(s)
 1859  View(s)
Rate this:
Hi Developers,

When doing RPC with autobahn, autobahn supports procedures returning python objects as long as they are json serializable. Some objects I'd like to return are not by default json serializable. I can easily write a custom encoder, but how would autobahn know it needs to use it?

Thanks in advance for any recommendations or solutions.


Total Post:604

Posted on    June-20-2013 7:55 AM

You can override _serialize and _unserialize on your factories. See here. Please note that this API is (currently) not promised to be stable.

Don't want to miss updates? Please click the below button!

Follow MindStick