Class BetaSpendLimitIncreaseRequestResolvedBy
-
- All Implemented Interfaces:
public final class BetaSpendLimitIncreaseRequestResolvedByWho approved or denied the increase request.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceBetaSpendLimitIncreaseRequestResolvedBy.VisitorAn interface that defines how to map each variant of BetaSpendLimitIncreaseRequestResolvedBy to a value of type T.
public final classBetaSpendLimitIncreaseRequestResolvedBy.Type
-
Method Summary
Modifier and Type Method Description final Optional<BetaSpendLimitUserActor>userActor()A user within the organization. final Optional<BetaSpendLimitScopedApiKeyActor>scopedApiKeyActor()A scoped Admin API key acting on behalf of the organization. final Optional<JsonValue>_json()final BetaSpendLimitIncreaseRequestResolvedBy.Typetype()final BooleanisUserActor()final BooleanisScopedApiKeyActor()final BetaSpendLimitUserActorasUserActor()A user within the organization. final BetaSpendLimitScopedApiKeyActorasScopedApiKeyActor()A scoped Admin API key acting on behalf of the organization. final <T extends Any> Taccept(BetaSpendLimitIncreaseRequestResolvedBy.Visitor<T> visitor)Maps this instance's current variant to a value of type T using the given visitor. final BetaSpendLimitIncreaseRequestResolvedByvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static BetaSpendLimitIncreaseRequestResolvedByofUserActor(BetaSpendLimitUserActor userActor)A user within the organization. final static BetaSpendLimitIncreaseRequestResolvedByofScopedApiKeyActor(BetaSpendLimitScopedApiKeyActor scopedApiKeyActor)A scoped Admin API key acting on behalf of the organization. final static BetaSpendLimitIncreaseRequestResolvedByofScopedApiKeyActor(String scopedApiKeyId)Returns an immutable instance of BetaSpendLimitIncreaseRequestResolvedBy whose ofScopedApiKeyActor variant is built from the given required scopedApiKeyId. -
-
Method Detail
-
userActor
final Optional<BetaSpendLimitUserActor> userActor()
A user within the organization.
nameandemail_addressare null when the underlying account is unavailable or has been deleted;deletedis true only for deleted accounts.
-
scopedApiKeyActor
final Optional<BetaSpendLimitScopedApiKeyActor> scopedApiKeyActor()
A scoped Admin API key acting on behalf of the organization.
-
type
final BetaSpendLimitIncreaseRequestResolvedBy.Type type()
-
isUserActor
final Boolean isUserActor()
-
isScopedApiKeyActor
final Boolean isScopedApiKeyActor()
-
asUserActor
final BetaSpendLimitUserActor asUserActor()
A user within the organization.
nameandemail_addressare null when the underlying account is unavailable or has been deleted;deletedis true only for deleted accounts.
-
asScopedApiKeyActor
final BetaSpendLimitScopedApiKeyActor asScopedApiKeyActor()
A scoped Admin API key acting on behalf of the organization.
-
accept
final <T extends Any> T accept(BetaSpendLimitIncreaseRequestResolvedBy.Visitor<T> visitor)
Maps this instance's current variant to a value of type T using the given visitor.
Note that this method is not forwards compatible with new variants from the API, unless visitor overrides Visitor.unknown. To handle variants not known to this version of the SDK gracefully, consider overriding Visitor.unknown:
import com.anthropic.core.JsonValue; import java.util.Optional; Optional<String> result = betaSpendLimitIncreaseRequestResolvedBy.accept(new BetaSpendLimitIncreaseRequestResolvedBy.Visitor<Optional<String>>() { @Override public Optional<String> visitUserActor(BetaSpendLimitUserActor userActor) { return Optional.of(userActor.toString()); } // ... @Override public Optional<String> unknown(JsonValue json) { // Or inspect the `json`. return Optional.empty(); } });
-
validate
final BetaSpendLimitIncreaseRequestResolvedBy validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
ofUserActor
final static BetaSpendLimitIncreaseRequestResolvedBy ofUserActor(BetaSpendLimitUserActor userActor)
A user within the organization.
nameandemail_addressare null when the underlying account is unavailable or has been deleted;deletedis true only for deleted accounts.
-
ofScopedApiKeyActor
final static BetaSpendLimitIncreaseRequestResolvedBy ofScopedApiKeyActor(BetaSpendLimitScopedApiKeyActor scopedApiKeyActor)
A scoped Admin API key acting on behalf of the organization.
-
ofScopedApiKeyActor
final static BetaSpendLimitIncreaseRequestResolvedBy ofScopedApiKeyActor(String scopedApiKeyId)
Returns an immutable instance of BetaSpendLimitIncreaseRequestResolvedBy whose ofScopedApiKeyActor variant is built from the given required scopedApiKeyId.
-
-
-
-