class ShardedMessageEnvelope implements Jsonifiable<JsonObject>, WithDittoHeaders<ShardedMessageEnvelope>, WithId {

    @Override
    public JsonObject toJson() {
        return JsonObject.newBuilder()
                .set(JSON_ID, String.valueOf(id))
                .set(JSON_TYPE, type)
                .set(JSON_MESSAGE, message)
                .set(JSON_DITTO_HEADERS, dittoHeaders.toJson())
                .build();
    }

    private  ShardedMessageEnvelope(final EntityId id,
            final String type,
            final JsonObject message,
            final DittoHeaders dittoHeaders);

}