Leveraging per-item prep time with CreatePaymentLink API

Hi, I found a couple older threads on this but wanted to describe what I’m looking for and see if anyone has a solution.

We have a custom website we’ve built to pull in our restaurant’s catalog of items from Square and uses the Checkout > Create Payment Link API to facilitate the transaction and place an order. The kitchen has the Square POS and printers wired up to print tickets that come in through our website.

For the moment, we’ve been sending data to the Create Payment Link API that looks like this

{
          idempotency_key: 'order-auth_token_for_test',
          description: 'Payment Link Generated at now! for key order-auth_token_for_test in environmnet test in Square env sandbox',
          order: {
            reference_id: '12345,
            location_id: 'ABCD',
            source: {name: 'Cafe Website'},
            line_items: [
              {
                quantity: '1',
                modifiers: [],
                catalog_object_id: 'I64PS4AH6NJUEALVKXQHSI73',
              },
              {
                quantity: '2',
                modifiers: [
                  {catalog_object_id: 'NFQ4JEXJLHRGM2CZWOXYLRNU'},
                  {catalog_object_id: '3RQVBHJRHHYBBF75ADBSEIMW'},
                ],
                catalog_object_id: 'GSM45RIBF2VTOKX5JIFYKPDH',
              },
            ],
            fulfillments: [
              type: 'PICKUP',
              pickup_details: {
                schedule_type: 'SCHEDULED',
                pickup_at: '2023-12-02T18:15:00Z',
                prep_time_duration: 'PT20M',
              },
            ],
          },
          checkout_options: {
            allow_tipping: false,
            enable_coupon: false,
            redirect_url: '.......',
            accepted_payment_methods: {
              apple_pay: true,
              google_pay: true,
              cash_app_pay: true,
            },
          },
          payment_note: 'Cafe Web Order',
        }

This has been functioning fine - with prep_time_duration set to 20m on the fulfillments, tickets are printing out at the kitchen printer 20m prior to the pickup time.

However, recently we’ve made a switch in the cafe where we have separate ticket printers, one ticket printer only prints drink tickets to the barista station, the food tickets go to the kitchen.

Our kitchen tickets are the bottleneck for prep time - food items require the 20m. With our current setup, both the barista drink tickets and food tickets both print out at the same time, 20m prior to pickup.

This causes a little bit of chaos at the barista station as they really want to start prepping drinks closer to the pickup time to keep them as hot as possible for customers. They have a bunch of tickets that print out which effectively just get queued up and mixed in with customers placing orders in-store.

I saw that in the Square website dashboard, you can configure things like default pickup times per location and also configure pickup times on an individual item basis. We would love to set it up so our hot drinks require 3m of prep time, food requires 20m.

However, cannot figure out if this is possible to do using the Create Payment Link API. I feel like I’ve tried every combination of omitting/providing different data in our Create Payment Link fulfillment data object as well as printer profile configuration. Is there any way to leverage these per-item prep times with the Create Payment Link API so we can get tickets printing out at different times for different items?

Would something like the KDS help here at all? Right now we’re just working off paper tickets and I believe the paper ticket management is also part of what’s contributing to our problems.

Would really appreciate any assistance. Thanks!

At this time the ability to have an additional fulfillment for an item that would print out at a different time from other items isn’t currently available with our APIs. We’re constantly working to improve our features based on feedback like this, so I’ll be sure to share your request to the API product team. :slightly_smiling_face:

1 Like