Adds id to the webhook item response model (#19947)
Adds id to the webhook item response model.
This commit is contained in:
@@ -120,6 +120,7 @@ public class ItemTypeMapDefinition : IMapDefinition
|
||||
// Umbraco.Code.MapAll
|
||||
private static void Map(IWebhook source, WebhookItemResponseModel target, MapperContext context)
|
||||
{
|
||||
target.Id = source.Key;
|
||||
target.Name = source.Name ?? source.Url;
|
||||
target.Url = source.Url;
|
||||
target.Enabled = source.Enabled;
|
||||
|
||||
@@ -48124,12 +48124,29 @@
|
||||
"required": [
|
||||
"enabled",
|
||||
"events",
|
||||
"id",
|
||||
"name",
|
||||
"signs",
|
||||
"types",
|
||||
"url"
|
||||
],
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"format": "uuid"
|
||||
},
|
||||
"signs": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"oneOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/SignModel"
|
||||
}
|
||||
]
|
||||
},
|
||||
"readOnly": true
|
||||
},
|
||||
"enabled": {
|
||||
"type": "boolean"
|
||||
},
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
using Umbraco.Cms.Api.Management.ViewModels.Item;
|
||||
|
||||
namespace Umbraco.Cms.Api.Management.ViewModels.Webhook.Item;
|
||||
|
||||
public class WebhookItemResponseModel
|
||||
public class WebhookItemResponseModel : ItemResponseModelBase
|
||||
{
|
||||
public bool Enabled { get; set; } = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user