safetykit 0.60.0 → 0.61.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7cb28c05f7fef84ce3dfd57ed9d02a7a91f5b82ca89fa83c7a8fcc1d8cb6f284
4
- data.tar.gz: 20ab9fdc4a618d9f5c53928b32aa0c4810b8bb2a0569d7a6c673e7226612521a
3
+ metadata.gz: 74d37bde20ce0dd29500d68690165a6c335b938f34981b568b1a3178a856bc20
4
+ data.tar.gz: 19a8abb52f8080e83e47025562fdc33bf6dece0f8dcb6a2097b4ad08845ed64f
5
5
  SHA512:
6
- metadata.gz: f7c7c368db73c3d086844655ff65a4597e48de920937854b21c322bc2b00ca29bdcb18749bcc0e6e93a0eefc64d5ca9d9435d581683c6797ab1fd2757dcc681e
7
- data.tar.gz: 49d1ab71b13c0a87126beba45f65499a4e3d8df4e272364bee01a05bc683cea2764dfea84fc8fde7e2dcdebc5d3380143a6e2bf592b380e1116fc89fb619a6a8
6
+ metadata.gz: 99472b2eff90b254304c3e57274013398bbf81b5e9dd8f862ac3e222c1b2345ceb8158a5e866582763968dbe173f00bbb471605553b2123f6b84c64ddd3aac19
7
+ data.tar.gz: c184514d9a4b98b3104486af354bff6595d170fd4fa7ad8cb1e26a4c3bca729e290b95256d052a000f8215a8e953d615c1a35253c16a0840a0cac2ccae4d9112
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.61.0 (2026-08-13)
4
+
5
+ Full Changelog: [v0.60.0...v0.61.0](https://github.com/GetSafetyKit/safetykit-ruby/compare/v0.60.0...v0.61.0)
6
+
7
+ ### Features
8
+
9
+ * **api:** api update ([5fbad62](https://github.com/GetSafetyKit/safetykit-ruby/commit/5fbad6289871e01019b6ffc6036b763c56ff5c2b))
10
+
3
11
  ## 0.60.0 (2026-08-12)
4
12
 
5
13
  Full Changelog: [v0.59.0...v0.60.0](https://github.com/GetSafetyKit/safetykit-ruby/compare/v0.59.0...v0.60.0)
data/README.md CHANGED
@@ -17,7 +17,7 @@ To use this gem, install via Bundler by adding the following to your application
17
17
  <!-- x-release-please-start-version -->
18
18
 
19
19
  ```ruby
20
- gem "safetykit", "~> 0.60.0"
20
+ gem "safetykit", "~> 0.61.0"
21
21
  ```
22
22
 
23
23
  <!-- x-release-please-end -->
@@ -50,7 +50,7 @@ module SafetyKit
50
50
  # A user appeals a moderation action taken against them. Use user_id for the appealing user, appealed_decision_id to reference the decision being appealed, and content and content_id for the appeal itself.
51
51
  variant -> { SafetyKit::AsyncCreateAsyncParams::Body::AppealEventRequest }
52
52
 
53
- # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution.
53
+ # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution. Use labels for categories the decision applied and negative_labels for categories the decision explicitly reviewed and determined do not apply; at least one of the two is required.
54
54
  variant -> { SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest }
55
55
 
56
56
  variant -> { SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8Array }
@@ -2931,12 +2931,6 @@ module SafetyKit
2931
2931
  # @return [String]
2932
2932
  required :event_name, String
2933
2933
 
2934
- # @!attribute labels
2935
- # One or more label categories supplied with the report or moderation decision.
2936
- #
2937
- # @return [Array<String>]
2938
- required :labels, SafetyKit::Internal::Type::ArrayOf[String]
2939
-
2940
2934
  # @!attribute source_id
2941
2935
  # Stable identifier within source_type. Examples: moderator@example.com or
2942
2936
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
@@ -2998,6 +2992,13 @@ module SafetyKit
2998
2992
  # @return [String, nil]
2999
2993
  optional :idempotency_key, String
3000
2994
 
2995
+ # @!attribute labels
2996
+ # Label categories the decision determined apply to the target. At least one of
2997
+ # labels or negative_labels is required.
2998
+ #
2999
+ # @return [Array<String>, nil]
3000
+ optional :labels, SafetyKit::Internal::Type::ArrayOf[String]
3001
+
3001
3002
  # @!attribute metadata
3002
3003
  # Non-PII product context for filtering, segmentation, and debugging. Values may
3003
3004
  # be strings, numbers, booleans, or arrays of those scalar values.
@@ -3006,6 +3007,14 @@ module SafetyKit
3006
3007
  optional :metadata,
3007
3008
  -> { SafetyKit::Internal::Type::HashOf[union: SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::Metadata] }
3008
3009
 
3010
+ # @!attribute negative_labels
3011
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
3012
+ # the target, such as a manual review that clears a user reported for spam. A
3013
+ # label cannot appear in both labels and negative_labels.
3014
+ #
3015
+ # @return [Array<String>, nil]
3016
+ optional :negative_labels, SafetyKit::Internal::Type::ArrayOf[String]
3017
+
3009
3018
  # @!attribute resources_used
3010
3019
  # Reusable resources observed during the event. Use this for emails, phone
3011
3020
  # numbers, names, addresses, social handles, URLs, payment identifiers,
@@ -3027,19 +3036,19 @@ module SafetyKit
3027
3036
  # @return [String, nil]
3028
3037
  optional :target_user_id, String
3029
3038
 
3030
- # @!method initialize(event_name:, labels:, source_id:, source_type:, timestamp:, type:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, metadata: nil, resources_used: nil, target_content_id: nil, target_user_id: nil)
3039
+ # @!method initialize(event_name:, source_id:, source_type:, timestamp:, type:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, labels: nil, metadata: nil, negative_labels: nil, resources_used: nil, target_content_id: nil, target_user_id: nil)
3031
3040
  # Some parameter documentations has been truncated, see
3032
3041
  # {SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest}
3033
3042
  # for more details.
3034
3043
  #
3035
3044
  # A moderation label or decision from an automated enforcement system or manual
3036
3045
  # review workflow. Do not send user_id; use source_type and source_id for
3037
- # attribution.
3046
+ # attribution. Use labels for categories the decision applied and negative_labels
3047
+ # for categories the decision explicitly reviewed and determined do not apply; at
3048
+ # least one of the two is required.
3038
3049
  #
3039
3050
  # @param event_name [String] Stable, low-cardinality product action name. Use snake_case and put dynamic valu
3040
3051
  #
3041
- # @param labels [Array<String>] One or more label categories supplied with the report or moderation decision.
3042
- #
3043
3052
  # @param source_id [String] Stable identifier within source_type. Examples: moderator@example.com or 550e840
3044
3053
  #
3045
3054
  # @param source_type [Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::SourceType] Coarse attribution category for the moderation decision source. Supported values
@@ -3056,8 +3065,12 @@ module SafetyKit
3056
3065
  #
3057
3066
  # @param idempotency_key [String] Optional caller-provided key used to make retries of this individual event idemp
3058
3067
  #
3068
+ # @param labels [Array<String>] Label categories the decision determined apply to the target. At least one of la
3069
+ #
3059
3070
  # @param metadata [Hash{Symbol=>String, Float, Boolean, Array<String, Float, Boolean>}] Non-PII product context for filtering, segmentation, and debugging. Values may b
3060
3071
  #
3072
+ # @param negative_labels [Array<String>] Label categories the decision explicitly reviewed and determined do NOT apply to
3073
+ #
3061
3074
  # @param resources_used [Array<SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::ResourcesUsed::EntityIDResource, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::ResourcesUsed::UnionMember1>] Reusable resources observed during the event. Use this for emails, phone numbers
3062
3075
  #
3063
3076
  # @param target_content_id [String] Your stable identifier for the content being reported.
@@ -3396,7 +3409,7 @@ module SafetyKit
3396
3409
  # A user appeals a moderation action taken against them. Use user_id for the appealing user, appealed_decision_id to reference the decision being appealed, and content and content_id for the appeal itself.
3397
3410
  variant :appeal, -> { SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::Appeal }
3398
3411
 
3399
- # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution.
3412
+ # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution. Use labels for categories the decision applied and negative_labels for categories the decision explicitly reviewed and determined do not apply; at least one of the two is required.
3400
3413
  variant :moderation_decision,
3401
3414
  -> { SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision }
3402
3415
 
@@ -6208,12 +6221,6 @@ module SafetyKit
6208
6221
  # @return [String]
6209
6222
  required :event_name, String
6210
6223
 
6211
- # @!attribute labels
6212
- # One or more label categories supplied with the report or moderation decision.
6213
- #
6214
- # @return [Array<String>]
6215
- required :labels, SafetyKit::Internal::Type::ArrayOf[String]
6216
-
6217
6224
  # @!attribute source_id
6218
6225
  # Stable identifier within source_type. Examples: moderator@example.com or
6219
6226
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
@@ -6275,6 +6282,13 @@ module SafetyKit
6275
6282
  # @return [String, nil]
6276
6283
  optional :idempotency_key, String
6277
6284
 
6285
+ # @!attribute labels
6286
+ # Label categories the decision determined apply to the target. At least one of
6287
+ # labels or negative_labels is required.
6288
+ #
6289
+ # @return [Array<String>, nil]
6290
+ optional :labels, SafetyKit::Internal::Type::ArrayOf[String]
6291
+
6278
6292
  # @!attribute metadata
6279
6293
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6280
6294
  # be strings, numbers, booleans, or arrays of those scalar values.
@@ -6283,6 +6297,14 @@ module SafetyKit
6283
6297
  optional :metadata,
6284
6298
  -> { SafetyKit::Internal::Type::HashOf[union: SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::Metadata] }
6285
6299
 
6300
+ # @!attribute negative_labels
6301
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6302
+ # the target, such as a manual review that clears a user reported for spam. A
6303
+ # label cannot appear in both labels and negative_labels.
6304
+ #
6305
+ # @return [Array<String>, nil]
6306
+ optional :negative_labels, SafetyKit::Internal::Type::ArrayOf[String]
6307
+
6286
6308
  # @!attribute resources_used
6287
6309
  # Reusable resources observed during the event. Use this for emails, phone
6288
6310
  # numbers, names, addresses, social handles, URLs, payment identifiers,
@@ -6304,19 +6326,19 @@ module SafetyKit
6304
6326
  # @return [String, nil]
6305
6327
  optional :target_user_id, String
6306
6328
 
6307
- # @!method initialize(event_name:, labels:, source_id:, source_type:, timestamp:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, metadata: nil, resources_used: nil, target_content_id: nil, target_user_id: nil, type: :moderation_decision)
6329
+ # @!method initialize(event_name:, source_id:, source_type:, timestamp:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, labels: nil, metadata: nil, negative_labels: nil, resources_used: nil, target_content_id: nil, target_user_id: nil, type: :moderation_decision)
6308
6330
  # Some parameter documentations has been truncated, see
6309
6331
  # {SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision}
6310
6332
  # for more details.
6311
6333
  #
6312
6334
  # A moderation label or decision from an automated enforcement system or manual
6313
6335
  # review workflow. Do not send user_id; use source_type and source_id for
6314
- # attribution.
6336
+ # attribution. Use labels for categories the decision applied and negative_labels
6337
+ # for categories the decision explicitly reviewed and determined do not apply; at
6338
+ # least one of the two is required.
6315
6339
  #
6316
6340
  # @param event_name [String] Stable, low-cardinality product action name. Use snake_case and put dynamic valu
6317
6341
  #
6318
- # @param labels [Array<String>] One or more label categories supplied with the report or moderation decision.
6319
- #
6320
6342
  # @param source_id [String] Stable identifier within source_type. Examples: moderator@example.com or 550e840
6321
6343
  #
6322
6344
  # @param source_type [Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::SourceType] Coarse attribution category for the moderation decision source. Supported values
@@ -6331,8 +6353,12 @@ module SafetyKit
6331
6353
  #
6332
6354
  # @param idempotency_key [String] Optional caller-provided key used to make retries of this individual event idemp
6333
6355
  #
6356
+ # @param labels [Array<String>] Label categories the decision determined apply to the target. At least one of la
6357
+ #
6334
6358
  # @param metadata [Hash{Symbol=>String, Float, Boolean, Array<String, Float, Boolean>}] Non-PII product context for filtering, segmentation, and debugging. Values may b
6335
6359
  #
6360
+ # @param negative_labels [Array<String>] Label categories the decision explicitly reviewed and determined do NOT apply to
6361
+ #
6336
6362
  # @param resources_used [Array<SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::ResourcesUsed::EntityIDResource, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::ResourcesUsed::UnionMember1>] Reusable resources observed during the event. Use this for emails, phone numbers
6337
6363
  #
6338
6364
  # @param target_content_id [String] Your stable identifier for the content being reported.
@@ -51,7 +51,7 @@ module SafetyKit
51
51
  # A user appeals a moderation action taken against them. Use user_id for the appealing user, appealed_decision_id to reference the decision being appealed, and content and content_id for the appeal itself.
52
52
  variant -> { SafetyKit::Beta::EventCreateParams::Body::AppealEventRequest }
53
53
 
54
- # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution.
54
+ # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution. Use labels for categories the decision applied and negative_labels for categories the decision explicitly reviewed and determined do not apply; at least one of the two is required.
55
55
  variant -> { SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest }
56
56
 
57
57
  variant -> { SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8Array }
@@ -2933,12 +2933,6 @@ module SafetyKit
2933
2933
  # @return [String]
2934
2934
  required :event_name, String
2935
2935
 
2936
- # @!attribute labels
2937
- # One or more label categories supplied with the report or moderation decision.
2938
- #
2939
- # @return [Array<String>]
2940
- required :labels, SafetyKit::Internal::Type::ArrayOf[String]
2941
-
2942
2936
  # @!attribute source_id
2943
2937
  # Stable identifier within source_type. Examples: moderator@example.com or
2944
2938
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
@@ -3001,6 +2995,13 @@ module SafetyKit
3001
2995
  # @return [String, nil]
3002
2996
  optional :idempotency_key, String
3003
2997
 
2998
+ # @!attribute labels
2999
+ # Label categories the decision determined apply to the target. At least one of
3000
+ # labels or negative_labels is required.
3001
+ #
3002
+ # @return [Array<String>, nil]
3003
+ optional :labels, SafetyKit::Internal::Type::ArrayOf[String]
3004
+
3004
3005
  # @!attribute metadata
3005
3006
  # Non-PII product context for filtering, segmentation, and debugging. Values may
3006
3007
  # be strings, numbers, booleans, or arrays of those scalar values.
@@ -3009,6 +3010,14 @@ module SafetyKit
3009
3010
  optional :metadata,
3010
3011
  -> { SafetyKit::Internal::Type::HashOf[union: SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::Metadata] }
3011
3012
 
3013
+ # @!attribute negative_labels
3014
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
3015
+ # the target, such as a manual review that clears a user reported for spam. A
3016
+ # label cannot appear in both labels and negative_labels.
3017
+ #
3018
+ # @return [Array<String>, nil]
3019
+ optional :negative_labels, SafetyKit::Internal::Type::ArrayOf[String]
3020
+
3012
3021
  # @!attribute resources_used
3013
3022
  # Reusable resources observed during the event. Use this for emails, phone
3014
3023
  # numbers, names, addresses, social handles, URLs, payment identifiers,
@@ -3030,19 +3039,19 @@ module SafetyKit
3030
3039
  # @return [String, nil]
3031
3040
  optional :target_user_id, String
3032
3041
 
3033
- # @!method initialize(event_name:, labels:, source_id:, source_type:, timestamp:, type:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, metadata: nil, resources_used: nil, target_content_id: nil, target_user_id: nil)
3042
+ # @!method initialize(event_name:, source_id:, source_type:, timestamp:, type:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, labels: nil, metadata: nil, negative_labels: nil, resources_used: nil, target_content_id: nil, target_user_id: nil)
3034
3043
  # Some parameter documentations has been truncated, see
3035
3044
  # {SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest}
3036
3045
  # for more details.
3037
3046
  #
3038
3047
  # A moderation label or decision from an automated enforcement system or manual
3039
3048
  # review workflow. Do not send user_id; use source_type and source_id for
3040
- # attribution.
3049
+ # attribution. Use labels for categories the decision applied and negative_labels
3050
+ # for categories the decision explicitly reviewed and determined do not apply; at
3051
+ # least one of the two is required.
3041
3052
  #
3042
3053
  # @param event_name [String] Stable, low-cardinality product action name. Use snake_case and put dynamic valu
3043
3054
  #
3044
- # @param labels [Array<String>] One or more label categories supplied with the report or moderation decision.
3045
- #
3046
3055
  # @param source_id [String] Stable identifier within source_type. Examples: moderator@example.com or 550e840
3047
3056
  #
3048
3057
  # @param source_type [Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::SourceType] Coarse attribution category for the moderation decision source. Supported values
@@ -3059,8 +3068,12 @@ module SafetyKit
3059
3068
  #
3060
3069
  # @param idempotency_key [String] Optional caller-provided key used to make retries of this individual event idemp
3061
3070
  #
3071
+ # @param labels [Array<String>] Label categories the decision determined apply to the target. At least one of la
3072
+ #
3062
3073
  # @param metadata [Hash{Symbol=>String, Float, Boolean, Array<String, Float, Boolean>}] Non-PII product context for filtering, segmentation, and debugging. Values may b
3063
3074
  #
3075
+ # @param negative_labels [Array<String>] Label categories the decision explicitly reviewed and determined do NOT apply to
3076
+ #
3064
3077
  # @param resources_used [Array<SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::ResourcesUsed::EntityIDResource, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::ResourcesUsed::UnionMember1>] Reusable resources observed during the event. Use this for emails, phone numbers
3065
3078
  #
3066
3079
  # @param target_content_id [String] Your stable identifier for the content being reported.
@@ -3399,7 +3412,7 @@ module SafetyKit
3399
3412
  # A user appeals a moderation action taken against them. Use user_id for the appealing user, appealed_decision_id to reference the decision being appealed, and content and content_id for the appeal itself.
3400
3413
  variant :appeal, -> { SafetyKit::Beta::EventCreateParams::Body::UnionMember8::Appeal }
3401
3414
 
3402
- # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution.
3415
+ # A moderation label or decision from an automated enforcement system or manual review workflow. Do not send user_id; use source_type and source_id for attribution. Use labels for categories the decision applied and negative_labels for categories the decision explicitly reviewed and determined do not apply; at least one of the two is required.
3403
3416
  variant :moderation_decision,
3404
3417
  -> { SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision }
3405
3418
 
@@ -6211,12 +6224,6 @@ module SafetyKit
6211
6224
  # @return [String]
6212
6225
  required :event_name, String
6213
6226
 
6214
- # @!attribute labels
6215
- # One or more label categories supplied with the report or moderation decision.
6216
- #
6217
- # @return [Array<String>]
6218
- required :labels, SafetyKit::Internal::Type::ArrayOf[String]
6219
-
6220
6227
  # @!attribute source_id
6221
6228
  # Stable identifier within source_type. Examples: moderator@example.com or
6222
6229
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
@@ -6278,6 +6285,13 @@ module SafetyKit
6278
6285
  # @return [String, nil]
6279
6286
  optional :idempotency_key, String
6280
6287
 
6288
+ # @!attribute labels
6289
+ # Label categories the decision determined apply to the target. At least one of
6290
+ # labels or negative_labels is required.
6291
+ #
6292
+ # @return [Array<String>, nil]
6293
+ optional :labels, SafetyKit::Internal::Type::ArrayOf[String]
6294
+
6281
6295
  # @!attribute metadata
6282
6296
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6283
6297
  # be strings, numbers, booleans, or arrays of those scalar values.
@@ -6286,6 +6300,14 @@ module SafetyKit
6286
6300
  optional :metadata,
6287
6301
  -> { SafetyKit::Internal::Type::HashOf[union: SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::Metadata] }
6288
6302
 
6303
+ # @!attribute negative_labels
6304
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6305
+ # the target, such as a manual review that clears a user reported for spam. A
6306
+ # label cannot appear in both labels and negative_labels.
6307
+ #
6308
+ # @return [Array<String>, nil]
6309
+ optional :negative_labels, SafetyKit::Internal::Type::ArrayOf[String]
6310
+
6289
6311
  # @!attribute resources_used
6290
6312
  # Reusable resources observed during the event. Use this for emails, phone
6291
6313
  # numbers, names, addresses, social handles, URLs, payment identifiers,
@@ -6307,19 +6329,19 @@ module SafetyKit
6307
6329
  # @return [String, nil]
6308
6330
  optional :target_user_id, String
6309
6331
 
6310
- # @!method initialize(event_name:, labels:, source_id:, source_type:, timestamp:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, metadata: nil, resources_used: nil, target_content_id: nil, target_user_id: nil, type: :moderation_decision)
6332
+ # @!method initialize(event_name:, source_id:, source_type:, timestamp:, client_info: nil, content: nil, content_id: nil, idempotency_key: nil, labels: nil, metadata: nil, negative_labels: nil, resources_used: nil, target_content_id: nil, target_user_id: nil, type: :moderation_decision)
6311
6333
  # Some parameter documentations has been truncated, see
6312
6334
  # {SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision}
6313
6335
  # for more details.
6314
6336
  #
6315
6337
  # A moderation label or decision from an automated enforcement system or manual
6316
6338
  # review workflow. Do not send user_id; use source_type and source_id for
6317
- # attribution.
6339
+ # attribution. Use labels for categories the decision applied and negative_labels
6340
+ # for categories the decision explicitly reviewed and determined do not apply; at
6341
+ # least one of the two is required.
6318
6342
  #
6319
6343
  # @param event_name [String] Stable, low-cardinality product action name. Use snake_case and put dynamic valu
6320
6344
  #
6321
- # @param labels [Array<String>] One or more label categories supplied with the report or moderation decision.
6322
- #
6323
6345
  # @param source_id [String] Stable identifier within source_type. Examples: moderator@example.com or 550e840
6324
6346
  #
6325
6347
  # @param source_type [Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::SourceType] Coarse attribution category for the moderation decision source. Supported values
@@ -6334,8 +6356,12 @@ module SafetyKit
6334
6356
  #
6335
6357
  # @param idempotency_key [String] Optional caller-provided key used to make retries of this individual event idemp
6336
6358
  #
6359
+ # @param labels [Array<String>] Label categories the decision determined apply to the target. At least one of la
6360
+ #
6337
6361
  # @param metadata [Hash{Symbol=>String, Float, Boolean, Array<String, Float, Boolean>}] Non-PII product context for filtering, segmentation, and debugging. Values may b
6338
6362
  #
6363
+ # @param negative_labels [Array<String>] Label categories the decision explicitly reviewed and determined do NOT apply to
6364
+ #
6339
6365
  # @param resources_used [Array<SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::ResourcesUsed::EntityIDResource, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::ResourcesUsed::UnionMember1>] Reusable resources observed during the event. Use this for emails, phone numbers
6340
6366
  #
6341
6367
  # @param target_content_id [String] Your stable identifier for the content being reported.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SafetyKit
4
- VERSION = "0.60.0"
4
+ VERSION = "0.61.0"
5
5
  end
@@ -6177,10 +6177,6 @@ module SafetyKit
6177
6177
  sig { returns(String) }
6178
6178
  attr_accessor :event_name
6179
6179
 
6180
- # One or more label categories supplied with the report or moderation decision.
6181
- sig { returns(T::Array[String]) }
6182
- attr_accessor :labels
6183
-
6184
6180
  # Stable identifier within source_type. Examples: moderator@example.com or
6185
6181
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
6186
6182
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -6275,6 +6271,14 @@ module SafetyKit
6275
6271
  sig { params(idempotency_key: String).void }
6276
6272
  attr_writer :idempotency_key
6277
6273
 
6274
+ # Label categories the decision determined apply to the target. At least one of
6275
+ # labels or negative_labels is required.
6276
+ sig { returns(T.nilable(T::Array[String])) }
6277
+ attr_reader :labels
6278
+
6279
+ sig { params(labels: T::Array[String]).void }
6280
+ attr_writer :labels
6281
+
6278
6282
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6279
6283
  # be strings, numbers, booleans, or arrays of those scalar values.
6280
6284
  sig do
@@ -6300,6 +6304,15 @@ module SafetyKit
6300
6304
  end
6301
6305
  attr_writer :metadata
6302
6306
 
6307
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6308
+ # the target, such as a manual review that clears a user reported for spam. A
6309
+ # label cannot appear in both labels and negative_labels.
6310
+ sig { returns(T.nilable(T::Array[String])) }
6311
+ attr_reader :negative_labels
6312
+
6313
+ sig { params(negative_labels: T::Array[String]).void }
6314
+ attr_writer :negative_labels
6315
+
6303
6316
  # Reusable resources observed during the event. Use this for emails, phone
6304
6317
  # numbers, names, addresses, social handles, URLs, payment identifiers,
6305
6318
  # caller-defined ids, or similar identifiers.
@@ -6346,11 +6359,12 @@ module SafetyKit
6346
6359
 
6347
6360
  # A moderation label or decision from an automated enforcement system or manual
6348
6361
  # review workflow. Do not send user_id; use source_type and source_id for
6349
- # attribution.
6362
+ # attribution. Use labels for categories the decision applied and negative_labels
6363
+ # for categories the decision explicitly reviewed and determined do not apply; at
6364
+ # least one of the two is required.
6350
6365
  sig do
6351
6366
  params(
6352
6367
  event_name: String,
6353
- labels: T::Array[String],
6354
6368
  source_id: String,
6355
6369
  source_type:
6356
6370
  SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::SourceType::OrSymbol,
@@ -6368,11 +6382,13 @@ module SafetyKit
6368
6382
  ],
6369
6383
  content_id: String,
6370
6384
  idempotency_key: String,
6385
+ labels: T::Array[String],
6371
6386
  metadata:
6372
6387
  T::Hash[
6373
6388
  Symbol,
6374
6389
  SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::Metadata::Variants
6375
6390
  ],
6391
+ negative_labels: T::Array[String],
6376
6392
  resources_used:
6377
6393
  T::Array[
6378
6394
  T.any(
@@ -6388,8 +6404,6 @@ module SafetyKit
6388
6404
  # Stable, low-cardinality product action name. Use snake_case and put dynamic
6389
6405
  # values in typed fields, content, resources_used, or metadata.
6390
6406
  event_name:,
6391
- # One or more label categories supplied with the report or moderation decision.
6392
- labels:,
6393
6407
  # Stable identifier within source_type. Examples: moderator@example.com or
6394
6408
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
6395
6409
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -6416,9 +6430,16 @@ module SafetyKit
6416
6430
  # Optional caller-provided key used to make retries of this individual event
6417
6431
  # idempotent. Reuse the same key only for retries of the same logical event.
6418
6432
  idempotency_key: nil,
6433
+ # Label categories the decision determined apply to the target. At least one of
6434
+ # labels or negative_labels is required.
6435
+ labels: nil,
6419
6436
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6420
6437
  # be strings, numbers, booleans, or arrays of those scalar values.
6421
6438
  metadata: nil,
6439
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6440
+ # the target, such as a manual review that clears a user reported for spam. A
6441
+ # label cannot appear in both labels and negative_labels.
6442
+ negative_labels: nil,
6422
6443
  # Reusable resources observed during the event. Use this for emails, phone
6423
6444
  # numbers, names, addresses, social handles, URLs, payment identifiers,
6424
6445
  # caller-defined ids, or similar identifiers.
@@ -6434,7 +6455,6 @@ module SafetyKit
6434
6455
  override.returns(
6435
6456
  {
6436
6457
  event_name: String,
6437
- labels: T::Array[String],
6438
6458
  source_id: String,
6439
6459
  source_type:
6440
6460
  SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::SourceType::OrSymbol,
@@ -6452,11 +6472,13 @@ module SafetyKit
6452
6472
  ],
6453
6473
  content_id: String,
6454
6474
  idempotency_key: String,
6475
+ labels: T::Array[String],
6455
6476
  metadata:
6456
6477
  T::Hash[
6457
6478
  Symbol,
6458
6479
  SafetyKit::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::Metadata::Variants
6459
6480
  ],
6481
+ negative_labels: T::Array[String],
6460
6482
  resources_used:
6461
6483
  T::Array[
6462
6484
  T.any(
@@ -12904,10 +12926,6 @@ module SafetyKit
12904
12926
  sig { returns(String) }
12905
12927
  attr_accessor :event_name
12906
12928
 
12907
- # One or more label categories supplied with the report or moderation decision.
12908
- sig { returns(T::Array[String]) }
12909
- attr_accessor :labels
12910
-
12911
12929
  # Stable identifier within source_type. Examples: moderator@example.com or
12912
12930
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
12913
12931
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -12998,6 +13016,14 @@ module SafetyKit
12998
13016
  sig { params(idempotency_key: String).void }
12999
13017
  attr_writer :idempotency_key
13000
13018
 
13019
+ # Label categories the decision determined apply to the target. At least one of
13020
+ # labels or negative_labels is required.
13021
+ sig { returns(T.nilable(T::Array[String])) }
13022
+ attr_reader :labels
13023
+
13024
+ sig { params(labels: T::Array[String]).void }
13025
+ attr_writer :labels
13026
+
13001
13027
  # Non-PII product context for filtering, segmentation, and debugging. Values may
13002
13028
  # be strings, numbers, booleans, or arrays of those scalar values.
13003
13029
  sig do
@@ -13023,6 +13049,15 @@ module SafetyKit
13023
13049
  end
13024
13050
  attr_writer :metadata
13025
13051
 
13052
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
13053
+ # the target, such as a manual review that clears a user reported for spam. A
13054
+ # label cannot appear in both labels and negative_labels.
13055
+ sig { returns(T.nilable(T::Array[String])) }
13056
+ attr_reader :negative_labels
13057
+
13058
+ sig { params(negative_labels: T::Array[String]).void }
13059
+ attr_writer :negative_labels
13060
+
13026
13061
  # Reusable resources observed during the event. Use this for emails, phone
13027
13062
  # numbers, names, addresses, social handles, URLs, payment identifiers,
13028
13063
  # caller-defined ids, or similar identifiers.
@@ -13069,11 +13104,12 @@ module SafetyKit
13069
13104
 
13070
13105
  # A moderation label or decision from an automated enforcement system or manual
13071
13106
  # review workflow. Do not send user_id; use source_type and source_id for
13072
- # attribution.
13107
+ # attribution. Use labels for categories the decision applied and negative_labels
13108
+ # for categories the decision explicitly reviewed and determined do not apply; at
13109
+ # least one of the two is required.
13073
13110
  sig do
13074
13111
  params(
13075
13112
  event_name: String,
13076
- labels: T::Array[String],
13077
13113
  source_id: String,
13078
13114
  source_type:
13079
13115
  SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::SourceType::OrSymbol,
@@ -13089,11 +13125,13 @@ module SafetyKit
13089
13125
  ],
13090
13126
  content_id: String,
13091
13127
  idempotency_key: String,
13128
+ labels: T::Array[String],
13092
13129
  metadata:
13093
13130
  T::Hash[
13094
13131
  Symbol,
13095
13132
  SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::Metadata::Variants
13096
13133
  ],
13134
+ negative_labels: T::Array[String],
13097
13135
  resources_used:
13098
13136
  T::Array[
13099
13137
  T.any(
@@ -13110,8 +13148,6 @@ module SafetyKit
13110
13148
  # Stable, low-cardinality product action name. Use snake_case and put dynamic
13111
13149
  # values in typed fields, content, resources_used, or metadata.
13112
13150
  event_name:,
13113
- # One or more label categories supplied with the report or moderation decision.
13114
- labels:,
13115
13151
  # Stable identifier within source_type. Examples: moderator@example.com or
13116
13152
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
13117
13153
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -13137,9 +13173,16 @@ module SafetyKit
13137
13173
  # Optional caller-provided key used to make retries of this individual event
13138
13174
  # idempotent. Reuse the same key only for retries of the same logical event.
13139
13175
  idempotency_key: nil,
13176
+ # Label categories the decision determined apply to the target. At least one of
13177
+ # labels or negative_labels is required.
13178
+ labels: nil,
13140
13179
  # Non-PII product context for filtering, segmentation, and debugging. Values may
13141
13180
  # be strings, numbers, booleans, or arrays of those scalar values.
13142
13181
  metadata: nil,
13182
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
13183
+ # the target, such as a manual review that clears a user reported for spam. A
13184
+ # label cannot appear in both labels and negative_labels.
13185
+ negative_labels: nil,
13143
13186
  # Reusable resources observed during the event. Use this for emails, phone
13144
13187
  # numbers, names, addresses, social handles, URLs, payment identifiers,
13145
13188
  # caller-defined ids, or similar identifiers.
@@ -13156,7 +13199,6 @@ module SafetyKit
13156
13199
  override.returns(
13157
13200
  {
13158
13201
  event_name: String,
13159
- labels: T::Array[String],
13160
13202
  source_id: String,
13161
13203
  source_type:
13162
13204
  SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::SourceType::OrSymbol,
@@ -13173,11 +13215,13 @@ module SafetyKit
13173
13215
  ],
13174
13216
  content_id: String,
13175
13217
  idempotency_key: String,
13218
+ labels: T::Array[String],
13176
13219
  metadata:
13177
13220
  T::Hash[
13178
13221
  Symbol,
13179
13222
  SafetyKit::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::Metadata::Variants
13180
13223
  ],
13224
+ negative_labels: T::Array[String],
13181
13225
  resources_used:
13182
13226
  T::Array[
13183
13227
  T.any(
@@ -6182,10 +6182,6 @@ module SafetyKit
6182
6182
  sig { returns(String) }
6183
6183
  attr_accessor :event_name
6184
6184
 
6185
- # One or more label categories supplied with the report or moderation decision.
6186
- sig { returns(T::Array[String]) }
6187
- attr_accessor :labels
6188
-
6189
6185
  # Stable identifier within source_type. Examples: moderator@example.com or
6190
6186
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
6191
6187
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -6280,6 +6276,14 @@ module SafetyKit
6280
6276
  sig { params(idempotency_key: String).void }
6281
6277
  attr_writer :idempotency_key
6282
6278
 
6279
+ # Label categories the decision determined apply to the target. At least one of
6280
+ # labels or negative_labels is required.
6281
+ sig { returns(T.nilable(T::Array[String])) }
6282
+ attr_reader :labels
6283
+
6284
+ sig { params(labels: T::Array[String]).void }
6285
+ attr_writer :labels
6286
+
6283
6287
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6284
6288
  # be strings, numbers, booleans, or arrays of those scalar values.
6285
6289
  sig do
@@ -6305,6 +6309,15 @@ module SafetyKit
6305
6309
  end
6306
6310
  attr_writer :metadata
6307
6311
 
6312
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6313
+ # the target, such as a manual review that clears a user reported for spam. A
6314
+ # label cannot appear in both labels and negative_labels.
6315
+ sig { returns(T.nilable(T::Array[String])) }
6316
+ attr_reader :negative_labels
6317
+
6318
+ sig { params(negative_labels: T::Array[String]).void }
6319
+ attr_writer :negative_labels
6320
+
6308
6321
  # Reusable resources observed during the event. Use this for emails, phone
6309
6322
  # numbers, names, addresses, social handles, URLs, payment identifiers,
6310
6323
  # caller-defined ids, or similar identifiers.
@@ -6351,11 +6364,12 @@ module SafetyKit
6351
6364
 
6352
6365
  # A moderation label or decision from an automated enforcement system or manual
6353
6366
  # review workflow. Do not send user_id; use source_type and source_id for
6354
- # attribution.
6367
+ # attribution. Use labels for categories the decision applied and negative_labels
6368
+ # for categories the decision explicitly reviewed and determined do not apply; at
6369
+ # least one of the two is required.
6355
6370
  sig do
6356
6371
  params(
6357
6372
  event_name: String,
6358
- labels: T::Array[String],
6359
6373
  source_id: String,
6360
6374
  source_type:
6361
6375
  SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::SourceType::OrSymbol,
@@ -6373,11 +6387,13 @@ module SafetyKit
6373
6387
  ],
6374
6388
  content_id: String,
6375
6389
  idempotency_key: String,
6390
+ labels: T::Array[String],
6376
6391
  metadata:
6377
6392
  T::Hash[
6378
6393
  Symbol,
6379
6394
  SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::Metadata::Variants
6380
6395
  ],
6396
+ negative_labels: T::Array[String],
6381
6397
  resources_used:
6382
6398
  T::Array[
6383
6399
  T.any(
@@ -6393,8 +6409,6 @@ module SafetyKit
6393
6409
  # Stable, low-cardinality product action name. Use snake_case and put dynamic
6394
6410
  # values in typed fields, content, resources_used, or metadata.
6395
6411
  event_name:,
6396
- # One or more label categories supplied with the report or moderation decision.
6397
- labels:,
6398
6412
  # Stable identifier within source_type. Examples: moderator@example.com or
6399
6413
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
6400
6414
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -6421,9 +6435,16 @@ module SafetyKit
6421
6435
  # Optional caller-provided key used to make retries of this individual event
6422
6436
  # idempotent. Reuse the same key only for retries of the same logical event.
6423
6437
  idempotency_key: nil,
6438
+ # Label categories the decision determined apply to the target. At least one of
6439
+ # labels or negative_labels is required.
6440
+ labels: nil,
6424
6441
  # Non-PII product context for filtering, segmentation, and debugging. Values may
6425
6442
  # be strings, numbers, booleans, or arrays of those scalar values.
6426
6443
  metadata: nil,
6444
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
6445
+ # the target, such as a manual review that clears a user reported for spam. A
6446
+ # label cannot appear in both labels and negative_labels.
6447
+ negative_labels: nil,
6427
6448
  # Reusable resources observed during the event. Use this for emails, phone
6428
6449
  # numbers, names, addresses, social handles, URLs, payment identifiers,
6429
6450
  # caller-defined ids, or similar identifiers.
@@ -6439,7 +6460,6 @@ module SafetyKit
6439
6460
  override.returns(
6440
6461
  {
6441
6462
  event_name: String,
6442
- labels: T::Array[String],
6443
6463
  source_id: String,
6444
6464
  source_type:
6445
6465
  SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::SourceType::OrSymbol,
@@ -6457,11 +6477,13 @@ module SafetyKit
6457
6477
  ],
6458
6478
  content_id: String,
6459
6479
  idempotency_key: String,
6480
+ labels: T::Array[String],
6460
6481
  metadata:
6461
6482
  T::Hash[
6462
6483
  Symbol,
6463
6484
  SafetyKit::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::Metadata::Variants
6464
6485
  ],
6486
+ negative_labels: T::Array[String],
6465
6487
  resources_used:
6466
6488
  T::Array[
6467
6489
  T.any(
@@ -12923,10 +12945,6 @@ module SafetyKit
12923
12945
  sig { returns(String) }
12924
12946
  attr_accessor :event_name
12925
12947
 
12926
- # One or more label categories supplied with the report or moderation decision.
12927
- sig { returns(T::Array[String]) }
12928
- attr_accessor :labels
12929
-
12930
12948
  # Stable identifier within source_type. Examples: moderator@example.com or
12931
12949
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
12932
12950
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -13017,6 +13035,14 @@ module SafetyKit
13017
13035
  sig { params(idempotency_key: String).void }
13018
13036
  attr_writer :idempotency_key
13019
13037
 
13038
+ # Label categories the decision determined apply to the target. At least one of
13039
+ # labels or negative_labels is required.
13040
+ sig { returns(T.nilable(T::Array[String])) }
13041
+ attr_reader :labels
13042
+
13043
+ sig { params(labels: T::Array[String]).void }
13044
+ attr_writer :labels
13045
+
13020
13046
  # Non-PII product context for filtering, segmentation, and debugging. Values may
13021
13047
  # be strings, numbers, booleans, or arrays of those scalar values.
13022
13048
  sig do
@@ -13042,6 +13068,15 @@ module SafetyKit
13042
13068
  end
13043
13069
  attr_writer :metadata
13044
13070
 
13071
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
13072
+ # the target, such as a manual review that clears a user reported for spam. A
13073
+ # label cannot appear in both labels and negative_labels.
13074
+ sig { returns(T.nilable(T::Array[String])) }
13075
+ attr_reader :negative_labels
13076
+
13077
+ sig { params(negative_labels: T::Array[String]).void }
13078
+ attr_writer :negative_labels
13079
+
13045
13080
  # Reusable resources observed during the event. Use this for emails, phone
13046
13081
  # numbers, names, addresses, social handles, URLs, payment identifiers,
13047
13082
  # caller-defined ids, or similar identifiers.
@@ -13088,11 +13123,12 @@ module SafetyKit
13088
13123
 
13089
13124
  # A moderation label or decision from an automated enforcement system or manual
13090
13125
  # review workflow. Do not send user_id; use source_type and source_id for
13091
- # attribution.
13126
+ # attribution. Use labels for categories the decision applied and negative_labels
13127
+ # for categories the decision explicitly reviewed and determined do not apply; at
13128
+ # least one of the two is required.
13092
13129
  sig do
13093
13130
  params(
13094
13131
  event_name: String,
13095
- labels: T::Array[String],
13096
13132
  source_id: String,
13097
13133
  source_type:
13098
13134
  SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::SourceType::OrSymbol,
@@ -13108,11 +13144,13 @@ module SafetyKit
13108
13144
  ],
13109
13145
  content_id: String,
13110
13146
  idempotency_key: String,
13147
+ labels: T::Array[String],
13111
13148
  metadata:
13112
13149
  T::Hash[
13113
13150
  Symbol,
13114
13151
  SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::Metadata::Variants
13115
13152
  ],
13153
+ negative_labels: T::Array[String],
13116
13154
  resources_used:
13117
13155
  T::Array[
13118
13156
  T.any(
@@ -13129,8 +13167,6 @@ module SafetyKit
13129
13167
  # Stable, low-cardinality product action name. Use snake_case and put dynamic
13130
13168
  # values in typed fields, content, resources_used, or metadata.
13131
13169
  event_name:,
13132
- # One or more label categories supplied with the report or moderation decision.
13133
- labels:,
13134
13170
  # Stable identifier within source_type. Examples: moderator@example.com or
13135
13171
  # 550e8400-e29b-41d4-a716-446655440000 for expert_labeler or human_moderator,
13136
13172
  # automated_review_v2026_06_04 for automation, or <vendor_name>-v2.1 for vendor.
@@ -13156,9 +13192,16 @@ module SafetyKit
13156
13192
  # Optional caller-provided key used to make retries of this individual event
13157
13193
  # idempotent. Reuse the same key only for retries of the same logical event.
13158
13194
  idempotency_key: nil,
13195
+ # Label categories the decision determined apply to the target. At least one of
13196
+ # labels or negative_labels is required.
13197
+ labels: nil,
13159
13198
  # Non-PII product context for filtering, segmentation, and debugging. Values may
13160
13199
  # be strings, numbers, booleans, or arrays of those scalar values.
13161
13200
  metadata: nil,
13201
+ # Label categories the decision explicitly reviewed and determined do NOT apply to
13202
+ # the target, such as a manual review that clears a user reported for spam. A
13203
+ # label cannot appear in both labels and negative_labels.
13204
+ negative_labels: nil,
13162
13205
  # Reusable resources observed during the event. Use this for emails, phone
13163
13206
  # numbers, names, addresses, social handles, URLs, payment identifiers,
13164
13207
  # caller-defined ids, or similar identifiers.
@@ -13175,7 +13218,6 @@ module SafetyKit
13175
13218
  override.returns(
13176
13219
  {
13177
13220
  event_name: String,
13178
- labels: T::Array[String],
13179
13221
  source_id: String,
13180
13222
  source_type:
13181
13223
  SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::SourceType::OrSymbol,
@@ -13192,11 +13234,13 @@ module SafetyKit
13192
13234
  ],
13193
13235
  content_id: String,
13194
13236
  idempotency_key: String,
13237
+ labels: T::Array[String],
13195
13238
  metadata:
13196
13239
  T::Hash[
13197
13240
  Symbol,
13198
13241
  SafetyKit::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::Metadata::Variants
13199
13242
  ],
13243
+ negative_labels: T::Array[String],
13200
13244
  resources_used:
13201
13245
  T::Array[
13202
13246
  T.any(
@@ -2286,7 +2286,6 @@ module SafetyKit
2286
2286
  type moderation_decision_event_request =
2287
2287
  {
2288
2288
  event_name: String,
2289
- labels: ::Array[String],
2290
2289
  source_id: String,
2291
2290
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::source_type,
2292
2291
  timestamp: Time,
@@ -2295,7 +2294,9 @@ module SafetyKit
2295
2294
  content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::content],
2296
2295
  content_id: String,
2297
2296
  idempotency_key: String,
2297
+ labels: ::Array[String],
2298
2298
  metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata],
2299
+ negative_labels: ::Array[String],
2299
2300
  resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::resources_used],
2300
2301
  target_content_id: String,
2301
2302
  target_user_id: String
@@ -2304,8 +2305,6 @@ module SafetyKit
2304
2305
  class ModerationDecisionEventRequest < SafetyKit::Internal::Type::BaseModel
2305
2306
  attr_accessor event_name: String
2306
2307
 
2307
- attr_accessor labels: ::Array[String]
2308
-
2309
2308
  attr_accessor source_id: String
2310
2309
 
2311
2310
  attr_accessor source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::source_type
@@ -2334,12 +2333,20 @@ module SafetyKit
2334
2333
 
2335
2334
  def idempotency_key=: (String) -> String
2336
2335
 
2336
+ attr_reader labels: ::Array[String]?
2337
+
2338
+ def labels=: (::Array[String]) -> ::Array[String]
2339
+
2337
2340
  attr_reader metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata]?
2338
2341
 
2339
2342
  def metadata=: (
2340
2343
  ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata]
2341
2344
  ) -> ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata]
2342
2345
 
2346
+ attr_reader negative_labels: ::Array[String]?
2347
+
2348
+ def negative_labels=: (::Array[String]) -> ::Array[String]
2349
+
2343
2350
  attr_reader resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::resources_used]?
2344
2351
 
2345
2352
  def resources_used=: (
@@ -2356,7 +2363,6 @@ module SafetyKit
2356
2363
 
2357
2364
  def initialize: (
2358
2365
  event_name: String,
2359
- labels: ::Array[String],
2360
2366
  source_id: String,
2361
2367
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::source_type,
2362
2368
  timestamp: Time,
@@ -2365,7 +2371,9 @@ module SafetyKit
2365
2371
  ?content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::content],
2366
2372
  ?content_id: String,
2367
2373
  ?idempotency_key: String,
2374
+ ?labels: ::Array[String],
2368
2375
  ?metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata],
2376
+ ?negative_labels: ::Array[String],
2369
2377
  ?resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::resources_used],
2370
2378
  ?target_content_id: String,
2371
2379
  ?target_user_id: String
@@ -2373,7 +2381,6 @@ module SafetyKit
2373
2381
 
2374
2382
  def to_hash: -> {
2375
2383
  event_name: String,
2376
- labels: ::Array[String],
2377
2384
  source_id: String,
2378
2385
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::source_type,
2379
2386
  timestamp: Time,
@@ -2382,7 +2389,9 @@ module SafetyKit
2382
2389
  content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::content],
2383
2390
  content_id: String,
2384
2391
  idempotency_key: String,
2392
+ labels: ::Array[String],
2385
2393
  metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::metadata],
2394
+ negative_labels: ::Array[String],
2386
2395
  resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::ModerationDecisionEventRequest::resources_used],
2387
2396
  target_content_id: String,
2388
2397
  target_user_id: String
@@ -4824,7 +4833,6 @@ module SafetyKit
4824
4833
  type moderation_decision =
4825
4834
  {
4826
4835
  event_name: String,
4827
- labels: ::Array[String],
4828
4836
  source_id: String,
4829
4837
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::source_type,
4830
4838
  timestamp: Time,
@@ -4833,7 +4841,9 @@ module SafetyKit
4833
4841
  content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::content],
4834
4842
  content_id: String,
4835
4843
  idempotency_key: String,
4844
+ labels: ::Array[String],
4836
4845
  metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata],
4846
+ negative_labels: ::Array[String],
4837
4847
  resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::resources_used],
4838
4848
  target_content_id: String,
4839
4849
  target_user_id: String
@@ -4842,8 +4852,6 @@ module SafetyKit
4842
4852
  class ModerationDecision < SafetyKit::Internal::Type::BaseModel
4843
4853
  attr_accessor event_name: String
4844
4854
 
4845
- attr_accessor labels: ::Array[String]
4846
-
4847
4855
  attr_accessor source_id: String
4848
4856
 
4849
4857
  attr_accessor source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::source_type
@@ -4872,12 +4880,20 @@ module SafetyKit
4872
4880
 
4873
4881
  def idempotency_key=: (String) -> String
4874
4882
 
4883
+ attr_reader labels: ::Array[String]?
4884
+
4885
+ def labels=: (::Array[String]) -> ::Array[String]
4886
+
4875
4887
  attr_reader metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata]?
4876
4888
 
4877
4889
  def metadata=: (
4878
4890
  ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata]
4879
4891
  ) -> ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata]
4880
4892
 
4893
+ attr_reader negative_labels: ::Array[String]?
4894
+
4895
+ def negative_labels=: (::Array[String]) -> ::Array[String]
4896
+
4881
4897
  attr_reader resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::resources_used]?
4882
4898
 
4883
4899
  def resources_used=: (
@@ -4894,7 +4910,6 @@ module SafetyKit
4894
4910
 
4895
4911
  def initialize: (
4896
4912
  event_name: String,
4897
- labels: ::Array[String],
4898
4913
  source_id: String,
4899
4914
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::source_type,
4900
4915
  timestamp: Time,
@@ -4902,7 +4917,9 @@ module SafetyKit
4902
4917
  ?content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::content],
4903
4918
  ?content_id: String,
4904
4919
  ?idempotency_key: String,
4920
+ ?labels: ::Array[String],
4905
4921
  ?metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata],
4922
+ ?negative_labels: ::Array[String],
4906
4923
  ?resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::resources_used],
4907
4924
  ?target_content_id: String,
4908
4925
  ?target_user_id: String,
@@ -4911,7 +4928,6 @@ module SafetyKit
4911
4928
 
4912
4929
  def to_hash: -> {
4913
4930
  event_name: String,
4914
- labels: ::Array[String],
4915
4931
  source_id: String,
4916
4932
  source_type: SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::source_type,
4917
4933
  timestamp: Time,
@@ -4920,7 +4936,9 @@ module SafetyKit
4920
4936
  content: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::content],
4921
4937
  content_id: String,
4922
4938
  idempotency_key: String,
4939
+ labels: ::Array[String],
4923
4940
  metadata: ::Hash[Symbol, SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::metadata],
4941
+ negative_labels: ::Array[String],
4924
4942
  resources_used: ::Array[SafetyKit::Models::AsyncCreateAsyncParams::Body::UnionMember8::ModerationDecision::resources_used],
4925
4943
  target_content_id: String,
4926
4944
  target_user_id: String
@@ -2290,7 +2290,6 @@ module SafetyKit
2290
2290
  type moderation_decision_event_request =
2291
2291
  {
2292
2292
  event_name: String,
2293
- labels: ::Array[String],
2294
2293
  source_id: String,
2295
2294
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::source_type,
2296
2295
  timestamp: Time,
@@ -2299,7 +2298,9 @@ module SafetyKit
2299
2298
  content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::content],
2300
2299
  content_id: String,
2301
2300
  idempotency_key: String,
2301
+ labels: ::Array[String],
2302
2302
  metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata],
2303
+ negative_labels: ::Array[String],
2303
2304
  resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::resources_used],
2304
2305
  target_content_id: String,
2305
2306
  target_user_id: String
@@ -2308,8 +2309,6 @@ module SafetyKit
2308
2309
  class ModerationDecisionEventRequest < SafetyKit::Internal::Type::BaseModel
2309
2310
  attr_accessor event_name: String
2310
2311
 
2311
- attr_accessor labels: ::Array[String]
2312
-
2313
2312
  attr_accessor source_id: String
2314
2313
 
2315
2314
  attr_accessor source_type: SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::source_type
@@ -2338,12 +2337,20 @@ module SafetyKit
2338
2337
 
2339
2338
  def idempotency_key=: (String) -> String
2340
2339
 
2340
+ attr_reader labels: ::Array[String]?
2341
+
2342
+ def labels=: (::Array[String]) -> ::Array[String]
2343
+
2341
2344
  attr_reader metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata]?
2342
2345
 
2343
2346
  def metadata=: (
2344
2347
  ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata]
2345
2348
  ) -> ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata]
2346
2349
 
2350
+ attr_reader negative_labels: ::Array[String]?
2351
+
2352
+ def negative_labels=: (::Array[String]) -> ::Array[String]
2353
+
2347
2354
  attr_reader resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::resources_used]?
2348
2355
 
2349
2356
  def resources_used=: (
@@ -2360,7 +2367,6 @@ module SafetyKit
2360
2367
 
2361
2368
  def initialize: (
2362
2369
  event_name: String,
2363
- labels: ::Array[String],
2364
2370
  source_id: String,
2365
2371
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::source_type,
2366
2372
  timestamp: Time,
@@ -2369,7 +2375,9 @@ module SafetyKit
2369
2375
  ?content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::content],
2370
2376
  ?content_id: String,
2371
2377
  ?idempotency_key: String,
2378
+ ?labels: ::Array[String],
2372
2379
  ?metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata],
2380
+ ?negative_labels: ::Array[String],
2373
2381
  ?resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::resources_used],
2374
2382
  ?target_content_id: String,
2375
2383
  ?target_user_id: String
@@ -2377,7 +2385,6 @@ module SafetyKit
2377
2385
 
2378
2386
  def to_hash: -> {
2379
2387
  event_name: String,
2380
- labels: ::Array[String],
2381
2388
  source_id: String,
2382
2389
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::source_type,
2383
2390
  timestamp: Time,
@@ -2386,7 +2393,9 @@ module SafetyKit
2386
2393
  content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::content],
2387
2394
  content_id: String,
2388
2395
  idempotency_key: String,
2396
+ labels: ::Array[String],
2389
2397
  metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::metadata],
