7.10.3 DeliverBasketRequest Method
The DeliverBasketRequest Method receives a set of deliver requests and puts them into one or several machine engines, after checking the correct price and collecting the (see 6.3.2.9 for details).
If the execution of the Method cannot be done due to some application logic, the Method should return an Uncertain StatusCode and provide details of the failure in the Status output Argument. When the Method returns an Uncertain StatusCode, the Method is considered to be failed, and no basket was created.
The signature of this Method is specified below. Table 33 and Table 34 specify the Arguments and AddressSpace representation, respectively.
If no UserId or PaymentMode is provided, the payment service assumes appropriate values. If the user choses a different UserId or PaymentMode when initiating the payment, that effects the price, the basket delivery may fail. The status of the basket indicates the used UserId and PaymentMode. The UI may use this information to get the price for those, displays it to the user and if the user accepts, automatically triggers a new DeliverRequest.
Signature
DeliverBasketRequest (
[in] 0:String UserId,
[in] 0:String PaymentMode,
[in] SelectionDataType[] BasketContent,
[in] PriceDataType Price,
[out] 0:UInt64[] TransactionIds,
[out] 0:UInt64 BasketId,
[out] 0:Int32 Status);| Argument | Description |
| UserId | Identification of the user. If the UserId is NULL or an empty string, the payment service selects the most appropriate UserId. If during payment a different UserId is used, which effects the price, the basket delivery may fail, or the price for the selected UserId is used. |
| PaymentMode | Payment mode to be used for the delivery. Supported payment modes of the payment service are defined in the PaymentModes of the PaymentService Object, using the PaymentModeId. If the PaymentMode is NULL or an empty string, the payment service selects the most appropriate payment mode or potentially several payment modes. If during payment a different payment mode is used, which effects the price, the basket delivery will fail. The special PaymentMode "NoCheck" indicates, that the Price is not checked, and the payment service will use a price depending on the payment mode used in the payment. This supports scenarios, where the user does not choose a payment mode before the deliver request and the UI typically displays the potentially different prices for all payment modes. |
| BasketContent | Defines an array what should be delivered, each entry including the corresponding machine engine, the SelectionId, and the requested options. Shall have at least one entry. |
| Price | The price expected to be paid for the basket. |
| TransactionIds | An array of unique identifiers given into the machine engine that uniquely identifies each deliver request. It shall be used as the TransactionId in the DeliveryRequests and the DeliveryProgress Variables. The array shall have the same length as the BasketContent and reflects each selection of that array. Shall not be interpreted when the Method returns with an UNCERTAIN StatusCode. |
| BasketId | A unique identifier of the basket. Shall not be interpreted when the Method returns with an UNCERTAIN StatusCode. |
| Status | Status of the execution of the method. If issues occurred during execution. 0 = Execution was successful. -1 = Machine engine referenced in MachineEngineProductInstanceUri not managed by payment service. -2 = Invalid UserId -3 = Invalid PaymentMode -4 = Invalid Price -5 = Invalid SelectionId -6 = Invalid Option contained in Options -7 = MachineEngine currently not available -8 = PriceService currently not available -9 = Cannot be executing because another payment is running -10 = Invalid SelectionListVersion -11 = Audit not running Vendors may return a vendor specific status starting with number -16 or smaller. |
Method Result Codes (defined in Call Service)
| Result Code | Description |
| Bad_UserAccessDenied | See OPC 10000-4 for a general description. |
| Attribute | Value | ||||
| BrowseName | DeliverBasketRequest | ||||
| References | NodeClass | BrowseName | DataType | TypeDefinition | ModellingRule |
|---|---|---|---|---|---|
| 0:HasProperty | Variable | 0:InputArguments | 0:Argument[] | 0:PropertyType | 0:Mandatory |
| 0:HasProperty | Variable | 0:OutputArguments | 0:Argument[] | 0:PropertyType | 0:Mandatory |