v1

latestOpenAPI 3.0.32026-07-268955212.1 KB
customers

Create a customer

Creates a customer for the company.

Scope: customers:write

post/companies/{companyId}/customers

Request body

idstring uuid
namestring required
type'company' | 'private' required
vatNumberstring
orgNumberstring
paymentTermsstring

Payment terms for the invoices. Payment terms can both take free text or days, in digits, until the payment is due.

On the invoice, if a digit is provided it will be suffixed with "days". For example, "30" will be displayed as "30 days" on the invoice. Note that the suffix will, similar to the rest of the invoice, use the language on the customer.

language'sv' | 'en'

Default 'sv'

modifiedDateTimestring date-time nullable

The date and time the customer was last modified. Returns null for customers that were changed before this field was introduced.

Example request

{
  "id": "55c899c5-82b2-47fa-9c51-e35fc9b26443",
  "name": "customer 1",
  "type": "company",
  "vatNumber": "SE1234567890",
  "orgNumber": "123456-7890",
  "paymentTerms": "30",
  "contactsDetails": [
    {
      "name": "John Doe",
      "email": "john@email.com",
      "phone": "0927-5631505",
      "isDefault": true
    }
  ],
  "address": {
    "line1": "Älvsborgsvägen 10",
    "line2": null,
    "city": "Göteborg",
    "postalCode": "123 45",
    "country": "SE"
  },
  "language": "sv",
  "modifiedDateTime": "2024-10-10T00:00:00Z"
}

Response

Customer created

idstring uuid
namestring required
type'company' | 'private' required
vatNumberstring
orgNumberstring
paymentTermsstring

Payment terms for the invoices. Payment terms can both take free text or days, in digits, until the payment is due.

On the invoice, if a digit is provided it will be suffixed with "days". For example, "30" will be displayed as "30 days" on the invoice. Note that the suffix will, similar to the rest of the invoice, use the language on the customer.

language'sv' | 'en'

Default 'sv'

modifiedDateTimestring date-time nullable

The date and time the customer was last modified. Returns null for customers that were changed before this field was introduced.

Example response

{
  "id": "55c899c5-82b2-47fa-9c51-e35fc9b26443",
  "name": "customer 1",
  "type": "company",
  "vatNumber": "SE1234567890",
  "orgNumber": "123456-7890",
  "paymentTerms": "30",
  "contactsDetails": [
    {
      "name": "John Doe",
      "email": "john@email.com",
      "phone": "0927-5631505",
      "isDefault": true
    }
  ],
  "address": {
    "line1": "Älvsborgsvägen 10",
    "line2": null,
    "city": "Göteborg",
    "postalCode": "123 45",
    "country": "SE"
  },
  "language": "sv",
  "modifiedDateTime": "2024-10-10T00:00:00Z"
}