{"title":"JsonValue data type","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/methods-auto/jsonvalue/jsonvalue-data-type/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/methods-auto/jsonvalue/jsonvalue-data-type, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/methods-auto/jsonvalue/jsonvalue-data-type","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Is a container for any well-formed fundamental JSON value.","date":"2026-10-01","meta":{"topic":"reference"},"outline":[{"level":2,"title":"Instance methods","slug":"instance-methods","at":173,"chars":4110},{"level":2,"title":"Related information","slug":"related-information","at":4283,"chars":117}],"text":"> Version: _Available or changed with runtime version 1.0._\nIs a container for any well-formed fundamental JSON value. A default JsonValue is set to the JSON value of NULL.\n## Instance methods\nThe following methods are available on instances of the JsonValue data type.\nMethod name|Description\njsonvalue-asbiginteger-method|Converts the value in a JsonValue to an BigInteger data type.\njsonvalue-asboolean-method|Converts the value in a JsonValue to a Boolean data type.\njsonvalue-asbyte-method|Converts the value in a JsonValue to a Byte data type.\njsonvalue-aschar-method|Converts the value in a JsonValue to a Char data type.\njsonvalue-ascode-method|Converts the value in a JsonValue to a Code data type.\njsonvalue-asdate-method|Converts the value in a JsonValue to a Date data type.\njsonvalue-asdatetime-method|Converts the value in a JsonValue to a DateTime data type.\njsonvalue-asdecimal-method|Converts the value in a JsonValue to a Decimal data type.\njsonvalue-asduration-method|Converts the value in a JsonValue to a Duration data type.\njsonvalue-asinteger-method|Converts the value in a JsonValue to an Integer data type.\njsonvalue-asoption-method|Converts the value in a JsonValue to an Option data type.\njsonvalue-astext-method|Converts the value in a JsonValue to a Text data type.\njsonvalue-astime-method|Converts the value in a JsonValue to a Time data type.\njsonvalue-astoken-method|Converts the value in a JsonValue to a JsonToken data type.\njsonvalue-clone-method|Creates a deep-copy of the JsonToken value.\njsonvalue-isnull-method|Indicates whether the JsonValue contains the JSON value of NULL.\njsonvalue-isundefined-method|Indicates whether the JsonValue contains the JSON value of UNDEFINED.\njsonvalue-path-method|Retrieves the JSON path of the value relative to its containing tree.\nReadFrom(Text)<jsonvalue-readfrom-string-method>|Reads the JSON data into a JsonValue variable.\njsonvalue-readfrom-instream-method|Reads the JSON data from the stream into a JsonValue variable.\nSelectToken(Text, var JsonToken)<jsonvalue-selecttoken-method>|Selects a JsonToken using a JPath expression.\njsonvalue-setvalue-boolean-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-char-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-byte-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-option-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-integer-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-biginteger-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-decimal-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-duration-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-date-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-time-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvalue-datetime-method|Set the contents of the JsonValue variable to the JSON representation of the given value.\nSetValue(Text)<jsonvalue-setvalue-string-method>|Set the contents of the JsonValue variable to the JSON representation of the given value.\njsonvalue-setvaluetonull-method|Set the contents of the JsonValue variable to the JSON representation of NULL.\njsonvalue-setvaluetoundefined-method|Set the contents of the JsonValue variable to the JSON representation of UNDEFINED.\nWriteTo(var Text)<jsonvalue-writeto-text-method>|Serializes and writes the JSON data of the JsonValue to a given object.\njsonvalue-writeto-outstream-method|Serializes and writes the JSON data of the JsonValue to a given object.\n> NOTE\n> For performance reasons all HTTP, JSON, TextBuilder, and XML types are reference types, not value types. Reference types holds a pointer to the data elsewhere in memory, whereas value types store its own data.\n## Related information\nGet Started with AL<../../devenv-get-started>\nDeveloping Extensions<../../devenv-dev-overview>"}