---
title: "Link a party to a CRM directory entry, or unlink it"
method: POST
path: "/v1/parties/{id}/directory-link"
tags: ["Contract Party Management"]
---

# Link a party to a CRM directory entry, or unlink it

`POST /v1/parties/{id}/directory-link`

## Request

- Base URL: `https://api.talonic.com`
- URL: `https://api.talonic.com/v1/parties/{id}/directory-link`
- Auth: HTTP bearer

Links the party to an entry of the workspace's active CRM directory by its `external_id`, or unlinks it with `external_id` null. A link set by a person stays. The CRM's name is added as a confirmed alias when it differs, and the rows the party holds a role on are filled again in the background.

## Path parameters

- `id` string, uuid, required

## Request body

- object
  - `external_id` string, nullable: The entry's id in the CRM; null unlinks.
  - `kind` 'company' | 'contact': The kind of entry; a person links to a contact and every other party to a company when omitted.

## Response `201`

The party's link.

- PartiesDirectoryLink: A party's link to an entry of the workspace's CRM directory.
  - `state` 'linked' | 'none' | 'pick': `pick`: several entries fit and a person picks one of `candidates`.
  - `kind` 'company' | 'contact', nullable
  - `external_id` string, nullable
  - `how` 'exact' | 'postcode' | 'fuzzy' | 'person' | 'id', nullable
  - `candidates` string[]
  - `odd_address` boolean: The directory's address differs clearly from the contract's.
  - `address_choice` 'crm' | 'document', nullable
  - `at` string, date-time
  - `by` string: `link` when the automatic linking set it.

## Other responses

- `400`: The request is invalid.
- `401`: Missing or invalid API key.
- `403`: The API key does not have the required scope.
- `404`: The party was not found, or no such entry is in the active directory.

## Changes

- **2026-11-26** `622d429de7ea`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/talonic/apis/talonic-api/changes/v1/parties/:id/directory-link/post.md)

---

[API](https://skmtc.dev/talonic/apis/talonic-api.md) - [All operations](https://skmtc.dev/talonic/apis/talonic-api/llms.txt) - [OpenAPI document](https://skmtc.dev/talonic/apis/talonic-api/revisions/9f6d53e2ab5e?raw)
