I disagree on the method prototype. IMO, we should really make a `serialize` method, which takes the data as parameter, and then a type as second.

For instance, `serialize(data, 'json')`. This can be done in another PR as it reduces a lot code redundancies and adds a `serializer` component, thing than can be useful in our case ^^