Team Member Management

Team Member Management API

The Team Member Management API allows you to manage team members and users in your TaskIP system. You can create, read, update, and delete team members, as well as perform bulk operations.

Endpoints Overview

MethodEndpointDescription
GET/api/public-v1/team-memberGet all team members
POST/api/public-v1/team-memberCreate a new team member
GET/api/public-v1/team-member/{id}Get a specific team member
PUT/api/public-v1/team-member/{id}Update a team member
DELETE/api/public-v1/team-member/{id}Delete a team member
POST/api/public-v1/team-member/bulk-deleteDelete multiple team members

Get All Team Members

Retrieve a list of all team members in your system.

GET /api/public-v1/team-member

Request Headers

X-Secret-Key: your-secret-key-here
Content-Type: application/json

Query Parameters

ParameterTypeRequiredDescription
pageintegerNoPage number for pagination (default: 1)
limitintegerNoNumber of team members per page (default: 50)
searchstringNoSearch term for name or email
sortstringNoSort field (name, email, role, created_at)
orderstringNoSort order (asc or desc)
rolestringNoFilter by role
statusstringNoFilter by status (active, inactive, pending)
departmentstringNoFilter by department

Example Request

curl -X GET "https://public-api.taskip.net/api/public-v1/team-member?page=1&limit=20&role=developer" \
  -H "X-Secret-Key: your-secret-key-here" \
  -H "Content-Type: application/json"

JavaScript Example

const response = await fetch('https://public-api.taskip.net/api/public-v1/team-member?status=active', {
  method: 'GET',
  headers: {
    'X-Secret-Key': 'your-secret-key-here',
    'Content-Type': 'application/json'
  }
});
 
const teamMembers = await response.json();

Example Response

{
  "message": "Team member list",
  "data": [
    {
      "id": 1,
      "first_name": "John",
      "last_name": "Smith",
      "full_name": "John Smith",
      "position": "Senior Developer",
      "email": "john.smith@taskip.com",
      "uuid": "550e8400-e29b-41d4-a716-446655440001",
      "role": "admin",
      "created_at": "01, Jan, 2024",
      "teams": [
        {
          "id": 1,
          "name": "Development Team",
          "description": "Frontend and Backend Development"
        }
      ],
      "image": {
        "id": 101,
        "url": "https://cdn.taskip.net/avatars/john-smith.jpg",
        "thumbnail": "https://cdn.taskip.net/avatars/john-smith-thumb.jpg"
      },
      "invitation": {
        "id": 1,
        "status": "accepted",
        "sent_at": "2024-01-01T09:00:00Z",
        "accepted_at": "2024-01-01T10:30:00Z"
      }
    },
    {
      "id": 2,
      "first_name": "Sarah",
      "last_name": "Davis",
      "full_name": "Sarah Davis",
      "position": "Project Manager",
      "email": "sarah.davis@taskip.com",
      "uuid": "550e8400-e29b-41d4-a716-446655440002",
      "role": "project_manager",
      "created_at": "02, Jan, 2024",
      "teams": [
        {
          "id": 2,
          "name": "Project Management",
          "description": "Project coordination and management"
        }
      ],
      "image": null,
      "invitation": {
        "id": 2,
        "status": "accepted",
        "sent_at": "2024-01-02T09:00:00Z",
        "accepted_at": "2024-01-02T11:15:00Z"
      }
    }
  ],
  "links": {
    "first": "https://public-api.taskip.net/api/public-v1/team-member?page=1",
    "last": "https://public-api.taskip.net/api/public-v1/team-member?page=3",
    "prev": null,
    "next": "https://public-api.taskip.net/api/public-v1/team-member?page=2"
  },
  "meta": {
    "current_page": 1,
    "from": 1,
    "last_page": 3,
    "path": "https://public-api.taskip.net/api/public-v1/team-member",
    "per_page": 20,
    "to": 20,
    "total": 45
  }
}

Create a Team Member

Create a new team member in your system.

POST /api/public-v1/team-member

Request Headers

X-Secret-Key: your-secret-key-here
Content-Type: application/json

Request Body

FieldTypeRequiredDescription
emailstringYesTeam member's email address (must be unique)
first_namestringYesTeam member's first name (max 191 characters)
last_namestringYesTeam member's last name (max 191 characters)
positionstringNoJob position/title (max 191 characters)
role_idintegerYesRole ID (numeric)
team_idintegerNoTeam ID (numeric)
imageintegerNoImage/Avatar ID (numeric)

