Skip to content

SEO

When a site moves to tourpingo, its old addresses must still lead somewhere. The seller lists them in the portal; before your site answers 404, ask where a path went:

Where an old address went
Terminal window
curl "https://api.stg.vacationpackagesoman.com/v1/public/redirect?path=%2Ftours%2Fdesert-safari.html" \
-H "Tp-Publishable-Key: $TP_KEY"
Answer: 200 OK
{
"to": "/en/trips/desert-safari-with-bbq-dinner",
"code": 301
}

Answer with the code (301 for a permanent move, 302 for a passing one) and to as the Location. When the path doesn’t redirect the API answers 404, and your site shows its own 404 page.

  • Trips: page through GET /v1/public/products with limit=100 and next_cursor; each trip’s locales says which languages it is published in.
  • Pages: GET /v1/public/pages, which leaves out pages that ask not to be listed.

A trip page in a language the trip isn’t published in shows English text (languages). For such a page:

  • add noindex for that language, and leave it out of the sitemap;
  • give hreflang alternates only for the trip’s locales.
  • Pages carry seo: meta_title (up to 60 characters shows in full), meta_description (up to 160), canonical_url when the same content lives at another address, and noindex.
  • Trips have no SEO fields of their own: use the title, and the summary for the description.

Render trip and list pages on your server, and cache catalog reads for a short time. Never cache a quote, a hold or a booking. Cache headers on catalog reads are coming with issue #531.