Ejemplo n.º 1
0
        protected string GetApiResponse(string endpoint, ApiMethod method)
        {
            var client   = new SentralRestClient(GetUri(endpoint), _header, method, null);
            var response = client.Invoke();

            return(response);
        }
Ejemplo n.º 2
0
        protected T GetApiResponse <T>(string endpoint, ApiMethod method, string payload)
        {
            var client   = new SentralRestClient(GetUri(endpoint), _header, method, payload);
            var response = client.Invoke();

            return(JsonConvert.DeserializeObject <T>(response, _settings));
        }
Ejemplo n.º 3
0
        protected BinaryFile GetBinaryFile(string endpoint)
        {
            var client = new SentralRestClient(GetUri(endpoint), _header, ApiMethod.GET, null);

            return(client.InvokeBinaryResponse());
        }
Ejemplo n.º 4
0
        protected byte[] GetBinaryData(string endpoint)
        {
            var client = new SentralRestClient(GetUri(endpoint), _header, ApiMethod.GET, null);

            return(client.InvokeBinary());
        }