|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.gsm.oneapi.payment.Reservation
public class Reservation
Field Summary | |
---|---|
static boolean |
dumpRequestAndResponse
|
Constructor Summary | |
---|---|
Reservation(ServiceEndpoints endPoints,
java.lang.String authorisationHeader)
Creates a new instance of the Payment Reservation API main interface. |
Method Summary | |
---|---|
PaymentResponse |
chargeAmount(java.lang.String endUserId,
java.lang.String referenceCode,
java.lang.String description,
java.lang.String currency,
double amount,
int referenceSequence,
java.lang.String code,
java.lang.String callbackURL,
java.lang.String clientCorrelator,
java.lang.String onBehalfOf,
java.lang.String purchaseCategoryCode,
java.lang.String channel,
double taxAmount,
java.lang.String serviceId,
java.lang.String productId)
Charge an amount to the end user's bill / mobile phone account from reserved amounts |
static void |
main(java.lang.String[] args)
|
PaymentResponse |
releaseReservation(java.lang.String endUserId,
java.lang.String referenceCode,
int referenceSequence)
Release a reserved amount Charge an amount to the end user's bill / mobile phone account from reserved amounts |
PaymentResponse |
reserveAdditionalAmount(java.lang.String endUserId,
java.lang.String referenceCode,
java.lang.String description,
java.lang.String currency,
double amount,
int referenceSequence,
java.lang.String code)
Reserve an additional payment amount on the end user's bill / mobile phone account. |
PaymentResponse |
reserveAdditionalAmount(java.lang.String endUserId,
java.lang.String referenceCode,
java.lang.String description,
java.lang.String currency,
double amount,
int referenceSequence,
java.lang.String code,
java.lang.String onBehalfOf,
java.lang.String purchaseCategoryCode,
java.lang.String channel,
double taxAmount,
java.lang.String serviceId,
java.lang.String productId)
Reserve an additional payment amount on the end user's bill / mobile phone account. |
PaymentResponse |
reserveInitialAmount(java.lang.String endUserId,
java.lang.String referenceCode,
java.lang.String description,
java.lang.String currency,
double amount,
java.lang.String code,
java.lang.String clientCorrelator,
java.lang.String onBehalfOf,
java.lang.String purchaseCategoryCode,
java.lang.String channel,
double taxAmount,
java.lang.String serviceId,
java.lang.String productId)
Reserve an initial payment amount on the end user's bill / mobile phone account. |
void |
setAuthorisationHeader(java.lang.String authorisationHeader)
Can be used to update the service authorisation header |
void |
setEndpoints(ServiceEndpoints endPoints)
Can be used to update the service endpoints |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static boolean dumpRequestAndResponse
Constructor Detail |
---|
public Reservation(ServiceEndpoints endPoints, java.lang.String authorisationHeader)
endPoints
- contains a set of service/ call specific endpointsauthorisationHeader
- Base 64 encoded username/ passwordServiceEndpoints
,
JSONRequest.getAuthorisationHeader(String, String)
Method Detail |
---|
public void setEndpoints(ServiceEndpoints endPoints)
endPoints
- contains a set of service/ call specific endpointsServiceEndpoints
public void setAuthorisationHeader(java.lang.String authorisationHeader)
authorisationHeader
- Base 64 encoded username/ passwordJSONRequest.getAuthorisationHeader(String, String)
public PaymentResponse reserveInitialAmount(java.lang.String endUserId, java.lang.String referenceCode, java.lang.String description, java.lang.String currency, double amount, java.lang.String code, java.lang.String clientCorrelator, java.lang.String onBehalfOf, java.lang.String purchaseCategoryCode, java.lang.String channel, double taxAmount, java.lang.String serviceId, java.lang.String productId)
endUserId
- (mandatory) is the end user ID; in this case their MSISDN including the 'tel:' protocol identifier and the country code preceded by '+'. i.e., tel:+16309700001. OneAPI also supports the Anonymous Customer Reference (ACR) if provided by the operator. Do not URL encode this value prior to passingreferenceCode
- (mandatory, unique per charge event) is your reference for reconciliation purposes. The operator should include it in reports so that you can match their view of what has been sold with yours by matching the referenceCodes.description
- (mandatory) is the human-readable text to appear on the bill, so the user can easily see what they bought.currency
- (mandatory) is the 3-figure code as per ISO 4217. Note either amount and currency or code must be provided.amount
- (mandatory) can be a whole number or decimal. Here means the amount to refund, which can be a full or partial refund of the original charge. Note either amount and currency or code must be provided.code
- (mandatory) a code provided by the OneAPI implementation that is used to reference an operator price point. Note either amount and currency or code must be provided.clientCorrelator
- (optional) uniquely identifies the refund request. If there is a communication failure during the refund request, using the same clientCorrelator when retrying the request allows the operator to avoid applying the same refund twice.onBehalfOf
- (optional) allows aggregators/partners to specify the actual payee.purchaseCategoryCode
- (optional) specifies the type/category of purchase e.g. "Video", "Game"channel
- (optional) can be "Wap", "Web", "SMS", depending on the source of user interactiontaxAmount
- (optional) tax already charged by the merchant.serviceId
- (optional) The ID of the partner/merchant serviceproductId
- (optional) combines with the serviceID to uniquely identify the product being purchased.PaymentResponse
public PaymentResponse reserveAdditionalAmount(java.lang.String endUserId, java.lang.String referenceCode, java.lang.String description, java.lang.String currency, double amount, int referenceSequence, java.lang.String code, java.lang.String onBehalfOf, java.lang.String purchaseCategoryCode, java.lang.String channel, double taxAmount, java.lang.String serviceId, java.lang.String productId)
endUserId
- (mandatory) is the end user ID; in this case their MSISDN including the 'tel:' protocol identifier and the country code preceded by '+'. i.e., tel:+16309700001. OneAPI also supports the Anonymous Customer Reference (ACR) if provided by the operator. Do not URL encode this value prior to passingreferenceCode
- (mandatory, unique per charge event) is your reference for reconciliation purposes. The operator should include it in reports so that you can match their view of what has been sold with yours by matching the referenceCodes.description
- (mandatory) is the human-readable text to appear on the bill, so the user can easily see what they bought.currency
- (mandatory) is the 3-figure code as per ISO 4217. Note either amount and currency or code must be provided.amount
- (mandatory) can be a whole number or decimal. Here means the additional amount to reserve. Note either amount and currency or code must be provided.referenceSequence
- (mandatory) can be a whole number or decimal.code
- (mandatory) a code provided by the OneAPI implementation that is used to reference an operator price point. Note either amount and currency or code must be provided.onBehalfOf
- (optional) allows aggregators/partners to specify the actual payee.purchaseCategoryCode
- (optional) specifies the type/category of purchase e.g. "Video", "Game"channel
- (optional) can be "Wap", "Web", "SMS", depending on the source of user interactiontaxAmount
- (optional) tax already charged by the merchant.serviceId
- (optional) The ID of the partner/merchant serviceproductId
- (optional) combines with the serviceID to uniquely identify the product being purchased.PaymentResponse
public PaymentResponse reserveAdditionalAmount(java.lang.String endUserId, java.lang.String referenceCode, java.lang.String description, java.lang.String currency, double amount, int referenceSequence, java.lang.String code)
endUserId
- (mandatory) is the end user ID; in this case their MSISDN including the 'tel:' protocol identifier and the country code preceded by '+'. i.e., tel:+16309700001. OneAPI also supports the Anonymous Customer Reference (ACR) if provided by the operator. Do not URL encode this value prior to passingreferenceCode
- (mandatory, unique per charge event) is your reference for reconciliation purposes. The operator should include it in reports so that you can match their view of what has been sold with yours by matching the referenceCodes.description
- (mandatory) is the human-readable text to appear on the bill, so the user can easily see what they bought.currency
- (mandatory) is the 3-figure code as per ISO 4217. Note either amount and currency or code must be provided.amount
- (mandatory) can be a whole number or decimal. Here means the additional amount to reserve. Note either amount and currency or code must be provided.referenceSequence
- (mandatory) can be a whole number or decimal. Here means the amount to refund, which can be a full or partial refund of the original chargecode
- (mandatory) a code provided by the OneAPI implementation that is used to reference an operator price point. Note either amount and currency or code must be provided.PaymentResponse
public PaymentResponse chargeAmount(java.lang.String endUserId, java.lang.String referenceCode, java.lang.String description, java.lang.String currency, double amount, int referenceSequence, java.lang.String code, java.lang.String callbackURL, java.lang.String clientCorrelator, java.lang.String onBehalfOf, java.lang.String purchaseCategoryCode, java.lang.String channel, double taxAmount, java.lang.String serviceId, java.lang.String productId)
endUserId
- (mandatory) is the end user ID; in this case their MSISDN including the 'tel:' protocol identifier and the country code preceded by '+'. i.e., tel:+16309700001. OneAPI also supports the Anonymous Customer Reference (ACR) if provided by the operator. Do not URL encode this value prior to passingreferenceCode
- (mandatory, unique per charge event) is your reference for reconciliation purposes. The operator should include it in reports so that you can match their view of what has been sold with yours by matching the referenceCodes.description
- (mandatory) is the human-readable text to appear on the bill, so the user can easily see what they bought.currency
- (mandatory) is the 3-figure code as per ISO 4217. Note either amount and currency or code must be provided.amount
- (mandatory) can be a whole number or decimal. Here means the amount to charge against a prior reservation. Note either amount and currency or code must be provided.referenceSequence
- (mandatory) can be a whole number or decimal.code
- (mandatory) a code provided by the OneAPI implementation that is used to reference an operator price point. Note either amount and currency or code must be provided.callbackURL
- (optional) URL to post the result of the charge operation toclientCorrelator
- (optional) uniquely identifies the refund request. If there is a communication failure during the refund request, using the same clientCorrelator when retrying the request allows the operator to avoid applying the same refund twice.onBehalfOf
- (optional) allows aggregators/partners to specify the actual payee.purchaseCategoryCode
- (optional) specifies the type/category of purchase e.g. "Video", "Game"channel
- (optional) can be "Wap", "Web", "SMS", depending on the source of user interactiontaxAmount
- (optional) tax already charged by the merchant.serviceId
- (optional) The ID of the partner/merchant serviceproductId
- (optional) combines with the serviceID to uniquely identify the product being purchased.PaymentResponse
public PaymentResponse releaseReservation(java.lang.String endUserId, java.lang.String referenceCode, int referenceSequence)
endUserId
- (mandatory) is the end user ID; in this case their MSISDN including the 'tel:' protocol identifier and the country code preceded by '+'. i.e., tel:+16309700001. OneAPI also supports the Anonymous Customer Reference (ACR) if provided by the operator. Do not URL encode this value prior to passingreferenceCode
- (mandatory, unique per charge event) is your reference for reconciliation purposes. The operator should include it in reports so that you can match their view of what has been sold with yours by matching the referenceCodes.referenceSequence
- (mandatory) can be a whole number or decimal.PaymentResponse
public static void main(java.lang.String[] args)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |