注册 登录
n/tools · 5 个月前 · 已编辑 · 2659 次浏览
u/MuXu_YI黄金3 YEARS
n/toolsu/MuXu_YI 3 YEARS · 5 个月前

K12 team自动拉取(gmail后缀)

注册登陆gmail账号,然后consle运行脚本。见下:

fetch("https://chatgpt.com/api/auth/session", {
  method: "GET",
  credentials: "include"
})
  .then(response => response.json())
  .then(sessionData => {
    const accessToken = sessionData.accessToken;
    
    if (!accessToken) {
      throw new Error("未能获取到 accessToken");
    }
    
    console.log("获取到 accessToken,正在发送邀请请求...");
    
    return fetch("https://chatgpt.com/backend-api/accounts/5e4c9b31-1b4e-4887-839b-607597928d7c/invites/request", {
      method: "POST",
      headers: {
        "accept": "*/*",
        "accept-language": "en-US,en;q=0.9",
        "authorization": `Bearer ${accessToken}`, // ← 这里使用了正确的反引号
        "cache-control": "no-cache",
        "oai-language": "en-US",
        "pragma": "no-cache",
        "sec-ch-ua-arch": "\"x86\"",
        "sec-ch-ua-bitness": "\"64\"",
        "sec-ch-ua-mobile": "?0",
        "sec-ch-ua-model": "\"\"",
        "sec-ch-ua-platform": "\"macOS\"",
        "sec-ch-ua-platform-version": "\"13.5.1\"",
        "sec-fetch-dest": "empty",
        "sec-fetch-mode": "cors",
        "sec-fetch-site": "same-origin"
      },
      referrer: "https://chatgpt.com/k12-verification",
      referrerPolicy: "strict-origin-when-cross-origin",
      body: null,
      mode: "cors",
      credentials: "include"
    });
  })
  .then(response => response.json())
  .then(result => {
    console.log("邀请请求成功:", result);
  })
  .catch(error => {
    console.error("请求失败:", error);
  });

转换服务: https://gtxx3600.github.io/GPTSession2CPAandSub2API/

31
65
登录后参与讨论。
海外原生IP VPS,稳定访问全球网络

还在为IP不纯、平台风控、频繁验证而烦恼? 丽萨主机海外原生IP VPS,双ISP住宅IP,覆盖美国、香港、日本、新加坡、台湾、德国、越南、英国等热门地区,适合跨境电商、社媒运营、AI工具、流媒体及海外业务使用。

lisahost.com 了解更多

65 条回复

排序
  1. Foch0x97 黄金 5 个月前 #2

    Done,感谢分享

    1
  2. MuXu_YI 黄金 楼主 3 YEARS 5 个月前 #3

    拿出来卖的吃相难看,所以我发出来了

    0
  3. yeluo 白银 5 个月前 #4

    佬 登codex能绕过接码吗

    0
  4. na_lu 黄金 5 个月前 #5

    需要重新登录账号么

    0
  5. MuXu_YI 黄金 楼主 3 YEARS 5 个月前 #6
    回复 @yeluo:佬 登codex能绕过接码吗

    不能,目前只能RT使用,不影响使用,sub2 cpa格式转换。

    0
  6. MuXu_YI 黄金 楼主 3 YEARS 5 个月前 #7
    回复 @na_lu:需要重新登录账号么

    不需要,刷新一下就行了

    0
  7. zatxm120 白银 5 个月前 #8

    感谢大佬

    0
  8. geepark 白银 5 个月前 #9

    It works guys try out

    0
  9. ll_dong 黄金 3 YEARS 5 个月前 #10

    大佬牛,已经成功了

    0
  10. Yuxiaojie 黄金 5 个月前 #11

    = =真不错

    0
  11. ashengwanAI 黄金 5 个月前 #12
    回复 @Foch0x97:Done,感谢分享

    佬,用自己的gmail会被封号吗?

    1
  12. yeluo 白银 5 个月前 #13
    回复 @MuXu_YI:不能,目前只能RT使用,不影响使用,sub2 cpa格式转换。

    佬 rt怎么获取呢

    0
  13. Foch0x97 黄金 5 个月前 #14
    回复 @ashengwanAI:佬,用自己的gmail会被封号吗?

    不清楚,最好别用大号

    1
  14. ashengwanAI 黄金 5 个月前 #15
    回复 @Foch0x97:不清楚,最好别用大号

    好的

    1
  15. yeluo 白银 5 个月前 #16
    回复 @yeluo:佬 rt怎么获取呢

    看到了 感谢佬

    0
  16. duongdang941 白银 5 个月前 #17

    Co the chuyen tai khoan Owner sang tai khoan domain. Sau do config bat dang nhap bang SSO duoc khong

    0
  17. 1751140932 黄金 5 个月前 #18

    牛逼,佬!

    0
  18. nikka8964 白银 5 个月前 #19

    感谢佬

    0
  19. account_not_defined 白银 5 个月前 #20

    必须使用Gmail邮箱注册的gpt才可以吗? 还是说其他邮箱都行?

    0
  20. kun_tao 白银 5 个月前 #21

    谢谢大佬分享

    0
  21. Struhaqi 黄金 5 个月前 #22

    这个是?能干些什么

    0
  22. MuXu_YI 黄金 楼主 3 YEARS 5 个月前 #23
    回复 @account_not_defined:必须使用Gmail邮箱注册的gpt才可以吗? 还是说其他邮箱都行?

    必须gmail.com后缀

    0
  23. CoolMan 钻石 3 YEARS 5 个月前 #24

    加入

    0
  24. qinyu521 白银 5 个月前 #25

    只能说大佬牛逼

    0
  25. AsaYong 白银 5 个月前 #26

    感谢佬!it worked

    0
  26. na_lu 黄金 5 个月前 #27

    怎么弄到sub呢,添加sub的时候要手机号

    0
  27. lij1122 黄金 3 YEARS 5 个月前 #28

    感谢

    0
  28. BigWai 白银 5 个月前 #29

    牛逼大佬

    0
  29. Jewel_Pfeiffer 黄金 3 YEARS 5 个月前 #30

    谷歌授权登陆可以成功

    0