Class UserProfileEnforcementActionRestriction.Builder
-
- All Implemented Interfaces:
public final class UserProfileEnforcementActionRestriction.BuilderA builder for UserProfileEnforcementActionRestriction.
-
-
Method Summary
-
-
Method Detail
-
id
final UserProfileEnforcementActionRestriction.Builder id(String id)
The action's ID (
enac_...), stable while the action is open.
-
id
final UserProfileEnforcementActionRestriction.Builder id(JsonField<String> id)
Sets Builder.id to an arbitrary JSON value.
You should usually call Builder.id with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
action
final UserProfileEnforcementActionRestriction.Builder action(UserProfileEnforcementActionNextStep action)
The next step on the action:
verifyornull.verify: the end user can clear it now by passing an identity check.null: there is nothing the end user can do now to clear it, including while Anthropic reviews an identity check the end user submitted.
-
action
final UserProfileEnforcementActionRestriction.Builder action(Optional<UserProfileEnforcementActionNextStep> action)
Alias for calling Builder.action with
action.orElse(null).
-
action
final UserProfileEnforcementActionRestriction.Builder action(JsonField<UserProfileEnforcementActionNextStep> action)
Sets Builder.action to an arbitrary JSON value.
You should usually call Builder.action with a well-typed UserProfileEnforcementActionNextStep value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
expiresAt
final UserProfileEnforcementActionRestriction.Builder expiresAt(OffsetDateTime expiresAt)
When the action ends on its own, in RFC 3339 format; it stops showing once this time has passed.
nullwhen it has no end date, and alwaysnullwhenreasonisaccount_compromise.
-
expiresAt
final UserProfileEnforcementActionRestriction.Builder expiresAt(Optional<OffsetDateTime> expiresAt)
Alias for calling Builder.expiresAt with
expiresAt.orElse(null).
-
expiresAt
final UserProfileEnforcementActionRestriction.Builder expiresAt(JsonField<OffsetDateTime> expiresAt)
Sets Builder.expiresAt to an arbitrary JSON value.
You should usually call Builder.expiresAt with a well-typed OffsetDateTime value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
openedAt
final UserProfileEnforcementActionRestriction.Builder openedAt(OffsetDateTime openedAt)
When Anthropic opened the action, in RFC 3339 format.
-
openedAt
final UserProfileEnforcementActionRestriction.Builder openedAt(JsonField<OffsetDateTime> openedAt)
Sets Builder.openedAt to an arbitrary JSON value.
You should usually call Builder.openedAt with a well-typed OffsetDateTime value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
reason
final UserProfileEnforcementActionRestriction.Builder reason(UserProfileEnforcementActionReason reason)
Why Anthropic placed the limit:
unsupported_region,fraud_or_abuse,high_harm,usage_policy_violation,account_compromiseorunspecified.
-
reason
final UserProfileEnforcementActionRestriction.Builder reason(JsonField<UserProfileEnforcementActionReason> reason)
Sets Builder.reason to an arbitrary JSON value.
You should usually call Builder.reason with a well-typed UserProfileEnforcementActionReason value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
type
final UserProfileEnforcementActionRestriction.Builder type(JsonValue type)
Sets the field to an arbitrary JSON value.
It is usually unnecessary to call this method because the field defaults to the following:
JsonValue.from("restriction")This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final UserProfileEnforcementActionRestriction.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final UserProfileEnforcementActionRestriction.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final UserProfileEnforcementActionRestriction.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final UserProfileEnforcementActionRestriction.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final UserProfileEnforcementActionRestriction.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final UserProfileEnforcementActionRestriction build()
Returns an immutable instance of UserProfileEnforcementActionRestriction.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.id() .action() .expiresAt() .openedAt() .reason()
-
-
-
-