Method: purchases.subscriptions.refund

เลิกใช้งานแล้ว: ใช้ orders.refund แทน คืนเงินค่าสมัครใช้บริการของผู้ใช้ แต่การสมัครใช้บริการจะยังคงมีผลจนถึงเวลาหมดอายุและจะเรียกเก็บเงินซ้ำต่อไป

คำขอ HTTP

POST https://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/purchases/subscriptions/{subscriptionId}/tokens/{token}:refund

URL ใช้ไวยากรณ์การแปลง gRPC

พารามิเตอร์เส้นทาง

พารามิเตอร์
packageName

string

ชื่อแพ็กเกจของแอปพลิเคชันที่ซื้อการสมัครใช้บริการนี้ (เช่น "com.some.thing")

subscriptionId

string

"รหัสการสมัครใช้บริการที่ซื้อ (เช่น "monthly001")

token

string

โทเค็นที่ระบุให้กับอุปกรณ์ของผู้ใช้เมื่อซื้อการสมัครใช้บริการ

เนื้อความของคำขอ

เนื้อหาของคำขอต้องว่างเปล่า

เนื้อหาการตอบกลับ

หากดำเนินการสำเร็จ เนื้อหาการตอบกลับจะว่างเปล่า

ตัวอย่าง

ตัวอย่างคําขอมีดังนี้

curl -X POST \
  'https://androidpublisher.googleapis.com/androidpublisher/v3/applications/com.example.myapp/purchases/subscriptions/monthly.premium.plan/tokens/abcdefghijklmnopqrstuvwxyz1234567890:refund' \
  -H 'Accept: application/json'

ขอบเขตการให้สิทธิ์

ต้องใช้ขอบเขต OAuth ต่อไปนี้

  • https://www.googleapis.com/auth/androidpublisher