# LeadConnector

> Manage contacts, notes, tasks and tags in a LeadConnector sub-account.

App · 20 actions. Web page: https://docs.lodol.com/docs/integrations/leadconnector

## Actions

### Add tags

Add Tags.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Tags (`tags`, list, required): Tags.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "tags": []
  }
}
```

### Create contact

Create Contact.

**Inputs**

- First name (`first_name`, text): First name.
- Last name (`last_name`, text): Last name.
- Name (`name`, text): Name.
- Email (`email`, text): Email.
- Location id (`location_id`, text): Leave empty to use the connected sub-account.
- Gender (`gender`, text): Gender.
- Phone (`phone`, text): Phone.
- Address1 (`address1`, text): Address1.
- City (`city`, text): City.
- State (`state`, text): State.
- Postal code (`postal_code`, text): Postal code.
- Website (`website`, text): Website.
- Timezone (`timezone`, text): Timezone.
- Dnd (`dnd`, true/false): Dnd.
- Dnd settings (`dnd_settings`, object): Dnd settings.
- Inbound dnd settings (`inbound_dnd_settings`, object): Inbound dnd settings.
- Tags (`tags`, list): Tags.
- Custom fields (`custom_fields`, list): Custom fields.
- Source (`source`, text): Source.
- Date of birth (`date_of_birth`, object): The birth date of the contact. Supported formats: YYYY/MM/DD, MM/DD/YYYY, YYYY-MM-DD, MM-DD-YYYY, YYYY.MM.DD, MM.DD.YYYY, YYYY_MM_DD, MM_DD_YYYY
- Country (`country`, text): Country.
- Company name (`company_name`, text): Company name.
- Assigned to (`assigned_to`, text): User's Id

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "contact": {
      "address1": "example",
      "assignedTo": "example",
      "birthDay": 1.0,
      "birthMonth": 1.0,
      "bounceEmail": false,
      "businessId": "example",
      "city": "example",
      "companyName": "example",
      "country": "example",
      "customFields": [],
      "dateAdded": "example",
      "dateOfBirth": "example",
      "dateUpdated": "example",
      "deleted": false,
      "dnd": false,
      "dndSettings": {
        "Call": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "Email": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "FB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "GMB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "SMS": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "WhatsApp": {
          "code": "example",
          "message": "example",
          "status": "active"
        }
      },
      "email": "example",
      "emailLowerCase": "example",
      "firstName": "example",
      "firstNameLowerCase": "example",
      "fullNameLowerCase": "example",
      "id": "example",
      "lastName": "example",
      "lastNameLowerCase": "example",
      "lastSessionActivityAt": "example",
      "locationId": "example",
      "offers": [],
      "phone": "example",
      "postalCode": "example",
      "products": [],
      "source": "example",
      "state": "example",
      "tags": [],
      "type": "example",
      "unsubscribeEmail": false,
      "website": "example"
    }
  }
}
```

### Create note

Create Note.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- User id (`service_user_id`, text): Service user id.
- Body (`body`, text, required): Body.
- Title (`title`, text): Title.
- Color (`color`, text): Color.
- Pinned (`pinned`, true/false): Pinned.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "note": {
      "body": "example",
      "color": "example",
      "contactId": "example",
      "dateAdded": "example",
      "id": "example",
      "pinned": false,
      "title": "example",
      "userId": "example"
    }
  }
}
```

### Create task

Create Task.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Title (`title`, text, required): Title.
- Body (`body`, text): Body.
- Due date (`due_date`, date and time, required): Due date.
- Completed (`completed`, true/false, required): Completed.
- Assigned to (`assigned_to`, text): Assigned to.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "task": {
      "assignedTo": "example",
      "body": "example",
      "completed": false,
      "contactId": "example",
      "dueDate": "example",
      "id": "example",
      "title": "example"
    }
  }
}
```

### Delete contact

Delete Contact.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "succeded": false
  }
}
```

### Delete note

Delete Note.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Id (`id`, text, required): Id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "succeded": false
  }
}
```

### Delete task

Delete Task.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Task id (`task_id`, text, required): Task id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "succeded": false
  }
}
```

### Get contact

Get Contact.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "contact": {
      "address1": "example",
      "assignedTo": "example",
      "attachments": "example",
      "attributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "businessId": "example",
      "city": "example",
      "companyName": "example",
      "country": "example",
      "customFields": [],
      "dateAdded": "example",
      "dateOfBirth": "example",
      "dateUpdated": "example",
      "dnd": false,
      "dndSettings": {
        "Call": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "Email": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "FB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "GMB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "SMS": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "WhatsApp": {
          "code": "example",
          "message": "example",
          "status": "active"
        }
      },
      "email": "example",
      "emailLowerCase": "example",
      "firstName": "example",
      "firstNameLowerCase": "example",
      "fullNameLowerCase": "example",
      "id": "example",
      "keyword": "example",
      "lastActivity": "example",
      "lastAttributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "lastName": "example",
      "lastNameLowerCase": "example",
      "locationId": "example",
      "name": "example",
      "phone": "example",
      "postalCode": "example",
      "source": "example",
      "ssn": "example",
      "state": "example",
      "tags": [],
      "timezone": "example",
      "type": "example",
      "visitorId": "example",
      "website": "example"
    }
  }
}
```

