Show / Hide Table of Contents

    Input types

    In order for the API to recognize if you actually want to set a value or not when processing an update command, we have introduced input types. They work by wrapping a potentially nullable value in yet another object so that the consumer has to acknowledge that they want to update a value.

    Basically, if the API expects an input type and gets the value null instead, it will just ignore setting the value. If it receives an input type with the inner value of null, it will actually set the domain value to null.

    Example

    An example of this is the UpdateComment command.

    {
    	"CommentId": "42",
    	"RootEntityId": "9827",
    	"Text": null,
    	"RawText": { "Value": null }
    }
    

    When you issue this command, it will not first see that there is no input at all for the value of Text, however RawText has a value that is null.

    This means that the API will not touch the current Text property of the comment, but will set the value of RawText to null.

    Types

    • BooleanInput
    • NotNullBooleanInput
    • DecimalInput
    • NotNullDecimalInput
    • LongInput
    • NotNullLongInput
    • IntegerInput
    • NotNullIntegerInput
    • DateTimeInput
    • NotNullDateTimeInput
    • StringInput
    Back to top Copyright © 2023 Monitor ERP System AB