You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

UserCreate.cs 2.2 KiB

4 years ago
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. using System.Collections.Generic;
  2. namespace Learun.Application.WeChat
  3. {
  4. public class UserCreate : OperationRequestBase<OperationResultsBase,HttpPostRequest>
  5. {
  6. protected override string Url()
  7. {
  8. return "https://qyapi.weixin.qq.com/cgi-bin/user/create?access_token=ACCESS_TOKEN";
  9. }
  10. /// <summary>
  11. /// 员工UserID。对应管理端的帐号,企业内必须唯一。长度为1~64个字符
  12. /// </summary>
  13. /// <returns></returns>
  14. [Length(1,64)]
  15. [IsNotNull]
  16. public string userid { get; set; }
  17. /// <summary>
  18. /// 成员名称。长度为1~64个字符
  19. /// </summary>
  20. /// <returns></returns>
  21. [Length(1, 64)]
  22. [IsNotNull]
  23. public string name { get; set; }
  24. /// <summary>
  25. /// 成员所属部门id列表。注意,每个部门的直属员工上限为1000个
  26. /// </summary>
  27. /// <returns></returns>
  28. [IsNotNull]
  29. public List<string> department { get; set; }
  30. /// <summary>
  31. /// 职位信息。长度为0~64个字符
  32. /// </summary>
  33. /// <returns></returns>
  34. [Length(0, 64)]
  35. public string position { get; set; }
  36. /// <summary>
  37. /// 手机号码。企业内必须唯一,mobile/weixinid/email三者不能同时为空
  38. /// </summary>
  39. /// <returns></returns>
  40. public string mobile { get; set; }
  41. /// <summary>
  42. /// 性别。gender=0表示男,=1表示女。默认gender=0
  43. /// </summary>
  44. /// <returns></returns>
  45. public string gender { get; set; }
  46. /// <summary>
  47. /// 办公电话。长度为0~64个字符
  48. /// </summary>
  49. /// <returns></returns>
  50. [Length(0, 64)]
  51. public string tel { get; set; }
  52. /// <summary>
  53. /// 邮箱。长度为0~64个字符。企业内必须唯一
  54. /// </summary>
  55. /// <returns></returns>
  56. [Length(0, 64)]
  57. public string email { get; set; }
  58. /// <summary>
  59. /// 微信号。企业内必须唯一
  60. /// </summary>
  61. /// <returns></returns>
  62. public string weixinid { get; set; }
  63. }
  64. }