@autobusal/order-process 1.5.1 → 1.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/BKT/Bkt.tsx CHANGED
@@ -76,7 +76,10 @@ const Bkt = ({ hash, t }: Props): JSX.Element => {
76
76
  <input type="hidden" defaultValue={ data?.currency } { ...register('currency') } />
77
77
  <input type="hidden" defaultValue={ data?.okUrl } { ...register('okUrl') } />
78
78
  <input type="hidden" defaultValue={ data?.failUrl } { ...register('failUrl') } />
79
- <input type="hidden" defaultValue={ data?.orderId } { ...register('oid') } />
79
+ { /* Claude - 2026-09-25 (audit): the hash is signed over data.oid (the
80
+ per-attempt order-number reference), not the database id - posting
81
+ orderId made BKT reject the signature. orderId stays as ObtBktId. */ }
82
+ <input type="hidden" defaultValue={ data?.oid ?? data?.orderId } { ...register('oid') } />
80
83
  <input type="hidden" defaultValue={ data?.amount } { ...register('amount') } />
81
84
  <input type="hidden" defaultValue={ data?.lang } { ...register('lang') } />
82
85
 
@@ -50,7 +50,7 @@ const Standard = ({ type, hash, t }: Props): JSX.Element => {
50
50
  if (isError) {
51
51
  const message = (error as { response?: { data?: { message?: string } } })?.response?.data?.message;
52
52
 
53
- const reason = message ?? t('order_process.error', { ns: 'common', defaultValue: 'We could not complete your order. Please try again.' });
53
+ const reason = message ?? t('order_process.error_order', { ns: 'common', defaultValue: 'We could not complete your order. Please try again.' });
54
54
 
55
55
  notifyError(reason);
56
56
 
@@ -74,7 +74,7 @@ const Standard = ({ type, hash, t }: Props): JSX.Element => {
74
74
  if (isSuccess) {
75
75
  return (
76
76
  <Container>
77
- <Inline text={ t('order_process.error', { ns: 'common', defaultValue: 'We could not confirm your order. Please open your orders to check its state.' }) } />
77
+ <Inline text={ t('order_process.error_confirm', { ns: 'common', defaultValue: 'We could not confirm your order. Please open your orders to check its state.' }) } />
78
78
  </Container>
79
79
  );
80
80
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autobusal/order-process",
3
- "version": "1.5.1",
3
+ "version": "1.5.3",
4
4
  "author": "Ferjolt Ozuni",
5
5
  "type": "module",
6
6
  "main": "index.ts",
package/types.ts CHANGED
@@ -5,7 +5,7 @@ export interface BKTFormData {
5
5
  currency: number
6
6
  okUrl: string
7
7
  failUrl: string
8
- oid: number
8
+ oid: number | string // Claude - 2026-09-25 (audit): the order-number reference is a string
9
9
  amount: number
10
10
  lang: string
11
11
  Email: string
@@ -47,6 +47,9 @@ export interface BKTData {
47
47
  description: string
48
48
  amount: number
49
49
  orderId: number
50
+ // Claude - 2026-09-25 (audit): the per-attempt order-number reference
51
+ // obtapi signs into the hash (BKT Prepare) - what BKT must receive as oid
52
+ oid?: string
50
53
  labelId: number
51
54
  domain: string
52
55
  currency: number