Adding mapping to endpoint