Closed rners01 closed 2 months ago
Possibly related to https://github.com/microsoft/kiota-typescript/pull/1120 cc @koros
Hi @rners01,
Thanks for raising the issue. I would like to seek more clarification; at the moment the serialization step intentionally skips all undefined fields see: https://github.com/microsoft/kiota-typescript/issues/1079, e.g
const Item = {
id: "123"
name: "Foo",
serverId: undefined
}
In the example above since the serverId
is undefined
, its omitted, after serialization the payload becomes:
{
"id": "123",
"name": "Foo"
}
Please confirm whether this is what you are seeing on your end and whether it addresses your issue
@koros Not really, it skips ""
empty string values in my case too
@rners01 thanks for the additional information. Any chance you could try with the latest version of the kiota dependencies published today? @koros implemented fixes for that specific scenario already.
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.
Hi, I'd encountered the issue with empty payload request using kiota generated API client. Client ignores payload with empty string or undefined values, eg.
property: ""
orproperty: undefined
. Before the request was made Iconsole.log
my payload and those values were present.Im thinking potentially the problem could be with the serializer..
My setup:
I'm using: