價格 (Prices)

價格:金額、幣別、單筆或週期性。

檢視 Markdown

價格屬於某個商品,決定金額、幣別,以及是單筆(OneTime)還是週期性扣款(Recurring)。amount 是整數:像 TWD 這種沒有小數位的幣別,amount 就是金額本身。

GET/api/Price— 列出價格,可用 productId 篩選
屬性值
所需權限prices:read
Idempotency-Key不需要
參數位置型別必填
pagequeryinteger (int32)
pageSizequeryinteger (int32)
orderByquerystring
orderDirectionquerystring
createdFromquerystring (date-time)
createdToquerystring (date-time)
productIdquerystring
POST/api/Price— 為某個商品建立一個新價格
屬性值
所需權限prices:write
Idempotency-Key不需要
參數位置型別必填
activebodyboolean
amountbodyinteger (int32)
currencybodystring
intervalbodystring
intervalCountbodyinteger (int32)
productIdbodystring
trialDaysbodyinteger (int32)
typebodystring
GET/api/Price/{priceId}— 讀取單一價格
屬性值
所需權限prices:read
Idempotency-Key不需要
參數位置型別必填
priceIdpathstring必填
PUT/api/Price/{priceId}— 更新價格。
屬性值
所需權限prices:write
Idempotency-Key不需要
參數位置型別必填
priceIdpathstring必填
activebodyboolean
GET/api/Price/{priceId}/EntitlementPolicy— 價格:EntitlementPolicy。
屬性值
所需權限entitlements:read
Idempotency-Key不需要
參數位置型別必填
priceIdpathstring必填
pagequeryinteger (int32)
pageSizequeryinteger (int32)
orderByquerystring
orderDirectionquerystring
createdFromquerystring (date-time)
createdToquerystring (date-time)
POST/api/Price/{priceId}/EntitlementPolicy— 價格:EntitlementPolicy。
屬性值
所需權限entitlements:write
Idempotency-Key不需要
參數位置型別必填
priceIdpathstring必填
allowedbodystring
creditGrantAmountbodyinteger (int32)
limitbodyinteger (int32)
limitAmountbodyinteger (int32)