2398
+ negative_labels: ::Array[String],
2390
2399
  resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::ModerationDecisionEventRequest::resources_used],
2391
2400
  target_content_id: String,
2392
2401
  target_user_id: String
@@ -4828,7 +4837,6 @@ module SafetyKit
4828
4837
  type moderation_decision =
4829
4838
  {
4830
4839
  event_name: String,
4831
- labels: ::Array[String],
4832
4840
  source_id: String,
4833
4841
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::source_type,
4834
4842
  timestamp: Time,
@@ -4837,7 +4845,9 @@ module SafetyKit
4837
4845
  content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::content],
4838
4846
  content_id: String,
4839
4847
  idempotency_key: String,
4848
+ labels: ::Array[String],
4840
4849
  metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata],
4850
+ negative_labels: ::Array[String],
4841
4851
  resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::resources_used],
4842
4852
  target_content_id: String,
4843
4853
  target_user_id: String
@@ -4846,8 +4856,6 @@ module SafetyKit
4846
4856
  class ModerationDecision < SafetyKit::Internal::Type::BaseModel
4847
4857
  attr_accessor event_name: String
4848
4858
 
4849
- attr_accessor labels: ::Array[String]
4850
-
4851
4859
  attr_accessor source_id: String
4852
4860
 
4853
4861
  attr_accessor source_type: SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::source_type
