|
|
@@ -59,27 +59,28 @@ public class piliang {
|
|
|
}
|
|
|
|
|
|
public static void addClaude(){
|
|
|
- String str = "rsspsaq1682a@outlook.com----jb906318----9e5f94bc-e8a4-4e73-b8be-63364c29d753----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\n" +
|
|
|
- "smltgnx9654i@outlook.com----bu262702----9e5f94bc-e8a4-4e73-b8be-63364c29d753----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\n" +
|
|
|
- "svdwmvs9877m@outlook.com----sp385098----9e5f94bc-e8a4-4e73-b8be-63364c29d753----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";
|
|
|
- List<String> list = Arrays.asList(str.split("\n"));
|
|
|
- System.out.println(list);
|
|
|
- AtomicInteger count = new AtomicInteger(153);
|
|
|
- list.forEach((token)->{
|
|
|
- String[] split = token.split("----");
|
|
|
- String email = split[0];
|
|
|
- String password = split[1];
|
|
|
- String rt = split[3];
|
|
|
- System.out.println(email);
|
|
|
- System.out.println(password);
|
|
|
- JSONObject jsonObject = new JSONObject();
|
|
|
- int andIncrement = count.getAndIncrement();
|
|
|
- jsonObject.putOpt("carID","Claude-PRO-" + andIncrement);
|
|
|
- jsonObject.putOpt("email", email);
|
|
|
- jsonObject.putOpt("password",password);
|
|
|
- jsonObject.putOpt("officialSession",rt);
|
|
|
- HttpResponse execute = new HttpRequest("https://kelaode.nf.video/adminapi/chatgpt/session/add").method(Method.POST).header("apiauth", "chan").body(jsonObject.toString()).execute();
|
|
|
- System.out.println(jsonObject.get("carID") + ":" + execute.body());
|
|
|
- });
|
|
|
+ String filePath = "/Users/chenbiao/project/yhlxj/netflix-web/src/main/java/com/cyksj/web/util/claude.txt"; // 文件路径
|
|
|
+ AtomicInteger count = new AtomicInteger(214);
|
|
|
+ try (BufferedReader reader = new BufferedReader(new FileReader(filePath))) {
|
|
|
+ String line;
|
|
|
+ while ((line = reader.readLine()) != null) {
|
|
|
+ String[] split = line.split("----");
|
|
|
+ String email = split[0];
|
|
|
+ String password = split[1];
|
|
|
+ String rt = split[3];
|
|
|
+ System.out.println(email);
|
|
|
+ System.out.println(password);
|
|
|
+ JSONObject jsonObject = new JSONObject();
|
|
|
+ int andIncrement = count.getAndIncrement();
|
|
|
+ jsonObject.putOpt("carID","Claude-PRO-" + andIncrement);
|
|
|
+ jsonObject.putOpt("email", email);
|
|
|
+ jsonObject.putOpt("password",password);
|
|
|
+ jsonObject.putOpt("officialSession",rt);
|
|
|
+ HttpResponse execute = new HttpRequest("https://kelaode.nf.video/adminapi/chatgpt/session/add").method(Method.POST).header("apiauth", "chan").body(jsonObject.toString()).execute();
|
|
|
+ System.out.println(jsonObject.get("carID") + ":" + execute.body());
|
|
|
+ }
|
|
|
+ }catch (IOException e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ }
|
|
|
}
|
|
|
}
|