IRPCSharedLinksPublic.UploadSharedFile
Vault API / standard write no session
Uploads a block of new content for a file opened for editing in Office for the web. Used by M-Files clients; applications rarely call it.
| Service | Shared links (anonymous access) MFiles.IRPCSharedLinksPublic |
|---|---|
| gRPC method | /MFiles.IRPCSharedLinksPublic/UploadSharedFile |
| HTTP (mf-http-grpc) | POST /grpc/v1/upload-shared-file |
| Request | UploadSharedFileRequest |
| Response | UploadSharedFileResponse |
| Book and level | Vault API, standard |
| Kind | write |
| Session | Not needed: the call can be made before logging in. |
| Idempotent | no |
| Returns metadata structure version | no |
| Streaming | none (unary) |
Remarks
- Works only with links of type
SHARED_LINK_TYPE_WOPIEDIT; other links fail with "The parameter is incorrect.". - Start with
upload_id0 andoffset0, then send the following blocks with the returnedupload_id. Finish with UploadSharedFileCommit.
Request: UploadSharedFileRequest
Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.
| Field | Type | Description |
|---|---|---|
guid_vault | string | The vault GUID. |
access_key | string | The access key of the editing link. |
upload_id | int32 | 0 for the first block; then the upload_id that the first call returned. |
additional_data[] | repeated NamedValue | Optional named values. Can be empty. |
additional_data[].key | string | The name of the value. |
additional_data[].value | TypedValue | The value as a serialized bytearray. |
additional_data[].value.is_null_value | bool | True if the value is empty. data is then unset. |
additional_data[].value.type | Datatype | The data type of the value. |
additional_data[].value.data | TypedValueUnion | The value, in the member that matches type. Unset for an empty value. |
total_size_in_bytes | int64 | The total size of the file. Read only with the first block (offset 0). |
offset | int64 | The position of this block in the file. Use multiples of 4096 bytes. |
data | bytes | The bytes of this block. |
Response: UploadSharedFileResponse
Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.
| Field | Type | Description |
|---|---|---|
upload_id | int32 | The upload ID to use for the following blocks and the commit. |
Related methods
- UploadSharedFileCommit -- Completes an upload made with UploadSharedFile and stores the content in the checked-out file. Used by M-Files clients; applications rarely call it.