diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.IQueueItemsClient.ResolveMany.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.IQueueItemsClient.ResolveMany.g.cs index 5a96d9f..cfc3dd4 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.IQueueItemsClient.ResolveMany.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.IQueueItemsClient.ResolveMany.g.cs @@ -6,7 +6,7 @@ public partial interface IQueueItemsClient { /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. @@ -41,7 +41,7 @@ public partial interface IQueueItemsClient global::System.Threading.CancellationToken cancellationToken = default); /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. @@ -76,14 +76,14 @@ public partial interface IQueueItemsClient global::System.Threading.CancellationToken cancellationToken = default); /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. /// /// /// - /// The item IDs to resolve. Up to 100. + /// The items to resolve, up to 100. Each is the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. /// The token to cancel the operation with diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenGetItems.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenGetItems.g.cs index da9d23c..864768e 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenGetItems.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenGetItems.g.cs @@ -6,7 +6,7 @@ public partial interface IReviewQueuesClient { /// /// List queue items
- /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` to resolve or unresolve an item. + /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` or `contentId` to resolve or unresolve an item. ///
/// /// The queue ID. @@ -63,7 +63,7 @@ public partial interface IReviewQueuesClient global::System.Threading.CancellationToken cancellationToken = default); /// /// List queue items
- /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` to resolve or unresolve an item. + /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` or `contentId` to resolve or unresolve an item. ///
/// /// The queue ID. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenResolveItem.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenResolveItem.g.cs index bd458b4..55e15b7 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenResolveItem.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenResolveItem.g.cs @@ -6,13 +6,13 @@ public partial interface IReviewQueuesClient { /// /// Resolve a queue item
- /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. To also take a moderation action, use `POST /actions/execute`. + /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. `itemId` is the item `id` or your `contentId`. To also take a moderation action, use `POST /actions/execute`. ///
/// /// The queue ID. /// /// - /// The item ID to resolve. + /// The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. @@ -37,13 +37,13 @@ public partial interface IReviewQueuesClient global::System.Threading.CancellationToken cancellationToken = default); /// /// Resolve a queue item
- /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. To also take a moderation action, use `POST /actions/execute`. + /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. `itemId` is the item `id` or your `contentId`. To also take a moderation action, use `POST /actions/execute`. ///
/// /// The queue ID. /// /// - /// The item ID to resolve. + /// The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs index f1cf516..7ac47db 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.IReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs @@ -6,13 +6,13 @@ public partial interface IReviewQueuesClient { /// /// Unresolve a queue item
- /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. + /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. `itemId` is the item `id` or your `contentId`. ///
/// /// The queue ID. /// /// - /// The item ID to unresolve. + /// The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. @@ -37,13 +37,13 @@ public partial interface IReviewQueuesClient global::System.Threading.CancellationToken cancellationToken = default); /// /// Unresolve a queue item
- /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. + /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. `itemId` is the item `id` or your `contentId`. ///
/// /// The queue ID. /// /// - /// The item ID to unresolve. + /// The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.IWordlistClient.Delete.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.IWordlistClient.Delete.g.cs new file mode 100644 index 0000000..a2e5c5c --- /dev/null +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.IWordlistClient.Delete.g.cs @@ -0,0 +1,40 @@ +#nullable enable + +namespace ModerationAPI +{ + public partial interface IWordlistClient + { + /// + /// Delete wordlist
+ /// Delete a wordlist and its words. Channels that use the wordlist do not block the delete: the wordlist is removed from their policies. `detachedChannelIds` lists those channels. This cannot be undone. + ///
+ /// + /// ID of the wordlist to delete + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + global::System.Threading.Tasks.Task DeleteAsync( + string id, + string? projectId = default, + global::ModerationAPI.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default); + /// + /// Delete wordlist
+ /// Delete a wordlist and its words. Channels that use the wordlist do not block the delete: the wordlist is removed from their policies. `detachedChannelIds` lists those channels. This cannot be undone. + ///
+ /// + /// ID of the wordlist to delete + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + global::System.Threading.Tasks.Task> DeleteAsResponseAsync( + string id, + string? projectId = default, + global::ModerationAPI.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default); + } +} \ No newline at end of file diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContext.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContext.g.cs index f8ae3ed..a235fcb 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContext.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContext.g.cs @@ -825,6 +825,7 @@ namespace ModerationAPI [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.CreateWordlistResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.WordlistGetWordlistPublicResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.WordlistUpdateResponse))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.DeleteWordlistResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.WordlistWordlistEmbeddingStatusResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.WordlistAddWordsResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::ModerationAPI.WordlistRemoveWordsResponse))] diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContextTypes.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContextTypes.g.cs index 318eb92..b6c99be 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContextTypes.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.JsonSerializerContextTypes.g.cs @@ -1486,255 +1486,259 @@ public sealed partial class JsonSerializerContextTypes /// /// /// - public global::ModerationAPI.WordlistWordlistEmbeddingStatusResponse? Type362 { get; set; } + public global::ModerationAPI.DeleteWordlistResponse? Type362 { get; set; } /// /// /// - public global::ModerationAPI.WordlistAddWordsResponse? Type363 { get; set; } + public global::ModerationAPI.WordlistWordlistEmbeddingStatusResponse? Type363 { get; set; } /// /// /// - public global::ModerationAPI.WordlistRemoveWordsResponse? Type364 { get; set; } + public global::ModerationAPI.WordlistAddWordsResponse? Type364 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponse? Type365 { get; set; } + public global::ModerationAPI.WordlistRemoveWordsResponse? Type365 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseContent? Type366 { get; set; } + public global::ModerationAPI.NewModerateModerateResponse? Type366 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentText? Type367 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseContent? Type367 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentImage? Type368 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentText? Type368 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentVideo? Type369 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentImage? Type369 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentAudio? Type370 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentVideo? Type370 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseAuthor? Type371 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseContentModifiedVariant1ModifiedNestedObjectContentAudio? Type371 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseAuthorBlock? Type372 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseAuthor? Type372 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseAuthorStatus? Type373 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseAuthorBlock? Type373 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseAuthorTrustLevel? Type374 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseAuthorStatus? Type374 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseEvaluation? Type375 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseAuthorTrustLevel? Type375 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseRecommendation? Type376 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseEvaluation? Type376 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseRecommendationAction? Type377 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseRecommendation? Type377 { get; set; } /// /// /// - public global::System.Collections.Generic.IList>? Type378 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseRecommendationAction? Type378 { get; set; } /// /// /// - public global::ModerationAPI.AnyOf? Type379 { get; set; } + public global::System.Collections.Generic.IList>? Type379 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseRecommendationReasonCode? Type380 { get; set; } + public global::ModerationAPI.AnyOf? Type380 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type381 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseRecommendationReasonCode? Type381 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseRecommendationMatchedRule? Type382 { get; set; } + public global::System.Collections.Generic.IList? Type382 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseCasebook? Type383 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseRecommendationMatchedRule? Type383 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseCasebookVerdict? Type384 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseCasebook? Type384 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseCasebookTopic? Type385 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseCasebookVerdict? Type385 { get; set; } /// /// /// - public global::ModerationAPI.OneOf? Type386 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseCasebookTopic? Type386 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieClassifierOutput? Type387 { get; set; } + public global::ModerationAPI.OneOf? Type387 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type388 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieClassifierOutput? Type388 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieClassifierOutputLabel? Type389 { get; set; } + public global::System.Collections.Generic.IList? Type389 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutput? Type390 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieClassifierOutputLabel? Type390 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type391 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutput? Type391 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatche? Type392 { get; set; } + public global::System.Collections.Generic.IList? Type392 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type393 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatche? Type393 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignals? Type394 { get; set; } + public global::System.Collections.Generic.IList? Type394 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignalsBrandImpersonation? Type395 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignals? Type395 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignalsBrandImpersonationMethod? Type396 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignalsBrandImpersonation? Type396 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsight? Type397 { get; set; } + public global::ModerationAPI.NewModerateModerateResponsePolicieEntityMatcherOutputMatcheSignalsBrandImpersonationMethod? Type397 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsightValue? Type398 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsight? Type398 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsightScores? Type399 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsightValue? Type399 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightLanguageInsight? Type400 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightSentimentInsightScores? Type400 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightCuriosityInsight? Type401 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightLanguageInsight? Type401 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightRespectInsight? Type402 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightCuriosityInsight? Type402 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightPersonalStoryInsight? Type403 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightRespectInsight? Type403 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseInsightCompassionInsight? Type404 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightPersonalStoryInsight? Type404 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseMeta? Type405 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseInsightCompassionInsight? Type405 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseMetaStatus? Type406 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseMeta? Type406 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type407 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseMetaStatus? Type407 { get; set; } /// /// /// - public global::ModerationAPI.NewModerateModerateResponseError? Type408 { get; set; } + public global::System.Collections.Generic.IList? Type408 { get; set; } /// /// /// - public global::ModerationAPI.ManagementProjectsListResponse? Type409 { get; set; } + public global::ModerationAPI.NewModerateModerateResponseError? Type409 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type410 { get; set; } + public global::ModerationAPI.ManagementProjectsListResponse? Type410 { get; set; } /// /// /// - public global::ModerationAPI.ManagementProjectsDeleteResponse? Type411 { get; set; } + public global::System.Collections.Generic.IList? Type411 { get; set; } /// /// /// - public global::ModerationAPI.ManagementChannelsListResponse? Type412 { get; set; } + public global::ModerationAPI.ManagementProjectsDeleteResponse? Type412 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type413 { get; set; } + public global::ModerationAPI.ManagementChannelsListResponse? Type413 { get; set; } /// /// /// - public global::ModerationAPI.ManagementChannelsDeleteResponse? Type414 { get; set; } + public global::System.Collections.Generic.IList? Type414 { get; set; } /// /// /// - public global::ModerationAPI.AuthorBlockedWebhookVersion? Type415 { get; set; } + public global::ModerationAPI.ManagementChannelsDeleteResponse? Type415 { get; set; } /// /// /// - public global::ModerationAPI.AuthorUnblockedWebhookVersion? Type416 { get; set; } + public global::ModerationAPI.AuthorBlockedWebhookVersion? Type416 { get; set; } /// /// /// - public global::ModerationAPI.AuthorSuspendedWebhookVersion? Type417 { get; set; } + public global::ModerationAPI.AuthorUnblockedWebhookVersion? Type417 { get; set; } /// /// /// - public global::ModerationAPI.AuthorUpdatedWebhookVersion? Type418 { get; set; } + public global::ModerationAPI.AuthorSuspendedWebhookVersion? Type418 { get; set; } /// /// /// - public global::ModerationAPI.AuthorTrustLevelChangedWebhookVersion? Type419 { get; set; } + public global::ModerationAPI.AuthorUpdatedWebhookVersion? Type419 { get; set; } /// /// /// - public global::ModerationAPI.AuthorActionWebhookVersion? Type420 { get; set; } + public global::ModerationAPI.AuthorTrustLevelChangedWebhookVersion? Type420 { get; set; } /// /// /// - public global::ModerationAPI.QueueItemResolvedWebhookVersion? Type421 { get; set; } + public global::ModerationAPI.AuthorActionWebhookVersion? Type421 { get; set; } /// /// /// - public global::ModerationAPI.QueueItemActionWebhookVersion? Type422 { get; set; } + public global::ModerationAPI.QueueItemResolvedWebhookVersion? Type422 { get; set; } /// /// /// - public global::ModerationAPI.QueueItemRejectedWebhookVersion? Type423 { get; set; } + public global::ModerationAPI.QueueItemActionWebhookVersion? Type423 { get; set; } /// /// /// - public global::ModerationAPI.QueueItemAllowedWebhookVersion? Type424 { get; set; } + public global::ModerationAPI.QueueItemRejectedWebhookVersion? Type424 { get; set; } + /// + /// + /// + public global::ModerationAPI.QueueItemAllowedWebhookVersion? Type425 { get; set; } /// /// diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.Json.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.Json.g.cs new file mode 100644 index 0000000..02e3d36 --- /dev/null +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.Json.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +namespace ModerationAPI +{ + public sealed partial class DeleteWordlistResponse + { + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerContext. + /// + public string ToJson( + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Serialize( + this, + this.GetType(), + jsonSerializerContext); + } + + /// + /// Serializes the current instance to a JSON string using the generated default JsonSerializerContext. + /// + public string ToJson() + { + return ToJson(global::ModerationAPI.SourceGenerationContext.Default); + } + + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public string ToJson( + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return ToJson(global::ModerationAPI.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Serialize( + this, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerContext. + /// + public static global::ModerationAPI.DeleteWordlistResponse? FromJson( + string json, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + typeof(global::ModerationAPI.DeleteWordlistResponse), + jsonSerializerContext) as global::ModerationAPI.DeleteWordlistResponse; + } + + /// + /// Deserializes a JSON string using the generated default JsonSerializerContext. + /// + public static global::ModerationAPI.DeleteWordlistResponse? FromJson( + string json) + { + return FromJson( + json, + global::ModerationAPI.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::ModerationAPI.DeleteWordlistResponse? FromJson( + string json, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJson( + json, + global::ModerationAPI.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerContext. + /// + public static async global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return (await global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + typeof(global::ModerationAPI.DeleteWordlistResponse), + jsonSerializerContext).ConfigureAwait(false)) as global::ModerationAPI.DeleteWordlistResponse; + } + + /// + /// Deserializes a JSON stream using the generated default JsonSerializerContext. + /// + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream) + { + return FromJsonStreamAsync( + jsonStream, + global::ModerationAPI.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJsonStreamAsync( + jsonStream, + global::ModerationAPI.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + jsonSerializerOptions); + } + } +} diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.g.cs new file mode 100644 index 0000000..d886a8a --- /dev/null +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.DeleteWordlistResponse.g.cs @@ -0,0 +1,71 @@ + +#nullable enable + +namespace ModerationAPI +{ + /// + /// + /// + public sealed partial class DeleteWordlistResponse + { + /// + /// ID of the deleted wordlist + /// + [global::System.Text.Json.Serialization.JsonPropertyName("id")] + [global::System.Text.Json.Serialization.JsonRequired] + public required string Id { get; set; } + + /// + /// Whether the wordlist was deleted + /// + [global::System.Text.Json.Serialization.JsonPropertyName("deleted")] + [global::System.Text.Json.Serialization.JsonRequired] + public required bool Deleted { get; set; } + + /// + /// IDs of the channels that used the wordlist. It was removed from them. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("detachedChannelIds")] + [global::System.Text.Json.Serialization.JsonRequired] + public required global::System.Collections.Generic.IList DetachedChannelIds { get; set; } + + /// + /// Additional properties that are not explicitly defined in the schema + /// + [global::System.Text.Json.Serialization.JsonExtensionData] + public global::System.Collections.Generic.IDictionary AdditionalProperties { get; set; } = new global::System.Collections.Generic.Dictionary(); + + /// + /// Initializes a new instance of the class. + /// + /// + /// ID of the deleted wordlist + /// + /// + /// Whether the wordlist was deleted + /// + /// + /// IDs of the channels that used the wordlist. It was removed from them. + /// +#if NET7_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] +#endif + public DeleteWordlistResponse( + string id, + bool deleted, + global::System.Collections.Generic.IList detachedChannelIds) + { + this.Id = id ?? throw new global::System.ArgumentNullException(nameof(id)); + this.Deleted = deleted; + this.DetachedChannelIds = detachedChannelIds ?? throw new global::System.ArgumentNullException(nameof(detachedChannelIds)); + } + + /// + /// Initializes a new instance of the class. + /// + public DeleteWordlistResponse() + { + } + + } +} \ No newline at end of file diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.QueueItem.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.QueueItem.g.cs index 6f0d321..1fd5f81 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.QueueItem.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.QueueItem.g.cs @@ -9,14 +9,14 @@ namespace ModerationAPI public sealed partial class QueueItem { /// - /// The item ID. Use it to resolve or unresolve the item in this queue. + /// The item ID: the ID of this submission. Use it, or `contentId`, to resolve or unresolve the item in this queue. /// [global::System.Text.Json.Serialization.JsonPropertyName("id")] [global::System.Text.Json.Serialization.JsonRequired] public required string Id { get; set; } /// - /// Your content ID, as you sent it to `POST /moderate`. + /// Your content ID, as you sent it to `POST /moderate`. Webhooks send it as `item.id`. The resolve endpoints accept it in place of `id`. /// [global::System.Text.Json.Serialization.JsonPropertyName("contentId")] [global::System.Text.Json.Serialization.JsonRequired] @@ -97,10 +97,10 @@ public sealed partial class QueueItem /// Initializes a new instance of the class. /// /// - /// The item ID. Use it to resolve or unresolve the item in this queue. + /// The item ID: the ID of this submission. Use it, or `contentId`, to resolve or unresolve the item in this queue. /// /// - /// Your content ID, as you sent it to `POST /moderate`. + /// Your content ID, as you sent it to `POST /moderate`. Webhooks send it as `item.id`. The resolve endpoints accept it in place of `id`. /// /// /// The moderation labels of the content. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsRequest.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsRequest.g.cs index b670fd7..3b832c6 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsRequest.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsRequest.g.cs @@ -9,7 +9,7 @@ namespace ModerationAPI public sealed partial class ResolveQueueItemsRequest { /// - /// The item IDs to resolve. Up to 100. + /// The items to resolve, up to 100. Each is the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// [global::System.Text.Json.Serialization.JsonPropertyName("itemIds")] [global::System.Text.Json.Serialization.JsonRequired] @@ -25,7 +25,7 @@ public sealed partial class ResolveQueueItemsRequest /// Initializes a new instance of the class. /// /// - /// The item IDs to resolve. Up to 100. + /// The items to resolve, up to 100. Each is the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// #if NET7_0_OR_GREATER [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsResponse.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsResponse.g.cs index 29ff5b9..6523d62 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsResponse.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.Models.ResolveQueueItemsResponse.g.cs @@ -16,7 +16,7 @@ public sealed partial class ResolveQueueItemsResponse public required int Resolved { get; set; } /// - /// Item IDs that do not exist in the project. + /// IDs from `itemIds` that match no item or content ID in the project. /// [global::System.Text.Json.Serialization.JsonPropertyName("notFoundIds")] [global::System.Text.Json.Serialization.JsonRequired] @@ -35,7 +35,7 @@ public sealed partial class ResolveQueueItemsResponse /// Number of items resolved. /// /// - /// Item IDs that do not exist in the project. + /// IDs from `itemIds` that match no item or content ID in the project. /// #if NET7_0_OR_GREATER [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.QueueItemsClient.ResolveMany.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.QueueItemsClient.ResolveMany.g.cs index a3f767e..a93ffbc 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.QueueItemsClient.ResolveMany.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.QueueItemsClient.ResolveMany.g.cs @@ -47,7 +47,7 @@ partial void ProcessResolveManyResponseContent( /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. @@ -94,7 +94,7 @@ partial void ProcessResolveManyResponseContent( } /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. @@ -680,14 +680,14 @@ partial void ProcessResolveManyResponseContent( } /// /// Resolve queue items
- /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`. + /// Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`. ///
/// /// The queue ID. /// /// /// - /// The item IDs to resolve. Up to 100. + /// The items to resolve, up to 100. Each is the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. /// The token to cancel the operation with diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenGetItems.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenGetItems.g.cs index 82358b9..3a7c37f 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenGetItems.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenGetItems.g.cs @@ -65,7 +65,7 @@ partial void ProcessQueueViewOpenGetItemsResponseContent( /// /// List queue items
- /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` to resolve or unresolve an item. + /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` or `contentId` to resolve or unresolve an item. ///
/// /// The queue ID. @@ -142,7 +142,7 @@ partial void ProcessQueueViewOpenGetItemsResponseContent( } /// /// List queue items
- /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` to resolve or unresolve an item. + /// List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` or `contentId` to resolve or unresolve an item. ///
/// /// The queue ID. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenResolveItem.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenResolveItem.g.cs index 621fef0..020088b 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenResolveItem.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenResolveItem.g.cs @@ -47,13 +47,13 @@ partial void ProcessQueueViewOpenResolveItemResponseContent( /// /// Resolve a queue item
- /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. To also take a moderation action, use `POST /actions/execute`. + /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. `itemId` is the item `id` or your `contentId`. To also take a moderation action, use `POST /actions/execute`. ///
/// /// The queue ID. /// /// - /// The item ID to resolve. + /// The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. @@ -89,13 +89,13 @@ partial void ProcessQueueViewOpenResolveItemResponseContent( } /// /// Resolve a queue item
- /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. To also take a moderation action, use `POST /actions/execute`. + /// Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. `itemId` is the item `id` or your `contentId`. To also take a moderation action, use `POST /actions/execute`. ///
/// /// The queue ID. /// /// - /// The item ID to resolve. + /// The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs index de5ac3e..4056c52 100644 --- a/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.ReviewQueuesClient.QueueViewOpenUnresolveItem.g.cs @@ -47,13 +47,13 @@ partial void ProcessQueueViewOpenUnresolveItemResponseContent( /// /// Unresolve a queue item
- /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. + /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. `itemId` is the item `id` or your `contentId`. ///
/// /// The queue ID. /// /// - /// The item ID to unresolve. + /// The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. @@ -89,13 +89,13 @@ partial void ProcessQueueViewOpenUnresolveItemResponseContent( } /// /// Unresolve a queue item
- /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. + /// Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. `itemId` is the item `id` or your `contentId`. ///
/// /// The queue ID. /// /// - /// The item ID to unresolve. + /// The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it. /// /// /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. diff --git a/src/libs/ModerationAPI/Generated/ModerationAPI.WordlistClient.Delete.g.cs b/src/libs/ModerationAPI/Generated/ModerationAPI.WordlistClient.Delete.g.cs new file mode 100644 index 0000000..8ad28f5 --- /dev/null +++ b/src/libs/ModerationAPI/Generated/ModerationAPI.WordlistClient.Delete.g.cs @@ -0,0 +1,556 @@ + +#nullable enable + +namespace ModerationAPI +{ + public partial class WordlistClient + { + + + private static readonly global::ModerationAPI.EndPointSecurityRequirement s_DeleteSecurityRequirement0 = + new global::ModerationAPI.EndPointSecurityRequirement + { + Authorizations = new global::ModerationAPI.EndPointAuthorizationRequirement[] + { new global::ModerationAPI.EndPointAuthorizationRequirement + { + Type = "Http", + SchemeId = "HttpBearer", + Location = "Header", + Name = "Bearer", + FriendlyName = "Bearer", + }, + }, + }; + private static readonly global::ModerationAPI.EndPointSecurityRequirement[] s_DeleteSecurityRequirements = + new global::ModerationAPI.EndPointSecurityRequirement[] + { s_DeleteSecurityRequirement0, + }; + partial void PrepareDeleteArguments( + global::System.Net.Http.HttpClient httpClient, + ref string id, + ref string? projectId); + partial void PrepareDeleteRequest( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpRequestMessage httpRequestMessage, + string id, + string? projectId); + partial void ProcessDeleteResponse( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpResponseMessage httpResponseMessage); + + partial void ProcessDeleteResponseContent( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpResponseMessage httpResponseMessage, + ref string content); + + /// + /// Delete wordlist
+ /// Delete a wordlist and its words. Channels that use the wordlist do not block the delete: the wordlist is removed from their policies. `detachedChannelIds` lists those channels. This cannot be undone. + ///
+ /// + /// ID of the wordlist to delete + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + public async global::System.Threading.Tasks.Task DeleteAsync( + string id, + string? projectId = default, + global::ModerationAPI.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default) + { + var __response = await DeleteAsResponseAsync( + id: id, + projectId: projectId, + requestOptions: requestOptions, + cancellationToken: cancellationToken + ).ConfigureAwait(false); + + return __response.Body; + } + /// + /// Delete wordlist
+ /// Delete a wordlist and its words. Channels that use the wordlist do not block the delete: the wordlist is removed from their policies. `detachedChannelIds` lists those channels. This cannot be undone. + ///
+ /// + /// ID of the wordlist to delete + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + public async global::System.Threading.Tasks.Task> DeleteAsResponseAsync( + string id, + string? projectId = default, + global::ModerationAPI.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default) + { + PrepareArguments( + client: HttpClient); + PrepareDeleteArguments( + httpClient: HttpClient, + id: ref id, + projectId: ref projectId); + + + var __authorizations = global::ModerationAPI.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_DeleteSecurityRequirements, + operationName: "DeleteAsync"); + + using var __timeoutCancellationTokenSource = global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateTimeoutCancellationTokenSource( + clientOptions: Options, + requestOptions: requestOptions, + cancellationToken: cancellationToken); + var __effectiveCancellationToken = __timeoutCancellationTokenSource?.Token ?? cancellationToken; + var __effectiveReadResponseAsString = global::ModerationAPI.AutoSDKRequestOptionsSupport.GetReadResponseAsString( + clientOptions: Options, + requestOptions: requestOptions, + fallbackValue: ReadResponseAsString); + var __maxAttempts = global::ModerationAPI.AutoSDKRequestOptionsSupport.GetMaxAttempts( + clientOptions: Options, + requestOptions: requestOptions, + supportsRetry: true); + + global::System.Net.Http.HttpRequestMessage __CreateHttpRequest() + { + + var __pathBuilder = new global::ModerationAPI.PathBuilder( + path: $"/wordlist/{id}", + baseUri: HttpClient.BaseAddress); + var __path = __pathBuilder.ToString(); + __path = global::ModerationAPI.AutoSDKRequestOptionsSupport.AppendQueryParameters( + path: __path, + clientParameters: Options.QueryParameters, + requestParameters: requestOptions?.QueryParameters); + var __httpRequest = new global::System.Net.Http.HttpRequestMessage( + method: global::System.Net.Http.HttpMethod.Delete, + requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute)); +#if NET6_0_OR_GREATER + __httpRequest.Version = global::System.Net.HttpVersion.Version11; + __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; +#endif + + foreach (var __authorization in __authorizations) + { + if (__authorization.Type == "Http" || + __authorization.Type == "OAuth2" || + __authorization.Type == "OpenIdConnect") + { + __httpRequest.Headers.Authorization = new global::System.Net.Http.Headers.AuthenticationHeaderValue( + scheme: __authorization.Name, + parameter: __authorization.Value); + } + else if (__authorization.Type == "ApiKey" && + __authorization.Location == "Header") + { + __httpRequest.Headers.Add(__authorization.Name, __authorization.Value); + } + } + + if (projectId != default) + { + __httpRequest.Headers.TryAddWithoutValidation("projectId", projectId.ToString()); + } + + global::ModerationAPI.AutoSDKRequestOptionsSupport.ApplyHeaders( + request: __httpRequest, + clientHeaders: Options.Headers, + requestHeaders: requestOptions?.Headers); + + PrepareRequest( + client: HttpClient, + request: __httpRequest); + PrepareDeleteRequest( + httpClient: HttpClient, + httpRequestMessage: __httpRequest, + id: id, + projectId: projectId); + + return __httpRequest; + } + + global::System.Net.Http.HttpRequestMessage? __httpRequest = null; + global::System.Net.Http.HttpResponseMessage? __response = null; + var __attemptNumber = 0; + try + { + for (var __attempt = 1; __attempt <= __maxAttempts; __attempt++) + { + __attemptNumber = __attempt; + __httpRequest = __CreateHttpRequest(); + await global::ModerationAPI.AutoSDKRequestOptionsSupport.OnBeforeRequestAsync( + clientOptions: Options, + context: global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "Delete", + methodName: "DeleteAsync", + pathTemplate: "$\"/wordlist/{id}\"", + httpMethod: "DELETE", + baseUri: BaseUri, + request: __httpRequest ?? throw new global::System.InvalidOperationException("The HTTP request was not created before invoking a request hook."), + response: null, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + try + { + __response = await HttpClient.SendAsync( + request: __httpRequest, + completionOption: global::System.Net.Http.HttpCompletionOption.ResponseContentRead, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + } + catch (global::System.Net.Http.HttpRequestException __exception) + { + var __retryDelay = global::ModerationAPI.AutoSDKRequestOptionsSupport.GetRetryDelay( + clientOptions: Options, + requestOptions: requestOptions, + response: null, + attempt: __attempt); + var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested; + await global::ModerationAPI.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "Delete", + methodName: "DeleteAsync", + pathTemplate: "$\"/wordlist/{id}\"", + httpMethod: "DELETE", + baseUri: BaseUri, + request: __httpRequest ?? throw new global::System.InvalidOperationException("The HTTP request was not created before invoking a request hook."), + response: null, + exception: __exception, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: __willRetry, + retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null, + retryReason: "exception", + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + if (!__willRetry) + { + throw; + } + + __httpRequest.Dispose(); + __httpRequest = null; + await global::ModerationAPI.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync( + retryDelay: __retryDelay, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + continue; + } + + if (__response != null && + __attempt < __maxAttempts && + global::ModerationAPI.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode)) + { + var __retryDelay = global::ModerationAPI.AutoSDKRequestOptionsSupport.GetRetryDelay( + clientOptions: Options, + requestOptions: requestOptions, + response: __response, + attempt: __attempt); + await global::ModerationAPI.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "Delete", + methodName: "DeleteAsync", + pathTemplate: "$\"/wordlist/{id}\"", + httpMethod: "DELETE", + baseUri: BaseUri, + request: __httpRequest ?? throw new global::System.InvalidOperationException("The HTTP request was not created before invoking a request hook."), + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: true, + retryDelay: __retryDelay, + retryReason: "status:" + ((int)__response.StatusCode).ToString(global::System.Globalization.CultureInfo.InvariantCulture), + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + __response.Dispose(); + __response = null; + __httpRequest.Dispose(); + __httpRequest = null; + await global::ModerationAPI.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync( + retryDelay: __retryDelay, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + continue; + } + + break; + } + + if (__response == null) + { + throw new global::System.InvalidOperationException("No response received."); + } + + using (__response) + { + + ProcessResponse( + client: HttpClient, + response: __response); + ProcessDeleteResponse( + httpClient: HttpClient, + httpResponseMessage: __response); + if (__response.IsSuccessStatusCode) + { + await global::ModerationAPI.AutoSDKRequestOptionsSupport.OnAfterSuccessAsync( + clientOptions: Options, + context: global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "Delete", + methodName: "DeleteAsync", + pathTemplate: "$\"/wordlist/{id}\"", + httpMethod: "DELETE", + baseUri: BaseUri, + request: __httpRequest ?? throw new global::System.InvalidOperationException("The HTTP request was not created before invoking a request hook."), + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attemptNumber, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + } + else + { + await global::ModerationAPI.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::ModerationAPI.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "Delete", + methodName: "DeleteAsync", + pathTemplate: "$\"/wordlist/{id}\"", + httpMethod: "DELETE", + baseUri: BaseUri, + request: __httpRequest ?? throw new global::System.InvalidOperationException("The HTTP request was not created before invoking a request hook."), + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attemptNumber, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + } + // Authorization not provided + if ((int)__response.StatusCode == 401) + { + string? __content_401 = null; + global::System.Exception? __exception_401 = null; + global::ModerationAPI.AuthenticationError? __value_401 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_401 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + __value_401 = global::ModerationAPI.AuthenticationError.FromJson(__content_401, JsonSerializerContext); + } + else + { + __content_401 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + + __value_401 = global::ModerationAPI.AuthenticationError.FromJson(__content_401, JsonSerializerContext); + } + } + catch (global::System.Exception __ex) + { + __exception_401 = __ex; + } + + + throw global::ModerationAPI.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_401 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_401, + responseBody: __content_401, + responseObject: __value_401, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // Not found + if ((int)__response.StatusCode == 404) + { + string? __content_404 = null; + global::System.Exception? __exception_404 = null; + global::ModerationAPI.NotFoundError? __value_404 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_404 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + __value_404 = global::ModerationAPI.NotFoundError.FromJson(__content_404, JsonSerializerContext); + } + else + { + __content_404 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + + __value_404 = global::ModerationAPI.NotFoundError.FromJson(__content_404, JsonSerializerContext); + } + } + catch (global::System.Exception __ex) + { + __exception_404 = __ex; + } + + + throw global::ModerationAPI.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_404 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_404, + responseBody: __content_404, + responseObject: __value_404, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // Too many requests. Retry after the number of seconds in the `Retry-After` header. + if ((int)__response.StatusCode == 429) + { + string? __content_429 = null; + global::System.Exception? __exception_429 = null; + global::ModerationAPI.RateLimitError? __value_429 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_429 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + __value_429 = global::ModerationAPI.RateLimitError.FromJson(__content_429, JsonSerializerContext); + } + else + { + __content_429 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + + __value_429 = global::ModerationAPI.RateLimitError.FromJson(__content_429, JsonSerializerContext); + } + } + catch (global::System.Exception __ex) + { + __exception_429 = __ex; + } + + + throw global::ModerationAPI.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_429 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_429, + responseBody: __content_429, + responseObject: __value_429, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + + if (__effectiveReadResponseAsString) + { + var __content = await __response.Content.ReadAsStringAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + + ProcessResponseContent( + client: HttpClient, + response: __response, + content: ref __content); + ProcessDeleteResponseContent( + httpClient: HttpClient, + httpResponseMessage: __response, + content: ref __content); + + try + { + __response.EnsureSuccessStatusCode(); + + var __value = global::ModerationAPI.DeleteWordlistResponse.FromJson(__content, JsonSerializerContext) ?? + throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" "); + return new global::ModerationAPI.AutoSDKHttpResponse( + statusCode: __response.StatusCode, + headers: global::ModerationAPI.AutoSDKHttpResponse.CreateHeaders(__response), + requestUri: __response.RequestMessage?.RequestUri, + body: __value); + } + catch (global::System.Exception __ex) + { + throw global::ModerationAPI.ApiException.Create( + statusCode: __response.StatusCode, + message: __content ?? __response.ReasonPhrase ?? string.Empty, + innerException: __ex, + responseBody: __content, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + } + else + { + try + { + __response.EnsureSuccessStatusCode(); + using var __content = await __response.Content.ReadAsStreamAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + + var __value = await global::ModerationAPI.DeleteWordlistResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ?? + throw new global::System.InvalidOperationException("Response deserialization failed."); + return new global::ModerationAPI.AutoSDKHttpResponse( + statusCode: __response.StatusCode, + headers: global::ModerationAPI.AutoSDKHttpResponse.CreateHeaders(__response), + requestUri: __response.RequestMessage?.RequestUri, + body: __value); + } + catch (global::System.Exception __ex) + { + string? __content = null; + try + { + __content = await __response.Content.ReadAsStringAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + } + catch (global::System.Exception) + { + } + + throw global::ModerationAPI.ApiException.Create( + statusCode: __response.StatusCode, + message: __content ?? __response.ReasonPhrase ?? string.Empty, + innerException: __ex, + responseBody: __content, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + } + + } + } + finally + { + __httpRequest?.Dispose(); + } + } + } +} \ No newline at end of file diff --git a/src/libs/ModerationAPI/Generated/autosdk.generated-examples.json b/src/libs/ModerationAPI/Generated/autosdk.generated-examples.json index 412b705..3667386 100644 --- a/src/libs/ModerationAPI/Generated/autosdk.generated-examples.json +++ b/src/libs/ModerationAPI/Generated/autosdk.generated-examples.json @@ -92,7 +92,7 @@ "Order": 9, "Title": "Resolve queue items", "Slug": "resolvequeueitems", - "Description": "Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with \u0060POST /queue/{id}/items/{itemId}/resolve\u0060. IDs that do not exist in the project are skipped and returned in \u0060notFoundIds\u0060.", + "Description": "Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with \u0060POST /queue/{id}/items/{itemId}/resolve\u0060, and each ID is an item \u0060id\u0060 or your \u0060contentId\u0060. IDs that match no item in the project are skipped and returned in \u0060notFoundIds\u0060.", "Language": "http", "Code": "### Resolve queue items\n# @name resolveQueueItems\nPOST {{host}}/queue/{{id}}/items/resolve\nAuthorization: Bearer {{token}}\nProject-Id: {{Project-Id}}\nContent-Type: application/json\nAccept: application/json\n\n{\n \u0022itemIds\u0022: [\n \u0022clx8k2v0e000108l4a9bz3f7q\u0022,\n \u0022clx8k2v0e000208l4h2mc6d1r\u0022\n ]\n}\n\n## Responses\n# 200\n# Description: Successful response\n# Content-Type: application/json\n# 400\n# Description: Invalid input data\n# Content-Type: application/json\n# 401\n# Description: Authorization not provided\n# Content-Type: application/json\n# 403\n# Description: Insufficient access\n# Content-Type: application/json\n# 429\n# Description: Too many requests. Retry after the number of seconds in the \u0060Retry-After\u0060 header.\n# Content-Type: application/json\n# 500\n# Description: Internal server error\n# Content-Type: application/json", "Format": "http", diff --git a/src/libs/ModerationAPI/openapi.yaml b/src/libs/ModerationAPI/openapi.yaml index b645479..f2a3041 100644 --- a/src/libs/ModerationAPI/openapi.yaml +++ b/src/libs/ModerationAPI/openapi.yaml @@ -3544,7 +3544,7 @@ "get": { "operationId": "queueView-openGetItems", "summary": "List queue items", - "description": "List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` to resolve or unresolve an item.", + "description": "List the items of a review queue, with the filters and the date window of the queue applied. By default only pending items. The list is paginated. Use the item `id` or `contentId` to resolve or unresolve an item.", "tags": [ "review-queues" ], @@ -3825,7 +3825,7 @@ "post": { "operationId": "queueView-openResolveItem", "summary": "Resolve a queue item", - "description": "Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. To also take a moderation action, use `POST /actions/execute`.", + "description": "Mark an item of a queue as resolved. It is the same as a check-off in the dashboard: the item leaves the pending list and a QUEUE_ITEM_COMPLETED webhook is sent. `itemId` is the item `id` or your `contentId`. To also take a moderation action, use `POST /actions/execute`.", "tags": [ "review-queues" ], @@ -3850,10 +3850,10 @@ "name": "itemId", "schema": { "type": "string", - "description": "The item ID to resolve." + "description": "The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it." }, "required": true, - "description": "The item ID to resolve." + "description": "The item to resolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it." }, { "in": "header", @@ -3991,7 +3991,7 @@ "post": { "operationId": "resolveQueueItems", "summary": "Resolve queue items", - "description": "Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`. IDs that do not exist in the project are skipped and returned in `notFoundIds`.", + "description": "Mark up to 100 items of a queue as resolved in one request. Each item is resolved the same as with `POST /queue/{id}/items/{itemId}/resolve`, and each ID is an item `id` or your `contentId`. IDs that match no item in the project are skipped and returned in `notFoundIds`.", "tags": [ "Review queues" ], @@ -4036,7 +4036,7 @@ "items": { "type": "string" }, - "description": "The item IDs to resolve. Up to 100." + "description": "The items to resolve, up to 100. Each is the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it." } }, "required": [ @@ -4069,7 +4069,7 @@ "items": { "type": "string" }, - "description": "Item IDs that do not exist in the project." + "description": "IDs from `itemIds` that match no item or content ID in the project." } }, "required": [ @@ -4183,7 +4183,7 @@ "post": { "operationId": "queueView-openUnresolveItem", "summary": "Unresolve a queue item", - "description": "Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list.", + "description": "Mark a resolved item of a queue as pending again. It is the same as removing a check-off in the dashboard: the item comes back in the pending list. `itemId` is the item `id` or your `contentId`.", "tags": [ "review-queues" ], @@ -4208,10 +4208,10 @@ "name": "itemId", "schema": { "type": "string", - "description": "The item ID to unresolve." + "description": "The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it." }, "required": true, - "description": "The item ID to unresolve." + "description": "The item to unresolve: the item `id` from `GET /queue/{id}/items`, or the `contentId` you sent to `POST /moderate` (webhooks send it as `item.id`). For a content ID, the newest submission with that content ID is used, as the queue shows it." }, { "in": "header", @@ -10025,6 +10025,124 @@ "source": "modapi wordlist update --secret-key \"$MODAPI_SECRET_KEY\" --id ''\n" } ] + }, + "delete": { + "operationId": "deleteWordlist", + "summary": "Delete wordlist", + "description": "Delete a wordlist and its words. Channels that use the wordlist do not block the delete: the wordlist is removed from their policies. `detachedChannelIds` lists those channels. This cannot be undone.", + "tags": [ + "Wordlists" + ], + "security": [ + { + "Authorization": [] + } + ], + "parameters": [ + { + "in": "path", + "name": "id", + "schema": { + "type": "string", + "description": "ID of the wordlist to delete" + }, + "required": true, + "description": "ID of the wordlist to delete" + }, + { + "in": "header", + "name": "Project-Id", + "required": false, + "schema": { + "type": "string" + }, + "description": "The project to act on, by ID or name. Required with an organization key unless the key reaches only one project; list projects with GET /projects. A project key acts on its own project and needs no value: naming another one is an error.", + "x-speakeasy-name-override": "projectId" + } + ], + "responses": { + "200": { + "description": "Wordlist deleted successfully", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "ID of the deleted wordlist" + }, + "deleted": { + "type": "boolean", + "description": "Whether the wordlist was deleted" + }, + "detachedChannelIds": { + "type": "array", + "items": { + "type": "string" + }, + "description": "IDs of the channels that used the wordlist. It was removed from them." + } + }, + "required": [ + "id", + "deleted", + "detachedChannelIds" + ], + "additionalProperties": false + } + } + } + }, + "401": { + "description": "Authorization not provided", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/AuthenticationError" + } + } + } + }, + "404": { + "description": "Not found", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/NotFoundError" + } + } + } + }, + "429": { + "description": "Too many requests. Retry after the number of seconds in the `Retry-After` header.", + "headers": { + "Retry-After": { + "description": "Seconds to wait before retrying.", + "schema": { + "type": "integer" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RateLimitError" + } + } + } + } + }, + "x-speakeasy-group": "wordlist", + "x-speakeasy-name-override": "delete", + "x-speakeasy-mcp": { + "title": "Delete wordlist", + "scopes": [ + "destructive" + ], + "readOnlyHint": false, + "destructiveHint": true + } } }, "/wordlist/{id}/embedding-status": { @@ -15494,11 +15612,11 @@ "properties": { "id": { "type": "string", - "description": "The item ID. Use it to resolve or unresolve the item in this queue." + "description": "The item ID: the ID of this submission. Use it, or `contentId`, to resolve or unresolve the item in this queue." }, "contentId": { "type": "string", - "description": "Your content ID, as you sent it to `POST /moderate`." + "description": "Your content ID, as you sent it to `POST /moderate`. Webhooks send it as `item.id`. The resolve endpoints accept it in place of `id`." }, "content": { "anyOf": [