using Furion.RemoteRequest;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

namespace YBDevice.NApi.Application.ThirdClient
{
    /// <summary>
    /// 抖音/头条接口代理
    /// </summary>
    public interface ITouTiaoHttp : IHttpDispatchProxy
    {
        /// <summary>
        /// 登录接口换取openid
        /// </summary>
        /// <param name="bodydata">请求参数</param>
        /// <param name="action">异常处理</param>
        /// <returns></returns>
        [Post("/api/apps/v2/jscode2session"),Client("toutiao"),Timeout(15)]
        Task<HttpResponseMessage> JSCode2SessionAsync([Body("application/json")]
        TouTiaoCode2SessionRequest bodydata,
        [Interceptor(InterceptorTypes.Exception)] Action<HttpResponseMessage, string> action = default
        );
    }
}
