AnsweredAssumed Answered

FMS v17 Data API - No records found query = 500 Error

Question asked by fmdataweb on Aug 29, 2018
Latest reply on Aug 29, 2018 by fmdataweb

I'm just trying to confirm that the following is how the FileMaker 17 Data API works when you make a find query request and no records are found. In my testing so far:

 

1. if there are no records found you get a HTTP/1.1 500 FileMaker Data API Engine Error

2. the response includes this:

 

{

  "messages": [

    {

      "code": "401",

      "message": "No records match the request"

    }

  ],

  "response": {}

}

 

which gives the usual 401 FileMaker error code for 'no records found'. I had been checking the response code for ≠ 200 to confirm a unsuccessful request, but I would argue that in the above case the request was successful but there were no records to return, so I was surprised at the "500 FileMaker Data API Engine Error" as that would usually indicate a more serious server error that couldn't process the request at all.

 

Am I missing something here or is this how it works in this case?

Outcomes