@@ -4876,12 +4884,20 @@ module SafetyKit
4876
4884
 
4877
4885
  def idempotency_key=: (String) -> String
4878
4886
 
4887
+ attr_reader labels: ::Array[String]?
4888
+
4889
+ def labels=: (::Array[String]) -> ::Array[String]
4890
+
4879
4891
  attr_reader metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata]?
4880
4892
 
4881
4893
  def metadata=: (
4882
4894
  ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata]
4883
4895
  ) -> ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata]
4884
4896
 
4897
+ attr_reader negative_labels: ::Array[String]?
4898
+
4899
+ def negative_labels=: (::Array[String]) -> ::Array[String]
4900
+
4885
4901
  attr_reader resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::resources_used]?
4886
4902
 
4887
4903
  def resources_used=: (
@@ -4898,7 +4914,6 @@ module SafetyKit
4898
4914
 
4899
4915
  def initialize: (
4900
4916
  event_name: String,
4901
- labels: ::Array[String],
4902
4917
  source_id: String,
4903
4918
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::source_type,
4904
4919
  timestamp: Time,
@@ -4906,7 +4921,9 @@ module SafetyKit
4906
4921
  ?content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::content],
4907
4922
  ?content_id: String,
4908
4923
  ?idempotency_key: String,
4924
+ ?labels: ::Array[String],
4909
4925
  ?metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata],
4926
+ ?negative_labels: ::Array[String],
4910
4927
  ?resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::resources_used],
4911
4928
  ?target_content_id: String,
4912
4929
  ?target_user_id: String,
@@ -4915,7 +4932,6 @@ module SafetyKit
4915
4932
 
4916
4933
  def to_hash: -> {
4917
4934
  event_name: String,
4918
- labels: ::Array[String],
4919
4935
  source_id: String,
4920
4936
  source_type: SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::source_type,
4921
4937
  timestamp: Time,
@@ -4924,7 +4940,9 @@ module SafetyKit
4924
4940
  content: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::content],
4925
4941
  content_id: String,
4926
4942
  idempotency_key: String,
4943
+ labels: ::Array[String],
4927
4944
  metadata: ::Hash[Symbol, SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::metadata],
4945
+ negative_labels: ::Array[String],
4928
4946
  resources_used: ::Array[SafetyKit::Models::Beta::EventCreateParams::Body::UnionMember8::ModerationDecision::resources_used],
4929
4947
  target_content_id: String,
4930
4948
  target_user_id: String
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: safetykit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.60.0
4
+ version: 0.61.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Safetykit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-08-12 00:00:00.000000000 Z
11
+ date: 2026-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cgi