TXN Feed API

Avg Endpoints

getAvgField

This endpoint calculates the average value of a specific field (for example the amount).
/transactions/aggregate/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/avg/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgField(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgField");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgField(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgField");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (for example the amount).
[apiInstance getAvgFieldWith:field
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getAvgField(field, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getAvgFieldExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (for example the amount).
                AggregateAvgResult result = apiInstance.getAvgField(field, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getAvgField: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getAvgField($field, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getAvgField: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getAvgField(field => $field, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getAvgField: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (for example the amount).
    api_response = api_instance.get_avg_field(field, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getAvgField: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getAvgField(field, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Responses


getAvgFieldForPayouts

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture).
/transactions/aggregate/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/avg/payouts/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgFieldForPayouts(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgFieldForPayouts(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture).
[apiInstance getAvgFieldForPayoutsWith:field
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getAvgFieldForPayouts(field, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getAvgFieldForPayoutsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture).
                AggregateAvgResult result = apiInstance.getAvgFieldForPayouts(field, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getAvgFieldForPayouts: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getAvgFieldForPayouts($field, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getAvgFieldForPayouts: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getAvgFieldForPayouts(field => $field, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getAvgFieldForPayouts: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture).
    api_response = api_instance.get_avg_field_for_payouts(field, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getAvgFieldForPayouts: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getAvgFieldForPayouts(field, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Responses


getAvgFieldForRefsAndRevs

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal).
/transactions/aggregate/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/avg/refundsandreversals/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgFieldForRefsAndRevs(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getAvgFieldForRefsAndRevs(field, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal).
[apiInstance getAvgFieldForRefsAndRevsWith:field
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getAvgFieldForRefsAndRevs(field, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getAvgFieldForRefsAndRevsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal).
                AggregateAvgResult result = apiInstance.getAvgFieldForRefsAndRevs(field, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getAvgFieldForRefsAndRevs: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getAvgFieldForRefsAndRevs($field, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getAvgFieldForRefsAndRevs: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getAvgFieldForRefsAndRevs(field => $field, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getAvgFieldForRefsAndRevs: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal).
    api_response = api_instance.get_avg_field_for_refs_and_revs(field, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getAvgFieldForRefsAndRevs: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getAvgFieldForRefsAndRevs(field, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Responses


getGrAvgField

This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
/transactions/aggregate/group/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/avg/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgField(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgField");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgField(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgField");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
[apiInstance getGrAvgFieldWith:field
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getGrAvgField(field, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getGrAvgFieldExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
                AggregateGroupedAvgResult result = apiInstance.getGrAvgField(field, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getGrAvgField: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getGrAvgField($field, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getGrAvgField: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getGrAvgField(field => $field, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getGrAvgField: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
    api_response = api_instance.get_gr_avg_field(field, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getGrAvgField: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getGrAvgField(field, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getGrAvgFieldForPayouts

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC')
/transactions/aggregate/group/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/avg/payouts/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForPayouts(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForPayouts(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC')
[apiInstance getGrAvgFieldForPayoutsWith:field
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getGrAvgFieldForPayouts(field, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getGrAvgFieldForPayoutsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC')
                AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForPayouts(field, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getGrAvgFieldForPayouts: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getGrAvgFieldForPayouts($field, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getGrAvgFieldForPayouts: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getGrAvgFieldForPayouts(field => $field, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getGrAvgFieldForPayouts: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC')
    api_response = api_instance.get_gr_avg_field_for_payouts(field, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getGrAvgFieldForPayouts: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getGrAvgFieldForPayouts(field, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getGrAvgFieldForRefsAndRevs

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
/transactions/aggregate/group/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/avg/refundsandreversals/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForRefsAndRevs(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForRefsAndRevs(field, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getGrAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
[apiInstance getGrAvgFieldForRefsAndRevsWith:field
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getGrAvgFieldForRefsAndRevs(field, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getGrAvgFieldForRefsAndRevsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
                AggregateGroupedAvgResult result = apiInstance.getGrAvgFieldForRefsAndRevs(field, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getGrAvgFieldForRefsAndRevs: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getGrAvgFieldForRefsAndRevs($field, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getGrAvgFieldForRefsAndRevs: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getGrAvgFieldForRefsAndRevs(field => $field, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getGrAvgFieldForRefsAndRevs: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
    api_response = api_instance.get_gr_avg_field_for_refs_and_revs(field, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getGrAvgFieldForRefsAndRevs: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getGrAvgFieldForRefsAndRevs(field, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getMrchtAvgFieldForAdmin

This endpoint calculates the average value of a specific field (for example the amount). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (for example the amount). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtAvgFieldForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtAvgFieldForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (for example the amount). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getMrchtAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtAvgFieldForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getMrchtAvgFieldForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtAvgFieldForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getMrchtAvgFieldForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtAvgFieldForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (for example the amount). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_avg_field_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtAvgFieldForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Responses


getMrchtAvgFieldForPayoutsForAdmin

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/payouts/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForPayoutsForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForPayoutsForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtAvgFieldForPayoutsForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtAvgFieldForPayoutsForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getMrchtAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtAvgFieldForPayoutsForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getMrchtAvgFieldForPayoutsForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtAvgFieldForPayoutsForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getMrchtAvgFieldForPayoutsForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtAvgFieldForPayoutsForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_avg_field_for_payouts_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtAvgFieldForPayoutsForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Responses


getMrchtAvgFieldForRefsAndRevsForAdmin

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/avg/refundsandreversals/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForRefsAndRevsForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getMrchtAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtAvgFieldForRefsAndRevsForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtAvgFieldForRefsAndRevsForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtAvgFieldForRefsAndRevsForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getMrchtAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtAvgFieldForRefsAndRevsForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getMrchtAvgFieldForRefsAndRevsForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtAvgFieldForRefsAndRevsForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getMrchtAvgFieldForRefsAndRevsForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtAvgFieldForRefsAndRevsForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_avg_field_for_refs_and_revs_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtAvgFieldForRefsAndRevsForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Responses


getMrchtGrAvgFieldForAdmin

This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtGrAvgFieldForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtGrAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtGrAvgFieldForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtGrAvgFieldForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getMrchtGrAvgFieldForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtGrAvgFieldForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getMrchtGrAvgFieldForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtGrAvgFieldForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (for example the amount) grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_gr_avg_field_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtGrAvgFieldForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtGrAvgFieldForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getMrchtGrAvgFieldForPayoutsForAdmin

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/payouts/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForPayoutsForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForPayoutsForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtGrAvgFieldForPayoutsForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtGrAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtGrAvgFieldForPayoutsForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtGrAvgFieldForPayoutsForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getMrchtGrAvgFieldForPayoutsForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtGrAvgFieldForPayoutsForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getMrchtGrAvgFieldForPayoutsForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtGrAvgFieldForPayoutsForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_gr_avg_field_for_payouts_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtGrAvgFieldForPayoutsForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtGrAvgFieldForPayoutsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getMrchtGrAvgFieldForRefsAndRevsForAdmin

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{partner_id_alpha}/{merchant_id_alpha}/aggregate/group/avg/refundsandreversals/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForRefsAndRevsForAdmin");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
        String partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getMrchtGrAvgFieldForRefsAndRevsForAdmin");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *merchantIdAlpha = merchantIdAlpha_example; // The id of the merchant (default to null)
String *partnerIdAlpha = partnerIdAlpha_example; // The id of the partner (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getMrchtGrAvgFieldForRefsAndRevsForAdminWith:field
    merchantIdAlpha:merchantIdAlpha
    partnerIdAlpha:partnerIdAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var merchantIdAlpha = merchantIdAlpha_example; // {String} The id of the merchant
var partnerIdAlpha = partnerIdAlpha_example; // {String} The id of the partner
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getMrchtGrAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getMrchtGrAvgFieldForRefsAndRevsForAdminExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var merchantIdAlpha = merchantIdAlpha_example;  // String | The id of the merchant (default to null)
            var partnerIdAlpha = partnerIdAlpha_example;  // String | The id of the partner (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getMrchtGrAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getMrchtGrAvgFieldForRefsAndRevsForAdmin: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$merchantIdAlpha = merchantIdAlpha_example; // String | The id of the merchant
$partnerIdAlpha = partnerIdAlpha_example; // String | The id of the partner
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getMrchtGrAvgFieldForRefsAndRevsForAdmin($field, $merchantIdAlpha, $partnerIdAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getMrchtGrAvgFieldForRefsAndRevsForAdmin: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $merchantIdAlpha = merchantIdAlpha_example; # String | The id of the merchant
my $partnerIdAlpha = partnerIdAlpha_example; # String | The id of the partner
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getMrchtGrAvgFieldForRefsAndRevsForAdmin(field => $field, merchantIdAlpha => $merchantIdAlpha, partnerIdAlpha => $partnerIdAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getMrchtGrAvgFieldForRefsAndRevsForAdmin: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
merchantIdAlpha = merchantIdAlpha_example # String | The id of the merchant (default to null)
partnerIdAlpha = partnerIdAlpha_example # String | The id of the partner (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {partner_id_alpha} and {merchant_id_alpha} are unique id's assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_mrcht_gr_avg_field_for_refs_and_revs_for_admin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getMrchtGrAvgFieldForRefsAndRevsForAdmin: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let merchantIdAlpha = merchantIdAlpha_example; // String
    let partnerIdAlpha = partnerIdAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getMrchtGrAvgFieldForRefsAndRevsForAdmin(field, merchantIdAlpha, partnerIdAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

merchantIdAlpha *

The id of the merchant

partnerIdAlpha *

The id of the partner

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getPrtnOrMrchtAvgField

This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/avg/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgField(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgField");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgField(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgField");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtAvgFieldWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtAvgField(field, idAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtAvgFieldExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgField(field, idAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtAvgField: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getPrtnOrMrchtAvgField($field, $idAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtAvgField: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getPrtnOrMrchtAvgField(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtAvgField: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_avg_field(field, idAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtAvgField: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtAvgField(field, idAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Responses


getPrtnOrMrchtAvgFieldForPayouts

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/avg/payouts/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForPayouts(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForPayouts(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtAvgFieldForPayoutsWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtAvgFieldForPayouts(field, idAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtAvgFieldForPayoutsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForPayouts(field, idAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtAvgFieldForPayouts: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getPrtnOrMrchtAvgFieldForPayouts($field, $idAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForPayouts: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getPrtnOrMrchtAvgFieldForPayouts(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForPayouts: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_avg_field_for_payouts(field, idAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForPayouts: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtAvgFieldForPayouts(field, idAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Responses


getPrtnOrMrchtAvgFieldForRefsAndRevs

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/avg/refundsandreversals/{field}"
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForRefsAndRevs(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        
        try {
            AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForRefsAndRevs(field, idAlpha, requestConfig);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtAvgFieldForRefsAndRevsWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
              completionHandler: ^(AggregateAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtAvgFieldForRefsAndRevsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateAvgResult result = apiInstance.getPrtnOrMrchtAvgFieldForRefsAndRevs(field, idAlpha, requestConfig);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtAvgFieldForRefsAndRevs: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 

try {
    $result = $api_instance->getPrtnOrMrchtAvgFieldForRefsAndRevs($field, $idAlpha, $requestConfig);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForRefsAndRevs: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 

eval { 
    my $result = $api_instance->getPrtnOrMrchtAvgFieldForRefsAndRevs(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForRefsAndRevs: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant. 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_avg_field_for_refs_and_revs(field, idAlpha, requestConfig)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtAvgFieldForRefsAndRevs: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Responses


getPrtnOrMrchtGrAvgField

This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/group/avg/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/group/avg/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgField(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgField");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgField(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgField");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtGrAvgFieldWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtGrAvgField(field, idAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtGrAvgFieldExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgField(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtGrAvgField: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getPrtnOrMrchtGrAvgField($field, $idAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtGrAvgField: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getPrtnOrMrchtGrAvgField(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtGrAvgField: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a field (for example the amount) for a specific partner/merchant grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_gr_avg_field(field, idAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtGrAvgField: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtGrAvgField(field, idAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getPrtnOrMrchtGrAvgFieldForPayouts

This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/group/avg/payouts/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/group/avg/payouts/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForPayouts(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForPayouts(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgFieldForPayouts");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtGrAvgFieldForPayoutsWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtGrAvgFieldForPayouts(field, idAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtGrAvgFieldForPayoutsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForPayouts(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtGrAvgFieldForPayouts: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getPrtnOrMrchtGrAvgFieldForPayouts($field, $idAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForPayouts: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getPrtnOrMrchtGrAvgFieldForPayouts(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForPayouts: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount field) for all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_gr_avg_field_for_payouts(field, idAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForPayouts: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtGrAvgFieldForPayouts(field, idAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


getPrtnOrMrchtGrAvgFieldForRefsAndRevs

This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
/transactions/{id_alpha}/aggregate/group/avg/refundsandreversals/{field}

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/{id_alpha}/aggregate/group/avg/refundsandreversals/{field}?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.AvgApi;

import java.io.File;
import java.util.*;

public class AvgApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.AvgApi;

public class AvgApiExample {
    public static void main(String[] args) {
        AvgApi apiInstance = new AvgApi();
        String field = field_example; // String | Field to be targeted for the aggregation
        String idAlpha = idAlpha_example; // String | The id of the target partner/merchant
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg
        
        try {
            AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling AvgApi#getPrtnOrMrchtGrAvgFieldForRefsAndRevs");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
AvgApi *apiInstance = [[AvgApi alloc] init];
String *field = field_example; // Field to be targeted for the aggregation (default to null)
String *idAlpha = idAlpha_example; // The id of the target partner/merchant (default to null)
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

// This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
[apiInstance getPrtnOrMrchtGrAvgFieldForRefsAndRevsWith:field
    idAlpha:idAlpha
    requestConfig:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedAvgResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.AvgApi()
var field = field_example; // {String} Field to be targeted for the aggregation
var idAlpha = idAlpha_example; // {String} The id of the target partner/merchant
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by totalAvg
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getPrtnOrMrchtGrAvgFieldForRefsAndRevsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new AvgApi();
            var field = field_example;  // String | Field to be targeted for the aggregation (default to null)
            var idAlpha = idAlpha_example;  // String | The id of the target partner/merchant (default to null)
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional)  (default to null)

            try {
                // This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
                AggregateGroupedAvgResult result = apiInstance.getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling AvgApi.getPrtnOrMrchtGrAvgFieldForRefsAndRevs: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AvgApi();
$field = field_example; // String | Field to be targeted for the aggregation
$idAlpha = idAlpha_example; // String | The id of the target partner/merchant
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

try {
    $result = $api_instance->getPrtnOrMrchtGrAvgFieldForRefsAndRevs($field, $idAlpha, $requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForRefsAndRevs: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::AvgApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::AvgApi->new();
my $field = field_example; # String | Field to be targeted for the aggregation
my $idAlpha = idAlpha_example; # String | The id of the target partner/merchant
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg

eval { 
    my $result = $api_instance->getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field => $field, idAlpha => $idAlpha, requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForRefsAndRevs: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.AvgApi()
field = field_example # String | Field to be targeted for the aggregation (default to null)
idAlpha = idAlpha_example # String | The id of the target partner/merchant (default to null)
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by totalAvg (optional) (default to null)

try: 
    # This endpoint calculates the average value of a specific field (i.e the amount) for all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) for a specific partner/merchant and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC'). 
 The {id_alpha} can either be the {merchant_id_alpha} or the {partner_id_alpha}. 
 The {id_alpha} is a unique id assigned to each partner and each merchant in the Handpoint Terminal Management System (TMS).
    api_response = api_instance.get_prtn_or_mrcht_gr_avg_field_for_refs_and_revs(field, idAlpha, requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling AvgApi->getPrtnOrMrchtGrAvgFieldForRefsAndRevs: %s\n" % e)
extern crate AvgApi;

pub fn main() {
    let field = field_example; // String
    let idAlpha = idAlpha_example; // String
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = AvgApi::Context::default();
    let result = client.getPrtnOrMrchtGrAvgFieldForRefsAndRevs(field, idAlpha, requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Path parameters
Name Description
field *

Field to be targeted for the aggregation

idAlpha *

The id of the target partner/merchant

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by totalAvg

Responses


Count Endpoints

getGrPayoutsTxnsCount

This endpoint counts all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
/transactions/aggregate/group/count/payouts

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/count/payouts?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.CountApi;

import java.io.File;
import java.util.*;

public class CountApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        CountApi apiInstance = new CountApi();
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
        
        try {
            AggregateGroupedCountResult result = apiInstance.getGrPayoutsTxnsCount(requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CountApi#getGrPayoutsTxnsCount");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.CountApi;

public class CountApiExample {
    public static void main(String[] args) {
        CountApi apiInstance = new CountApi();
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
        
        try {
            AggregateGroupedCountResult result = apiInstance.getGrPayoutsTxnsCount(requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CountApi#getGrPayoutsTxnsCount");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
CountApi *apiInstance = [[CountApi alloc] init];
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional) (default to null)

// This endpoint counts all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
[apiInstance getGrPayoutsTxnsCountWith:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedCountResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.CountApi()
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getGrPayoutsTxnsCount(requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getGrPayoutsTxnsCountExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new CountApi();
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional)  (default to null)

            try {
                // This endpoint counts all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
                AggregateGroupedCountResult result = apiInstance.getGrPayoutsTxnsCount(requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling CountApi.getGrPayoutsTxnsCount: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CountApi();
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

try {
    $result = $api_instance->getGrPayoutsTxnsCount($requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CountApi->getGrPayoutsTxnsCount: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::CountApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::CountApi->new();
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

eval { 
    my $result = $api_instance->getGrPayoutsTxnsCount(requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CountApi->getGrPayoutsTxnsCount: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.CountApi()
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional) (default to null)

try: 
    # This endpoint counts all transactions representing an income of cash flow (EMV Sale, MSR Sale, Refund Reversal, Refund Cancellation and Pre-authorization Capture) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
    api_response = api_instance.get_gr_payouts_txns_count(requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CountApi->getGrPayoutsTxnsCount: %s\n" % e)
extern crate CountApi;

pub fn main() {
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = CountApi::Context::default();
    let result = client.getGrPayoutsTxnsCount(requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

Responses


getGrRefsAndRevsTxnsCount

This endpoint counts all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
/transactions/aggregate/group/count/refundsandreversals

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/count/refundsandreversals?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.CountApi;

import java.io.File;
import java.util.*;

public class CountApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        CountApi apiInstance = new CountApi();
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
        
        try {
            AggregateGroupedCountResult result = apiInstance.getGrRefsAndRevsTxnsCount(requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CountApi#getGrRefsAndRevsTxnsCount");
            e.printStackTrace();
        }
    }
}
import com.handpoint.api.txnfeed.api.CountApi;

public class CountApiExample {
    public static void main(String[] args) {
        CountApi apiInstance = new CountApi();
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
        CalendarInterval calendarInterval = ; // CalendarInterval | 
        Order order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
        
        try {
            AggregateGroupedCountResult result = apiInstance.getGrRefsAndRevsTxnsCount(requestConfig, groupBy, calendarInterval, order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CountApi#getGrRefsAndRevsTxnsCount");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];

// Configure API key authorization: (authentication scheme: ApiKeyAuth)
[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"AnalyticsApiKey"];
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"AnalyticsApiKey"];


// Create an instance of the API class
CountApi *apiInstance = [[CountApi alloc] init];
RequestConfig *requestConfig = ; // 
String *groupBy = groupBy_example; // List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
CalendarInterval *calendarInterval = ; //  (optional) (default to null)
Order *order = ; // Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional) (default to null)

// This endpoint counts all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
[apiInstance getGrRefsAndRevsTxnsCountWith:requestConfig
    groupBy:groupBy
    calendarInterval:calendarInterval
    order:order
              completionHandler: ^(AggregateGroupedCountResult output, NSError* error) {
    if (output) {
        NSLog(@"%@", output);
    }
    if (error) {
        NSLog(@"Error: %@", error);
    }
}];
var TxnFeedApi = require('txn_feed_api');
var defaultClient = TxnFeedApi.ApiClient.instance;

// Configure API key authorization: ApiKeyAuth
var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = "YOUR API KEY";
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix['AnalyticsApiKey'] = "Token";

// Create an instance of the API class
var api = new TxnFeedApi.CountApi()
var requestConfig = ; // {RequestConfig} 
var opts = {
  'groupBy': groupBy_example, // {String} List of fields used to group the query. Ex: serial number,card type etc.
  'calendarInterval': , // {CalendarInterval} 
  'order':  // {Order} Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getGrRefsAndRevsTxnsCount(requestConfig, opts, callback);
using System;
using System.Diagnostics;
using Com.Handpoint.Api.Txnfeed.Api;
using Com.Handpoint.Api.Txnfeed.Client;
using Com.Handpoint.Api.Txnfeed.Model;

namespace Example
{
    public class getGrRefsAndRevsTxnsCountExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.ApiKey.Add("AnalyticsApiKey", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("AnalyticsApiKey", "Bearer");
            
            // Create an instance of the API class
            var apiInstance = new CountApi();
            var requestConfig = new RequestConfig(); // RequestConfig | 
            var groupBy = groupBy_example;  // String | List of fields used to group the query. Ex: serial number,card type etc. (optional)  (default to null)
            var calendarInterval = new CalendarInterval(); // CalendarInterval |  (optional)  (default to null)
            var order = new Order(); // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional)  (default to null)

            try {
                // This endpoint counts all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
                AggregateGroupedCountResult result = apiInstance.getGrRefsAndRevsTxnsCount(requestConfig, groupBy, calendarInterval, order);
                Debug.WriteLine(result);
            } catch (Exception e) {
                Debug.Print("Exception when calling CountApi.getGrRefsAndRevsTxnsCount: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure API key authorization: ApiKeyAuth
ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKey('AnalyticsApiKey', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// ComHandpointApiTxnfeed\Configuration::getDefaultConfiguration()->setApiKeyPrefix('AnalyticsApiKey', 'Bearer');

// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\CountApi();
$requestConfig = ; // RequestConfig | 
$groupBy = groupBy_example; // String | List of fields used to group the query. Ex: serial number,card type etc.
$calendarInterval = ; // CalendarInterval | 
$order = ; // Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

try {
    $result = $api_instance->getGrRefsAndRevsTxnsCount($requestConfig, $groupBy, $calendarInterval, $order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CountApi->getGrRefsAndRevsTxnsCount: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use Com::Handpoint::Api::Txnfeed::Configuration;
use Com::Handpoint::Api::Txnfeed::CountApi;

# Configure API key authorization: ApiKeyAuth
$Com::Handpoint::Api::Txnfeed::Configuration::api_key->{'AnalyticsApiKey'} = 'YOUR_API_KEY';
# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
#$Com::Handpoint::Api::Txnfeed::Configuration::api_key_prefix->{'AnalyticsApiKey'} = "Bearer";

# Create an instance of the API class
my $api_instance = Com::Handpoint::Api::Txnfeed::CountApi->new();
my $requestConfig = Com::Handpoint::Api::Txnfeed::Object::RequestConfig->new(); # RequestConfig | 
my $groupBy = groupBy_example; # String | List of fields used to group the query. Ex: serial number,card type etc.
my $calendarInterval = ; # CalendarInterval | 
my $order = ; # Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

eval { 
    my $result = $api_instance->getGrRefsAndRevsTxnsCount(requestConfig => $requestConfig, groupBy => $groupBy, calendarInterval => $calendarInterval, order => $order);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CountApi->getGrRefsAndRevsTxnsCount: $@\n";
}
from __future__ import print_statement
import time
import com.handpoint.api.txnfeed
from com.handpoint.api.txnfeed.rest import ApiException
from pprint import pprint

# Configure API key authorization: ApiKeyAuth
com.handpoint.api.txnfeed.configuration.api_key['AnalyticsApiKey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# com.handpoint.api.txnfeed.configuration.api_key_prefix['AnalyticsApiKey'] = 'Bearer'

# Create an instance of the API class
api_instance = com.handpoint.api.txnfeed.CountApi()
requestConfig =  # RequestConfig | 
groupBy = groupBy_example # String | List of fields used to group the query. Ex: serial number,card type etc. (optional) (default to null)
calendarInterval =  # CalendarInterval |  (optional) (default to null)
order =  # Order | Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount) (optional) (default to null)

try: 
    # This endpoint counts all transactions representing an outgoing of cash flow (EMV Refund, MSR Refund, Sale Reversal, Sale Cancellation and Pre-authorization Capture Reversal) and serves the results grouped by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
    api_response = api_instance.get_gr_refs_and_revs_txns_count(requestConfig, groupBy=groupBy, calendarInterval=calendarInterval, order=order)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CountApi->getGrRefsAndRevsTxnsCount: %s\n" % e)
extern crate CountApi;

pub fn main() {
    let requestConfig = ; // RequestConfig
    let groupBy = groupBy_example; // String
    let calendarInterval = ; // CalendarInterval
    let order = ; // Order

    let mut context = CountApi::Context::default();
    let result = client.getGrRefsAndRevsTxnsCount(requestConfig, groupBy, calendarInterval, order, &context).wait();

    println!("{:?}", result);
}

Parameters

Body parameters
Name Description
requestConfig *

Request filters

Query parameters
Name Description
groupBy

List of fields used to group the query. Ex: serial number,card type etc.

calendarInterval

order

Enum [ASC/DESC] used to order the aggregated data by the number of hits (totalCount)

Responses


getGrTxnsCount

This endpoint counts the number of transactions and groups them by a set of query parameters ('groupBy', 'calendarInterval' or 'ASC/DESC').
/transactions/aggregate/group/count

Usage and SDK Samples

curl -X POST \
-H "AnalyticsApiKey: Your-Api-Key" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{ "startDate":"20200101000000", "endDate": "20200201000000" }'  \
"https://txnfeed.handpoint.io/transactions/aggregate/group/count?groupBy=&calendarInterval=&order="
                            
import com.handpoint.api.txnfeed.*;
import com.handpoint.api.txnfeed.auth.*;
import com.handpoint.api.txnfeed.model.*;
import com.handpoint.api.txnfeed.api.CountApi;

import java.io.File;
import java.util.*;

public class CountApiExample {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure API key authorization: ApiKeyAuth
        ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
        ApiKeyAuth.setApiKey("YOUR API KEY");
        // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
        //ApiKeyAuth.setApiKeyPrefix("Token");
        
        // Create an instance of the API class
        CountApi apiInstance = new CountApi();
        RequestConfig requestConfig = ; // RequestConfig | 
        String groupBy = groupBy_example; // String | List of fields used to group the transactions. Ex: serial number,card type etc.
        CalendarInterval c