replaceGroups


Method description



A method to complety replace all properties of one or more groups. Can also be used to create groups.

Preconditions for use

You will need to know the syncID of the parent hierarchy where you want to update/add the group in itslearning.

Message Schema

Input parameters / request message elements

Name

Description

Data type

Allowed values

M/O

groupIdPairSet

Wrapper for a list of groupIdPair elements




groupIdPair

Wrapper for a set of one <sourcedid><identifier and one <group> element




<sourcedId ><identifier>

The syncID of the group to be replace.

Text

Max 64 chars

M

<group>

The full group date to replace with. Refer to GroupManagement service and the group object for details

Object

Valid group object

M

Please refer to the WSDL for the full element structure, only key elements are described here

Response message elements


Name

Description

Data type

replaceGroupsResponse

Empty createGroupResponse element

Empty



For each <identifier> in the request you will get a status in the <statusinfoSet><status> in the response. The order of the <statusInfoset><status> corresponds to the the order of the <identifier> in the request.


Comments


If the syncID to update does not exist, itslearning will try to create it. Depending on the data provided, there may or may not be enough data to successfully create the group.

Example

Description

See createGroupsRequest

Example request message

Identical to createGroups request, just different method name:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ims="http://www.imsglobal.org/services/gms/xsd/imsGroupManMessSchema_v1p0" xmlns:ims1="http://www.imsglobal.org/services/common/imsCommonSchema_v1p0" xmlns:ims2="http://www.imsglobal.org/services/gms/xsd/imsGroupManDataSchema_v1p0" xmlns:ims3="http://www.imsglobal.org/services/common/imsMessBindSchema_v1p0">
<soapenv:Header>
<ims3:syncRequestHeaderInfo>
<ims3:messageIdentifier>1234567890</ims3:messageIdentifier>
</ims3:syncRequestHeaderInfo>
</soapenv:Header>
<soapenv:Body>
<ims:replaceGroupsRequest>
<ims:groupIdPairSet>
<ims:groupIdPair>
<ims:sourcedId>
<ims1:identifier>HHH</ims1:identifier>
</ims:sourcedId>
<ims:group>
<ims2:groupType>
<ims2:scheme>ItslearningOrganisationTypes</ims2:scheme>
<ims2:typeValue>
<ims2:type>Unspecified</ims2:type>
<ims2:level>-1</ims2:level>
</ims2:typeValue>
</ims2:groupType>
<ims2:relationship>
<ims2:relation>Parent</ims2:relation>
<ims2:sourceId>
<ims1:identifier>root</ims1:identifier>
</ims2:sourceId>
</ims2:relationship>
<ims2:description>
<ims2:descShort>School AB</ims2:descShort>
</ims2:description>
</ims:group>
</ims:groupIdPair>
<ims:groupIdPair>
<ims:sourcedId>
<ims1:identifier>III</ims1:identifier>
</ims:sourcedId>
<ims:group>
<ims2:groupType>
<ims2:scheme>ItslearningOrganisationTypes</ims2:scheme>
<ims2:typeValue>
<ims2:type>Unspecified</ims2:type>
<ims2:level>-1</ims2:level>
</ims2:typeValue>
</ims2:groupType>
<ims2:relationship>
<ims2:relation>Parent</ims2:relation>
<ims2:sourceId>
<ims1:identifier>HHH</ims1:identifier>
</ims2:sourceId>
</ims2:relationship>
<ims2:description>
<ims2:descShort>Course group</ims2:descShort>
</ims2:description>
<ims2:extension>
<ims1:extensionField>
<ims1:fieldName>course</ims1:fieldName>
<ims1:fieldType>String</ims1:fieldType>
<ims1:fieldValue>History</ims1:fieldValue>
</ims1:extensionField>
<ims1:extensionField>
<ims1:fieldName>course/code</ims1:fieldName>
<ims1:fieldType>String</ims1:fieldType>
<ims1:fieldValue>HIS-01</ims1:fieldValue>
</ims1:extensionField>
</ims2:extension>
</ims:group>
</ims:groupIdPair>
</ims:groupIdPairSet>
</ims:replaceGroupsRequest>
</soapenv:Body>
</soapenv:Envelope>


Example response message

Identical to createGroups response, just different method name

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope ">
<s:Header>
<h:syncResponseHeaderInfo>
<messageIdentifier>1234567890</messageIdentifier>
<statusInfoSet>
<statusInfo>
<codeMajor>success</codeMajor>
<severity>status</severity>
<messageIdRef>1234567890</messageIdRef>
</statusInfo>
<statusInfo>
<codeMajor>success</codeMajor>
<severity>status</severity>
<messageIdRef>1234567890</messageIdRef>
</statusInfo>
</statusInfoSet>
</h:syncResponseHeaderInfo>
<o:Security s:mustUnderstand="1" >
<u:Timestamp u:Id="_0">
<u:Created>2011-02-03T13:39:39.352Z</u:Created>
<u:Expires>2011-02-03T13:44:39.352Z</u:Expires>
</u:Timestamp>
</o:Security>
</s:Header>
<s:Body >
<replaceGroupsResponse />
</s:Body>
</s:Envelope>