這是我在貝寶捕捉支付寶
OAuthTokenCredential tokenCredential = new OAuthTokenCredential("<CLIENT_ID>", "<CLIENT_SECRET>");
var accessToken = tokenCredential.GetAccessToken();
Authorization authorization = Authorization.Get(accessToken, "5RA45624N3531924N");
Capture capture = new Capture();
Amount captureAmount = new Amount();
captureAmount.currency = "USD";
captureAmount.total = "1";
capture.amount = captureAmount;
capture.is_final_capture = true;
Capture responseCapture = authorization.Capture(accessToken, capture);
用於捕獲支付代碼,但它說
參數類型「串」不分配給參數類型「PayPal.Api.APIContext '
在下面的行accessToken
參數
Authorization authorization = Authorization.Get(accessToken, "5RA45624N3531924N");
我該如何解決這個問題?