WooCommerce MCP Server

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Integrations

  • Enables comprehensive management of WooCommerce stores, including products, orders, customers, shipping, taxes, discounts, and store configuration through the WooCommerce REST API.

  • Provides content management capabilities for WordPress sites, including creating, retrieving, updating, and deleting posts and managing post metadata independently of WooCommerce functionality.

WooCommerce MCP 서버

WooCommerce 통합을 위한 MCP(Model Context Protocol) 서버로, Windows, macOS, Linux와 호환됩니다.

개요

이 MCP 서버는 WordPress REST API를 통해 WooCommerce 스토어와 상호 작용할 수 있도록 지원합니다. JSON-RPC 2.0 프로토콜을 사용하여 제품, 주문, 고객, 배송, 세금, 할인 및 스토어 구성의 모든 측면을 관리할 수 있는 포괄적인 도구를 제공합니다.

설치

  1. 저장소를 복제합니다
  2. 종속성 설치:

지엑스피1

  1. 프로젝트를 빌드하세요:
npm run build

구성

자격 증명에 대한 환경 변수를 사용하여 MCP 설정 파일에 서버를 추가합니다.

{ "mcpServers": { "woocommerce": { "command": "node", "args": ["path/to/build/index.js"], "env": { "WORDPRESS_SITE_URL": "https://your-wordpress-site.com", "WOOCOMMERCE_CONSUMER_KEY": "your-woocommerce-consumer-key", "WOOCOMMERCE_CONSUMER_SECRET": "your-woocommerce-consumer-secret", "WORDPRESS_USERNAME": "your-wordpress-username", "WORDPRESS_PASSWORD": "your-wordpress-password" } } } }

환경 변수

WooCommerce API 액세스에 필요함:

  • WORDPRESS_SITE_URL : WordPress 사이트 URL(WooCommerce는 WordPress 플러그인입니다)
  • WOOCOMMERCE_CONSUMER_KEY : WooCommerce REST API 소비자 키
  • WOOCOMMERCE_CONSUMER_SECRET : WooCommerce REST API 소비자 비밀번호

WordPress API 메서드에만 필요합니다.

  • WORDPRESS_USERNAME : 적절한 권한이 있는 WordPress 사용자 이름
  • WORDPRESS_PASSWORD : WordPress 인증을 위한 비밀번호

환경 변수를 사용하지 않으려면 요청 매개변수에 이러한 자격 증명을 제공할 수도 있습니다.

인증 옵션

WooCommerce 인증

WooCommerce API에 액세스하려면 WordPress 대시보드의 WooCommerce → 설정 → 고급 → REST API에서 생성할 수 있는 소비자 키가 필요합니다.

워드프레스 인증

WordPress 특정 방법(게시물 관리 등)의 경우 다음을 제공해야 합니다.

  • 기본 인증을 위한 사용자 이름/비밀번호 자격 증명
  • 사이트에서 WordPress REST API를 활성화해야 합니다.

API 메서드

이 서버는 WordPress와 WooCommerce API 메서드를 모두 지원합니다. 사용 가능한 메서드 목록은 다음과 같습니다.

워드프레스 콘텐츠 관리

이러한 방법에는 WordPress 사용자 이름/비밀번호 인증 정보가 필요하며 WooCommerce API와 별개입니다.

방법설명
create_post새로운 WordPress 게시물 만들기
get_postsWordPress 게시물 검색
update_post기존 WordPress 게시물 업데이트
get_post_meta게시물 메타데이터 가져오기
update_post_meta게시물 메타데이터 업데이트
create_post_meta게시물 메타데이터 생성
delete_post_meta게시물 메타데이터 삭제

WooCommerce 제품

방법설명
get_products제품 목록을 검색합니다
get_productID로 단일 제품 가져오기
create_product새로운 제품을 만드세요
update_product기존 제품 업데이트
delete_product제품 삭제
get_product_meta제품 메타데이터 가져오기
create_product_meta제품 메타데이터 생성/업데이트
update_product_meta제품 메타데이터 업데이트(생성 별칭)
delete_product_meta제품 메타데이터 삭제

