Create a contact
contacts:contacts.writehttps://api.holded.com/api/v2/contactsCreates a new contact in your account. Contacts represent the people and companies you do business with — customers, suppliers, leads, debtors, or creditors. At minimum you must provide a `name`. The `type` field controls how the contact appears in your accounting (e.g. client, supplier). If omitted, the contact is created without a type and can be classified later. The response returns the new contact `id`. Use it to create invoices, purchases, or any other document linked to this contact.
Request body
Contact full name or company name
Tax identification number (NIF, CIF, etc.)
EU VAT number
Commercial or trade name, if different from legal name
True if the contact is an individual, false if a company
Email address. Several can be sent separated by commas or semicolons: the first is the primary, the rest are returned in `extra_emails`. Invalid ones are ignored (400 if none is valid).
Landline phone number
Mobile phone number
Website URL
Contact classification
clientdebtorsuppliercreditorleadNumber of the accounting account (chart of accounts) used when this contact acts as a client
Number of the accounting account (chart of accounts) used when this contact acts as a supplier
IBAN bank account number
SWIFT/BIC code of the bank
SEPA mandate reference for direct debit collections
Date the SEPA direct debit mandate was signed
Fiscal operation type of the contact (e.g. general, intra, receq, exento). Must be one of the operations defined by the account tax scheme
Billing address
Street address
City
Postal or ZIP code
Province or state
Country name
ISO 3166-1 alpha-2 country code
Additional address information
Shipping addresses of the contact
Label for this shipping address
Street address
City name
Postal or ZIP code
State or province
Country name
ISO 3166-1 alpha-2 country code
Public notes about this address
Internal notes not visible to the contact
Social network profiles of the contact. `website` is also used as the contact website when the top-level `website` is not sent
Handle or URL for `facebook`
Handle or URL for `twitter`
Handle or URL for `instagram`
Handle or URL for `google`
Handle or URL for `linkedin`
Handle or URL for `pinterest`
Handle or URL for `foursquare`
Handle or URL for `youtube`
Handle or URL for `vimeo`
Handle or URL for `wordpress`
Handle or URL for `website`
Tags attached to the contact
Internal notes attached to the contact.
Identifier of an existing note to update. Omit it to create a new note
Title of the note
Content of the note
Color label of the note
User-defined custom fields
Custom field identifier
Value stored in the custom field
Default settings applied to documents created for this contact
Default sales channel identifier
Default expenses accounting account
Default payment due days
Default fixed payment day of the month
Default payment method identifier
Default discount percentage
Default document language code
Default currency code
Default sales tax keys applied to sales documents
Default purchases tax keys applied to purchase documents
Whether the contact accumulates in tax form 347. Defaults to true when omitted.
Default numbering series applied to new documents of each type created for this contact. Each value must be a valid numbering series ID; invalid or unrecognized IDs are silently ignored (stored as null).
Request
import requests
url = "https://api.holded.com/api/v2/contacts"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Accept": "application/json",
}
payload = {
"name": "string",
"code": "string",
"vat_number": "string",
"trade_name": "string",
"is_person": false,
"email": "string",
"phone": "string",
"mobile": "string",
"website": "string",
"type": [
"client",
"supplier",
"debtor",
"creditor",
"lead"
],
"client_record": 0,
"supplier_record": 0,
"iban": "string",
"swift": "string",
"sepa_ref": "string",
"sepa_date": "2024-01-15",
"tax_operation": "string",
"bill_address": {
"address": "string",
"city": "string",
"postal_code": "string",
"province": "string",
"country": "string",
"country_code": "ES",
"info": "string"
},
"shipping_addresses": [
{
"name": "string",
"address": "string",
"city": "string",
"postal_code": "string",
"province": "string",
"country": "string",
"country_code": "string",
"notes": "string",
"private_notes": "string"
}
],
"social_networks": {
"facebook": "string",
"twitter": "string",
"instagram": "string",
"google": "string",
"linkedin": "string",
"pinterest": "string",
"foursquare": "string",
"youtube": "string",
"vimeo": "string",
"wordpress": "string",
"website": "string"
},
"tags": [
"string"
],
"notes": [
{
"note_id": "string",
"name": "string",
"description": "string",
"color": "string"
}
],
"custom_fields": [
{
"field": "string",
"value": {}
}
],
"defaults": {
"sales_channel": "string",
"expenses_account": "string",
"due_days": 0,
"payment_day": 0,
"payment_method": "string",
"discount": 0,
"language": "string",
"currency": "EUR",
"sales_tax": [
"string"
],
"purchases_tax": [
"string"
],
"accumulate_in_form_347": false,
"numbering_series": {
"invoice": "string",
"receipt": "string",
"salesorder": "string",
"estimate": "string",
"order": "string",
"proform": "string",
"waybill": "string"
}
}
}
response = requests.post(url, headers=headers, json=payload)
print(response.json())Responses
Response
{
"id": "507f1f77bcf86cd799439011"
}Success responses
201Contact createdapplication/jsonError responses
400Bad requestapplication/json401Invalid or missing API keyapplication/json403Insufficient permissionsapplication/json422Validation errorapplication/json429Rate limit exceededapplication/json