# insertteam

### description

Inserts a new team into a Buzzy Organization

### parameters

The `X-Auth-Token` and `X-User-Id` are derived from the values `authToken` and `userId` returned from the login endpoint and are used in the HTTP header.

```
{
        "teamInfo":{
          "organizationID":"<organization which to insert the team into>",
          "_id": "<optional unique identified, will be autogenerated>",
          "name": "<name of team>",
          "description":"<optional description>"
        },
        adminID: "optional userID, that will become the admin of the team, 
        if ot supplied  will be the user making the request"      
}





```

### response

Returns the status of the request including the ID for the new organization.

### example

<pre><code><strong>POST /api/insertteam 
</strong>X-Auth-Token:&#x3C;insert token here>
X-User-Id:&#x3C;insert user id here>

{
        "teamInfo":{
          "organizationID":"&#x3C;organization which to insert the team into>",
          "_id": "&#x3C;optional unique identified, will be autogenerated>",
          "name": "&#x3C;name of team>",
          "description":"&#x3C;optional description>"
        },
        adminID: "optional userID, that will become the admin of the team, 
        if ot supplied  will be the user making the request"      
}
</code></pre>

You should get back:

```
{
    "status": "success", "result":"<result of insert>"
}
```

***