제품 카테고리

방법설명
get_product_categories제품 카테고리 검색
get_product_category단일 제품 카테고리를 얻으세요
create_product_category새로운 제품 카테고리를 만드세요
update_product_category제품 카테고리 업데이트
delete_product_category제품 카테고리 삭제

제품 태그

방법설명
get_product_tags제품 태그 검색
get_product_tag단일 제품 태그를 받으세요
create_product_tag새로운 제품 태그를 만드세요
update_product_tag제품 태그 업데이트
delete_product_tag제품 태그 삭제

제품 속성

방법설명
get_product_attributes제품 속성 검색
get_product_attribute단일 제품 속성 가져오기
create_product_attribute새로운 제품 속성을 만듭니다
update_product_attribute제품 속성 업데이트
delete_product_attribute제품 속성 삭제
get_attribute_terms속성 용어 검색
get_attribute_term단일 속성 용어 가져오기
create_attribute_term새로운 속성 용어 만들기
update_attribute_term속성 용어 업데이트
delete_attribute_term속성 용어 삭제

제품 변형

방법설명
get_product_variations제품 변형 검색
get_product_variation단일 제품 변형을 얻으세요
create_product_variation새로운 제품 변형을 만듭니다
update_product_variation제품 변형 업데이트
delete_product_variation제품 변형 삭제

제품 리뷰

방법설명
get_product_reviews제품 리뷰 검색
get_product_review단일 제품 리뷰를 받으세요
create_product_review새로운 제품 리뷰를 작성하세요
update_product_review제품 리뷰 업데이트
delete_product_review상품평 삭제

WooCommerce 주문

방법설명
get_orders주문 목록을 검색합니다
get_orderID로 단일 주문 받기
create_order새로운 주문을 만드세요
update_order기존 주문 업데이트
delete_order주문 삭제
get_order_meta주문 메타데이터 가져오기
create_order_meta주문 메타데이터 생성/업데이트
update_order_meta주문 메타데이터 업데이트(생성 별칭)
delete_order_meta주문 메타데이터 삭제

주문 참고 사항

방법설명
get_order_notes주문 메모 검색
get_order_note단일 주문 메모 받기
create_order_note새로운 주문 메모 만들기
delete_order_note주문 메모 삭제

주문 환불

방법설명
get_order_refunds주문 환불 검색
get_order_refund단일 주문 환불 받기
create_order_refund새로운 주문 환불 생성
delete_order_refund주문 환불 삭제

WooCommerce 고객

방법설명
get_customers고객 목록을 검색합니다
get_customerID로 단일 고객 가져오기
create_customer새로운 고객 만들기
update_customer기존 고객 업데이트
delete_customer고객 삭제
get_customer_meta고객 메타데이터 가져오기
create_customer_meta고객 메타데이터 생성/업데이트
update_customer_meta고객 메타데이터 업데이트(생성 별칭)
delete_customer_meta고객 메타데이터 삭제

해운

방법설명
get_shipping_zones배송 지역 검색
get_shipping_zone단일 배송 구역을 받으세요
create_shipping_zone새로운 배송 구역 만들기
update_shipping_zone배송 지역 업데이트
delete_shipping_zone배송 지역 삭제
get_shipping_methods배송 방법 검색
get_shipping_zone_methods특정 지역의 배송 방법을 알아보세요
create_shipping_zone_method특정 지역에 대한 새로운 배송 방법 만들기
update_shipping_zone_method특정 지역의 배송 방법 업데이트
delete_shipping_zone_method지역에서 배송 방법 삭제
get_shipping_zone_locations배송 구역 위치 가져오기
update_shipping_zone_locations배송 구역의 위치 업데이트

구실

방법설명
get_tax_classes세무 수업 검색
create_tax_class새로운 세금 등급을 만듭니다
delete_tax_class세금 등급 삭제
get_tax_rates세율 검색
get_tax_rate단일 세율을 받으세요
create_tax_rate새로운 세율 생성
update_tax_rate세율 업데이트
delete_tax_rate세율 삭제

할인/쿠폰

