symfony - How does the configuration for Payum Bundle work? -


i'm new payum , trying create new payment gateway. can't figure out how config values relate files i've created (actions/factory etc).

here's have far;

payum:     security:         token_storage:             path\to\paymentsecuritytoken:                 doctrine:                     driver: orm     contexts:         xxx:             yyyy:                 api:                     options:                         sandbox: true         storages:             path\to\payment:                 doctrine:                     driver: orm 

i don't supposed put xxx , yyy. no matter values try still don't it. keep getting following error.

invalidconfigurationexception: unrecognized options "yyy" under "payum.contexts.xxx" 

can tell me values supposed , how values set related gateway , there needed config matches in gateway code?

thanks in advance :)

yyyy - payment (or storage) factory name. under section put payment specific options. defined in addconfiguration method. these options later passed method creates payment service

there factories shipped payum bundle. can use or add own. have implement paymentfactoryinterface , register others payum extension.

xxx - context name (you name it). idea behind pretty simple. can have 2 paypal payments configured differently. 1 , 1 eu (different paypal accounts). like:

payum:    contexts:        paypal_eu:            paypal_express_checkout_nvp:                username: ~                password: ~                signature: ~        paypal_us:            paypal_express_checkout_nvp:                username: ~                password: ~                signature: ~ 

later when want payment instance have use context name:

$payment = $container->get('payum')->getpayment('paypal_eu'); 

p.s. real config examples can find in docs.


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

thorough guide for profiling racket code -