刪除附加元件提交Delete an add-on submission

使用 Microsoft Store 提交 API 中的這個方法,刪除現有的附加元件 (也稱為應用程式內產品或 IAP) 提交。Use this method in the Microsoft Store submission API to delete an existing add-on (also known as in-app product or IAP) submission.

必要條件Prerequisites

若要使用這個方法,您必須先進行下列動作:To use this method, you need to first do the following:

  • 如果您尚未完成,請先完成 Microsoft Store 提交 API 的所有先決條件If you have not done so already, complete all the prerequisites for the Microsoft Store submission API.
  • 取得 Azure AD 存取權杖以便用於這個方法的要求標頭。Obtain an Azure AD access token to use in the request header for this method. 在您取得存取權杖之後,您在權杖到期之前有 60 分鐘的時間可以使用權杖。After you obtain an access token, you have 60 minutes to use it before it expires. 權杖到期之後,您可以取得新的權杖。After the token expires, you can obtain a new one.

要求Request

這個方法的語法如下。This method has the following syntax. 請參閱下列各小節了解標頭和要求本文的使用範例和描述。See the following sections for usage examples and descriptions of the header and request body.

方法Method 要求 URIRequest URI
DELETEDELETE https://manage.devcenter.microsoft.com/v1.0/my/inappproducts/{inAppProductId}/submissions/{submissionId}

要求的標頭Request header

標頭Header 類型Type 描述Description
AuthorizationAuthorization 字串string 必要。Required. 在表單中的 Azure AD 存取權杖持有人 <語彙基元>。The Azure AD access token in the form Bearer <token>.

要求參數Request parameters

名稱Name 類型Type 描述Description
inAppProductIdinAppProductId 字串string 必要。Required. 包含要刪除提交之附加元件的市集識別碼。The Store ID of the add-on that contains the submission to delete. 存放區識別碼適用於合作夥伴中心。The Store ID is available in Partner Center.
submissionIdsubmissionId 字串string 必要。Required. 要刪除之提交的識別碼。The ID of the submission to delete. 建立附加元件提交要求的回應資料中有提供此識別碼。This ID is available in the response data for requests to create an add-on submission. 提交在合作夥伴中心所建立,此識別碼也會提供在合作夥伴中心內的 [提交] 頁面的 url。For a submission that was created in Partner Center, this ID is also available in the URL for the submission page in Partner Center.

要求本文Request body

不提供此方法的要求本文。Do not provide a request body for this method.

要求範例Request example

下列範例示範如何刪除附加元件提交。The following example demonstrates how to delete an add-on submission.

DELETE https://manage.devcenter.microsoft.com/v1.0/my/inappproducts/9NBLGGH4TNMP/submissions/1152921504621230023 HTTP/1.1
Authorization: Bearer <your access token>

回應Response

如果成功,此方法會傳回空白回應主體。If successful, this method returns an empty response body.

錯誤碼Error codes

如果要求無法順利完成,則回應會包含下列其中一個 HTTP 錯誤碼。If the request cannot be successfully completed, the response will contain one of the following HTTP error codes.

錯誤碼Error code 描述Description
400400 要求參數無效。The request parameters are invalid.
404404 找不到指定的提交。The specified submission could not be found.
409409 找不到指定的提交,但無法刪除在目前的狀態,或附加元件會使用合作夥伴中心功能都十分目前不支援 Microsoft Store 提交 APIThe specified submission was found but it could not be deleted in its current state, or the add-on uses a Partner Center feature that is currently not supported by the Microsoft Store submission API.