Example #1
0
 internal AmoRequest(string httpMethod, string uri, string content, IAmoAuthProvider auth)
 {
     _httpMethod  = new HttpMethod(httpMethod);
     _uri         = new Uri(uri);
     _content     = new StringContent(content);
     _auth        = auth;
     this.content = content;
 }
Example #2
0
 /// <summary>
 /// Generic amoCRM repository constructor.
 /// </summary>
 ///<param name = "acc" ><see cref="AmoAccount"/> object, must implement <see cref="IAmoAccount"/>.</param>
 public GenericAmoRepository(IAmoAccount acc)
 {
     _auth       = acc.auth;
     _entityLink = (string)typeof(T).GetProperty("entityLink").GetValue(null, null);   //IModel.entityLink;
     _apiAddress = $"https://{acc.subdomain}.amocrm.ru/api/v4/";
 }
Example #3
0
 internal AmoRequest(string httpMethod, string uri, IAmoAuthProvider auth)
 {
     _httpMethod = new HttpMethod(httpMethod);
     _uri        = new Uri(uri);
     _auth       = auth;
 }