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

# UpdateExport

PATCH https://api.getedulead.com/v4/exports/{id}
Content-Type: application/json

UpdateExport moves the export through its steps (update_mask target, template_id, options,
 range_from with range_to): the target first, then the template, then the options, which
 start the review. A new target clears the template and the options; a reviewed export's
 template, options and range can still change, without a new review.

Reference: https://docs.getedulead.com/api-reference/exports/update

## Authentication

- `Authorization` header (bearer token, required) — A team API key, sent as `Authorization: Bearer <key>`.
- `Authorization` header (bearer token, required) — The Cognito access token of a signed-in Edulead user (`edulead auth login`), sent as `Authorization: Bearer <token>`.

## Request

### Path parameters

- `id` (string, required) — Identifier of the resource, assigned by Edulead and opaque to callers.

### Query parameters

- `update_mask` (string, optional) — Which fields of the resource to change. Fields not listed keep their values.

### Body (application/json)

This endpoint expects an edulead.v4.Export.

- `id` (string, optional) — Identifier of the resource, assigned by Edulead and opaque to callers.
- `entity` (enum, optional) — What it carries; on create, CONTACT or INSTITUTION. enum.defined_only = true
  - Allowed values: `EXPORT_ENTITY_UNSPECIFIED`, `EXPORT_ENTITY_CONTACT`, `EXPORT_ENTITY_INSTITUTION`, `EXPORT_ENTITY_INGESTION`
- `target` (enum, optional) — Where it goes; unset until chosen. enum.defined_only = true
  - Allowed values: `EXPORT_TARGET_UNSPECIFIED`, `EXPORT_TARGET_CSV`, `EXPORT_TARGET_JSON`, `EXPORT_TARGET_HUBSPOT`, `EXPORT_TARGET_SALESFORCE`
- `state` (enum, optional) — enum.defined_only = true
  - Allowed values: `EXPORT_STATE_UNSPECIFIED`, `EXPORT_STATE_FAILURE`, `EXPORT_STATE_SUCCESS`, `EXPORT_STATE_PENDING`, `EXPORT_STATE_IN_PROGRESS`, `EXPORT_STATE_SKIPPED`, `EXPORT_STATE_PREVIEW`, `EXPORT_STATE_TARGET_SELECTION`, `EXPORT_STATE_OPTIONS_SELECTION`, `EXPORT_STATE_REVIEW`, `EXPORT_STATE_EXPORT_PROGRESS`, `EXPORT_STATE_COMPLETED`, `EXPORT_STATE_FAILED`, `EXPORT_STATE_FIELDS_SELECTION`, `EXPORT_STATE_REVIEW_PROGRESS`, `EXPORT_STATE_ARCHIVED`, `EXPORT_STATE_PARTIAL_SUCCESS`, `EXPORT_STATE_REJECTED`
- `step` (enum, optional) — The step the running review or export is at. enum.defined_only = true
  - Allowed values: `EXPORT_STEP_UNSPECIFIED`, `EXPORT_STEP_FETCHING_DATA`, `EXPORT_STEP_VALIDATING_EMAILS`, `EXPORT_STEP_COMPARING_WITH_CRM`, `EXPORT_STEP_PREPARING`, `EXPORT_STEP_EXPORTING`, `EXPORT_STEP_FINALIZING`
