[SOLVED] Search for a specific Request using the API

[SOLVED] Search for a specific Request using the API

I would like to make a call using the API and return a specific ticket by filtering on several categories. I think it is possible or almost possible but I am slightly hung up.

My problem is that the documentation says to "Get all requests" I should use a Get method, but in the documentation also tells me to send input_data in json to specify my search parameters but if I do that I would have to send a POST or a PUT.

Here is what I have:

in Powershell
Invoke-RestMethod -uri [URL/api/v3/requests] -headers @{TECHNICIAN_KEY=[REDACTED]} -Method POST -Body $inputData

Inside of $inputData I have:

{
    "list_info":  {
                      "row_count":  "1",
                      "sort_field":  "created_time.display_value",
                      "search_fields":  {
                                            "subject":  "New User",
                                            "group.name":  "Access Request",
                                            "status.name":  "Open"
                                        },
                      "sort_order":  "asc"
                  }
}

All I get is 4004 error codes.

                  New to ADSelfService Plus?