Deprecated feature

OrderProcess URL

Submits an order for processing. The order must be locked by the OrderPrepare command.

URL

OrderProcess

Controller command

com.ibm.commerce.order.commands.OrderProcessCmd

Implementation class

com.ibm.commerce.order.commands.OrderProcessCmdImpl

Commands called

Diagram

Legend

URL structure

http://host_name/path/
The fully qualified name of your Transaction server and the configuration path.

Parameter values

forUser
Specifies the logon ID of the user on whose behalf the command runs; only a person with the authority to process orders can specify this parameter.
forUserId
Same as forUser, but identifies the user by the internal user ID as found in the USERS table.
langId
Sets or resets the preferred language for the session; the supported languages for a store are found in the STORELANG table.
storeId
Specifies the reference number of the store with which the order is to be placed. This value is ignored unless an error occurs before the order is resolved. It is used only to call the correct store's exception handler.
orderId
Required: Specifies the reference number of the order to be processed. This parameter can be repeated.
externalUserId
Specifies a user ID to be sent with the order-transfer request.
externalPassword
Specifies a password for the user ID specified by the externalUserId parameter.
transferMode
Specifies the mode of transfer to an external system. A value of 0 transfers the order without payment information (shopping-cart transfer); a value of 1 transfers the order with payment information (purchase-order transfer). The default value is 0.
billtoAddressId
Specifies the reference number of the address to bill.
field1, field2, and field3
Specify customizable fields.
notify_[msgtype]_transportname_attributename
Specifies the configuration attributes that apply to order notifications for a specific message type and message transport. Include the following variables to define this parameter:
msgtype
Optional. If you do not include a value for this variable, the configuration attribute applies to all message types. If you specify a msgtype value for one attribute, such as "subject", specify the same msgtype value for all attributes that are used in the notification request. The values for this variable are stored in the NAME column of the MSGTYPES table.
transportname
The values for this variable are stored in the NAME column of the TRANSPORT table.
attributename
The values for this variable can be any of the following values:
  • recipient
  • CC
  • BCC
  • sender
  • subject
  • replyTo
  • contentType
The following are examples of defined notification parameters:
  • The following example sends the "order received" email notification for orders that are processed by this command to two email addresses, john@ibm.com, and victor@ibm.com:
    notify_OrderReceived_EMailSender_recipient=john@ibm.com,victor@ibm.com
    
  • This example sends all types of order email notifications to a single email address: jack@ibm.com:
    notify_EMailSender_recipient=jack@ibm.com
    
The following example shows a set of parameters that are invalid because the msgtype values are different between the attributes that are used in the request notification:
notify_OrderReceived_EMailSender_subject=We have received your order
notify_EMailSender_recipient=john@ibm.com,victor@ibm.com
The following examples show valid sets of parameters. Each set includes parameters that have the same msgtype value for the attributes within the request notification:
  • notify_OrderReceived_EMailSender_subject=We have received your order
    notify_OrderReceived_EMailSender_recipient=john@ibm.com,victor@ibm.com
    
  • notify_EMailSender_subject=Order notification
    notify_EMailSender_recipient=john@ibm.com,victor@ibm.com
  • notify_OrderReceived_EMailSender_subject=We have received your order
    notify_OrderReceived_EMailSender_recipient=john@ibm.com,victor@ibm.com
    notify_EMailSender_recipient=john@ibm.com,victor@ibm.com
Note: If you want to send an email notification to a guest customer, then you must capture the email address of the guest customer.
notifyMerchant
Specifies whether the store is notified when the order processing is complete.
notifyShopper
Specifies whether the customer is notified when the order processing is complete. Email notifications are not sent if PrimePaymentCmd fails. A value of 1 specifies that the customer is notified; a value of 0 specifies that the customer is not notified.
quoteExpiryPolicy
Defines the behavior of the command if the order total expires or an order item's fulfillment center changes during inventory allocation. Order total expires if the current time is greater than or equal to the last update timestamp on the order plus the number of seconds specified in the QUOTEGOODFOR column of the STORE table. This parameter can have three values:
alwaysProceed
Always proceed with processing the order after the order total is recalculated.
stopOnBiggerTotal
Proceed with processing the order if the recalculated order total is unchanged or is less than the previous order total. Otherwise, redirect to a URL specified by the quoteExpiredUrl.
neverProceed
Always redirect to the URL specified by the quoteExpiredUrl parameter.
quoteExpiredURL
Specifies the URL to which to redirect if the order total expired in agreement with the expiry policy specified by the quoteExpiryPolicy parameter.
notifyOrderSubmitted
Specifies whether the customer is notified when the order is successfully submitted for processing. A value of 1 specifies that the customer is notified; a value of 0 specifies that the customer is not notified. The default is 0.
availabilityChangeURL
Specifies the URL to which to redirect when the estimated availability time plus the shipping offset for any order item moves into the future (as a result of allocating or back ordering inventory) by more than the time interval specified by the maxAvailabilityChange parameter. This parameter is ignored if ATP inventory allocation is not enabled.
maxAvailabilityChange
Specifies the time interval, in seconds, mentioned in the availabilityChangeURL parameter description. The default value is 3600 (1 hour). This parameter is ignored if the availabilityChangeURL parameter is not specified, or if ATP inventory allocation is not enabled.
noInventoryURL
Specifies the URL to which to redirect if any of the items in the order cannot be allocated or backordered. This parameter is ignored if ATP inventory allocation is not enabled.
tcId
Specifies the identifier of a Terms and Conditions object (refer to the TERMCOND table). If this parameter is specified and if it identifies a PaymentTC, and if that PaymentTC specifies a memberId and an address nickName (refer to the PaymentTC mapping), then the memberId and address nickName are used to determine the billing address, in which case the billToAddressId parameter is ignored.
Notes about order notification: If you need to configure order notification:
  1. Enable outbound messaging.
  2. Create templates for composing order notification messages.
