Class LatitudePayCreatePosPurchaseRequest
Represents a request to create a new payment plan.
Inherited Members
Namespace: Yort.LatitudePay.InStore
Assembly: Yort.LatitudePay.InStore.dll
Syntax
public class LatitudePayCreatePosPurchaseRequest
Properties
| Improve this Doc View SourceBillingAddress
Gets or sets the billing address for this payment plan. Optional.
Declaration
[JsonProperty("billingAddress")]
public LatitudePayAddress BillingAddress { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayAddress | The billing address. |
See Also
| Improve this Doc View SourceCustomer
Gets or sets details about the customer the payment plan is for. Required (see remarks).
Declaration
[Required]
[JsonProperty("customer")]
public LatitudePayCustomer Customer { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayCustomer | A LatitudePayCustomer containing details of the customer. |
Remarks
You must provide a LatitudePayCustomer instance with the MobileNumber set, but providing additional details when known can speed the sign up process for new customers.
IdempotencyKey
A value unique to this payment, but common to all CreatePosPurchaseRequests sent for this payment, to ensure the payment is created only once.
Declaration
[JsonIgnore]
public string IdempotencyKey { get; set; }
Property Value
Type | Description |
---|---|
String |
Remarks
This value is optional but highly recommended as without using it you cannot guarantee network problems and other issues won't lead to customers making payments the system doesn't know about.
Set this property to a value that is unique for this *payment* but the same for each call to CreatePosPurchaseAsync(LatitudePayCreatePosPurchaseRequest) for that payment. Any repeat requests using the same idempotency key value will return the original response without creating a second payment or sending the customer another message. If the original request never got processed (due to power failure, network outage etc) then the next request will be treated as the first one. This guarantees the customer gets one and only one request to make payment.
Products
Gets or sets details of the items purchased with this payment plan. At least one valid LatitudePayProduct is required.
Declaration
[JsonProperty("products")]
public IEnumerable<LatitudePayProduct> Products { get; set; }
Property Value
Type | Description |
---|---|
IEnumerable<LatitudePayProduct> | The products purchased. |
Remarks
Note products collection may be enumerated multiple times as part of the validation and send processes, so should be a stable enumerable set and not a LINQ or dynamic query that might be subject to change or iterable only once.
The product information is informative only (displayed to customer and merchant when viewing transaction in LatitudePay portals), it is not required for the value of items to total to the payment amount etc.
See Also
| Improve this Doc View SourceReference
A unique reference for this payment plan. Required.
Declaration
[Required]
[JsonProperty("reference")]
public string Reference { get; set; }
Property Value
Type | Description |
---|---|
String | The client generated reference for this payment plan. |
ReturnUrls
Gets or sets url's that will be used for callbacks when the payment plan changes status. Optional, can be null.
Declaration
[JsonProperty("returnUrls")]
public LatitudePayReturnUrls ReturnUrls { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayReturnUrls | The callback urls. |
ShippingAddress
Gets or sets the shipping address for products purchased with this payment plan. Optional.
Declaration
[JsonProperty("shippingAddress")]
public LatitudePayAddress ShippingAddress { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayAddress | The shipping address. |
See Also
| Improve this Doc View SourceShippingLines
Gets or sets a collection of details about shipments paid for with this payment plan, if any. Optional.
Declaration
[JsonProperty("shippingLines")]
public IEnumerable<LatitiudePayShippingLine> ShippingLines { get; set; }
Property Value
Type | Description |
---|---|
IEnumerable<LatitiudePayShippingLine> | The shipping lines. |
Remarks
While you do not have to provide any shipping lines, this value cannot be null when sent to LatitudePay. If the value is left null, an empty array will be assigned for you when the request is sent.
See Also
| Improve this Doc View SourceTaxAmount
Gets or sets the amount of tax included in TotalAmount. Optional, can be set to zero for the currency of the payment.
Declaration
[JsonProperty("taxAmount")]
public LatitudePayMoney TaxAmount { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayMoney | The tax amount included in this payment plan. |
See Also
| Improve this Doc View SourceTotalAmount
Gets or sets the total amount. Must be a positive non-zero value.
Declaration
[Required]
[JsonProperty("totalAmount")]
public LatitudePayMoney TotalAmount { get; set; }
Property Value
Type | Description |
---|---|
LatitudePayMoney | The total amount. |
Remarks
The amount specified here is the full amount charged as part of the payment plan. It does not have to match the sum of values from Products in the case of split payments or complex POS transactions.