Get organization
This service searches for an organization by unique ID, or by distinguished name (DN).
Request
Request BOD GetOrganization Access profile Search criteria:
- Find by Unique ID: {_wcf.ap=$accessProfile$}/Organization[OrganizationIdentifier[(UniqueID='$organizationId$')]]
- Find by Distinguished Name: {_wcf.ap=$accessProfile$}/Organization[OrganizationIdentifier[(DistinguishedName='$distinguishedName$')]]
where $accessProfile$ is the access profile being used, for example, IBM_Summary.
The following access profiles, specified as part of the request, specify how much information is returned in the response BOD::
- IBM_Summary: Populates the organization with the following summary information:
- /Organization/OrganizationIdentifier
- /Organization/OrganizationName
- /Organization/ParentOrganizationIdentifier
- /Organization/@type
- /Organizaiton/@status
- /Organization/ContactInfo/ContactInfoIdentifier
- /Organization/ContactInfo/ContactName
- IBM_Details: Populates the organization with the IBM_Summary information and then adds the remainder of the /Organization/ContactInfo information.
- IBM_All: Populates the organization with the IBM_Details information and then adds all of the remaining information about the organization.
Schema /xsd/OAGIS/9.0/Overlays/IBM/Commerce/BODs/GetOrganization.xsd Service data object com.ibm.commerce.member.facade.datatypes.GetOrganizationType
Sample GetOrganization Request BOD
This sample request BOD searches for organization by unique ID.
<?xml version="1.0" encoding="UTF-8"?> <_mbr:GetOrganization xmlns:_mbr="http://www.ibm.com/xmlns/prod/commerce/9/member" xmlns:_wcf="http://www.ibm.com/xmlns/prod/commerce/9/foundation" xmlns:oa="http://www.openapplications.org/oagis/9" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <oa:ApplicationArea xsi:type="_wcf:ApplicationAreaType"> <oa:CreationDateTime>2006-12-20T09:51:52.422Z</oa:CreationDateTime> <oa:BODID>a0a33df0-9039-11db-ab11-832f45894e08</oa:BODID> <_wcf:BusinessContext/> </oa:ApplicationArea> <_mbr:DataArea> <oa:Get> <oa:Expression expressionLanguage="wcf:XPath">{_wcf.ap=ALL}/Organization[OrganizationIdentifier[(UniqueId='-2000')]] </oa:Expression> </oa:Get> </_mbr:DataArea> </_mbr:GetOrganization>
Response
Response BOD ShowOrganization. Schema /xsd/OAGIS/9.0/Overlays/IBM/Commerce/BODs/ShowOrganization.xsd Service data object com.ibm.commerce.member.facade.datatypes.ShowOrganizationType Response
- Search for organization by Unique Id
- OrganizationIdentifier
- ParentOrganizationIdentifier
- OrganizationName
- ContactInfo/ContactInfoIdentifier
- ContactInfo/ContactName
- Search for organization by Distinguished Name (DN)
- Summary information and complete ContactInfo
Sample ShowOrganization Response BOD
This response BOD shows:
<?xml version="1.0" encoding="UTF-8"?> <_mbr:ShowOrganization xmlns:Oagis9="http://www.openapplications.org/oagis/9" xmlns:_mbr="http://www.ibm.com/xmlns/prod/commerce/9/member" xmlns:_wcf="http://www.ibm.com/xmlns/prod/commerce/9/foundation"> <_mbr:DataArea> <Oagis9:Show/> <_mbr:Organization registrationApprovalStatus="" status="" type="Organization" xmlns:_mbr="http://www.ibm.com/xmlns/prod/commerce/9/member" xmlns:_wcf="http://www.ibm.com/xmlns/prod/commerce/9/foundation" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ibm.com/xmlns/prod/commerce/9/member OAGIS/9.0/Overlays/IBM/Commerce/Resources/Nouns/Organization.xsd http://www.ibm.com/xmlns/prod/commerce/9/foundation ../Components/CommonTypes.xsd "> <_mbr:OrganizationIdentifier > <_wcf:UniqueID>-2000</_wcf:UniqueID> <_wcf:DistinguishedName>o=default organization,o=root organization</_wcf:DistinguishedName> </_mbr:OrganizationIdentifier> <_mbr:ParentOrganizationIdentifier > <_wcf:UniqueID>-2001</_wcf:UniqueID> <_wcf:DistinguishedName> o=root organization </_wcf:DistinguishedName> </_mbr:ParentOrganizationIdentifier> <_mbr:OrganizationName>Default Organization</_mbr:OrganizationName> <_mbr:BusinessCategory>_mbr:BusinessCategory</_mbr:BusinessCategory> <_mbr:Description language="">_mbr:Description</_mbr:Description> <_mbr:LegalIdentifier>_mbr:LegalIdentifier</_mbr:LegalIdentifier> <_mbr:ContactInfo > <_wcf:ContactInfoIdentifier > <_wcf:UniqueID>1000</_wcf:UniqueID> <_wcf:ExternalIdentifier > <_wcf:ContactInfoNickName>default organization</_wcf:ContactInfoNickName> <_wcf:PersonIdentifier > <_wcf:UniqueID>-2000 </_wcf:UniqueID> <_wcf:DistinguishedName> o=default organization,o=root organization </_wcf:DistinguishedName> </_wcf:PersonIdentifier> </_wcf:ExternalIdentifier> </_wcf:ContactInfoIdentifier> <_wcf:ContactName > <_wcf:PersonTitle>_wcf:PersonTitle</_wcf:PersonTitle> <_wcf:BusinessTitle>_wcf:BusinessTitle</_wcf:BusinessTitle> <_wcf:LastName>_wcf:LastName</_wcf:LastName> <_wcf:FirstName>_wcf:FirstName</_wcf:FirstName> <_wcf:MiddleName>_wcf:MiddleName</_wcf:MiddleName> </_wcf:ContactName> <_wcf:Address primary="true" type="" > <_wcf:AddressLine>_wcf:AddressLine</_wcf:AddressLine> <_wcf:City>_wcf:City</_wcf:City> <_wcf:StateOrProvinceName>_wcf:StateOrProvinceName</_wcf:StateOrProvinceName> <_wcf:Country>_wcf:Country</_wcf:Country> <_wcf:PostalCode>_wcf:PostalCode</_wcf:PostalCode> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:Address> <_wcf:Telephone1 publish="true" type="" > <_wcf:Value>_wcf:Value</_wcf:Value> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:Telephone1> <_wcf:OrganizationName>_wcf:OrganizationName</_wcf:OrganizationName> <_wcf:OrganizationUnitName>_wcf:OrganizationUnitName</_wcf:OrganizationUnitName> <_wcf:GeographicalShippingCode>_wcf:GeographicalShippingCode</_wcf:GeographicalShippingCode> <_wcf:GeographicalTaxCode>_wcf:GeographicalTaxCode</_wcf:GeographicalTaxCode> <_wcf:Attributes name="">_wcf:Attributes</_wcf:Attributes> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_mbr:ContactInfo> <_mbr:AddressBook > <_mbr:Contact > <_wcf:ContactInfoIdentifier > <_wcf:UniqueID>_wcf:UniqueID</_wcf:UniqueID> <_wcf:ExternalIdentifier > <_wcf:ContactInfoNickName>_wcf:ContactInfoNickName</_wcf:ContactInfoNickName> <_wcf:PersonIdentifier > <_wcf:UniqueID>_wcf:UniqueID</_wcf:UniqueID> <_wcf:DistinguishedName>_wcf:DistinguishedName</_wcf:DistinguishedName> </_wcf:PersonIdentifier> </_wcf:ExternalIdentifier> </_wcf:ContactInfoIdentifier> <_wcf:ContactName > <_wcf:PersonTitle>_wcf:PersonTitle</_wcf:PersonTitle> <_wcf:BusinessTitle>_wcf:BusinessTitle</_wcf:BusinessTitle> <_wcf:LastName>_wcf:LastName</_wcf:LastName> <_wcf:FirstName>_wcf:FirstName</_wcf:FirstName> <_wcf:MiddleName>_wcf:MiddleName</_wcf:MiddleName> </_wcf:ContactName> <_wcf:Address primary="true" type="" > <_wcf:AddressLine>_wcf:AddressLine</_wcf:AddressLine> <_wcf:City>_wcf:City</_wcf:City> <_wcf:StateOrProvinceName>_wcf:StateOrProvinceName</_wcf:StateOrProvinceName> <_wcf:Country>_wcf:Country</_wcf:Country> <_wcf:PostalCode>_wcf:PostalCode</_wcf:PostalCode> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:Address> <_wcf:EmailAddress1 > <_wcf:Value>_wcf:Value</_wcf:Value> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:EmailAddress1> <_wcf:EmailAddress2 > <_wcf:Value>_wcf:Value</_wcf:Value> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:EmailAddress2> <_wcf:Fax1 > <_wcf:Value>_wcf:Value</_wcf:Value> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:Fax1> <_wcf:Fax2 > <_wcf:Value>_wcf:Value</_wcf:Value> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_wcf:Fax2> <_wcf:OrganizationName>_wcf:OrganizationName</_wcf:OrganizationName> <_wcf:OrganizationUnitName>_wcf:OrganizationUnitName</_wcf:OrganizationUnitName> <_wcf:GeographicalShippingCode>_wcf:GeographicalShippingCode</_wcf:GeographicalShippingCode> <_wcf:GeographicalTaxCode>_wcf:GeographicalTaxCode</_wcf:GeographicalTaxCode> <_wcf:Attributes name="">_wcf:Attributes</_wcf:Attributes> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_mbr:Contact> </_mbr:AddressBook> <_mbr:ContextAttribute > <_mbr:Name>_mbr:Name</_mbr:Name> <_mbr:AttributeValue StoreID="" > <_mbr:Value>_mbr:Value</_mbr:Value> </_mbr:AttributeValue> </_mbr:ContextAttribute> <_mbr:Attributes name="">_mbr:Attributes</_mbr:Attributes> <_wcf:UserData > <_wcf:UserDataField name="">_wcf:UserDataField</_wcf:UserDataField> </_wcf:UserData> </_mbr:Organization>
Exceptions
If there is an error, the error is reported in the Response message. You can see the error details in the trace log, SystemOut.log.
Usage
There are three ways to call Web services:
- Call Web services in JSP pages
- To use this service request on a JSP page use one of the following expression-builders:
- getOrganizationByUniqueID, and pass the organizationId parameter
This maps to the following XPath expression:
{_wcf.ap=$accessProfile$}/Organization[OrganizationIdentifier[(UniqueID='$organizationId$')]]
- findByDistinguishedName, and pass the distinguishedName parameter
This maps to the following XPath expression:
{_wcf.ap=$accessProfile$}/Organization[OrganizationIdentifier[(DistinguishedName='$distinguishedName$')]]
- This service request uses the OrgEntityDataBean data bean.
- Call Web services in Java client
- To call member services create a Get BOD then call the correct client API.
- Call Web services
- Use any standard Web services invocation method.
Related Reference
Member services
Schema Organization.xsd
Schema ProcessOrganization.xsd
Schema RespondOrganization.xsd
Schema ShowOrganization.xsd