private void Init(AmazonCredential Credentials) { this.Credentials = Credentials; this._Feeds = new Pipelines.FeedsPipeline(this.GetCredentials, this.Throttle); this._Finances = new Pipelines.FinancesPipeline(this.GetCredentials, this.Throttle); this._Products = new Pipelines.ProductsPipeline(this.GetCredentials, this.Throttle); this._Recommendations = new Pipelines.RecommendationsPipeline(this.GetCredentials, this.Throttle); this._Reports = new Pipelines.ReportsPipeline(this.GetCredentials, this.Throttle); this._Orders = new Pipelines.OrdersPipeline(this.GetCredentials, this.Throttle); }
public void Authenticate(AmazonCredential Credentials) { if (this.Credentials == default(AmazonCredential)) { Init(Credentials); } else { throw new InvalidOperationException("Error, you are already authenticated to amazon in this AmazonConnection, dispose of this connection and create a new one to connect to a different account."); } }
public AmazonConnection(AmazonCredential Credentials) : this() { this.Authenticate(Credentials); }
internal protected TClient GetClient(AmazonCredential Credentials) => (TClient)Activator.CreateInstance(typeof(TClient), Credentials.AccessKeyID, Credentials.SecretAccessKey, this.GetConfig());