MCPcopy Index your code
hub / github.com/smallfawn/QLScriptPublic / createDefaultNote

Method createDefaultNote

daily/ydyp.js:4133–4143  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4131 return this.noteToken = e.headers?.NOTE_TOKEN || e.headers?.note_token || "", this.noteAuth = e.headers?.APP_AUTH || e.headers?.app_auth || "", !(!this.noteToken || !this.noteAuth)
4132 }
4133 async createDefaultNote() {
4134 if (!await this.refreshNoteToken()) return void this.log("跳过创建笔记: 缺少 authToken");
4135 const e = {
4136 ...pt,
4137 APP_NUMBER: this.account,
4138 APP_AUTH: this.noteAuth,
4139 NOTE_TOKEN: this.noteToken
4140 },
4141 t = await this.api.syncNotebook(e);
4142 this.notebookId = t?.notebooks?.[0]?.notebookId || "", this.notebookId ? (await this.api.createNote(e, this.notebookId), this.log("创建笔记完成")) : this.log("获取默认笔记本失败")
4143 }
4144 async uploadZeroFile() {
4145 await this.api.uploadSimpleFile(), this.log("上传任务文件完成")
4146 }

Callers 1

doTaskMethod · 0.95

Calls 2

refreshNoteTokenMethod · 0.95
logMethod · 0.95

Tested by

no test coverage detected