# For API Integration (Merchants) You can associate a bank account with orders or payment links in two ways: ## Option 1: Using an Existing Bank Account ID If the customer already has a registered bank account, reference it by ID: ## Create Order ### API Endpoint ```curl POST https://api.glomopay.com/api/v1/orders ``` ### Request ```curl { "customer_id": "cust_E602dMzgjpDC", "amount": 10000, "currency": "USD", "purpose_code": "P1401", "bank_account_id": "ba_xyz123" } ``` ## Option 2: Providing Bank Account Details Inline If you have the customer's bank account details, provide them directly: ## Create Order ### API Endpoint ```curl POST https://api.glomopay.com/api/v1/orders ``` ### Request ```curl { "customer_id": "cust_E602dMzgjpDC", "amount": 10000, "currency": "USD", "purpose_code": "P1401", "bank_account_details": { "account_number": "1234567890", "bic_primary": "HDFCINBBDEL", "bic_secondary": "HDFC0001097", "bank_customer_id": "7189204715" } } ``` ### Bank account details parameters | Parameter | Required | Description | | --- | --- | --- | | `account_number` | Yes | The bank account number | | `bic_primary` | Conditional | SWIFT/BIC code of the bank. Either `bic_primary` or `bic_secondary` must be provided | | `bic_secondary` | Conditional | Local routing code (e.g., IFSC for India). Either `bic_primary` or `bic_secondary` must be provided | | `bank_customer_id` | No | Optional bank customer identifier | | `bank_code` | No | Optional bank code | **Important**: You cannot provide both `bank_account_id` and `bank_account_details` in the same request.