strongloop/loopback — pull request #427 by fabien (2014-08-01 09:34:22+00:00)
Title: Allow custom relation path (http) - enable hasOne remoting access

Specify `options: { path: 'plural-name' }` to set custom relation paths, regardless of `as`:

// Relation path setting - final api: /users/1/public-photos
User.hasMany('Photo', {
as: 'publicPhotos',
scope: { where: { public: true } },
options: { path: 'public-photos' }
});

See also: https://github.com/strongloop/loopback-datasource-juggler/pull/199