Begins a fenced metadata scan without reading backup contents.
POST
/api/workspace/file-protection/agent/v1/observations:begin
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Post, RequestUri = new Uri("https://example.com/api/workspace/file-protection/agent/v1/observations:begin"), Headers = { { "X-Moltaro-File-Protection-Agent", "<X-Moltaro-File-Protection-Agent>" }, }, Content = new StringContent("{ \"SourceId\": \"example\", \"AssignmentRevision\": \"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0\", \"ExpectedGeneration\": 1, \"ScanId\": \"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0\", \"ProtocolVersion\": \"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/file-protection/agent/v1/observations:begin';const options = { method: 'POST', headers: { 'X-Moltaro-File-Protection-Agent': '<X-Moltaro-File-Protection-Agent>', 'Content-Type': 'application/json' }, body: '{"SourceId":"example","AssignmentRevision":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","ExpectedGeneration":1,"ScanId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","ProtocolVersion":"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/file-protection/agent/v1/observations:begin \ --header 'Content-Type: application/json' \ --header 'X-Moltaro-File-Protection-Agent: <X-Moltaro-File-Protection-Agent>' \ --data '{ "SourceId": "example", "AssignmentRevision": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ExpectedGeneration": 1, "ScanId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ProtocolVersion": "example" }'Requires TLS at the API connection. A workspace bearer token does not authenticate an Agent.
Send the enrolled device credential in the X-Moltaro-File-Protection-Agent header. Revoked or invalid credentials are rejected.
Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”Obtains a server generation before any filesystem work; retries use the same ScanId.
object
SourceId
string
AssignmentRevision
string format: uuid
ExpectedGeneration
integer format: int64
ScanId
string format: uuid
ProtocolVersion
string
Examplegenerated
{ "SourceId": "example", "AssignmentRevision": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ExpectedGeneration": 1, "ScanId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ProtocolVersion": "example"}Obtains a server generation before any filesystem work; retries use the same ScanId.
object
SourceId
string
AssignmentRevision
string format: uuid
ExpectedGeneration
integer format: int64
ScanId
string format: uuid
ProtocolVersion
string
Examplegenerated
{ "SourceId": "example", "AssignmentRevision": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ExpectedGeneration": 1, "ScanId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ProtocolVersion": "example"}Obtains a server generation before any filesystem work; retries use the same ScanId.
object
SourceId
string
AssignmentRevision
string format: uuid
ExpectedGeneration
integer format: int64
ScanId
string format: uuid
ProtocolVersion
string
Examplegenerated
{ "SourceId": "example", "AssignmentRevision": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ExpectedGeneration": 1, "ScanId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ProtocolVersion": "example"}Responses
Section titled “Responses”OK
Media typeapplication/json
object
Data
object
Generation
integer format: int64
StartedAtUtc
string format: date-time
ExpiresAtUtc
string format: date-time
Errors
Array<object>
object
Code
required
string
Message
required
string
Target
string
Field
string
Metadata
object
key
additional properties
string
Type
integer format: int32
Severity
integer format: int32
Warnings
Array<object>
object
Code
required
string
Message
required
string
Target
string
Field
string
Metadata
object
key
additional properties
string
Type
integer format: int32
Severity
integer format: int32
Success
boolean
Example
{ "Errors": [ { "Type": 0, "Severity": 0 } ], "Warnings": [ { "Type": 0, "Severity": 0 } ]}