프로젝트

일반

사용자정보

UploadZip » 이력 » 버전 3

이름없음, 2021/06/04 05:05

1 2 이름없음
h1. uploadZip
2 3 이름없음
3
*Martipart-Form 요청 형식*
4
5
| key | type | description |
6
| file | File | 업로드 할 파일 %{color: #ff0000;}(폴더를 포함하지 않는 zip 확장자 파일)% |
7
| operations | Text(one-line) | 표준 GraphQL Post 요청 형식에 따른 쿼리를 작성합니다. |
8
9
h2. *요청 필드*
10
11
<pre><code class="c">
12
uploadResource(
13
uploadResourceRequest: UploadResourceRequest
14
): UploadLocationResponse
15
</code></pre>
16
17
*UploadResourceRequest*
18
19
| field | type | description |
20
| did | String | snplab의 did |
21
| path | String | 업로드 한 파일 경로 |
22
23
*UploadAdvertizeZipResponse*
24
25
| field | type | description |
26
| command | String | 요청한 Command 유형 |
27
| fullurlPath | [String] | 저장된 파일 경로 |
28
29
*요청 예시*
30
31
<pre>
32
{
33
"query": "mutation($param: UploadResourceRequest){
34
uploadZip(uploadResourceRequest: $param){
35
command fullUrlPath}}",
36
"variables": {
37
"param": {
38
"did": "NfoPEFaG1adkCpijR85L66",
39
"path": "data" 
40
}
41
}
42
}</pre>
43
44
*응답 예시*
45
46
<pre>
47
{
48
"data": {
49
"uploadResource": {
50
"command": "uploadResource",
51
"result": [
52
{
53
"originalFilename": "cc.html",
54
"fullUrlPath": "https://cdn.myd.world/data/cc.html" 
55
}
56
]
57
}
58
}
59
}
60
</pre>
클립보드 이미지 추가 (최대 크기: 97.7 MB)