SNCF Train Ticket & Connection Scraper avatar

SNCF Train Ticket & Connection Scraper

Pricing

from $12.00 / 1,000 sncf train connections

Go to Apify Store
SNCF Train Ticket & Connection Scraper

SNCF Train Ticket & Connection Scraper

Scrape SNCF Connect train connections, departure and arrival times, journey duration, direct or connecting status, operators, displayed ticket prices, fare classes, seat-count hints, and onboard services.

Pricing

from $12.00 / 1,000 sncf train connections

Rating

0.0

(0)

Developer

Muhammad Afzal

Muhammad Afzal

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

4 days ago

Last modified

Share

Search the public SNCF Connect booking flow and export one structured record per train connection. The Actor is designed for travel planners, price-watch dashboards, route research, and AI agents that need current departure and arrival times, journey duration, direct/connecting status, displayed fares, train operators, and onboard services.

What it extracts

Each dataset item represents one SNCF Connect result card:

FieldDescription
origin, destinationStation labels shown by SNCF Connect
departureTime, arrivalTimeISO timestamps in Europe/Paris
durationMinutesJourney duration when displayed
direct, changesDirect/connection interpretation of the result card
carrier, trainTypeDisplayed operator and normalized family (tgv-inoui, ouigo, ter, intercites, or eurostar)
lowestPrice, faresDisplayed EUR prices by class, including “dès” and seat-count hints when present
servicesOnboard services such as Wi-Fi, bar, or bicycle space
sourceUrl, searchedAtResult page and retrieval timestamp

Prices and availability are live snapshots displayed by SNCF Connect. They are not a booking, quote, inventory guarantee, or guarantee that every operator is returned.

When to use it

Use it for a bounded one-way route search. Enter station names as SNCF Connect presents them; city names such as Paris and Lyon are also accepted and are resolved to the best matching station. Use directOnly or trainType for a narrower result set, priceMode: "schedules" when fare cards are not needed, and maxResults for a predictable budget.

The Actor does not log in, purchase tickets, access user bookings, solve CAPTCHAs, or bypass DataDome. It only reads the public booking flow. A challenged session is returned as a clear BLOCKED diagnostic with zero result charges.

Input

{
"from": "Paris Gare de Lyon",
"to": "Lyon Part-Dieu",
"departureDate": "2026-09-11",
"departureTime": "08:00",
"directOnly": false,
"trainType": "all",
"priceMode": "prices",
"maxResults": 5,
"maxLoadMoreClicks": 1
}

departureDate defaults to tomorrow in Europe/Paris. maxResults accepts 1–50. maxLoadMoreClicks accepts 0–8. The default proxy configuration uses an Apify French residential session because SNCF Connect commonly applies DataDome to non-browser or datacenter traffic. Keep the proxy, browser, cookies, locale, and geography consistent for a run.

Console/API example:

apify call YOUR_USERNAME/sncf-train-ticket-connection-scraper \
-p '{"from":"Paris Gare de Lyon","to":"Lyon Part-Dieu","departureTime":"08:00","maxResults":3}'

Output example

{
"connectionId": "5d0a5f0e4c46a4c0c98b5e8d",
"origin": "Paris - Gare De Lyon - Hall 1 & 2",
"destination": "Lyon Part Dieu",
"departureTime": "2026-09-11T08:00:00+02:00",
"arrivalTime": "2026-09-11T09:56:00+02:00",
"durationMinutes": 116,
"changes": 0,
"direct": true,
"carrier": "TGV INOUI",
"trainType": "tgv-inoui",
"services": ["Wifi à bord", "Voiture bar"],
"lowestPrice": 49,
"currency": "EUR",
"fares": [{"className":"second","price":49,"currency":"EUR","priceFrom":true,"availabilityText":null}],
"searchedFrom": "Paris Gare de Lyon",
"searchedTo": "Lyon Part-Dieu",
"searchedAt": "2026-09-10T03:00:00.000Z",
"source": "SNCF Connect",
"sourceUrl": "https://www.sncf-connect.com/home/shop/results/outward"
}

Run diagnostics are written to the OUTPUT key-value record. Outcomes are DATA, EMPTY, BLOCKED, REJECTED, or FAILED. The Actor never adds an error object to the homogeneous connection dataset.

Pay per event

EventPrice
SNCF search start$0.035 per GB (2 GB default = $0.070)
train-connection$0.012 per delivered connection

The start event is synthetic and is never manually charged. A connection is pushed to the dataset before its result event is charged. maxResults, pagination, and Apify’s maximum-charge limit bound work and spend. The minimum allowed cap is $0.15 to leave room for the 2 GB start, one result, and browser/proxy usage; the default cap is $0.30.

Reliability and compliance

The scraper uses a displayed Chromium session, a French residential route, bounded concurrency, short pagination, coherent browser signals, and session retirement for HTTP 403/429 or challenge responses. If SNCF changes its page structure, the Actor reports an explicit extraction diagnostic instead of fabricating records. Respect SNCF Connect’s terms, robots/access policies, fare display conditions, and applicable privacy and database-rights law. Do not use this Actor to automate purchasing or circumvent access controls.

Support

For a reproducible issue, include the redacted input, run ID, outcome, and OUTPUT record. Do not include cookies, proxy URLs, account credentials, or other secrets.