quotationSubmission
Controls whether the relType attribute values for "selection" OrderQuotationRel objects that identify the order being processed with their childId attribute must be changed to "submission". A value of 0 does not change the relType attributes of the OrderQuotationRel objects in the list to indicate "submission". A value of 1 does change the relType attributes to indicate "submission". The default value is 0.
reduceParentQuantities
Controls whether quantities of order items in the selection parent order are reduced by the quantities of order items in the order that is being processed. A value of 0 does not reduce parent quantities; a value of 1 reduces parent quantities. The default value is 0.

The parent order is updated only when the status attribute is P or E.

Only those order items that have the same CatalogEntryId, SpecifiedItemId, and correlationGroup attribute values as the items in the order are updated.

continue
Controls whether order processing continues to the next order when there is a failure in processing one of multiple orders. A value of 0 specifies that the process should not continue; a value of 1 specifies that the process should continue. The default value is 0.
isPIAddNeeded
If not passed, the default value is true. If it is true, PIAdd is called to add one payment instruction. Otherwise, no payment instruction is added. If isPIAddNeeded is not passed, or if isPIAddNeeded=Y, policyId is required.
payMethodId
The meaning of the payMethodId parameter changed from version 5.x to version 6.x. Older versions used payMethodId to set the payment method ID to add payment instruction. This has been deprecated for more than 2 releases, and was removed from version 6. Now, payMethodId means the payment method ID of the payment instruction to add. It corresponds to the column POLICYNAME of the record in the table POLICY used by this payment instruction.
policyId
Sets the payment policy ID. If it is not set, use the default policy ID. It is used only for compatible mode.
valueFromProfileOrder
If this parameter is not passed in, the value is 'N.' This parameter indicates that if isPIAddNeeded is Y or not passed in, the payment information for the profile is queried out and used in the payment protocol data. This is used in quick checkout.
billing_address_id
If isPIAddNeeded is true, sets the billing address Id of the Payment Instruction. If this parameter is not set, it uses the billing address of the order.
PONumber_i
Sets the purchase order number for this order for the group i. If the purchaseorder_id is specified, this value is replaced.
purchaseorder_id
Sets the purchase order number for this order for the group i.
paymentInstructionId
Use this parameter to pass sensitive payment information for payment instructions.

For example, a shopper adds 2 payment instructions (10001 and 10002). The shopper inputs payment information for a third payment instruction. The shopper clicks the submit order button and is prompted to enter credit card verification information for all three payment instructions. Next, the order is submitted and the OrderProcess command is called. In this example, the relevant parameters are as follows:

paymentInstructionId_1=10001&paymentInstructionId_2=10002&pay_data_cc_cvc_1=1111&pay_data_cc_cvc_2=2222&pay_data_cc_cvc_0=3333

This information is passed to the corresponding payment plug-in as extended data for the payment instruction. This data is not persisted.

To use the paymentInstructionId parameter, you must configure the payment plug-in to use synchronous event processing.

Example 1

The following command processes the placing of an order whose reference number is 3.

http://myhostname/webapp/wcs/stores/servlet/OrderProcess?orderId=3

Behavior

Call OrderCommentRecordContrlCmd to process any order comments from the CSR

If the flag updateChannelId is set:
  • Update the order channel Id

Call PIAddCmd to add payment instructions if the remaining amount is greater than zero and if isPIAddNeeded = Y

Call ValidatePaymentMethodCmd to validate any existing PIs for the current order (not bound to "If the flag updateChannelId is set")

If Unified Business Flow is enabled:
  • Call BusinessFlowUrlEventCmd (UBF command) to process the order in Unified Business Flow:
    • Initialize BusinessFlowEvent
    • In BusinessFlowEventListener
      • Execute OrderProcessPreApprovalCmd, which invokes PreProcessOrderCmd
      • Execute OrderProcessCheckApprovalCmd to check whether approval is required
      • Execute OrderProcessPostApprovalCmd, which invokes ProcessOrderCmd
Otherwise:
  • Call ProcessOrderCmd directly to process order without Unified Business Flow

Call RaiseOrderEventCmd to raise ORDER_SUBMISSION_EVENT (not bound to "Otherwise")

Exception conditions

  • If the order is not locked, the command throws the ECApplicationException specifying the OrderUnlockErrorView command.
  • If the customer typed incorrect data, the command throws the ECApplicationException specifying the BadOrderDataErrorView error view command to notify the customer.
  • If the order is not pending, the command throws the ECApplicationException exception specifying the OrderNoneErrorView command.
  • If any of the contracts that are used by the order are not valid, the command throws the ECApplicationException.