Upload a full project ZIP archive and create a new immutable source revision.
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Post, RequestUri = new Uri("https://example.com/api/workspace/admin/net-operation-project/upload"), Content = new MultipartFormDataContent { new StringContent("") { Headers = { ContentType = new MediaTypeHeaderValue("application/octet-stream"), ContentDisposition = new ContentDispositionHeaderValue("form-data") { Name = "File", FileName = "file", } } }, new StringContent("example") { Headers = { ContentType = new MediaTypeHeaderValue("text/plain"), ContentDisposition = new ContentDispositionHeaderValue("form-data") { Name = "Comment", } } }, },};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/admin/net-operation-project/upload';const form = new FormData();form.append('File', 'file');form.append('Comment', 'example');
const options = {method: 'POST'};
options.body = form;
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/admin/net-operation-project/upload \ --header 'Content-Type: multipart/form-data' \ --form File=@file \ --form Comment=exampleAuthorizations
Section titled “Authorizations”- None
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”object
Uploaded ZIP archive.
Optional revision comment.
Responses
Section titled “Responses”OK
object
Result of uploading a Net Operation Project source archive.
object
Immutable Net Operation Project source revision.
object
Revision identifier.
Project identifier.
Monotonic revision number.
Optional revision comment.
Canonical source tree checksum.
Optional schema contract hash captured with the revision.
Creation timestamp.
Creating user identifier.
Number of files stored in the revision.
Net Operation Project build history record.
object
Build identifier.
Project identifier.
Source revision identifier.
Monotonic build number.
Localization key for current build stage.
Current progress percentage.
Requesting user identifier.
Build request timestamp.
Build start timestamp.
Build completion timestamp.
Worker that claimed the build.
Last worker heartbeat timestamp.
Number of worker attempts.
Optional generated project checksum.
Optional schema contract hash.
Optional structured diagnostics JSON.
Optional short error summary.
Concurrency token.
Safe structured diagnostics for a failed Net Operation Project build.
object
Stable machine-readable reason code.
Whether retrying can reasonably succeed without operator remediation.
Optional PostgreSQL SQLSTATE without SQL or parameter values.
Optional allow-listed publication target kind.
Optional safe logical target identifier.
Stable remediation instruction code.
object
object
object
object
Example
{ "Data": { "Revision": { "SourceKind": 0, "Status": 0 }, "Build": { "Kind": 0, "Status": 0, "Stage": 0, "Failure": { "Category": 0 } } }, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Bad Request
object
Result of uploading a Net Operation Project source archive.
object
Immutable Net Operation Project source revision.
object
Revision identifier.
Project identifier.
Monotonic revision number.
Optional revision comment.
Canonical source tree checksum.
Optional schema contract hash captured with the revision.
Creation timestamp.
Creating user identifier.
Number of files stored in the revision.
Net Operation Project build history record.
object
Build identifier.
Project identifier.
Source revision identifier.
Monotonic build number.
Localization key for current build stage.
Current progress percentage.
Requesting user identifier.
Build request timestamp.
Build start timestamp.
Build completion timestamp.
Worker that claimed the build.
Last worker heartbeat timestamp.
Number of worker attempts.
Optional generated project checksum.
Optional schema contract hash.
Optional structured diagnostics JSON.
Optional short error summary.
Concurrency token.
Safe structured diagnostics for a failed Net Operation Project build.
object
Stable machine-readable reason code.
Whether retrying can reasonably succeed without operator remediation.
Optional PostgreSQL SQLSTATE without SQL or parameter values.
Optional allow-listed publication target kind.
Optional safe logical target identifier.
Stable remediation instruction code.
object
object
object
object
Example
{ "Data": { "Revision": { "SourceKind": 0, "Status": 0 }, "Build": { "Kind": 0, "Status": 0, "Stage": 0, "Failure": { "Category": 0 } } }, "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}Forbidden
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}