-
Notifications
You must be signed in to change notification settings - Fork 88
Open
Labels
binding-httpIssues related to http protocol bindingIssues related to http protocol binding
Description
Description / Problem
When consuming HTTP endpoints that return responses with multiple Content-Encoding values (e.g., Content-Encoding: gzip, br
), the HTTP binding in node-wot passes compressed or partially decoded data directly to codecs.
Since codecs expect plain, uncompressed payloads, this results in parsing/validation failures such as:
Invalid value according to DataSchema
Example
Here is an example TD to reproduce the issue:
{
"@context": "https://www.w3.org/2022/wot/td/v1.1",
"title": "dateTimeAPI",
"securityDefinitions": { "nosec_sc": { "scheme": "nosec" } },
"security": ["nosec_sc"],
"properties": {
"currentDateTime": {
"description": "Get current datetime",
"readOnly": true,
"type": "object",
"properties": {
"datetime": { "type": "string", "format": "date-time" }
},
"forms": [
{
"href": "https://aisenseapi.com/services/v1/datetime",
"contentType": "application/json"
}
]
}
}
}
Notes
See #1413 for the initial discussion.
relu91 and danielpeintner
Metadata
Metadata
Assignees
Labels
binding-httpIssues related to http protocol bindingIssues related to http protocol binding