在最新的DocuSign SDK中,我注意到成员“ScaleValue”类型已从string
更改为Number
。
我以前的代码曾经是:
SignHere signHere = new SignHere
{
DocumentId = ....,
ScaleValue = "0.6",
XPosition = "150",
YPosition = "150",
};
我已将其改编为以下内容:
SignHere signHere = new SignHere
{
DocumentId = ....,
ScaleValue = new Number { OriginalValue = "0.6" },
XPosition = "150",
YPosition = "150",
};
但是,这似乎是提交我的包进行创建时出现问题的原因。以下是我收到的错误消息:
Error calling CreateEnvelope: {
"errorCode": "INVALID_REQUEST_BODY",
"message": "The request body is missing or improperly formatted. Cannot deserialize the current JSON object (e.g. {\"name\":\"value\"}) into type 'System.Nullable`1[System.Single]' because the type requires a JSON primitive value (e.g. string, number, boolean, null) to deserialize correctly.\r\nTo fix this error either change the JSON to a JSON primitive value (e.g. string, number, boolean, null) or change the deserialized type so that it is a normal .NET type (e.g. not a primitive type like integer, not a collection type like an array or List<T>) that can be deserialized from a JSON object. JsonObjectAttribute can also be added to the type to force it to deserialize from a JSON object.\r\nPath 'recipients.signers[0].tabs.signHereTabs[0].scaleValue.originalValue', line 1, position 28730."
}