I am trying to GET all my WooCommerce products using this URL address: https://svetvramu.cz/wp-json/wc/v2/products
(using official documentation https://woocommerce.github.io/woocommerce-rest-api-docs/wp-api-v2.html#list-all-products).
The same URL address using Make.com for the connection establishing (as you can see below – screenshot and whole request).
{
"message": "Požadavek se nepodařilo dokončit vzhledem k chybě předchozího požadavku.",
"code": "SC424",
"suberrors": [
{
"message": "Status Code Error: 500",
"name": "RuntimeError"
}
],
"debug": [
[
"woocommerce2:",
"request",
"GET",
"https://svetvramu.cz/wp-json/wc/v2/products",
{
"qs": {
"consumer_key": "***",
"consumer_secret": "***"
},
"headers": {
"user-agent": "Make/production"
},
"timeout": 40000
}
],
[
"woocommerce2:",
"response",
500,
{
"body": "<!DOCTYPE html>n<html lang="cs">n<head>nt<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />nt<meta name="viewport" content="width=device-width">ntt<meta name='robots' content='max-image-preview:large, noindex, follow' />nt<title>WordPress › Chyba</title>nt<style type="text/css">ntthtml {ntttbackground: #f1f1f1;ntt}nttbody {ntttbackground: #fff;ntttborder: 1px solid #ccd0d4;ntttcolor: #444;ntttfont-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;ntttmargin: 2em auto;ntttpadding: 1em 2em;ntttmax-width: 700px;nttt-webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, .04);ntttbox-shadow: 0 1px 1px rgba(0, 0, 0, .04);ntt}ntth1 {ntttborder-bottom: 1px solid #dadada;ntttclear: both;ntttcolor: #666;ntttfont-size: 24px;ntttmargin: 30px 0 0 0;ntttpadding: 0;ntttpadding-bottom: 7px;ntt}ntt#error-page {ntttmargin-top: 50px;ntt}ntt#error-page p,ntt#error-page .wp-die-message {ntttfont-size: 14px;ntttline-height: 1.5;ntttmargin: 25px 0 20px;ntt}ntt#error-page code {ntttfont-family: Consolas, Monaco, monospace;ntt}nttul li {ntttmargin-bottom: 10px;ntttfont-size: 14px ;ntt}ntta {ntttcolor: #2271b1;ntt}ntta:hover,ntta:active {ntttcolor: #135e96;ntt}ntta:focus {ntttcolor: #043959;ntttbox-shadow: 0 0 0 2px #2271b1;ntttoutline: 2px solid transparent;ntt}ntt.button {ntttbackground: #f3f5f6;ntttborder: 1px solid #016087;ntttcolor: #016087;ntttdisplay: inline-block;nttttext-decoration: none;ntttfont-size: 13px;ntttline-height: 2;ntttheight: 28px;ntttmargin: 0;ntttpadding: 0 10px 1px;ntttcursor: pointer;nttt-webkit-border-radius: 3px;nttt-webkit-appearance: none;ntttborder-radius: 3px;ntttwhite-space: nowrap;nttt-webkit-box-sizing: border-box;nttt-moz-box-sizing: border-box;ntttbox-sizing: border-box;nntttvertical-align: top;ntt}nntt.button.button-large {ntttline-height: 2.30769231;ntttmin-height: 32px;ntttpadding: 0 12px;ntt}nntt.button:hover,ntt.button:focus {ntttbackground: #f1f1f1;ntt}nntt.button:focus {ntttbackground: #f3f5f6;ntttborder-color: #007cba;nttt-webkit-box-shadow: 0 0 0 1px #007cba;ntttbox-shadow: 0 0 0 1px #007cba;ntttcolor: #016087;ntttoutline: 2px solid transparent;ntttoutline-offset: 0;ntt}nntt.button:active {ntttbackground: #f3f5f6;ntttborder-color: #7e8993;nttt-webkit-box-shadow: none;ntttbox-shadow: none;ntt}nnttt</style>n</head>n<body id="error-page">nt<div class="wp-die-message"><p>Na webu došlo k závažné chybě.</p><p><a href="https://wordpress.org/documentation/article/faq-troubleshooting/">Další informace o řešení potíží s WordPressem.</a></p></div></body>n</html>nt",
"headers": {
"date": "Tue, 16 Jul 2024 12:44:31 GMT",
"server": "Apache",
"x-robots-tag": "noindex",
"link": "<https://svetvramu.cz/wp-json/>; rel="https://api.w.org/"",
"x-content-type-options": "nosniff",
"access-control-expose-headers": "X-WP-Total, X-WP-TotalPages, Link",
"access-control-allow-headers": "Authorization, X-WP-Nonce, Content-Disposition, Content-MD5, Content-Type",
"expires": "Wed, 11 Jan 1984 05:00:00 GMT",
"cache-control": "no-cache, must-revalidate, max-age=0, no-store, private",
"vary": "User-Agent",
"upgrade": "h2,h2c",
"connection": "Upgrade, close",
"content-security-policy": "upgrade-insecure-requests;",
"transfer-encoding": "chunked",
"content-type": "text/html; charset=UTF-8"
}
}
]
]
}
I have tried the same GET https://svetvramu.cz/wp-json/wc/v2/products
request via Postman – the result is the same (error 500). If I use any specific ID of the product (https://svetvramu.cz/wp-json/wc/v2/products/2
, the result is still same.
{
"code": "internal_server_error",
"message": "<p>Na webu došlo k závažné chybě.</p><p><a href="https://wordpress.org/documentation/article/faq-troubleshooting/">Další informace o řešení potíží s WordPressem.</a></p>",
"data": {
"status": 500
},
"additional_errors": []
}
For example, GET on URL https://svetvramu.cz/wp-json/wc/v2/orders
works well (200 OK, I see created orders).
Do you have any idea what can be the reason of 500 error? I will really appreciate any help.