As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
public static void main(String[] args) throws UnsupportedEncodingException{ HttpClient client = new HttpClient(); client.getParams().setAuthenticationPreemptive(true); Credentials defaultcreds = new UsernamePasswordCredentials("admin", "admin"); client.getState().setCredentials(AuthScope.ANY, defaultcreds); GetMethod method = new GetMethod("http://127.0.0.1:8085/alfresco/wcs/api/groups/ALFRESCO_ADMINISTRATORS"); try { System.out.println(client.executeMethod(method)); System.out.println(method.getResponseBodyAsString()); } catch (HttpException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } }
GetMethod method = new GetMethod("http://127.0.0.1:8085/alfresco/s/api/groups/ALFRESCO_ADMINISTRATORS");
200 { "data":{ "authorityType": "GROUP", "shortName": "ALFRESCO_ADMINISTRATORS", "fullName": "GROUP_ALFRESCO_ADMINISTRATORS", "displayName": "ALFRESCO_ADMINISTRATORS", "isRootGroup": true, "isAdminGroup": false, "url": "/api/groups/ALFRESCO_ADMINISTRATORS" } }