Overview
In this guide, we'll show you how to add 'Authority to Leave' and 'Signature Required' checkboxes to your Shopify checkout. This ensures that when you import orders into Starshipit, these delivery preferences will be automatically selected. Follow these steps to streamline your shipping process and enhance your customers' delivery experience.
Modify the shopping cart page in Shopify
To add a checkbox to select 'Authority To Leave'/'Signature Required in your Shopify shopping cart, you first need to create a checkbox that your customer can select.
Shopify plan requirements
Per Shopifys eligibility requirements you must be on an a Shopify plus plan.
We have introduced a new 'UI Extension' called 'Checkout Delivery Options' on our Shopify app. This extension allows you to customise the checkout process by adding specific delivery options directly to the checkout page.
-
Ensure you have our Shopify app and then navigate to Settings > Checkout > Customise.
-
Scroll down and click on 'Add app block' at the bottom of the page.
-
In the app block selection, you should see 'checkout-delivery-options'. Select it.
-
The 'Checkout Delivery Options' extension has a settings page where you can choose to show any of the following options:
-
Authority to Leave (ATL)
- Signature Required
-
-
You can rename these settings to anything you like. Rest assured, they will still send the correct attributes to Starshipit upon order import.
Shopify deprecation
This method has since been deprecated by Shopify. If you were previously using this method, we recommend migrating to checkout extensibility.
Edit the Theme Code of Shopify and copy the custom code from Starshipit.
To learn how to edit the Theme Code, refer to the section "Add a form field to your theme code" of this article or you can follow the following steps.
- On the Shopify admin page, go to Online Store > Themes.
- Locate the theme you want to edit, and then click Actions > Edit code.
- In the Sections area, click on cart-template.liquid. If your theme doesn't have a cart-template.liquid, then, in the Templates directory, click on cart.liquid.
- Search for the last subtotal reference in the file, and then locate the closing tag.
- On a new line right below the closing tag, paste the code below. You may need to experiment with putting the code in different places to ensure the field appears correctly on your cart page.
<p class="cart-attribute__field">
<input type="hidden" name="attributes[Authority To Leave]" value="No">
<input type="checkbox" name="attributes[Authority To Leave]" value="Yes"{% if cart.attributes["Authority To Leave"] == "Yes" %} checked{% endif %}>
<label>Authority To Leave</label>
</p>
This is what it should look like when the code has been pasted:
You can modify the style of the checkbox, however, the name must be Authority To Leave. Otherwise, the information won't be imported into Starshipit.How this appears in Shopify
After you have added the Authority To Leave checkbox, you should see it on your shopping cart page and the order details page.
How this appears in Starshipit
After you have added the checkbox to your Shopify shopping cart, your customer can select it during the checkout process. When orders are imported from Shopify to Starshipit, the option will be automatically selected in Starshipit.