# Migrating from Entur's existing sales APIs

import { Link } from "zudoku/components";
import { Card, CardDescription } from "zudoku/ui/Card";

:::lead
This page is for partners who already sell through Entur's existing sales APIs. It shows how each action maps to new endpoints in Sales v2.
:::

## What changes

Instead of calling and orchestrating several services, you call Sales v2 processes and collections, and Sales v2 handles the rest. See [What Sales v2 does](/docs/partner-services/sales-v2#what-sales-v2-does) for the APIs it replaces.

## Step-by-step mapping

| Step | Existing sales APIs | Sales v2 |
| --- | --- | --- |
| Search for offers | [Offers](/apis/offers-partner). You supply NeTEx IDs, configure recommendations, and bundle offers yourself. | `search-offers` with sane defaults for recommendations and bundling. `FareZone`, `StopPlace`, `TripPattern`, GPS coordinates and addresses are supported. Just search with `from`, `to` and optionally `via` |
| Select offers | [Orders](/apis/order-partner) and [Reserve Offers](/apis/reserve-offers-partner). You create the order or order lines yourself | `select-offers` to create a package from a set of offers and start modifying it with `ancillaries` or `assets`. Or use the `purchase-offers` shortcut to go straight from offers to a purchasable package. |
| Buy | [Orders](/apis/order-partner): unlock, reset, fail, and confirm. | `release-package` if the user abandons the checkout, `extend-expiry-time` if they need more time, `purchase-package` once they are ready to proceed |
| Pay | [Payment API](/apis/payment-partner) or your PSP and imported payments. | The same. Create a package in Sales v2 and make sure it is paid, and the system prepares the rest |
| Get the ticket | [Ticket Distribution](/apis/ticket-distribution-partner) and NOD. You fetch and rotate tickets yourself. | `travel-documents` collection with automatic refresh. Just `GET` the latest valid travel documents |
| Change ticket time | [Ticket Distributions](/apis/ticket-distribution-partner). `update-validities`, then fetch a new distribution and ticket. | `update-travel-document-validity`, the `travel-documents` collection updates too |
| Find allowed changes | Change Options | `change-options` collection |
| Reserve seats and assets | [Seating Services](/apis/seatingservices) ([Seating Manager](/apis/seating-manager) and Seatmap), mapped to order lines yourself. | `assign-asset` process and `assets` collection |
| Refund | [Refunds](/apis/refund-partner) | `refund-options` collection, `claim-refund-option`. `cancel-package` if package is non-refundable |
| Create a customer | [Customers](/apis/customers) | `customers` collection |

You still call [Journey Planner](/docs/open-services/journey-planner), [Geocoder](/docs/open-services/geocoder) or NSR yourself when you need a TripPattern or trip suggestions client-side.

## What stays the same

- Payment stays outside the sales flow, with your PSP or the Entur Payment API.
- The [Receipt API](/apis/receipt-partner) and [Third Party Product API](/apis/third-party-product-partner) stay separate.
- You still need the ABT API if you use account-based ticketing.

## Next steps

Follow the guides in order to see the new flow end to end.

<div className="grid grid-cols-1 md:grid-cols-2 gap-4 not-prose my-4">
  <Card className="p-6 gap-2 rounded">
    <p className="text-xs uppercase tracking-widest text-muted-foreground font-medium">Step 1</p>
    <Link to="/guides/sales-v2/search-offers" className="text-base font-bold! underline text-foreground!">Search offers</Link>
    <CardDescription>Model who is travelling and get your first offers.</CardDescription>
  </Card>
  <Card className="p-6 gap-2 rounded">
    <p className="text-xs uppercase tracking-widest text-muted-foreground font-medium">Step 2</p>
    <Link to="/guides/sales-v2/make-first-purchase" className="text-base font-bold! underline text-foreground!">Make your first purchase</Link>
    <CardDescription>Prepare, pay for, and confirm a package.</CardDescription>
  </Card>
</div>

<div className="grid grid-cols-1 md:grid-cols-2 gap-4 not-prose my-4">
  <Card className="p-6 gap-2 rounded">
    <p className="text-xs uppercase tracking-widest text-muted-foreground font-medium">API reference</p>
    <Link to="/apis/sales" className="text-base font-bold! underline text-foreground!">Sales v2 API reference</Link>
    <CardDescription>The full list of processes and collections.</CardDescription>
  </Card>
  <Card className="p-6 gap-2 rounded">
    <p className="text-xs uppercase tracking-widest text-muted-foreground font-medium">Documentation</p>
    <Link to="/docs/partner-services/sales-platform/sales" className="text-base font-bold! underline text-foreground!">Existing sales APIs</Link>
    <CardDescription>Documentation for the APIs you use today.</CardDescription>
  </Card>
</div>
