Skip to content

Commit

Permalink
Merge branch 'main' into 4521
Browse files Browse the repository at this point in the history
  • Loading branch information
lsampras authored May 30, 2024
2 parents 56f4469 + 21a3a2e commit 63dbd23
Show file tree
Hide file tree
Showing 229 changed files with 5,220 additions and 2,724 deletions.
63 changes: 63 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,69 @@ All notable changes to HyperSwitch will be documented here.

- - -

## 2024.05.30.0

### Features

- **connector:**
- [ZSL] handle partial payments in Local Bank Transfer ([#4777](https://github.com/juspay/hyperswitch/pull/4777)) ([`e410eba`](https://github.com/juspay/hyperswitch/commit/e410eba6ed4894b4d0d505188d89016b93391d57))
- Add support for external authentication for cybersource ([#4714](https://github.com/juspay/hyperswitch/pull/4714)) ([`97f2ff0`](https://github.com/juspay/hyperswitch/commit/97f2ff0e7051025e397c645fd67a579d0bb492f0))
- [Klarna] Add support for Capture, Psync, Refunds and Rsync flows ([#4799](https://github.com/juspay/hyperswitch/pull/4799)) ([`e41d5e2`](https://github.com/juspay/hyperswitch/commit/e41d5e25dfd4d3113edac11b249e847f8718b263))
- **users:**
- Add redis in Begin and Verify TOTP and create a new API that updates TOTP ([#4765](https://github.com/juspay/hyperswitch/pull/4765)) ([`cd9c9b6`](https://github.com/juspay/hyperswitch/commit/cd9c9b609c8d5d7c77658d973f7922ae71af9a4d))
- Add endpoint to check 2fa status ([#4810](https://github.com/juspay/hyperswitch/pull/4810)) ([`0f7f3d9`](https://github.com/juspay/hyperswitch/commit/0f7f3d9e74f0dad5112d6045089c8bfa12f4767f))

### Bug Fixes

- **Cypress:** Fixing 3DS payment failure in headless mode ([#4807](https://github.com/juspay/hyperswitch/pull/4807)) ([`b335867`](https://github.com/juspay/hyperswitch/commit/b335867eb92b7fe5a1147e7a3dd70d9f2746ba96))
- Implement StrongEq for Vec<u8> ([#4795](https://github.com/juspay/hyperswitch/pull/4795)) ([`b812e59`](https://github.com/juspay/hyperswitch/commit/b812e596a1bef4cc154f5b925753ad158c9022de))

### Refactors

- **connector:** [Klarna] Refactor Authorize call and configs for prod ([#4750](https://github.com/juspay/hyperswitch/pull/4750)) ([`a6570b6`](https://github.com/juspay/hyperswitch/commit/a6570b6a06917be27e543cb35bb210df4fc6391e))
- **core:** Move router data response and request models to hyperswitch domain models crate ([#4789](https://github.com/juspay/hyperswitch/pull/4789)) ([`dd33329`](https://github.com/juspay/hyperswitch/commit/dd333298f8b4e8ff3c15fc79fbc528a61fa1b63f))

**Full Changelog:** [`2024.05.29.0...2024.05.30.0`](https://github.com/juspay/hyperswitch/compare/2024.05.29.0...2024.05.30.0)

- - -

## 2024.05.29.0

### Features

- **connector:**
- [Iatapay] add upi qr support ([#4728](https://github.com/juspay/hyperswitch/pull/4728)) ([`c9fa94f`](https://github.com/juspay/hyperswitch/commit/c9fa94febe7a1fcd24e8d723d14b78f8a73da0e3))
- [CRYPTOPAY] Pass network details in payment request ([#4779](https://github.com/juspay/hyperswitch/pull/4779)) ([`84e032e`](https://github.com/juspay/hyperswitch/commit/84e032e6c28afc410c82e73e51deb629b0c4a81a))

### Bug Fixes

- **docker-compose:** Fix docker compose syntax ([#4782](https://github.com/juspay/hyperswitch/pull/4782)) ([`7645edf`](https://github.com/juspay/hyperswitch/commit/7645edfa2e00500da3f8f117cc1a485fe1f41ab5))
- Include client columns in payment attempts response struct ([#4761](https://github.com/juspay/hyperswitch/pull/4761)) ([`d686ec7`](https://github.com/juspay/hyperswitch/commit/d686ec7acda6ce852fac8d7413f9ba903adcee1d))

### Refactors

- **payment_methods:** Add support for passing ttl to locker entries ([#4690](https://github.com/juspay/hyperswitch/pull/4690)) ([`7ca9c6e`](https://github.com/juspay/hyperswitch/commit/7ca9c6e81313199589444a431a73fbcdf712a9ee))
- Retrieve extended card info config during business profile get call ([#4784](https://github.com/juspay/hyperswitch/pull/4784)) ([`c362fd0`](https://github.com/juspay/hyperswitch/commit/c362fd05325743bb3d173e335124734f1c23b9fa))

### Documentation

- **analytics:** Add documentation for setting up data services and enabling data features in control center ([#4741](https://github.com/juspay/hyperswitch/pull/4741)) ([`d15cb31`](https://github.com/juspay/hyperswitch/commit/d15cb31814390bc631f9eb4195ca114e43ab4cd2))

**Full Changelog:** [`2024.05.28.0...2024.05.29.0`](https://github.com/juspay/hyperswitch/compare/2024.05.28.0...2024.05.29.0)

- - -

## 2024.05.28.0

### Features

- **connector:** [AUTHORIZEDOTNET] Implement non-zero mandates ([#4758](https://github.com/juspay/hyperswitch/pull/4758)) ([`ed82af8`](https://github.com/juspay/hyperswitch/commit/ed82af81f9316c266adc7ee8273b0e33e1c83ccf))
- **core:** [Paypal] Add session_token flow for Paypal sdk ([#4697](https://github.com/juspay/hyperswitch/pull/4697)) ([`b3d4d13`](https://github.com/juspay/hyperswitch/commit/b3d4d13db81143cf663142d8bd8fdf95b0882b3f))

**Full Changelog:** [`2024.05.27.0...2024.05.28.0`](https://github.com/juspay/hyperswitch/compare/2024.05.27.0...2024.05.28.0)

- - -

## 2024.05.27.0

### Refactors
Expand Down
5 changes: 3 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The single API to access payment ecosystems across 130+ countries</div>

<p align="center">
<a href="#%EF%B8%8F-quick-start-guide">Quick Start Guide</a> •
<a href="https://github.com/juspay/hyperswitch/blob/main/docs/try_local_system.md">Local Setup Guide</a> •
<a href="/docs/try_local_system.md">Local Setup Guide</a> •
<a href="#-fast-integration-for-stripe-users">Fast Integration for Stripe Users</a> •
<a href="https://api-reference.hyperswitch.io/introduction"> API Docs </a> •
<a href="#-supported-features">Supported Features</a> •
Expand Down
13 changes: 7 additions & 6 deletions config/config.example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,12 @@ recon_admin_api_key = "recon_test_admin" # recon_admin API key for recon authent
# PCI Compliant storage entity which stores payment method information
# like card details
[locker]
host = "" # Locker host
host_rs = "" # Rust Locker host
mock_locker = true # Emulate a locker locally using Postgres
locker_signing_key_id = "1" # Key_id to sign basilisk hs locker
locker_enabled = true # Boolean to enable or disable saving cards in locker
host = "" # Locker host
host_rs = "" # Rust Locker host
mock_locker = true # Emulate a locker locally using Postgres
locker_signing_key_id = "1" # Key_id to sign basilisk hs locker
locker_enabled = true # Boolean to enable or disable saving cards in locker
ttl_for_storage_in_secs = 220752000 # Time to live for storage entries in locker

[delayed_session_response]
connectors_with_delayed_session_response = "trustpay,payme" # List of connectors which has delayed session response
Expand Down Expand Up @@ -194,7 +195,7 @@ gocardless.base_url = "https://api-sandbox.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://sandbox.iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.playground.klarna.com/"
mifinity.base_url = "https://demo.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down
38 changes: 38 additions & 0 deletions config/dashboard.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
[default.theme]
primary_color="#006DF9"
primary_hover_color="#005ED6"
sidebar_color="#242F48"

[default.endpoints]
api_url="http://localhost:8080" # The backend hyperswitch API server for making payments
sdk_url="http://localhost:9050/HyperLoader.js" # SDK distribution url used for loading the SDK in control center
logo_url=""
favicon_url=""
mixpanel_token=""

[default.features]
test_live_toggle=false
is_live_mode=false
email=false
quick_start=false
audit_trail=true
system_metrics=false
sample_data=false
frm=false
payout=true
recon=false
test_processors=true
feedback=false
mixpanel=false
generate_report=false
user_journey_analytics=false
authentication_analytics=false
surcharge=false
dispute_evidence_upload=false
paypal_automatic_flow=false
threeds_authenticator=false
global_search=false
dispute_analytics=true
configure_pmts=false
branding=false
totp=false
2 changes: 2 additions & 0 deletions config/deployments/env_specific.toml
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ mock_locker = true # Emulate
locker_signing_key_id = "1" # Key_id to sign basilisk hs locker
locker_enabled = true # Boolean to enable or disable saving cards in locker
redis_temp_locker_encryption_key = "redis_temp_locker_encryption_key" # Encryption key for redis temp locker
ttl_for_storage_in_secs = 220752000 # Time to live for storage entries in locker


[log.console]
enabled = true
Expand Down
2 changes: 1 addition & 1 deletion config/deployments/integration_test.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ gocardless.base_url = "https://api-sandbox.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://sandbox.iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.playground.klarna.com/"
mifinity.base_url = "https://demo.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down
4 changes: 2 additions & 2 deletions config/deployments/production.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ gocardless.base_url = "https://api.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.klarna.com/"
mifinity.base_url = "https://secure.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down Expand Up @@ -91,7 +91,7 @@ worldline.base_url = "https://eu.sandbox.api-ingenico.com/"
worldpay.base_url = "https://try.access.worldpay.com/"
zen.base_url = "https://api.zen.com/"
zen.secondary_base_url = "https://secure.zen.com/"
zsl.base_url = "https://api.sitoffalb.net/"
zsl.base_url = "https://api.prodoffalb.net/"
threedsecureio.base_url = "https://service.3dsecure.io"
netcetera.base_url = "https://{{merchant_endpoint_prefix}}.3ds-server.prev.netcetera-cloud-payment.ch"

Expand Down
2 changes: 1 addition & 1 deletion config/deployments/sandbox.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ gocardless.base_url = "https://api-sandbox.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://sandbox.iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.playground.klarna.com/"
mifinity.base_url = "https://demo.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down
5 changes: 2 additions & 3 deletions config/development.toml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ host_rs = ""
mock_locker = true
basilisk_host = ""
locker_enabled = true
ttl_for_storage_in_secs = 220752000

[forex_api]
call_delay = 21600
Expand Down Expand Up @@ -196,7 +197,7 @@ gocardless.base_url = "https://api-sandbox.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://sandbox.iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.playground.klarna.com/"
mifinity.base_url = "https://demo.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down Expand Up @@ -403,8 +404,6 @@ debit = { currency = "USD" }

[pm_filters.klarna]
klarna = { country = "AU,AT,BE,CA,CZ,DK,FI,FR,DE,GR,IE,IT,NL,NZ,NO,PL,PT,ES,SE,CH,GB,US", currency = "AUD,EUR,EUR,CAD,CZK,DKK,EUR,EUR,EUR,EUR,EUR,EUR,EUR,NZD,NOK,PLN,EUR,EUR,SEK,CHF,GBP,USD" }
credit = { not_available_flows = { capture_method = "manual" } }
debit = { not_available_flows = { capture_method = "manual" } }

[pm_filters.zen]
credit = { not_available_flows = { capture_method = "manual" } }
Expand Down
3 changes: 2 additions & 1 deletion config/docker_compose.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ host_rs = ""
mock_locker = true
basilisk_host = ""
locker_enabled = true
ttl_for_storage_in_secs = 220752000

[jwekey]
vault_encryption_key = ""
Expand Down Expand Up @@ -132,7 +133,7 @@ gocardless.base_url = "https://api-sandbox.gocardless.com"
gpayments.base_url = "https://{{merchant_endpoint_prefix}}-test.api.as1.gpayments.net"
helcim.base_url = "https://api.helcim.com/"
iatapay.base_url = "https://sandbox.iata-pay.iata.org/api/v1"
klarna.base_url = "https://api-na.playground.klarna.com/"
klarna.base_url = "https://api{{region_based_endpoint}}.playground.klarna.com/"
mifinity.base_url = "https://demo.mifinity.com/"
mollie.base_url = "https://api.mollie.com/v2/"
mollie.secondary_base_url = "https://api.cc.mollie.com/v1/"
Expand Down
104 changes: 104 additions & 0 deletions crates/analytics/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
# Running Kafka & Clickhouse with Analytics and Events Source Configuration

This document provides instructions on how to run Kafka and Clickhouse using Docker Compose, and how to configure the analytics and events source.

## Architecture
+------------------------+
| Hyperswitch |
+------------------------+
|
|
v
+------------------------+
| Kafka |
| (Event Stream Broker) |
+------------------------+
|
|
v
+------------------------+
| ClickHouse |
| +------------------+ |
| | Kafka Engine | |
| | Table | |
| +------------------+ |
| | |
| v |
| +------------------+ |
| | Materialized | |
| | View (MV) | |
| +------------------+ |
| | |
| v |
| +------------------+ |
| | Storage Table | |
| +------------------+ |
+------------------------+


## Starting the Containers

Docker Compose can be used to start all the components.

Run the following command:

```bash
docker compose --profile olap up -d
```
This will spawn up the following services
1. kafka
2. clickhouse
3. opensearch

## Setting up Kafka

Kafka-UI is a visual tool for inspecting Kafka and it can be accessed at `localhost:8090` to view topics, partitions, consumers & generated events.

## Setting up Clickhouse

Once Clickhouse is up and running, you can interact with it via web.

You can either visit the URL (`http://localhost:8123/play`) where the Clickhouse server is running to get a playground, or you can bash into the Clickhouse container and execute commands manually.

Run the following commands:

```bash
# On your local terminal
docker compose exec clickhouse-server bash

# Inside the clickhouse-server container shell
clickhouse-client --user default

# Inside the clickhouse-client shell
SHOW TABLES;
```

## Configuring Analytics and Events Source

To use Clickhouse and Kafka, you need to enable the `analytics.source` and update the `events.source` in the configuration file.

You can do this in either the `config/development.toml` or `config/docker_compose.toml` file.

Here's an example of how to do this:

```toml
[analytics]
source = "clickhouse"

[events]
source = "kafka"
```

After making this change, save the file and restart your application for the changes to take effect.

## Enabling Data Features in Dashboard

To check the data features in the dashboard, you need to enable them in the `config/dashboard.toml` configuration file.

Here's an example of how to do this:

```toml
[default.features]
audit_trail=true
system_metrics=true
```
Loading

0 comments on commit 63dbd23

Please sign in to comment.