Skip to content

Instantly share code, notes, and snippets.

@Bradisswag
Last active October 17, 2021 23:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Bradisswag/fcda76a13d22f421b660f863476076e6 to your computer and use it in GitHub Desktop.
Save Bradisswag/fcda76a13d22f421b660f863476076e6 to your computer and use it in GitHub Desktop.
2021-10-17T23:56:29+00:00 DEBUG
====Laybuy Version: 5.3.4====
====Start Log====
Failed to parse Laybuy response: array (
'headers' =>
Requests_Utility_CaseInsensitiveDictionary::__set_state(array(
'data' =>
array (
'date' => 'Sun, 17 Oct 2021 23:56:29 GMT',
'content-type' => 'text/html; charset=UTF-8',
'x-frame-options' => 'SAMEORIGIN',
'referrer-policy' => 'same-origin',
'cache-control' => 'private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0',
'expires' => 'Thu, 01 Jan 1970 00:00:01 GMT',
'expect-ct' => 'max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"',
'vary' => 'Accept-Encoding',
'server' => 'cloudflare',
'cf-ray' => '69fd76b94c545343-LAX',
'content-encoding' => 'gzip',
),
)),
'body' => '<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en-US"> <![endif]-->
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="en-US"> <![endif]-->
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="en-US"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en-US"> <!--<![endif]-->
<head>
<title>Access denied | api.laybuy.com used Cloudflare to restrict access</title>
<meta charset="UTF-8" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
<meta name="robots" content="noindex, nofollow" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<link rel="stylesheet" id="cf_styles-css" href="/cdn-cgi/styles/main.css" type="text/css" media="screen,projection" />
<script defer src="https://api.radar.cloudflare.com/beacon.js"></script>
</head>
<body>
<div id="cf-wrapper">
<div class="cf-alert cf-alert-error cf-cookie-error hidden" id="cookie-alert" data-translate="enable_cookies">Please enable cookies.</div>
<div id="cf-error-details" class="p-0">
<header class="mx-auto pt-10 lg:pt-6 lg:px-8 w-240 lg:w-full mb-15 antialiased">
<h1 class="inline-block md:block mr-2 md:mb-2 font-light text-60 md:text-3xl text-black-dark leading-tight">
<span data-translate="error">Error</span>
<span>1020</span>
</h1>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">Ray ID: 69fd76b94c545343 &bull;</span>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">2021-10-17 23:56:29 UTC</span>
<h2 class="text-gray-600 leading-1.3 text-3xl lg:text-2xl font-light">Access denied</h2>
</header>
<section class="w-240 lg:w-full mx-auto mb-8 lg:px-8">
<div id="what-happened-section" class="w-1/2 md:w-full">
<h2 class="text-3xl leading-tight font-normal mb-4 text-black-dark antialiased" data-translate="what_happened">What happened?</h2>
<p>This website is using a security service to protect itself from online attacks.</p>
</div>
</section>
<div class="cf-error-footer cf-wrapper w-240 lg:w-full py-10 sm:py-4 sm:px-8 mx-auto text-center sm:text-left border-solid border-0 border-t border-gray-300">
<p class="text-13">
<span class="cf-footer-item sm:block sm:mb-1">Cloudflare Ray ID: <strong class="font-semibold">69fd76b94c545343</strong></span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Your IP</span>: 2a02:4780:b::6</span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Performance &amp; security by</span> <a rel="noopener noreferrer" href="https://www.cloudflare.com/5xx-error-landing" id="brand_link" target="_blank">Cloudflare</a></span>
</p>
</div><!-- /.error-footer -->
</div><!-- /#cf-error-details -->
</div><!-- /#cf-wrapper -->
<script type="text/javascript">
window._cf_translation = {};
</script>
</body>
</html>
',
'response' =>
array (
'code' => 403,
'message' => 'Forbidden',
),
'cookies' =>
array (
),
'filename' => NULL,
'http_response' =>
WP_HTTP_Requests_Response::__set_state(array(
'response' =>
Requests_Response::__set_state(array(
'body' => '<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en-US"> <![endif]-->
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="en-US"> <![endif]-->
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="en-US"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en-US"> <!--<![endif]-->
<head>
<title>Access denied | api.laybuy.com used Cloudflare to restrict access</title>
<meta charset="UTF-8" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
<meta name="robots" content="noindex, nofollow" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<link rel="stylesheet" id="cf_styles-css" href="/cdn-cgi/styles/main.css" type="text/css" media="screen,projection" />
<script defer src="https://api.radar.cloudflare.com/beacon.js"></script>
</head>
<body>
<div id="cf-wrapper">
<div class="cf-alert cf-alert-error cf-cookie-error hidden" id="cookie-alert" data-translate="enable_cookies">Please enable cookies.</div>
<div id="cf-error-details" class="p-0">
<header class="mx-auto pt-10 lg:pt-6 lg:px-8 w-240 lg:w-full mb-15 antialiased">
<h1 class="inline-block md:block mr-2 md:mb-2 font-light text-60 md:text-3xl text-black-dark leading-tight">
<span data-translate="error">Error</span>
<span>1020</span>
</h1>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">Ray ID: 69fd76b94c545343 &bull;</span>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">2021-10-17 23:56:29 UTC</span>
<h2 class="text-gray-600 leading-1.3 text-3xl lg:text-2xl font-light">Access denied</h2>
</header>
<section class="w-240 lg:w-full mx-auto mb-8 lg:px-8">
<div id="what-happened-section" class="w-1/2 md:w-full">
<h2 class="text-3xl leading-tight font-normal mb-4 text-black-dark antialiased" data-translate="what_happened">What happened?</h2>
<p>This website is using a security service to protect itself from online attacks.</p>
</div>
</section>
<div class="cf-error-footer cf-wrapper w-240 lg:w-full py-10 sm:py-4 sm:px-8 mx-auto text-center sm:text-left border-solid border-0 border-t border-gray-300">
<p class="text-13">
<span class="cf-footer-item sm:block sm:mb-1">Cloudflare Ray ID: <strong class="font-semibold">69fd76b94c545343</strong></span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Your IP</span>: 2a02:4780:b::6</span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Performance &amp; security by</span> <a rel="noopener noreferrer" href="https://www.cloudflare.com/5xx-error-landing" id="brand_link" target="_blank">Cloudflare</a></span>
</p>
</div><!-- /.error-footer -->
</div><!-- /#cf-error-details -->
</div><!-- /#cf-wrapper -->
<script type="text/javascript">
window._cf_translation = {};
</script>
</body>
</html>
',
'raw' => 'HTTP/1.1 403 Forbidden
Date: Sun, 17 Oct 2021 23:56:29 GMT
Content-Type: text/html; charset=UTF-8
Transfer-Encoding: chunked
Connection: close
X-Frame-Options: SAMEORIGIN
Referrer-Policy: same-origin
Cache-Control: private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Expect-CT: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
Vary: Accept-Encoding
Server: cloudflare
CF-RAY: 69fd76b94c545343-LAX
Content-Encoding: gzip
<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en-US"> <![endif]-->
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="en-US"> <![endif]-->
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="en-US"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en-US"> <!--<![endif]-->
<head>
<title>Access denied | api.laybuy.com used Cloudflare to restrict access</title>
<meta charset="UTF-8" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
<meta name="robots" content="noindex, nofollow" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<link rel="stylesheet" id="cf_styles-css" href="/cdn-cgi/styles/main.css" type="text/css" media="screen,projection" />
<script defer src="https://api.radar.cloudflare.com/beacon.js"></script>
</head>
<body>
<div id="cf-wrapper">
<div class="cf-alert cf-alert-error cf-cookie-error hidden" id="cookie-alert" data-translate="enable_cookies">Please enable cookies.</div>
<div id="cf-error-details" class="p-0">
<header class="mx-auto pt-10 lg:pt-6 lg:px-8 w-240 lg:w-full mb-15 antialiased">
<h1 class="inline-block md:block mr-2 md:mb-2 font-light text-60 md:text-3xl text-black-dark leading-tight">
<span data-translate="error">Error</span>
<span>1020</span>
</h1>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">Ray ID: 69fd76b94c545343 &bull;</span>
<span class="inline-block md:block heading-ray-id font-mono text-15 lg:text-sm lg:leading-relaxed">2021-10-17 23:56:29 UTC</span>
<h2 class="text-gray-600 leading-1.3 text-3xl lg:text-2xl font-light">Access denied</h2>
</header>
<section class="w-240 lg:w-full mx-auto mb-8 lg:px-8">
<div id="what-happened-section" class="w-1/2 md:w-full">
<h2 class="text-3xl leading-tight font-normal mb-4 text-black-dark antialiased" data-translate="what_happened">What happened?</h2>
<p>This website is using a security service to protect itself from online attacks.</p>
</div>
</section>
<div class="cf-error-footer cf-wrapper w-240 lg:w-full py-10 sm:py-4 sm:px-8 mx-auto text-center sm:text-left border-solid border-0 border-t border-gray-300">
<p class="text-13">
<span class="cf-footer-item sm:block sm:mb-1">Cloudflare Ray ID: <strong class="font-semibold">69fd76b94c545343</strong></span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Your IP</span>: 2a02:4780:b::6</span>
<span class="cf-footer-separator sm:hidden">&bull;</span>
<span class="cf-footer-item sm:block sm:mb-1"><span>Performance &amp; security by</span> <a rel="noopener noreferrer" href="https://www.cloudflare.com/5xx-error-landing" id="brand_link" target="_blank">Cloudflare</a></span>
</p>
</div><!-- /.error-footer -->
</div><!-- /#cf-error-details -->
</div><!-- /#cf-wrapper -->
<script type="text/javascript">
window._cf_translation = {};
</script>
</body>
</html>
',
'headers' =>
Requests_Response_Headers::__set_state(array(
'data' =>
array (
'date' =>
array (
0 => 'Sun, 17 Oct 2021 23:56:29 GMT',
),
'content-type' =>
array (
0 => 'text/html; charset=UTF-8',
),
'x-frame-options' =>
array (
0 => 'SAMEORIGIN',
),
'referrer-policy' =>
array (
0 => 'same-origin',
),
'cache-control' =>
array (
0 => 'private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0',
),
'expires' =>
array (
0 => 'Thu, 01 Jan 1970 00:00:01 GMT',
),
'expect-ct' =>
array (
0 => 'max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"',
),
'vary' =>
array (
0 => 'Accept-Encoding',
),
'server' =>
array (
0 => 'cloudflare',
),
'cf-ray' =>
array (
0 => '69fd76b94c545343-LAX',
),
'content-encoding' =>
array (
0 => 'gzip',
),
),
)),
'status_code' => 403,
'protocol_version' => 1.1,
'success' => false,
'redirects' => 0,
'url' => 'https://api.laybuy.com/order/create',
'history' =>
array (
),
'cookies' =>
Requests_Cookie_Jar::__set_state(array(
'cookies' =>
array (
),
)),
)),
'filename' => NULL,
'data' => NULL,
'headers' => NULL,
'status' => NULL,
)),
)
====End Log====
2021-10-17T23:56:29+00:00 DEBUG
====Laybuy Version: 5.3.4====
====Start Log====
Error: Laybuy_ApiGateway::createOrder() returned -2 (Laybuy did not provide a token for this order.)
====End Log====
2021-10-17T23:56:29+00:00 DEBUG
====Laybuy Version: 5.3.4====
====Start Log====
Error: API Payload: Array
(
[amount] => 50.20
[returnUrl] => https://cakeandsugarart.co.nz/?gateway_id=wc-laybuy&quote_id=45605&post_type=laybuy_quote&_wpnonce=7f990df2cf&compatibility=1
[merchantReference] => #616cb82cebd28456051634514988
[customer] => Array
(
[firstName] => Brad
[lastName] => Cade
[email] => bradley@southcityelectrical.co.nz
[phone] => 0274732879
)
[billingAddress] => Array
(
[address1] => 146 Clyde Street
[city] => Invercargill
[postcode] => 9810
[country] => NZ
)
[items] => Array
(
[0] => Array
(
[id] => shipping_fee_for_order#45605
[description] => Shipping fee for this order
[quantity] => 1
[price] => 8
)
[1] => Array
(
[id] => item_for_order___#45605
[description] => Purchase from Cake and Sugar Art
[quantity] => 1
[price] => 42.2
)
)
[tax] => 0
)
====End Log====
2021-10-17T23:56:29+00:00 DEBUG
====Laybuy Version: 5.3.4====
====Start Log====
Error: API Response: false
====End Log====
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment