> This page is for API Reference.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://fiftytwo-demo.ferndocs.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://fiftytwo-demo.ferndocs.com/_mcp/server.

# Migrating off the Receipt API

> **Warning**
>
> **The Receipt API is deprecated.** Its own specification says so: *"This API is
> deprecated — please switch to Transaction POS Log API."* It remains documented
> here for teams still running against it.

## What it did

The Receipt API served two directions at once:

* **Writing in.** Posting receipts from external systems like webshops, so
  customers could return goods in a physical store, giving FiftyTwo one point of
  entry for receipts.
* **Reading out.** Retrieving receipts produced by FiftyTwo (or posted through
  the method above), and end-of-day reports.

That split is exactly why it was replaced: the two directions have different
requirements, and they are now two APIs.

## The mapping

**Post an external receipt** — now [Register Sale](/api/register-sale/overview)

```diff
- POST /receiptmanagement/v1
+ POST /v1/sale
```

**Read receipts for a chain** — now [Transaction POS Log](/api/transactions/overview)

```diff
- GET /receipts/v1/chain/{chainNo}/receiptid/{lastReceiptId}
+ GET /v1/chain/{chainNumber}/transaction-pos-log/{lastId}
```

**Read receipts for a single store** — now Transaction POS Log

```diff
- GET /receipts/v1/chain/{chainNo}/store/{storeNo}/receiptid/{lastReceiptId}
+ GET /v1/chain/{chainNumber}/store/{storeNumber}/transaction-pos-log/{lastId}
```

**End-of-day report** — now Transaction POS Log

```diff
- GET /endofday/v1/chain/{chainNo}/store/{storeNo}/session/{sessionNo}
+ GET /v1/chain/{chainNumber}/store/{storeNumber}/session/{sessionNumber}/end-of-day
```

## Why the read side is worth migrating

The Receipt API is poll-only. TPLA pushes events over Apache Pulsar, so you stop
long-polling, react in real time, and get ordered replay after an outage. The
REST cursor endpoints remain for backfill.

## Migration order

#### Move reads to TPLA REST first

The cursor endpoints map almost one-to-one. This is a low-risk change you can
verify by comparing output against the Receipt API for the same cursor.

#### Then subscribe to events

Once your parser handles the TPLA payload, subscribe to Pulsar. The payload is
identical, so nothing downstream changes.

#### Move writes to Register Sale

Note the different auth: Register Sale uses an Auth0-issued Bearer JWT rather
than a token from `auth.fiftytwo.com`. Track correlation IDs, because Register
Sale is not idempotent for you.

#### Reconcile, then decommission

Run both for a period and compare counts before switching off the old path.

#### [Consume transaction events](/docs/guides/transaction-events)

The new read path.

#### [Import webshop sales](/docs/guides/import-sales)

The new write path.