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

# Create Project Call

POST https://api.coperniq.io/v1/projects/{project_id}/calls
Content-Type: application/json

Create a new phone call record associated with a project

Reference: https://docs.coperniq.io/api-reference/calls/create-project-call

## Authentication

- `x-api-key` header (required) — API Key authentication via header

## Request

### Path parameters

- `project_id` (string, required)

### Body (application/json)

This endpoint expects a CallCreate.

- `fromNumber` (string, required) — Phone number that initiated the call
- `toNumber` (string, required) — Phone number that received the call
- `isInbound` (boolean, required, default: false) — Whether the call was inbound (true) or outbound (false)
- `startTime` (string, required) — When the call started
- `endTime` (string, required) — When the call ended
- `reason` (enum, required) — Reason for the call
  - Allowed values: `PRODUCT`, `PROCESS`, `SERVICE`, `ACCOUNTING`, `REVENUE_OPPORTUNITY`, `FEEDBACK`, `OTHER`
- `disposition` (enum, required) — Call disposition
  - Allowed values: `INFO_PROVIDED`, `VISIT_SCHEDULED`, `ISSUE_RESOLVED`, `FOLLOW_UP`, `ESCALATION`, `NO_ACTION`, `UNRESPONSIVE`, `OTHER`
- `outcome` (enum, optional) — Call outcome
  - Allowed values: `ANSWERED`, `MISSED`
- `note` (string, optional) — Notes about the call
- `recordingUrl` (string, optional) — URL to the call recording
- `transcriptUrl` (string, optional) — URL to the call transcript

## Response

### 201

Call record created successfully

- `id` (integer, required) — Call identifier
- `fromNumber` (string, required) — Phone number that initiated the call
- `toNumber` (string, required) — Phone number that received the call
- `isInbound` (boolean, required) — Whether the call was inbound (true) or outbound (false)
- `createdAt` (string, required) — Creation timestamp
- `updatedAt` (string, required) — Last update timestamp
- `outcome` (enum, optional, nullable) — Call outcome
  - Allowed values: `ANSWERED`, `MISSED`
- `startTime` (string, optional, nullable) — When the call started
- `endTime` (string, optional, nullable) — When the call ended
- `reason` (enum, optional, nullable) — Reason for the call
  - Allowed values: `PRODUCT`, `PROCESS`, `SERVICE`, `ACCOUNTING`, `REVENUE_OPPORTUNITY`, `FEEDBACK`, `OTHER`
- `disposition` (enum, optional, nullable) — Call disposition
  - Allowed values: `INFO_PROVIDED`, `VISIT_SCHEDULED`, `ISSUE_RESOLVED`, `FOLLOW_UP`, `ESCALATION`, `NO_ACTION`, `UNRESPONSIVE`, `OTHER`
- `note` (string, optional, nullable) — Notes about the call
- `recordingUrl` (string, optional, nullable) — URL to the call recording
- `transcriptUrl` (string, optional, nullable) — URL to the call transcript
- `missedCount` (integer, optional, nullable) — Number of times the call was missed

## Errors

### 400 Bad Request Error

Invalid request

- `message` (string, optional)
- `code` (enum, optional)
  - Allowed values: `UNAUTHORIZED`
- `field` (string, optional) — Field that caused the validation error (if applicable)

### 401 Unauthorized Error

Authentication failed

- `message` (string, optional)
- `code` (enum, optional)
  - Allowed values: `UNAUTHORIZED`

## Examples

**Request**

```json
{
  "fromNumber": "string",
  "toNumber": "string",
  "isInbound": false,
  "startTime": "2024-01-15T09:30:00Z",
  "endTime": "2024-01-15T09:30:00Z",
  "reason": "PRODUCT",
  "disposition": "INFO_PROVIDED"
}
```

**Response**

```json
{
  "id": 1,
  "fromNumber": "string",
  "toNumber": "string",
  "isInbound": true,
  "createdAt": "2024-01-15T09:30:00Z",
  "updatedAt": "2024-01-15T09:30:00Z",
  "outcome": "ANSWERED",
  "startTime": "2024-01-15T09:30:00Z",
  "endTime": "2024-01-15T09:30:00Z",
  "reason": "PRODUCT",
  "disposition": "INFO_PROVIDED",
  "note": "string",
  "recordingUrl": "string",
  "transcriptUrl": "string",
  "missedCount": 1
}
```

