Introducing OpenTelemetry for Chargebee SDKs — trace every API call in any telemetry tool.

Einvoices

An e-invoice record associated with an invoice or credit note. It includes processing status, provider references, nested artifacts (for example application responses), and related status messages.

Sample EinvoiceJSON

Einvoices attributes

id
required, string, max chars=50

The unique id for the e-invoice. This is auto-generated by Chargebee.

entity_type
required, enumerated string

The type of the parent document this e-invoice belongs to.

Enum Values
invoice

Invoice

credit_note

Credit note

entity_id
required, string, max chars=50

The unique id of the parent document this e-invoice belongs to. When entity_type is invoice, this is the invoice id; when entity_type is credit_note, this is the credit note id.

reference_id
optional, string, max chars=50

Identifier returned by the connected e-invoicing provider for this submission (for example, a document submission id). Chargebee uses this value when communicating with the provider to retrieve submission status and related artifacts.

reference_number
optional, string, max chars=100

This attribute is used to populate the unique reference number assigned to an invoice on the Invoice Registration Portal (IRP) network. It is essential for identifying and tracking invoices that are processed through the IRP network.

In the future, this field may be used to store similar reference numbers for other networks.

status
required, enumerated string

The status of processing the e-invoice. To obtain detailed information about the current status, see message.

Enum Values
scheduled

Sending the e-invoice to the customer has been scheduled.

skipped

The e-invoice was not sent. This could be due to missing information or because the entity_identifier is not registered on the e-invoicing network.

in_progress

The e-invoice has been sent and Chargebee is waiting for confirmation from the receiving entity.

success

The e-invoice has been successfully delivered to the customer.

failed

The e-invoice was sent and there was an error due to which it was not delivered.

message
optional, string, max chars=3000

Detailed information about the status of the e-invoice. When status is skipped or failed, this contains the reason or error details. The following are some valid examples:

  • Invoice successfully sent to customer via the e-invoicing network 9090:123456
  • Invoice successfully sent to customer via email id abc@acme.com
created_at
required, timestamp(UTC) in seconds

Timestamp indicating when this e-invoice resource was created.

resource_version
optional, long

Version number of this resource. The resource_version is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.

updated_at
optional, timestamp(UTC) in seconds

Timestamp indicating when this e-invoice was last updated. This attribute will be present only if the resource has been updated after 2016-09-28.

deleted
required, boolean

Indicates that this resource has been deleted.

provider_references
optional

List of key-value pairs from the e-invoicing provider (for example, a Receipt Message ID).

business_entity_id
optional, string, max chars=50

The unique ID of the business entity of this e-invoice. Same as the business entity of the parent invoice or credit note.

artifacts

List of e-invoice artifacts related to this e-invoice (for example application responses).