url.go 9.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. package tax
  2. import "fmt"
  3. var AreaUriMap = map[string]string{
  4. "beijing.pro": "https://tpass.beijing.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.beijing.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=se8dc9bba4s9466a93bb2qaab2b8c9ca",
  5. "tianjin.pro": "https://tpass.tianjin.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.tianjin.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=q4q6b8aa469v4369ae7483c4vb45cvca",
  6. "shanghai.pro": "https://tpass.shanghai.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.shanghai.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=h49fdcfd823b49a6aasd3ffacb33bffh&response_type=code&state=21424b4e8da545d59b26d9ea6befe179&client_pid=h49fdcfd823b49a6aasd3ffacb33bffh",
  7. "chongqing.pro": "https://tpass.chongqing.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.chongqing.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=y75ey676f5e445f6bs4f5b78d45bs2b6&response_type=code&state=8adc7b9d294b48278187a1d4cbfbc60b&client_pid=y75ey676f5e445f6bs4f5b78d45bs2b6",
  8. "dalian.pro": "https://tpass.dalian.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.dalian.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=p4b8e7cpdcs745a5bp7ep3d5c2s96e7b&response_type=code&state=ef36083149414cef9158c9766db250fb",
  9. "qingdao.pro": "https://tpass.qingdao.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.qingdao.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=vt8337t23tv94cdvbdb875e7t8a357e2&response_type=code&state=a610a08cc13b41fda058535b97232d15",
  10. "ningbo.pro": "https://tpass.ningbo.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.ningbo.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=ybad3c55a29c4226b5xcfxx5y49cf427&response_type=code&state=450ba1f3a23a4f7389130ce0c0baec9e&client_pid=ybad3c55a29c4226b5xcfxx5y49cf427",
  11. "henan.pro": "https://tpass.henan.chinatax.gov.cn:8443/#/login?client_id=te95ftefe59243cbafta4fb82bbtfcte",
  12. "neimenggu.pro": "https://tpass.neimenggu.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.neimenggu.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=v93v3f7ed6af4vnan8nf2vn7n2vne93a&response_type=code&state=9cabdeca8d8f42549d91ca06dfbf72fe&client_pid=v93v3f7ed6af4vnan8nf2vn7n2vne93a",
  13. "hebei.pro": "https://tpass.hebei.chinatax.gov.cn:8443/#/login?redirect_uri=https://etax.hebei.chinatax.gov.cn:8443/mhzx/api/mh/tpass/code&client_id=ap5bfdavp66a49979apa5848fpaa5353",
  14. "shanxi.pro": "https://tpass.shanxi.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.shanxi.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=sa67ddd29sc94cga9f96s7da2772s6d7",
  15. "jilin.pro": "https://tpass.jilin.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.jilin.chinatax.gov.cn%3A10812%2Fsword%3Fctrl%3DDzswjKxtxCtrl_getKxtxOauth2Token&client_id=e2eb5ccdc19b11edb89a40a6b72a3d68",
  16. "jiangsu.pro": "https://tpass.jiangsu.chinatax.gov.cn:8443/#/login?client_id=mcsc7e2ssscb4sfmbsmas35sass2753b",
  17. "xinjiang.pro": "https://tpass.xinjiang.chinatax.gov.cn:8443/#/login?client_id=hc62e89d4ece439k8bb6f9f8k7a94hff",
  18. "shandong.pro": "https://tpass.shandong.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.shandong.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=h792a55w35bbht6bbecb9tbea69799ee&response_type=code&state=a48365f04c8b4e98a5d4cd8ffba1e8e6",
  19. "shenzhen.pro": "https://tpass.shenzhen.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.shenzhen.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=b5492bba3b4e4f37b977c354a2b26a59&response_type=code&state=cc32fa6239b54e4387c74b5463f890ba&client_pid=b5492bba3b4e4f37b977c354a2b26a59",
  20. "sichuan.pro": "https://tpass.sichuan.chinatax.gov.cn:8443/#/login?client_id=dddkead26f29477b9ea237d6845b8f44",
  21. "hunan.pro": "https://tpass.hunan.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.hunan.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=ue7c9954acea492784ac6g78939gc2e9",
  22. "jiangxi.pro": "https://tpass.jiangxi.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.jiangxi.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=h6h824d7df2d4d66bdb3ddbd42d43h8f",
  23. "guangxi.pro": "https://tpass.guangxi.chinatax.gov.cn:8443/#/login?client_id=u96fafdfbhda4s699a89es4fsc2hua2e",
  24. "shaanxi.pro": "https://tpass.shaanxi.chinatax.gov.cn:8443/#/login?client_id=gd4bbma9mf6a4559a372da5f5g8b4eb4",
  25. "yunnan.pro": "https://tpass.yunnan.chinatax.gov.cn:8443/#/login?client_id=tc8td8ea8edn4be483f5a9ktd52599n5",
  26. "hainan.pro": "https://tpass.hainan.chinatax.gov.cn:8443/#/login?client_id=c73sas6335e74c3cc2cs645bs9797633",
  27. "gansu.pro": "https://tpass.gansu.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.gansu.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=n4553b866na9459d9f24naesb5ds5asa&response_type=code&state=e4e2bb4d5ba34c19946ba337c9481c55&client_pid=n4553b866na9459d9f24naesb5ds5asa",
  28. "heilongjiang.pro": "https://tpass.heilongjiang.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.heilongjiang.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=j36c2335ff6948fya33ffjaf49p5c9d4&response_type=code&state=b32030206e504c82a845d6d2a754960b",
  29. "anhui.pro": "https://tpass.anhui.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.anhui.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=n7b7ecp5696hna6f969b22pacch966nn&response_type=code&state=723fbb3cf4f74b0ea0b23444b367a57c&client_pid=n7b7ecp5696hna6f969b22pacch966nn",
  30. "liaoning.pro": "https://tpass.liaoning.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.liaoning.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=yd7d85y3ac9a4adhb5387b3b7b7h892a&response_type=code&state=d6882f334cf243bb90771140cc3ec781&client_pid=yd7d85y3ac9a4adhb5387b3b7b7h892a",
  31. "xizang.pro": "https://tpass.xizang.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.xizang.chinatax.gov.cn%3A5100%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=zfca7bznza854da9be798fz4e5b9d724",
  32. "guizhou.pro": "https://tpass.guizhou.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.guizhou.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=aec7eia2ab294w26aw2899f9ded277e5&response_type=code&state=92eb5dd3191e475a8f7c12ff412074da",
  33. "qinghai.pro": "https://tpass.qinghai.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.qinghai.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=u6ret4ft7b5d4e55b5358rbtt3tu44a7&response_type=code&state=6917057c85b54f7db6263db9d5349b66&client_pid=u6ret4ft7b5d4e55b5358rbtt3tu44a7",
  34. "fujian.pro": "https://tpass.fujian.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.fujian.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=y25c624344444baf8b5956934uac2523&response_type=code&state=ee768695dc3b44afa42b179563bfd324",
  35. "ningxia.pro": "https://tpass.ningxia.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.ningxia.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=abyaayyy52464f2yaay275a6d7dcyy2d",
  36. "xiamen.pro": "https://tpass.xiamen.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.xiamen.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=y56b7aay5brf48f8aa7bf24dd54d775r&response_type=code&state=6bd9cff17da24eb49c6fee5be8c8d34f",
  37. "hubei.pro": "https://tpass.hubei.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.hubei.chinatax.gov.cn%2Fportal%2Flogin-web%2Fapi%2Fthird%2Fsso%2Flogin%2Fredirect&client_id=y852fe37d8e24d46ae8923fcd5yee6ac",
  38. // "": "",
  39. "guangdong.pro": "https://tpass.guangdong.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.guangdong.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=c5djdncfa7nj4n2cajna2j68cndbj2fc&response_type=code&state=354981c2cff7446da472a9d4b3d62761",
  40. "zhejiang.pro": "https://tpass.zhejiang.chinatax.gov.cn:8443/#/login?redirect_uri=https%3A%2F%2Fetax.zhejiang.chinatax.gov.cn%3A8443%2Fmhzx%2Fapi%2Fmh%2Ftpass%2Fcode&client_id=tct8zta97w6c46zdt9zc2648227df5z2&response_type=code&state=2255b361ebb944d8ba38d3f414e71425",
  41. }
  42. // GetBaseUri 获取地区域名
  43. func GetBaseUri(Area string) (BaseUrl string) {
  44. BaseUrl = fmt.Sprintf(`https://etax.%s.chinatax.gov.cn:8443`, Area)
  45. if Area == "shaanxi" {
  46. BaseUrl = "https://etax.shaanxi.chinatax.gov.cn"
  47. }
  48. if Area == "sichuan" {
  49. BaseUrl = "https://etax.sichuan.chinatax.gov.cn"
  50. }
  51. if Area == "xizang" {
  52. BaseUrl = "https://etax.xizang.chinatax.gov.cn:5100"
  53. }
  54. return
  55. }
  56. // GetLoginbUri 获取税局首页
  57. func GetLoginbUri(Area string) (BaseUrl string) {
  58. BaseUrl = GetBaseUri(Area)
  59. if Area == "shaanxi" {
  60. BaseUrl += "/"
  61. }
  62. return
  63. }
  64. // GetTpassUri 获取地区域名
  65. func GetTpassUri(Area string) (BaseUrl string) {
  66. return fmt.Sprintf(`https://tpass.%s.chinatax.gov.cn:8443`, Area)
  67. }