Skip to main content

External registration

AiFi-managed registration

The current external registration flow at AiFi differs from the internal or no registration flow. It includes additional steps to collect user information on the screen.

When integrating your payment terminal, use the card hash or fingerprint (a unique value returned by payment providers) to recognize the customer. If you can do this, don't require extra registration for returning customers. Instead, check them in directly using the regular flow.

If your integration can't recognize returning customers and each card tap could be from a new or existing customer, use the remote register call. This will trigger AiFi to collect user data upon entry.

External registration flow

  1. The customer taps the credit card on the terminal owned by the retailer.
  2. The retailer's system performs all checks regarding their systems and the customer.
  3. Optional The retailer's system checks whether it’s a new or recurring customer.
    • If recurring: follow the regular no registration flow.
    • If new: continue.
  4. The retailer's system sends to OASIS API Admin API -> customers -> remote register.
  5. AiFi system (OASIS API) begins the registration process, collecting the email/phone and resolving conflicts on data.
  6. Upon success, AiFi opens the doors.
  7. The customer enters the store.
  8. AiFi sends out the webhook Push -> Transitions -> Customer Entered a store, for the customer that entered the store.
# As always, remember - this is an example call! For the most recent APIs, refer to the API docs!
CUSTOMER_TOKEN=${1:-some-session-id}
TOKEN_TYPE=${2:-SESSION_ID}
STORE_ID=${3:-1}
CHECK_IN_DEVICE_ID=${4:-1}
TOKEN=<ask_us_for_a_dev_token>
BODY=`cat <<EOM
{
"token": "$CUSTOMER_TOKEN",
"tokenType": "$TOKEN_TYPE",
"storeId": "$STORE_ID",
"checkInDeviceId": "$CHECK_IN_DEVICE_ID"
}
EOM
`
curl \
-X POST \
-H "Content-type: application/json" \
-H "Authorization: Bearer $TOKEN" \
-d "$BODY" \
https://oasis-api.public.sandbox.oasis.aifi.com/api/admin/v2/customers/remote-register

Important considerations

  1. Always keep the tokenType as "SESSION_ID" and provide sessionId in the token. The sessionId is still the token that we will send you back in the checkout webhook, just as in the other flows!
  2. Ensure that recurring customers have different handling. You don’t want to trigger the remote registration for existing customers. If you can identify AiFi's customer ID on their subsequent visits based on their credit card metadata (such as card hash or fingerprint that certain payment providers offer), prefer reusing the customer entity. This ensures a smoother user experience in your store.
  3. You can implement your own registration screen. Consider whether it’s possible for you to implement the entry system with an integrated screen, where all data about the customers and their resolution, as well as any auxiliary screens, are owned by you. This way, ensuring you have an identified AiFi Customer, the integration simplifies to the no registration flow.