• Skip to primary navigation
  • Skip to main content

WP Data Sync

The only data sync API for WordPress websites.

  • Products
  • Blog
    • Code Examples
  • Documentation
    • Getting Started
    • Actions
    • Filters
    • FAQ
    • Specifications
    • Change Log
  • Contact
  • Support
  • Checkout
    • Cart
  • Account

Developer Documentation

Filed Under: Getting Started

Order Mapping – Path

When mapping an order, we must define the path to create the data object to send an order to a remote API. We use a method named Dot Notation.

What is Dot Notation?

Dot Notation is one way to access a property of an object. To use dot notation, write the name of the object, followed by a dot (.), followed by the name of the property.

The WP Data Sync API extends Dot Notation with [i] to create the items for our request body.

Path Mapping

Path mapping is done by using the object keys. The correct format should be provided in your remote API documentation.

Since a single order can contain multiple items. There are 2 methods to map items for an order.

Path Mapping Methods

  1. Multiple Item Request
  2. Single Item Request

Multiple Item Request

A multiple item request sends all items in a single request.

Example: Multiple Item Request Object

{
    "Order": {
        "FullName": "Shipping Full Name",
        "Address": "123 E Main St",
        "City": "Scottsdale",
        "State": "AZ",
        "Zip": "85250",
        "Company": "WP Data Sync",
        "Items": [
            {
                "ProductName": "Product Name",
                "ProductID": 121,
                "Quantity": 1,
                "Price": "12.66",
                "ShippingMethod": "Standard Shipping"
            },
            {
                "ProductName": "Product Name 2",
                "ProductID": 1234,
                "Quantity": 1,
                "Price": "17.66",
                "ShippingMethod": "Standard Shipping"
            }
        ]
    }
}

Paths for example multiple item request object

  • Order.FullName
  • Order.Address
  • Order.City
  • Order.State
  • Order.Zip
  • Order.Company
  • Order.Items.[i].ProductName
  • Order.Items.[i].ProductID
  • Order.Items.[i].Quantity
  • Order.Items.[i].Price
  • Order.Items.[i].ShippingMethod

NOTE: The [i] notation is used to define an item object. This instructs the WPDS API to create an item object for each item in the order.

Single Item Request

A single item request sends one item in multiple requests.

Example: Single Item Request Object

Each of the 2 item objects will be sent in a separate request.

{
    "FullName": "Shipping Full Name",
    "Address": "123 E Main St",
    "City": "Scottsdale",
    "State": "AZ",
    "Zip": "85250",
    "Company": "WP Data Sync",
    "Item": {
        "productName": "Items - Product Name",
        "productID": 121,
        "quantity": 1,
        "price": "12.66",
        "shippingMethod": "Standard Shipping"
    }
},
{
    "FullName": "Shipping Full Name",
    "Address": "123 E Main St",
    "City": "Scottsdale",
    "State": "AZ",
    "Zip": "85250",
    "Company": "WP Data Sync",
    "Item": {
        "productName": "Items - Product Name 2",
        "productID": 1234,
        "quantity": 1,
        "price": "17.66",
        "shippingMethod": "Standard Shipping"
    }
}

Paths for example single item request object

  • [i].FullName
  • [i].Address
  • [i].City
  • [i].State
  • [i].Zip
  • [i].Company
  • [i].Item.ProductName
  • [i].Item.ProductID
  • [i].Item.Quantity
  • [i].Item.Price
  • [i].Item.ShippingMethod

Order Mapping UI

Create the order map paths in the easy to use order mapping UI. See the screenshot below for an example. Once your paths are saved. You can use the request test feature to check for the correct order object format.

Order Mapping UI

WP Dat Sync icon
Copyright © 2025 · WP Data Sync · Located in Scottsdale AZ

  • Developers
  • Data Access Request
  • Terms of Service
  • Privacy Policy
This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Cookie settingsACCEPT
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Non-necessary
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.
SAVE & ACCEPT