wow/codeable-etsy-product

A Custom Etsy Product Type for WooCommerce

Installs: 6

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 1

Type:woocommerce-plugin

pkg:composer/wow/codeable-etsy-product

dev-master 2025-12-30 16:19 UTC

This package is not auto-updated.

Last update: 2026-01-04 02:53:42 UTC


README

A WooCommerce plugin that creates a custom product type for displaying Etsy shop listings directly in your WooCommerce store. Products automatically sync their title, description, images, and pricing from Etsy.

Features

  • New Product Type: Adds "Etsy Product" to WooCommerce's product type selector
  • Automatic Data Sync: Pulls product title, description, images, and pricing directly from Etsy
  • Configurable Caching: Cache Etsy data for optimal performance (1 minute to 1 day)
  • Responsive Images: Multiple image sizes for optimal display across devices
  • Direct Etsy Linking: "View On Etsy" button directs customers to purchase on Etsy
  • Internationalization: Translation-ready with Spanish (es_ES) included

Requirements

Installation

Via Composer

composer require wow/woo-etsy-product

Manual Installation

  1. Download or clone this repository
  2. Upload the woo-etsy-product folder to /wp-content/plugins/
  3. Activate the plugin through the Plugins menu in WordPress
  4. Ensure WooCommerce is installed and activated

Plugin Screen

Configuration

Global Settings

  1. Navigate to WooCommerce > Settings > Products
  2. Click on the Etsy Product Settings tab
  3. Configure:
    • Etsy API Key: Your Etsy API key for authentication
    • Etsy Shop Name: Your Etsy shop name (e.g., MyEtsyShop)

Settings

Creating an Etsy Product

  1. Go to Products > Add New
  2. In the Product data section, select Etsy Product from the dropdown

Products Screen

  1. Click on the Etsy Product tab that appears
  2. Pick an Etsy Item: Select your Etsy listing from the dropdown (populated from your shop)
  3. Cache for faster displaying: Choose a cache duration for performance optimization

Etsy Product Options

  1. Click Publish or Update - your product setup is complete!

The product title, description, images, and price will automatically be pulled from Etsy.

Results

Your Etsy products will appear in your admin list view with the title, price, and picture:

Admin list view

On your website, products appear alongside other products in the grid view:

Website grid view

Full product details are available on the product page:

Product details

Caching Options

Option Duration Use Case
Don't cache Real-time Testing, frequently updated listings
1 minute 60 seconds High-traffic sites with frequent updates
5 minutes 5 minutes Balanced freshness and performance
30 minutes 30 minutes Recommended for most sites
1 hour 60 minutes Stable listings, reduced API calls
1 day 24 hours Static listings, maximum performance

How It Works

Architecture

The plugin consists of three main components:

  1. EtsyAPI (app/etsy/EtsyAPI.php): Static utility class for making authenticated requests to the Etsy API v2 with built-in caching via WordPress transients.

  2. EtsyProductAdmin (app/admin/EtsyProductAdmin.php): Handles admin-side functionality including settings pages and product configuration UI.

  3. EtsyProduct (app/frontend/EtsyProduct.php): Extends WC_Product to intercept WordPress filters and inject Etsy data dynamically.

Data Flow

WooCommerce loads product
    ↓
WC_Product_Etsy instantiated
    ↓
Etsy listing ID retrieved from post meta
    ↓
Etsy API called (with caching)
    ↓
WordPress filters hijacked to inject Etsy data
    ↓
Product displayed with Etsy data

Filter Hijacking

The plugin uses WordPress filters to seamlessly inject Etsy data:

  • the_title - Returns Etsy listing title
  • the_content - Returns Etsy listing description
  • get_post_metadata - Intercepts price and thumbnail ID requests
  • wp_get_attachment_image_src - Returns Etsy image URLs
  • wp_get_attachment_image_attributes - Provides responsive image srcsets

File Structure

woo-etsy-product/
├── woo-etsy-product.php         # Main plugin file
├── composer.json                 # Composer configuration
├── README.md                     # This file
├── UNLICENSE                     # License file
├── app/
│   ├── WC_Product_Etsy.php      # WooCommerce product type wrapper
│   ├── admin/
│   │   ├── EtsyProductAdmin.php # Admin functionality
│   │   └── views/
│   │       └── etsy-product-tab.php
│   ├── etsy/
│   │   └── EtsyAPI.php          # Etsy API wrapper
│   └── frontend/
│       ├── EtsyProduct.php      # Frontend product class
│       └── views/
│           └── add-to-cart-btn.php
├── languages/                    # Translation files
│   ├── woo-etsy-product.pot
│   ├── woo-etsy-product-es_ES.po
│   └── woo-etsy-product-es_ES.mo
└── vendor/                       # Composer dependencies

Localization

Translations are currently available in Spanish. The /languages directory contains the .pot file for further translating.

Spanish

Frequently Asked Questions

Can customers purchase directly through WooCommerce?

No. This plugin displays Etsy products in your WooCommerce catalog, but the "Add to Cart" button is replaced with a "View On Etsy" button that redirects customers to complete their purchase on Etsy.

How often does the product data update?

Data freshness depends on your cache settings. With no caching, data is fetched in real-time. With maximum caching (1 day), data updates once per day.

Can I display products from multiple Etsy shops?

Currently, the plugin supports one Etsy shop per WordPress installation. All Etsy products pull from the configured shop.

What happens if my Etsy API key expires?

Products will fail to display their Etsy data. Ensure your API key remains valid and update it in WooCommerce settings if needed.

Does this affect my regular WooCommerce products?

No. The plugin only affects products with the "Etsy Product" type. All other product types work normally.

Changelog

0.1

  • Initial release
  • Basic Etsy product integration
  • Configurable caching
  • Spanish translations

License

This project is released under the Unlicense, placing it in the public domain.

Author

Jake Chapa

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request