Re: Adding a member programmatically
The tags in my prior update did not go through. The Atom doc should look like this, with the square brackets replaced with angled brackets.
[?xml version="1.0" encoding="UTF-8"?]
This info is wrong. Here's how to add a member to a community:
REST endpoint: /communities/service/atom/community/members (not /communities/service/atom2/acl, as indicated in the doc)
URL parameter: communityUuid= (no memberid, as indicated in the doc)
Minimal Atom entry document representing the user
With the above, you can easily test this using wget, as follows:
Copy the XML into a file (e.g. payload.xml)
Run wget --no-check-certificate --user lcadmin --password passw0rd --post-file=payload.xml --header="Content-Type: application/atom+xml" https://connections.ibm.com/communities/service/atom/community/members?communityUuid=6cdca030-a7e6-4795-9a69-aefd1654a0b0
It is critical that you add the "Content-Type: application/atom+xml" header or the parser will fail to recognize the document, throwing exceptions on the JVM and resulting in an HTTP 400 on the client end.