POST
/
cleemy-procurement
/
api
/
purchases
/
{id}
/
commitment
curl --request POST \
--url https://{host}/cleemy-procurement/api/purchases/{id}/commitment \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '{
"costDate": "2025-04-14",
"invoiceDate": "2025-04-14",
"amountIncludingTaxes": {
"excludingTaxes": {
"value": 120,
"currency": "EUR"
},
"taxes": []
},
"type": "OneTimeCommitment",
"attachmentIds": [],
"state": "Created",
"comment": "Comment",
"paymentMethod": null
}'
{
  "id": 54635,
  "costDate": "2025-04-14",
  "invoiceDate": "2025-04-14",
  "amountIncludingTaxes": {
    "excludingTaxes": {
      "value": 120,
      "currency": "EUR"
    },
    "taxes": []
  },
  "type": "OneTimeCommitment",
  "attachmentIds": [],
  "state": "Created",
  "comment": "Comment",
  "paymentMethod": null,
  "createdAt": "2024-09-24T10:02:01.9244011+00:00",
  "author": {
    "name": "John Doe",
    "firstName": "John",
    "lastName": "Doe",
    "pictureHref": "https://example.ilucca.net/directory/api/employees/416/picture",
    "id": 416,
    "href": "https://example.ilucca.net/api/v3/users/416"
  },
  "modifiedAt": "2024-09-24T13:52:40.3558953+00:00",
  "modifier": {
    "name": "Matt Bawss",
    "firstName": "Matt",
    "lastName": "Bawss",
    "pictureHref": "https://example.ilucca.net/directory/api/employees/979/picture",
    "id": 979,
    "href": "https://example.ilucca.net/api/v3/users/979"
  }
}

Headers

Authorization
string
required

API key. Value must be formatted like so: lucca application={api_key}.

Path Parameters

id
integer
required

ID of the purchase you want to create a commitment for.

Body

application/json

Represents a purchase commitment. Can be one of two types: Subscription or OneTime.

A "subscription" typed commitment represents a purchase commitment that will be paid in installments over a given period, whereas a "one-time" commitment will be paid in full once. Commitment for a subscription.

type
string

Type of the commitment.

Allowed value: "SubscriptionCommitment"
owner
object

Owner of the commitment. Reference to a user. User ID who is the owner of the commitment.

purchase
object

Purchase of the commitment. Reference to a purchase. Purchase of the subscription commitment.

attachments
attachment · object[]

Attachments of the commitment.

Required array length: 1 - 3 elements
comment
string | null

Comment of the commitment.

paymentMethod
enum<string> | null

Method of payment of the commitment. BankTransfer: bank transfer. PhysicalCard: physical card. Check: check. DirectDebit: direct debit. SingleUseCard: single use card.

Available options:
BankTransfer,
PhysicalCard,
Check,
DirectDebit,
SingleUseCard
state
enum<string>

State of the commitment.

Available options:
Created,
UnderReview,
Provisioned,
Denied,
Cancelled
startDate
string<date>

Start date of the subscription.

firstInvoiceDate
string<date>

Date of the first invoice.

invoicingFrequency
object

Invoicing frequency of the subscription.

subscriptionDuration
object

Duration of the subscription.

contractualObligation
object

Contractual obligation of the subscription.

terminationNotice
object

Termination notice of the subscription.

amountIncludingTaxesPerPeriod
object

Represents an amount of money with VAT taxes in two different currencies. Amount including taxes per period.

amountIncludingTaxes
object

Represents an amount of money with VAT taxes in two different currencies. Amount including taxes.

subscriptionEndDate
string<date>

End date of the subscription.

periodsCount
integer

Number of periods.

contractualEndDate
string<date> | null

End date of the contractual obligation.

author
object

Reference to a user. Read-only. User ID who is the author of the commitment.

modifier
object

Reference to a user. Read-only. User ID who is the modifier of the commitment.

Response

200 - application/json

OK

items
(Subscription Commitment · object | One-Time Commitment · object)[]