API browser of generalInvoiceRequest450 COM module


/images/arrow_right.png IGeneralInvoiceResult::GetBalance method space
Retrieves the balance information.
space
/images/arrow_right.png Restful webservice calling syntax
[POST] /baseURL/IGeneralInvoiceResult/GetBalance
[JSON input data] pIGeneralInvoiceResult: longValue,    //interface address
[JSON result data] pdAmount:
pdAmountObligatory:
pdAmountPrepaid:
pdAmountReminder:
pdAmountDue:
pdAmountVat:
pbStatus:
doubleValue,
doubleValue,
doubleValue,
doubleValue,
doubleValue,
doubleValue,
booleanValue
 
[HTTP result status] 200 Return status 200 signals a successful method call
204 Return status 204 (noContent) signals that the end of an iteration is reached
>= 400 Return status >= 400 signals an unsuccessful function call. The returned JSON{errorCode: code, errorText:"text"} supplies the error message the same as GetAbortInfo() would do.
space
/images/arrow_right.png C/C++ calling syntax
HRESULT GetBalance( double
double
double
double
double
double
VARIANT_BOOL
*pdAmount,
*pdAmountObligatory,
*pdAmountPrepaid,
*pdAmountReminder,
*pdAmountDue,
*pdAmountVat,
*pbStatus);
[C/C++ return value] S_OK This value is returned if the function call was successful.
S_FALSE This value is returned if the end of an iteration is reached
E_name This value is returned if the function call was unsuccessful and an error exception was generated. Note that if you are using SmartPointers an exception is thrown under these conditions.
space
/images/arrow_right.png Calling argument description
[out] double *pdAmount The total amount in CHF of the invoice/reminder accumulated over all 2-digit precision service amounts. Therefore, the amount implicitly has a 2-digit precision as well.
 
Note that amount is negative if a credit advice or a storno request is produced.
[out] double *pdAmountObligatory The total amount in CHF of obligatory services (eIsObligatory = enObligationYes) accumulated over the 2-digit precision service amounts. Therefore, the amount implicitly has a 2-digit precision as well.
 
Note that amount might be negative if a credit advice or a storno request is produced.
[out] double *pdAmountPrepaid The prepaid amount in CHF of the invoice/reminder rounded to 2-digit precision that is subtracted from the total amount to calculate the amount due.
 
This amount can only be set in the IGeneralInvoiceRequest::SetTiers method. Furthermore this amount changes the sign if a credit advice or a storno request is produced.
[out] double *pdAmountReminder The optional reminder charge in CHF of the reminder rounded to 2-digit precision that is added to the total amount to calculate the amount due.
 
This amount can only be set in the /IGeneralInvoiceRequest::SetReminder method. Furthermore this amount changes the sign if a credit advice or a storno request is produced.
[out] double *pdAmountDue The due amount in CHF of the invoice/reminder (and coded into the ESR payment transaction) calculated as
«amount + amount_reminder - amount_prepaid»

where the used summands are 2-digit precision amounts and the result is finally rounded half up ("Kaufmännisches Runden")
 
Note that amount is negative if a credit advice or a storno request is produced.
[out] double *pdAmountVat The total VAT amount in CHF accumulated over all 2-digit precision service VAT amounts. Therefore, the total VAT amount implicitly has a 2-digit precision as well.
[out,retval] VARIANT_BOOL *pbStatus Return status of the method. If pbStatus is VARIANT_FALSE then an error occurred and GetAbortInfo should be called to retrieve the error string.
space