updated endpoint and url pattern