---
title: "Create a contact"
method: POST
path: "/companies/{company}/contacts"
tags: ["Contacts"]
---

# Create a contact

`POST /companies/{company}/contacts`

## Request

- Base URL: `https://api.factuarea.com/v1`
- URL: `https://api.factuarea.com/v1/companies/{company}/contacts`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Create one canonical contact with no role or any combination of `customer`, `supplier` and `lead`; the response `id` is a UUID v7.
- A repeated `Idempotency-Key` replays the original response without duplicating the contact.
- An existing `external_id` is updated idempotently within the company.

## Path parameters

- `company` string, uuid, required

## Headers

- `Idempotency-Key` string
- `Factuarea-Version` string, date

## Request body

- CreateBusinessContactV1Request
  - `name` string, required
  - `kind` 'person' | 'company', required
  - `tax_id` string, nullable
  - `alternative_id_type` 'nif_iva' | 'passport' | 'country_id' | 'residence_certificate' | 'other_document' | 'not_registered' | 'national_id' | 'tax_id_foreign' | 'null', nullable
  - `alternative_id_value` string, nullable
  - `alternative_id_country_code` 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AQ' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AX' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BV' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'EH' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GS' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HM' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IO' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TF' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'UM' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW' | 'null', nullable
  - `vat_id` string, nullable
  - `business_name` string, nullable
  - `commercial_name` string, nullable
  - `address` object
    - `line_1` string, nullable
    - `line_2` string, nullable
    - `number` string, nullable
    - `floor` string, nullable
    - `door` string, nullable
    - `staircase` string, nullable
    - `city` string, nullable
    - `province` string, nullable
    - `postal_code` string, nullable
    - `country_code` 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AQ' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AX' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BV' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'EH' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GS' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HM' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IO' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TF' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'UM' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW' | 'null', nullable
  - `contact_person` string, nullable
  - `email` string, email, nullable
  - `phone` string, nullable
  - `mobile` string, nullable
  - `fax` string, nullable
  - `website` string, uri, nullable
  - `billing_emails` string[]
  - `tags` string[]
  - `notes` string, nullable
  - `metadata` Metadata, nullable: A free map of up to 50 key→value pairs for storing arbitrary structured data (values are strings up to 500 characters). Unlike `custom_fields` — an ordered list of typed `{field, value}` pairs with display semantics, present on the six document resources — `metadata` is an unordered map for opaque integration data; a document may carry both. The master resources (Client, Supplier) have no `custom_fields`, so their `metadata` doubles as the custom-fields store. **Reserved keys (read-only).** When the system auto-issues an invoice from a payment correlation (Stripe/GoCardless/MONEI), it writes `stripe_subscription_id`, `stripe_invoice_id`, `billing_reason`, `period_start` and `period_end` into that invoice metadata automatically. Do not set or overwrite them by hand — the platform owns them and a manual value may be replaced when the correlation runs.
  - `accumulate_347` boolean
  - `external_id` string, nullable
  - `latitude` number, nullable
  - `longitude` number, nullable
  - `customer_profile` object
    - `default_price_list_uuid` string, uuid, nullable: Public identifier (UUID v7) of an active price list of your company applied by default to this customer, or `null`.
    - `discount` number, nullable
    - `vat_rate` number, nullable
    - `retention_rate` number, nullable
    - `surcharge_subject` boolean
    - `operation_regime` 'general' | 'intracomunitaria' | 'importacion_exportacion' | 'isp' | 'null', nullable
    - `payment_method` 'bank_transfer' | 'direct_debit' | 'sepa_direct_debit' | 'cash' | 'credit_card' | 'check' | 'paypal' | 'bizum' | 'other' | 'null', nullable
    - `payment_terms_days` integer, nullable: Payment term in days (0-365). For a new contact, omitted or null means 30 days; an explicit 0 means immediate payment. For an existing contact upsert, an omitted profile is preserved and a supplied profile replaces its defaults.
    - `dir3_accounting_office` string, nullable
    - `dir3_managing_body` string, nullable
    - `dir3_processing_unit` string, nullable
  - `supplier_profile` object
    - `default_tax_uuid` string, uuid, nullable
    - `discount` number, nullable
    - `vat_rate` number, nullable
    - `retention_rate` number, nullable
    - `surcharge_subject` boolean
    - `operation_regime` 'general' | 'intracomunitaria' | 'importacion_exportacion' | 'isp' | 'null', nullable
    - `payment_method` 'bank_transfer' | 'direct_debit' | 'sepa_direct_debit' | 'cash' | 'credit_card' | 'check' | 'paypal' | 'bizum' | 'other' | 'null', nullable
    - `payment_terms_days` integer, nullable: Payment term in days (0-365). For a new contact, omitted or null means 30 days; an explicit 0 means immediate payment. For an existing contact upsert, an omitted profile is preserved and a supplied profile replaces its defaults.
  - `roles` string[], required
  - `bank_accounts` object[]
    - `iban` string, required
    - `bic` string, nullable
    - `notes` string, nullable
    - `collection` boolean
    - `payment` boolean
    - `is_default_collection` boolean
    - `is_default_payment` boolean

