0
내가 모든 CREATED
사업 계획 삭제하려고 해요 제공 :대금 청구 계획 패치 : - HTTP 400 잘못된 경로
for (Plan plan : created.getPlans()) {
List<Patch> patchRequestList = new ArrayList<>();
Map<String, String> value = new HashMap<>();
value.put("state", "DELETED");
Patch patch = new Patch();
patch.setPath("/v1/payments/billing-plans/" + plan.getId());
patch.setValue(value);
patch.setOp("replace");
patchRequestList.add(patch);
plan.update(apiContext, patchRequestList);
}
을하지만 내가 갖는 모든은 다음과 같습니다 documentation에 따르면
Caused by: java.io.IOException: Server returned HTTP response code: 400 for URL: https://api.sandbox.paypal.com/v1/payments/billing-plans/P-8SX60559PJ5455037EICJEYY
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1889)
나는 그것이 올바르게하고 있다고 생각한다. 그러나 나는 시도했다
patch.setPath("/v1/payments/billing-plans/" + plan.getId());
patch.setPath("/v1/payments/billing-plans");
patch.setPath("/payments/billing-plans);
등등 그러나 이것들이 효과가 없다.
내가 뭘 잘못하고 있니?