public static IAgencyTransactional ByAccountApiKey(string apiKey, string clientId, ICreateSendOptions options = null)
        {
            if (apiKey == null) throw new ArgumentNullException("apiKey");
            if (clientId == null) throw new ArgumentNullException("clientId");

            return new TransactionalContext(new AccountApiKey(apiKey, clientId), options);
        }
示例#2
0
 public TransactionalContext(AuthenticationDetails auth, ICreateSendOptions options)
 {
     classicEmail = new ClassicEmailContext(auth, options);
     smartEmail   = new SmartEmailContext(auth, options);
     messages     = new MessagesContext(auth, options);
     statistics   = new StatisticsContext(auth, options);
 }
 public TransactionalContext(AuthenticationDetails auth, ICreateSendOptions options)
 {
     classicEmail = new ClassicEmailContext(auth, options);
     smartEmail = new SmartEmailContext(auth, options);
     messages = new MessagesContext(auth, options);
     statistics = new StatisticsContext(auth, options);
 }
        public static ITransactional ByOAuth(string accessToken, string refreshToken, string clientId, ICreateSendOptions options = null)
        {
            if (accessToken == null) throw new ArgumentNullException("accessToken");
            if (refreshToken == null) throw new ArgumentNullException("refreshToken");
            if (clientId == null) throw new ArgumentNullException("clientId");

            return new TransactionalContext(new OAuthWithClientId(accessToken, refreshToken, clientId), options);
        }
示例#5
0
        public static IAgencyTransactional ByAccountApiKey(string apiKey, ICreateSendOptions options = null)
        {
            if (apiKey == null)
            {
                throw new ArgumentNullException("apiKey");
            }

            return(new TransactionalContext(new AccountApiKey(apiKey), options));
        }
 public SmartEmailContext(AuthenticationDetails authenticationDetails, ICreateSendOptions options)
     : base(authenticationDetails, options)
 {
 }
示例#7
0
 public SmartEmailContext(AuthenticationDetails authenticationDetails, ICreateSendOptions options)
     : base(authenticationDetails, options)
 {
 }
示例#8
0
 public StatisticsContext(AuthenticationDetails authenticationDetails, ICreateSendOptions options)
     : base(authenticationDetails, options)
 {
 }
        public CreateSendBase(AuthenticationDetails auth, ICreateSendOptions options = null)
        {
            this.options = options ?? new CreateSendOptionsWrapper();

            Authenticate(auth);
        }
示例#10
0
 public MessagesContext(AuthenticationDetails authenticationDetails, ICreateSendOptions options)
     : base(authenticationDetails, options)
 {
 }
示例#11
0
 public MessagesContext(AuthenticationDetails authenticationDetails, ICreateSendOptions options)
     : base(authenticationDetails, options)
 {
 }
示例#12
0
        public static ITransactional ByOAuth(string accessToken, string refreshToken, string clientId, ICreateSendOptions options = null)
        {
            if (accessToken == null)
            {
                throw new ArgumentNullException("accessToken");
            }
            if (refreshToken == null)
            {
                throw new ArgumentNullException("refreshToken");
            }
            if (clientId == null)
            {
                throw new ArgumentNullException("clientId");
            }

            return(new TransactionalContext(new OAuthWithClientId(accessToken, refreshToken, clientId), options));
        }
示例#13
0
        public static ITransactional ByClientApiKey(string apiKey, ICreateSendOptions options = null)
        {
            if (apiKey == null) throw new ArgumentNullException("apiKey");

            return new TransactionalContext(new ClientApiKey(apiKey), options);
        }