> This page is for Plate-forme, version Hérité.
> For other versions, use one of these documentation indexes:
> - V4 (default): https://next.developer.frame.io/platform/v4/llms.txt
> - V4 expérimental: https://next.developer.frame.io/platform/v4-experimental/llms.txt
> - Hérité: https://next.developer.frame.io/platform/v2/llms.txt

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://next.developer.frame.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://next.developer.frame.io/_mcp/server.

# Ajouter un collaborateur à un projet

POST https://api.frame.io/v2/projects/{project_id}/collaborators
Content-Type: application/json

Ajouter un nouvel utilisateur collaborateur à un projet

Reference: https://next.developer.frame.io/platform/v2/api-reference/projects/add-collaborator-to-project

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `project_id` (string, required)

### Query parameters

- `include` (string, optional) — Inclure des « préchargements » supplémentaires pour cette ressource

### Body (application/json)

This endpoint expects an object.

- `email` (string, optional)

## Response

### 200

Collaborator success response

- `_type` (enum, optional)
  - Allowed values: `collaborator`, `pending_collaborator`
- `email` (string, optional)
- `project_id` (string, optional)
- `user` (User, optional) — Modèle d’utilisateur
- `user_id` (string, optional)

## Errors

### 401 Unauthorized Error

Unauthorized response

- `code` (integer, optional)
- `errors` (list of HttpErrorErrorsItems, optional)
- `message` (string, optional)

### 404 Not Found Error

Not Found response

- `code` (integer, optional)
- `errors` (list of HttpErrorErrorsItems, optional)
- `message` (string, optional)

## Types

### User

Modèle d’utilisateur

- `digest_frequency` (string, optional)
- `features_seen` (any, optional)
- `profile_image_original` (any, optional)
- `image_32` (string, optional)
- `image_128` (string, optional)
- `from_google` (boolean, optional)
- `mfa_enforced_at` (string, optional)
- `email` (string, optional)
- `bio` (any, optional)
- `name` (string, optional)
- `image_64` (string, optional)
- `timezone_value` (string, optional)
- `account_id` (string, optional)
- `updated_at` (string, optional)
- `image_256` (string, optional)
- `_type` (string, optional)
- `user_hash` (string, optional)
- `context` (any, optional)
- `upload_url` (string, optional)
- `location` (any, optional)
- `phone` (any, optional)
- `deleted_at` (any, optional)
- `profile_image` (string, optional)
- `first_login_at` (string, optional)
- `joined_via` (string, optional)
- `email_confirm_by` (any, optional)
- `id` (string, optional)
- `next_digest_date` (string, optional)
- `email_preferences` (any, optional)
- `last_seen` (string, optional)
- `inserted_at` (string, optional)
- `from_adobe` (boolean, optional)
- `avatar_color` (string, optional)
- `highest_account_role` (string, optional)
- `integrations` (list of string, optional)
- `roles` (UserRoles, optional)
- `user_default_color` (string, optional)

### HttpErrorErrorsItems

- `code` (integer, optional)
- `detail` (string, optional)
- `status` (integer, optional)
- `title` (string, optional)

### UserRoles

- `admin` (boolean, optional)
- `id` (string, optional)
- `sales` (boolean, optional)
- `support` (boolean, optional)
- `service_desk` (boolean, optional)

## Examples

**Request**

```json
{}
```

**Response**

```json
{
  "_type": "collaborator",
  "email": "string",
  "project_id": "string",
  "user": {
    "digest_frequency": "string",
    "image_32": "string",
    "image_128": "string",
    "from_google": true,
    "mfa_enforced_at": "string",
    "email": "string",
    "name": "string",
    "image_64": "string",
    "timezone_value": "string",
    "account_id": "string",
    "updated_at": "string",
    "image_256": "string",
    "_type": "string",
    "user_hash": "string",
    "upload_url": "string",
    "profile_image": "string",
    "first_login_at": "string",
    "joined_via": "string",
    "id": "string",
    "next_digest_date": "string",
    "last_seen": "string",
    "inserted_at": "string",
    "from_adobe": true,
    "avatar_color": "string",
    "highest_account_role": "string",
    "integrations": [
      "string"
    ],
    "roles": {
      "admin": true,
      "id": "string",
      "sales": true,
      "support": true,
      "service_desk": true
    },
    "user_default_color": "string"
  },
  "user_id": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.frame.io/v2/projects/project_id/collaborators"

payload = {}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.frame.io/v2/projects/project_id/collaborators';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.frame.io/v2/projects/project_id/collaborators"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.frame.io/v2/projects/project_id/collaborators")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.frame.io/v2/projects/project_id/collaborators")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.frame.io/v2/projects/project_id/collaborators', [
  'body' => '{}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.frame.io/v2/projects/project_id/collaborators");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.frame.io/v2/projects/project_id/collaborators")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```