cancel
Showing results for 
Search instead for 
Did you mean: 

get members of a group REST API not responding

sara-fatima
Champ in-the-making
Champ in-the-making

Hello everyone, I am using alfresco trial version with a local deployment using docker. All other REST APIs are working fine for me except the api to get members of a group. This is the way I call the API

curl -X GET -H 'Accept: application/json' -H 'Authorization: Basic <token>' 'http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_EMAIL_CONTRIBUTORS/members' | jq
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- 0:01:17 --:--:-- 0

and this is the log I see

proxy_1               | 2023/01/06 13:42:23 [error] 26#26: *240 upstream sent no valid HTTP/1.0 header while reading response header from upstream, client: 172.18.0.1, server: , request: "GET /alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_ALFRESCO_ADMINISTRATORS/members HTTP/1.1", upstream: "http://172.18.0.7:8080/alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_ALFRESCO_ADMINISTRATORS/members", host: "localhost:8080"

the API returns nothing basically and I really need to get members of a group. Any help would be highly appreciated.

2 REPLIES 2

sanjaybandhaniya
Elite Collaborator
Elite Collaborator

I  have tried this api with Alfresco 7.3 and working.

curl -X GET -H "authorization: Basic YWRtaW46YWRtaW4=" "http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_EMAIL_CONTRIBUT..." -H "accept: application/json" 

{"list":{"pagination":{"count":1,"hasMoreItems":false,"totalItems":1,"skipCount":0,"maxItems":100},"entries":[{"entry":{"displayName":"admin","id":"admin","memberType":"PERSON"}}]}}

thankyou for your reply. I have tried again but faced the same issue again.

proxy_1               | 2023/01/12 03:51:53 [error] 26#26: *407 upstream sent no valid HTTP/1.0 header while reading response header from upstream, client: 172.20.0.1, server: , request: "GET /alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_site_swsdp/members HTTP/1.1", upstream: "http://172.20.0.5:8080/alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_site_swsdp/members", host: "localhost:8080"
proxy_1               | 172.20.0.1 - - [12/Jan/2023:03:51:53 +0000] "GET /alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_site_swsdp/members HTTP/1.1" 009 111 "-" "curl/7.79.1"

the call I made:

curl -X GET -H 'Accept: application/json' -H 'Authorization: Basic VElDS0VUX2I4YWJlOGM5ODFkZGZhYmMzNTUxYThiYzIwMjlkMGQxMDdmNWIwZmI=' 'http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/groups/GROUP_site_swsdp/members' | jq
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:01:17 --:--:--     0