Get started
Webhooks

itinerary

itinerary

Subscribe an endpoint to every event on this page with itinerary.*. Each is the envelope every webhook event shares, with the ItineraryEventObject object as its data.object.

Event typeWhat happened
itinerary.createdAn itinerary was created.
itinerary.updatedAn itinerary's name, description or privacy changed.
itinerary.deletedAn itinerary was deleted.
itinerary.publishedAn itinerary was published.
itinerary.unpublishedAn itinerary was taken down.

The ItineraryEventObject object

An itinerary as a webhook event carries it: its identifiers, its name and description, its status, whether it is private, and its version. Its segments, waypoints and geometry are never carried: getItinerary reads them.

object

string

required

One of: itinerary

The kind of object this is, always itinerary: the family of the event types that carry it, and what tells the members of WebhookEventObject apart.

id

string (uuid)

required

Identifier of the itinerary.

organization_id

string (uuid)

required

Identifier of the organization the itinerary belongs to.

activity_id

string (uuid)

required

Identifier of the itinerary's activity, in the catalog getActivities lists.

name

string

required

The itinerary's name.

description

string | null

required

The itinerary's description, null when it has none.

status

string

required

One of: draft, published

Whether the itinerary has a live publication once this change was made.

is_private

boolean

required

Whether the itinerary is private to the organization.

version

integer (int64)

required

The itinerary's version once this change was made. It climbs with every change a read of the itinerary shows, so of two events about one itinerary the one carrying the higher version is the later state: events are not delivered in order. A delete is the itinerary's last version change: itinerary.deleted carries the version one past the last the itinerary held, so an event about it that arrives after its delete is never the later state.

origin

string

One of: created, imported, duplicated

How the itinerary came to be. Present on itinerary.created alone.

created_by

object

required

The user who created the itinerary.

created_at

string (date-time)

required

When the itinerary was created.

updated_at

string (date-time)

required

When the itinerary last changed.

itinerary.created

An itinerary was created, imported from a file or copied. origin says which.

Triggered by

  • itinerary.create: Always, with origin created.
    • POST /v1/itineraries: postItinerary, mountaya.studio.itineraries.postItinerary() in TypeScript. Every itinerary created.
  • itinerary.import: Always, with origin imported. Its segments and waypoints are part of it, and record no event of their own.
    • POST /v1/itineraries/import: postItineraryImport, mountaya.studio.itineraries.postItineraryImport() in TypeScript. Every import confirmed.
  • itinerary.duplicate: Always, for the copy, with origin duplicated. The itinerary copied is not changed.
    • POST /v1/itineraries/{itinerary_id}/duplicate: postItineraryDuplicate, mountaya.studio.itineraries.postItineraryDuplicate() in TypeScript. Every copy made.

Payload

type

string

required

One of: itinerary.created

Always itinerary.created.

data.object

ItineraryEventObject

required

Every other field is the envelope every webhook event shares.

itinerary.updated

An itinerary's own fields were written. A change to its segments, segment groups or waypoints is an event of their own.

Triggered by

  • itinerary.update: Always: every accepted change writes a new revision, one that sends the values already held included.
    • PATCH /v1/itineraries/{itinerary_id}: patchItinerary, mountaya.studio.itineraries.patchItinerary() in TypeScript. Every change accepted.

Payload

type

string

required

One of: itinerary.updated

Always itinerary.updated.

data.object

ItineraryEventObject

required
data.previous_attributes

object

The former value of each field of data.object the change moved, and of no other.

Every other field is the envelope every webhook event shares.

itinerary.deleted

An itinerary was deleted, with its segments, segment groups, waypoints, publication and share link, which record no event of their own.

Triggered by

  • itinerary.delete: Always.
    • DELETE /v1/itineraries/{itinerary_id}: deleteItinerary, mountaya.studio.itineraries.deleteItinerary() in TypeScript. Every itinerary deleted.

Payload

type

string

required

One of: itinerary.deleted

Always itinerary.deleted.

data.object

ItineraryEventObject

required

Every other field is the envelope every webhook event shares.

itinerary.published

An itinerary was published: a first publication, or a republication replacing the live one.

Triggered by

  • itinerary.publish: Always: a republication replaces the live publication and is recorded too.
    • POST /v1/itineraries/{itinerary_id}/publication: postItineraryPublication, mountaya.studio.itineraries.postItineraryPublication() in TypeScript. Every publication.

Payload

type

string

required

One of: itinerary.published

Always itinerary.published.

data.object

ItineraryEventObject

required

Every other field is the envelope every webhook event shares.

itinerary.unpublished

An itinerary's live publication was taken down.

Triggered by

  • itinerary.unpublish: When the itinerary was published. Taking down what is not published records nothing.
    • DELETE /v1/itineraries/{itinerary_id}/publication: deleteItineraryPublication, mountaya.studio.itineraries.deleteItineraryPublication() in TypeScript. Every request.

Payload

type

string

required

One of: itinerary.unpublished

Always itinerary.unpublished.

data.object

ItineraryEventObject

required

Every other field is the envelope every webhook event shares.