using System;
using System.Net;

namespace MarcusLaw.OutlookAddin.Core.Services
{
    public sealed class EspoCrmAuthorizationException : Exception
    {
        public EspoCrmAuthorizationException(string message)
            : base(message)
        {
        }
    }

    public sealed class EspoCrmHttpException : Exception
    {
        public HttpStatusCode StatusCode { get; }
        public string? ResponseBody { get; }

        public EspoCrmHttpException(HttpStatusCode statusCode, string? responseBody, string message)
            : base(message)
        {
            StatusCode = statusCode;
            ResponseBody = responseBody;
        }
    }
}
