Add linked resources to all api resources

More general implementation of #29, will close both when merged.