共用方式為


Manage orders - Get subscription by ID

依據合作夥伴的 Active Directory 租使用者識別碼,依識別碼擷取合作夥伴客戶的訂用帳戶。

GET https://api.partnercenter.microsoft.com/v{version}/customers/{customer_id}/subscriptions/{subscription_id}

URI 參數

名稱 位於 必要 類型 Description
customer_id
path True

string

客戶的 Active Directory 租使用者識別碼。

subscription_id
path True

string

訂用帳戶識別碼。

version
path True

string

要求標頭

名稱 必要 類型 Description
Authorization True

string

授權持有人權杖

ms-correlationid

string

用於在內部追蹤要求。 如果未提供 ms-correlationid,伺服器將會為每個要求產生新的識別碼

ms-cv

string

用於在內部追蹤要求。 如果未提供 ms-cv,伺服器將會為每個要求產生新的要求

ms-requestid

string

用於要求的等冪性。 如果未提供 ms-requestid,伺服器將會為每個要求產生新的要求

回應

名稱 類型 Description
200 OK

Microsoft.Partner.Services.Subscriptions.V1.Models.Subscription

要求成功。 回應本文包含訂用帳戶資訊。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

400 Bad Request

遺漏或不正確輸入。 回應本文將提供錯誤詳細資料。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

401 Unauthorized

要求未經驗證。 用戶端必須先向合作夥伴 API 服務進行驗證。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

403 Forbidden

要求已經過驗證,但因為呼叫端沒有叫用要求的許可權而遭到拒絕。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

404 Not Found

找不到資源,或無法使用指定的輸入參數。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

500 Internal Server Error

合作夥伴 API 服務或其其中一個相依性無法滿足要求。 來電者可能會重試此動作。

Media Types: "application/json", "text/json", "application/xml", "text/xml"

定義

名稱 Description
Microsoft.Partner.Core.Collections.Link
Microsoft.Partner.Core.Collections.ResourceAttributes
Microsoft.Partner.Services.Subscriptions.V1.Models.ItemType
Microsoft.Partner.Services.Subscriptions.V1.Models.ProductTerm
Microsoft.Partner.Services.Subscriptions.V1.Models.PurchaseCommitment
Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantity
Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantityDetail
Microsoft.Partner.Services.Subscriptions.V1.Models.RefundOption
Microsoft.Partner.Services.Subscriptions.V1.Models.ScheduledNextTermInstructions
Microsoft.Partner.Services.Subscriptions.V1.Models.Scope
Microsoft.Partner.Services.Subscriptions.V1.Models.Subscription
Microsoft.Partner.Services.Subscriptions.V1.Models.SubscriptionLineItemDetail
Microsoft.Partner.Services.Subscriptions.V1.Models.SubscriptionLinks
System.Collections.Generic.KeyValuePair[System.String,System.String]
名稱 類型 Description
body

string

headers

System.Collections.Generic.KeyValuePair[System.String,System.String][]

method

string

uri

string

Microsoft.Partner.Core.Collections.ResourceAttributes

名稱 類型 Description
etag

string

objectType

string

Microsoft.Partner.Services.Subscriptions.V1.Models.ItemType

名稱 類型 Description
displayName

string

id

string

subType

Microsoft.Partner.Services.Subscriptions.V1.Models.ItemType

Microsoft.Partner.Services.Subscriptions.V1.Models.ProductTerm

名稱 類型 Description
availabilityId

string

billingCycle enum:
  • annual
  • biennial
  • monthly
  • none
  • one_time
  • triennial
  • unknown
productId

string

skuId

string

termDuration

string

Microsoft.Partner.Services.Subscriptions.V1.Models.PurchaseCommitment

名稱 類型 Description
amount

number

currency

string

grain

string

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantity

名稱 類型 Description
details

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantityDetail[]

totalQuantity

integer

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantityDetail

名稱 類型 Description
allowedUntilDateTime

string

quantity

integer

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundOption

名稱 類型 Description
expiresAt

string

type

string

Microsoft.Partner.Services.Subscriptions.V1.Models.ScheduledNextTermInstructions

名稱 類型 Description
customTermEndDate

string

product

Microsoft.Partner.Services.Subscriptions.V1.Models.ProductTerm

quantity

integer

Microsoft.Partner.Services.Subscriptions.V1.Models.Scope

名稱 類型 Description
entitlementId

string

managementGroupId

string

resourceGroupId

string

subscriptionId

string

type

string

Microsoft.Partner.Services.Subscriptions.V1.Models.Subscription

名稱 類型 Description
actionTaken

boolean

actions

string[]

attentionNeeded

boolean

attentionReason

string

attributes

Microsoft.Partner.Core.Collections.ResourceAttributes

autoRenewEnabled

boolean

billingCycle enum:
  • annual
  • monthly
  • none
  • one_time
  • triennial
  • unknown
billingType enum:
  • benefit
  • license
  • none
  • usage
commitmentEndDate

string

contractType enum:
  • product_key
  • redemption_code
  • subscription
creationDate

string

effectiveStartDate

string

entitlementId

string

friendlyName

string

hasPurchasableAddons

boolean

id

string

isMicrosoftProduct

boolean

isTrial

boolean

lineItems

Microsoft.Partner.Services.Subscriptions.V1.Models.SubscriptionLineItemDetail[]

links

Microsoft.Partner.Services.Subscriptions.V1.Models.SubscriptionLinks

migratedFromSubscriptionId

string

offerId

string

offerName

string

orderId

string

parentSubscriptionId

string

partnerId

string

productOrderId

string

productType

Microsoft.Partner.Services.Subscriptions.V1.Models.ItemType

promotionId

string

publisherName

string

quantity

integer

refundOptions

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundOption[]

refundableQuantity

Microsoft.Partner.Services.Subscriptions.V1.Models.RefundableQuantity

renewalTermDuration

string

scheduledNextTermInstructions

Microsoft.Partner.Services.Subscriptions.V1.Models.ScheduledNextTermInstructions

status enum:
  • active
  • deleted
  • disabled
  • expired
  • none
  • pending
  • suspended
suspensionReasons

string[]

termDuration

string

unitType

string

Microsoft.Partner.Services.Subscriptions.V1.Models.SubscriptionLineItemDetail

名稱 類型 Description
autoRenewEnabled

boolean

friendlyName

string

id

string

purchaseCommitment

Microsoft.Partner.Services.Subscriptions.V1.Models.PurchaseCommitment

quantity

integer

scope

Microsoft.Partner.Services.Subscriptions.V1.Models.Scope

status enum:
  • active
  • deleted
  • expired
  • expired
  • none
  • pending
  • suspended
名稱 類型 Description
activationLinks

Microsoft.Partner.Core.Collections.Link

availability

Microsoft.Partner.Core.Collections.Link

entitlement

Microsoft.Partner.Core.Collections.Link

next

Microsoft.Partner.Core.Collections.Link

offer

Microsoft.Partner.Core.Collections.Link

parentSubscription

Microsoft.Partner.Core.Collections.Link

pendingChanges

Microsoft.Partner.Core.Collections.Link

previous

Microsoft.Partner.Core.Collections.Link

product

Microsoft.Partner.Core.Collections.Link

self

Microsoft.Partner.Core.Collections.Link

sku

Microsoft.Partner.Core.Collections.Link

System.Collections.Generic.KeyValuePair[System.String,System.String]

名稱 類型 Description
key

string

value

string