**SDK Code**

```python
import requests

url = "https://api.coperniq.io/v1/projects/project_id/calls"

payload = {
    "fromNumber": "string",
    "toNumber": "string",
    "isInbound": False,
    "startTime": "2024-01-15T09:30:00Z",
    "endTime": "2024-01-15T09:30:00Z",
    "reason": "PRODUCT",
    "disposition": "INFO_PROVIDED"
}
headers = {
    "x-api-key": "<apiKey>",
    "Content-Type": "application/json"
}

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

print(response.json())
```

```javascript
const url = 'https://api.coperniq.io/v1/projects/project_id/calls';
const options = {
  method: 'POST',
  headers: {'x-api-key': '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"fromNumber":"string","toNumber":"string","isInbound":false,"startTime":"2024-01-15T09:30:00Z","endTime":"2024-01-15T09:30:00Z","reason":"PRODUCT","disposition":"INFO_PROVIDED"}'
};

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.coperniq.io/v1/projects/project_id/calls"

	payload := strings.NewReader("{\n  \"fromNumber\": \"string\",\n  \"toNumber\": \"string\",\n  \"isInbound\": false,\n  \"startTime\": \"2024-01-15T09:30:00Z\",\n  \"endTime\": \"2024-01-15T09:30:00Z\",\n  \"reason\": \"PRODUCT\",\n  \"disposition\": \"INFO_PROVIDED\"\n}")

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

	req.Header.Add("x-api-key", "<apiKey>")
	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.coperniq.io/v1/projects/project_id/calls")

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

request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"fromNumber\": \"string\",\n  \"toNumber\": \"string\",\n  \"isInbound\": false,\n  \"startTime\": \"2024-01-15T09:30:00Z\",\n  \"endTime\": \"2024-01-15T09:30:00Z\",\n  \"reason\": \"PRODUCT\",\n  \"disposition\": \"INFO_PROVIDED\"\n}"

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.coperniq.io/v1/projects/project_id/calls")
  .header("x-api-key", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"fromNumber\": \"string\",\n  \"toNumber\": \"string\",\n  \"isInbound\": false,\n  \"startTime\": \"2024-01-15T09:30:00Z\",\n  \"endTime\": \"2024-01-15T09:30:00Z\",\n  \"reason\": \"PRODUCT\",\n  \"disposition\": \"INFO_PROVIDED\"\n}")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.coperniq.io/v1/projects/project_id/calls', [
  'body' => '{
  "fromNumber": "string",
  "toNumber": "string",
  "isInbound": false,
  "startTime": "2024-01-15T09:30:00Z",
  "endTime": "2024-01-15T09:30:00Z",
  "reason": "PRODUCT",
  "disposition": "INFO_PROVIDED"
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'x-api-key' => '<apiKey>',
  ],
]);

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

```csharp
using RestSharp;

var client = new RestClient("https://api.coperniq.io/v1/projects/project_id/calls");
var request = new RestRequest(Method.POST);
request.AddHeader("x-api-key", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"fromNumber\": \"string\",\n  \"toNumber\": \"string\",\n  \"isInbound\": false,\n  \"startTime\": \"2024-01-15T09:30:00Z\",\n  \"endTime\": \"2024-01-15T09:30:00Z\",\n  \"reason\": \"PRODUCT\",\n  \"disposition\": \"INFO_PROVIDED\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "x-api-key": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = [
  "fromNumber": "string",
  "toNumber": "string",
  "isInbound": false,
  "startTime": "2024-01-15T09:30:00Z",
  "endTime": "2024-01-15T09:30:00Z",
  "reason": "PRODUCT",
  "disposition": "INFO_PROVIDED"
] as [String : Any]

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

let request = NSMutableURLRequest(url: NSURL(string: "https://api.coperniq.io/v1/projects/project_id/calls")! 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()
```