Example Request

curl -X POST "https://public-api.taskip.net/api/public-v1/team-member" \
  -H "X-Secret-Key: your-secret-key-here" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "alice.johnson@taskip.com",
    "first_name": "Alice",
    "last_name": "Johnson",
    "position": "Frontend Developer",
    "role_id": 2,
    "team_id": 1,
    "image": null
  }'

Python Example

import requests
 
headers = {
    'X-Secret-Key': 'your-secret-key-here',
    'Content-Type': 'application/json'
}
 
team_member_data = {
    "email": "alice.johnson@taskip.com",
    "first_name": "Alice",
    "last_name": "Johnson",
    "position": "Frontend Developer",
    "role_id": 2,
    "team_id": 1,
    "image": None
}
 
response = requests.post(
    'https://public-api.taskip.net/api/public-v1/team-member',
    headers=headers,
    json=team_member_data
)
 
result = response.json()

Example Response

{
  "msg": "Team Member Invited Successfully",
  "data": {
    "id": 26,
    "first_name": "Alice",
    "last_name": "Johnson",
    "full_name": "Alice Johnson",
    "position": "Frontend Developer",
    "email": "alice.johnson@taskip.com",
    "uuid": "550e8400-e29b-41d4-a716-446655440026",
    "role": "developer",
    "created_at": "25, Jan, 2024",
    "teams": [
      {
        "id": 1,
        "name": "Development Team",
        "description": "Frontend and Backend Development"
      }
    ],
    "image": null,
    "invitation": {
      "id": 26,
      "status": "pending",
      "sent_at": "2024-01-25T11:45:00Z",
      "accepted_at": null
    }
  }
}

Get a Specific Team Member

Retrieve details of a specific team member by ID.

GET /api/public-v1/team-member/{id}

Path Parameters

ParameterTypeRequiredDescription
idintegerYesTeam member ID

Example Request

curl -X GET "https://public-api.taskip.net/api/public-v1/team-member/26" \
  -H "X-Secret-Key: your-secret-key-here" \
  -H "Content-Type: application/json"

Example Response

{
  "message": "Team Member Details",
  "data": {
    "id": 26,
    "first_name": "Alice",
    "last_name": "Johnson",
    "full_name": "Alice Johnson",
    "position": "Frontend Developer",
    "email": "alice.johnson@taskip.com",
    "uuid": "550e8400-e29b-41d4-a716-446655440026",
    "role": "developer",
    "created_at": "25, Jan, 2024",
    "teams": [
      {
        "id": 1,
        "name": "Development Team",
        "description": "Frontend and Backend Development"
      }
    ],
    "image": {
      "id": 126,
      "url": "https://cdn.taskip.net/avatars/alice-johnson.jpg",
      "thumbnail": "https://cdn.taskip.net/avatars/alice-johnson-thumb.jpg"
    },
    "invitation": {
      "id": 26,
      "status": "accepted",
      "sent_at": "2024-01-25T11:45:00Z",
      "accepted_at": "2024-01-25T14:20:00Z"
    }
  }
}

Update a Team Member

Update an existing team member's information.

PUT /api/public-v1/team-member/{id}

Path Parameters

ParameterTypeRequiredDescription
idintegerYesTeam member ID to update

Request Body

FieldTypeRequiredDescription
emailstringYesTeam member's email address (must be unique, except for current user)
first_namestringYesTeam member's first name (max 191 characters)
last_namestringYesTeam member's last name (max 191 characters)
positionstringNoJob position/title (max 191 characters)
role_idintegerYesRole ID (numeric)
team_idintegerNoTeam ID (numeric)
imageintegerNoImage/Avatar ID (numeric)

Example Request

curl -X PUT "https://public-api.taskip.net/api/public-v1/team-member/26" \
  -H "X-Secret-Key: your-secret-key-here" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "alice.johnson@company.com",
    "first_name": "Alice",
    "last_name": "Johnson",
    "position": "Lead Frontend Developer",
    "role_id": 3,
    "team_id": 1,
    "image": 150
  }'

Example Response

{
  "msg": "Team member updated successfully"
}

Delete a Team Member

