Skip to main content

Saving an empty value using ODATA API is not possible. It changes the task_status but doesn’t update the user_def1 to empty in the below example.

URL : https://<fmsserver>/odata/task(12345)

Method : Patch

1st call (works fine)

Body : 

{

    "task_status": "HOLD",

    "status_as_of": "2021-10-26T15:37:37.0047496",

    "user_def1": "ENROUTE",

    "modified_by": "USER1"

}

 

2nd call (user_def1 is not set to blank)

Body : 

{

    "task_status": "ENROUTE",

    "status_as_of": "2021-10-26T15:37:37.0047496",

    "user_def1": "",

    "modified_by": "USER1"

}

Hi @TDCSOURABH,

Have you tried the suggestions from this article:

There may be other similar articles in the Community as well as this is a common question.

It is always a good idea to search the Community before creating a post in case there is already an answer available.

Kind regards,

Lee Pinchbeck


Yes, I have but that post has nothing to do with the OData REST API. Or at least I have no idea how to configure the Integration settings for ODATA rest api’s. What should be the Data Connector and Message Name ??


Hi @TDCSOURABH,

In that case I would look into training for FSM Connect and Integrations for FSM. It is too in depth a topic to be covered in a Community topic.

You can set up FSM to tell it what to expect and how to interpret data coming from the API.

Kind regards,

Lee Pinchbeck


Figured out a way to update a value to blank.

 

You can use “=” to update a value to blank/null

 

For example if you want to reset user_def1 from any value “ABC” to blank/null just supply “=”

{

    "task_status": "ENROUTE",

    "status_as_of": "2021-10-26T15:37:37.0047496",

    "user_def1": "=",

    "modified_by": "USER1"

}


Reply