Modified myt.generateLink to support passing additional data using JSON.