# Create Rule

**Create Rule to Manage Delivery by PIN Codes**

Easily control where your products can be delivered by creating rules based on PIN codes. Set estimated delivery times, return and exchange availability, and apply rules to single PIN codes, ranges, or bulk CSV uploads. Prioritize rules to ensure the most important settings are applied first, and choose whether they apply to all products, specific products, or specific collections.

<mark style="color:blue;">**Step #1**</mark> &#x20;

**Create a Rule**\
Go to your Shopify store backend:\
**Apps ➤ ZOX Zipcode Check ➤ Create Rule**

* Enter a **name** for your rule.
* Set the **status** (Active/Inactive).

<figure><img src="/files/QzwS0niOznwoDWVNJuP8" alt=""><figcaption></figcaption></figure>

#### <mark style="color:blue;">Step #2</mark>

**Add PIN Codes**\
You can add PIN codes in three ways:

1. **Single PIN Code** – Enter a specific PIN code (e.g., 314005) and set **estimated delivery days**, **return**, and **exchange availability**.
2. **PIN Code Range** – Specify a range (e.g., 314001 to 314005) to apply the rule to multiple PIN codes at once.
3. **CSV Upload** – Upload a CSV file containing multiple PIN codes for bulk import.

<figure><img src="/files/3ZzStgdOsdYfH1QR1doO" alt=""><figcaption></figcaption></figure>

#### <mark style="color:blue;">Step #3</mark>

* Choose whether delivery should be **Available** or **Not Available** for the selected PIN codes.
* Assign a **priority** to this rule relative to your other rules.

<figure><img src="/files/W80CkXfSuYqApI8e6h2F" alt=""><figcaption></figcaption></figure>

<mark style="color:blue;">**Step #4**</mark>

**Select Products or Collections**\
Choose where this rule should apply:

* **All Products** – Applies to every product in your store.
* **Specific Products** – Apply the rule to selected products.
* **Specific Collections** – Apply the rule to entire collections.

<figure><img src="/files/dr4W3cE8gvOKi7ItIeQe" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/DqWr9xjedpesdzB8HYYf" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/vHyFsYiCnXGxynxgmLxI" alt=""><figcaption></figcaption></figure>

* You can select an option as to which you want to apply the deliveries according to the pincodes - **products** or **collections** as per your choice.

<mark style="color:blue;">**Step #5**</mark>&#x20;

**Save and Manage Rules**\
Once created, the rule is applied automatically based on its priority. You can manage, edit, or delete rules anytime to keep delivery availability up to date.

For example, if you select a **specific product** like *Arrow Shirt*, the rule will appear on the frontend like this. Enter a PIN code to instantly see whether delivery is available for that product.

<figure><img src="/files/Y6R2JKk529ryeiHR2m4H" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/VK5dbWemWYhwgSyzoNdj" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/mXkWfmCKh7qGS2nx83Gg" alt=""><figcaption></figcaption></figure>

**Important:** Go to **Settings** and turn this option on to ensure customers cannot checkout if an incorrect PIN code is entered.

<figure><img src="/files/AnFifSHYgGbCuOyQbEyf" alt=""><figcaption></figcaption></figure>

#### Export All Pincodes

You can now easily export all added pincodes from the app in just one click.

**How it works:**

* Navigate to the Create rule section in the app
* Click on the **Export** button
* All configured pincodes will be downloaded in a file for your reference

<figure><img src="/files/X5gHPAPPWYTph991Zl3f" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://magecomp.gitbook.io/shopify/apps/zox-zipcode-check/create-rule.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