- `version` (integer, optional) — 2 for exports made through the wizard, 1 for the retired one-step exports.
- `conditions` (string, optional) — The records: a JSON array of conditions, the same as SearchPeople and SearchInstitutions take, stored as given.
- `estimated_count` (integer, optional, nullable) — The search's total when the export was created.
- `search_id` (string, optional) — The saved search the conditions came from.
- `search_name` (string, optional) — That search's name; GetExport only, empty when the search is gone.
- `template_id` (string, optional) — The template: which fields go where.
- `range_from` (integer, optional, nullable) — The first record to export, from 1; unset with range_to means all.
- `range_to` (integer, optional, nullable) — The last record to export, inclusive.
- `options` (edulead.v4.ExportOptions, optional) — ExportOptions are the choices that start the review; each applies to some entities and targets.
- `match_id` (string, optional) — The match the export came from.
- `source_export_id` (string, optional) — The contact export whose missing companies this export carries.
- `copied_from_export_id` (string, optional) — The export this one copied.
- `companies_export_id` (string, optional) — The export made from this one's missing companies.
- `creator_id` (string, optional) — The user or API key that created it.
- `record_count` (integer, optional, nullable) — Records read; set once the run has counted them.
- `success_count` (integer, optional, nullable)
- `failed_count` (integer, optional, nullable)
- `skipped_count` (integer, optional, nullable)
- `file_name` (string, optional) — The file's name, once a file export succeeded.
- `hubspot_list_id` (string, optional) — The HubSpot list the export made, and the portal it is in.
- `hubspot_portal_id` (string, optional)
- `failure_message` (string, optional) — Why the export FAILED or was REJECTED.
- `review` (edulead.v4.ExportReviewSummary, optional) — The review's decisions; GetExport only, once the review has run.
- `email_verification` (edulead.v4.ExportEmailVerification, optional) — The emails verified; GetExport only, when any were.
- `billable_institutions` (edulead.v4.ExportBillableInstitutions, optional) — The institutions the export would unlock against the team's limit; GetExport only, for a contact export in REVIEW when the team's limit is not unlimited.
- `download_uri` (string, optional) — A link that downloads the file for five minutes; GetExport only, for a successful file export.
- `create_time` (datetime, optional) — When Edulead created the resource.
- `complete_time` (datetime, optional) — When the export finished.
- `archive_time` (datetime, optional) — When the export was archived.
- `update_time` (datetime, optional) — When any field last changed.
- `record_ids` (list of string, optional) — On create only: the people or institutions to export, by id, instead of conditions (a selection). The export stores them as conditions.

## Response

### 200

Success

- `export` (edulead.v4.Export, optional) — Export is one export of people or institutions.

## Types

### edulead.v4.ExportOptions

ExportOptions are the choices that start the review; each applies to some entities and targets.

- `send_notification` (boolean, optional) — Email the creator when the export finishes.
- `email_provider` (enum, optional) — Contacts: who verifies the emails again. enum.defined_only = true
  - Allowed values: `EXPORT_EMAIL_PROVIDER_UNSPECIFIED`, `EXPORT_EMAIL_PROVIDER_NONE`, `EXPORT_EMAIL_PROVIDER_ZEROBOUNCE`, `EXPORT_EMAIL_PROVIDER_NEVERBOUNCE`
- `invalid_email_handling` (enum, optional) — Contacts verified again: what to do with an invalid email. enum.defined_only = true
  - Allowed values: `EXPORT_INVALID_EMAIL_HANDLING_UNSPECIFIED`, `EXPORT_INVALID_EMAIL_HANDLING_SKIP`, `EXPORT_INVALID_EMAIL_HANDLING_INCLUDE`
- `companyless_contacts` (enum, optional) — Contacts to HubSpot: what to do with a contact whose company is missing. enum.defined_only = true
  - Allowed values: `EXPORT_COMPANYLESS_CONTACTS_UNSPECIFIED`, `EXPORT_COMPANYLESS_CONTACTS_IMPORT_ANYWAY`, `EXPORT_COMPANYLESS_CONTACTS_SKIP`, `EXPORT_COMPANYLESS_CONTACTS_CREATE_COMPANY_AND_IMPORT`
- `create_hubspot_list` (boolean, optional) — Contacts to HubSpot: put the exported contacts in a new list.
- `hubspot_list_name` (string, optional) — That list's name.
- `account_association` (enum, optional) — Contacts to HubSpot or to Salesforce contacts: how many companies a contact is linked to. enum.defined_only = true
  - Allowed values: `EXPORT_ACCOUNT_ASSOCIATION_UNSPECIFIED`, `EXPORT_ACCOUNT_ASSOCIATION_MULTIPLE`, `EXPORT_ACCOUNT_ASSOCIATION_SINGLE`
- `salesforce_object` (enum, optional) — Contacts to Salesforce: the object they become. enum.defined_only = true
  - Allowed values: `EXPORT_SALESFORCE_OBJECT_UNSPECIFIED`, `EXPORT_SALESFORCE_OBJECT_CONTACT`, `EXPORT_SALESFORCE_OBJECT_LEAD`
- `include_child_institutions` (boolean, optional) — Institutions to a CRM: also export their schools.
- `preserve_hierarchy` (boolean, optional) — Institutions to a CRM: link each school to its district.

### edulead.v4.ExportReviewSummary

ExportReviewSummary counts an export's review decisions over its records of the export's entity.

- `undecided` (integer, optional)
- `take` (integer, optional)
- `skip` (integer, optional)
- `ineligible` (integer, optional)
- `total` (integer, optional)
- `missing_companies` (integer, optional) — Institutions the CRM does not have yet, which a companies export can create.

### edulead.v4.ExportEmailVerification

ExportEmailVerification counts the emails an export verified.

