Webiant Logo Webiant Logo
  1. No results found.

    Try your search with a different keyword or use * as a wildcard.

AvalaraWebhookController.cs

using Microsoft.AspNetCore.Mvc;
using Nop.Plugin.Tax.Avalara.Services;

namespace Nop.Plugin.Tax.Avalara.Controllers;

public class AvalaraWebhookController : Controller
{
    #region Fields

    protected readonly AvalaraTaxManager _avalaraTaxManager;

    #endregion

    #region Ctor

    public AvalaraWebhookController(AvalaraTaxManager avalaraTaxManager)
    {
        _avalaraTaxManager = avalaraTaxManager;
    }

    #endregion

    #region Methods

    [HttpPost]
    public async Task ItemClassificationWebhook()
    {
        await _avalaraTaxManager.HandleItemClassificationWebhookAsync(Request);
        return Ok();
    }

    #endregion
}