Create invoice

To create invoices you POST an Invoice object to a pre-configured contract ID.

  • your-authorization should be replaced with your Authorization header, see Access
info

Values should be limited to character encoding ISO-8859-1

Example Request

Copy
Copied
POST /v1/invoices/$(contract-id)

Accept: application/json
Authorization: $(your-authorization)


{
  "invoiceNumber": 12345,
  "technicalReference": "ref 2323132",
  "currencyCode": "SEK",
  "invoiceDate": "2019-01-01",
  "dueDate": "2019-01-30",
  "invoiceReference": "John Doe",
  "customer": {
    "customerNumber": 12345,
    "customerName": "my customer",
    "attention": "John Doe",
    "streetAddress": "Street 1",
    "zipCode": 12345,
    "city": "Stockholm",
    "countryCode": "SE",
    "identityNumber": "5522113131",
    "phoneNumber": "0712345678",
    "ourReference": "John Doe",
    "languageCode": "SV",
    "vatNr": "SE552211313101"
  },
  "distribution": {
    "method": "EMAIL",
    "emailAddress": "my@email.com"
  },
  "rows": [
    {
      "sku": "123",
      "description": "Rent for December",
      "quantity": 1,
      "unit": null,
      "netUnitPrice": 10.00,
      "discountPercent": null,
      "vatPercent": 25.00,
      "accountNumber": 1510,
      "costCenter": "1",
      "activityCode": "123"
    },
    {
      "type": "TEXT",
      "text": "Happy x-Mas"
    }
  ]
}

Successful Response

Copy
Copied
{
    "id": "1d73c81d-39a6-44d1-bb45-69f6a49afa96",
    "status": "CREATED"
}

Unsuccessful Response

Copy
Copied
{
    "status": "ERROR",
    "statusDescription": "No invoice rows supplied"
}
info

To see the end result of the created invoice please contact Svea at wallet.integration@svea.com