Create or idempotently resume a managed multipart upload.
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Post, RequestUri = new Uri("https://example.com/api/workspace/files/uploads"), Headers = { { "Authorization", "Bearer <token>" }, }, Content = new StringContent("{ \"TargetFolderId\": \"example\", \"RequestedFileName\": \"example\", \"DeclaredMimeType\": \"example\", \"DeclaredSizeBytes\": 1, \"ClientDeclaredSha256\": \"example\", \"IdempotencyKey\": \"example\", \"OwnerModuleKey\": \"example\", \"OwnerResourceKind\": \"example\", \"OwnerContextResourceId\": \"example\", \"OwnerResourceObjectId\": \"example\", \"Description\": \"example\", \"PublicationMode\": 0, \"FieldTarget\": { \"EntityDefinitionIdOrKey\": \"example\", \"FieldId\": \"example\", \"InstanceId\": \"example\", \"CreateOperationKey\": \"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0\", \"DraftFields\": { \"additionalProperty\": \"example\" } }, \"FileReferenceId\": \"example\", \"ParentContext\": { \"EntityDefinitionId\": \"example\", \"FormSurfaceId\": \"example\", \"ExpectedRevision\": \"example\", \"ItemId\": \"example\", \"ParentInstanceId\": \"example\", \"ParentFields\": { \"additionalProperty\": \"example\" } } }") { Headers = { ContentType = new MediaTypeHeaderValue("application/json") } }};using (var response = await client.SendAsync(request)){ response.EnsureSuccessStatusCode(); var body = await response.Content.ReadAsStringAsync(); Console.WriteLine(body);}const url = 'https://example.com/api/workspace/files/uploads';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"TargetFolderId":"example","RequestedFileName":"example","DeclaredMimeType":"example","DeclaredSizeBytes":1,"ClientDeclaredSha256":"example","IdempotencyKey":"example","OwnerModuleKey":"example","OwnerResourceKind":"example","OwnerContextResourceId":"example","OwnerResourceObjectId":"example","Description":"example","PublicationMode":0,"FieldTarget":{"EntityDefinitionIdOrKey":"example","FieldId":"example","InstanceId":"example","CreateOperationKey":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","DraftFields":{"additionalProperty":"example"}},"FileReferenceId":"example","ParentContext":{"EntityDefinitionId":"example","FormSurfaceId":"example","ExpectedRevision":"example","ItemId":"example","ParentInstanceId":"example","ParentFields":{"additionalProperty":"example"}}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/workspace/files/uploads \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "TargetFolderId": "example", "RequestedFileName": "example", "DeclaredMimeType": "example", "DeclaredSizeBytes": 1, "ClientDeclaredSha256": "example", "IdempotencyKey": "example", "OwnerModuleKey": "example", "OwnerResourceKind": "example", "OwnerContextResourceId": "example", "OwnerResourceObjectId": "example", "Description": "example", "PublicationMode": 0, "FieldTarget": { "EntityDefinitionIdOrKey": "example", "FieldId": "example", "InstanceId": "example", "CreateOperationKey": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "DraftFields": { "additionalProperty": "example" } }, "FileReferenceId": "example", "ParentContext": { "EntityDefinitionId": "example", "FormSurfaceId": "example", "ExpectedRevision": "example", "ItemId": "example", "ParentInstanceId": "example", "ParentFields": { "additionalProperty": "example" } } }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Optional access token for clients that cannot set Authorization headers. Prefer Authorization: Bearer <token> when possible.
Request Body
Section titled “Request Body”Request to create an S3-backed managed FileSystem upload.
object
Field coordinates used to authorize upload and subsequent FK assignment.
object
Entity definition ID or stable key.
Immutable field definition ID, including a child-table File field.
Existing root instance, or null when preparing a new instance.
For a new instance, the same operation key supplied to Entity create.
Actual unsaved form values used for create-permission preview.
object
The parent draft of a child draft in a Form with a WithParent section, sent with a child-scoped request made
before the Form is saved. The server builds the parent’s effective draft for the actor (defaults, effects and
calculations of the parent Form evaluation) and exposes it only as the record the child’s parent Reference points to;
the child’s parent Reference is set by the server. Preview only: nothing is written and nothing is granted, the Form
submission decides everything again.
object
Id of the parent Entity definition.
Id of the parent Form surface.
The Submission.Revision of the parent Form the client renders.
Id of a WithParent related-table item of the child’s relation (any repeated item of that relation; its
own child Form is the one the request runs on).
Id of the existing parent record; null while the parent is created by the same Form.
Unsaved parent draft values by field key, as the parent Form evaluation takes them.
object
Request to create an S3-backed managed FileSystem upload.
object
Field coordinates used to authorize upload and subsequent FK assignment.
object
Entity definition ID or stable key.
Immutable field definition ID, including a child-table File field.
Existing root instance, or null when preparing a new instance.
For a new instance, the same operation key supplied to Entity create.
Actual unsaved form values used for create-permission preview.
object
The parent draft of a child draft in a Form with a WithParent section, sent with a child-scoped request made
before the Form is saved. The server builds the parent’s effective draft for the actor (defaults, effects and
calculations of the parent Form evaluation) and exposes it only as the record the child’s parent Reference points to;
the child’s parent Reference is set by the server. Preview only: nothing is written and nothing is granted, the Form
submission decides everything again.
object
Id of the parent Entity definition.
Id of the parent Form surface.
The Submission.Revision of the parent Form the client renders.
Id of a WithParent related-table item of the child’s relation (any repeated item of that relation; its
own child Form is the one the request runs on).
Id of the existing parent record; null while the parent is created by the same Form.
Unsaved parent draft values by field key, as the parent Form evaluation takes them.
object
Request to create an S3-backed managed FileSystem upload.
object
Field coordinates used to authorize upload and subsequent FK assignment.
object
Entity definition ID or stable key.
Immutable field definition ID, including a child-table File field.
Existing root instance, or null when preparing a new instance.
For a new instance, the same operation key supplied to Entity create.
Actual unsaved form values used for create-permission preview.
object
The parent draft of a child draft in a Form with a WithParent section, sent with a child-scoped request made
before the Form is saved. The server builds the parent’s effective draft for the actor (defaults, effects and
calculations of the parent Form evaluation) and exposes it only as the record the child’s parent Reference points to;
the child’s parent Reference is set by the server. Preview only: nothing is written and nothing is granted, the Form
submission decides everything again.
object
Id of the parent Entity definition.
Id of the parent Form surface.
The Submission.Revision of the parent Form the client renders.
Id of a WithParent related-table item of the child’s relation (any repeated item of that relation; its
own child Form is the one the request runs on).
Id of the existing parent record; null while the parent is created by the same Form.
Unsaved parent draft values by field key, as the parent Form evaluation takes them.
object
Responses
Section titled “Responses”OK
object
Public state of a resumable managed file upload. PublishedFileReferenceId is non-null only once the session reaches Available.
object
One provider-confirmed uploaded part safe to expose for resume.
object
object
object
object
object
object
object
object
Example
{ "Data": null, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Bad Request
object
Public state of a resumable managed file upload. PublishedFileReferenceId is non-null only once the session reaches Available.
object
One provider-confirmed uploaded part safe to expose for resume.
object
object
object
object
object
object
object
object
Example
{ "Data": null, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Forbidden
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Not Found
object
Public state of a resumable managed file upload. PublishedFileReferenceId is non-null only once the session reaches Available.
object
One provider-confirmed uploaded part safe to expose for resume.
object
object
object
object
object
object
object
object
Example
{ "Data": null, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Conflict
object
Public state of a resumable managed file upload. PublishedFileReferenceId is non-null only once the session reaches Available.
object
One provider-confirmed uploaded part safe to expose for resume.
object
object
object
object
object
object
object
object
Example
{ "Data": null, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Too Many Requests
object
object
object
object
object
Example
{ "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Service Unavailable
object
Public state of a resumable managed file upload. PublishedFileReferenceId is non-null only once the session reaches Available.
object
One provider-confirmed uploaded part safe to expose for resume.
object
object
object
object
object
object
object
object
Example
{ "Data": null, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}