WooCommerce
WooCommerce es un plugin de comercio electrónico de código abierto para WordPress. Está diseñado para comerciantes en línea pequeños, medianos y grandes que usan WordPress. El plugin se volvió popular rápidamente por su facilidad de instalación y personalización, así como por la posición de mercado del producto base como software gratuito.
WooCommerce es ahora una de las principales opciones para tiendas en línea y para personas que quieren abrir su tienda en internet y gestionar pedidos desde allí.
OneChat admite la integración con WooCommerce de forma nativa junto con todas las acciones que la API actual de WooCommerce soporta en sus endpoints.
No solo puedes crear automatizaciones usando OneChat para tu tienda WooCommerce, sino también crear, editar y actualizar pedidos, completarlos, dar seguimiento a pedidos, envíos, reseñas, etc.
_fchgll4b9wa8Integrando tu tienda WooCommerce con OneChat
Para integrar OneChat con tu tienda WooCommerce, debes iniciar sesión en tu tienda y hacer clic en la pestaña de WooCommerce.
Haz clic en **Settings > Advanced > REST API**.
Haz clic en **Add Key**.
Ingresa los detalles y crea tu API Key.
Guarda y copia los detalles.
En OneChat, haz clic en la pestaña **Integrations** y luego en **WooCommerce** para integrar tu tienda.
_qywkl6tgo34gUso de acciones de WooCommerce
Para usar acciones de WooCommerce, crea un nodo de acción y luego haz clic en **integrations** para encontrar la pestaña de WooCommerce y hacer clic en ella.
_5dfr7e2hi6ytAcciones nativas de WooCommerce
WooCommerce soporta las siguientes acciones desde sus endpoints de API como se muestra a continuación.
Ahora exploraremos cada una de ellas en detalle.
_e1oqd458287xAgregar al carrito
Esta acción se usa para agregar un artículo o producto al carrito del usuario.
Se recibe la siguiente carga útil de respuesta:
| {
"variant_id": 4120,
"product_id": 375,
"quantity": 1,
"previous_quantity": 0
} |
_qxq4uewnmm3iEliminar del carrito por variante
Esta acción se usa para eliminar un artículo o producto del carrito usando su variante y el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"variant_id": 4120,
"product_id": 375,
"quantity": 1,
"previous_quantity": 3
} |
_7r2k2cfi70y9Eliminar del carrito por producto
Esta acción se usa para eliminar un artículo o producto del carrito usando solo el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"product_id": 375,
"removed_variants": [
{
"variant_id": 4120,
"quantity": 1
}
]
} |
_e4vvkvajwmvyVaciar carrito
Esta acción se usa para vaciar completamente el carrito.
Se recibe la siguiente carga útil de respuesta.
| {
"status": "ok"
} |
_4taap9plt30yObtener artículos del carrito
Esta acción se usa para obtener todos los detalles de los artículos presentes en el carrito.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 258,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"sku": "",
"price": 175,
"image": "https://shop.businessautomated.io/wp-content/uploads/2021/03/sports-shoe5.jpg",
"parent_name": "DNK Black Shoes"
}
] |
_9u3xgc9fsf3bObtener IDs y cantidad de artículos del carrito
Esta acción se usa para obtener los IDs y la cantidad de los artículos presentes en el carrito.
Se recibe la siguiente carga útil de respuesta.
| [
{
"product_id": 375,
"quantity": 2,
"variation_id": 4120
}
] |
_r9ekpcya3l9yCrear pedido desde el carrito
Esta acción se usa para crear un pedido usando los artículos del carrito.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4597,
"parent_id": 0,
"status": "pending",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T11:01:51",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": null,
"date_paid": null,
"cart_hash": "",
"number": "4597",
"meta_data": [
{
"id": 6465,
"key": "user_ns",
"value": "f12372u15376836"
}
],
"line_items": [
{
"id": 259,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"tax_class": "",
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": true,
"needs_payment": true,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T11:01:51",
"date_completed_gmt": null,
"date_paid_gmt": null,
"currency_symbol": "$"
} |
_g9rvyjselfgbBuscar cupones
Esta acción se usa para buscar cupones disponibles en tu tienda WooCommerce con varios parámetros y consultas de búsqueda.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 4592,
"code": "vipdiscount60fc",
"amount": "10.00",
"status": "publish",
"date_created": "2023-01-25T06:56:57",
"date_created_gmt": "2023-01-25T06:56:57",
"date_modified": "2023-01-25T06:56:57",
"date_modified_gmt": "2023-01-25T06:56:57",
"discount_type": "percent",
"description": "10% discount on entire order, single use",
"date_expires": null,
"date_expires_gmt": null,
"usage_count": 1,
"individual_use": false,
"product_ids": [
],
"excluded_product_ids": [
],
"usage_limit": 1,
"usage_limit_per_user": 1,
"limit_usage_to_x_items": null,
"free_shipping": false,
"product_categories": [
],
"excluded_product_categories": [
],
"exclude_sale_items": false,
"minimum_amount": "0.00",
"maximum_amount": "0.00",
"email_restrictions": [
],
"used_by": [
"mark@doe.com"
],
"meta_data": [
],
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_39pw4196j5b1Obtener información de cupón
Esta acción se usa para obtener la información de un cupón específico usando su ID de cupón.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4592,
"code": "vipdiscount60fc",
"amount": "10.00",
"status": "publish",
"date_created": "2023-01-25T06:56:57",
"date_created_gmt": "2023-01-25T06:56:57",
"date_modified": "2023-01-25T06:56:57",
"date_modified_gmt": "2023-01-25T06:56:57",
"discount_type": "percent",
"description": "10% discount on entire order, single use",
"date_expires": null,
"date_expires_gmt": null,
"usage_count": 1,
"individual_use": false,
"product_ids": [
],
"excluded_product_ids": [
],
"usage_limit": 1,
"usage_limit_per_user": 1,
"limit_usage_to_x_items": null,
"free_shipping": false,
"product_categories": [
],
"excluded_product_categories": [
],
"exclude_sale_items": false,
"minimum_amount": "0.00",
"maximum_amount": "0.00",
"email_restrictions": [
],
"used_by": [
"mark@doe.com"
],
"meta_data": [
]
} |
_718oj1nmyb54Eliminar cupón
Esta acción se usa para eliminar un cupón según su ID de cupón.
Se recibe la siguiente carga útil de respuesta.
| {
"status": "ok"
} |
_blhnpn5wyzkqCrear cupón
Esta acción se usa para crear un cupón.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4598,
"code": "test12",
"amount": "10.00",
"status": "publish",
"date_created": "2023-04-14T14:27:49",
"date_created_gmt": "2023-04-14T14:27:49",
"date_modified": "2023-04-14T14:27:49",
"date_modified_gmt": "2023-04-14T14:27:49",
"discount_type": "percent",
"description": "test coupon",
"date_expires": "2023-05-01T00:00:00",
"date_expires_gmt": "2023-05-01T00:00:00",
"usage_count": 0,
"individual_use": false,
"product_ids": [
],
"excluded_product_ids": [
],
"usage_limit": 1,
"usage_limit_per_user": 1,
"limit_usage_to_x_items": null,
"free_shipping": false,
"product_categories": [
],
"excluded_product_categories": [
],
"exclude_sale_items": false,
"minimum_amount": "0.00",
"maximum_amount": "0.00",
"email_restrictions": [
],
"used_by": [
],
"meta_data": [
]
} |
_2zwynr9w15u0Actualizar cupón
Esta acción se usa para actualizar un cupón usando su ID de cupón.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4598,
"code": "test12",
"amount": "15.00",
"status": "publish",
"date_created": "2023-04-14T14:27:49",
"date_created_gmt": "2023-04-14T14:27:49",
"date_modified": "2023-04-14T14:27:49",
"date_modified_gmt": "2023-04-14T14:27:49",
"discount_type": "percent",
"description": "test coupon",
"date_expires": "2023-05-01T00:00:00",
"date_expires_gmt": "2023-05-01T00:00:00",
"usage_count": 0,
"individual_use": false,
"product_ids": [
],
"excluded_product_ids": [
],
"usage_limit": 3,
"usage_limit_per_user": 1,
"limit_usage_to_x_items": null,
"free_shipping": false,
"product_categories": [
],
"excluded_product_categories": [
],
"exclude_sale_items": false,
"minimum_amount": "0.00",
"maximum_amount": "0.00",
"email_restrictions": [
],
"used_by": [
],
"meta_data": [
]
} |
_1id6ok10irdBuscar clientes
Esta acción se usa para buscar clientes usando varios parámetros y consultas.
Se recibió la siguiente carga útil de respuesta.
| [
{
"id": 2,
"date_created": "2022-10-10T01:24:22",
"date_created_gmt": "2022-10-10T01:24:22",
"date_modified": "2022-10-10T01:24:22",
"date_modified_gmt": "2022-10-10T01:24:22",
"email": "test@test.com",
"first_name": "",
"last_name": "last",
"role": "customer",
"username": "test",
"billing": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"email": "",
"phone": ""
},
"shipping": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/b642b4217b34b1e8d3bd915fc65c4452?s=96&d=mm&r=g",
"meta_data": [
{...} // 3 keys
],
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
},
{
"id": 5,
"date_created": "2022-10-12T16:32:26",
"date_created_gmt": "2022-10-12T16:32:26",
"date_modified": "2022-10-12T16:32:26",
"date_modified_gmt": "2022-10-12T16:32:26",
"email": "mark@onechat.com.au",
"first_name": "Mark",
"last_name": "van der Made",
"role": "customer",
"username": "markvdmade",
"billing": {
"first_name": "Mark",
"last_name": "van der Made",
"company": "",
"address_1": "palmonostora 143",
"address_2": "",
"city": "Palmonostora",
"postcode": "6112",
"country": "Hungary",
"state": "bacs-kiskun",
"email": "mark@onechat.com.au",
"phone": "+36707203759"
},
"shipping": {
"first_name": "Mark",
"last_name": "van der Made",
"company": "",
"address_1": "palmonostora 143",
"address_2": "",
"city": "Palmonostora",
"postcode": "6112",
"country": "Hungary",
"state": "bacs-kiskun",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/f96de5c9ef467d55b706b615b56a641b?s=96&d=mm&r=g",
"meta_data": [
],
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_429ma5djs71Obtener información del cliente
Esta acción se usa para obtener información de un cliente usando su ID de cliente.
| {
"id": 2,
"date_created": "2022-10-10T01:24:22",
"date_created_gmt": "2022-10-10T01:24:22",
"date_modified": "2022-10-10T01:24:22",
"date_modified_gmt": "2022-10-10T01:24:22",
"email": "test@test.com",
"first_name": "",
"last_name": "last",
"role": "customer",
"username": "test",
"billing": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"email": "",
"phone": ""
},
"shipping": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/b642b4217b34b1e8d3bd915fc65c4452?s=96&d=mm&r=g",
"meta_data": [
{
"id": 62,
"key": "wc_last_active",
"value": "1665532800"
}
]
} |
_siboxflpzrhyCrear cliente
Esta acción se usa para crear un cliente.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 6,
"date_created": "2023-04-14T17:54:14",
"date_created_gmt": "2023-04-14T17:54:14",
"date_modified": "2023-04-14T17:54:14",
"date_modified_gmt": "2023-04-14T17:54:14",
"email": "hammadsiddiqui788@gmail.com",
"first_name": "Hammad",
"last_name": "Siddiqui",
"role": "customer",
"username": "HammadSiddiqui76",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "abc road , garden city",
"address_2": "Maymar, Karachi",
"city": "Karachi",
"postcode": "78601",
"country": "Pakistan",
"state": "Sindh",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+923032320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "abc road , garden city",
"address_2": "Maymar, Karachi",
"city": "Karachi",
"postcode": "78601",
"country": "Pakistan",
"state": "Sindh",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/f4c6265a08a9578979e81cc594810336?s=96&d=mm&r=g",
"meta_data": [
]
} |
_3ie8up342ewkActualizar cliente
Esta acción se usa para actualizar los detalles de un cliente usando su ID de cliente.
Una vez creado, el nombre de usuario y la contraseña del cliente no pueden ser cambiados por el administrador.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 6,
"date_created": "2023-04-14T17:54:14",
"date_created_gmt": "2023-04-14T17:54:14",
"date_modified": "2023-04-14T17:57:24",
"date_modified_gmt": "2023-04-14T17:57:24",
"email": "hammadsiddiqui788@gmail.com",
"first_name": "Hammad",
"last_name": "Siddiqui",
"role": "customer",
"username": "HammadSiddiqui76",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "abc road , garden city",
"address_2": "Maymar, Karachi",
"city": "Karachi",
"postcode": "78601",
"country": "Pakistan",
"state": "Sindh",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+923032320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "abc road , garden city",
"address_2": "Maymar, Karachi",
"city": "Karachi",
"postcode": "78601",
"country": "Pakistan",
"state": "Sindh",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/f4c6265a08a9578979e81cc594810336?s=96&d=mm&r=g",
"meta_data": [
]
} |
_uzpfx1t7dqs1Eliminar cliente
Esta acción se usa para eliminar un cliente específico usando su ID de cliente.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 2,
"date_created": "2022-10-10T01:24:22",
"date_created_gmt": "2022-10-10T01:24:22",
"date_modified": "2022-10-10T01:24:22",
"date_modified_gmt": "2022-10-10T01:24:22",
"email": "test@test.com",
"first_name": "",
"last_name": "last",
"role": "customer",
"username": "test",
"billing": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"email": "",
"phone": ""
},
"shipping": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"postcode": "",
"country": "",
"state": "",
"phone": ""
},
"is_paying_customer": false,
"avatar_url": "https://secure.gravatar.com/avatar/b642b4217b34b1e8d3bd915fc65c4452?s=96&d=mm&r=g",
"meta_data": [
{
"id": 62,
"key": "wc_last_active",
"value": "1665532800"
}
]
} |
_4lcjw5mjhi2yBuscar pedidos
Esta acción se usa para buscar pedidos usando varios parámetros y consultas.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 4597,
"parent_id": 0,
"status": "pending",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T11:01:51",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": null,
"date_paid": null,
"cart_hash": "",
"number": "4597",
"meta_data": [
{...} // 3 keys
],
"line_items": [
{...} // 16 keys
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": true,
"needs_payment": true,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T11:01:51",
"date_completed_gmt": null,
"date_paid_gmt": null,
"currency_symbol": "$",
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_ydfkmhkrssjdObtener información del pedido
Esta acción se usa para obtener información del pedido usando el ID del pedido.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4597,
"parent_id": 0,
"status": "pending",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T11:01:51",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": null,
"date_paid": null,
"cart_hash": "",
"number": "4597",
"meta_data": [
{
"id": 6465,
"key": "user_ns",
"value": "f12372u15376836"
}
],
"line_items": [
{
"id": 259,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"tax_class": "",
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": true,
"needs_payment": true,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T11:01:51",
"date_completed_gmt": null,
"date_paid_gmt": null,
"currency_symbol": "$"
} |
_qsifbxdp90ziCrear pedido desde un solo producto
Esta acción se usa para crear un pedido de un solo artículo o producto. (Para varios artículos, usa la acción de crear pedido desde el carrito).
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4599,
"parent_id": 0,
"status": "pending",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T18:13:13",
"date_modified": "2023-04-14T18:13:13",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "175.00",
"total_tax": "0.00",
"customer_id": 4,
"order_key": "wc_order_yhGfOfZ0eoCYe",
"billing": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"state": "",
"postcode": "",
"country": "",
"email": "mark@onechat.com",
"phone": ""
},
"shipping": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"state": "",
"postcode": "",
"country": "",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": null,
"date_paid": null,
"cart_hash": "",
"number": "4599",
"meta_data": [
],
"line_items": [
{
"id": 260,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 1,
"tax_class": "",
"subtotal": "175.00",
"subtotal_tax": "0.00",
"total": "175.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4599?pay_for_order=true&key=wc_order_yhGfOfZ0eoCYe",
"is_editable": true,
"needs_payment": true,
"needs_processing": true,
"date_created_gmt": "2023-04-14T18:13:13",
"date_modified_gmt": "2023-04-14T18:13:13",
"date_completed_gmt": null,
"date_paid_gmt": null,
"currency_symbol": "$"
} |
_qu7fku44gcunActualizar pedido
Esta acción se usa para actualizar la información y el estado del pedido usando el ID del pedido.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4597,
"parent_id": 0,
"status": "completed",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T18:16:14",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": "2023-04-14T18:16:14",
"date_paid": "2023-04-14T18:16:14",
"cart_hash": "",
"number": "4597",
"meta_data": [
{
"id": 6465,
"key": "user_ns",
"value": "f12372u15376836"
},
{
"id": 6499,
"key": "_new_order_email_sent",
"value": "true"
}
],
"line_items": [
{
"id": 259,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"tax_class": "",
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": false,
"needs_payment": false,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T18:16:14",
"date_completed_gmt": "2023-04-14T18:16:14",
"date_paid_gmt": "2023-04-14T18:16:14",
"currency_symbol": "$"
} |
_ac1t6ksw8vb2Eliminar pedido
Esta acción se usa para eliminar un pedido usando el ID del pedido.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4597,
"parent_id": 0,
"status": "completed",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T18:16:14",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": "2023-04-14T18:16:14",
"date_paid": "2023-04-14T18:16:14",
"cart_hash": "",
"number": "4597",
"meta_data": [
{
"id": 6465,
"key": "user_ns",
"value": "f12372u15376836"
},
{
"id": 6499,
"key": "_new_order_email_sent",
"value": "true"
}
],
"line_items": [
{
"id": 259,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"tax_class": "",
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": false,
"needs_payment": false,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T18:16:14",
"date_completed_gmt": "2023-04-14T18:16:14",
"date_paid_gmt": "2023-04-14T18:16:14",
"currency_symbol": "$"
} |
_xe5u0jstuwpkCrear nota de pedido
Esta acción se usa para crear una nota de pedido usando el ID del pedido.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 65,
"author": "WooCommerce",
"date_created": "2023-04-14T18:21:24",
"date_created_gmt": "2023-04-14T18:21:24",
"note": "This is a test order",
"customer_note": false
} |
_m2avyzirq8wsBuscar productos
Esta acción se usa para buscar productos usando varios parámetros y consultas.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 375,
"name": "DNK Black Shoes",
"slug": "dnk-black-shoes",
"permalink": "https://shop.businessautomated.io/product/dnk-black-shoes",
"type": "variable",
"status": "publish",
"featured": false,
"catalog_visibility": "visible",
"description": "",
"short_description": "",
"sku": "",
"price": "175",
"regular_price": "",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"purchasable": true,
"total_sales": 30,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"external_url": "",
"button_text": "",
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"sold_individually": false,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_required": true,
"shipping_taxable": true,
"shipping_class": "",
"shipping_class_id": 0,
"reviews_allowed": true,
"average_rating": "0.00",
"rating_count": 0,
"parent_id": 0,
"purchase_note": "",
"attributes": [
],
"variations": [
4120,
4119,
4122,
4121
],
"grouped_products": [
],
"menu_order": 0,
"related_ids": [
242,
229,
86,
211,
79
],
"stock_status": "instock",
"has_options": true,
"image": "https://shop.businessautomated.io/wp-content/uploads/2021/03/sports-shoe5.jpg"
}
] |
_gt794n61au7vObtener información del producto
Esta acción se usa para obtener información del producto usando el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 375,
"name": "DNK Black Shoes",
"slug": "dnk-black-shoes",
"permalink": "https://shop.businessautomated.io/product/dnk-black-shoes",
"type": "variable",
"status": "publish",
"featured": false,
"catalog_visibility": "visible",
"description": "",
"short_description": "",
"sku": "",
"price": "175",
"regular_price": "",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"purchasable": true,
"total_sales": 30,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"external_url": "",
"button_text": "",
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"sold_individually": false,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_required": true,
"shipping_taxable": true,
"shipping_class": "",
"shipping_class_id": 0,
"reviews_allowed": true,
"average_rating": "0.00",
"rating_count": 0,
"parent_id": 0,
"purchase_note": "",
"attributes": [
],
"variations": [
4120,
4119,
4122,
4121
],
"grouped_products": [
],
"menu_order": 0,
"related_ids": [
247,
209,
160,
169,
109
],
"stock_status": "instock",
"has_options": true,
"image": "https://shop.businessautomated.io/wp-content/uploads/2021/03/sports-shoe5.jpg"
} |
_mdsskrixiyqrCrear producto
Esta acción se usa para crear un producto en tu tienda WooCommerce.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4600,
"name": "Test Product",
"slug": "test-product",
"permalink": "https://shop.businessautomated.io/product/test-product",
"type": "simple",
"status": "publish",
"featured": false,
"catalog_visibility": "visible",
"description": "this is a test product",
"short_description": "",
"sku": "123456",
"price": "10",
"regular_price": "10",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"purchasable": true,
"total_sales": 0,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"external_url": "",
"button_text": "",
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"sold_individually": false,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_required": true,
"shipping_taxable": true,
"shipping_class": "",
"shipping_class_id": 0,
"reviews_allowed": true,
"average_rating": "0",
"rating_count": 0,
"parent_id": 0,
"purchase_note": "",
"attributes": [
],
"variations": [
],
"grouped_products": [
],
"menu_order": 0,
"related_ids": [
109,
212,
157,
210,
229
],
"stock_status": "instock",
"has_options": false,
"image": null
} |
_2i79a03kla4tActualizar producto
Esta acción se usa para actualizar los detalles del producto usando el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4600,
"name": "Test Product",
"slug": "test-product",
"permalink": "https://shop.businessautomated.io/?post_type=product&p=4600",
"type": "simple",
"status": "pending",
"featured": false,
"catalog_visibility": "visible",
"description": "this is a test product",
"short_description": "",
"sku": "123456",
"price": "10",
"regular_price": "10",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"purchasable": true,
"total_sales": 0,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"external_url": "",
"button_text": "",
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"sold_individually": false,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_required": true,
"shipping_taxable": true,
"shipping_class": "",
"shipping_class_id": 0,
"reviews_allowed": true,
"average_rating": "0",
"rating_count": 0,
"parent_id": 0,
"purchase_note": "",
"attributes": [
],
"variations": [
],
"grouped_products": [
],
"menu_order": 0,
"related_ids": [
252,
86,
247,
95,
242
],
"stock_status": "instock",
"has_options": false,
"image": null
} |
_k58ni2ndf936Eliminar producto
Esta acción se usa para eliminar un producto usando el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4600,
"name": "Test Product",
"slug": "test-product",
"permalink": "https://shop.businessautomated.io/?post_type=product&p=4600",
"date_created": "2023-04-15T01:02:07",
"date_created_gmt": "2023-04-15T01:02:07",
"date_modified": "2023-04-15T01:03:28",
"date_modified_gmt": "2023-04-15T01:03:28",
"type": "simple",
"status": "pending",
"featured": false,
"catalog_visibility": "visible",
"description": "this is a test product",
"short_description": "",
"sku": "123456",
"price": "10",
"regular_price": "10",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"purchasable": true,
"total_sales": 0,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"external_url": "",
"button_text": "",
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"sold_individually": false,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_required": true,
"shipping_taxable": true,
"shipping_class": "",
"shipping_class_id": 0,
"reviews_allowed": true,
"average_rating": "0",
"rating_count": 0,
"upsell_ids": [
],
"cross_sell_ids": [
],
"parent_id": 0,
"purchase_note": "",
"categories": [
{
"id": 49,
"name": "Women",
"slug": "women"
}
],
"tags": [
{
"id": 57,
"name": "Test Product",
"slug": "test-product"
}
],
"images": [
],
"attributes": [
],
"default_attributes": [
],
"variations": [
],
"grouped_products": [
],
"menu_order": 0,
"price_html": "<span class="woocommerce-Price-amount amount"><bdi><span class="woocommerce-Price-currencySymbol">$</span>10.00</bdi></span>",
"related_ids": [
160,
157,
194,
210,
252
],
"meta_data": [
],
"stock_status": "instock",
"has_options": false
} |
_uzzxt2eoul0aBuscar variantes de producto
Esta acción se usa para buscar variantes de producto según varios filtros.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 4122,
"date_created": "2022-08-17T08:01:49",
"date_created_gmt": "2022-08-17T08:01:49",
"date_modified": "2022-08-17T08:01:49",
"date_modified_gmt": "2022-08-17T08:01:49",
"description": "",
"permalink": "https://shop.businessautomated.io/product/dnk-black-shoes?attribute_pa_color=red",
"sku": "",
"price": "195",
"regular_price": "195",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"status": "publish",
"purchasable": true,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"stock_status": "instock",
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_class": "",
"shipping_class_id": 0,
"image": {
"id": 2462,
"date_created": "2021-03-05T07:22:32",
"date_created_gmt": "2021-03-05T07:22:32",
"date_modified": "2021-03-05T07:22:32",
"date_modified_gmt": "2021-03-05T07:22:32",
"src": "https://shop.businessautomated.io/wp-content/uploads/2021/03/sports-shoe2.jpg",
"name": "sports-shoe2",
"alt": ""
},
"attributes": [
{...} // 3 keys
],
"menu_order": 3,
"meta_data": [
{...}, // 3 keys
{...}, // 3 keys
{...} // 3 keys
],
"_links": {
"self": [...], // 1 items
"collection": [...], // 1 items
"up": [...] // 1 items
}
}
] |
_tmrj6cs32kr0Obtener información de variante de producto
Esta acción se usa para obtener información de una variante usando su ID de variante y el ID del producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4122,
"date_created": "2022-08-17T08:01:49",
"date_created_gmt": "2022-08-17T08:01:49",
"date_modified": "2022-08-17T08:01:49",
"date_modified_gmt": "2022-08-17T08:01:49",
"description": "",
"permalink": "https://shop.businessautomated.io/product/dnk-black-shoes?attribute_pa_color=red",
"sku": "",
"price": "195",
"regular_price": "195",
"sale_price": "",
"date_on_sale_from": null,
"date_on_sale_from_gmt": null,
"date_on_sale_to": null,
"date_on_sale_to_gmt": null,
"on_sale": false,
"status": "publish",
"purchasable": true,
"virtual": false,
"downloadable": false,
"downloads": [
],
"download_limit": -1,
"download_expiry": -1,
"tax_status": "taxable",
"tax_class": "",
"manage_stock": false,
"stock_quantity": null,
"stock_status": "instock",
"backorders": "no",
"backorders_allowed": false,
"backordered": false,
"low_stock_amount": null,
"weight": "",
"dimensions": {
"length": "",
"width": "",
"height": ""
},
"shipping_class": "",
"shipping_class_id": 0,
"image": {
"id": 2462,
"date_created": "2021-03-05T07:22:32",
"date_created_gmt": "2021-03-05T07:22:32",
"date_modified": "2021-03-05T07:22:32",
"date_modified_gmt": "2021-03-05T07:22:32",
"src": "https://shop.businessautomated.io/wp-content/uploads/2021/03/sports-shoe2.jpg",
"name": "sports-shoe2",
"alt": ""
},
"attributes": [
{
"id": 0,
"name": "color",
"option": "red"
}
],
"menu_order": 3,
"meta_data": [
{
"id": 3030,
"key": "_wxr_import_user_slug",
"value": "alex"
},
{
"id": 3031,
"key": "_astra_sites_imported_post",
"value": "1"
},
{
"id": 3032,
"key": "_astra_sites_enable_for_batch",
"value": "1"
}
]
} |
_ptarwxk01el2Buscar categorías
Esta acción se usa para obtener categorías usando varios parámetros y consultas.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 49,
"name": "Women",
"slug": "women",
"parent": 0,
"description": " Nam nec tellus a odio tincidunt auctor a ornare odio. Sed non mauris vitae erat consequat auctor eu in elit. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Mauris in erat justo. Nullam ac urna eu felis dapibus condimentum sit amet a augue. Sed non neque elit sed ut. ",
"display": "default",
"image": {
"id": 500,
"date_created": "2018-12-06T05:50:12",
"date_created_gmt": "2018-12-06T05:50:12",
"date_modified": "2022-10-06T23:57:20",
"date_modified_gmt": "2022-10-06T23:57:20",
"src": "https://shop.businessautomated.io/wp-content/uploads/2018/12/women-fashion-free-img.jpg",
"name": "women-fashion-free-img",
"alt": ""
},
"menu_order": 0,
"count": 17,
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_4pzdfgcg9cnlObtener información de categoría
Esta acción se usa para obtener información de una categoría usando su ID de categoría.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 49,
"name": "Women",
"slug": "women",
"parent": 0,
"description": " Nam nec tellus a odio tincidunt auctor a ornare odio. Sed non mauris vitae erat consequat auctor eu in elit. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Mauris in erat justo. Nullam ac urna eu felis dapibus condimentum sit amet a augue. Sed non neque elit sed ut. ",
"display": "default",
"image": {
"id": 500,
"date_created": "2018-12-06T05:50:12",
"date_created_gmt": "2018-12-06T05:50:12",
"date_modified": "2022-10-06T23:57:20",
"date_modified_gmt": "2022-10-06T23:57:20",
"src": "https://shop.businessautomated.io/wp-content/uploads/2018/12/women-fashion-free-img.jpg",
"name": "women-fashion-free-img",
"alt": ""
},
"menu_order": 0,
"count": 17,
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_88gaamwdp322Obtener información de etiqueta de producto
Esta acción se usa para obtener información de etiquetas de producto usando el ID de la etiqueta.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 49,
"name": "Women",
"slug": "women",
"parent": 0,
"description": " Nam nec tellus a odio tincidunt auctor a ornare odio. Sed non mauris vitae erat consequat auctor eu in elit. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Mauris in erat justo. Nullam ac urna eu felis dapibus condimentum sit amet a augue. Sed non neque elit sed ut. ",
"display": "default",
"image": {
"id": 500,
"date_created": "2018-12-06T05:50:12",
"date_created_gmt": "2018-12-06T05:50:12",
"date_modified": "2022-10-06T23:57:20",
"date_modified_gmt": "2022-10-06T23:57:20",
"src": "https://shop.businessautomated.io/wp-content/uploads/2018/12/women-fashion-free-img.jpg",
"name": "women-fashion-free-img",
"alt": ""
},
"menu_order": 0,
"count": 17,
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_pytjklh81dq6Crear etiqueta de producto
Esta acción se usa para crear una etiqueta de producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 57,
"name": "Test Product",
"slug": "test-product",
"description": "this is a test product",
"count": 0
} |
_9ybygdgec7m2Listar todos los métodos de envío
Esta acción se usa para listar todos los métodos de envío disponibles para la tienda.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": "flat_rate",
"title": "Flat rate",
"description": "Lets you charge a fixed rate for shipping.",
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
},
{
"id": "free_shipping",
"title": "Free shipping",
"description": "Free shipping is a special method which can be triggered with coupons and minimum spends.",
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
},
{
"id": "local_pickup",
"title": "Local pickup",
"description": "Allow customers to pick up orders themselves. By default, when using local pickup store base taxes will apply regardless of customer address.",
"_links": {
"self": [...], // 1 items
"collection": [...] // 1 items
}
}
] |
_ooutsem8qmr6Crear una reseña de producto
Esta acción se usa para crear una reseña para un producto.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 66,
"date_created": "2023-04-15T02:02:44",
"date_created_gmt": "2023-04-15T02:02:44",
"product_id": 375,
"product_name": "DNK Black Shoes",
"product_permalink": "https://shop.businessautomated.io/product/dnk-black-shoes",
"status": "approved",
"reviewer": "John Jigga",
"reviewer_email": "jigga69@gmail.com",
"review": "This is a very good product, me likes",
"rating": 4,
"verified": false,
"reviewer_avatar_urls": {
"24": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=24&d=mm&r=g",
"48": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=48&d=mm&r=g",
"96": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=96&d=mm&r=g"
}
} |
_ch080e5o5qdBuscar reseñas de productos
Esta acción se usa para obtener reseñas de productos usando varios filtros y parámetros.
Se recibe la siguiente carga útil de respuesta.
| [
{
"id": 66,
"date_created": "2023-04-15T02:02:44",
"date_created_gmt": "2023-04-15T02:02:44",
"product_id": 375,
"product_name": "DNK Black Shoes",
"product_permalink": "https://shop.businessautomated.io/product/dnk-black-shoes",
"status": "approved",
"reviewer": "John Jigga",
"reviewer_email": "jigga69@gmail.com",
"review": "<p>This is a very good product, me likes</p> ",
"rating": 4,
"verified": false,
"reviewer_avatar_urls": {
"24": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=24&d=mm&r=g",
"48": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=48&d=mm&r=g",
"96": "https://secure.gravatar.com/avatar/fbe4f4181cb19f28ab07c9b4967048ab?s=96&d=mm&r=g"
},
"_links": {
"self": [...], // 1 items
"collection": [...], // 1 items
"up": [...] // 1 items
}
}
] |
_6z5ouz10aekrTriggers nativos de WooCommerce
WooCommerce se integra de forma nativa con OneChat para proporcionar triggers de webhook. Estos triggers se activan cada vez que se realiza un evento en la tienda WooCommerce, ya sea mediante una API o directamente desde la tienda.
WooCommerce soporta los siguientes triggers nativos.
_rt5w45p0x2s6Creación de pedido
Este trigger se activa cada vez que se crea un pedido en la tienda WooCommerce, ya sea mediante una API o directamente desde la tienda.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4599,
"parent_id": 0,
"status": "pending",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T18:13:13",
"date_modified": "2023-04-14T18:13:13",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "175.00",
"total_tax": "0.00",
"customer_id": 4,
"order_key": "wc_order_yhGfOfZ0eoCYe",
"billing": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"state": "",
"postcode": "",
"country": "",
"email": "mark@onechat.com",
"phone": ""
},
"shipping": {
"first_name": "",
"last_name": "",
"company": "",
"address_1": "",
"address_2": "",
"city": "",
"state": "",
"postcode": "",
"country": "",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": null,
"date_paid": null,
"cart_hash": "",
"number": "4599",
"meta_data": [
],
"line_items": [
{
"id": 260,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 1,
"tax_class": "",
"subtotal": "175.00",
"subtotal_tax": "0.00",
"total": "175.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4599?pay_for_order=true&key=wc_order_yhGfOfZ0eoCYe",
"is_editable": true,
"needs_payment": true,
"needs_processing": true,
"date_created_gmt": "2023-04-14T18:13:13",
"date_modified_gmt": "2023-04-14T18:13:13",
"date_completed_gmt": null,
"date_paid_gmt": null,
"currency_symbol": "$"
} |
_z0auxqd7a11cActualización de pedido
Este trigger se activa cada vez que se actualiza un pedido en la tienda WooCommerce, ya sea mediante una API o directamente desde la tienda.
Se recibe la siguiente carga útil de respuesta.
| {
"id": 4597,
"parent_id": 0,
"status": "completed",
"currency": "AUD",
"version": "6.9.4",
"prices_include_tax": false,
"date_created": "2023-04-14T11:01:51",
"date_modified": "2023-04-14T18:16:14",
"discount_total": "0.00",
"discount_tax": "0.00",
"shipping_total": "0.00",
"shipping_tax": "0.00",
"cart_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"customer_id": 0,
"order_key": "wc_order_5hKQmDkxUiesi",
"billing": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"email": "hammadsiddiqui788@gmail.com",
"phone": "+9230302320964"
},
"shipping": {
"first_name": "Hammad",
"last_name": "Siddiqui",
"company": "",
"address_1": "ABC Road, Garden City",
"address_2": "",
"city": "Karachi",
"state": "Sindh",
"postcode": "",
"country": "Pakistan",
"phone": ""
},
"payment_method": "",
"payment_method_title": "",
"transaction_id": "",
"customer_ip_address": "",
"customer_user_agent": "",
"created_via": "rest-api",
"customer_note": "",
"date_completed": "2023-04-14T18:16:14",
"date_paid": "2023-04-14T18:16:14",
"cart_hash": "",
"number": "4597",
"meta_data": [
{
"id": 6465,
"key": "user_ns",
"value": "f12372u15376836"
},
{
"id": 6499,
"key": "_new_order_email_sent",
"value": "true"
}
],
"line_items": [
{
"id": 259,
"name": "DNK Black Shoes - blue",
"product_id": 375,
"variation_id": 4120,
"quantity": 2,
"tax_class": "",
"subtotal": "350.00",
"subtotal_tax": "0.00",
"total": "350.00",
"total_tax": "0.00",
"taxes": [...], // 0 items
"meta_data": [...], // 1 items
"sku": "",
"price": 175,
"image": {...}, // 2 keys
"parent_name": "DNK Black Shoes"
}
],
"tax_lines": [
],
"shipping_lines": [
],
"fee_lines": [
],
"coupon_lines": [
],
"refunds": [
],
"payment_url": "https://shop.businessautomated.io/checkout-2/order-pay/4597?pay_for_order=true&key=wc_order_5hKQmDkxUiesi",
"is_editable": false,
"needs_payment": false,
"needs_processing": true,
"date_created_gmt": "2023-04-14T11:01:51",
"date_modified_gmt": "2023-04-14T18:16:14",
"date_completed_gmt": "2023-04-14T18:16:14",
"date_paid_gmt": "2023-04-14T18:16:14",
"currency_symbol": "$"
} |
_cpfq07vdhe4rCreación de usuario usando triggers
OneChat identifica la información que llega desde la carga útil del trigger y la compara con los usuarios existentes del bot. Si la encuentra, el flujo se ejecuta para ese usuario. Si no se encuentra al usuario, entonces se crea uno usando la información incluida en la carga útil.
Si tanto el correo electrónico como el teléfono están disponibles, entonces se crea un usuario en el canal Web; si solo está disponible el correo electrónico, el usuario igualmente se crea en el canal Web. Si solo está disponible el teléfono, entonces el usuario se crea en el canal Whatsapp.
Si la información mínima requerida anterior no llega en la carga útil, entonces el trigger no puede identificar ni crear un usuario y, por lo tanto, no se activa.
Configurar una automatización de carrito abandonado de WooCommerce para enviar un mensaje de WhatsApp
WooCommerce no soporta un trigger nativo de carrito abandonado; sin embargo, con plugins gratuitos junto con OneChat, puedes crear tu propio flujo de carrito abandonado en unos pocos pasos simples.
Instalación del plugin
Una vez que hayas iniciado sesión, desde tu panel de WooCommerce desplázate hacia abajo hasta ver la pestaña de plugins en el menú lateral izquierdo.
Haz clic en **"Add new plugin"** y escribe **"cart"** en la barra de búsqueda. Ahora tendrás múltiples plugins para elegir; para esta documentación usaremos **Cartflows**.
Una vez instalado, actualiza la página y vuelve al panel.
Integración del plugin con OneChat
Desde tu panel, haz clic en la pestaña de WooCommerce y luego ve a **Cart abandonment**.
Haz clic en la pestaña **Settings**.
Desde aquí, vamos a configurar los ajustes para el trigger.
Primero, vamos a configurar el intervalo del trigger; para este plugin en particular, el mínimo que puedes usar es 10 minutos.
También asegúrate de que **Enable Tracking** esté activado.
Desplázate hacia abajo hasta ver la configuración de webhook, activa **Enable webhook** y pega el webhook entrante que puedes crear dentro de OneChat en el campo URL de abajo:
Haz clic en **trigger sample** para asegurarte de que estás recibiendo la carga útil. Una vez hecho esto, desplázate hacia abajo y haz clic en **"Save Changes"**.
Realizar un pedido y abandonar el carrito
Ve a tu tienda WooCommerce, agrega un producto al carrito, continúa al checkout y abandona la página después de ingresar los datos de facturación.
No completes el pedido. Como configuramos el trigger para activarse después de 10 minutos, no esperaremos 10 minutos para recibir la carga útil en nuestro webhook entrante dentro de OneChat.
Configuración del Webhook entrante
Dentro de OneChat, ve a tools e inbound webhook, y haz clic en **Edit** frente al webhook que elegiste para la configuración del carrito abandonado.
Espera 10 minutos y luego haz clic en **"Listen to payload"**.
Haz clic en **done**. Y previsualiza la carga útil. Mapea todos los valores necesarios de la carga útil recibida.
Nota: Asegúrate de que tu número de teléfono esté en el formato correcto e incluya el código de país; de lo contrario, causará problemas. El formato puede configurarse dentro de WooCommerce, o también podemos usar preprocesamiento de datos para formatearlo manualmente mediante código Javascript.
Una vez hecho esto, conecta el webhook al flujo que prefieras.
Configuración del flujo
Ve a **Contents** y luego a **Whatsapp templates**. Y asegúrate de tener una plantilla para carritos abandonados. Si no, puedes crear una dentro de OneChat y hacer que sea aprobada.
Ve a **flow builder** y configura la plantilla de la siguiente manera:
Una vez hecho esto, ya está listo. Puedes abandonar otro carrito y probar el flujo.