# KsefReceipt

Exact UPO bytes with separate schema, identity/hash binding and retrieval evidence. This does not verify a digital signature or fiscal treatment.

Class 

`OfficeIMO.Invoicing.KSeF`

**Namespace**

`OfficeIMO.Invoicing.KSeF`

**Assembly**

`OfficeIMO.Invoicing.KSeF`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[KsefReceipt.cs:27](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L27)

**Modifiers**

sealed

Exact UPO bytes with separate schema, identity/hash binding and retrieval evidence. This does not verify a digital signature or fiscal treatment.

## Inheritance

- object
- KsefReceipt

## Usage

Explore 2 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 2

- Method [KsefClient.GetInvoiceReceiptAsync](/api/invoicing-ksef/officeimo-invoicing-ksef-ksefclient/#method-getinvoicereceiptasync-officeimo-invoicing-ksef-ksefcredentials-officeimo-invoicing-ksef-ksefsubmission-threading-cancellationtoken)
- Method [KsefReceipt.Inspect](/api/invoicing-ksef/officeimo-invoicing-ksef-ksefreceipt/#method-inspect-byte-officeimo-invoicing-ksef-ksefcontext-string-string-string-threading-cancellationtoken)

Filter members 

Show inherited

## Methods

`public byte[] GetBytes()` [#](#method-getbytes)

[KsefReceipt.cs:27](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L27)

Returns a defensive copy of the receipt as delivered.

Returns

`byte[]`

`public static KsefReceipt Inspect(byte[] xml, KsefContext context, string sessionReference, string ksefNumber, string invoiceHash, CancellationToken cancellationToken = default)` [#](#method-inspect-byte-officeimo-invoicing-ksef-ksefcontext-string-string-string-threading-cancellationtoken)

[KsefReceipt.cs:30](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L30)

Inspects offline receipt bytes without claiming authenticated retrieval.

Parameters

**xml byte[] required**

**context OfficeIMO.Invoicing.KSeF.KsefContext required**

**sessionReference string required**

**ksefNumber string required**

**invoiceHash string required**

**cancellationToken System.Threading.CancellationToken = default optional**

Returns

`KsefReceipt`

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

## Properties

`public bool RetrievedThroughAuthenticatedApi { get; }` [#](#property-retrievedthroughauthenticatedapi)

[KsefReceipt.cs:17](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L17)

Whether this instance was obtained through the client's direct authenticated official API route.

`public bool IsBound { get; }` [#](#property-isbound)

[KsefReceipt.cs:19](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L19)

Whether session, context, KSeF identifier and exact document hash match the expected values.

`public InvoiceValidationStatus SchemaStatus { get; }` [#](#property-schemastatus)

[KsefReceipt.cs:21](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L21)

Pinned UPO v4-3 XSD result, independent of retrieval and invoice acceptance.

`public IReadOnlyList<InvoiceDiagnostic> Diagnostics { get; }` [#](#property-diagnostics)

[KsefReceipt.cs:23](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L23)

Schema and binding diagnostics; a failed schema is never silently relaxed.

`public string Sha256 { get; }` [#](#property-sha256)

[KsefReceipt.cs:25](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Invoicing.KSeF/KsefReceipt.cs#L25)

SHA-256 of exact UPO bytes, hexadecimal encoded.

<!-- PowerForge markdown artifact sha256:CBD16A01CF163E6CA63C455143BED65BA39434EE58BB19E9783E88E18F534288 -->
