Summary
The contingency fee allows a grocer to add an additional fee to boost the initial total of the cart to ensure that there is a buffer at the pre-auth that will account for any increases to cost of goods due to substitutions at fulfillment.
Contingency fee is also referenced in the post about cart functionality
The contingency fee percentage is set in the theme (see theme settings below); when the cart page loads, it tallies the total of all items in the cart and multiplies it by the contingency fee percentage. The resulting cost is added to each order.
When used, the contingency fee line item and associated cost should never be included in the final order. It should be deleted at fulfillment in Orderbot and also deleted in Shopify when an order is being administered for delivery or pickup.
Front end
On the cart page, the contingency fee is calculated and displayed in the cart summary. It displays the percentage and if the questions mark is clicked, a text box opens do display messaging explaining the contingency fee in more detail.

In the checkout, the contingency fee is grouped in the subtotalling area.

Theme settings and admin
Since Shopify doesn't permit additional fees to be created in carts and checkout, the contingency fee solution involves a dummy or "ghost" product that is set up in Shopify.
Before the contingency fee system can be set up, the contingency fee product needs to be created. The product should be set up as follows:
- Title: Contingency Fee
- SKU: CONTFEE
- Price: $0.01
Once the product is set up, you can configure the theme settings.
Online store > Customize > Theme Settings > Cart
In this settings panel, the following controls are available for the contingency fee:
- Enable contingency fee (on/off toggle)
- The CF percentage
- Selection of the contingency fee product that has been set up
- The CF message that displays in the cart
Finally, to ensure that customers don't ever accidentally end up on a PDP for the contingency fee, set up a redirect for the product:
