WC

WooCommerce API Setup Guide

How to get your Consumer Key, Consumer Secret, and Store URL

← Back to App

Contents

  1. Requirements
  2. Enable WooCommerce REST API
  3. Generate Consumer Key & Secret
  4. Find your Store URL
  5. Add Connection in EcomCentral
  6. Test the Connection
  7. Required API Permissions
  8. WooCommerce Order Statuses
  9. Troubleshooting

Requirements

  • WooCommerce 3.5 or later installed and active
  • WordPress admin access (Administrator role)
  • Store must be on HTTPS — the REST API requires SSL
  • Pretty Permalinks must be enabled (Settings → Permalinks → any option other than Plain)
⚠️ If your store uses plain ?p=123 URLs (plain permalinks), the REST API will not work. Go to Settings → Permalinks and choose Post name.

Step 1 — Enable the WooCommerce REST API

The REST API is enabled by default in WooCommerce 3.5+. To confirm it is on:

  1. Log in to your WordPress admin dashboard
  2. Go to WooCommerce → Settings
  3. Click the Advanced tab
  4. Click REST API in the sub-menu
  5. Confirm the page loads (it lists existing keys) — the API is active
ℹ️ If you don't see a REST API sub-menu under Advanced, your WooCommerce may be outdated. Update it to the latest version.

Step 2 — Generate Consumer Key & Secret

  1. In WordPress admin, go to WooCommerce → Settings → Advanced → REST API
  2. Click the Add Key button
  3. Fill in the form:
    • Description: e.g. EcomCentral Integration
    • User: Select an Administrator user
    • Permissions: Select Read/Write (required for updating orders and stock)
  4. Click Generate API Key
  5. Copy both keys immediately — the Consumer Secret is shown only once.
    ⚠️ The Consumer Secret is displayed only once after generation. Copy it before navigating away. If lost, you must delete the key and generate a new one.
WooCommerce → Settings → Advanced → REST API → Add Key Description: EcomCentral · User: admin · Permissions: Read/Write

You will see two values after generation:

FieldExample valueUsed as
Consumer Key ck_a1b2c3d4e5f6... EcomCentral → consumer_key
Consumer Secret cs_a1b2c3d4e5f6... EcomCentral → consumer_secret

Step 3 — Find your Store URL

Your Store URL is simply the base URL of your WordPress / WooCommerce site.

  • If your store is at https://myshop.com, use https://myshop.com
  • If installed in a subdirectory: https://myshop.com/store
  • Do not include /wp-json or /wc/v3 — EcomCentral appends the correct path automatically
You can verify the API is reachable by visiting: https://yourstore.com/wp-json/wc/v3/system_status in your browser — it should return JSON (you may be prompted for HTTP Basic credentials).

Step 4 — Add Connection in EcomCentral

  1. Open EcomCentral and click + Add Connection
  2. Select WooCommerce from the channel list
  3. Fill in the connection form:
    FieldValue to enter
    Connection NameA descriptive label, e.g. My Main Store
    EnvironmentProduction (or Staging if testing)
    store_urlYour store base URL, e.g. https://myshop.com
    consumer_keyThe ck_... value from Step 2
    consumer_secretThe cs_... value from Step 2
  4. Click Save Connection

Step 5 — Test the Connection

After saving, go to WooCommerce in the sidebar and click ⚡ Test next to your store. A successful response shows:

  • Store name
  • WooCommerce version
  • WordPress version
  • Store currency
If the test passes, you're ready. Use 📋 Orders to view and manage orders, and 📦 Stock to manage product inventory.

Required API Permissions

FeatureRequired Permission
View OrdersRead
View Products / Stock levelsRead
Update Order StatusWrite
Add Tracking to OrderWrite
Update Stock QuantityWrite
Test ConnectionRead
ℹ️ Always use Read/Write permission when generating the key in WooCommerce, so all EcomCentral features are available.

WooCommerce Order Statuses

StatusMeaningTypical next step
Pending Order placed, payment not yet received Wait for payment or cancel
Processing Payment received, order being fulfilled Pack and ship; add tracking
On Hold Awaiting action (e.g. bank transfer confirmation) Confirm payment, then process
Completed Order fully fulfilled and shipped No action needed
Cancelled Order cancelled by customer or store Issue refund if already charged
Refunded Order refunded (fully or partially)
Failed Payment failed or was declined Contact customer; cancel or retry

Troubleshooting

401 Unauthorized

The Consumer Key or Consumer Secret is incorrect. Double-check you copied them exactly (they're case-sensitive). Regenerate if needed.

404 Not Found on /wp-json/wc/v3

Permalinks are set to Plain. Go to Settings → Permalinks, choose any other option, and click Save.

SSL / cURL error

Your store must be served over HTTPS. Ensure your SSL certificate is valid. On localhost, disable CURLOPT_SSL_VERIFYPEER only for development.

403 Forbidden

The API key user does not have Administrator role, or a security plugin (Wordfence, Sucuri) is blocking the REST API. Check your security plugin's settings to whitelist /wp-json/.

Consumer Secret is lost / not visible

WooCommerce only shows the Consumer Secret once. Delete the key in WooCommerce → Settings → Advanced → REST API and generate a new one.

Orders endpoint returns empty array

The key may have Read-only permission. Regenerate with Read/Write. Also confirm there are orders in your store under WooCommerce → Orders.