Documentation for version v72
Unpack
Description
The Unpack pipe unmarshals JSON or XML from the $in.body field and writes the result to $in.data
Peculiarities:
$in.body must be a byte array
Structure
| Field | Type of value | Example | Required | Description |
|---|---|---|---|---|
| id | number | 10 | yes | Pipe's ID |
| type | string | "unpack" | yes | Type of a pipe |
| params | UnpackParamsObject | no | Type-specific parameters | |
| outs | OutsObject | no | Pipe's outputs |
| UnpackParamsObject | |||||
|---|---|---|---|---|---|
| Field | Type | Example | Reqiered | Default | Description |
| type | string | "JSON" | no | "JSON" | Format. Possible values: -JSON - XML |
Errors
- $in.body is not found.
- $in.body is not a byte array.
- params.type is not valid
- Byte unmarshalling error.
Examples
{
"id": 10,
"type": "unpack",
"params": {
"type": "XML"
},
"outs": {
"success": 20,
"error": 1000
}
}
{
"id": 10,
"type": "unpack",
"outs": {
"success": 15,
"error": 1001
}
}