.middleware.grouper.grouperClient.4.9.3.source-code.grouper.client.usage.example.txt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of grouperClient Show documentation
Show all versions of grouperClient Show documentation
Client for Grouper LDAP and Web Services
====
Copyright 2014 Internet2
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
====
Grouper Client USAGE:
This program runs queries against grouper ldap and web services
The system exit code will be 0 for success, and not 0 for failure
Output data is printed to stdout, error messages are printed to stderr or logs (configured in grouper.client.properties)
Grouper client webpage: https://spaces.internet2.edu/display/Grouper/Grouper+Client
Arguments are in the format: --argName=argValue
Example argument: --operation=encryptPassword
Example argument(OS dependent): --operation="value with whitespace"
Optional arguments below are in [brackets]
###############################################
## Misc operations
Encrypt passwords for storing passwords in external encrypted files:
java -jar grouperClient.jar --operation=encryptPassword [--dontMask=true|false]
Usage (this message):
java -jar grouperClient.jar
Send file to web service (readOnly is a designation for the always available client):
java -jar grouperClient.jar --operation=sendFile --urlSuffix=groups/aStem:aGroup/members [fileName=theFileName] [fileContents=theFileContents] [--contentType=text/xml] [--labelForLog=addMember] [--indentOutput=false] [--saveResultsToFile=fileName] [--readOnly=true] [--debug=true] [--clientVersion=someVersion]
e.g. java -jar grouperClient.jar --operation=sendFile --fileName="C:/addMember.xml" --urlSuffix=groups/aStem:aGroup/members
###############################################
## LDAP operations
NOTE: CHANGE THIS OR REMOVE IN grouper.client.usage.txt FOR YOUR SCHOOOL'S LDAP QUERIES
pennname to pennid usage:
java -jar grouperClient.jar --operation=pennnameToPennid --pennnameToDecode=pennname [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--debug=true]
e.g.: java -jar grouperClient.jar --operation=pennnameToPennid --pennnameToDecode=jsmith
output: pennid: 12341234
NOTE: CHANGE THIS OR REMOVE IN grouper.client.usage.txt FOR YOUR SCHOOOL'S LDAP QUERIES
pennid to pennname usage:
java -jar grouperClient.jar --operation=pennidToPennkey --pennidToDecode=pennid [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--debug=true]
e.g.: java -jar grouperClient.jar --operation=pennidToPennkey --pennidToDecode=12341234
output: pennname: jsmith
NOTE: CHANGE THIS OR REMOVE IN grouper.client.usage.txt FOR YOUR SCHOOOL'S LDAP QUERIES
hasMember ldap usage:
java -jar grouperClient.jar --operation=hasMemberLdap --groupName=a:b:c --pennnameToCheck=pennkey [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--debug=true]
e.g.: java -jar grouperClient.jar --operation=hasMemberLdap --groupName=penn:myfolder:mygroup --pennnameToCheck=jsmith
output: hasMemberLdap: true
NOTE: CHANGE THIS OR REMOVE IN grouper.client.usage.txt FOR YOUR SCHOOOL'S LDAP QUERIES
getMembers ldap usage:
java -jar grouperClient.jar --operation=getMembersLdap --groupName=a:b:c [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--debug=true]
e.g.: java -jar grouperClient.jar --operation=getMembersLdap --groupName=penn:myfolder:mygroup
output: groupList: jsmith, tsmith, msmith
note: extremely large group lists might not display fully (e.g. over 1000 members)
###############################################
## Web Service operations
addMemberWs web service usage (note: you can replace all members of a group also):
java -jar grouperClient.jar --operation=addMemberWs [--groupName=a:b:c] [--groupUuid=123abc] [--groupIdIndex=12345] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--subjectIdsFile=fileName] [--subjectIdentifiersFile=fileName] [--subjectSourcesFile=fileName] [--defaultSubjectSource=subjectSourceId] [--fieldName=fieldNameToAdd] [--txType=NONE|READ_WRITE_NEW] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--replaceAllExisting=true|false] [--disabledTime=yyyy/mm/dd hh:mi:ss] [--enabledTime=yyyy/mm/dd hh:mi:ss] [--addExternalSubjectIfNotFound=true|false] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=addMemberWs --groupName=aStem:aGroup --subjectIds=12345,23456
output line: Index 0: success: T: code: SUCCESS: 12345
getMembersWs web service usage:
java -jar grouperClient.jar --operation=getMembersWs [--groupNames=a:b:c,a:b:d] [--groupUuids=1234,abcd] [--groupIdIndexes=1234,2345] [--fieldName=fieldNameToAdd] [--memberFilter=All|Immediate|NonImmediate|Effective|Composite] [--sourceIds=sourceId1,sourceId2] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--pointInTimeFrom=yyyy/mm/dd hh:mi:ss] [--pointInTimeTo=yyyy/mm/dd hh:mi:ss] [--pageSize=100] [--pageNumber=1] [--sortString=displayName] [--ascending=true|false] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source] [--autopage=true] [--autopageOverlap=50]
e.g.: java -jar grouperClient.jar --operation=getMembersWs --groupNames=aStem:aGroup,aStem:aGroup2
output line: GroupIndex 0: success: T: code: SUCCESS: group: aStem:aGroup: subjectIndex: 0: 12345
deleteMemberWs web service usage:
java -jar grouperClient.jar --operation=deleteMemberWs [--groupName=a:b:c] [--groupUuid=abc123] [--groupIdIndex=12345] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--subjectIdsFile=fileName] [--subjectIdentifiersFile=fileName] [--subjectSourcesFile=fileName] [--defaultSubjectSource=subjectSourceId] [--fieldName=fieldNameToAdd] [--txType=NONE|READ_WRITE_NEW] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=deleteMemberWs --groupName=aStem:aGroup --subjectIds=12345,23456
output line: Index 0: success: T: code: SUCCESS: 12345
hasMemberWs web service usage:
java -jar grouperClient.jar --operation=hasMemberWs [--groupName=a:b:c] [--groupUuid=123abc] [--groupIdIndex=123456] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--subjectIdsFile=fileName] [--subjectIdentifiersFile=fileName] [--subjectSourcesFile=fileName] [--defaultSubjectSource=subjectSourceId] [--fieldName=fieldNameToAdd] [--memberFilter=GcMemberFilter] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--pointInTimeFrom=yyyy/mm/dd hh:mi:ss] [--pointInTimeTo=yyyy/mm/dd hh:mi:ss] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=hasMemberWs --groupName=aStem:aGroup --subjectIds=12345,23456
output line: Index 0: success: T: code: IS_MEMBER: 12345: true
getGroupsWs web service usage:
java -jar grouperClient.jar --operation=getGroupsWs [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--subjectIdsFile=fileName] [--subjectIdentifiersFile=fileName] [--subjectSourcesFile=fileName] [--defaultSubjectSource=subjectSourceId] [--memberFilter=GcMemberFilter] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--scope=some:folder:] [--stemName=stemNameToSearchIn] [--stemUuid=stemUuidToSearchIn] [--stemScope=ONE_LEVEL|ALL_IN_SUBTREE] [--enabled=A|T|F] [--pageSize=100] [--pageNumber=1] [--sortString=displayName] [--ascending=true|false] [--fieldName=members] [--pointInTimeFrom=yyyy/mm/dd hh:mi:ss] [--pointInTimeTo=yyyy/mm/dd hh:mi:ss] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getGroupsWs --subjectIds=12345,23456
output line: SubjectIndex 0: success: T: code: SUCCESS: subject: 12345: groupIndex: 0: aStem:aGroup2
groupSaveWs web service usage:
java -jar grouperClient.jar --operation=groupSaveWs --name=a:b:c [--includeGroupDetail=true] [--txType=NONE|READ_WRITE_NEW] [--saveMode=INSERT_OR_UPDATE|INSERT|UPDATE] [--groupLookupName=a:b:c] [--groupLookupUuid=sd87f-dsf87-sdf89-df78f] [--groupLookupIdIndex=12345] [--description=theDescription] [--displayExtension=theDisplayExtension] [--createParentStemsIfNotExist=true|false] [--typeOfGroup=group|role|entity] [--idIndex=12345] [--attributeName0=someName] [--attributeValue0=someValue] [--attributeNameX=xthName] [--attributeValueX=xthValue] [--compositeType=COMPLEMENT|INTERSECTION|UNION] [--leftGroupName=compositeLeft] [--rightGroupName=compositeRight] [--groupDetailParamName0=paramName] [--groupDetailParamValue0=paramValue] [--groupDetailParamNameX=xthName] [--groupDetailParamNameX=xthValue] [--typeNames=namesOfGroupTypes] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=groupSaveWs --name=aStem:aGroup
output: Success: T: code: SUCCESS_INSERTED: aStem:aGroup
stemSaveWs web service usage:
java -jar grouperClient.jar --operation=stemSaveWs --name=stemName [--txType=NONE|READ_WRITE_NEW] [--saveMode=INSERT_OR_UPDATE|INSERT|UPDATE] [--stemLookupName=theName] [--stemLookupUuid=theUuid] [--stemLookupidIndex=123456] [--description=theDescription] [--displayExtension=theDisplayExtension] [--createParentStemsIfNotExist=true|false] [-idIndex=123456] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=stemSaveWs --name=aStem:someStem
output: Success: T: code: SUCCESS_INSERTED: aStem:someStem
groupDeleteWs web service usage:
java -jar grouperClient.jar --operation=groupDeleteWs --groupNames=groupName0,groupName1 [--txType=NONE|READ_WRITE_NEW] [--includeGroupDetail=true|false] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=groupDeleteWs --groupNames=aStem:aGroup0,aStem:aGroup1
output line: Index 0: success: T: code: SUCCESS: aStem:aGroup0
stemDeleteWs web service usage:
java -jar grouperClient.jar --operation=stemDeleteWs --stemNames=a:b,a:c [--txType=NONE|READ_WRITE_NEW] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=stemDeleteWs --stemNames=aStem:aStem0,aStem:aStem1
output line: Index 0: success: T: code: SUCCESS: aStem:aStem0
getGrouperPrivilegesLiteWs web service usage
java -jar grouperClient.jar --operation=getGrouperPrivilegesLiteWs [--groupName=a:b:c] [--stemName=a:b] [--privilegeName=admin|view|read|optin|optout|update|stem|create|etc] [--privilegeType=access|naming|etc] [--subjectId=subjId0] [--subjectIdentifier=subjIdent0] [--subjectSource=source0] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getGrouperPrivilegesLiteWs --groupName=aStem:aGroup --subjectId=test.subject.0
output line: Index 0: success: T: code: SUCCESS: group: aStem:aGroup: subject: test.subject.0: access: admin
assignGrouperPrivilegesWs web service usage
java -jar grouperClient.jar --operation=assignGrouperPrivilegesWs --privilegeNames=admin|view|read|optin|optout|update|stem|create|etc (comma separated) --allowed=true|false [--groupName=a:b:c] [--stemName=a:b] [--privilegeType=access|naming|etc] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--txType=NONE|READ_WRITE_NEW] [--replaceAllExisting=true|false] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignGrouperPrivilegesWs --groupName=aStem:aGroup --subjectIds=test.subject.0,test.subject.1 --privilegeNames=admin,update --allowed=true
output: Index: 0, success: T, code: SUCCESS_ALLOWED, group: aStem:aGroup, subject: test.subject.0, access: admin
assignGrouperPrivilegesLiteWs web service usage
java -jar grouperClient.jar --operation=assignGrouperPrivilegesLiteWs --privilegeName=admin|view|read|optin|optout|update|stem|create|etc --allowed=true|false [--groupName=a:b:c] [--stemName=a:b] [--privilegeType=access|naming|etc] [--subjectId=subjId0] [--subjectIdentifier=subjIdent0] [--subjectSource=source0] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignGrouperPrivilegesLiteWs --groupName=aStem:aGroup --subjectId=test.subject.0 --privilegeName=admin --allowed=true
output: Success: T: code: SUCCESS_ALLOWED: group: aStem:aGroup: subject: test.subject.0: access: admin
findGroupsWs web service usage
java -jar grouperClient.jar --operation=findGroupsWs --queryFilterType=AND|MINUS|OR|FIND_BY_APPROXIMATE_ATTRIBUTE|FIND_BY_EXACT_ATTRIBUTE|FIND_BY_GROUP_NAME_APPROXIMATE|FIND_BY_GROUP_NAME_EXACT|FIND_BY_GROUP_UUID|FIND_BY_STEM_NAME|FIND_BY_TYPE|etc [--groupName=a:b:c] [--groupUuid=12as-1234gjth] [--groupNames=a:b,b:c] [--groupUuids=12ab,23cd] [--groupIdIndexes=12345,23456] [--stemName=aStem:someStem] [--stemUuid=sfds-sds234] [--stemNameScope=ONE_LEVEL|ALL_IN_SUBTREE] [--groupTypeName=someName] [--groupAttributeName=someName] [--groupAttributeValue=someValue] [--includeGroupDetail=true|false] [--sortString=T|F] [--ascending=T|F] [--pageNumber=2] [--pageSize=50] [--typeOfGroups=group,role,entity] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=findGroupsWs --queryFilterType=FIND_BY_GROUP_NAME_APPROXIMATE --groupName=aStem:aGroup
output: Index 0: name: aStem:aGroup, displayName: A stem:A Group
Note: to specify group math, use queryFilterType of AND|OR|MINUS, and then specify attribute for the left group with a 0 after attribute name, and 1 for the right group.
e.g.: java -jar grouperClient.jar --operation=findGroupsWs --queryFilterType=OR --queryFilterType0=OR --queryFilterType00=FIND_BY_GROUP_NAME_APPROXIMATE --groupName00=aStem:aGroup --queryFilterType01=FIND_BY_GROUP_NAME_APPROXIMATE --groupName01=aStem:aGroup --queryFilterType1=FIND_BY_GROUP_NAME_APPROXIMATE --groupName1=aStem:aGroup
Note: it is not clear which attributes go with which filter types, the rules are in the Java class: WsQueryFilterType
or use trial and error
findStemsWs web service usage
java -jar grouperClient.jar --operation=findStemsWs --stemQueryFilterType=AND|MINUS|OR|FIND_BY_APPROXIMATE_ATTRIBUTE|FIND_BY_PARENT_STEM_NAME|FIND_BY_STEM_NAME|FIND_BY_STEM_NAME_APPROXIMATE|FIND_BY_STEM_UUID|etc [--stemName=a:b:c] [--stemUuid=12as-1234gjth] [--stemNames=a:b,b:c] [--stemUuids=12ab,23cd] [--stemIdIndexes=12345,23456] [--parentStemName=aStem:someStem] [--parentStemNameScope=ONE_LEVEL|ALL_IN_SUBTREE] [--stemAttributeName=someName] [--stemAttributeValue=someValue] [--sortString=T|F] [--ascending=T|F] [--pageNumber=2] [--pageSize=50] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=findGroupsWs --stemQueryFilterType=FIND_BY_STEM_NAME_APPROXIMATE --stemName=aStem:aGroup
output: Index 0: name: aStem:aStem0, displayName: A stem:A Stem 0
Note: to specify group math, use stemQueryFilterType of AND|OR|MINUS, and then specify attribute for the left stem with a 0 after attribute name, and 1 for the right stem.
e.g.: java -jar grouperClient.jar --operation=findStemsWs --stemQueryFilterType=OR --stemQueryFilterType0=OR --stemQueryFilterType00=FIND_BY_STEM_NAME --stemName00=aStem --stemQueryFilterType01=FIND_BY_STEM_NAME --stemName01=aStem --stemQueryFilterType1=FIND_BY_STEM_NAME --stemName1=aStem
Note: it is not clear which attributes go with which filter types, the rules are in the Java class: WsStemQueryFilterType
or use trial and error
memberChangeSubjectWs web service usage (note: you need to be in the sysAdminGroup or actAs someone who is)
java -jar grouperClient.jar --operation=memberChangeSubjectWs [--oldSubjectId=oldId] [--oldSubjectIdentifier=oldIdent] [--oldSubjectSource=oldSourceId] [--newSubjectId=newId] [--newSubjectIdentifier=newIdent] [--newSubjectSource=newSourceId] [--deleteOldMember=false] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=memberChangeSubjectWs --oldSubjectId=test.subject.0 --newSubjectId=test.subject.1 --actAsSubjectId=GrouperSystem
output: Success: T: code: SUCCESS: oldSubject: test.subject.0, newSubject: test.subject.1
getMembershipsWs web service usage:
java -jar grouperClient.jar --operation=getMembershipsWs [--groupNames=a:b:c,a:b:d] [--groupUuids=1234,abcd] [--groupIdIndexes=12345,23456] [--ownerStemNames=a:b:c,a:b:d] [--ownerStemUuids=1234,abcd] [--ownerNamesOfAttributeDefs=a:b:c,a:b:d] [--ownerIdsOfAttributeDefs=1234,abcd] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--fieldName=fieldNameToAdd] [--fieldType=list|access|naming|attributeDef] [--memberFilter=All|Immediate|NonImmediate|Effective|Composite] [--sourceIds=sourceId1,sourceId2] [--membershipIds=abc,bcd] [--scope=school:folder:somewhere] [--stemName=a:b:c] [--stemUuid=abc] [--stemIdIndex=12345] [--stemScope=ONE_LEVEL|ALL_IN_SUBTREE] [--enabled=A|T|F] [--serviceRole=admin|user] [--serviceId=abc123] [--serviceName=a:b:c] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--pageSize=100] [--pageNumber=1] [--sortString=displayName] [--ascending=true|false] [--pageSizeForMember=100] [--pageNumberForMember=1] [--sortStringForMember=displayName] [--ascendingForMember=true|false] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getMembershipsWs --groupNames=aStem:aGroup,aStem:aGroup2
output line: Index 0: group: aStem:aGroup, subject: 12345, list: members, type: Immediate, enabled: T
Note: subjectSources are the sources for the subjects specified. sourceIds are if you arent specifying subjectIds, and you just want all person memberships for example.
getSubjectsWs web service usage:
java -jar grouperClient.jar --operation=getSubjectsWs [--searchString=someone] [--subjectIds=subjId0,subjId1] [--subjectIdentifiers=subjIdent0,subjIdent1] [--subjectSources=source0,source1] [--fieldName=fieldNameToAdd] [--memberFilter=All|Immediate|NonImmediate|Effective|Composite] [--sourceIds=sourceId1,sourceId2] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--groupName=a:b:c] [--groupUuid=1234] [--groupIdIndex=12345] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getSubjectsWs --subjectIds=subjId0,subjId1
output line: Index 0: success: T, code: SUCCESS, subject: 12345
Note: subjectSources are the sources for the subjects specified. sourceIds are if you arent specifying subjectIds, and you want to filter the searchString
getAttributeAssignmentsWs web service usage:
java -jar grouperClient.jar --operation=getAttributeAssignmentsWs --attributeAssignType=group|member|stem|any_mem|imm_mem|attr_def|any_mem_asgn|attr_def_asgn|group_asgn|imm_mem_asgn|mem_asgn|stem_asgn [--includeAssignmentsOnAssignments=true|false] [--attributeDefNames=a:b,b:c] [--attributeDefUuids=1a,2b] [--attributeDefIdndexes=12345,23456] [--attributeDefNameNames=a:b,b:c] [--attributeDefNameUuids=1a,2b] [--attributeDefNameIdIndexes=12345,23456] [--ownerAttributeDefNames=a:b,b:c] [--ownerAttributeDefUuids=1a,2b] [--ownerAttributeDefIdIndexes=12345] [--ownerGroupNames=a:b:c,a:b:d] [--ownerGroupUuids=1234,abcd] [--ownerGroupIdIndexes=12345] [--owner0SubjectId=subjId0] [--owner0SubjectIdentifier=subjIdent0] [--owner0SubjectSource=source0] [--ownerMembershipUuids=abc,bcd] [--ownerStemNames=a:b,b:c] [--ownerStemUuids=1a,2b] [--ownerStemIdIndexes] [--ownerMembershipAny0SubjectId=12] [--ownerMembershipAny0SubjectIdentifier=ab] [--ownerMembershipAny0SubjectSource=xyz] [--ownerMembershipAny0GroupName=3c] [--ownerMembershipAny0GroupUuid=1a] [--ownerMembershipAny0GroupIdIndex=12345] [--attributeAssignUuids=a1,b2] [--attributeDefValueType=floating|integer|memberId|string|timestamp] [--theValue=123] [--includeAssignmentsFromAssignments=T|F] [--attributeDefType==attr|domain|type|limit|perm] [--assignAssignOwnerAttributeAssignUuids=a1,b2] [--assignAssignOwnerNamesOfAttributeDefs=a:b,b:c] [--assignAssignOwnerUuidsOfAttributeDefs=1a,2b] [--assignAssignOwnerNamesOfAttributeDefNames=a:b,b:c] [--assignAssignOwnerUuidsOfAttributeDefNames=1a,2b] [--assignAssignOwnerActions=read] [--enabled=A|T|F] [--actions=read,write] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getAttributeAssignmentsWs --attributeAssignType=group --attributeDefNames=test:testAttributeAssignDefNameDef
output line: Index: 0: attributeAssignType: group, owner: test:groupTestAttrAssign, attributeDefNameName: test:testAttributeAssignDefName, action: assign, values: 15,5,5, enabled: T, id: a9c83eeb78c04ae5befcea36272d318c
assignAttributesWs web service usage:
java -jar grouperClient.jar --operation=assignAttributesWs --attributeAssignType=group|member|stem|any_mem|imm_mem|attr_def|group_asgn|mem_asgn|stem_asgn|any_mem_asgn|imm_mem_asgn|attr_def_asgn --attributeAssignOperation=assign_attr|add_attr|remove_attr|replace_attrs [--attributeDefNameNames=a:b,b:c] [--attributeDefNameUuids=1a,2b] [--attributeDefNameIdIndexes=12] [--ownerAttributeDefNames=a:b,b:c] [--ownerAttributeDefUuids=1a,2b] [--ownerAttributeDefIdIndexs=123] [--ownerGroupNames=a:b:c,a:b:d] [--ownerGroupUuids=1234,abcd] [--ownerGroupIdIndexes=123] [--owner0SubjectId=subjId0] [--owner0SubjectIdentifier=subjIdent0] [--owner0SubjectSource=source0] [--ownerMembershipUuids=abc,bcd] [--ownerStemNames=a:b,b:c] [--ownerStemUuids=1a,2b] [--ownerStemIdIndexes=1234] [--ownerMembershipAny0SubjectId=12] [--ownerMembershipAny0SubjectIdentifier=ab] [--ownerMembershipAny0SubjectSource=xyz] [--ownerMembershipAny0GroupName=3c] [--ownerMembershipAny0GroupUuid=1a] [--ownerMembershipAny0GroupIdIndex=12] [--ownerAttributeAssignUuids=a1,b2] [--attributeAssignValueOperation=assign_value|add_value|remove_value|replace_values] [--values0Id=a1] [--values0Formatted=hey] [--values0System=there] [--attributeAssignUuids=a:b,b:c] [--actions=read,write] [--assignmentDisabledTime=2010/03/05_17:05:13.123] [--assignmentEnabledTime=2010/03/05_17:05:13.123] [--assignmentNotes=someNotes] [--delegatable=TRUE|FALSE|GRANT] [--attributeDefNamesToReplace=a:b,b:c] [--attributeDefUuidsToReplace=1a,2b] [--actionsToReplace=read,write] [--attributeDefTypesToReplace=attr,perm,limit,domain,type] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignAttributesWs --attributeAssignType=group --attributeAssignOperation=assign_attr --attributeDefNameNames=test:testAttributeAssignDefNameDef --ownerGroupNames=a:b:c
output line: Index: 0: attributeAssignType: group, owner: test:groupTestAttrAssign, attributeDefNameName: test:testAttributeAssignDefName, action: assign, values: 15,5,5, enabled: T, id: a9c83eeb78c04ae5befcea36272d318c, changed: T, deleted: F, valuesChanged: F
assignAttributesBatchWs web service usage (X is the assignment entry starting from and incrementing from 0):
java -jar grouperClient.jar --operation=assignAttributesBatchWs --entry_X_attributeAssignType=group|member|stem|any_mem|imm_mem|attr_def|group_asgn|mem_asgn|stem_asgn|any_mem_asgn|imm_mem_asgn|attr_def_asgn --entry_X_attributeAssignOperation=assign_attr|add_attr|remove_attr [--entry_X_nameOfAttributeDefName=a:b] [--entry_X_uuidOfAttributeDefName=1a] [--entry_X_idIndexOfAttributeDefName=1a] [--entry_X_ownerNameOfAttributeDef=a:b] [--entry_X_ownerUuidOfAttributeDef=1a] [--entry_X_ownerIdIndexOfAttributeDef=1a] [--entry_X_ownerGroupName=a:b:c] [--entry_X_ownerGroupUuid=1234] [--entry_X_ownerGroupIdIndex=1234] [--entry_X_ownerSubjectId=subjId0] [--entry_X_ownerSubjectIdentifier=subjIdent0] [--entry_X_ownerSubjectSource=source0] [--entry_X_ownerMembershipUuid=abc] [--entry_X_ownerStemName=a:b] [--entry_X_ownerStemUuid=1a] [--entry_X_ownerStemIdIndex=1a] [--entry_X_ownerMembershipAnySubjectId=12] [--entry_X_ownerMembershipAnySubjectIdentifier=ab] [--entry_X_ownerMembershipAnySubjectSource=xyz] [--entry_X_ownerMembershipAnyGroupName=a:b:c] [--entry_X_ownerMembershipAnyGroupUuid=1a] [--entry_X_ownerMembershipAnyGroupIdIndex=12] [--entry_X_ownerAttributeAssignUuid=a1] [--entry_X_ownerAttributeAssignBatchIndex=0] [--entry_X_attributeAssignValueOperation=assign_value|add_value|remove_value|replace_values] [--entry_X_values0Id=a1] [--entry_X_values0Formatted=hey] [--entry_X_values0System=there] [--entry_X_attributeAssignUuid=a:b] [--entry_X_action=read] [--entry_X_assignmentDisabledTime=2010/03/05_17:05:13.123] [--entry_X_assignmentEnabledTime=2010/03/05_17:05:13.123] [--entry_X_assignmentNotes=someNotes] [--entry_X_delegatable=TRUE|FALSE|GRANT] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignAttributesBatchWs --entry_0_attributeAssignType=group --entry_0_attributeAssignOperation=assign_attr --entry_0_nameOfAttributeDefName=test:testAttributeAssignDefNameDef --entry_0_ownerGroupName=a:b:c --entry_1_attributeAssignType=group --entry_1_attributeAssignOperation=assign_attr --entry_1_nameOfAttributeDefName=test:testAttributeAssignDefNameDef2 --entry_1_ownerGroupName=a:b:c
output line: Index: 0, result: 0: attributeAssignType: group, owner: test:groupTestAttrAssign, attributeDefNameName: test:testAttributeAssignDefName, action: assign, values: 15,5,5, enabled: T, id: a9c83eeb78c04ae5befcea36272d318c, changed: T, deleted: F, valuesChanged: F
getPermissionAssignmentsWs web service usage:
java -jar grouperClient.jar --operation=getPermissionAssignmentsWs [--includeAttributeAssignments=true|false] [--includeAssignmentsOnAssignments=true|false] [--includeAttributeDefNames=true|false] [--includePermissionAssignDetail=true|false] [--attributeDefNames=a:b,b:c] [--attributeDefUuids=1a,2b] [--attributeDefIdIndexes=12] [--attributeDefNameNames=a:b,b:c] [--attributeDefNameUuids=1a,2b] [--attributeDefNameIdIndexes=12] [--roleNames=a:b:c,a:b:d] [--roleUuids=1234,abcd] [--roleIdIndexes=1234] [--subject0SubjectId=subjId0] [--subject0SubjectIdentifier=subjIdent0] [--subject0SubjectSource=source0] [--enabled=A|T|F] [--actions=read,write] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--pointInTimeFrom=yyyy/mm/dd hh:mi:ss] [--pointInTimeTo=yyyy/mm/dd hh:mi:ss] [--immediateOnly=T|F] [--permissionType=role_subject|role] [--permissionProcessor=FILTER_REDUNDANT_PERMISSIONS|FILTER_REDUNDANT_PERMISSIONS_AND_PROCESS_LIMITS|FILTER_REDUNDANT_PERMISSIONS_AND_ROLES|FILTER_REDUNDANT_PERMISSIONS_AND_ROLES_AND_PROCESS_LIMITS|PROCESS_LIMITS] [--limitEnvVarName0=name0] [--limitEnvVarValue0=value0] [--limitEnvVarType0=integer|decimal|date|timestamp|text|boolean|null|emptyString] [--limitEnvVarNameX=xthName] [--limitEnvVarValueX=xthValue] [--limitEnvVarTypeX=xthType] [--includeLimits=T|F] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=getPermissionAssignmentsWs --permissionType=role_subject --attributeDefNames=test:testAttributeAssignDefNameDef
output line: Index: 0: permissionType: role_subject, role: test:someRole, subject: 123456, attributeDefNameName: test:testPermission, action: assign, allowedOverall: T, enabled: T
assignPermissionsWs web service usage:
java -jar grouperClient.jar --operation=assignPermissionsWs --permissionType=role|role_subject --permissionAssignOperation=assign_permission|remove_permission|replace_permissions [--permissionDefNameNames=a:b,b:c] [-permissionDefNameUuids=1a,2b] [-permissionDefNameIdIndexes=12] [--roleNames=a:b:c,a:b:d] [--roleUuids=1234,abcd] [--roleIdIndexes=1234] [--subjectRole0SubjectId=12] [--subjectRole0SubjectIdentifier=ab] [--subjectRole0SourceId=xyz] [--subjectRole0RoleName=3c] [--subjectRole0RoleUuid=1a] [--attributeAssignUuids=a:b,b:c] [--actions=read,write] [--disallowed=true|false] [--assignmentDisabledTime=2010/03/05_17:05:13.123] [--assignmentEnabledTime=2010/03/05_17:05:13.123] [--assignmentNotes=someNotes] [--delegatable=TRUE|FALSE|GRANT] [--includeGroupDetail=true|false] [--includeSubjectDetail=true|false] [--subjectAttributeNames=name0,name1] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--attributeDefNamesToReplace=a:b,b:c] [--attributeDefUuidsToReplace=1a,2b] [--actionsToReplace=read,write] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignPermissionsWs --permissionType=role --permissionAssignOperation=assign_permission --permissionDefNameNames=test:testAttributeAssignDefNameDef --roleNames=a:b:c
output line: Index: 0: permissionType: role, owner: a:b:c, permissionDefNameName: test:testAttributeAssignDefName, action: assign, disallowed: T, enabled: T, attributeAssignId: a9c83eeb78c04ae5befcea36272d318c, changed: T, deleted: F
attributeDefNameSaveWs web service usage:
java -jar grouperClient.jar --operation=attributeDefNameSaveWs --name=a:b:c [--saveMode=INSERT_OR_UPDATE|INSERT|UPDATE] [--attributeDefNameLookupName=a:b:c] [--attributeDefNameLookupUuid=sd87f-dsf87-sdf89-df78f] [--attributeDefNameLookupIdIndex=1234] [--description=theDescription] [--displayExtension=theDisplayExtension] [--idIndex=1234] [--createParentStemsIfNotExist=true|false] [--uuidOfAttributeDef=sd87f-dsf87-sdf89-df78f] [--nameOfAttributeDef=a:b:c] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=attributeDefNameSave --name=aStem:aGroup
output: Success: T: code: SUCCESS_INSERTED: aStem:aGroup
attributeDefNameDeleteWs web service usage:
java -jar grouperClient.jar --operation=attributeDefNameDeleteWs --attributeDefNameNames=attributeDefNameName0,attributeDefNameName1 [--txType=NONE|READ_WRITE_NEW] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=attributeDefNameDelete --attributeDefNameNames=aStem:anAttributeDefName0,aStem:anAttributeDefName1
output line: Index 0: success: T: code: SUCCESS: aStem:anAttributeDefName0
assignAttributeDefNameInheritanceWs web service usage:
java -jar grouperClient.jar --operation=assignAttributeDefNameInheritanceWs --attributeDefNameName=attributeDefNameName0 --relatedAttributeDefNameNames=relatedName0,relatedName1 --assign=T|F [--replaceAllExisting=T|F] [--txType=NONE|READ_WRITE_NEW] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=assignAttributeDefNameInheritanceWs --attributeDefNameName=aStem:anAttributeDefName0 --relatedAttributeDefNameNames=aStem:anAttributeDefName1 --assign=T
output line: code: SUCCESS, message: Had 1 successful adds, 0 adds which already existed, 0 successful removes, and 0 removes which didnt exist.
findAttributeDefNamesWs web service usage
java -jar grouperClient.jar --operation=findAttributeDefNamesWs [--scope=some:scopeOrTerms] [--splitScope=T|F] [--attributeDefNameNames=a:b,b:c] [--attributeDefNameUuids=12ab,23cd] [--attributeDefNameIdIndexes=12] [--nameOfAttributeDef=a:b:c] [--uuidOfAttributeDef=12fg-34fg] [--idIndexOfAttributeDef=12] [--attributeAssignType=any_mem|any_mem_asgn|attr_def|attr_def_asgn|group|group_asgn|imm_mem|imm_mem_asgn|mem_asgn|member|stem|stem_asgn] [--attributeDefType=attr|domain|limit|perm|type] [--inheritanceSetRelation=IMPLIED_BY_THIS|IMPLIED_BY_THIS_IMMEDIATE|THAT_IMPLY_THIS|THAT_IMPLY_THIS_IMMEDIATE] [--serviceRole=admin|user] [--subjectId=1234] [--subjectIdentifier=jsmith] [--subjectSource=sourceId] [--sortString=name|displayName|extension|displayExtension] [--ascending=T|F] [--pageNumber=2] [--pageSize=50] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=findAttributeDefNamesWs --scope=aStem:
output: Index 0: name: aStem:anAttributeDefName, displayName: A stem:An AttributeDefName
findExternalSubjectsWs web service usage
java -jar grouperClient.jar --operation=findExternalSubjectsWs [[email protected]] [[email protected],[email protected]] [--sortString=T|F] [--ascending=T|F] [--pageNumber=2] [--pageSize=50] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=findGroupsWs --queryFilterType=FIND_BY_GROUP_NAME_APPROXIMATE --groupName=aStem:aGroup
output: Index 0: identifier: [email protected], name: John Smith
externalSubjectSaveWs web service usage:
java -jar grouperClient.jar --operation=externalSubjectSaveWs [email protected] --name="John Smith" [--institution="Some School"] [--enabled=T] [[email protected]] [[email protected]] [--txType=NONE|READ_WRITE_NEW] [--saveMode=INSERT_OR_UPDATE|INSERT|UPDATE] [--attributeName0=someName] [--attributeValue0=someValue] [--attributeNameX=xthName] [--attributeValueX=xthValue] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=externalSubjectSaveWs [email protected] --name="John Smith"
output: Success: T: code: SUCCESS_INSERTED: [email protected]: John Smith
externalSubjectDeleteWs web service usage:
java -jar grouperClient.jar --operation=externalSubjectDeleteWs [[email protected]] [[email protected],[email protected]] [--txType=NONE|READ_WRITE_NEW] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--saveResultsToFile=fileName] [--outputTemplate=somePattern] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source]
e.g.: java -jar grouperClient.jar --operation=externalSubjectDeleteWs [email protected]
output line: Index 0: success: T: code: SUCCESS: [email protected]: John Smith
sendMessageWs web service usage:
java -jar grouperClient.jar --operation=sendMessageWs --messageBody0=someMessage --queueOrTopicName=myQueue [--queueType=queue|topic] [--routingKey=someKey] [--messageSystemName=rabbitmq] [--messageBody1..n=anotherMessage] [--autocreateObjects=T|F] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId]
e.g.: java -jar grouperClient.jar --operation=sendMessageWs --messageBody0=someMessage --queueOrTopicName=myQueue
output line: Success: T, queueOrTopicName: test_queue, numberOfMessages: 2
receiveMessageWs web service usage:
java -jar grouperClient.jar --operation=receiveMessageWs --queueOrTopicName=myQueue [--maxMessagesToReceiveAtOnce=20] [--blockMillis=20000] [--routingKey=someKey] [--messageSystemName=rabbitmq] [--autocreateObjects=T|F] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId]
e.g.: java -jar grouperClient.jar --operation=receiveMessageWs --queueOrTopicName=myQueue
output line: Index 0: success: T, queueOrTopicName: test_queue, messageBody: message body
acknowledgeMessageWs web service usage:
java -jar grouperClient.jar --operation=acknowledgeMessageWs --queueOrTopicName=myQueue --messageIds=abc,bcd,def --acknowledgeType=mark_as_processed|return_to_queue|return_to_end_of_queue|send_to_another_queue [--anotherQueueOrTopicName=abc] [--anotherQueueType=queue|topic] [--messageSystemName=rabbitmq] [--actAsSubjectId=subjId] [--actAsSubjectIdentifier=subjIdent] [--actAsSubjectSource=source] [--paramName0=name0] [--paramValue0=value1] [--paramNameX=xthParamName] [--paramValueX=xthParamValue] [--debug=true] [--clientVersion=someVersion] [--grouperActAsSubjectId=subjId] [--grouperActAsSubjectIdentifier=subjIdent] [--grouperActAsSubjectSource=source] [--xRequestId=someRequestId] [--xCorrelationId=someCorrelationId]
e.g.: java -jar grouperClient.jar --operation=acknowledgeMessageWs --messageIds=abc --queueOrTopicName=myQueue --acknowledgeType=mark_as_processed
output line: Success: T, queueOrTopicName: test_queue, numberOfMessages: 1
###############################################
Common options:
--outputTemplate=${index}: ${wsGroup.name}
the output template allow the caller to customize what is displayed in the output from the XML
anything in ${} will be evaluated, and there are different variables available for various operations.
if you pass in --debug=true, it will tell you the xml and the variables you can use. You can drill down
in the variables, e.g. ${wsGroupDeleteResult.wsGroup.name}, you can do operations, e.g. ${index+1},
you can do simple string utilities from GrouperClientUtils or GrouperClientCommonUtils, e.g.
${grouperClientUtils.trimToEmpty(wsGroup.name)}
--debug=true
this will display debug information including the request and response to stderr
--saveResultsToFile=/tmp/somefile.txt
you can save the stdout to a file if you like
--actAsSubjectId=subjId --actAsSubjectIdentifier=subjIdent --actAsSubjectSource=source
if you want to run the operation as a different user than the user who is authenticating
to the web service, then specify the actAsSubjectId or actAsSubjectIdentifier (and optionally
the actAsSubjectSource). You would do this e.g. to run a command as admin, or as a user who
is using the end layer application. Note you need permissions to do this in grouper.
--paramName0=name0 --paramValue0=value1 --paramNameX=xthParamName --paramValueX=xthParamValue
you can specify params in name/value pairs if the operation supports it (see grouper
web service documentation for details)
--clientVersion=someVersion
generally this does not need to be changed. This is the version label sent to the web service
which might affect the output from the web service. Not it does not affect the request to the
web service (besides the label), it only affect the response from the web service.
--txType=GcTransactionType
affects how batched operations are executed on the server (e.g. adding multiple subjects to a group)
generally the only values which make sense are to use a large transaction or not: READ_WRITE_NEW, NONE
--includeGroupDetail=true
if applicable, this option will return not only the group's name, but more information such as the
attribuites, types, composite members, etc.
--subjectAttributeNames=a,b,c
if applicable, subjects will be returned from the server with these attributes in a string array
--grouperActAsSubjectId=subjId
--grouperActAsSubjectIdentifier=subjIdent
--grouperActAsSubjectSource=source
grouper top layer act as built for messaging to WS bridge
--wsEndpoint=https://server.school.edu/grouper-ws/servicesRest
--wsUser=myUserToWs
--wsPass=xyz123
--wsPassEncrypted=jg874mg85mg8
--wsPassFile=/some/file
--wsPassFileEncrypted=/some/fileWithEncryptedPassInside
--xRequestId=someRequestId
--xCorrelationId=someCorrelationId