Claude Platform Docs

支出上限を削除

client.Beta.Organization.SpendLimits.Delete(ctx, spendLimitID) (*BetaOrganizationSpendLimitDeleteResponse, error)
DELETE/v1/organizations/spend_limits/{spend_limit_id}

支出上限を削除します。

Claude Enterprise組織の場合、ユーザーごとのオーバーライドが削除され、 メンバーはその期間に継承される支出上限にフォールバックします。 シート階層、グループ、組織レベルの行はこのエンドポイントでは削除できません。 Claude Console組織は、組織およびワークスペースの上限を削除しますが、usage_tier の上限は削除しません。 APIによる組織およびワークスペースの上限の削除はアーリーアクセスプレビュー段階です。

Parameters
spendLimitID string⁠Path parameter

ID of the Spend Limit.

Returns
type BetaOrganizationSpendLimitDeleteResponse struct { Type: "spend_limit_deleted"; ID }
Type SpendLimitDeleted
defaultspend_limit_deleted
ID string
支出上限を削除
package main

import (
	"context"
	"fmt"

	"github.com/anthropics/anthropic-sdk-go"
	"github.com/anthropics/anthropic-sdk-go/option"
)

func main() {
	client := anthropic.NewClient(
		option.WithAPIKey("my-anthropic-api-key"),
	)
	spendLimit, err := client.Beta.Organization.SpendLimits.Delete(context.TODO(), "spend_limit_id")
	if err != nil {
		panic(err.Error())
	}
	fmt.Printf("%+v\n", spendLimit.ID)
}
Returns Examples
Response 200
{
  "id": "id",
  "type": "spend_limit_deleted"
}