- `cached` (integer, optional) — Answered from earlier verifications.
- `sent` (integer, optional) — Sent to the provider.
- `skipped_over_limit` (integer, optional) — Not verified: the team's monthly limit was reached.

### edulead.v4.ExportBillableInstitutions

ExportBillableInstitutions counts the institutions a contact export would unlock.

- `used` (integer, optional) — Institutions the team has unlocked so far.
- `limit` (integer, optional) — How many it may unlock.
- `would_unlock` (integer, optional) — The export's institutions not unlocked yet.
- `already_unlocked` (integer, optional) — The export's institutions unlocked already.

### edulead.v4.Export

Export is one export of people or institutions.

- `id` (string, optional) — Identifier of the resource, assigned by Edulead and opaque to callers.
- `entity` (enum, optional) — What it carries; on create, CONTACT or INSTITUTION. enum.defined_only = true
  - Allowed values: `EXPORT_ENTITY_UNSPECIFIED`, `EXPORT_ENTITY_CONTACT`, `EXPORT_ENTITY_INSTITUTION`, `EXPORT_ENTITY_INGESTION`
- `target` (enum, optional) — Where it goes; unset until chosen. enum.defined_only = true
  - Allowed values: `EXPORT_TARGET_UNSPECIFIED`, `EXPORT_TARGET_CSV`, `EXPORT_TARGET_JSON`, `EXPORT_TARGET_HUBSPOT`, `EXPORT_TARGET_SALESFORCE`
- `state` (enum, optional) — enum.defined_only = true
  - Allowed values: `EXPORT_STATE_UNSPECIFIED`, `EXPORT_STATE_FAILURE`, `EXPORT_STATE_SUCCESS`, `EXPORT_STATE_PENDING`, `EXPORT_STATE_IN_PROGRESS`, `EXPORT_STATE_SKIPPED`, `EXPORT_STATE_PREVIEW`, `EXPORT_STATE_TARGET_SELECTION`, `EXPORT_STATE_OPTIONS_SELECTION`, `EXPORT_STATE_REVIEW`, `EXPORT_STATE_EXPORT_PROGRESS`, `EXPORT_STATE_COMPLETED`, `EXPORT_STATE_FAILED`, `EXPORT_STATE_FIELDS_SELECTION`, `EXPORT_STATE_REVIEW_PROGRESS`, `EXPORT_STATE_ARCHIVED`, `EXPORT_STATE_PARTIAL_SUCCESS`, `EXPORT_STATE_REJECTED`
- `step` (enum, optional) — The step the running review or export is at. enum.defined_only = true
  - Allowed values: `EXPORT_STEP_UNSPECIFIED`, `EXPORT_STEP_FETCHING_DATA`, `EXPORT_STEP_VALIDATING_EMAILS`, `EXPORT_STEP_COMPARING_WITH_CRM`, `EXPORT_STEP_PREPARING`, `EXPORT_STEP_EXPORTING`, `EXPORT_STEP_FINALIZING`
- `version` (integer, optional) — 2 for exports made through the wizard, 1 for the retired one-step exports.
- `conditions` (string, optional) — The records: a JSON array of conditions, the same as SearchPeople and SearchInstitutions take, stored as given.
- `estimated_count` (integer, optional, nullable) — The search's total when the export was created.
- `search_id` (string, optional) — The saved search the conditions came from.
- `search_name` (string, optional) — That search's name; GetExport only, empty when the search is gone.
- `template_id` (string, optional) — The template: which fields go where.
- `range_from` (integer, optional, nullable) — The first record to export, from 1; unset with range_to means all.
- `range_to` (integer, optional, nullable) — The last record to export, inclusive.
- `options` (edulead.v4.ExportOptions, optional) — ExportOptions are the choices that start the review; each applies to some entities and targets.
- `match_id` (string, optional) — The match the export came from.
- `source_export_id` (string, optional) — The contact export whose missing companies this export carries.
- `copied_from_export_id` (string, optional) — The export this one copied.
- `companies_export_id` (string, optional) — The export made from this one's missing companies.
- `creator_id` (string, optional) — The user or API key that created it.
- `record_count` (integer, optional, nullable) — Records read; set once the run has counted them.
- `success_count` (integer, optional, nullable)
- `failed_count` (integer, optional, nullable)
- `skipped_count` (integer, optional, nullable)
- `file_name` (string, optional) — The file's name, once a file export succeeded.
- `hubspot_list_id` (string, optional) — The HubSpot list the export made, and the portal it is in.
- `hubspot_portal_id` (string, optional)
- `failure_message` (string, optional) — Why the export FAILED or was REJECTED.
- `review` (edulead.v4.ExportReviewSummary, optional) — The review's decisions; GetExport only, once the review has run.
- `email_verification` (edulead.v4.ExportEmailVerification, optional) — The emails verified; GetExport only, when any were.
- `billable_institutions` (edulead.v4.ExportBillableInstitutions, optional) — The institutions the export would unlock against the team's limit; GetExport only, for a contact export in REVIEW when the team's limit is not unlimited.
- `download_uri` (string, optional) — A link that downloads the file for five minutes; GetExport only, for a successful file export.
- `create_time` (datetime, optional) — When Edulead created the resource.
- `complete_time` (datetime, optional) — When the export finished.
- `archive_time` (datetime, optional) — When the export was archived.
- `update_time` (datetime, optional) — When any field last changed.
- `record_ids` (list of string, optional) — On create only: the people or institutions to export, by id, instead of conditions (a selection). The export stores them as conditions.

