Is Paypal Sandbox offline? - paypal

Sorry for asking here, but this is a bit of an emergency and I know from past experience, it could take more than 7 days to get a response from Paypal.
I am working on a project that, about 10 days ago, was working fine. 2 Days ago I returned to the PP portion and all of a sudden, I am getting no response from Paypal.
This is the URL I am calling:
https://api.sandbox.paypal.com/v1/payments/payment
And absolutely no response is being returned. I'm certain that before it at least returned an error if no parameters are included. But now, nothing at all with or without parameters.

Paypal does have a status page for the live site. Not sure if it still extends to the sandbox, tho. There was a major outage on the live end yesterday.
Which API are you using?

Do you still have issues with this? It's working fine for me. I don't believe we had an outage either.
$ curl -v https://api.sandbox.paypal.com/v1/payments/payment
* About to connect() to api.sandbox.paypal.com port 443 (#0)
* Trying 23.43.75.39...
* connected
* Connected to api.sandbox.paypal.com (23.43.75.39) port 443 (#0)
*a lot of SSL stuff*
> GET /v1/payments/payment HTTP/1.1
> User-Agent: curl/7.28.1
> Host: api.sandbox.paypal.com
> Accept: */*
>
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 401 Unauthorized
< Server: Apache-Coyote/1.1
< Paypal-Debug-Id: 7177ce39c4142
< Content-Type: application/json
< Content-Length: 0
< DC: origin1-api.sandbox.paypal.com
< Date: Sun, 03 Nov 2013 12:07:31 GMT
< Connection: keep-alive
< Set-Cookie: DC=origin1-api.sandbox.paypal.com; secure
<
* Connection #0 to host api.sandbox.paypal.com left intact
* Closing connection #0
* SSLv3, TLS alert, Client hello (1):
Note the HTTP 401 response (because I didn't specify a valid Authorization header with an access token for the request).

Related

Filter by hostname is not working in my WireShark

I am using RESTFul client Insomnia to test my GET request.
I get 500 internal server error as shown below
* Preparing request to https://sample.azure-api.net/masterData/carTypes
* Using libcurl/7.57.0-DEV OpenSSL/1.0.2o zlib/1.2.11 libssh2/1.7.0_DEV
* Current time is 2019-08-30T05:03:09.029Z
* Disable timeout
* Enable automatic URL encoding
* Enable SSL validation
* Enable cookie sending with jar of 0 cookies
* Found bundle for host sample.azure-api.net: 0x205d69260b0 [can pipeline]
* Re-using existing connection! (#7) with host sample.azure-api.net
* Connected to sample.azure-api.net (XX.XXX.XXX.XX) port 443 (#7)
> GET /masterData/carTypes HTTP/1.1
> Host: sample.azure-api.net
> User-Agent: insomnia/6.6.2
> Accept: */*
< HTTP/1.1 500 Internal Server Error
< Content-Length: 111
< Content-Type: application/json
< Date: Fri, 30 Aug 2019 05:03:09 GMT
To troubleshoot, I opened wireshark, selected Ethernet2 interface and started to capture the traffic. also added a filter as follow
http.host == "sample.azure-api.net"
But I do not see any traffic filtered when I apply the above filter.
But when I try to filter like IP Destination, I get to see the traffic.
ip.dst == XX.XXX.XXX.XX && tcp.port == 443
Why filter by hostname is not working?
What I am trying to solve? Root Issue
When I try same request from c# code using rest client, I get below error
{"The request was aborted: Could not create SSL/TLS secure channel."}
So basically I am trying to find where exactly is request is failing!

Facebook Object Debugger Error 502 and Error parsing input URL

Well, this website uses AWS EC2, and right now when i shared the site on Facebook, facebook don't show nothing, but yesterday it work well.
Right now the Facebook lint(object debugger) says
Error parsing input URL, no data was cached, or no data was scraped.
And
Curl Error : RECV_ERROR Received HTTP code 502 from proxy after
CONNECT
But when i use curl via terminal on my Mac (like curl -v -X TRACE www.cuinzy.com) this return:
* Rebuilt URL to: www.cuinzy.com/
* Hostname was NOT found in DNS cache
* Trying 54.207.48.99...
* Connected to www.cuinzy.com (127.0.0.1) port 80 (#0)
> TRACE / HTTP/1.1
> User-Agent: curl/7.37.1
> Host: www.cuinzy.com
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Mon, 17 Aug 2015 10:14:36 GMT
* Server Apache is not blacklisted
< Server: Apache
< Connection: close
< Transfer-Encoding: chunked
< Content-Type: message/http
<
TRACE / HTTP/1.1
User-Agent: curl/7.37.1
Host: www.cuinzy.com
Accept: */*
* Closing connection 0
Curl return response code 200 on www.cuinzy.com, and if try with url https://www.cuinzy.com/itm/572-aumento-natural-del-busto-pueraria-mirifica-100-x-500mg.html, this return:
* Hostname was NOT found in DNS cache
* Trying 54.207.48.99...
* Connected to www.cuinzy.com (127.0.0.1) port 443 (#0)
* TLS 1.2 connection using TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384
* Server certificate: *.cuinzy.com
* Server certificate: COMODO RSA Domain Validation Secure Server CA
* Server certificate: COMODO RSA Certification Authority
* Server certificate: AddTrust External CA Root
> TRACE /itm/572-aumento-natural-del-busto-pueraria-mirifica-100-x-500mg.html HTTP/1.1
> User-Agent: curl/7.37.1
> Host: www.cuinzy.com
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Mon, 17 Aug 2015 10:16:25 GMT
* Server Apache is not blacklisted
< Server: Apache
< Connection: close
< Transfer-Encoding: chunked
< Content-Type: message/http
<
TRACE /itm/572-aumento-natural-del-busto-pueraria-mirifica-100-x-500mg.html HTTP/1.1
User-Agent: curl/7.37.1
Host: www.cuinzy.com
Accept: */*
* Closing connection 0
And look how the use of SSL does not represent a change, additionally, notice that at all times the http response code is 200.
And, if i click on See exactly what our scraper sees for your URL link of Facebook Lint, this only return:
Document returned no data
Ah, additionally, i try this tools(and all return http response code 200 and work fine):
curl via terminal on mac
http://httpstatus.io/
http://iframely.com/debug?uri=https%3A%2F%2Fwww.cuinzy.com%2Fitm%2F572-aumento-natural-del-busto-pueraria-mirifica-100-x-500mg.html
http://opengraphcheck.com/result.php?url=https%3A%2F%2Fwww.cuinzy.com%2Fitm%2F572-aumento-natural-del-busto-pueraria-mirifica-100-x-500mg.html#.VdG3hVN_Oko
https://coveloping.com/tools/open-graph-tag-tester
Please, if you know whats happend tell me, i dont understand...
P.S: sorry for my bad english.

Context Provider Response is not recognized

Using the latest development version:
I have registered a context provider for an attribute. When the attribute is asked the context provider is interrogated through a POST request which returns
curl -v --request POST http://130.206.83.68/ngsi10/queryContext
* About to connect() to 130.206.83.68 port 80 (#0)
* Trying 130.206.83.68... connected
> POST /ngsi10/queryContext HTTP/1.1
> User-Agent: curl/7.22.0 (x86_64-pc-linux-gnu) libcurl/7.22.0 OpenSSL/1.0.1 zlib/1.2.3.4 libidn/1.23 librtmp/2.3
> Host: 130.206.83.68
> Accept: */*
>
< HTTP/1.1 200 OK
< X-Powered-By: Express
< Content-Type: application/json; charset=utf-8
< Content-Length: 206
< Date: Fri, 27 Mar 2015 11:09:05 GMT
< Connection: keep-alive
<
* Connection #0 to host 130.206.83.68 left intact
* Closing connection #0
{"contextResponses":[{"contextElement":
{"isPattern":false,"id":"Madrid","type":"Ciudad",
"attributes":[{"name":"population7","value":"6000","type":"string"}]},
"statusCode": {"code":200,"reasonPhrase":"OK"}}]}
However Orion does not recognize the response and the following trace appears:
INFO#10:59:36 clientSocketHttp.cpp[154]: Starting transaction to 130.206.83.68:80/ngsi10/queryContext
INFO#10:59:36 clientSocketHttp.cpp[364]: Notification Successfully Sent to 130.206.83.68:80/ngsi10/queryContext
INFO#10:59:36 clientSocketHttp.cpp[375]: Transaction ended
WARNING#10:59:36 postQueryContext.cpp[211]: Other Error (context provider response to QueryContext is empty)
INFO#10:59:36 rest.cpp[383]: Transaction ended
This problem is probably due to current Orion version (0.19.0) assumes always that the context providers implement XML rendering. Thus, if your context provider responses in JSON, Orion will not understand the response.
The solution is to implement XML in your context provider (or wait until Orion implement the proper mechanism).

Questions on proper REST api design specifically on the PUT action when updating a resource

I'm creating a REST interface (aren't we all), and I want to UPDATE a resource.
So, I think to use a PUT.
So, i read this.
My take away is that i PUT to a URL like this
/hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c
with a payload, then a permanent redirect to the URL that it can GET an updated version of the resource.
In this case it happens to be the same URL, different action.
So my questions are:
Is my understanding of updating a resource correct in using a PUT, and is my understanding of the use of the PUT correct.
When a client gets a redirect does it do the same action on the redirected URL as it did on the original URL? If its "depends" is there a standard most clients follow?
I ask the 2nd question, because POSTMAN and my JQuery AJAX calls are choking. JQuery because of net::ERR_TOO_MANY_REDIRECTS. So is it redirecting and trying the PUT again, which it will get another REDIRECT?
curl blows up too but even though it says if it gets a 301 it will switch to a GET, it doesn't really seem to do that when i look at the output (below).
When curl follows a redirect and the request is not a plain GET (for example POST or PUT), it will do the following request with a GET if the HTTP response was 301, 302, or 303. If the response code was any other 3xx code, curl will re-send the following request using the same unmodified method.
CURL OUTPUT (edited for brevity) (also note how it says its going to switch to a GET [incorrectly from a POST], but then it seems to do a PUT anyway):
curl -X PUT -H "Authorization: Basic AUTHZ==" -H "Content-Type: application/json" -H "Cache-Control: no-cache" -H "Postman-Token: e80657f0-a8f5-af77-1d9d-d7bc22ed0b30" -d '{ JSONDATA"}' http://localhost:8080/hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c -v -L
* Hostname was NOT found in DNS cache
* Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 8080 (#0)
> PUT /hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c HTTP/1.1
> User-Agent: curl/7.37.1
> Host: localhost:8080
> Accept: */*
> Authorization: Basic AUTHZ==
> Content-Type: application/json
> Cache-Control: no-cache
> Postman-Token: e80657f0-a8f5-af77-1d9d-d7bc22ed0b30
> Content-Length: 203
>
* upload completely sent off: 203 out of 203 bytes
< HTTP/1.1 301 Moved Permanently
< Connection: keep-alive
< X-Powered-By: Undertow/1
< Set-Cookie: rememberMe=deleteMe; Path=/hc; Max-Age=0; Expires=Fri, 20-Feb-2015 03:53:28 GMT
< Set-Cookie: JSESSIONID=uwI3_41LAa7vlvapTsrZdw10.macbook-air; path=/hc
* Server WildFly/8 is not blacklisted
< Server: WildFly/8
< Location: /hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c
< Content-Length: 0
< Date: Sat, 21 Feb 2015 03:53:28 GMT
<
* Connection #0 to host localhost left intact
* Issue another request to this URL: 'http://localhost:8080/hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c'
* Switch from POST to GET
* Found bundle for host localhost: 0x7f9e4b415430
* Re-using existing connection! (#0) with host localhost
* Connected to localhost (127.0.0.1) port 8080 (#0)
> PUT /hc/api/v1/organizer/event/762d36c2-afc5-4c51-84eb-9b5b0ef2990c HTTP/1.1
> User-Agent: curl/7.37.1
> Host: localhost:8080
> Accept: */*
> Authorization: Basic dGVzdHVzZXIxOlBhc3N3b3JkMQ==
> Content-Type: application/json
> Cache-Control: no-cache
> Postman-Token: e80657f0-a8f5-af77-1d9d-d7bc22ed0b30
>
< HTTP/1.1 500 Internal Server Error
< Connection: keep-alive
< Set-Cookie: JSESSIONID=fDXxlH2xI-0-DEaC6Dj5EhD9.macbook-air; path=/hc
< Content-Type: text/html; charset=UTF-8
< Content-Length: 8593
< Date: Sat, 21 Feb 2015 03:53:28 GMT
<
...failure ensues... It actually does a PUT
thanks in advance.
I think you're reading too much into the 301 redirect section.
If you want to update a resource using PUT, return:
201: if the resource was created
200: with the updated resource
The 301 in question only applies if there actually is a redirect in question - like, if something can be identified by name, and you need to redirect it to a url that has the id or something. (Maybe you refactor and people are still consuming the old endpoint).
So, do you really need to redirect your PUT requests? Because you should be sending back the updated resource within the same loop using 200, like stated above, instead of "redirecting to GET".
EDIT: Fix some spelling.

Paypal Refund Transaction Refused

I making refund option with PayPal REST API on my site.
I make order with Paypal test account all taht works great, but when I try to refund i get "Transaction refused". I try refunding full amount, part amount, currency changes... nothing helped me. I also try with new orders and some older orders ( 2 days old) same.
Here what I run and what I get
curl -v https://api.sandbox.paypal.com/v1/payments/sale/*******/refund -H 'Content-Type:application/json' -H 'Authorization: Bearer ***********' -d '{"amount":{"total":"5.00","currency":"JPY"}}'
* About to connect() to api.sandbox.paypal.com port 443 (#0)
* Trying 173.0.82.78...
* Connected to api.sandbox.paypal.com (173.0.82.78) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
* CAfile: /etc/pki/tls/certs/ca-bundle.crt
CApath: none
* NSS: client certificate not found (nickname not specified)
* SSL connection using SSL_RSA_WITH_3DES_EDE_CBC_SHA
* Server certificate:
* subject: CN=api.sandbox.paypal.com,OU=PayPal Production,O="PayPal, Inc.",L=San Jose,ST=California,C=US
* start date: Dec 06 00:00:00 2012 GMT
* expire date: Dec 06 23:59:59 2016 GMT
* common name: api.sandbox.paypal.com
* issuer: CN=VeriSign Class 3 Secure Server CA - G3,OU=Terms of use at https:// www.verisign.com/rpa (c)10,OU=VeriSign Trust Network,O="VeriSign, Inc.",C=US
> POST /v1/payments/sale/**********/refund HTTP/1.1
> User-Agent: curl/7.29.0
> Host: api.sandbox.paypal.com
> Accept: */*
> Content-Type:application/json
> Authorization: Bearer ******************
> Content-Length: 44
>
* upload completely sent off: 44 out of 44 bytes
< HTTP/1.1 400 Bad Request
< Server: Apache-Coyote/1.1
< Date: Sun, 25 Aug 2013 21:35:55 GMT
< Connection: close
< PayPal-Debug-Id: 6ccd19f66d117
< Content-Type: application/json
< Content-Length: 171
< Connection: close
<
* Closing connection 0
{"name":"TRANSACTION_REFUSED","message":"{0}","information_link":"https://developer.paypal.com/webapps/developer/docs/api/#TRANSACTION_REFUSED","debug_id":"6ccd19f66d117"}
So what can be problem? I check link about that PayPal give me and he didnt help me at all.
I need to make refund option working ASAP.
The original transactions were run in Japanese Yen (JPY), but you don't have a JPY balance in your PayPal account -- hence, all of the transactions you've run in JPY are sitting in 'unclaimed' status. Log in to the seller's account (https://www.sandbox.paypal.com) and go to Profile->My Money. Under More (next to PayPal balance), click Currencies. Then, under the Select new currency drop-down, choose Japanese Yen and click Add Currency. The transactions you've previously taken should begin funneling into the account within a few minutes, after which you should be able to process your refund.