Пример #1
0
        public async Task <PersonDetail> GetPersonDetail(string token, int personId)
        {
            var client = new WebApiClient(token);

            return(await client.GetAsync <PersonDetail>(_appSettings.PersonUrl, "api/person", personId.ToString()));
        }
Пример #2
0
        public async Task <PersonDetail[]> GetPersonDetails(string token)
        {
            var client = new WebApiClient(token);

            return(await client.GetAsync <PersonDetail[]>(_appSettings.PersonUrl, "api/person"));
        }
Пример #3
0
        public async Task <AuthenticateResponse> Authenticate(AuthenticateRequest authenticateRequest)
        {
            var client = new WebApiClient();

            return(await client.Post <AuthenticateRequest, AuthenticateResponse>(_appSettings.AuthenticationUrl, "api/authentication/authenticate", authenticateRequest));
        }