## Examples

**Request**

```json
{}
```

**Response**

```json
{
  "export": {
    "id": "string",
    "entity": "EXPORT_ENTITY_UNSPECIFIED",
    "target": "EXPORT_TARGET_UNSPECIFIED",
    "state": "EXPORT_STATE_UNSPECIFIED",
    "step": "EXPORT_STEP_UNSPECIFIED",
    "version": 1,
    "conditions": "string",
    "estimated_count": 1,
    "search_id": "string",
    "search_name": "string",
    "template_id": "string",
    "range_from": 1,
    "range_to": 1,
    "options": {
      "send_notification": true,
      "email_provider": "EXPORT_EMAIL_PROVIDER_UNSPECIFIED",
      "invalid_email_handling": "EXPORT_INVALID_EMAIL_HANDLING_UNSPECIFIED",
      "companyless_contacts": "EXPORT_COMPANYLESS_CONTACTS_UNSPECIFIED",
      "create_hubspot_list": true,
      "hubspot_list_name": "string",
      "account_association": "EXPORT_ACCOUNT_ASSOCIATION_UNSPECIFIED",
      "salesforce_object": "EXPORT_SALESFORCE_OBJECT_UNSPECIFIED",
      "include_child_institutions": true,
      "preserve_hierarchy": true
    },
    "match_id": "string",
    "source_export_id": "string",
    "copied_from_export_id": "string",
    "companies_export_id": "string",
    "creator_id": "string",
    "record_count": 1,
    "success_count": 1,
    "failed_count": 1,
    "skipped_count": 1,
    "file_name": "string",
    "hubspot_list_id": "string",
    "hubspot_portal_id": "string",
    "failure_message": "string",
    "review": {
      "undecided": 1,
      "take": 1,
      "skip": 1,
      "ineligible": 1,
      "total": 1,
      "missing_companies": 1
    },
    "email_verification": {
      "cached": 1,
      "sent": 1,
      "skipped_over_limit": 1
    },
    "billable_institutions": {
      "used": 1,
      "limit": 1,
      "would_unlock": 1,
      "already_unlocked": 1
    },
    "download_uri": "string",
    "create_time": "2023-01-15T01:30:15.01Z",
    "complete_time": "2023-01-15T01:30:15.01Z",
    "archive_time": "2023-01-15T01:30:15.01Z",
    "update_time": "2023-01-15T01:30:15.01Z",
    "record_ids": [
      "string"
    ]
  }
}
```

**SDK Code**

```python
import requests

url = "https://api.getedulead.com/v4/exports/id"

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

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

print(response.json())
```

```javascript
const url = 'https://api.getedulead.com/v4/exports/id';
const options = {
  method: 'PATCH',
  headers: {Authorization: 'Bearer <apiKey>', '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.getedulead.com/v4/exports/id"

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

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

	req.Header.Add("Authorization", "Bearer <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.getedulead.com/v4/exports/id")

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

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <apiKey>'
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.patch("https://api.getedulead.com/v4/exports/id")
  .header("Authorization", "Bearer <apiKey>")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('PATCH', 'https://api.getedulead.com/v4/exports/id', [
  'body' => '{}',
  'headers' => [
    'Authorization' => 'Bearer <apiKey>',
    'Content-Type' => 'application/json',
  ],
]);

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

```csharp
using RestSharp;

var client = new RestClient("https://api.getedulead.com/v4/exports/id");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "Bearer <apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

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

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

let request = NSMutableURLRequest(url: NSURL(string: "https://api.getedulead.com/v4/exports/id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
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()
```