Delete a specific team member from your system.

DELETE /api/public-v1/team-member/{id}

Path Parameters

ParameterTypeRequiredDescription
idintegerYesTeam member ID to delete
⚠️

Warning: Deleting a team member will transfer their assigned tasks and projects to the system administrator. This action cannot be undone.

Example Request

curl -X DELETE "https://public-api.taskip.net/api/public-v1/team-member/26" \
  -H "X-Secret-Key: your-secret-key-here"

Example Response

{
  "status": true,
  "message": "Team Member deleted successfully"
}

Bulk Delete Team Members

Delete multiple team members at once.

POST /api/public-v1/team-member/bulk-delete

Request Body

FieldTypeRequiredDescription
idsarrayYesArray of team member IDs to delete
ids.*integerYesEach ID must be a valid integer that exists in users table

Example Request

curl -X POST "https://public-api.taskip.net/api/public-v1/team-member/bulk-delete" \
  -H "X-Secret-Key: your-secret-key-here" \
  -H "Content-Type: application/json" \
  -d '{
    "ids": [24, 25, 27, 28]
  }'

JavaScript Example

const bulkDeleteData = {
  ids: [24, 25, 27, 28]
};
 
const response = await fetch('https://public-api.taskip.net/api/public-v1/team-member/bulk-delete', {
  method: 'POST',
  headers: {
    'X-Secret-Key': 'your-secret-key-here',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify(bulkDeleteData)
});
 
const result = await response.json();

Example Response

{
  "message": "Team Member deleted successfully"
}

User Roles and Permissions

Available Roles

RoleDescriptionDefault Permissions
adminFull system accessAll permissions
project_managerManage projects and teamsproject.*, task.*, team.view
developerDevelopment workproject.view, task.*, time.track
designerDesign workproject.view, task.*, file.upload
clientClient accessproject.view, invoice.view

Permission Categories

CategoryPermissionsDescription
Projectproject.view, project.create, project.edit, project.deleteProject management
Tasktask.view, task.create, task.edit, task.delete, task.assignTask management
Useruser.view, user.create, user.edit, user.deleteUser management
Invoiceinvoice.view, invoice.create, invoice.edit, invoice.sendInvoice management
Reportreport.view, report.generate, report.exportReporting

Error Responses

Common Error Codes

Status CodeError TypeDescription
400Bad RequestInvalid request data or missing required fields
401UnauthorizedInvalid or missing X-Secret-Key
403ForbiddenInsufficient permissions
404Not FoundTeam member not found
409ConflictEmail or username already exists
422Validation ErrorRequest data failed validation
429Too Many RequestsRate limit exceeded

Example Error Response

{
  "success": false,
  "error": "Validation Error",
  "message": "The given data was invalid",
  "errors": {
    "email": ["The email field is required.", "The email must be a valid email address."],
    "role": ["The selected role is invalid."],
    "permissions": ["Invalid permission: invalid.permission"]
  },
  "status_code": 422
}

Response Schemas

Team Member Object

{
  "id": "integer",
  "first_name": "string",
  "last_name": "string",
  "full_name": "string",
  "position": "string|null",
  "email": "string",
  "uuid": "string",
  "role": "string",
  "created_at": "string (formatted: 'd, M, Y')",
  "teams": "array",
  "image": "object|null",
  "invitation": "object"
}

Team Object

{
  "id": "integer",
  "name": "string",
  "description": "string|null"
}

Image Object

{
  "id": "integer",
  "url": "string",
  "thumbnail": "string"
}

Invitation Object

{
  "id": "integer",
  "status": "string",
  "sent_at": "string (ISO 8601)",
  "accepted_at": "string|null (ISO 8601)"
}

Best Practices

Team Management

  1. Role Assignment: Assign appropriate roles based on job functions
  2. Permission Control: Use granular permissions for fine-tuned access control
  3. Regular Reviews: Periodically review team member access and permissions
  4. Secure Passwords: Enforce strong password policies

User Onboarding

  1. Welcome Emails: Use invitation emails for new team members
  2. Profile Completion: Encourage complete profile setup
  3. Training Resources: Provide system training and documentation
  4. Access Reviews: Regular access reviews and updates
💡

Tip: Use the department filter in the GET /team-member endpoint to organize team members by department. This is particularly useful for larger organizations with multiple departments and teams.