Skip to main content

Introduction

The objective of this guide is to walk you through the process of generating a simple PDF invoice you can send to your customers. This is valid for tax regimes that donโ€™t require any electronic reporting or invoicing, and serves as a useful example from which to create your own workflows. Once completed, the workflow will work with any GOBL invoice produced for any country in the world.
Example of a PDF invoice

Prerequisites

Youโ€™ll need the following data to issue basic PDF invoices:
  • Supplier details: fiscal details of the issuer.
  • Customer details: fiscal details of who is receiving for B2B invoices.
  • Items: list of products or services being sold, including quantities and prices.
  • Taxes & Rates: knowing how these apply to each item.
  • Series: a series is a counter with number formatting details to be able to generate a code.

Setup

Issuing PDF invoices with Invopop requires very little preparation. We assume that you already have access to the Invopop Console and know how to create a workflow.

Configuration options

Once you have connected the โ€œPDF Generatorโ€ app, you can configure the โ€œGenerate PDFโ€ workflow step. The following options are available.
Generate PDF logo
Upload logoUpload an image which will be used as a logo in the document. A square or horizontal logo layout in PNG format is recommended. If you need to upload a different logo for each supplier, include the logos field in the party entry as detailed in the FAQ.
Logo heightHeight for the logo in pixels. Thereโ€™s 72 pixels in an inch and 37 pixels in a centimeter. The default height is 40 pixels (a little over 1cm)
Generate PDF locale
LocaleSets the language and formatting conventions used in the PDF. We add new locales based on the demand of our customers.
Date formatControls how dates are displayed. Options include: YYYY-MM-DD, DD-MM-YYYY, MM-DD-YYYY, DD.MM.YYYY, MM.DD.YYYY
LayoutDefines the physical page size for regional printing standards. Options include:
  • A4: used in Europe and various other countries.
  • Letter: used in United States, Canada, Mexico, Philippines, and other countries in Latin America.
  • DIN5008: used in Germany as the standard for documents that will present information within an envelope window. If you select this option, the customerโ€™s information (name and address) will be placed within this window.
Generate PDF visual markers
Title badgeContextual labels such as โ€œoriginalโ€, โ€œcopyโ€, โ€œdraftโ€, or โ€œinternalโ€
Background watermarkText that will be displayed in the background of the document such as โ€œdraftโ€, โ€œreviewโ€, โ€œinternalโ€, โ€œconfidentialโ€, etc.
Generate PDF formatting
Currency formatting is a dedicated section allows overriding the default currency formatting normally dictated by the documentโ€™s own currency.
Currency templateWhether the currency symbol should be before or after the number, e.g. โ‚ฌ100 or 100โ‚ฌ.
Format for negative valuesWhether the negative sign should be before or after the number, e.g. โ‚ฌ-100 or -โ‚ฌ100. Parenthesis - โ‚ฌ(100) can also be used according to some accounting standards.
Thousands separatorSeparator to improve the readability of the number, e.g. 1,000, 1.000, 1 000 or 1_000.
Decimal markSeparator for the decimal part of the number, e.g. 1.00 or 1,00.
Generate PDF checkboxes
Adjustment invoicesToggle to generate โ€œadjustment invoicesโ€ using negative values instead of traditional credit and debit notes. Useful for countries that donโ€™t officially recognise the concept of credit or debit notes such as Spain and Poland as detailed in the FAQ.
Hide โ€œPowered by Invopopโ€Toggle to hide the โ€œPowered by Invopopโ€ attribution. This setting does not remove the GOBL logo from the PDF.
Disable public download URLsSecurity control to disable the creation of public download URLs for generated PDFs, preventing external sharing via link.

Running

Use the following example GOBL Invoices inside the Invopop Console or via the API to create new silo entries. Once a silo entry has been stored, you can create a new job to run the โ€œPDF Invoiceโ€ workflow you just created.

B2B Invoice - United Kingdom

