<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>thread Diagnosing INVALID_REQUEST_ERROR in Archived Discussions (Read Only)</title>
    <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6643#M95186</link>
    <description>&lt;P&gt;Submitting a V2 API request to:&lt;BR /&gt;url = &lt;A href="https://connect.squareup.com/v2/CBASEMVn_aQuXyMe93tfKwApGPM/transactions" target="_blank"&gt;https://connect.squareup.com/v2/CBASEMVn_aQuXyMe93tfKwApGPM/transactions&lt;/A&gt;&lt;BR /&gt;with POSTed data of:&lt;BR /&gt;{&lt;BR /&gt;"idempotency_key": "91750",&lt;BR /&gt;"billing_address": {&lt;BR /&gt;"address_line_1": "4433 SW 48th AV",&lt;BR /&gt;"address_line_2": "",&lt;BR /&gt;"locality": "Portland",&lt;BR /&gt;"administrative_district_level_1": "OR",&lt;BR /&gt;"postal_code": "97221",&lt;BR /&gt;"country": "US"&lt;BR /&gt;},&lt;BR /&gt;"amount_money": {&lt;BR /&gt;"amount": 10,&lt;BR /&gt;"currency": "USD"&lt;BR /&gt;},&lt;BR /&gt;"card_nonce": "CBASEJuQWW4DsEFg1N2io4fYB1Q",&lt;BR /&gt;"delay_capture": false,&lt;BR /&gt;"buyer_email_address": "support@example.com"&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;Generates an INVALID_REQUEST_ERROR.&lt;BR /&gt;&lt;BR /&gt;How do I find details about specifically what it is seeing wrong with this request? According to the documentation this should be a valid request.&lt;/P&gt;</description>
    <pubDate>Sat, 11 Jun 2016 22:01:20 GMT</pubDate>
    <dc:creator>ezms</dc:creator>
    <dc:date>2016-06-11T22:01:20Z</dc:date>
    <item>
      <title>Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6643#M95186</link>
      <description>&lt;P&gt;Submitting a V2 API request to:&lt;BR /&gt;url = &lt;A href="https://connect.squareup.com/v2/CBASEMVn_aQuXyMe93tfKwApGPM/transactions" target="_blank"&gt;https://connect.squareup.com/v2/CBASEMVn_aQuXyMe93tfKwApGPM/transactions&lt;/A&gt;&lt;BR /&gt;with POSTed data of:&lt;BR /&gt;{&lt;BR /&gt;"idempotency_key": "91750",&lt;BR /&gt;"billing_address": {&lt;BR /&gt;"address_line_1": "4433 SW 48th AV",&lt;BR /&gt;"address_line_2": "",&lt;BR /&gt;"locality": "Portland",&lt;BR /&gt;"administrative_district_level_1": "OR",&lt;BR /&gt;"postal_code": "97221",&lt;BR /&gt;"country": "US"&lt;BR /&gt;},&lt;BR /&gt;"amount_money": {&lt;BR /&gt;"amount": 10,&lt;BR /&gt;"currency": "USD"&lt;BR /&gt;},&lt;BR /&gt;"card_nonce": "CBASEJuQWW4DsEFg1N2io4fYB1Q",&lt;BR /&gt;"delay_capture": false,&lt;BR /&gt;"buyer_email_address": "support@example.com"&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;Generates an INVALID_REQUEST_ERROR.&lt;BR /&gt;&lt;BR /&gt;How do I find details about specifically what it is seeing wrong with this request? According to the documentation this should be a valid request.&lt;/P&gt;</description>
      <pubDate>Sat, 11 Jun 2016 22:01:20 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6643#M95186</guid>
      <dc:creator>ezms</dc:creator>
      <dc:date>2016-06-11T22:01:20Z</dc:date>
    </item>
    <item>
      <title>Re: Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6754#M95187</link>
      <description>&lt;P&gt;Seems I was missing the '/locations' path element in the URL&lt;/P&gt;</description>
      <pubDate>Thu, 09 Jun 2016 20:36:24 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6754#M95187</guid>
      <dc:creator>ezms</dc:creator>
      <dc:date>2016-06-09T20:36:24Z</dc:date>
    </item>
    <item>
      <title>Re: Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6758#M95188</link>
      <description>&lt;P&gt;Sorry I didn't catch your post yesterday, glad you found it!&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;Let us know if anything else comes up, I can pass it to our developers if need be.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Jun 2016 21:10:21 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/6758#M95188</guid>
      <dc:creator>Spenser</dc:creator>
      <dc:date>2016-06-09T21:10:21Z</dc:date>
    </item>
    <item>
      <title>Re: Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22919#M95189</link>
      <description>Hi,
Having a real problem getting the api v2 working. How do I turn on debugging to see what is or is not being posted correctly within the sandbox? I am using php (process-card.php)?
I was able to turn on debug within connect:

