using System.Text.Json.Serialization;
using System.Collections.Generic;
using Topsdk.Util;

namespace Topsdk.Top.Ability371.Request;

public class TaobaoTbkCouponGetRequest : AbstractTopApiRequest
{

    /*
        带券ID与商品ID的加密串
            */
    private string? me;


    /*
        商品ID
            */
    private string? itemId;


    /*
        券ID
            */
    private string? activityId;


    [JsonPropertyName("me")]
    public string? Me
    {
        get => me;
        set => this.me = value;
    }

    [JsonPropertyName("item_id")]
    public string? ItemId
    {
        get => itemId;
        set => this.itemId = value;
    }

    [JsonPropertyName("activity_id")]
    public string? ActivityId
    {
        get => activityId;
        set => this.activityId = value;
    }



    public override IDictionary<string, string> ToRequestParam()
    {
        IDictionary<string, string> requestParam = new Dictionary<string, string>();
        if(this.me != null)
        {
            requestParam.Add("me",TopUtils.ConvertBasicType(this.me));
        }
        if(this.itemId != null)
        {
            requestParam.Add("item_id",TopUtils.ConvertBasicType(this.itemId));
        }
        if(this.activityId != null)
        {
            requestParam.Add("activity_id",TopUtils.ConvertBasicType(this.activityId));
        }
        return requestParam;
    }

    public override IDictionary<string, TopFileItem> ToFileParam()
    {
        IDictionary<string, TopFileItem> fileParam = new Dictionary<string, TopFileItem>();
        return fileParam;
    }

    public override string GetApiCode()
    {
        return "taobao.tbk.coupon.get";
    }

}

