> For a complete page index, fetch https://developer.close.com/llms.txt

# Get a single Email activity

GET https://api.close.com/api/v1/activity/email/{id}/

Reference: https://developer.close.com/api/resources/activities/emails/get

## Authentication

- `Authorization` header (basic auth, required) — Use your API key as the username and leave the password empty.
- `Authorization` header (bearer token, required)

## Request

### Path parameters

- `id` (string, required)

### Query parameters

- `_fields` (string, optional) — Comma-separated list of fields to include in the response.

## Response

### 200

Successful response

- `_type` (string, required)
- `activity_at` (datetime, required, nullable)
- `bcc` (list of string, required)
- `body_html` (string, required, nullable)
- `body_text` (string, required, nullable)
- `bulk_email_action_id` (string, required, nullable)
- `cc` (list of string, required)
- `contact_id` (string, required, nullable)
- `created_by` (string, required, nullable)
- `date_created` (datetime, required)
- `date_scheduled` (datetime, required, nullable)
- `date_sent` (datetime, required, nullable)
- `date_updated` (datetime, required)
- `direction` (enum, required, nullable) — Direction of communication. Outgoing means the communication flowing from the user to the lead/contact. Inbound means the opposite.
  - Allowed values: `incoming`, `outgoing`
- `followup_sequence_add_cc_bcc` (boolean, required)
- `followup_sequence_delay` (integer, required, nullable)
- `has_reply` (boolean, required)
- `id` (string, required)
- `in_reply_to_id` (string, required, nullable)
- `lead_id` (string, required, nullable)
- `message_ids` (list of string, required)
- `need_smtp_credentials` (boolean, required)
- `opens_summary` (string, required, nullable)
- `organization_id` (string, required)
- `references` (list of string, required)
- `send_as_id` (string, required, nullable)
- `sender` (string, required, nullable)
- `status` (enum, required) — Status of a message, such as Email or SMS.
  - Allowed values: `inbox`, `draft`, `scheduled`, `outbox`, `sent`, `error`
- `subject` (string, required, nullable)
- `template_id` (string, required, nullable)
- `thread_id` (string, required, nullable)
- `to` (list of string, required)
- `updated_by` (string, required, nullable)
- `user_id` (string, required, nullable)
- `users` (list of string, required)
- `agent_action_reason` (string, optional, nullable)
- `agent_config_id` (string, optional, nullable)
- `attachments` (list of object, optional, nullable)
  - `content_type` (string, required, nullable)
  - `filename` (string, required, nullable)
  - `size` (integer, required, nullable)
  - `url` (string, required)
  - `thumbnail_url` (string, optional, nullable)
- `body_preview` (string, optional, nullable)
- `created_by_name` (string, optional, nullable)
- `email_account_id` (string, optional, nullable)
- `envelope` (map from string to any, optional, nullable)
- `followup_sequence_id` (string, optional, nullable)
- `opens` (list of object, optional, nullable)
  - `ip_address` (string, required, nullable)
  - `opened_at` (datetime, required)
  - `opened_by` (string, required, nullable)
  - `user_agent` (string, required, nullable)
- `send_attempts` (list of map from string to string, optional, nullable)
- `sequence_id` (string, optional, nullable)
- `sequence_name` (string, optional, nullable)
- `sequence_subscription_id` (string, optional, nullable)
- `template_name` (string, optional, nullable)
- `updated_by_name` (string, optional, nullable)
- `user_name` (string, optional, nullable)

## Examples

**Response**

