// <auto-generated/>

#nullable disable

using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using OpenAI;

namespace OpenAI.Assistants
{
    [Experimental("OPENAI001")]
    public partial class AssistantThread
    {
        private protected IDictionary<string, BinaryData> _additionalBinaryDataProperties;

        internal AssistantThread(string id, DateTimeOffset createdAt, ToolResources toolResources)
        {
            Id = id;
            CreatedAt = createdAt;
            Metadata = new ChangeTrackingDictionary<string, string>();
            ToolResources = toolResources;
        }

        internal AssistantThread(string id, DateTimeOffset createdAt, IReadOnlyDictionary<string, string> metadata, string @object, ToolResources toolResources, IDictionary<string, BinaryData> additionalBinaryDataProperties)
        {
            // Plugin customization: ensure initialization of collections
            Id = id;
            CreatedAt = createdAt;
            Metadata = metadata ?? new ChangeTrackingDictionary<string, string>();
            Object = @object;
            ToolResources = toolResources;
            _additionalBinaryDataProperties = additionalBinaryDataProperties;
        }

        public string Id { get; }

        public DateTimeOffset CreatedAt { get; }

        public IReadOnlyDictionary<string, string> Metadata { get; }

        internal IDictionary<string, BinaryData> SerializedAdditionalRawData
        {
            get => _additionalBinaryDataProperties;
            set => _additionalBinaryDataProperties = value;
        }
    }
}
