PayPal 订阅 API:使用 curl 检索现有计费计划 ID 的信息

PayPal Subscriptions API: retrieving information for a existing billing plan ID using curl

问题是关于 PayPal API via curl:创建计划后如何稍后重新检查

关注 https://developer.paypal.com/docs/subscriptions/integrate/ 我能够创建我的代币、创建产品、创建计划并获得计划的 ID。

响应中有

'links' => array ( 0 => array ( 'href' => 'https://api.sandbox.paypal.com/v1/billing/plans/____PLANID_____',

我如何制定一个 curl 命令来在以后检索此计划 ID 的信息?

我试过了...

$paypalcurl = 'curl -v -X POST https://api.sandbox.paypal.com/v1/billing/plans/____PLANID_____ \
    -H "Content-Type: application/json" \
    -H "Accept-Language: en_US" \
    -H "Content-Type: application/json" \
    -H "Authorization: Bearer '.paypal_tokenix().'" ';
$plan_result = json_decode(exec($paypalcurl.' 2>&1'),true);

var_dump($plan_result,true);

但是没有收到任何回复。

curl -v -X POST

文档:https://developer.paypal.com/docs/api/subscriptions/v1/#plans_get

使用方法 GET。