API Docs

Resources

BASE URL:<<nexiles|gateway service base>>/principalservice
resource description
version plug-in version
teams container teams
users users
groups groups

API Description URL

A HTTP GET to the root of the service base url will return a api description.

Resource: Teams

BASE URL:<<nexiles|gateway service base>>/principalservice/teams
path method description example
/ GET query teams teams?name=*test*
/<oid> GET query one team teams/OR:wt.inf.ContainerTeam:12345
/<oid>/participants GET get participant/role map for team teams/OR:wt.inf.ContainerTeam:12345/participants
/<oid>/roles GET get roles for team teams/OR:wt.inf.ContainerTeam:12345/roles
/<oid>/roles/<role> GET get roles for team teams/OR:wt.inf.ContainerTeam:12345/roles

Participants

URL:/teams/<oid>/participants
METHOD:GET

Returns the role/participant map for the given team.

Data Format:

{
  "_runtime": 0.40400004386901855,
  "oid": "OR:wt.inf.team.ContainerTeam:295708",
  "name": "a team name",
  "url": "/services/principalservice/teams/OR:wt.inf.team.ContainerTeam:295708/participants",
  "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.inf.team.ContainerTeam:295708&u8=1",
  "count": 26,
  "items": [
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTGroup:39550235&u8=1",
      "name": "fritz",
      "oid": "OR:wt.org.WTGroup:39550235",
      "role": "DESIGNER",
      "url": "/services/principalservice/groups?oid=OR%3Awt.org.WTGroup%3A39550235"
    },
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:35978064&u8=1",
      "name": "fred",
      "oid": "OR:wt.org.WTUser:35978064",
      "role": "DESIGNER",
      "url": "/services/principalservice/users?oid=OR%3Awt.org.WTUser%3A35978064"
    },
    ...
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:144636365&u8=1",
      "name": "heinz",
      "oid": "OR:wt.org.WTUser:144636365",
      "role": "INFORMATION ALL MODULES",
      "url": "/services/principalservice/users?oid=OR%3Awt.org.WTUser%3A144636365"
    }
  ],
}

Roles

URL:/teams/<oid>/roles
METHOD:GET

Returns all roles defined on the given team.

Data Format:

{
  "_runtime": 0.016000032424926758,
  "oid": "OR:wt.inf.team.ContainerTeam:295708",
  "name": "A team name",
  "url": "/services/principalservice/teams/OR:wt.inf.team.ContainerTeam:295708/roles",
  "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.inf.team.ContainerTeam:295708&u8=1",
  "count": 4,
  "items": [
    "INFORMATION ACCESSORIES",
    "PRODUCT MANAGER",
    "DESIGNER",
    "APPROVER"
  ]
}

Role info

URL:/teams/<oid>/roles/<role>
METHOD:GET

Return participants of the given role.

Data Format:

{
  "_runtime": 0.08000016212463379,
  "name": "Produkt - TestProduct",
  "oid": "OR:wt.inf.team.ContainerTeam:295708",
  "role": "DESIGNER",
  "url": "/services/principalservice/teams/OR:wt.inf.team.ContainerTeam:295708/roles/DESIGNER"
  "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.inf.team.ContainerTeam:295708&u8=1",
  "count": 6,
  "items": [
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTGroup:39550235&u8=1",
      "name": "fred",
      "oid": "OR:wt.org.WTGroup:39550235",
      "url": "/services/principalservice/groups?oid=OR%3Awt.org.WTGroup%3A39550235"
    },
    ...
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:35978528&u8=1",
      "name": "heinz",
      "oid": "OR:wt.org.WTUser:35978528",
      "url": "/services/principalservice/users?oid=OR%3Awt.org.WTUser%3A35978528"
    },
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:144636365&u8=1",
      "name": "anton",
      "oid": "OR:wt.org.WTUser:144636365",
      "url": "/services/principalservice/users?oid=OR%3Awt.org.WTUser%3A144636365"
    }
  ]
}

Resource: Users

BASE URL:<<nexiles|gateway service base>>/principalservice/users
path method description example
/ GET query users users?name=*test*
/<oid> GET query one users users/OR:wt.inf.ContainerTeam:12345
/<oid> POST update one users users/OR:wt.inf.ContainerTeam:12345

Users

URL:/users
METHOD:GET

Returns all users.

Data Format:

{
  "_runtime": 0.03900003433227539,
  "url": "/services/principalservice/users",
  "count": 4,
  "items": [
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:30080482&u8=1",
      "name": "trainpart08",
      "oid": "OR:wt.org.WTUser:30080482",
      "url": "/services/principalservice/users/OR:wt.org.WTUser:30080482"
    },
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:30811855&u8=1",
      "name": "anton",
      "oid": "OR:wt.org.WTUser:30811855",
      "url": "/services/principalservice/users/OR:wt.org.WTUser:30811855"
    },
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:31441920&u8=1",
      "name": "heinz",
      "oid": "OR:wt.org.WTUser:31441920",
      "url": "/services/principalservice/users/OR:wt.org.WTUser:31441920"
    },
    {
      "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:31441929&u8=1",
      "name": "fritz",
      "oid": "OR:wt.org.WTUser:31441929",
      "url": "/services/principalservice/users/OR:wt.org.WTUser:31441929"
    }
  ]
}

Users – specific user

URL:/users/<oid>
METHOD:GET

Returns user info of specified user.

Data Format:

{
  "_runtime": 0.01699995994567871,
  "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:42910167&u8=1",
  "item": {
    "email": "fritz@example.com",
    "fullname": "Fritz Muster",
    "name": "fritz",
    "oid": "OR:wt.org.WTUser:42910167"
  },
  "name": "fritz",
  "oid": "OR:wt.org.WTUser:42910167",
  "url": "/services/principalservice/users/OR:wt.org.WTUser:42910167"
}

Users – update user data

URL:/users/<oid>
METHOD:POST

Update a user. For this to work, you need to post a valid JSON containing the keys you want to update:

{
    "email": "updated@example.com",
    "first": "Fritz",
    "last": "Muster"
}

Data Format:

{
  "_runtime": 0.01699995994567871,
  "details": "http://example.com/Windchill/servlet/TypeBasedIncludeServlet?oid=OR:wt.org.WTUser:42910167&u8=1",
  "item": {
    "email": "fritz@example.com",
    "fullname": "Fritz Muster",
    "name": "fritz",
    "oid": "OR:wt.org.WTUser:42910167"
  },
  "name": "fritz",
  "oid": "OR:wt.org.WTUser:42910167",
  "url": "/services/principalservice/users/OR:wt.org.WTUser:42910167"
}

Resource: Groups

BASE URL:<<nexiles|gateway service base>>/principalservice/groups