Skip to content

Terminal Reference ​

Objects, statuses, errors, and webhook events for Terminal.

Read the overview and the integration page first.

Reader object ​

FieldTypeDescription
idstringReader id.
labelstringWhat the cashier calls this device. Free text.
statusenumACTIVE, BLOCKED, COMPROMISED, or REVOKED.
connection_statusenumonline or offline.
created_attimestampWhen the Reader first registered.
updated_attimestampWhen the Reader row last changed.

Reader status ​

A Reader has one of four statuses.

StatusMeaning
ACTIVEThe Reader can take payments.
BLOCKEDThe Reader is temporarily stopped.
COMPROMISEDThe Reader is permanently stopped for a security reason.
REVOKEDThe Reader is permanently stopped by request.

A Reader leaves ACTIVE in one direction only. To use the device again, approve it as a new Reader. Deleting a Reader sets it to REVOKED. Its past payments stay on record.

Connection status ​

ValueMeaning
onlineThe Reader sent a signal recently.
offlineThe Reader has not sent a signal recently.

Terminal object ​

FieldTypeDescription
idstringTerminal id.
merchant_idstringThe merchant this Terminal belongs to.
location_idstring, nullableThe Location this Terminal trades from.
namestringWhat the merchant calls this Terminal.
typeenumsoftpos.
statusenumpending, active, or deleted.
capabilitiesarrayPayment methods this Terminal may take.
permissionsobjectWhat this Terminal is allowed to do.

Terminal status ​

StatusMeaning
pendingThe Terminal is registered but not yet ready to take payments.
activeThe Terminal can take payments.
deletedThe merchant withdrew this Terminal.

Capability entry ​

FieldTypeDescription
nameenumcard_present, napas_qr, or visa_qr.
statusenumactive, pending, restricted, or unsupported.

Only an active capability is accepted. A Terminal takes a payment method when the capability for that method is active.

Permissions ​

FieldTypeDescription
accept_paymentboolThe Terminal may accept a payment.
export_invoiceboolThe Terminal may export an invoice.
view_historyboolThe Terminal may view payment history.

Errors ​

Error codeTypeHTTP statusCauseAction
terminal_reader_busyapi_error500The Reader already runs an action.Wait until the action ends. Or call cancel_action.
terminal_reader_timeoutapi_error500The Reader did not answer in time.Retry the request.
intent_invalid_stateinvalid_request_error400The PaymentIntent is not in requires_payment_method.Create a new PaymentIntent.
resource_missinginvalid_request_error400The Reader has no action in progress.Check the Reader before you cancel.

Bahn sets the HTTP status from the error type: card_error and invalid_request_error return 400, authentication_error returns 401, idempotency_error returns 409, rate_limit_error returns 429, and api_error returns 500.

Webhook events ​

PaymentIntent events ​

EventDescription
payment_intent.status.succeededThe payment is complete.
payment_intent.status.requires_payment_methodThe payment was declined. Send the PaymentIntent to the Reader again.
payment_intent.status.canceledThe PaymentIntent was canceled.

Reader action events ​

EventDescription
reader_action.status.succeededBahn authorized the payment.
reader_action.status.failedThe payment was declined, timed out, or the Reader lost its connection. Read failure_code, failure_message, and failure_decline_code.
reader_action.status.canceledYou or the customer canceled the action.

See Events for the full payloads.

Developers