Skip to main content

Parse OpenSPP fields from uploaded JSON file

Upload a JSON file; the server infers field types and returns the schema. Max 10 MB.

Request​

Method: POST
Path: /api/openspp-fields/parse-file

Authentication: Not required

Responses​

200 - Parsed fields​

400 - Invalid JSON or missing file​

Examples​

cURL​

curl -X POST \
-H "Content-Type: application/json" \
http://localhost:3000/api/openspp-fields/parse-file \
-d '{"example": "data"}'

JavaScript​

const response = await fetch('http://localhost:3000/api/openspp-fields/parse-file', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
// Request data
}),
});

const data = await response.json();
console.log(data);

This documentation is automatically generated from the OpenAPI specification.