Mobilitybox Ticketing Restore Tickets General Idea

This chapter explains how you can restore a ticket in the Mobilitybox API.

Restore API

You must call the /ticketing/orders/{id}/restore.json endpoint to restore one or multiple tickets.

You need the API-Key you used to create the order and the following parameters:

  "restore_secret": "mobilitybox-restore_secret",
  "coupon_ids": [

Restore Secret: secret key of the booking from which to restore the coupons. The restore secret is returned by the order create api.

Coupon Ids: one or multiple coupon ids which are to be restored. (They need to belong to the order)

You can only restore already activated coupons.


  "order_id": "mobilitybox-order-uuid",
  "optional_order_reference": "Optional Order Reference",
  "environment": "test",
  "coupons": [
      "id": "mobilitybox-coupon-uuid-restored-1",
      "original_coupon_id": "mobilitybox-coupon-uuid-1",
      "restored_coupon_id": null,
      "product": {...},
      "area": {...},
      "subscription": {
        "id": "mobilitybox-subscription-uuid-restored-1",
        "original_subscription_id": "mobilitybox-subscription-uuid-1",
        "restored_subscription_id": null,
      "activated": true,
      "environment": "test"

The restore endpoint will create a new coupon for each coupon you passed in the parameters. You can then activate the new coupons in the usual way by passing the identification medium.

"original_...": means the old coupon/subscription which was restored. For example when you restore Coupon-A, the new coupon will have the ID of Coupon-A set in it's original_coupon_id attribute

"restored_...": means the new coupon/subscription which is the restored instance. For example when you restore Coupon-B, this will have the attribute restored_coupon_id set to the new Coupon-B-Restored ID

The created tickets will have the same validity times like the old tickets.

Restore Subscription

When you restore a subscription coupon, the restored coupon will have a new subscription_id and new subscription_cycle_ids. A new restored subscription cycle will also be ordered for each subscription cycle. You only have to activate and reactivate the coupon again to get current and future tickets again.