Forum Stats

  • 3,780,928 Users
  • 2,254,456 Discussions
  • 7,879,497 Comments

Discussions

HCM REST API Workers problem with Query

Martin...
Martin... Member Posts: 4 Green Ribbon
edited Dec 1, 2021 1:02AM in HCM Cloud Service

Hi,

On this page:

There is an example of a call to retrieve workers by names.LastName

GET "https://<host>:<port>/hcmRestApi/resources/11.13.18.05/workers?q=names.LastName='Doe'"

Every time I call the API in this form I receive the response:

400 Bad Request

URLrequestparameterqwithvaluenames.LastName='Doe'isnotvalid.


I have also tried this with publicWorker:

/hcmRestApi/resources/11.13.18.05/publicWorkers?q=LastName='Doe'

Successfully returns a matched record

/hcmRestApi/resources/11.13.18.05/publicWorkers?q=LastName like 'Do%'

Returns a zero result list


Am I misunderstanding the call with the q= parameter or is there an issue?


Thanks