방법설명
get_coupons쿠폰 검색
get_coupon쿠폰 한 장 받기
create_coupon새로운 쿠폰을 만드세요
update_coupon쿠폰 업데이트
delete_coupon쿠폰 삭제

결제 게이트웨이

방법설명
get_payment_gateways결제 게이트웨이 검색
get_payment_gateway단일 결제 게이트웨이를 받으세요
update_payment_gateway결제 게이트웨이 업데이트

보고서

방법설명
get_sales_report판매 보고서 검색
get_products_report제품 보고서 검색
get_orders_report주문 보고서 검색
get_categories_report카테고리 보고서 검색
get_customers_report고객 보고서 검색
get_stock_report주식 보고서 검색
get_coupons_report쿠폰 보고서 검색
get_taxes_report세금 보고서 검색

설정

방법설명
get_settings모든 설정 검색
get_setting_options설정에 대한 옵션 검색
update_setting_option설정 옵션 업데이트

시스템 상태

방법설명
get_system_status시스템 상태 검색
get_system_status_tools시스템 상태 도구 검색
run_system_status_tool시스템 상태 도구 실행

데이터

방법설명
get_data매장 데이터 검색
get_continents대륙 데이터 검색
get_countries국가 데이터 검색
get_currencies통화 데이터 검색
get_current_currency현재 통화를 받으세요

메서드 매개변수

모든 메서드는 유사한 매개변수 구조를 따릅니다. 다음은 몇 가지 예입니다.

모든 메서드에 대한 공통 매개변수

  • siteUrl : (env에 설정된 경우 선택 사항) WordPress 사이트 URL

WooCommerce 메서드에 대한 추가 매개변수

  • consumerKey : (env에 설정된 경우 선택 사항) WooCommerce 소비자 키
  • consumerSecret : (env에 설정된 경우 선택 사항) WooCommerce 소비자 비밀번호

WordPress 메서드에 대한 추가 매개변수

  • username : (env에 설정된 경우 선택 사항) WordPress 사용자 이름
  • password : (env에 설정된 경우 선택 사항) WordPress 비밀번호

사용 예

WordPress API 예제

{ "jsonrpc": "2.0", "id": 1, "method": "create_post", "params": { "siteUrl": "https://your-wordpress-site.com", "username": "your-wordpress-username", "password": "your-wordpress-password", "title": "My New Blog Post", "content": "This is the content of my new blog post.", "status": "publish" } }

WooCommerce 제품 예시

{ "jsonrpc": "2.0", "id": 1, "method": "get_products", "params": { "perPage": 20, "page": 1, "filters": { "category": 19, "status": "publish" } } }

제품 예제 만들기

{ "jsonrpc": "2.0", "id": 1, "method": "create_product", "params": { "productData": { "name": "Premium T-Shirt", "type": "simple", "regular_price": "29.99", "description": "Comfortable cotton t-shirt, available in various sizes.", "short_description": "Premium quality t-shirt.", "categories": [ { "id": 19 } ], "images": [ { "src": "http://example.com/wp-content/uploads/2022/06/t-shirt.jpg" } ] } } }

제품 메타데이터 예시

{ "jsonrpc": "2.0", "id": 1, "method": "create_product_meta", "params": { "productId": 456, "metaKey": "_custom_product_field", "metaValue": { "special_attribute": "value", "another_attribute": 42 } } }

주문 메타데이터 예

{ "jsonrpc": "2.0", "id": 1, "method": "create_order_meta", "params": { "orderId": 789, "metaKey": "_delivery_instructions", "metaValue": "Leave package at the back door" } }

보안 참고 사항

WooCommerce REST API에 접근하려면 API 키를 생성해야 합니다. WordPress 대시보드의 WooCommerce → 설정 → 고급 → REST API에서 API 키를 생성할 수 있습니다.

요구 사항

  • Node.js 20.0.0 이상
  • WooCommerce 플러그인이 설치된 WordPress 사이트
  • WooCommerce REST API 키

특허

MIT 라이선스 - 자세한 내용은 라이선스 파일을 참조하세요.

ID: 6cg08xtbwq