Expose record's url in API responses

When the API is created with a `baseUrl` and `apiBaseUrl` option
it can use that to generate links within the API output. This also
works on sub-documents, so the embedded memberships will have url
properties as well.