mirror of
https://github.com/oceanprotocol/docs.git
synced 2024-11-26 19:49:26 +01:00
add multiple storage types
This commit is contained in:
parent
e14ee28b05
commit
e0111575df
@ -196,12 +196,68 @@ Example:
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
During the publish process, file URLs must be encrypted with a respective _Provider_ API call before storing the DDO on-chain. For this an array of strings with one or multiple URLs is what gets encrypted and send to _Provider_:
|
During the publish process, file URLs must be encrypted with a respective _Provider_ API call before storing the DDO on-chain. For this an array of objects defining the storage access details are sent.
|
||||||
|
Type of objects supported :
|
||||||
|
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<th>Key</th>
|
||||||
|
<th>Description</th>
|
||||||
|
<th>Example</th>
|
||||||
|
</tr>
|
||||||
|
<td>'url'</td>
|
||||||
|
<td>Static URL. Contains url and HTTP method</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
```json
|
```json
|
||||||
["https://url.com/file1.csv", "https://url.com/file2.csv"]
|
[
|
||||||
|
{
|
||||||
|
"url":{
|
||||||
|
"url":"https://url.com/file1.csv",
|
||||||
|
"method":"GET"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url":{
|
||||||
|
"url":"https://url.com/file2.csv",
|
||||||
|
"method":"POST"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
```
|
```
|
||||||
|
|
||||||
|
</td>
|
||||||
|
</tr></table>
|
||||||
|
|
||||||
|
First class integrations supported in the future :
|
||||||
|
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<th>Key</th>
|
||||||
|
<th>Description</th>
|
||||||
|
<th>Example</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>"ipfs"</td><td>IPFS files</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
```json
|
||||||
|
[
|
||||||
|
{ "ipfs": { "hash":"XXX"}}
|
||||||
|
]
|
||||||
|
```
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<tr><td>"filecoin"</td><td>Filecoin storage</td><td> </td></tr>
|
||||||
|
<tr><td>"arwave"</td><td>Arwave</td><td> </td></tr>
|
||||||
|
<tr><td>"storj"</td><td>Storj</td><td> </td></tr>
|
||||||
|
<tr><td>"sql"</td><td>Sql connection, dataset is generated by a query</td><td> </td></tr>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
|
||||||
|
A service can contain multiple files, using multiple storage types.
|
||||||
|
|
||||||
|
|
||||||
To get information about the files after encryption, the `/fileinfo` endpoint of _Provider_ returns based on a passed DID an array of file metadata:
|
To get information about the files after encryption, the `/fileinfo` endpoint of _Provider_ returns based on a passed DID an array of file metadata:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
|
Loading…
Reference in New Issue
Block a user