Convert a Group to Team
    • Dark
      Light
    • PDF

    Convert a Group to Team

    • Dark
      Light
    • PDF

    Article summary

    Post
    /api/v1/groups.convertToTeam

    Convert a group to a team.

    Changelog

    VersionDescription
    3.13.0Added
    Header parameters
    X-Auth-Token
    stringRequired

    The authToken of the authenticated user.

    ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
    X-User-Id
    stringRequired

    The userId of the authenticated user.

    ExamplerbAXPnMktTFbNpwtJ
    Body parameters
    object
    teamName
    string

    Enter the team name. This parameter is required if teamId is not provided.

    teamId
    string

    Enter the team ID. This parameter is required if teamName is not provided.

    roomsToRemove
    Array of string

    The room IDs to delete along with the team.

    string
    Example8dugqGhuRvCBLdZft
    Responses
    200

    OK

    Example 1
    {
      "team": {
        "_id": "6172b15bc563fc000acc462e",
        "name": "ddd",
        "type": 1,
        "createdAt": "2021-10-22T12:40:59.928Z",
        "createdBy": {
          "_id": "d26x6zSkaPSe5gCyy",
          "username": "rodriq"
        },
        "_updatedAt": "2021-10-22T12:40:59.928Z",
        "roomId": "h3HLZkQdrWCPg2RN7"
      },
      "success": true
    }
    Expand All
    object
    team
    object
    _id
    string
    name
    string
    type
    integer
    createdAt
    string
    createdBy
    object
    _id
    string
    username
    string
    _updatedAt
    string
    roomId
    string
    success
    boolean
    400

    Bad Request

    Example 1
    {
      "success": false,
      "error": "team-name-already-exists"
    }
    Example 2
    {
      "success": false,
      "error": "The parameter \"roomId\" or \"roomName\" is required"
    }
    Example 3
    {
      "success": false,
      "error": "The required \"roomId\" or \"roomName\" param provided does not match any group [error-room-not-found]",
      "errorType": "error-room-not-found"
    }
    object
    success
    boolean
    error
    string
    401

    Unauthorized

    Authorization Error
    {
      "status": "error",
      "message": "You must be logged in to do this."
    }
    object
    status
    string
    message
    string

    Was this article helpful?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.