from metadata.sdk import configurefrom metadata.sdk.entities import Teamsconfigure( host="https://your-company.getcollate.io/api", jwt_token="your-jwt-token")# Get by IDteam = Teams.retrieve("449b5f25-4cbb-42db-8f71-3be2c5cd888a")print(f"{team.fullyQualifiedName}: {team.teamType}")# Get by ID with fieldsteam = Teams.retrieve( "449b5f25-4cbb-42db-8f71-3be2c5cd888a", fields=["users", "parents", "policies"])# Get by fully qualified nameteam = Teams.retrieve_by_name("Accounting")# Get by name with fieldsteam = Teams.retrieve_by_name( "Accounting", fields=["users", "parents", "children"])
Retrieve a team entity by UUID or fully qualified name with optional field expansion for users, roles, policies, and parent/child team relationships using the Collate REST API.
GET
/
v1
/
teams
/
{id}
GET /v1/teams/{id}
Copy
from metadata.sdk import configurefrom metadata.sdk.entities import Teamsconfigure( host="https://your-company.getcollate.io/api", jwt_token="your-jwt-token")# Get by IDteam = Teams.retrieve("449b5f25-4cbb-42db-8f71-3be2c5cd888a")print(f"{team.fullyQualifiedName}: {team.teamType}")# Get by ID with fieldsteam = Teams.retrieve( "449b5f25-4cbb-42db-8f71-3be2c5cd888a", fields=["users", "parents", "policies"])# Get by fully qualified nameteam = Teams.retrieve_by_name("Accounting")# Get by name with fieldsteam = Teams.retrieve_by_name( "Accounting", fields=["users", "parents", "children"])
from metadata.sdk import configurefrom metadata.sdk.entities import Teamsconfigure( host="https://your-company.getcollate.io/api", jwt_token="your-jwt-token")# Get by IDteam = Teams.retrieve("449b5f25-4cbb-42db-8f71-3be2c5cd888a")print(f"{team.fullyQualifiedName}: {team.teamType}")# Get by ID with fieldsteam = Teams.retrieve( "449b5f25-4cbb-42db-8f71-3be2c5cd888a", fields=["users", "parents", "policies"])# Get by fully qualified nameteam = Teams.retrieve_by_name("Accounting")# Get by name with fieldsteam = Teams.retrieve_by_name( "Accounting", fields=["users", "parents", "children"])