You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用App Store Connect API批量更新自动续期订阅全地区价格的问询

批量更新自动续期订阅多地区价格的API问题

我希望通过单次请求批量更新自动续期订阅所有地区的价格。我了解可以通过Create a Subscription Price Change API端点逐个地区完成该操作,但这意味着我需要为每个地区调用一次该API,而我有大量订阅需要更新。

另有一个Modify an Auto-Renewable Subscription API端点似乎支持该操作。

对于需要修改价格的国家/地区,我通过List All Price Points for a Subscription API端点获取订阅价格点。

当我使用以下请求体调用该API端点时:

{
  "data": {
    "type": "subscriptions",
    "relationships": {
      "prices": {
        "data": [
          {
            "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJDQU4iLCJwIjoiMTAwMDEifQ",
            "type": "subscriptionPrices"
          },
          {
            "type": "subscriptionPrices",
            "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJVU0EiLCJwIjoiMTAwMDEifQ"
          }
        ]
      }
    },
    "id": "6740021496"
  },
  "included": [
    {
      "relationships": {
        "subscriptionPricePoint": {
          "data": {
            "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJDQU4iLCJwIjoiMTAwMDEifQ",
            "type": "subscriptionPricePoints"
          }
        },
        "territory": {
          "data": {
            "type": "territories",
            "id": "CAN"
          }
        },
        "subscription": {
          "data": {
            "id": "6740021496",
            "type": "subscriptions"
          }
        }
      },
      "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJDQU4iLCJwIjoiMTAwMDEifQ",
      "attributes": {
        "preserveCurrentPrice": true
      },
      "type": "subscriptionPrices"
    },
    {
      "attributes": {
        "preserveCurrentPrice": true
      },
      "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJVU0EiLCJwIjoiMTAwMDEifQ",
      "type": "subscriptionPrices",
      "relationships": {
        "subscription": {
          "data": {
            "type": "subscriptions",
            "id": "6740021496"
          }
        },
        "subscriptionPricePoint": {
          "data": {
            "type": "subscriptionPricePoints",
            "id": "eyJzIjoiNjc0MDAyMTQ5NiIsInQiOiJVU0EiLCJwIjoiMTAwMDEifQ"
          }
        },
        "territory": {
          "data": {
            "type": "territories",
            "id": "USA"
          }
        }
      }
    }
  ]
}

我收到了409错误:

{
  "errors" : [ {
    "id" : "5b6a4b62-686c-4a65-87ba-e16131db517b",
    "status" : "409",
    "code" : "ENTITY_ERROR",
    "title" : "There is a problem with the request entity",
    "detail" : "User is not allowed to edit.",
    "source" : {
      "pointer" : "subscriptionPrices"
    }
  } ]
}

我已确认:

  • Bearer授权令牌正确且未过期;
  • p8密钥拥有管理员权限。

请问该PATCH端点是否可用于实现我的需求?如果可以,使用该端点有什么特殊注意事项吗?

内容的提问来源于stack exchange,提问作者alpennec

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.14 16:25:18