A simple invoice for a VAT registered supplier in the United Kingdom
{
  "$schema": "https://gobl.org/draft-0/bill/invoice",
  "currency": "GBP",
  "series": "TEST",
  "supplier": {
    "tax_id": {
      "country": "GB",
      "code": "844281425"
    },
    "name": "BrightTech Solutions Ltd.",
    "emails": [
      {
        "addr": "[email protected]"
      }
    ],
    "addresses": [
      {
        "num": "123",
        "street": "Innovation Park",
        "locality": "Cambridge",
        "code": "CB1 2AB",
        "country": "GB"
      }
    ]
  },
  "customer": {
    "tax_id": {
      "country": "GB",
      "code": "350983637"
    },
    "name": "GreenWave Energy Ltd.",
    "emails": [
      {
        "addr": "[email protected]"
      }
    ],
    "addresses": [
      {
        "num": "45",
        "street": "Riverside Business Park",
        "locality": "London",
        "code": "SW1A 1AA",
        "country": "GB"
      }
    ]
  },
  "lines": [
    {
      "quantity": 50,
      "item": {
        "name": "Thermal efficient mugs",
        "price": "16.00"
      },
      "taxes": [
        {
          "cat": "VAT",
          "rate": "standard"
        }
      ]
    }
  ]
}

B2B Invoice - United States

Simple invoice for a VAT registered supplier in the United States
{
  "$schema": "https://gobl.org/draft-0/bill/invoice",
  "series": "SAMPLE",
  "currency": "USD",
  "tax": {
    "prices_include": "ST"
  },
  "supplier": {
    "name": "Provide One Inc.",
    "tax_id": {
      "country": "US"
    },
    "addresses": [
      {
        "num": "16",
        "street": "Jessie Street",
        "locality": "San Francisco",
        "region": "CA",
        "code": "94105",
        "country": "US"
      }
    ],
    "emails": [
      {
        "addr": "[email protected]"
      }
    ]
  },
  "customer": {
    "name": "Sample Consumer",
    "emails": [
      {
        "addr": "[email protected]"
      }
    ]
  },
  "lines": [
    {
      "i": 1,
      "quantity": "20",
      "item": {
        "name": "Development services",
        "price": "90.00",
        "unit": "h"
      },
      "discounts": [
        {
          "percent": "10%",
          "reason": "Special discount"
        }
      ],
      "taxes": [
        {
          "cat": "ST",
          "percent": "8.5%"
        }
      ]
    }
  ]
}

FAQ

Add them within the supplier object within a logos array, here is an example:
    "supplier": {
        "name": "Invopop SL",
        "tax_id": {
            "country": "ES",
            "code": "B85905495"
        },
        "logos": [
            {
                "url": "https://ams3.digitaloceanspaces.com/invopop-console-files-dev/9acccd03a8258818cadbfce3e32e67af1e7ff826deb2e6ec66c9cdc6fc8f24a1$0",
                "height": 100,
                "width": 100
            }
        ]
    }
Make sure your image is publicly accessible. Sometimes server restrictions prevent our services from accessing the image. An easy way to verify this is by asking ChatGPT โ€œis this URL https://โ€ฆ publicly accesible?โ€
Spain, along with a very small selection of other countries like Poland, doesnโ€™t officially recognise the concept of credit or debit notes. Instead they use the concept of corrective or adjustment invoices whereby the amounts are displayed as differences from the original document. The two main types are:
  • Replacement Invoice (Factura Rectificativa por Sustituciรณn) known in GOBL with the invoice type corrective and completely replaces any previous documents.
  • Adjustment Invoice (Factura Rectificativa por Diferencias) reflected in GOBL as either a credit-note or debit-note invoice type that appends to the previous documents.
GOBL is a designed to be an international format, so when deciding the types we try to take the most common business concepts and map them to local requirements. A credit note by definition implies a deduction from the preceding invoice, so all totals and values must be positive. This can cause confusion in Spain, where most companies are accustomed to the local way of issuing invoices with negative totals.When converting GOBL to the local tax agency format (like VERI*FACTU XML in Spain), Invopop will automatically inverts the values in a credit-note to ensure that the agency receives what they are expecting, while at the same time maintaining global compatibility in the actual document. With these changes, PDF can now apply the same logic to invert the totals and change the text translations while maintaining the same underlying information.

Participate in our community

Ask and answer questions about PDF invoices โ†’