Community articleCreating profiles codes using Administration API
Added by IBM contributorIBM | Edited by IBM contributorLDD Webmaster on July 1, 2014
Rate this article 1 starsRate this article 2 starsRate this article 3 starsRate this article 4 starsRate this article 5 stars

No abstract provided.

To add a profiles code to the Profiles application, send a codes entry document in Atom format to the appropriate resource of the Administration API.

Input

Provide a profile entry Atom entry document as the POST data. The content type of the Atom entry document must be application/atom+xml. The following entries must be provided in the profile entry document:


<entry>

	<id>tag:profiles.ibm.com,2006:com.ibm.snx_profiles.codes.{country|department|empType|organization|workLocation}:{code value}</id>

	</entry>

 

Output

None.

All other entries are optional.

 

Input
Method URI Description
POST /profiles/admin/atom/codes/Country.do country
POST /profiles/admin/atom/codes/Department.do department
POST /profiles/admin/atom/codes/EmployeeType.do employee type
POST /profiles/admin/atom/codes/Organization.do organization
POST /profiles/admin/atom/codes/WorkLocation.do work location
Content Type: application/atom+xml
Examples
To add a codes entry in the country table for the country of Andorra, complete the following steps. 1.Create a codes entry in the country table for the country of Andorra. The following XML snippet is a sample codes entry document. 2.Send a POST request to the /admin/atom/country.do resource and pass this document as input on the request.
<entry>
  <id>tag:profiles.ibm.com,2006:com.ibm.snx_profiles.codes.country:ad</id>
  <title type="text">ad</title>
  <updated>2010-12-10T23:23:16.087Z</updated>
  <link
    href="http://example.org/profiles/admin//atom/codes/country.do?code=ad" rel="edit"/>
  <content type="application/xml">
    <appData xmlns="http://ns.opensocial.org/2008/opensocial">
      <com.ibm.snx_profiles.codes.country>

           Andorra, Principality of

       </com.ibm.snx_profiles.codes.country>
    </appData>
  </content>
</entry>