Skip to main content
PUT
/
api
/
external
/
v2
/
quotes
/
{id}
Update a quote
curl --request PUT \
  --url https://app.pennylane.com/api/external/v2/quotes/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "date": "2023-08-30",
  "deadline": "2024-08-30",
  "customer_id": 42,
  "quote_template_id": 42,
  "pdf_invoice_free_text": "Additional free field",
  "pdf_invoice_subject": "Quote title",
  "pdf_description": "Quote description",
  "currency": "<string>",
  "special_mention": "Additional details",
  "discount": {
    "type": "absolute",
    "value": "25"
  },
  "language": "fr_FR",
  "invoice_lines": {
    "create": [
      {
        "label": "Demo label",
        "quantity": 12,
        "discount": {
          "type": "absolute",
          "value": "25"
        },
        "ledger_account_id": 1255,
        "raw_currency_unit_price": "33.333334",
        "unit": "piece",
        "vat_rate": "FR_200",
        "description": "<string>",
        "product_id": 42,
        "section_rank": 1
      }
    ],
    "update": [
      {
        "id": 42,
        "label": "Demo label",
        "quantity": 12,
        "ledger_account_id": 1255,
        "raw_currency_unit_price": "33.333334",
        "unit": "piece",
        "vat_rate": "FR_200",
        "description": "<string>",
        "product_id": 42,
        "discount": {
          "type": "absolute",
          "value": "25"
        },
        "section_rank": 1
      }
    ],
    "delete": [
      {
        "id": 42
      }
    ]
  },
  "external_reference": "FR123"
}'
{
  "id": 42,
  "label": "Quote label",
  "quote_number": "PLERYGTXYOIMZZ",
  "currency": "EUR",
  "amount": "230.32",
  "currency_amount": "230.32",
  "currency_amount_before_tax": "196.32",
  "exchange_rate": "1.0",
  "date": "2020-01-01",
  "deadline": "2020-12-31",
  "currency_tax": "34.0",
  "tax": "34.0",
  "language": "fr_FR",
  "status": "pending",
  "discount": {
    "type": "absolute",
    "value": "25"
  },
  "public_file_url": "https://app.pennylane.com/public/quote/pdf?encrypted_id=bzjoVJe...3D%3D",
  "filename": "my_file.pdf",
  "special_mention": "Additional details",
  "customer": {
    "id": 42,
    "url": "https://app.pennylane.com/api/external/v2/customers/42"
  },
  "invoice_line_sections": {
    "url": "https://app.pennylane.com/api/external/v2/quotes/42/invoice_line_sections"
  },
  "invoice_lines": {
    "url": "https://app.pennylane.com/api/external/v2/quotes/42/invoice_lines"
  },
  "linked_invoices": {
    "url": "https://app.pennylane.com/api/external/v2/customer_invoices?filter=%5B%7B%22field%22%3A%22quote_id%22%2C%22operator%22%3A%22eq%22%2C%22value%22%3A1927271459%7D%5D"
  },
  "pdf_invoice_free_text": "Quote details",
  "pdf_invoice_subject": "Quote subject",
  "pdf_description": "Quote description",
  "quote_template": {
    "id": 123
  },
  "appendices": {
    "url": "https://app.pennylane.com/api/external/v2/quotes/42/appendices"
  },
  "external_reference": "FR123",
  "archived_at": "2023-08-30T10:08:08.146343Z",
  "created_at": "2023-08-30T10:08:08.146343Z",
  "updated_at": "2023-08-30T10:08:08.146343Z"
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

id
integer
required

Body

application/json
date
string<date>

Quote date (ISO 8601)

Example:

"2023-08-30"

deadline
string<date>

Quote validity deadline (ISO 8601)

Example:

"2024-08-30"

customer_id
integer

Customer identifier

Example:

42

quote_template_id
integer

The quote template ID

Example:

42

pdf_invoice_free_text
string | null

For example, the contact details of the person to contact

Example:

"Additional free field"

pdf_invoice_subject
string | null

Quote title

Example:

"Quote title"

pdf_description
string | null

Quote description

Example:

"Quote description"

currency
string

Quote Currency (ISO 4217). Default is EUR.

special_mention
string | null

Additional details

Example:

"Additional details"

discount
object
language
enum<string>
default:fr_FR
Available options:
fr_FR,
en_GB
invoice_lines
object

Add, update, delete invoice lines.

external_reference
string

The unique external reference that was assigned during creation either by you or Pennylane.

Example:

"FR123"

Response

A quote

id
integer
required

Quote identifier

Example:

42

label
string | null
required
Example:

"Quote label"

quote_number
string
required
Example:

"PLERYGTXYOIMZZ"

currency
enum<string>
default:EUR
required
Available options:
EUR,
USD,
GBP,
AED,
AFN,
ALL,
AMD,
ANG,
AOA,
ARS,
AUD,
AWG,
AZN,
BAM,
BBD,
BDT,
BGN,
BHD,
BIF,
BMD,
BND,
BOB,
BRL,
BSD,
BTN,
BWP,
BYN,
BYR,
BZD,
CAD,
CDF,
CHF,
CLF,
CLP,
CNY,
COP,
CRC,
CUC,
CUP,
CVE,
CZK,
DJF,
DKK,
DOP,
DZD,
EGP,
ERN,
ETB,
FJD,
FKP,
GEL,
GGP,
GHS,
GIP,
GMD,
GNF,
GTQ,
GYD,
HKD,
HNL,
HRK,
HTG,
HUF,
IDR,
ILS,
IMP,
INR,
IQD,
IRR,
ISK,
JEP,
JMD,
JOD,
JPY,
KES,
KGS,
KHR,
KMF,
KPW,
KRW,
KWD,
KYD,
KZT,
LAK,
LBP,
LKR,
LRD,
LSL,
LTL,
LVL,
LYD,
MAD,
MDL,
MGA,
MKD,
MMK,
MNT,
MOP,
MRO,
MUR,
MVR,
MWK,
MXN,
MYR,
MZN,
NAD,
NGN,
NIO,
NOK,
NPR,
NZD,
OMR,
PAB,
PEN,
PGK,
PHP,
PKR,
PLN,
PYG,
QAR,
RON,
RSD,
RUB,
RWF,
SAR,
SBD,
SCR,
SDG,
SEK,
SGD,
SHP,
SLL,
SOS,
SRD,
STD,
SVC,
SYP,
SZL,
THB,
TJS,
TMT,
TND,
TOP,
TRY,
TTD,
TWD,
TZS,
UAH,
UGX,
UYU,
UZS,
VEF,
VND,
VUV,
WST,
XAF,
XCD,
XDR,
XOF,
XPF,
YER,
ZAR,
ZMK,
ZMW,
ZWL
amount
string
required

Quote amount (total value of the quote in euros. If the currency is euro, currency_amount and amount are identical)

Example:

"230.32"

currency_amount
string
required

Quote currency amount (total value of the quote in the currency of the quote)

Example:

"230.32"

currency_amount_before_tax
string
required

Quote currency amount before tax (total value before tax of the quote in the currency of the quote)

Example:

"196.32"

exchange_rate
string
required

Quote exchange rate (used to convert the quote to euros. If the quote currency is euro it will be 1.0)

Example:

"1.0"

date
string<date> | null
required

Quote issue date (ISO 8601)

Example:

"2020-01-01"

deadline
string | null
required

Quote expiration deadline (ISO 8601)

Example:

"2020-12-31"

currency_tax
string
required

Quote taxable amount (in quote currency)

Example:

"34.0"

tax
string
required

Quote taxable amount (in quote currency)

Example:

"34.0"

language
enum<string>
default:fr_FR
required
Available options:
fr_FR,
en_GB
status
enum<string>
required
  • accepted: quote has been accepted
  • denied: quote has been denied
  • expired: quote has expired
  • invoiced: quote has been invoiced
  • pending: quote to be denied or accepted
Available options:
pending,
accepted,
denied,
invoiced,
expired
discount
object
required
public_file_url
string | null
required

Public URL of the quote file. The URL will expire after 30 minutes.

Example:

"https://app.pennylane.com/public/quote/pdf?encrypted_id=bzjoVJe...3D%3D"

filename
string | null
required

Name of the file attached to the quote

Example:

"my_file.pdf"

special_mention
string | null
required

Additional details

Example:

"Additional details"

customer
object | null
required
invoice_line_sections
object
required
invoice_lines
object
required
linked_invoices
object
required
pdf_invoice_free_text
string
required
Example:

"Quote details"

pdf_invoice_subject
string
required
Example:

"Quote subject"

pdf_description
string | null
required
Example:

"Quote description"

quote_template
object | null
required
appendices
object
required
external_reference
string
required

The unique external reference that was assigned during creation either by you or Pennylane. (Same attribute as external_id in the API v1)

Example:

"FR123"

archived_at
string<date-time> | null
required

The time the quote has been archived

Example:

"2023-08-30T10:08:08.146343Z"

created_at
string<date-time>
required

The time the quote has been created

Example:

"2023-08-30T10:08:08.146343Z"

updated_at
string<date-time>
required

The last time the quote has been updated

Example:

"2023-08-30T10:08:08.146343Z"

I