## Response `200`

The `external_id` already identified a contact of the company: that contact was updated with the request, keeps its `id` and is returned.

- object
  - `data` BusinessContact, required: A canonical business contact with cumulative customer, supplier and fiscal lead roles, or no assigned role. The fiscal lead role requires the same fiscal identity as other contacts; pre-fiscal opportunities belong to the separately planned CRM.
    - `id` string, uuid, required: Public UUID v7. Internal numeric keys are never exposed.
    - `object` 'contact', required
    - `kind` 'company' | 'person', required
    - `name` string, required
    - `business_name` string, nullable, required
    - `commercial_name` string, nullable, required
    - `tax_id` string, nullable, required
    - `vat_id` string, nullable, required
    - `alternative_id` AlternativeId, required: Alternative tax identification for non-Spanish clients. Mutually exclusive with `tax_id` (NIF/CIF/NIE).
      - `object` 'alternative_id', required
      - `type` 'nif_iva' | 'passport' | 'country_id' | 'residence_certificate' | 'other_document' | 'not_registered' | 'tax_id_foreign' | 'national_id', required: AEAT IDType (lista L7): nif_iva, passport, country_id, residence_certificate, other_document or not_registered. The legacy values `tax_id_foreign` and `national_id` are accepted on input and normalized.
      - `value` string, required: Identifier value (free-form string, 1-50 characters).
      - `country_code` string, required: ISO 3166-1 alpha-2 country code in uppercase (other than `ES`).
    - `address` object, required
      - `line1` string, nullable, required
      - `line2` string, nullable, required
      - `number` string, nullable, required
      - `floor` string, nullable, required
      - `door` string, nullable, required
      - `staircase` string, nullable, required
      - `city` string, nullable, required
      - `province` string, nullable, required
      - `postal_code` string, nullable, required
      - `country` string, required
    - `contact_person` string, nullable, required
    - `email` string, email, nullable, required
    - `phone` string, required: Permissive international phone number: optional `+`, digits, spaces, hyphens and parentheses (6..20 characters).
    - `mobile` string, nullable, required
    - `fax` string, nullable, required
    - `website` string, uri, nullable, required
    - `billing_emails` string[], required
    - `tags` string[], required
    - `coordinates` object, nullable, required: Geographic coordinates. Each axis is nullable independently; the object is null only when neither axis is recorded.
      - `latitude` number, float, nullable, required
      - `longitude` number, float, nullable, required
    - `notes` string, nullable, required
    - `metadata` Metadata, nullable, required: A free map of up to 50 key→value pairs for storing arbitrary structured data (values are strings up to 500 characters). Unlike `custom_fields` — an ordered list of typed `{field, value}` pairs with display semantics, present on the six document resources — `metadata` is an unordered map for opaque integration data; a document may carry both. The master resources (Client, Supplier) have no `custom_fields`, so their `metadata` doubles as the custom-fields store. **Reserved keys (read-only).** When the system auto-issues an invoice from a payment correlation (Stripe/GoCardless/MONEI), it writes `stripe_subscription_id`, `stripe_invoice_id`, `billing_reason`, `period_start` and `period_end` into that invoice metadata automatically. Do not set or overwrite them by hand — the platform owns them and a manual value may be replaced when the correlation runs.
    - `accumulate_347` boolean, required
    - `external_id` string, nullable, required
    - `roles` object[], required
      - `role` 'customer' | 'supplier' | 'lead', required
      - `status` 'active' | 'inactive', required
      - `assigned_at` string, date-time, required
      - `deactivated_at` string, date-time, nullable, required
    - `bank_accounts` object[], required
      - `iban` string, required
      - `bic` string, nullable, required
      - `notes` string, nullable, required
      - `can_collect` boolean, required
      - `can_pay` boolean, required
      - `is_default_collection` boolean, required
      - `is_default_payment` boolean, required
    - `customer_profile` object, nullable, required
      - `default_price_list_uuid` string, uuid, nullable, required
      - `default_discount` number, float, nullable, required
      - `default_vat_rate` number, float, nullable, required
      - `default_retention_rate` number, float, nullable, required
      - `is_surcharge_subject` boolean, required
      - `preferred_operation_regime` string, nullable, required
      - `payment_method` string, nullable, required
      - `payment_terms_days` integer, nullable, required
      - `dir3_accounting_office` string, nullable, required
      - `dir3_managing_body` string, nullable, required
      - `dir3_processing_unit` string, nullable, required
    - `supplier_profile` object, nullable, required
      - `default_taxes_uuid` string, uuid, nullable, required
      - `default_discount` number, float, nullable, required
      - `default_vat_rate` number, float, nullable, required
      - `default_retention_rate` number, float, nullable, required
      - `is_surcharge_subject` boolean, required
      - `preferred_operation_regime` string, nullable, required
      - `payment_method` string, nullable, required
      - `payment_terms_days` integer, nullable, required
    - `financial_summary` object, required: Directional sales and purchases totals for this contact, as 2-decimal strings. Amounts use the currency declared in each direction.
      - `sales` object, required
        - `invoiced_amount` string, required
        - `collected_amount` string, required
        - `receivable_amount` string, required
        - `currency` string, required
      - `purchases` object, required
        - `purchased_amount` string, required
        - `paid_amount` string, required
        - `payable_amount` string, required
        - `currency` string, required
    - `latest_activity` object, nullable, required: Most recent sales or purchases movement, or `null` when the contact has no financial activity.
      - `type` 'sales_invoice' | 'collection' | 'purchase_invoice' | 'payment', required
      - `direction` 'sales' | 'purchases', required
      - `amount` string, required
      - `currency` string, required
      - `occurred_at` string, date-time, required
      - `related_resource_uuid` string, uuid, required
    - `is_archived` boolean, required
    - `archived_at` string, date-time, nullable, required
    - `created_at` string, date-time, required
    - `updated_at` string, date-time, required

