Please report issues and contribute improvements on GitHub!

Template lateinvoicewithpayment@0.3.0

Contract ^0.12.0 bb660d488021f5e1d4f02048ca73888be0d390dda84d77f5481f467d2ec1d20e

A sample Late invoice clause which emits a payment obligation.

Download Archive Open in Template Studio

Late Invoice Clause With Payment

A sample Late invoice clause which emits a payment obligation.

Sample

2.4 "Betty Buyer" is not required to pay any invoice that is issued more than 180 days after it is due to be issued by "Steve Seller".
                

Model Dependencies

Technical Integration

Please refer to the Cicero documentation for details and examples of how to integrate a call to a Cicero template into your application.

View the Latest code for this template on on GitHub.

Sample Instance

{
    "$class": "org.accordproject.lateinvoicewithpayment.LateInvoiceContract",
    "contractId": "d72f8249-253f-439a-9d30-91110c86fe71",
    "maximumDelay": {
        "$class": "org.accordproject.time.Duration",
        "amount": 180,
        "unit": "days"
    },
    "purchaser": {
        "$class": "org.accordproject.cicero.contract.AccordParty",
        "partyId": "Betty Buyer"
    },
    "supplier": {
        "$class": "org.accordproject.cicero.contract.AccordParty",
        "partyId": "Steve Seller"
    }
}

State Types

Type Sample JSON
org.accordproject.cicero.contract.AccordContractState
{
    "$class": "org.accordproject.cicero.contract.AccordContractState",
    "stateId": "cb1be9d0-575d-11e9-9ffa-db0629e5d319"
}

Request Types

Type Sample JSON
org.accordproject.lateinvoicewithpayment.LateInvoiceRequest
{
    "$class": "org.accordproject.lateinvoicewithpayment.LateInvoiceRequest",
    "invoiceDue": "2019-04-05T00:46:36.268-04:00",
    "amountDue": {
        "$class": "org.accordproject.money.MonetaryAmount",
        "doubleValue": 105.273,
        "currencyCode": "VUV"
    },
    "transactionId": "cb1bc2c0-575d-11e9-9ffa-db0629e5d319",
    "timestamp": "2019-04-05T00:46:36.268-04:00"
}

Response Types

Type Sample JSON
org.accordproject.lateinvoicewithpayment.LateInvoiceResponse
{
    "$class": "org.accordproject.lateinvoicewithpayment.LateInvoiceResponse",
    "paymentRequired": false,
    "cause": "Fugiat sint.",
    "transactionId": "cb1bc2c1-575d-11e9-9ffa-db0629e5d319",
    "timestamp": "2019-04-05T00:46:36.268-04:00"
}

Events Types

Type Sample JSON
org.accordproject.cicero.runtime.PaymentObligation
{
    "$class": "org.accordproject.cicero.runtime.PaymentObligation",
    "amount": {
        "$class": "org.accordproject.money.MonetaryAmount",
        "doubleValue": 83.417,
        "currencyCode": "LBP"
    },
    "description": "Non minim dolor.",
    "contract": "resource:org.accordproject.lateinvoicewithpayment.LateInvoiceContract#2479",
    "promisor": "resource:org.accordproject.cicero.contract.AccordParty#0865",
    "promisee": "resource:org.accordproject.cicero.contract.AccordParty#4312",
    "deadline": "2019-04-05T00:46:36.269-04:00",
    "eventId": "cb1be9d1-575d-11e9-9ffa-db0629e5d319",
    "timestamp": "2019-04-05T00:46:36.269-04:00"
}