MCPcopy
hub / github.com/iterative/cml / upload

Method upload

src/drivers/gitlab.js:133–143  ·  view source on GitHub ↗
(opts = {})

Source from the content-addressed store, hash-verified

131 }
132
133 async upload(opts = {}) {
134 const projectPath = await this.projectPath();
135 const endpoint = `/projects/${projectPath}/uploads`;
136 const { size, mime, data } = await fetchUploadData(opts);
137 const body = new FormData();
138 body.append('file', data);
139
140 const { url } = await this.request({ endpoint, method: 'POST', body });
141
142 return { uri: url, mime, size };
143 }
144
145 async runnerToken(body) {
146 const projectPath = await this.projectPath();

Callers 4

publishMethod · 0.45
github.e2e.test.jsFile · 0.45
gitlab.e2e.test.jsFile · 0.45

Calls 3

projectPathMethod · 0.95
requestMethod · 0.95
fetchUploadDataFunction · 0.85

Tested by

no test coverage detected