### Get note

Get Note.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Id (`id`, text, required): Id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "note": {
      "body": "example",
      "color": "example",
      "contactId": "example",
      "dateAdded": "example",
      "id": "example",
      "pinned": false,
      "title": "example",
      "userId": "example"
    }
  }
}
```

### Get task

Get Task.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Task id (`task_id`, text, required): Task id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "task": {
      "assignedTo": "example",
      "body": "example",
      "completed": false,
      "contactId": "example",
      "dueDate": "example",
      "id": "example",
      "title": "example"
    }
  }
}
```

### List appointments

Get Appointments for Contact.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "events": []
  }
}
```

### List notes

Get All Notes.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "notes": []
  }
}
```

### List tasks

Get all Tasks.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "tasks": []
  }
}
```

### Remove tags

Remove Tags.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Tags (`tags`, list, required): Tags.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "tags": []
  }
}
```

### Search contacts

Search Contacts.

**Inputs**

- Location id (`location_id`, text): Leave empty to use the connected sub-account.
- Query (`query`, text): Search the contact fields enabled in your sub-account.
- Page (`page`, number): Page number, starting at 1. Do not combine with a cursor. At least 1.
- Page limit (`page_limit`, number): How many contacts to return per page, up to 500. From 1 to 500. Default: `100`.
- Search after (`search_after`, list): Copy the searchAfter array from the last contact of the preceding page. Do not combine with Page.

**Outputs**

- `data` (object): One page of matching contacts.

**Example output**

```json
{
  "data": {
    "contacts": [],
    "total": 1,
    "traceId": "example"
  }
}
```

### Set task completed

Update Task Completed.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Task id (`task_id`, text, required): Task id.
- Completed (`completed`, true/false, required): Completed.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "task": {
      "assignedTo": "example",
      "body": "example",
      "completed": false,
      "contactId": "example",
      "dueDate": "example",
      "id": "example",
      "title": "example"
    }
  }
}
```

### Update contact

Update Contact.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- First name (`first_name`, text): First name.
- Last name (`last_name`, text): Last name.
- Name (`name`, text): Name.
- Email (`email`, text): Email.
- Phone (`phone`, text): Phone.
- Address1 (`address1`, text): Address1.
- City (`city`, text): City.
- State (`state`, text): State.
- Postal code (`postal_code`, text): Postal code.
- Website (`website`, text): Website.
- Timezone (`timezone`, text): Timezone.
- Dnd (`dnd`, true/false): Dnd.
- Dnd settings (`dnd_settings`, object): Dnd settings.
- Inbound dnd settings (`inbound_dnd_settings`, object): Inbound dnd settings.
- Tags (`tags`, list): This field will overwrite all current tags associated with the contact. To update a tags, it is recommended to use the Add Tag or Remove Tag API instead.
- Custom fields (`custom_fields`, list): Custom fields.
- Source (`source`, text): Source.
- Date of birth (`date_of_birth`, object): The birth date of the contact. Supported formats: YYYY/MM/DD, MM/DD/YYYY, YYYY-MM-DD, MM-DD-YYYY, YYYY.MM.DD, MM.DD.YYYY, YYYY_MM_DD, MM_DD_YYYY
- Country (`country`, text): Country.
- Assigned to (`assigned_to`, text): User's Id

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "contact": {
      "address1": "example",
      "assignedTo": "example",
      "attachments": "example",
      "attributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "businessId": "example",
      "city": "example",
      "companyName": "example",
      "country": "example",
      "customFields": [],
      "dateAdded": "example",
      "dateOfBirth": "example",
      "dateUpdated": "example",
      "dnd": false,
      "dndSettings": {
        "Call": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "Email": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "FB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "GMB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "SMS": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "WhatsApp": {
          "code": "example",
          "message": "example",
          "status": "active"
        }
      },
      "email": "example",
      "emailLowerCase": "example",
      "firstName": "example",
      "firstNameLowerCase": "example",
      "fullNameLowerCase": "example",
      "id": "example",
      "keyword": "example",
      "lastActivity": "example",
      "lastAttributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "lastName": "example",
      "lastNameLowerCase": "example",
      "locationId": "example",
      "name": "example",
      "phone": "example",
      "postalCode": "example",
      "source": "example",
      "ssn": "example",
      "state": "example",
      "tags": [],
      "timezone": "example",
      "type": "example",
      "visitorId": "example",
      "website": "example"
    },
    "succeded": false
  }
}
```

### Update note

