Skip to content

Add Skyscanner flights adapter#15

Closed
ankitranjan7 wants to merge 2 commits into
mainfrom
add-skyscanner-adapter
Closed

Add Skyscanner flights adapter#15
ankitranjan7 wants to merge 2 commits into
mainfrom
add-skyscanner-adapter

Conversation

@ankitranjan7

Copy link
Copy Markdown

Summary

  • Add webcmd skyscanner flights <origin> <destination> --depart-date <YYYY-MM-DD> --return-date <YYYY-MM-DD>
  • Extract visible round-trip flight cards from a warmed CloakBrowser session using Skyscanner data-testid="ticket" UI
  • Detect Skyscanner human verification/CAPTCHA pages and fail with a typed auth-required path instead of returning empty rows
  • Add adapter tests for URL/date validation, duplicate DOM text handling, CAPTCHA detection, and execution behavior

Command Added

webcmd skyscanner flights nyca lond --depart-date 2026-08-01 --return-date 2026-08-08 --limit 3

Columns: rank, priceText, airlines, outboundTime, outboundRoute, outboundDuration, outboundStops, returnTime, returnRoute, returnDuration, returnStops, url.

Notes

  • This is intentionally browser-backed. Cold Skyscanner sessions may require the user to clear Skyscanner verification in CloakBrowser first.
  • The adapter does not bypass CAPTCHA; it reuses a valid browser session and reports verification as auth-required when blocked.

Verification

  • npm run test:adapter -- clis/skyscanner/flights.test.js
  • npm run dev -- skyscanner flights nyca lond --depart-date 2026-08-01 --return-date 2026-08-08 --limit 3 --site-session persistent --keep-tab true --window foreground -f json
  • npm run dev -- browser work verify skyscanner/flights --strict-memory
  • npm run check:silent-column-drop
  • npm run check:typed-error-lint
  • npm run typecheck
  • npm run build

@rishabhraj36

Copy link
Copy Markdown
Collaborator

Closing this because the adapter has been published as an external Webcmd plugin: https://github.com/rishabhraj36/webcmd-plugin-skyscanner

Install it with: webcmd plugin install github:rishabhraj36/webcmd-plugin-skyscanner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants