> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.webflow.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.webflow.com/_mcp/server.

# Update Order

PATCH https://api.webflow.com/v2/sites/{site_id}/orders/{order_id}
Content-Type: application/json

This API lets you update the fields, `comment`, `shippingProvider`,
and/or `shippingTracking` for a given order. All three fields can be
updated simultaneously or independently.

Required scope | `ecommerce:write`


Reference: https://developers.webflow.com/data/reference/ecommerce/orders/update

## Authentication

- `Authorization` header (bearer token, required)

## Request

### Path parameters

- `site_id` (string, required) — Unique identifier for a Site
- `order_id` (string, required) — Unique identifier for an Order

### Body (application/json)

- `comment` (string, optional) — Arbitrary data for your records
- `shippingProvider` (string, optional) — Company or method used to ship order
- `shippingTracking` (string, optional) — Tracking number for order shipment
- `shippingTrackingURL` (string, optional) — URL to track order shipment

## Response

### 200

Request was successful

- `orderId` (string, optional) — The order ID. Will usually be 6 hex characters, but can also be 9 hex characters if the site has a very large number of Orders. Randomly assigned.
- `status` (enum, optional) — The status of the Order
  - Allowed values: `pending`, `unfulfilled`, `fulfilled`, `disputed`, `dispute-lost`, `refunded`
- `comment` (string, optional) — A comment string for this Order, which is editable by API user (not used by Webflow).
- `orderComment` (string, optional) — A comment that the customer left when making their Order
- `acceptedOn` (string, optional, nullable) — The ISO8601 timestamp that an Order was placed.
- `fulfilledOn` (string, optional, nullable) — When an Order is marked as 'fulfilled', this field represents the timestamp of the fulfillment in ISO8601 format. Otherwise, it is null.
- `refundedOn` (string, optional, nullable) — When an Order is marked as 'refunded', this field represents the timestamp of the fulfillment in ISO8601 format. Otherwise, it is null.
- `disputedOn` (string, optional, nullable) — When an Order is marked as 'disputed', this field represents the timestamp of the fulfillment in ISO8601 format. Otherwise, it is null.
- `disputeUpdatedOn` (string, optional, nullable) — If an Order has been disputed by the customer, this key will be set to the ISO8601 timestamp of the last update received. If the Order is not disputed, the key will be null.
- `disputeLastStatus` (enum, optional, nullable) — If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status).
  - Allowed values: `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `charge_refunded`, `won`, `lost`
- `customerPaid` (object, optional) — The total paid by the customer
  - `unit` (string, optional) — The three-letter ISO currency code
  - `value` (string, optional) — The numeric value in the base unit of the currency
  - `string` (string, optional) — The user-facing string representation of the amount
- `netAmount` (object, optional) — The net amount after application fees
  - `unit` (string, optional) — The three-letter ISO currency code
  - `value` (string, optional) — The numeric value in the base unit of the currency
  - `string` (string, optional) — The user-facing string representation of the amount
- `applicationFee` (object, optional) — The application fee assessed by the platform
  - `unit` (string, optional) — The three-letter ISO currency code
  - `value` (string, optional) — The numeric value in the base unit of the currency
  - `string` (string, optional) — The user-facing string representation of the amount
- `allAddresses` (list of object, optional) — All addresses provided by the customer during the ordering flow.
  - `type` (enum, optional) — The type of the order address (billing or shipping)
    - Allowed values: `shipping`, `billing`
  - `japanType` (enum, optional, nullable) — Represents a Japan-only address format. This field will only appear on orders placed from Japan.
    - Allowed values: `kana`, `kanji`
  - `addressee` (string, optional) — Display name on the address
  - `line1` (string, optional) — The first line of the address
  - `line2` (string, optional) — The second line of the address
  - `city` (string, optional) — The city of the address.
  - `state` (string, optional) — The state or province of the address
  - `country` (string, optional) — The country of the address
  - `postalCode` (string, optional) — The postal code of the address
- `shippingAddress` (object, optional) — The shipping address
  - `type` (enum, optional) — The type of the order address (billing or shipping)
    - Allowed values: `shipping`, `billing`
  - `japanType` (enum, optional, nullable) — Represents a Japan-only address format. This field will only appear on orders placed from Japan.
    - Allowed values: `kana`, `kanji`
  - `addressee` (string, optional) — Display name on the address
  - `line1` (string, optional) — The first line of the address
  - `line2` (string, optional) — The second line of the address
  - `city` (string, optional) — The city of the address.
  - `state` (string, optional) — The state or province of the address
  - `country` (string, optional) — The country of the address
  - `postalCode` (string, optional) — The postal code of the address
- `billingAddress` (object, optional) — The billing address
  - `type` (enum, optional) — The type of the order address (billing or shipping)
    - Allowed values: `shipping`, `billing`
  - `japanType` (enum, optional, nullable) — Represents a Japan-only address format. This field will only appear on orders placed from Japan.
    - Allowed values: `kana`, `kanji`
  - `addressee` (string, optional) — Display name on the address
  - `line1` (string, optional) — The first line of the address
  - `line2` (string, optional) — The second line of the address
  - `city` (string, optional) — The city of the address.
  - `state` (string, optional) — The state or province of the address
  - `country` (string, optional) — The country of the address
  - `postalCode` (string, optional) — The postal code of the address
- `shippingProvider` (string, optional, nullable) — A string editable by the API user to note the shipping provider used (not used by Webflow).
- `shippingTracking` (string, optional, nullable) — A string editable by the API user to note the shipping tracking number for the order (not used by Webflow).
- `shippingTrackingURL` (string, optional, nullable)
- `customerInfo` (object, optional) — An object with the keys `fullName` and `email`.
  - `fullName` (string, optional) — The full name of the Customer
  - `email` (string, optional) — The Customer's email address
- `purchasedItems` (list of object, optional) — An array of all things that the Customer purchased.
  - `count` (double, optional) — Number of Item purchased.
  - `rowTotal` (object, optional) — The total for the row
    - `unit` (string, optional) — The three-letter ISO currency code
    - `value` (string, optional) — The numeric value in the base unit of the currency
    - `string` (string, optional) — The user-facing string representation of the amount
  - `productId` (string, optional) — The unique identifier for the Product
  - `productName` (string, optional) — User-facing name of the Product
  - `productSlug` (string, optional) — Slug for the Product
  - `variantId` (string, optional) — Identifier for the Product Variant (SKU)
  - `variantName` (string, optional) — User-facing name of the Product Variant (SKU)
  - `variantSlug` (string, optional) — Slug for the Product Variant (SKU)
  - `variantSKU` (string, optional) — The user-defined custom SKU of the Product Variant (SKU)
  - `variantImage` (object, optional)
    - `url` (string, optional) — The hosted location for the Variant's image
    - `file` (object, optional)
      - `size` (double, optional) — The image size in bytes
      - `originalFileName` (string, optional) — the original name of the image
      - `createdOn` (string, optional) — The creation timestamp of the image
      - `contentType` (string, optional) — The MIME type of the image
      - `width` (integer, optional) — The image width in pixels
      - `height` (integer, optional) — The image height in pixels
      - `variants` (list of object, optional) — Variants of the supplied image
        - `url` (string, optional) — The hosted location for the Variant's image
        - `originalFileName` (string, optional)
        - `size` (double, optional) — The image size in bytes
        - `width` (integer, optional) — The image width in pixels
        - `height` (integer, optional) — The image height in pixels
  - `variantPrice` (object, optional) — The price corresponding to the variant
    - `unit` (string, optional) — The three-letter ISO currency code
    - `value` (string, optional) — The numeric value in the base unit of the currency
    - `string` (string, optional) — The user-facing string representation of the amount
  - `weight` (double, optional, nullable) — The physical weight of the variant if provided, or null
  - `width` (double, optional, nullable) — The physical width of the variant if provided, or null
  - `height` (double, optional, nullable) — The physical height of the variant if provided, or null
  - `length` (double, optional, nullable) — The physical length of the variant if provided, or null
- `purchasedItemsCount` (double, optional) — The sum of all 'count' fields in 'purchasedItems'.
- `stripeDetails` (object, optional) — An object with various Stripe IDs, useful for linking into the stripe dashboard.
  - `subscriptionId` (string, optional, nullable) — Stripe-generated identifier for the Subscription
  - `paymentMethod` (string, optional, nullable) — Stripe-generated identifier for the PaymentMethod used
  - `paymentIntentId` (string, optional, nullable) — Stripe-generated identifier for the PaymentIntent, or null
  - `customerId` (string, optional, nullable) — Stripe-generated customer identifier, or null
  - `chargeId` (string, optional, nullable) — Stripe-generated charge identifier, or null
  - `disputeId` (string, optional, nullable) — Stripe-generated dispute identifier, or null
  - `refundId` (string, optional, nullable) — Stripe-generated refund identifier, or null
  - `refundReason` (string, optional, nullable) — Stripe-generated refund reason, or null
- `stripeCard` (object, optional) — Details on the card used to fulfill this order, if this order was finalized with Stripe.
  - `last4` (string, optional) — The last 4 digits on the card as a string
  - `brand` (enum, optional) — The card's brand (ie. credit card network)
    - Allowed values: `Visa`, `American Express`, `MasterCard`, `Discover`, `JCB`, `Diners Club`, `Unknown`
  - `ownerName` (string, optional) — The name on the card.
  - `expires` (object, optional) — The card's expiration date.
    - `year` (double, optional) — Year that the card expires
    - `month` (double, optional) — Month that the card expires
- `paypalDetails` (object, optional)
  - `orderId` (string, optional) — PayPal order identifier
  - `payerId` (string, optional) — PayPal payer identifier
  - `captureId` (string, optional) — PayPal capture identifier
  - `refundId` (string, optional) — PayPal refund identifier
  - `refundReason` (string, optional) — PayPal-issued reason for the refund
  - `disputeId` (string, optional) — PayPal dispute identifier
- `customData` (list of object, optional) — An array of additional inputs for custom order data gathering. Each object in the array represents an input with a name, and a textInput, textArea, or checkbox value.
- `metadata` (object, optional)
  - `isBuyNow` (boolean, optional)
- `isCustomerDeleted` (boolean, optional) — A boolean indicating whether the customer has been deleted from the site.
- `isShippingRequired` (boolean, optional) — A boolean indicating whether the order contains one or more purchased items that require shipping.
- `hasDownloads` (boolean, optional) — A boolean indicating whether the order contains one or more purchased items that are downloadable.
- `paymentProcessor` (string, optional) — A string indicating the payment processor used for this order.
- `totals` (object, optional) — An object describing various pricing totals
  - `subtotal` (object, optional) — The subtotal price
    - `unit` (string, optional) — The three-letter ISO currency code
    - `value` (string, optional) — The numeric value in the base unit of the currency
    - `string` (string, optional) — The user-facing string representation of the amount
  - `extras` (list of object, optional) — An array of extra items, includes discounts, shipping, and taxes.
    - `type` (enum, optional) — The type of extra item this is.
      - Allowed values: `discount`, `discount-shipping`, `shipping`, `tax`
    - `name` (string, optional) — A human-readable (but English) name for this extra charge.
    - `description` (string, optional) — A human-readable (but English) description of this extra charge.
    - `price` (object, optional) — The price for the item
      - `unit` (string, optional) — The three-letter ISO currency code
      - `value` (string, optional) — The numeric value in the base unit of the currency
      - `string` (string, optional) — The user-facing string representation of the amount
  - `total` (object, optional) — The total price
    - `unit` (string, optional) — The three-letter ISO currency code
    - `value` (string, optional) — The numeric value in the base unit of the currency
    - `string` (string, optional) — The user-facing string representation of the amount
- `downloadFiles` (list of object, optional, default: []) — An array of downloadable file objects.
  - `id` (string, optional) — The unique identifier for the downloadable file
  - `name` (string, optional) — The user-facing name for the downloadable file
  - `url` (string, optional) — The hosted location for the downloadable file

## Examples

**Request**

```json
{}
```

**Response**

```json
{
  "orderId": "fc7-128",
  "status": "refunded",
  "comment": "Customer requested gift wrapping and a personalized note saying: Happy Birthday, Ford! 🎉 Please ensure the item is packed with extra bubble wrap for safe transit.",
  "orderComment": "Please gift wrap with a personal note saying \"Happy Birthday, Ford! 🎉",
  "acceptedOn": "2024-03-29T21:29:21.555Z",
  "fulfilledOn": "2024-03-29T21:29:21.555Z",
  "refundedOn": "2024-04-08T18:25:04.238Z",
  "disputedOn": "2024-03-29T21:29:21.555Z",
  "disputeUpdatedOn": "2024-03-29T21:29:21.555Z",
  "disputeLastStatus": "charge_refunded",
  "customerPaid": {
    "unit": "USD",
    "value": "11873",
    "string": "$ 118.73 USD"
  },
  "netAmount": {
    "unit": "USD",
    "value": "11262",
    "string": "$ 112.62 USD"
  },
  "applicationFee": {
    "unit": "USD",
    "value": "237",
    "string": "$ 2.37 USD"
  },
  "allAddresses": [
    {
      "type": "billing",
      "addressee": "Arthur Dent",
      "line1": "20 W 34th St",
      "line2": "Empire State Building",
      "city": "New York",
      "state": "New York",
      "country": "US",
      "postalCode": "10118"
    },
    {
      "type": "shipping",
      "addressee": "Arthur Dent",
      "line1": "20 W 34th St",
      "line2": "Empire State Building",
      "city": "New York",
      "state": "New York",
      "country": "US",
      "postalCode": "10118"
    }
  ],
  "shippingAddress": {
    "type": "shipping",
    "japanType": "kanji",
    "addressee": "Arthur Dent",
    "line1": "20 W 34th St",
    "line2": "Empire State Building",
    "city": "New York",
    "state": "New York",
    "country": "US",
    "postalCode": "10118"
  },
  "billingAddress": {
    "type": "billing",
    "addressee": "Arthur Dent",
    "line1": "20 W 34th St",
    "line2": "Empire State Building",
    "city": "New York",
    "state": "New York",
    "country": "US",
    "postalCode": "10118"
  },
  "shippingProvider": "Shipping Company, Co.",
  "shippingTracking": "tr00000000001",
  "shippingTrackingURL": "https://www.shippingcompany.com/tracking/tr00000000001",
  "customerInfo": {
    "fullName": "Arthur Dent",
    "email": "arthur.dent@example.com"
  },
  "purchasedItems": [
    {
      "count": 1,
      "rowTotal": {
        "unit": "USD",
        "value": "5561",
        "string": "$ 55.61 USD"
      },
      "productId": "66072fb61b89448912e26791",
      "productName": "Luxurious Fresh Ball",
      "productSlug": "luxurious-fresh-ball",
      "variantId": "66072fb71b89448912e2683f",
      "variantName": "Luxurious Fresh Ball Generic: Bronze, Practical: Plastic",
      "variantSlug": "luxurious-fresh-ball-generic-bronze-practical-plastic",
      "variantSKU": "luxurious-fresh-ball-generic-bronze-practical-plastic",
      "variantImage": {
        "url": "https://dev-assets.website-files.com/66072f39417a2a35b2589cc7/66072fb51b89448912e2672c_image14.jpeg"
      },
      "variantPrice": {
        "unit": "USD",
        "value": "5561",
        "string": "$ 55.61 USD"
      },
      "weight": 11,
      "width": 82,
      "height": 70,
      "length": 9
    },
    {
      "count": 1,
      "rowTotal": {
        "unit": "USD",
        "value": "5344",
        "string": "$ 53.44 USD"
      },
      "productId": "66072fb61b89448912e26799",
      "productName": "Recycled Steel Gloves",
      "productSlug": "recycled-steel-gloves",
      "variantId": "66072fb91b89448912e26ab9",
      "variantName": "Recycled Steel Gloves Electronic: Granite, Handcrafted: grey",
      "variantSlug": "recycled-steel-gloves-electronic-granite-handcrafted-grey",
      "variantSKU": "recycled-steel-gloves-electronic-granite-handcrafted-grey",
      "variantImage": {
        "url": "https://dev-assets.website-files.com/66072f39417a2a35b2589cc7/66072fb51b89448912e2671e_image2.jpeg"
      },
      "variantPrice": {
        "unit": "USD",
        "value": "5344",
        "string": "$ 53.44 USD"
      },
      "weight": 38,
      "width": 76,
      "height": 85,
      "length": 40
    }
  ],
  "purchasedItemsCount": 2,
  "stripeDetails": {
    "subscriptionId": null,
    "paymentMethod": "pm_1OzmzBJYFi4lcbXWHKNdXU7j",
    "paymentIntentId": "pi_3OzmzDJYFi4lcbXW1hTBW6ft",
    "customerId": "cus_PpRsNHwWdUoRKR",
    "chargeId": "ch_3OzmzDJYFi4lcbXW1ndkkrH2",
    "disputeId": null,
    "refundId": "re_3OzmzDJYFi4lcbXW1kFAmlBk",
    "refundReason": "fraudulent"
  },
  "stripeCard": {
    "last4": "4242",
    "brand": "Visa",
    "ownerName": "Arthur Dent",
    "expires": {
      "year": 2024,
      "month": 4
    }
  },
  "customData": [
    {}
  ],
  "metadata": {
    "isBuyNow": false,
    "hasDownloads": false,
    "paymentProcessor": "stripe"
  },
  "isCustomerDeleted": false,
  "isShippingRequired": true,
  "totals": {
    "subtotal": {
      "unit": "USD",
      "value": "10905",
      "string": "$ 109.05 USD"
    },
    "extras": [
      {
        "type": "tax",
        "name": "State Taxes",
        "description": "NY Taxes (4.00%)",
        "price": {
          "unit": "USD",
          "value": "436",
          "string": "$ 4.36 USD"
        }
      },
      {
        "type": "tax",
        "name": "City Taxes",
        "description": "NEW YORK Taxes (4.88%)",
        "price": {
          "unit": "USD",
          "value": "532",
          "string": "$ 5.32 USD"
        }
      },
      {
        "type": "shipping",
        "name": "Flat",
        "description": "",
        "price": {
          "unit": "USD",
          "value": "0",
          "string": "$ 0.00 USD"
        }
      }
    ],
    "total": {
      "unit": "USD",
      "value": "11873",
      "string": "$ 118.73 USD"
    }
  },
  "downloadFiles": [
    {
      "id": "5e9a5eba75e0ac242e1b6f64",
      "name": "New product guide",
      "url": "https://webflow.com/dashboard/download-digital-product?payload=5d93ba5e38c6b0160ab711d3;e7634a;5eb1aac72912ec06f561278c;5e9a5eba75e0ac242e1b6f63:ka2nehxy:4a1ee0a632feaab94294350087215ed89533f2f530903e3b933b638940e921aa"
    }
  ]
}
```

**SDK Code**

```typescript
import { WebflowClient } from "webflow-api";

async function main() {
    const client = new WebflowClient({
        accessToken: "YOUR_TOKEN_HERE",
    });
    await client.orders.update("580e63e98c9a982ac9b8b741", "5e8518516e147040726cc415", {});
}
main();

```

```python
from webflow import Webflow

client = Webflow(
    access_token="YOUR_TOKEN_HERE",
)

client.orders.update(
    site_id="580e63e98c9a982ac9b8b741",
    order_id="5e8518516e147040726cc415",
)

```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.patch("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('PATCH', 'https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415', [
  'body' => '{}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/orders/5e8518516e147040726cc415")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```