Update Note.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Id (`id`, text, required): Id.
- User id (`service_user_id`, text): Service user id.
- Body (`body`, text): Body.
- Title (`title`, text): Title.
- Color (`color`, text): Color.
- Pinned (`pinned`, true/false): Pinned.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "note": {
      "body": "example",
      "color": "example",
      "contactId": "example",
      "dateAdded": "example",
      "id": "example",
      "pinned": false,
      "title": "example",
      "userId": "example"
    }
  }
}
```

### Update task

Update Task.

**Inputs**

- Contact (`contact_id`, text, required): Contact id.
- Task id (`task_id`, text, required): Task id.
- Title (`title`, text): Title.
- Body (`body`, text): Body.
- Due date (`due_date`, date and time): Due date.
- Completed (`completed`, true/false): Completed.
- Assigned to (`assigned_to`, text): Assigned to.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "task": {
      "assignedTo": "example",
      "body": "example",
      "completed": false,
      "contactId": "example",
      "dueDate": "example",
      "id": "example",
      "title": "example"
    }
  }
}
```

### Upsert contact

Upsert Contact.

**Inputs**

- First name (`first_name`, text): First name.
- Last name (`last_name`, text): Last name.
- Name (`name`, text): Name.
- Email (`email`, text): Email.
- Location id (`location_id`, text): Leave empty to use the connected sub-account.
- Gender (`gender`, text): Gender.
- Phone (`phone`, text): Phone.
- Address1 (`address1`, text): Address1.
- City (`city`, text): City.
- State (`state`, text): State.
- Postal code (`postal_code`, text): Postal code.
- Website (`website`, text): Website.
- Timezone (`timezone`, text): Timezone.
- Dnd (`dnd`, true/false): Dnd.
- Dnd settings (`dnd_settings`, object): Dnd settings.
- Inbound dnd settings (`inbound_dnd_settings`, object): Inbound dnd settings.
- Tags (`tags`, list): This field will overwrite all current tags associated with the contact. To update a tags, it is recommended to use the Add Tag or Remove Tag API instead.
- Custom fields (`custom_fields`, list): Custom fields.
- Source (`source`, text): Source.
- Date of birth (`date_of_birth`, object): The birth date of the contact. Supported formats: YYYY/MM/DD, MM/DD/YYYY, YYYY-MM-DD, MM-DD-YYYY, YYYY.MM.DD, MM.DD.YYYY, YYYY_MM_DD, MM_DD_YYYY
- Country (`country`, text): Country.
- Company name (`company_name`, text): Company name.
- Assigned to (`assigned_to`, text): User's Id
- Create new if duplicate allowed (`create_new_if_duplicate_allowed`, true/false): Controls whether to create a new contact or update an existing duplicate. **Scenario 1:** If this value is `true` and the location allows duplicate contacts, a new contact will be created immediately without checking for duplicates. **Scenario 2:** If this value is `true` but the location does not allow duplicate contacts, this field is ignored and the normal upsert behavior applies: the API will search for an existing duplicate contact, update it if found, or create a new contact if not found. **Scenario 3:** If this value is `false` or not provided, the normal upsert behavior applies regardless of the location's duplicate contact setting. Default: `false`.

**Outputs**

- `data` (object): Service response.

**Example output**

```json
{
  "data": {
    "contact": {
      "address1": "example",
      "assignedTo": "example",
      "attachments": "example",
      "attributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "businessId": "example",
      "city": "example",
      "companyName": "example",
      "country": "example",
      "customFields": [],
      "dateAdded": "example",
      "dateOfBirth": "example",
      "dateUpdated": "example",
      "dnd": false,
      "dndSettings": {
        "Call": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "Email": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "FB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "GMB": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "SMS": {
          "code": "example",
          "message": "example",
          "status": "active"
        },
        "WhatsApp": {
          "code": "example",
          "message": "example",
          "status": "active"
        }
      },
      "email": "example",
      "emailLowerCase": "example",
      "firstName": "example",
      "firstNameLowerCase": "example",
      "fullNameLowerCase": "example",
      "id": "example",
      "keyword": "example",
      "lastActivity": "example",
      "lastAttributionSource": {
        "campaign": "example",
        "campaignId": "example",
        "dclid": "example",
        "fbEventId": "example",
        "fbc": "example",
        "fbclid": "example",
        "fbp": "example",
        "gclid": "example",
        "ip": "example",
        "medium": "example",
        "mediumId": "example",
        "msclikid": "example",
        "referrer": "example",
        "url": "example",
        "userAgent": "example",
        "utmContent": "example",
        "utmMedium": "example",
        "utmSource": "example"
      },
      "lastName": "example",
      "lastNameLowerCase": "example",
      "locationId": "example",
      "name": "example",
      "phone": "example",
      "postalCode": "example",
      "source": "example",
      "ssn": "example",
      "state": "example",
      "tags": [],
      "timezone": "example",
      "type": "example",
      "visitorId": "example",
      "website": "example"
    },
    "new": false,
    "traceId": "example"
  }
}
```
