Secuconnect\Client\LoyaltyCustomersApi

All URIs are relative to https://connect-testing.secupay-ag.de/api/v2

Method HTTP request Description
addCustomer POST /Loyalty/Customers POST Loyalty/Customers
assignPaymentContainer POST /Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId} POST Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId}
checkForDuplicates POST /Loyalty/Customers/{loyaltyCustomerId}/checkDuplicated/ POST Loyalty/Customers/{loyaltyCustomerId}/checkDuplicated/
getAll GET /Loyalty/Customers GET Loyalty/Customers
getOne GET /Loyalty/Customers/{loyaltyCustomerId} GET Loyalty/Customers/{loyaltyCustomerId}
removeAssignedPaymentContainer DELETE /Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId} DELETE Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId}
removeCustomer DELETE /Loyalty/Customers/{loyaltyCustomerId} DELETE Loyalty/Customers/{loyaltyCustomerId}
updateCustomer PUT /Loyalty/Customers/{loyaltyCustomerId} PUT Loyalty/Customers/{loyaltyCustomerId}

addCustomer

\Secuconnect\Client\Model\LoyaltyCustomersProductModel addCustomer($body)

POST Loyalty/Customers

Add loyalty customer

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$body = new \Secuconnect\Client\Model\LoyaltyCustomersDTO(); // \Secuconnect\Client\Model\LoyaltyCustomersDTO | loyalty Customer container properties

