Skip to content

add processing_instruction to OrderRequest#62

Open
Bala1324 wants to merge 1 commit intopaypal:mainfrom
Bala1324:feature/processing-instruction
Open

add processing_instruction to OrderRequest#62
Bala1324 wants to merge 1 commit intopaypal:mainfrom
Bala1324:feature/processing-instruction

Conversation

@Bala1324
Copy link
Copy Markdown

Title: feat(orders): Add processing_instruction to OrderRequest

Summary

  • Added ProcessingInstruction enum with two values:
    • ORDER_COMPLETE_ON_PAYMENT_APPROVAL — PayPal auto-completes the order (authorize/capture) upon
      payer approval
    • NO_INSTRUCTION — Caller manually authorizes or captures after payer approval
  • Added optional processingInstruction field to the OrderRequest interface and schema, mapping to
    the processing_instruction JSON key
  • Exported ProcessingInstruction from the package index
  • Added documentation for the new enum and updated order-request.md

Why

The processing_instruction field is required for payment flows like MBWay, Wero where the order should
be auto-completed on payment approval (ORDER_COMPLETE_ON_PAYMENT_APPROVAL). It was missing from
the OrderRequest interface, making it impossible to type-safely pass this field when creating
orders.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant