Zid Docs
  1. MCP
Zid Docs
  • Merchant API
    • Start Here πŸš€
    • Overview to Zid Apps
    • Authorization
    • Responses
    • Webhooks
    • Rate Limiting
    • APIs
      • Orders
        • Update Order by ID
        • Get Order Credit Notes
        • Get Order by ID
        • List of Orders
        • Order Notes
      • Reverse Orders
        • Reverse Order Reasons
        • Create Reverse Orders
        • Create Reverse Orders Waybill
        • Add Reverse Order Reasons
      • Carts
        • Get Abandoned Cart Details
        • List Abandoned Carts
      • Products
        • Managing Products
          • Get a Product by ID
          • Retrieve a list of products
          • Create a new product
          • Update an existing product.
          • Bulk update of products using their IDs or SKUs
          • Delete a product.
          • Product Setting
          • List Product Reviews
        • Digital Vouchers
          • Product Vouchers
          • Order Voucher
          • Add Product Voucher
          • Import Vouchers
          • Export Vouchers
          • Update Product Voucher
          • Remove Product Voucher
        • Product Categories
          • Get Single Category Details
          • Get all categories
          • Create Store Category
          • Update a Store Category
          • Add a product to a certain category
          • Publish/Unpublish a Category
          • Detach Category from All Products
          • Remove Category from Product
        • Product Badge
          • Product Badge
        • Product Attributes
          • Get Product Attributes
          • Get Product Attributes
          • Retrieve a product attribute
          • Add a New Product Attribute
          • Add a New Product Attribute
          • Update a product attribute
          • Delete a product attribute
        • Product Attribute Presets
          • Get attribute presets
          • Create Attribute Preset
          • Update Attribute Preset
          • Delete an attribute preset
        • Product Customizations
          • Add Product Variants
          • Insert Custom Options to a Product
          • Insert Custom User-Input Fields to a Product
        • Product Manual Sorting
          • Set Custom Product Order
          • Reset the manual sorting of all products
        • Product Images
          • Get List of images of a product.
          • Add an image to a product
          • Update a product Image Order
          • Delete a product image
        • Product Notifications
          • Availability Notification Stats
          • Availability Notifications Settings
          • List Availability Notifications
          • Add Availability Notification
          • Save Availability Notifications Settings
          • Manually Send Availability Notification Email
          • Export Availability Notifications
        • Product Import
          • Email All Products to Store Owner
          • Import Products via CSV or xlsx File
        • Product Stock (Multi-Inventory)
          • Get Product Stock by ID
          • List Product Stocks
          • Add Product Stock
          • Update Single Product Stock
          • Bulk Update Product Stocks
        • Product Questions & Answers
          • Get Question
          • Get Answer
          • Get All Questions
          • List Question Answers
          • Create Question
          • Create Answer
          • Update Question
          • Update Answer
          • Delete Question
          • Delete Answer
        • Product Reviews
          • List Reviews
          • New Reviews Total
          • Change Review Status
          • Bulk Change all Review Statuses
          • Delete Review
          • Import Product Reviews
          • Reply to Review
          • Delete Reply
          • Update Reply to Review
        • Digital Products
          • Create Downloadable Product
          • Generate an Upload URL
          • Upload File to S3
          • Create Product Downloadables
          • Get Product Downloadables
          • Delete Product Downloadables
          • Get Store Downloadables
          • Create Store Downloadables
          • Delete Store Downloadables
      • Inventories
        • Get Store Location by ID
        • List Store Locations
        • Add a New Location
        • Update a Location by ID
        • Update Products Stock by Location ID
      • Shipping
        • List Store Delivery Options
        • Add Shipping Option
      • Marketing
        • Gift Cards
          • Get Store Settings
          • Add gift card to the cart
          • Update Store Settings
          • Upload gift card designs
          • Remove gift card from the cart
        • Coupons
          • Create a New Coupon
          • List Coupons
          • Get Coupon Details
          • Update Coupon
          • Delete Coupon
        • Bundle Offers
          • Retrieve all Bundle Offers
        • Loyalty Program
          • Customer Wallet
          • Customer Points
          • Loyalty Program Points per Order
          • Store Loyalty Status
          • Redemption Methods
          • Cashback Rules
          • Add Redemption to Cart
          • Remove Redemption from Cart
          • Info Page
          • Loyalty Program Activation
          • Loyalty Status
          • Set Points Expiration
          • Cashback Rule Method Update
          • Cashback Rule Method Update Status
          • Add Points Redemption Method
          • Update Points Redemption Method
          • Delete Points Redemption Method
          • Toggle Redemption Method Status
          • Show Loyalty Points Info for Specific Customer
          • List Data
          • Customer Points History
          • Info Page - Managers
          • Update Info Page
          • Adjust Customer Points
      • Customers
        • Customer Profile
        • List of Customers
        • Get Customer by ID
      • Store Settings
        • πŸ“„ User Roles and Permissions
        • Get Manager's Profile
        • Get VAT Settings
        • List of Payment Method
      • Countries and Cities
        • Retrieve Store Operating Countries
        • Retrieve Cities by Country ID
        • Countries List
      • Webhook
        • List of Webhooks
        • Create a Webhook
        • Delete a Webhook by OriginalId
        • Delete a Webhook by Subscriber
    • Store Events
      • Order
      • Product
      • Abandoned Cart
      • Customer
      • Product Category
  • Payment API
    • Merchant Activation
    • Submitting
    • Gateway Error Codes
    • Webhooks
      • Link Merchant Event
      • Payment Paid Event
      • Refund Event
    • Payment
      • Embedded Payment
      • Execute Payment Request
      • Get payment status
      • Direct Payment
    • ApplePay
      • ApplePay Checkout
      • On Payment Authorized
      • Register ApplePay Domain
      • On Providing Merchant Validation
    • Refund
      • Request Refund
  • Apps
    • Create your First App
    • Embedded Apps
    • App Scripts
    • App Events
    • App Subscription
      • Get Subscription Details
      • Update Usage-Based Charges
  • Themes
    • 🚨 Important Update: Zid Themes
    • Adding Video URL Feature to Third-Party Themes
    • Landing Page Development
    • Getting Started with Zid Themes
      • Introduction to Theme Development
      • Manage your Themes
      • Building Themes in Zid
      • Theme File Structure
      • Twig Syntax and Features
      • Zid Theme Packager
    • Templates
      • Layout
      • Home Page
      • Products
      • Cart
      • Store Language and Currency
    • Settings Schema
      • Text
      • Number
      • Text-Area
      • Select
      • Radio Buttons
      • Checkbox
      • Range
      • Color
      • Image
      • Product
      • Category
      • List
      • Fieldset
    • Code Snippets
      • Apple Pay Quick Checkout
      • Custom CSS Injection
      • Displaying the Store's Business Center Logo
      • Customizing Copyright Text
      • Store's Main Navigation Menu
      • Customer Wishlist
      • Store Social Media
      • Products
        • Products Badges
        • Product Ratings
        • Remaining Product Stock
        • Sold Items Count
        • Product Filtration by Attributes
        • Grouped Products
        • Product Questions & Answers
        • Product Restock Notfication
      • SEO
        • Images alt text
        • Themes SEO Marketing Tags
      • Marketing
        • Metafields
        • Gift Feature
        • Loyalty Program
    • Zid Themes Library: API Integration
      • Products
      • Product Categories
      • Cart
      • Blog
      • Customer
      • Store Settings
    • Data Reference
      • Locals
      • Store
      • Cart
      • Product
      • Products List
      • Category
      • Categories List
      • Session
      • FAQs
      • Customer
      • Blogs
      • Page
      • Main Menu
      • Main Navigation Menu
      • Request
      • Orders
      • Addresses
      • Store Payment Methods
      • Store Shipping Methods
      • Store Banks
      • Asset URL
      • Header Meta Tags
      • Loyalty pogram Wallet
    • Themes CLI
      • CLI Authentication
      • Theme Create
      • Theme Package
      • Theme Update
      • Themes List
      • Theme Preview
  • MCP
    • Orders
    • Orders 1
  1. MCP

Orders 1

This guide explains how to use the Zid MCP tools for managing orders, returns, and related data in your Zid store. Each tool is callable from your MCP environment and supports flexible filtering, localization, and integration into dashboards or workflows.

1. List Orders (mcp_Zid_ListOrders)#

Purpose:
Retrieve a paginated list of orders from your Zid store, with powerful filtering options.
Use Cases:
Display all recent orders in your admin dashboard.
Filter orders by status (e.g., only show "new" or "delivered" orders).
Search for orders by customer, date, or payment method.
How to Use:
Call this tool with optional parameters to filter and sort the results.
Parameters:
page (number): Page number for pagination (default: 1).
perPage (number): Number of orders per page (default: 10, max: 100).
orderStatus (string): Filter by order status (new, preparing, ready, indelivery, delivered, canceled).
paymentMethod (string): Filter by payment method (zid_cod, zid_bank_transfer, zid_cop, zid_credit_card).
customerId (number): Filter by customer ID.
dateFrom/dateTo (string): Filter by order creation date range (format: YYYY-MM-DD).
sortBy (string): Sort order (asc or desc).
searchTerm (string): Search by order number, customer name, etc.
language (string): Response language (en or ar).
Example Usage:
List all new orders:
mcp_Zid_ListOrders({ orderStatus: "new" })
List orders from a specific date:
mcp_Zid_ListOrders({ dateFrom: "2024-06-01" })

2. Get Order Details (mcp_Zid_GetOrderDetails)#

Purpose:
Fetch detailed information about a specific order, including items, customer info, shipping, and payment details.
Use Cases:
View all details for a selected order in your admin panel.
Display order summary to customer support agents.
How to Use:
Provide the orderId (number or string) to retrieve the order.
Parameters:
orderId (number or string): The unique ID of the order.
language (string): Response language (en or ar).
Example Usage:
Get details for order #12345:
mcp_Zid_GetOrderDetails({ orderId: 12345 })

3. Update Order Status (mcp_Zid_action_UpdateOrderStatus)#

Purpose:
Change the status of an order (e.g., mark as "preparing", "ready", "delivered", or "cancelled").
Use Cases:
Move an order to the next stage in your fulfillment workflow.
Cancel an order if requested by the customer.
How to Use:
Provide the orderId and the new orderStatus. Optionally, include tracking info.
Parameters:
orderId (number or string): The unique ID of the order.
orderStatus (string): New status (new, preparing, ready, indelivery, delivered, cancelled).
inventoryAddressId (string, optional): ID of the inventory location (for shipping).
trackingNumber (string, optional): Shipment tracking number.
trackingUrl (string, optional): URL for tracking the shipment.
waybillUrl (string, optional): URL to the waybill document.
language (string): Response language (en or ar).
Example Usage:
Mark order #12345 as delivered:
mcp_Zid_action_UpdateOrderStatus({ orderId: 12345, orderStatus: "delivered" })
Mark as in delivery with tracking:
mcp_Zid_action_UpdateOrderStatus({ orderId: 12345, orderStatus: "indelivery", trackingNumber: "TRACK123", trackingUrl: "https://track.com/TRACK123" })

4. Get Order Credit Notes (mcp_Zid_GetOrderCreditNotes)#

Purpose:
Retrieve all credit notes (refunds, adjustments) associated with a specific order.
Use Cases:
Display a list of refunds or adjustments for an order.
Audit order financials for discrepancies.
How to Use:
Provide the orderId.
Parameters:
orderId (number or string): The unique ID of the order.
language (string): Response language (en or ar).
Example Usage:
Get credit notes for order #12345:
mcp_Zid_GetOrderCreditNotes({ orderId: 12345 })

5. Get Order Vouchers (mcp_Zid_GetOrderVouchers)#

Purpose:
List all vouchers (e.g., gift cards, codes) associated with a specific order.
Use Cases:
Show which vouchers were purchased or used in an order.
Help customer support resolve voucher-related issues.
How to Use:
Provide the orderId. Supports pagination.
Parameters:
orderId (string): The unique ID of the order.
page (number): Page number (default: 1).
pageSize (number): Number per page (default: 15, max: 100).
language (string): Response language (en or ar).
Example Usage:
List vouchers for order #12345:
mcp_Zid_GetOrderVouchers({ orderId: "12345" })

6. Get Reverse Order Reasons (mcp_Zid_GetReverseOrderReasons)#

Purpose:
Retrieve a list of reasons that can be used when creating a reverse order (return or refund).
Use Cases:
Populate a dropdown for customers to select a return reason.
Analyze common reasons for returns.
How to Use:
No parameters required (optional language).
Parameters:
language (string): Response language (en or ar).
Example Usage:
Get all reverse order reasons:
mcp_Zid_GetReverseOrderReasons({})

7. Add Reverse Order Reason (mcp_Zid_action_AddReverseOrderReason)#

Purpose:
Add a new reason to the list of available reverse order (return/refund) reasons.
Use Cases:
Customize the list of return reasons for your store.
How to Use:
Provide the reason name.
Parameters:
name (string): The reason to add.
language (string): Response language (en or ar).
Example Usage:
Add a new reason:
mcp_Zid_action_AddReverseOrderReason({ name: "Wrong size" })

8. Create Reverse Order (mcp_Zid_action_CreateReverseOrder)#

Purpose:
Create a reverse order (return or refund) for an existing order.
Use Cases:
Allow customers or staff to initiate a return process.
Track returns and refunds in your system.
How to Use:
Provide order and consignee details, and the reason(s) for the reverse order.
Parameters:
orderId (number): The original order ID.
consigneeName (string): Name of the person receiving the return.
consigneeMobile (string): Mobile number of the consignee.
consigneeCityId (number): City ID for the consignee.
consigneeAddress1 (string): Address line 1.
consigneeAddress2 (string, optional): Address line 2.
inventoryLocationId (string, optional): Inventory location for the return.
reason (string[]): List of reasons for the return.
language (string): Response language (en or ar).
Example Usage:
Create a reverse order:
mcp_Zid_action_CreateReverseOrder({
  orderId: 12345,
  consigneeName: "John Doe",
  consigneeMobile: "5551234567",
  consigneeCityId: 1,
  consigneeAddress1: "123 Main St",
  reason: ["Wrong item sent"]
})

9. Create Reverse Order Waybill (mcp_Zid_action_CreateReverseOrderWaybill)#

Purpose:
Generate a shipping waybill for a reverse order (to facilitate the return shipment).
Use Cases:
Provide customers with a return shipping label.
Track the return shipment in your system.
How to Use:
Provide the orderId and optionally specify if it’s a standalone Zidship waybill.
Parameters:
orderId (number): The original order ID.
isStandaloneZidshipWaybill (boolean, optional): Whether to create a standalone Zidship waybill (default: true).
language (string): Response language (en or ar).
Example Usage:
Create a waybill for a reverse order:
mcp_Zid_action_CreateReverseOrderWaybill({ orderId: 12345 })

Summary Table#

Tool NamePurpose/Use CaseKey Parameters
List OrdersList/filter/search orderspage, perPage, orderStatus, etc.
Get Order DetailsFetch full details for a specific orderorderId
Update Order StatusChange the status of an orderorderId, orderStatus, tracking info
Get Order Credit NotesList credit notes (refunds/adjustments) for an orderorderId
Get Order VouchersList vouchers associated with an orderorderId, page, pageSize
Get Reverse Order ReasonsList possible reasons for returns(none required)
Add Reverse Order ReasonAdd a new return reasonname
Create Reverse OrderInitiate a return/refund processorderId, consignee info, reason
Create Reverse Order WaybillGenerate a return shipping labelorderId, isStandaloneZidshipWaybill

Modified atΒ 2025-07-23 14:06:50
Previous
Orders
Built with