```json
{
  "_type": "Email",
  "activity_at": "2013-02-01T00:54:51.274000+00:00",
  "bcc": [],
  "body_html": "Hi! My name is Karan and I'm your Account Manager. I'm here to get your team set up and help with anything you may need as you evaluate our platform. Please don't hesitate to reach out to me with any questions!",
  "body_text": "Hi! My name is Karan and I'm your Account Manager. I'm here to get your team set up and help with anything you may need as you evaluate our platform. Please don't hesitate to reach out to me with any questions!",
  "bulk_email_action_id": null,
  "cc": [],
  "contact_id": "cont_8NNOJnVwmHQEYuVOgJ4B4zU7g9RUxYH4JnPjza5Vr6t",
  "created_by": null,
  "date_created": "2013-02-01T00:54:51.274000+00:00",
  "date_scheduled": null,
  "date_sent": "2013-02-01T00:54:51.274000+00:00",
  "date_updated": "2013-02-01T00:56:04.184000+00:00",
  "direction": "incoming",
  "followup_sequence_add_cc_bcc": false,
  "followup_sequence_delay": null,
  "has_reply": false,
  "id": "acti_WuIVvTT9b3zLmOOWalxK0OrqtdkxEEdu4mNr1TPGb2o",
  "in_reply_to_id": null,
  "lead_id": "lead_KwD00BYbXCHiPWj68LxFkxaeWuULpZ7awzm6LqeFs0h",
  "message_ids": [],
  "need_smtp_credentials": false,
  "opens_summary": null,
  "organization_id": "orga_RbREgmiiwcr1w2b4cOnCMQaQPSIFxMqAD2Dh243uxcH",
  "references": [],
  "send_as_id": null,
  "sender": "karan@close.com",
  "status": "inbox",
  "subject": "Welcome to Close!",
  "template_id": null,
  "thread_id": "acti_WuIVvTT9b3zLmOOWalxK0OrqtdkxEEdu4mNr1TPGb2o",
  "to": [
    "phil+sample@close.com"
  ],
  "updated_by": "user_N6KhMpzHRCYQHdn4gRNIFNN5JExnsrprKA6ekxM63XA",
  "user_id": "user_N6KhMpzHRCYQHdn4gRNIFNN5JExnsrprKA6ekxM63XA",
  "users": [],
  "attachments": [],
  "envelope": {
    "bcc": [],
    "cc": [],
    "date": "Fri, 01 Feb 2013 00:54:51 +0000",
    "from": [
      {
        "email": "karan@close.com",
        "name": ""
      }
    ],
    "in_reply_to": null,
    "message_id": "<20130201005451.14369.20369@ec2-54-245-86-79.us-west-2.compute.amazonaws.com>",
    "reply_to": [],
    "sender": [
      {
        "email": "karan@close.com",
        "name": ""
      }
    ],
    "subject": "Welcome to Close!",
    "to": [
      {
        "email": "phil+sample@close.com",
        "name": ""
      }
    ]
  },
  "opens": [],
  "send_attempts": [],
  "sequence_id": "seq_1BTljGuCooX0nbFoPihl07",
  "sequence_name": "My Sequence",
  "sequence_subscription_id": "sub_wRlAku35U53xEV7PcNY3Qo",
  "updated_by_name": "Bruce Wayne",
  "user_name": "Bruce Wayne",
  "body_text_quoted": [
    {
      "expand": true,
      "text": "Hi! My name is Karan and I'm your Account Manager. I'm here to get your team set up and help with anything you may need as you evaluate our platform. Please don't hesitate to reach out to me with any questions!"
    }
  ]
}
```

**SDK Code**

```python activities.emails_get_example
import requests

url = "https://api.close.com/api/v1/activity/email/id/"

response = requests.get(url, auth=("<CLOSE_API_KEY>", ""))

print(response.json())
```

```javascript activities.emails_get_example
const url = 'https://api.close.com/api/v1/activity/email/id/';
const credentials = btoa("<CLOSE_API_KEY>:");

const options = {method: 'GET', headers: {Authorization: `Basic ${credentials}`}};

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

```go activities.emails_get_example
package main

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

func main() {

	url := "https://api.close.com/api/v1/activity/email/id/"

	req, _ := http.NewRequest("GET", url, nil)

	req.SetBasicAuth("<CLOSE_API_KEY>", "")

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

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

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

}
```

```ruby activities.emails_get_example
require 'uri'
require 'net/http'

url = URI("https://api.close.com/api/v1/activity/email/id/")

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

request = Net::HTTP::Get.new(url)
request.basic_auth("<CLOSE_API_KEY>", "")

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

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

HttpResponse<String> response = Unirest.get("https://api.close.com/api/v1/activity/email/id/")
  .basicAuth("<CLOSE_API_KEY>", "")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.close.com/api/v1/activity/email/id/', [
  'headers' => [
  ],
    'auth' => ['<CLOSE_API_KEY>', ''],
]);

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

```csharp activities.emails_get_example
using RestSharp;
using RestSharp.Authenticators;

var client = new RestClient("https://api.close.com/api/v1/activity/email/id/");
client.Authenticator = new HttpBasicAuthenticator("<CLOSE_API_KEY>", "");
var request = new RestRequest(Method.GET);

IRestResponse response = client.Execute(request);
```