Hiya All,
I am currently trying to integrate with the Confluence API, to get wiki content pages to be used in a separate application. As part of this integration, I need to query content pages, and get pages updated within the last 24 hours, which is where to issue is occurring. I am getting errors when attempting to order by, or filter by the last modified date.
I have outlined more details below.
The Goal:
The Issue:
- When using the below call, I am seeing a 400 error with the message 'com.atlassian.confluence.api.service.exceptions.BadRequestException: Unsupported orderBy field: history.lastUpdated desc'.
- https://{{my domain}}.atlassian.net/wiki/rest/api/content?expand=history.lastUpdated&orderby=history.lastUpdated desc
- An alternative approach that was tried was the search endpoint, and CQL, but this returns another error, detailed below.
- https://{{my domain}}.atlassian.net/wiki/rest/api/content/search?cql=type = page and lastmodified > startOfWeek()
- Error: "com.atlassian.confluence.api.service.exceptions.SSStatusCodeException: CQL was parsed but the search manager was unable to execute the search. Error message: com.atlassian.confluence.api.service.exceptions.SSStatusCodeException: There was an illegal request passed to XP-Search Aggregator API : HTTP/1.1 403 Forbidden"
Any assistance is much appreciated.