You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ curl -v -X GET https://api-m.sandbox.paypal.com/v1/billing/plans?sort_by=create_time&sort_order=desc \
-H 'Authorization: Bearer TOKEN_RETRACTED' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Prefer: return=representation'
[2] 2345
bash: -H: command not found
Note: Unnecessary use of -X or --request, GET is already inferred.
* processing: https://api-m.sandbox.paypal.com/v1/billing/plans?sort_by=create_time
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
Problem is fixed by enclosing the url within double quotes
$ curl -v -X GET "https://api-m.sandbox.paypal.com/v1/billing/plans?sort_by=create_time&sort_order=desc" \
-H 'Authorization: Bearer TOKEN_RETRACTED' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Prefer: return=representation'
Note: Unnecessary use of -X or --request, GET is already inferred.
* processing: https://api-m.sandbox.paypal.com/v1/billing/plans?sort_by=create_time&sort_order=desc
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Trying 199.232.169.35:443...
* Connected to api-m.sandbox.paypal.com (199.232.169.35) port 443
* schannel: disabled automatic use of client certificate
* using HTTP/1.x
> GET /v1/billing/plans?sort_by=create_time&sort_order=desc HTTP/1.1
> Host: api-m.sandbox.paypal.com
> User-Agent: curl/8.2.1
> Authorization: Bearer TOKEN_RETRACTED
> Content-Type: application/json
> Accept: application/json
> Prefer: return=representation
>
< HTTP/1.1 401 Unauthorized
< Connection: keep-alive
< Content-Length: 95
< Content-Type: application/json
< Server: nginx
< Cache-Control: max-age=0, no-cache, no-store, must-revalidate
< Paypal-Debug-Id: 13cb9c4b4755f
< Strict-Transport-Security: max-age=31536000; includeSubDomains
< Accept-Ranges: bytes
< Via: 1.1 varnish, 1.1 varnish
< Edge-Control: max-age=0
< Date: Tue, 26 Sep 2023 04:25:16 GMT
< X-Served-By: cache-lhr7338-LHR, cache-par-lfpg1960022-PAR
< X-Cache: MISS, MISS
< X-Cache-Hits: 0, 0
< X-Timer: S1695702316.041763,VS0,VE202
< Vary: Accept-Encoding
<
{ [95 bytes data]
100 95 100 95 0 0 90 0 0:00:01 0:00:01 --:--:-- 90{"error":"invalid_token","error_description":"The token passed in was not found in the system"}
* Connection #0 to host api-m.sandbox.paypal.com left intact
Steps To Reproduce
See above
What type of Operating System are you seeing the problem on?
Windows
What type of browser are you seeing the problem on?
No response
Screenshots or Videos
No response
Code to produce this issue.
See above
The text was updated successfully, but these errors were encountered:
Contact Details
[email protected]
Describe the Issue
Some of the curl examples have the destination url not within double quotes which can cause problems. Here's an example:
Problem is fixed by enclosing the url within double quotes
Steps To Reproduce
See above
What type of Operating System are you seeing the problem on?
Windows
What type of browser are you seeing the problem on?
No response
Screenshots or Videos
No response
Code to produce this issue.
The text was updated successfully, but these errors were encountered: