Hipay Integration
Hipay processes card payments and handles refunds. The integration communicates with the Hipay API for transaction management.
Components
| Component | File | Role |
|---|---|---|
HipayApi | src/CoreBundle/Api/HipayApi.php | Hipay API client |
Configuration
Required parameters in parameters.yml:
hipay:
api_url: "https://..."
username: "..."
password: "..."
entity: "..."
Data Flow
Transaction Flow
- The customer initiates payment through the Magento checkout
- Magento redirects to or calls the Hipay payment gateway
- Hipay processes the card transaction
- A server-to-server notification is sent to Logidav
HipayApivalidates and records the transaction
Refund Flow
Refunds are initiated from Logidav and processed through the Hipay API:
- An operator triggers a refund from the back-office
HipayApisends the refund request to Hipay- Hipay processes the refund and returns a confirmation
- The transaction status is updated in the database
Error Handling
| Scenario | Behavior |
|---|---|
| Transaction declined | Status recorded; customer notified via Magento |
| Notification delivery failure | Hipay retries; Logidav handles idempotently |
| Refund rejected | Alert raised; operator must review |
| API timeout | Retry with backoff |
:::info Notification URL Hipay sends transaction notifications to a configured callback URL. Ensure this URL is accessible from Hipay's servers and that the route is properly configured in Logidav. :::