public async Task <string> GetByTransactionId(string id)
        {
            var httpClient = _httpClientFactory.CreateClient();

            httpClient.DefaultRequestHeaders.Authorization = _authBuilder.Build();

            var requestUri = _uriComposer.Build(ResourceTemplates.TEMPLATE_TRANSACTION_BY_ID, (ResourceTemplates.PARAM_NAME_TRANSACTION_ID, id));
            var response   = await httpClient.GetAsync(requestUri);

            response.EnsureSuccessStatusCode();
            return(await response.Content.ReadAsStringAsync());
        }
        public async Task <PaymentResponse> PurchaseAsync(PaymentRequest request)
        {
            var httpClient = _httpClientFactory.CreateClient();

            httpClient.DefaultRequestHeaders.Authorization = _authBuilder.Build();
            var jsonBody      = JsonSerializer.Serialize(request, _serializerOptions);
            var stringContent = new StringContent(jsonBody, Encoding.UTF8, MediaTypeNames.Application.Json);

            var requestUri = _uriComposer.Build(ResourceTemplates.TEMPLATE_TRANSACTION_V5);

            var response = await httpClient.PostAsync(requestUri, stringContent);

            response.EnsureSuccessStatusCode();
            var json = await response.Content.ReadAsStringAsync();

            return(JsonSerializer.Deserialize <PaymentResponse>(json));
        }