## Other responses

- `201`: Contact created. The `Location` header contains the canonical URL of the new contact.
- `400`: The request is syntactically malformed — e.g. an unknown query parameter, an integer parameter with non-numeric value, or a value outside the documented range. `parameter_unknown` with `subcode` `retired_active_profile_header`: the retired `X-Active-Profile` header was sent; the company goes in the path. `parameter_invalid_format` on `Factuarea-Version`: the header is not a `YYYY-MM-DD` date. `unsupported_api_version`: the `Factuarea-Version` date is not a supported version.
- `401`: Missing or invalid API key.
- `403`: The request is authenticated but not allowed: the API key lacks the required scope (`insufficient_scope`), the plan does not include the public API or this feature (`addon_not_active`, `feature_not_available_in_plan`), or the module is not available with a test key (`module_not_available_in_sandbox`). `company_inactive`: the company in the path is deactivated; reactivate it to operate.
- `404`: The requested resource does not exist or belongs to another company. `profile_not_found`: the company in the path does not exist, is not in the API key scope or belongs to the other environment (live or test).
- `409`: The request conflicts with data that already exists or with a request running at the same time. `resource_already_exists` with `subcode` `tax_id_already_exists`: another contact of the company already has that fiscal identity; `details.existing_resource_id` is its identifier. `resource_conflict`: another request was reserving identifiers for the same kind of record at that moment and this one could not complete its reservation. Nothing was written; send the request again after a few seconds.
- `422`: Validation failed. The `error.param` field identifies which input is invalid. `idempotency_key_reused`: the `Idempotency-Key` was already used with a different body; send a new key or the same body. `invalid_param_format` on `Idempotency-Key`: the key must be 1 to 255 printable ASCII characters.
- `429`: Rate limit exceeded. Retry after the duration in `Retry-After`.
- `500`: Unexpected server error.

---

[API](https://skmtc.dev/factuarea/apis/factuarea-public-api.md) · [All operations](https://skmtc.dev/factuarea/apis/factuarea-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/factuarea/apis/factuarea-public-api/revisions/718e77934422?raw)