try {
    $result = $api_instance->addCustomer($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->addCustomer: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
body \Secuconnect\Client\Model\LoyaltyCustomersDTO loyalty Customer container properties

Return type

\Secuconnect\Client\Model\LoyaltyCustomersProductModel

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

assignPaymentContainer

\Secuconnect\Client\Model\LoyaltyCustomersProductModel assignPaymentContainer($loyalty_customer_id, $loyalty_payment_container_id)

POST Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId}

Assigns LoyaltyPaymentcontainer to customer

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | Loyalty customer id
$loyalty_payment_container_id = "loyalty_payment_container_id_example"; // string | LoyaltyPaymentcontainer id

try {
    $result = $api_instance->assignPaymentContainer($loyalty_customer_id, $loyalty_payment_container_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->assignPaymentContainer: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string Loyalty customer id
loyalty_payment_container_id string LoyaltyPaymentcontainer id

Return type

\Secuconnect\Client\Model\LoyaltyCustomersProductModel

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

checkForDuplicates

object checkForDuplicates($loyalty_customer_id)

POST Loyalty/Customers/{loyaltyCustomerId}/checkDuplicated/

check if there are duplicated customers for a given merchant

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | Loyalty customer id

try {
    $result = $api_instance->checkForDuplicates($loyalty_customer_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->checkForDuplicates: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string Loyalty customer id

Return type

object

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getAll

\Secuconnect\Client\Model\LoyaltyCustomersList getAll($count, $offset, $fields, $q, $sort)

GET Loyalty/Customers

Get a list of loyalty customers

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$count = 56; // int | The number of items to return.
$offset = 56; // int | The position within the whole result set to start returning items (First element is at 0).
$fields = "fields_example"; // string | List of fields to include in the result. Nested properties can be accessed with this notation: prop1.prop2  Example: prop3,prop1.prop2
$q = "q_example"; // string | A query string to restrict the returned items to given conditions. The query string must consist of any combination of single expressions in the form property:condition.  *                  A condition may contain:  *                      - wildcard \"*\" for any number of characters  *                      - wildcard \"?\" for one character  *                      - ranges in the form [value TO value]  *  *                  Single expressions may combined by 'AND', 'OR', 'NOT' operators and parenthesis '(', ')' for grouping.  *                  Property names can be nested like \"prop1.prop2\".  *                  Example: (NOT customer.name:meier*) AND (customer.age:[30 TO 40] OR customer.age:[50 TO 60])  *
$sort = "sort_example"; // string | String with comma separated pairs of field:order (e.g. contact.surname:asc,contact.comapnyname:desc). Result set will be sorted by included fields, in ascending 'asc', or descending 'dsc' order.

try {
    $result = $api_instance->getAll($count, $offset, $fields, $q, $sort);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->getAll: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
count int The number of items to return. [optional]
offset int The position within the whole result set to start returning items (First element is at 0). [optional]
fields string List of fields to include in the result. Nested properties can be accessed with this notation: prop1.prop2 Example: prop3,prop1.prop2 [optional]
q string A query string to restrict the returned items to given conditions. The query string must consist of any combination of single expressions in the form property:condition. A condition may contain: - wildcard \"\" for any number of characters - wildcard \"?\" for one character - ranges in the form [value TO value] Single expressions may combined by 'AND', 'OR', 'NOT' operators and parenthesis '(', ')' for grouping. Property names can be nested like \"prop1.prop2\". Example: (NOT customer.name:meier) AND (customer.age:[30 TO 40] OR customer.age:[50 TO 60]) * [optional]
sort string String with comma separated pairs of field:order (e.g. contact.surname:asc,contact.comapnyname:desc). Result set will be sorted by included fields, in ascending 'asc', or descending 'dsc' order. [optional]

Return type

LoyaltyCustomersList

Properties

Name Type Description Notes
count int Number of existing loyalty customers [optional]
data \Secuconnect\Client\Model\LoyaltyCustomersProductModel[] GET Loyalty/Customers [optional]

[Back to Model list] [Back to API list] [Back to README]

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getOne

\Secuconnect\Client\Model\LoyaltyCustomersProductModel getOne($loyalty_customer_id)

GET Loyalty/Customers/{loyaltyCustomerId}

Get loyalty customer for a specific id

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | Search one loyalty customer by provided id

try {
    $result = $api_instance->getOne($loyalty_customer_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->getOne: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string Search one loyalty customer by provided id

Return type

\Secuconnect\Client\Model\LoyaltyCustomersProductModel

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

removeAssignedPaymentContainer

\Secuconnect\Client\Model\LoyaltyCustomersProductModel removeAssignedPaymentContainer($loyalty_customer_id, $loyalty_payment_container_id)

DELETE Loyalty/Customers/{loyaltyCustomerId}/assignPaymentcontainer/{loyaltyPaymentContainerId}

Removes an assigned LoyaltyPaymentcontainer from customer

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | Loyalty customer id
$loyalty_payment_container_id = "loyalty_payment_container_id_example"; // string | LoyaltyPaymentcontainer id

try {
    $result = $api_instance->removeAssignedPaymentContainer($loyalty_customer_id, $loyalty_payment_container_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->removeAssignedPaymentContainer: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string Loyalty customer id
loyalty_payment_container_id string LoyaltyPaymentcontainer id

Return type

\Secuconnect\Client\Model\LoyaltyCustomersProductModel

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

removeCustomer

\Secuconnect\Client\Model\LoyaltyCustomersDeleted removeCustomer($loyalty_customer_id)

DELETE Loyalty/Customers/{loyaltyCustomerId}

Remove assigned loyalty customer

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | Loyalty customer id

try {
    $result = $api_instance->removeCustomer($loyalty_customer_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->removeCustomer: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string Loyalty customer id

Return type

LoyaltyCustomersDeleted

Properties

Name Type Description Notes
deleted bool Result is true or false [optional]

[Back to Model list] [Back to API list] [Back to README]

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

updateCustomer

\Secuconnect\Client\Model\LoyaltyCustomersProductModel updateCustomer($loyalty_customer_id, $body)

PUT Loyalty/Customers/{loyaltyCustomerId}

Function to update customer's data

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure OAuth2 access token for authorization: oauth_token
Secuconnect\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Secuconnect\Client\Api\LoyaltyCustomersApi();
$loyalty_customer_id = "loyalty_customer_id_example"; // string | loyalty Customer Id CUS_XXX
$body = new \Secuconnect\Client\Model\LoyaltyCustomersDTO(); // \Secuconnect\Client\Model\LoyaltyCustomersDTO | loyalty Customer container properties

try {
    $result = $api_instance->updateCustomer($loyalty_customer_id, $body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoyaltyCustomersApi->updateCustomer: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
loyalty_customer_id string loyalty Customer Id CUS_XXX
body \Secuconnect\Client\Model\LoyaltyCustomersDTO loyalty Customer container properties

Return type

\Secuconnect\Client\Model\LoyaltyCustomersProductModel

Authorization

oauth_token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]