Package DE_EPAGES::Klarna::API::KlarnaClient
This class implements the client for Klarna web interface.
Base |
- |
@EXPORT_OK |
Functions
- ActivateInvoice
- AddTransaction
- CancelInvoice
- CheckOrderStatus
- DeleteInvoice
- GetMonthlyCost
- GetPclass
- GetPclasses
- GetPeriodicCost
- GetTotalCreditPurchaseCost
- Gross2net
- Net2gross
- SendInvoiceToCustomer
- UpdateInvoice
- _GetLastName
- new
ActivateInvoice
Function sends activating request to Klarna.
Syntax |
my $hResponse = $self->ActivateInvoice($hParams) |
Input |
|
Return |
|
AddTransaction
Function sends a transaction to Klarna.
Syntax |
my $hResponse = $self->AddTransaction($hParams) |
Input |
|
Return |
|
CancelInvoice
Cancels an invoice at Klarna
Syntax |
$self->CancelInvoice($LineItemContainer); |
Input |
|
Return |
|
CheckOrderStatus
Check status of Klarna payment for existing order
Syntax |
$self->CheckOrderStatus($LineItemContainer); |
Input |
|
Return |
|
DeleteInvoice
Function sends deleting request to Klarna.
Syntax |
my $hResponse = $self->DeleteInvoice($hParams) |
Input |
|
Return |
|
GetMonthlyCost
Function calculates monthly cost. Formulas are copied from php package of Klarna (monthly_cost function).
Syntax |
my $result = $self->GetMonthlyCost($hParams) |
Input |
|
Return |
|
GetPclass
Function returns pclass id number.
Syntax |
my $Encoding = GetPclass($LineItemContainer); |
Input |
|
Return |
|
GetPclasses
Function gets pclass values from Klarna.
Syntax |
my $hResponse = $self->GetPclasses($hParams) |
Input |
|
Return |
|
GetPeriodicCost
Function calculates periodic cost. Formulas are copied from php package of Klarna (periodic_cost function).
Syntax |
my $result = $self->GetPeriodicCost($hParams) |
Input |
|
Return |
|
GetTotalCreditPurchaseCost
Function calculates total credit purchase cost. Formulas are copied from php package of Klarna (total_credit_purchase_cost function).
Syntax |
my $result = $self->GetTotalCreditPurchaseCost($hParams) |
Input |
|
Return |
|
Gross2net
Converts a price from gross to net if necessary
Syntax |
Gross2net($PaymentMethod, $GrossValue); |
Input |
|
Return |
|
Net2gross
Converts a price from net to gross if necessary
Syntax |
Net2gross($PaymentMethod, $NetValue); |
Input |
|
Return |
|
SendInvoiceToCustomer
Function sends request to Klarna that invoice can be sent to customer.
Syntax |
my $hResponse = $self->SendInvoiceToCustomer($hParams) |
Input |
|
Return |
|
UpdateInvoice
Function sends update request to Klarna.
Syntax |
my $hResponse = $self->UpdateInvoice($hParams) |
Input |
|
Return |
|
_GetLastName
Function returns the last name
Syntax |
my $LastName = _GetLastName($Address); |
Input |
|
Return |
|
new
Constructor for KlarnaClient
Syntax |
$Object = DE_EPAGES::Klarna::API::KlarnaClient->new(); |
Input |
|
Return |
|