mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-27 19:46:48 +08:00
638 lines
35 KiB
TOML
638 lines
35 KiB
TOML
# This is a sample config file whose sole purpose is to enumerate
|
|
# all the available configuration options, and is intended to be used
|
|
# solely as a reference. Please copy this file to create a config.
|
|
|
|
# Server configuration
|
|
[server]
|
|
port = 8080
|
|
host = "127.0.0.1"
|
|
# This is the grace time (in seconds) given to the actix-server to stop the execution
|
|
# For more details: https://actix.rs/docs/server/#graceful-shutdown
|
|
shutdown_timeout = 30
|
|
# HTTP Request body limit. Defaults to 32kB
|
|
request_body_limit = 32_768
|
|
# Proxy server configuration for connecting to payment gateways.
|
|
# Don't define the fields if a Proxy isn't needed. Empty strings will cause failure.
|
|
[proxy]
|
|
# http_url = "http proxy url" # Proxy all HTTP traffic via this proxy
|
|
# https_url = "https proxy url" # Proxy all HTTPS traffic via this proxy
|
|
idle_pool_connection_timeout = 90 # Timeout for idle pool connections (defaults to 90s)
|
|
|
|
|
|
# Main SQL data store credentials
|
|
[master_database]
|
|
username = "db_user" # DB Username
|
|
password = "db_pass" # DB Password. Use base-64 encoded kms encrypted value here when kms is enabled
|
|
host = "localhost" # DB Host
|
|
port = 5432 # DB Port
|
|
dbname = "hyperswitch_db" # Name of Database
|
|
pool_size = 5 # Number of connections to keep open
|
|
connection_timeout = 10 # Timeout for database connection in seconds
|
|
queue_strategy = "Fifo" # Add the queue strategy used by the database bb8 client
|
|
|
|
# Replica SQL data store credentials
|
|
[replica_database]
|
|
username = "replica_user" # DB Username
|
|
password = "db_pass" # DB Password. Use base-64 encoded kms encrypted value here when kms is enabled
|
|
host = "localhost" # DB Host
|
|
port = 5432 # DB Port
|
|
dbname = "hyperswitch_db" # Name of Database
|
|
pool_size = 5 # Number of connections to keep open
|
|
connection_timeout = 10 # Timeout for database connection in seconds
|
|
queue_strategy = "Fifo" # Add the queue strategy used by the database bb8 client
|
|
|
|
# Redis credentials
|
|
[redis]
|
|
host = "127.0.0.1"
|
|
port = 6379
|
|
pool_size = 5 # Number of connections to keep open
|
|
reconnect_max_attempts = 5 # Maximum number of reconnection attempts to make before failing. Set to 0 to retry forever.
|
|
reconnect_delay = 5 # Delay between reconnection attempts, in milliseconds
|
|
default_ttl = 300 # Default TTL for entries, in seconds
|
|
default_hash_ttl = 900 # Default TTL for hashes entries, in seconds
|
|
use_legacy_version = false # Resp protocol for fred crate (set this to true if using RESPv2 or redis version < 6)
|
|
stream_read_count = 1 # Default number of entries to read from stream if not provided in stream read options
|
|
auto_pipeline = true # Whether or not the client should automatically pipeline commands across tasks when possible.
|
|
disable_auto_backpressure = false # Whether or not to disable the automatic backpressure features when pipelining is enabled.
|
|
max_in_flight_commands = 5000 # The maximum number of in-flight commands (per connection) before backpressure will be applied.
|
|
default_command_timeout = 30 # An optional timeout to apply to all commands. In seconds
|
|
unresponsive_timeout = 10 # An optional timeout for Unresponsive commands in seconds. This should be less than default_command_timeout.
|
|
max_feed_count = 200 # The maximum number of frames that will be fed to a socket before flushing.
|
|
|
|
# This section provides configs for currency conversion api
|
|
[forex_api]
|
|
call_delay = 21600 # Api calls are made after every 6 hrs
|
|
local_fetch_retry_count = 5 # Fetch from Local cache has retry count as 5
|
|
local_fetch_retry_delay = 1000 # Retry delay for checking write condition
|
|
api_timeout = 20000 # Api timeouts once it crosses 20000 ms
|
|
api_key = "YOUR API KEY HERE" # Api key for making request to foreign exchange Api
|
|
fallback_api_key = "YOUR API KEY" # Api key for the fallback service
|
|
redis_lock_timeout = 26000 # Redis remains write locked for 26000 ms once the acquire_redis_lock is called
|
|
|
|
# Logging configuration. Logging can be either to file or console or both.
|
|
|
|
# Logging configuration for file logging
|
|
[log.file]
|
|
enabled = false # Toggle [true or false]
|
|
path = "logs" # specify the directory to create log files
|
|
file_name = "debug.log" # base name for log files.
|
|
# levels can be "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"
|
|
# defaults to "WARN"
|
|
level = "WARN"
|
|
# sets the log level for one or more crates
|
|
filtering_directive = "WARN,router=INFO,reqwest=INFO"
|
|
# ^^^^ ^^^^---------^^^^-- sets the log level for the
|
|
# | router and reqwest crates to INFO.
|
|
# |
|
|
# |______________________________ sets the log level for all
|
|
# other crates to WARN.
|
|
|
|
# Logging configuration for console logging
|
|
[log.console]
|
|
enabled = true # boolean [true or false]
|
|
log_format = "default" # Log format. "default" or "json"
|
|
# levels can be "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF"
|
|
# defaults to "WARN"
|
|
level = "DEBUG"
|
|
# sets the log level for one or more crates
|
|
filtering_directive = "WARN,router=INFO,reqwest=INFO"
|
|
# ^^^^ ^^^^---------^^^^-- sets the log level for the
|
|
# | router and reqwest crates to INFO.
|
|
# |
|
|
# |______________________________ sets the log level for all
|
|
# other crates to WARN.
|
|
|
|
# Telemetry configuration for metrics and traces
|
|
[log.telemetry]
|
|
traces_enabled = false # boolean [true or false], whether traces are enabled
|
|
metrics_enabled = false # boolean [true or false], whether metrics are enabled
|
|
ignore_errors = false # boolean [true or false], whether to ignore errors during traces or metrics pipeline setup
|
|
sampling_rate = 0.1 # decimal rate between 0.0 - 1.0
|
|
otel_exporter_otlp_endpoint = "http://localhost:4317" # endpoint to send metrics and traces to, can include port number
|
|
otel_exporter_otlp_timeout = 5000 # timeout (in milliseconds) for sending metrics and traces
|
|
use_xray_generator = false # Set this to true for AWS X-ray compatible traces
|
|
route_to_trace = ["*/confirm"]
|
|
|
|
# This section provides some secret values.
|
|
[secrets]
|
|
master_enc_key = "sample_key" # Master Encryption key used to encrypt merchant wise encryption key. Should be 32-byte long.
|
|
admin_api_key = "test_admin" # admin API key for admin authentication.
|
|
jwt_secret = "secret" # JWT secret used for user authentication.
|
|
recon_admin_api_key = "recon_test_admin" # recon_admin API key for recon authentication.
|
|
|
|
# Locker settings contain details for accessing a card locker, a
|
|
# 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
|
|
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
|
|
|
|
[webhook_source_verification_call]
|
|
connectors_with_webhook_source_verification_call = "paypal" # List of connectors which has additional source verification api-call
|
|
|
|
[jwekey] # 4 priv/pub key pair
|
|
vault_encryption_key = "" # public key in pem format, corresponding private key in basilisk-hs
|
|
rust_locker_encryption_key = "" # public key in pem format, corresponding private key in rust locker
|
|
vault_private_key = "" # private key in pem format, corresponding public key in basilisk-hs
|
|
|
|
# Refund configuration
|
|
[refund]
|
|
max_attempts = 10 # Number of refund attempts allowed
|
|
max_age = 365 # Max age of a refund in days.
|
|
|
|
[webhooks]
|
|
outgoing_enabled = true
|
|
|
|
# Validity of an Ephemeral Key in Hours
|
|
[eph_key]
|
|
validity = 1
|
|
|
|
[api_keys]
|
|
# Hex-encoded 32-byte long (64 characters long when hex-encoded) key used for calculating hashes of API keys
|
|
hash_key = "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef"
|
|
|
|
# Connector configuration, provided attributes will be used to fulfill API requests.
|
|
# Examples provided here are sandbox/test base urls, can be replaced by live or mock
|
|
# base urls based on your need.
|
|
# Note: These are not optional attributes. hyperswitch request can fail due to invalid/empty values.
|
|
[connectors]
|
|
aci.base_url = "https://eu-test.oppwa.com/"
|
|
adyen.base_url = "https://checkout-test.adyen.com/"
|
|
adyen.secondary_base_url = "https://pal-test.adyen.com/"
|
|
airwallex.base_url = "https://api-demo.airwallex.com/"
|
|
applepay.base_url = "https://apple-pay-gateway.apple.com/"
|
|
authorizedotnet.base_url = "https://apitest.authorize.net/xml/v1/request.api"
|
|
bambora.base_url = "https://api.na.bambora.com"
|
|
bankofamerica.base_url = "https://apitest.merchant-services.bankofamerica.com/"
|
|
billwerk.base_url = "https://api.reepay.com/"
|
|
billwerk.secondary_base_url = "https://card.reepay.com/"
|
|
bitpay.base_url = "https://test.bitpay.com"
|
|
bluesnap.base_url = "https://sandbox.bluesnap.com/"
|
|
bluesnap.secondary_base_url = "https://sandpay.bluesnap.com/"
|
|
boku.base_url = "https://$-api4-stage.boku.com"
|
|
braintree.base_url = "https://api.sandbox.braintreegateway.com/"
|
|
braintree.secondary_base_url = "https://payments.sandbox.braintree-api.com/graphql"
|
|
cashtocode.base_url = "https://cluster05.api-test.cashtocode.com"
|
|
checkout.base_url = "https://api.sandbox.checkout.com/"
|
|
coinbase.base_url = "https://api.commerce.coinbase.com"
|
|
cryptopay.base_url = "https://business-sandbox.cryptopay.me"
|
|
cybersource.base_url = "https://apitest.cybersource.com/"
|
|
dlocal.base_url = "https://sandbox.dlocal.com/"
|
|
dummyconnector.base_url = "http://localhost:8080/dummy-connector"
|
|
ebanx.base_url = "https://sandbox.ebanxpay.com/"
|
|
fiserv.base_url = "https://cert.api.fiservapps.com/"
|
|
forte.base_url = "https://sandbox.forte.net/api/v3"
|
|
globalpay.base_url = "https://apis.sandbox.globalpay.com/ucp/"
|
|
globepay.base_url = "https://pay.globepay.co/"
|
|
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{{klarna_region}}.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/"
|
|
multisafepay.base_url = "https://testapi.multisafepay.com/"
|
|
netcetera.base_url = "https://{{merchant_endpoint_prefix}}.3ds-server.prev.netcetera-cloud-payment.ch"
|
|
nexinets.base_url = "https://apitest.payengine.de/v1"
|
|
nmi.base_url = "https://secure.nmi.com/"
|
|
noon.base_url = "https://api-test.noonpayments.com/"
|
|
noon.key_mode = "Test"
|
|
nuvei.base_url = "https://ppp-test.nuvei.com/"
|
|
opayo.base_url = "https://pi-test.sagepay.com/"
|
|
opennode.base_url = "https://dev-api.opennode.com"
|
|
payeezy.base_url = "https://api-cert.payeezy.com/"
|
|
payme.base_url = "https://sandbox.payme.io/"
|
|
payone.base_url = "https://payment.preprod.payone.com/"
|
|
paypal.base_url = "https://api-m.sandbox.paypal.com/"
|
|
payu.base_url = "https://secure.snd.payu.com/"
|
|
placetopay.base_url = "https://test.placetopay.com/rest/gateway"
|
|
powertranz.base_url = "https://staging.ptranz.com/api/"
|
|
prophetpay.base_url = "https://ccm-thirdparty.cps.golf/"
|
|
rapyd.base_url = "https://sandboxapi.rapyd.net"
|
|
riskified.base_url = "https://sandbox.riskified.com/api"
|
|
shift4.base_url = "https://api.shift4.com/"
|
|
signifyd.base_url = "https://api.signifyd.com/"
|
|
square.base_url = "https://connect.squareupsandbox.com/"
|
|
square.secondary_base_url = "https://pci-connect.squareupsandbox.com/"
|
|
stax.base_url = "https://apiprod.fattlabs.com/"
|
|
stripe.base_url = "https://api.stripe.com/"
|
|
threedsecureio.base_url = "https://service.sandbox.3dsecure.io"
|
|
stripe.base_url_file_upload = "https://files.stripe.com/"
|
|
trustpay.base_url = "https://test-tpgw.trustpay.eu/"
|
|
trustpay.base_url_bank_redirects = "https://aapi.trustpay.eu/"
|
|
tsys.base_url = "https://stagegw.transnox.com/"
|
|
volt.base_url = "https://api.sandbox.volt.io/"
|
|
wise.base_url = "https://api.sandbox.transferwise.tech/"
|
|
worldline.base_url = "https://eu.sandbox.api-ingenico.com/"
|
|
worldpay.base_url = "https://try.access.worldpay.com/"
|
|
zsl.base_url = "https://api.sitoffalb.net/"
|
|
zen.base_url = "https://api.zen-test.com/"
|
|
zen.secondary_base_url = "https://secure.zen-test.com/"
|
|
|
|
#Payment Method Filters Based on Country and Currency
|
|
[pm_filters.default]
|
|
apple_pay = { country = "AU,CN,HK,JP,MO,MY,NZ,SG,TW,AM,AT,AZ,BY,BE,BG,HR,CY,CZ,DK,EE,FO,FI,FR,GE,DE,GR,GL,GG,HU,IS,IE,IM,IT,KZ,JE,LV,LI,LT,LU,MT,MD,MC,ME,NL,NO,PL,PT,RO,SM,RS,SK,SI,ES,SE,CH,UA,GB,AR,CO,CR,BR,MX,PE,BH,IL,JO,KW,PS,QA,SA,AE,CA,UM,US,KR,VN,MA,ZA,VA,CL,SV,GT,HN,PA", currency = "AED,AUD,CHF,CAD,EUR,GBP,HKD,SGD,USD" }
|
|
|
|
# Bank redirect configs for allowed banks through online_banking_czech_republic payment method
|
|
[bank_config.online_banking_czech_republic]
|
|
adyen = { banks = "ceska_sporitelna,komercni_banka,platnosc_online_karta_platnicza" }
|
|
|
|
# Bank redirect configs for allowed banks through online_banking_slovakia payment method
|
|
[bank_config.online_banking_slovakia]
|
|
adyen = { banks = "e_platby_vub,postova_banka,sporo_pay,tatra_pay,viamo" }
|
|
|
|
# Bank redirect configs for allowed banks through online_banking_poland payment method
|
|
[bank_config.online_banking_poland]
|
|
adyen = { banks = "blik_psp,place_zipko,m_bank,pay_with_ing,santander_przelew24,bank_pekaosa,bank_millennium,pay_with_alior_bank,banki_spoldzielcze,pay_with_inteligo,bnp_paribas_poland,bank_nowy_sa,credit_agricole,pay_with_bos,pay_with_citi_handlowy,pay_with_plus_bank,toyota_bank,velo_bank,e_transfer_pocztowy24" }
|
|
|
|
# Bank redirect configs for allowed banks through open_banking_uk payment method
|
|
[bank_config.open_banking_uk]
|
|
adyen = { banks = "aib,bank_of_scotland,danske_bank,first_direct,first_trust,halifax,lloyds,monzo,nat_west,nationwide_bank,royal_bank_of_scotland,starling,tsb_bank,tesco_bank,ulster_bank,barclays,hsbc_bank,revolut,santander_przelew24,open_bank_success,open_bank_failure,open_bank_cancelled" }
|
|
|
|
# Bank redirect configs for allowed banks through przelewy24 payment method
|
|
[bank_config.przelewy24]
|
|
stripe = { banks = "alior_bank,bank_millennium,bank_nowy_bfg_sa,bank_pekao_sa,banki_spbdzielcze,blik,bnp_paribas,boz,citi,credit_agricole,e_transfer_pocztowy24,getin_bank,idea_bank,inteligo,mbank_mtransfer,nest_przelew,noble_pay,pbac_z_ipko,plus_bank,santander_przelew24,toyota_bank,volkswagen_bank" }
|
|
|
|
# This data is used to call respective connectors for wallets and cards
|
|
[connectors.supported]
|
|
wallets = ["klarna", "mifinity", "braintree", "applepay"]
|
|
rewards = ["cashtocode", "zen"]
|
|
cards = [
|
|
"adyen",
|
|
"authorizedotnet",
|
|
"coinbase",
|
|
"cryptopay",
|
|
"braintree",
|
|
"checkout",
|
|
"cybersource",
|
|
"globalpay",
|
|
"globepay",
|
|
"gocardless",
|
|
"gpayments",
|
|
"helcim",
|
|
"mollie",
|
|
"paypal",
|
|
"shift4",
|
|
"square",
|
|
"stax",
|
|
"stripe",
|
|
"threedsecureio",
|
|
"worldpay",
|
|
"zen",
|
|
"zsl",
|
|
]
|
|
|
|
# Scheduler settings provides a point to modify the behaviour of scheduler flow.
|
|
# It defines the streams/queues name and configuration as well as event selection variables
|
|
[scheduler]
|
|
stream = "SCHEDULER_STREAM"
|
|
graceful_shutdown_interval = 60000 # Specifies how much time to wait while re-attempting shutdown for a service (in milliseconds)
|
|
loop_interval = 5000 # Specifies how much time to wait before starting the defined behaviour of producer or consumer (in milliseconds)
|
|
|
|
[scheduler.consumer]
|
|
consumer_group = "SCHEDULER_GROUP"
|
|
disabled = false # This flag decides if the consumer should actively consume task
|
|
|
|
[scheduler.producer]
|
|
upper_fetch_limit = 0 # Upper limit for fetching entries from the redis queue (in seconds)
|
|
lower_fetch_limit = 1800 # Lower limit for fetching entries from redis queue (in seconds)
|
|
lock_key = "PRODUCER_LOCKING_KEY" # The following keys defines the producer lock that is created in redis with
|
|
lock_ttl = 160 # the ttl being the expiry (in seconds)
|
|
|
|
# Scheduler server configuration
|
|
[scheduler.server]
|
|
port = 3000 # Port on which the server will listen for incoming requests
|
|
host = "127.0.0.1" # Host IP address to bind the server to
|
|
workers = 1 # Number of actix workers to handle incoming requests concurrently
|
|
|
|
batch_size = 200 # Specifies the batch size the producer will push under a single entry in the redis queue
|
|
|
|
# Drainer configuration, which handles draining raw SQL queries from Redis streams to the SQL database
|
|
[drainer]
|
|
stream_name = "DRAINER_STREAM" # Specifies the stream name to be used by the drainer
|
|
num_partitions = 64 # Specifies the number of partitions the stream will be divided into
|
|
max_read_count = 100 # Specifies the maximum number of entries that would be read from redis stream in one call
|
|
shutdown_interval = 1000 # Specifies how much time to wait, while waiting for threads to complete execution (in milliseconds)
|
|
loop_interval = 500 # Specifies how much time to wait after checking all the possible streams in completed (in milliseconds)
|
|
|
|
# Filtration logic for list payment method, allowing use to limit payment methods based on the requirement country and currency
|
|
[pm_filters.stripe]
|
|
# ^--- This can be any connector (can be multiple)
|
|
paypal = { currency = "USD,INR", country = "US" }
|
|
# ^ ^------- comma-separated values
|
|
# ^------------------------------- any valid payment method type (can be multiple) (for cards this should be card_network)
|
|
# If either currency or country isn't provided then, all possible values are accepted
|
|
|
|
[cors]
|
|
max_age = 30 # Maximum time (in seconds) for which this CORS request may be cached.
|
|
origins = "http://localhost:8080" # List of origins that are allowed to make requests.
|
|
allowed_methods = "GET,POST,PUT,DELETE" # List of methods that are allowed
|
|
wildcard_origin = false # If true, allows any origin to make requests
|
|
|
|
# EmailClient configuration. Only applicable when the `email` feature flag is enabled.
|
|
[email]
|
|
sender_email = "example@example.com" # Sender email
|
|
aws_region = "" # AWS region used by AWS SES
|
|
base_url = "" # Base url used when adding links that should redirect to self
|
|
allowed_unverified_days = 1 # Number of days the api calls ( with jwt token ) can be made without verifying the email
|
|
active_email_client = "SES" # The currently active email client
|
|
|
|
# Configuration for aws ses, applicable when the active email client is SES
|
|
[email.aws_ses]
|
|
email_role_arn = "" # The amazon resource name ( arn ) of the role which has permission to send emails
|
|
sts_role_session_name = "" # An identifier for the assumed role session, used to uniquely identify a session.
|
|
|
|
[user]
|
|
password_validity_in_days = 90 # Number of days after which password should be updated
|
|
two_factor_auth_expiry_in_secs = 300 # Number of seconds after which 2FA should be done again if doing update/change from inside
|
|
totp_issuer_name = "Hyperswitch" # Name of the issuer for TOTP
|
|
|
|
#tokenization configuration which describe token lifetime and payment method for specific connector
|
|
[tokenization]
|
|
stripe = { long_lived_token = false, payment_method = "wallet", payment_method_type = { type = "disable_only", list = "google_pay" } }
|
|
checkout = { long_lived_token = false, payment_method = "wallet", apple_pay_pre_decrypt_flow = "network_tokenization" }
|
|
mollie = { long_lived_token = false, payment_method = "card" }
|
|
stax = { long_lived_token = true, payment_method = "card,bank_debit" }
|
|
square = { long_lived_token = false, payment_method = "card" }
|
|
braintree = { long_lived_token = false, payment_method = "card" }
|
|
gocardless = { long_lived_token = true, payment_method = "bank_debit" }
|
|
billwerk = { long_lived_token = false, payment_method = "card" }
|
|
|
|
[temp_locker_enable_config]
|
|
stripe = { payment_method = "bank_transfer" }
|
|
nuvei = { payment_method = "card" }
|
|
shift4 = { payment_method = "card" }
|
|
bluesnap = { payment_method = "card" }
|
|
bankofamerica = { payment_method = "card" }
|
|
cybersource = { payment_method = "card" }
|
|
nmi = { payment_method = "card" }
|
|
payme = { payment_method = "card" }
|
|
|
|
[dummy_connector]
|
|
enabled = true # Whether dummy connector is enabled or not
|
|
payment_ttl = 172800 # Time to live for dummy connector payment in redis
|
|
payment_duration = 1000 # Fake delay duration for dummy connector payment
|
|
payment_tolerance = 100 # Fake delay tolerance for dummy connector payment
|
|
payment_retrieve_duration = 500 # Fake delay duration for dummy connector payment sync
|
|
payment_retrieve_tolerance = 100 # Fake delay tolerance for dummy connector payment sync
|
|
payment_complete_duration = 500 # Fake delay duration for dummy connector payment complete
|
|
payment_complete_tolerance = 100 # Fake delay tolerance for dummy connector payment complete
|
|
refund_ttl = 172800 # Time to live for dummy connector refund in redis
|
|
refund_duration = 1000 # Fake delay duration for dummy connector refund
|
|
refund_tolerance = 100 # Fake delay tolerance for dummy connector refund
|
|
refund_retrieve_duration = 500 # Fake delay duration for dummy connector refund sync
|
|
refund_retrieve_tolerance = 100 # Fake delay tolerance for dummy connector refund sync
|
|
authorize_ttl = 36000 # Time to live for dummy connector authorize request in redis
|
|
assets_base_url = "https://www.example.com/" # Base url for dummy connector assets
|
|
default_return_url = "https://www.example.com/" # Default return url when no return url is passed while payment
|
|
slack_invite_url = "https://www.example.com/" # Slack invite url for hyperswitch
|
|
discord_invite_url = "https://www.example.com/" # Discord invite url for hyperswitch
|
|
|
|
[mandates.supported_payment_methods]
|
|
card.credit = { connector_list = "stripe,adyen,cybersource,bankofamerica" } # Mandate supported payment method type and connector for card
|
|
wallet.paypal = { connector_list = "adyen" } # Mandate supported payment method type and connector for wallets
|
|
pay_later.klarna = { connector_list = "adyen" } # Mandate supported payment method type and connector for pay_later
|
|
bank_debit.ach = { connector_list = "gocardless" } # Mandate supported payment method type and connector for bank_debit
|
|
bank_debit.becs = { connector_list = "gocardless" } # Mandate supported payment method type and connector for bank_debit
|
|
bank_debit.sepa = { connector_list = "gocardless" } # Mandate supported payment method type and connector for bank_debit
|
|
bank_redirect.ideal = { connector_list = "stripe,adyen,globalpay" } # Mandate supported payment method type and connector for bank_redirect
|
|
bank_redirect.sofort = { connector_list = "stripe,adyen,globalpay" }
|
|
wallet.apple_pay = { connector_list = "stripe,adyen,cybersource,noon,bankofamerica" }
|
|
wallet.google_pay = { connector_list = "bankofamerica" }
|
|
bank_redirect.giropay = { connector_list = "adyen,globalpay" }
|
|
|
|
|
|
[mandates.update_mandate_supported]
|
|
card.credit = { connector_list = "cybersource" } # Update Mandate supported payment method type and connector for card
|
|
card.debit = { connector_list = "cybersource" } # Update Mandate supported payment method type and connector for card
|
|
|
|
# Required fields info used while listing the payment_method_data
|
|
[required_fields.pay_later] # payment_method = "pay_later"
|
|
afterpay_clearpay = { fields = { stripe = [ # payment_method_type = afterpay_clearpay, connector = "stripe"
|
|
# Required fields vector with its respective display name in front-end and field_type
|
|
{ required_field = "shipping.address.first_name", display_name = "first_name", field_type = "text" },
|
|
{ required_field = "shipping.address.last_name", display_name = "last_name", field_type = "text" },
|
|
{ required_field = "shipping.address.country", display_name = "country", field_type = { drop_down = { options = [
|
|
"US",
|
|
"IN",
|
|
] } } },
|
|
] } }
|
|
|
|
[payouts]
|
|
payout_eligibility = true # Defaults the eligibility of a payout method to true in case connector does not provide checks for payout eligibility
|
|
|
|
[pm_filters.adyen]
|
|
sofort = { country = "AT,BE,DE,ES,CH,NL", currency = "CHF,EUR" }
|
|
paypal = { country = "AU,NZ,CN,JP,HK,MY,TH,KR,PH,ID,AE,KW,BR,ES,GB,SE,NO,SK,AT,NL,DE,HU,CY,LU,CH,BE,FR,DK,FI,RO,HR,UA,MT,SI,GI,PT,IE,CZ,EE,LT,LV,IT,PL,IS,CA,US", currency = "AUD,BRL,CAD,CZK,DKK,EUR,HKD,HUF,INR,JPY,MYR,MXN,NZD,NOK,PHP,PLN,RUB,GBP,SGD,SEK,CHF,THB,USD" }
|
|
klarna = { country = "AU,AT,BE,CA,CZ,DK,FI,FR,DE,GR,IE,IT,NO,PL,PT,RO,ES,SE,CH,NL,GB,US", currency = "AUD,EUR,CAD,CZK,DKK,NOK,PLN,RON,SEK,CHF,GBP,USD" }
|
|
ideal = { country = "NL", currency = "EUR" }
|
|
online_banking_fpx = { country = "MY", currency = "MYR" }
|
|
online_banking_thailand = { country = "TH", currency = "THB" }
|
|
touch_n_go = { country = "MY", currency = "MYR" }
|
|
atome = { country = "MY,SG", currency = "MYR,SGD" }
|
|
swish = { country = "SE", currency = "SEK" }
|
|
permata_bank_transfer = { country = "ID", currency = "IDR" }
|
|
bca_bank_transfer = { country = "ID", currency = "IDR" }
|
|
bni_va = { country = "ID", currency = "IDR" }
|
|
bri_va = { country = "ID", currency = "IDR" }
|
|
cimb_va = { country = "ID", currency = "IDR" }
|
|
danamon_va = { country = "ID", currency = "IDR" }
|
|
mandiri_va = { country = "ID", currency = "IDR" }
|
|
alfamart = { country = "ID", currency = "IDR" }
|
|
indomaret = { country = "ID", currency = "IDR" }
|
|
open_banking_uk = { country = "GB", currency = "GBP" }
|
|
oxxo = { country = "MX", currency = "MXN" }
|
|
pay_safe_card = { country = "AT,AU,BE,BR,BE,CA,HR,CY,CZ,DK,FI,FR,GE,DE,GI,HU,IS,IE,KW,LV,IE,LI,LT,LU,MT,MX,MD,ME,NL,NZ,NO,PY,PE,PL,PT,RO,SA,RS,SK,SI,ES,SE,CH,TR,AE,GB,US,UY", currency = "EUR,AUD,BRL,CAD,CZK,DKK,GEL,GIP,HUF,KWD,CHF,MXN,MDL,NZD,NOK,PYG,PEN,PLN,RON,SAR,RSD,SEK,TRY,AED,GBP,USD,UYU" }
|
|
seven_eleven = { country = "JP", currency = "JPY" }
|
|
lawson = { country = "JP", currency = "JPY" }
|
|
mini_stop = { country = "JP", currency = "JPY" }
|
|
family_mart = { country = "JP", currency = "JPY" }
|
|
seicomart = { country = "JP", currency = "JPY" }
|
|
pay_easy = { country = "JP", currency = "JPY" }
|
|
boleto = { country = "BR", currency = "BRL" }
|
|
|
|
[pm_filters.volt]
|
|
open_banking_uk = { country = "DE,GB,AT,BE,CY,EE,ES,FI,FR,GR,HR,IE,IT,LT,LU,LV,MT,NL,PT,SI,SK,BG,CZ,DK,HU,NO,PL,RO,SE,AU,BR", currency = "EUR,GBP,DKK,NOK,PLN,SEK,AUD,BRL" }
|
|
|
|
[pm_filters.zen]
|
|
credit = { not_available_flows = { capture_method = "manual" } }
|
|
debit = { not_available_flows = { capture_method = "manual" } }
|
|
boleto = { country = "BR", currency = "BRL" }
|
|
efecty = { country = "CO", currency = "COP" }
|
|
multibanco = { country = "PT", currency = "EUR" }
|
|
pago_efectivo = { country = "PE", currency = "PEN" }
|
|
pse = { country = "CO", currency = "COP" }
|
|
pix = { country = "BR", currency = "BRL" }
|
|
red_compra = { country = "CL", currency = "CLP" }
|
|
red_pagos = { country = "UY", currency = "UYU" }
|
|
|
|
[pm_filters.zsl]
|
|
local_bank_transfer = { country = "CN", currency = "CNY" }
|
|
|
|
[pm_filters.bankofamerica]
|
|
credit = { currency = "USD" }
|
|
debit = { currency = "USD" }
|
|
apple_pay = { currency = "USD" }
|
|
google_pay = { currency = "USD" }
|
|
|
|
[pm_filters.stax]
|
|
credit = { currency = "USD" }
|
|
debit = { currency = "USD" }
|
|
ach = { currency = "USD" }
|
|
|
|
[pm_filters.prophetpay]
|
|
card_redirect = { currency = "USD" }
|
|
|
|
[pm_filters.helcim]
|
|
credit = { currency = "USD" }
|
|
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 = "CHF,DKK,EUR,GBP,NOK,PLN,SEK,USD,AUD,NZD,CAD" }
|
|
|
|
[connector_customer]
|
|
connector_list = "gocardless,stax,stripe"
|
|
payout_connector_list = "stripe,wise"
|
|
|
|
[bank_config.online_banking_fpx]
|
|
adyen.banks = "affin_bank,agro_bank,alliance_bank,am_bank,bank_islam,bank_muamalat,bank_rakyat,bank_simpanan_nasional,cimb_bank,hong_leong_bank,hsbc_bank,kuwait_finance_house,maybank,ocbc_bank,public_bank,rhb_bank,standard_chartered_bank,uob_bank"
|
|
|
|
[bank_config.online_banking_thailand]
|
|
adyen.banks = "bangkok_bank,krungsri_bank,krung_thai_bank,the_siam_commercial_bank,kasikorn_bank"
|
|
|
|
[multiple_api_version_supported_connectors]
|
|
supported_connectors = "braintree"
|
|
|
|
[applepay_decrypt_keys]
|
|
apple_pay_ppc = "APPLE_PAY_PAYMENT_PROCESSING_CERTIFICATE" # Payment Processing Certificate provided by Apple Pay (https://developer.apple.com/) Certificates, Identifiers & Profiles > Apple Pay Payment Processing Certificate
|
|
apple_pay_ppc_key = "APPLE_PAY_PAYMENT_PROCESSING_CERTIFICATE_KEY" # Private key generated by Elliptic-curve prime256v1 curve. You can use `openssl ecparam -out private.key -name prime256v1 -genkey` to generate the private key
|
|
apple_pay_merchant_cert = "APPLE_PAY_MERCHNAT_CERTIFICATE" # Merchant Certificate provided by Apple Pay (https://developer.apple.com/) Certificates, Identifiers & Profiles > Apple Pay Merchant Identity Certificate
|
|
apple_pay_merchant_cert_key = "APPLE_PAY_MERCHNAT_CERTIFICATE_KEY" # Private key generated by RSA:2048 algorithm. Refer Hyperswitch Docs (https://docs.hyperswitch.io/hyperswitch-cloud/payment-methods-setup/wallets/apple-pay/ios-application/) to generate the private key
|
|
|
|
[applepay_merchant_configs]
|
|
# Run below command to get common merchant identifier for applepay in shell
|
|
#
|
|
# CERT_PATH="path/to/certificate.pem"
|
|
# MERCHANT_ID=$(openssl x509 -in "$CERT_PATH" -noout -text |
|
|
# awk -v oid="1.2.840.113635.100.6.32" '
|
|
# BEGIN { RS = "\n\n" }
|
|
# /X509v3 extensions/ { in_extension=1 }
|
|
# in_extension && /'"$oid"'/ { print $0; exit }' |
|
|
# grep -oE '\.@[A-F0-9]+' | sed 's/^\.@//'
|
|
# )
|
|
# echo "Merchant ID: $MERCHANT_ID"
|
|
common_merchant_identifier = "APPLE_PAY_COMMON_MERCHANT_IDENTIFIER" # This can be obtained by decrypting the apple_pay_ppc_key as shown above in comments
|
|
merchant_cert = "APPLE_PAY_MERCHANT_CERTIFICATE" # Merchant Certificate provided by Apple Pay (https://developer.apple.com/) Certificates, Identifiers & Profiles > Apple Pay Merchant Identity Certificate
|
|
merchant_cert_key = "APPLE_PAY_MERCHANT_CERTIFICATE_KEY" # Private key generate by RSA:2048 algorithm. Refer Hyperswitch Docs (https://docs.hyperswitch.io/hyperswitch-cloud/payment-methods-setup/wallets/apple-pay/ios-application/) to generate the private key
|
|
applepay_endpoint = "https://apple-pay-gateway.apple.com/paymentservices/registerMerchant" # Apple pay gateway merchant endpoint
|
|
|
|
[payment_link]
|
|
sdk_url = "http://localhost:9090/0.16.7/v0/HyperLoader.js"
|
|
|
|
[payment_method_auth]
|
|
redis_expiry = 900
|
|
pm_auth_key = "Some_pm_auth_key"
|
|
|
|
# Analytics configuration.
|
|
[analytics]
|
|
source = "sqlx" # The Analytics source/strategy to be used
|
|
|
|
[analytics.clickhouse]
|
|
username = "" # Clickhouse username
|
|
password = "" # Clickhouse password (optional)
|
|
host = "" # Clickhouse host in http(s)://<URL>:<PORT> format
|
|
database_name = "" # Clickhouse database name
|
|
|
|
[analytics.sqlx]
|
|
username = "db_user" # Analytics DB Username
|
|
password = "db_pass" # Analytics DB Password
|
|
host = "localhost" # Analytics DB Host
|
|
port = 5432 # Analytics DB Port
|
|
dbname = "hyperswitch_db" # Name of Database
|
|
pool_size = 5 # Number of connections to keep open
|
|
connection_timeout = 10 # Timeout for database connection in seconds
|
|
queue_strategy = "Fifo" # Add the queue strategy used by the database bb8 client
|
|
|
|
# Config for KV setup
|
|
[kv_config]
|
|
# TTL for KV in seconds
|
|
ttl = 900
|
|
|
|
[frm]
|
|
enabled = true
|
|
|
|
[paypal_onboarding]
|
|
client_id = "paypal_client_id" # Client ID for PayPal onboarding
|
|
client_secret = "paypal_secret_key" # Secret key for PayPal onboarding
|
|
partner_id = "paypal_partner_id" # Partner ID for PayPal onboarding
|
|
enabled = true # Switch to enable or disable PayPal onboarding
|
|
|
|
[events]
|
|
source = "logs" # The event sink to push events supports kafka or logs (stdout)
|
|
|
|
[events.kafka]
|
|
brokers = [] # Kafka broker urls for bootstrapping the client
|
|
intent_analytics_topic = "topic" # Kafka topic to be used for PaymentIntent events
|
|
attempt_analytics_topic = "topic" # Kafka topic to be used for PaymentAttempt events
|
|
refund_analytics_topic = "topic" # Kafka topic to be used for Refund events
|
|
api_logs_topic = "topic" # Kafka topic to be used for incoming api events
|
|
connector_logs_topic = "topic" # Kafka topic to be used for connector api events
|
|
outgoing_webhook_logs_topic = "topic" # Kafka topic to be used for outgoing webhook events
|
|
dispute_analytics_topic = "topic" # Kafka topic to be used for Dispute events
|
|
audit_events_topic = "topic" # Kafka topic to be used for Payment Audit events
|
|
payout_analytics_topic = "topic" # Kafka topic to be used for Payouts and PayoutAttempt events
|
|
consolidated_events_topic = "topic" # Kafka topic to be used for Consolidated events
|
|
|
|
# File storage configuration
|
|
[file_storage]
|
|
file_storage_backend = "aws_s3" # File storage backend to be used
|
|
|
|
[file_storage.aws_s3]
|
|
region = "us-east-1" # The AWS region used by the AWS S3 for file storage
|
|
bucket_name = "bucket1" # The AWS S3 bucket name for file storage
|
|
|
|
[secrets_management]
|
|
secrets_manager = "aws_kms" # Secrets manager client to be used
|
|
|
|
[secrets_management.aws_kms]
|
|
key_id = "kms_key_id" # The AWS key ID used by the KMS SDK for decrypting data.
|
|
region = "kms_region" # The AWS region used by the KMS SDK for decrypting data.
|
|
|
|
[encryption_management]
|
|
encryption_manager = "aws_kms" # Encryption manager client to be used
|
|
|
|
[encryption_management.aws_kms]
|
|
key_id = "kms_key_id" # The AWS key ID used by the KMS SDK for decrypting data.
|
|
region = "kms_region" # The AWS region used by the KMS SDK for decrypting data.
|
|
|
|
[opensearch]
|
|
host = "https://localhost:9200"
|
|
|
|
[opensearch.auth]
|
|
auth = "basic"
|
|
username = "admin"
|
|
password = "admin"
|
|
region = "eu-central-1"
|
|
|
|
[opensearch.indexes]
|
|
payment_attempts = "hyperswitch-payment-attempt-events"
|
|
payment_intents = "hyperswitch-payment-intent-events"
|
|
refunds = "hyperswitch-refund-events"
|
|
disputes = "hyperswitch-dispute-events"
|
|
|
|
[saved_payment_methods]
|
|
sdk_eligible_payment_methods = "card"
|
|
|
|
[multitenancy]
|
|
enabled = false
|
|
|
|
[multitenancy.tenants]
|
|
public = { name = "hyperswitch", base_url = "http://localhost:8080", schema = "public", redis_key_prefix = ""} # schema -> Postgres db schema, redis_key_prefix -> redis key distinguisher, base_url -> url of the tenant |