Teams
Ce contenu n’est pas encore disponible dans votre langue.
Overview
Section titled “Overview”The Teams resource provides fake team data with names, descriptions, leads, and member associations.
Endpoints
Section titled “Endpoints”| Method | Endpoint | Description |
|---|---|---|
| GET | /v1/teams | List all teams |
| GET | /v1/teams/:id | Get a specific team |
| GET | /v1/teams/:id/members | Get team's members |
Team Object
Section titled “Team Object”{ "id": 1, "organizationId": 1, "name": "Alpha Team", "slug": "alpha-team", "description": "Frontend development team", "leadId": 5, "createdAt": "2026-01-15T10:30:00.000Z", "updatedAt": "2026-01-15T10:30:00.000Z"}| Field | Type | Description |
|---|---|---|
id |
number |
Unique identifier |
organizationId |
number |
ID of the parent organization |
name |
string |
Team name |
slug |
string |
URL-friendly unique slug |
description |
string |
Team description |
leadId |
number |
ID of the team lead |
createdAt |
string |
ISO 8601 timestamp |
updatedAt |
string |
ISO 8601 timestamp |
List Teams
Section titled “List Teams”curl https://api.phantomjson.app/v1/teamsQuery Parameters
Section titled “Query Parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
page |
number |
1 |
Page number |
limit |
number |
20 |
Items per page (max: 100) |
sort |
string |
— | Sort field and direction |
q |
string |
— | Search query |
fields |
string |
— | Fields to return |
organizationId |
number |
— | Filter by organization ID |
Response
Section titled “Response”{ "data": [ { "id": 1, "organizationId": 1, "name": "Alpha Team", "slug": "alpha-team", "description": "Frontend development team" } ], "meta": { "total": 10, "page": 1, "limit": 20, "totalPages": 1 }}Get Team by ID
Section titled “Get Team by ID”curl https://api.phantomjson.app/v1/teams/1Response
Section titled “Response”{ "data": { "id": 1, "organizationId": 1, "name": "Alpha Team", "slug": "alpha-team", "description": "Frontend development team", "leadId": 5, "organization": { "id": 1, "name": "Acme Corporation" } }}Get Team’s Members
Section titled “Get Team’s Members”curl https://api.phantomjson.app/v1/teams/1/membersResponse
Section titled “Response”{ "data": [ { "id": 1, "teamId": 1, "employeeId": 1, "role": "member", "joinedAt": "2026-01-15T10:30:00.000Z", "employee": { "id": 1, "firstName": "Alice", "lastName": "Johnson", "jobTitle": "Software Engineer" } } ], "meta": { "total": 5, "page": 1, "limit": 20, "totalPages": 1 }}Examples
Section titled “Examples”Search Teams
Section titled “Search Teams”curl "https://api.phantomjson.app/v1/teams?q=alpha"Filter by Organization
Section titled “Filter by Organization”curl "https://api.phantomjson.app/v1/teams?organizationId=1"Field Selection
Section titled “Field Selection”curl "https://api.phantomjson.app/v1/teams?fields=id,name,organizationId"Combined Query
Section titled “Combined Query”# Teams in organization 1, sorted by namecurl "https://api.phantomjson.app/v1/teams?organizationId=1&sort=name:asc&fields=id,name,description"Relations
Section titled “Relations”- Organization — Each team belongs to an organization (
organizationId) - Members — Each team has many members (access via
/v1/teams/:id/members) - Lead — Each team may have a lead (
leadId)