[DEBUG] HTTP Request body &amp;nbsp;~BEGIN~
{"card_nonce":"CBASEGre99XsFfF8K81884vyzT0","amount_money":{"amount":100,"currency":"USD"},"idempotency_key":"581c1b872605a"}
~END~
* About to connect() to connect.squareup.com port 443 (#0)
* &amp;nbsp; Trying 74.122.189.136... * connected
* Connected to connect.squareup.com (74.122.189.136) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
* &amp;nbsp; CAfile: /etc/pki/tls/certs/ca-bundle.crt
&amp;nbsp; CApath: none
* SSL connection using TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
* Server certificate:
* 	subject: CN=*.squareup.com,O="Square, Inc.",L=San Francisco,ST=California,C=US
* 	start date: Dec 02 17:16:03 2015 GMT
* 	expire date: Dec 16 17:46:01 2016 GMT
* 	common name: *.squareup.com
* 	issuer: CN=Entrust Certification Authority - L1K,OU="(c) 2012 Entrust, Inc. - for authorized use only",OU=See &lt;A href="http://www.entrust.net/legal-terms,O=&amp;quot;Entrust" target="_blank"&gt;www.entrust.net/legal-terms,O="Entrust&lt;/A&gt;, Inc.",C=US
&amp;gt; POST /v2/locations/%7B%0A%20%20%22locations%22%3A%20%5B%0A%20%20%20%20%7B%0A%20%20%20%20%20%20%22id%22%3A%20%2218YC4JDH91E1H%22%2C%0A%20%20%20%20%20%20%22name%22%3A%20%22your%20location%20name%22%2C%0A%20%20%20%20%20%20%22address%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%22address_line_1%22%3A%20%22123%20Main%20St%22%2C%0A%20%20%20%20%20%20%20%20%22locality%22%3A%20%22San%20Francisco%22%2C%0A%20%20%20%20%20%20%20%20%22administrative_district_level_1%22%3A%20%22CA%22%2C%0A%20%20%20%20%20%20%20%20%22postal_code%22%3A%20%2294114%22%2C%0A%20%20%20%20%20%20%20%20%22country%22%3A%20%22US%22%0A%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%22timezone%22%3A%20%22America%2FLos_Angeles%22%2C%0A%20%20%20%20%20%20%22capabilities%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%22CREDIT_CARD_PROCESSING%22%0A%20%20%20%20%20%20%5D%0A%20%20%20%20%7D%0A%20%20%5D%0A%7D/transactions HTTP/1.1
User-Agent: Square-Connect-PHP/2.0.0.1
Host: connect.squareup.com
Accept: application/json
Content-Type: application/json
Authorization: Bearer sandbox-xxxxxxxxxxxxxxxxx
Content-Length: 125

&amp;lt; HTTP/1.1 404 Not Found
&amp;lt; Content-Type: application/json
&amp;lt; Vary: Origin, Accept-Encoding
&amp;lt; X-Content-Type-Options: nosniff
&amp;lt; X-Download-Options: noopen
&amp;lt; X-Frame-Options: SAMEORIGIN
&amp;lt; X-Permitted-Cross-Domain-Policies: none
&amp;lt; X-Xss-Protection: 1; mode=block
&amp;lt; Date: Fri, 04 Nov 2016 05:24:23 GMT
&amp;lt; Keep-Alive: timeout=60
&amp;lt; Strict-Transport-Security: max-age=631152000
&amp;lt; content-length: 648
&amp;lt;&amp;nbsp;
* Connection #0 to host connect.squareup.com left intact
[DEBUG] HTTP Response body ~BEGIN~
{"errors":[{"category":"INVALID_REQUEST_ERROR","code":"NOT_FOUND","detail":"API endpoint for URL path `/v2/locations/{\n &amp;nbsp;\"locations\": [\n &amp;nbsp; &amp;nbsp;{\n &amp;nbsp; &amp;nbsp; &amp;nbsp;\"id\": \"18YC4JDH91E1H\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp;\"name\": \"your location name\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp;\"address\": {\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"address_line_1\": \"123 Main St\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"locality\": \"San Francisco\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"administrative_district_level_1\": \"CA\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"postal_code\": \"94114\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"country\": \"US\"\n &amp;nbsp; &amp;nbsp; &amp;nbsp;},\n &amp;nbsp; &amp;nbsp; &amp;nbsp;\"timezone\": \"America/Los_Angeles\",\n &amp;nbsp; &amp;nbsp; &amp;nbsp;\"capabilities\": [\n &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;\"CREDIT_CARD_PROCESSING\"\n &amp;nbsp; &amp;nbsp; &amp;nbsp;]\n &amp;nbsp; &amp;nbsp;}\n &amp;nbsp;]\n}/transactions` and HTTP method `POST` is not found."}]}
~END~
* Closing connection #0

Of course I am using a bogus Location as well

Thanks,
Larry</description>
      <pubDate>Fri, 04 Nov 2016 05:53:39 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22919#M95189</guid>
      <dc:creator>lhughes33472</dc:creator>
      <dc:date>2016-11-04T05:53:39Z</dc:date>
    </item>
    <item>
      <title>Re: Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22988#M95190</link>
      <description>&lt;P&gt;What kind of debugging are you interested in? It seems like your error is that you are adding things as url parameters instead of a POST body. Doest that help?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Nov 2016 00:20:45 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22988#M95190</guid>
      <dc:creator>tristansokol</dc:creator>
      <dc:date>2016-11-05T00:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: Diagnosing INVALID_REQUEST_ERROR</title>
      <link>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22994#M95191</link>
      <description>Hi,
&amp;nbsp;
I am using php and followed all the instructions here at:
&lt;A href="https://github.com/square/connect-api-examples/tree/master/connect-examples/v2/php_payment" target="_blank"&gt;https://github.com/square/connect-api-examples/tree/master/connect-examples/v2/php_payment&lt;/A&gt;
&amp;nbsp;
And it does not work as stated.
So I turned on debug in /vendor/square/connect/lib/Configuration.php
to see if i could find out why this doesn't work and all I get INVALID_REQUEST_ERROR.
&amp;nbsp;
Any help would be great.
&amp;nbsp;
Thanks,
Larry</description>
      <pubDate>Sat, 05 Nov 2016 00:52:23 GMT</pubDate>
      <guid>https://community.squareup.com/t5/Archived-Discussions-Read-Only/Diagnosing-INVALID-REQUEST-ERROR/m-p/22994#M95191</guid>
      <dc:creator>lhughes33472</dc:creator>
      <dc:date>2016-11-05T00:52:23Z</dc:date>
    </item>
  </channel>
</rss>

