Skip to main content
Version: 2.0.0

Settings

This page explains every GP WebPay setting used by the plugin and what admins should configure before enabling live payments.

Open settings in Craft CP:

  1. Yui -> Payment plugins
  2. GP WebPay

Right panel switches

The right-side switches control runtime behavior:

  • Enable GP WebPay: registers the gateway in store payment methods.
  • Enable Subscriptions: adds gpwebpay-subscription gateway variant.
  • Enable Sandbox Mode: routes requests to GP WebPay test endpoint.

If the plugin is disabled, gateway registration is skipped.

General tab

Use this tab for checkout-facing labels:

  • Display Name (settings[name])
  • Select button name (settings[buttonName])
  • Instructions (settings[instructions])

Recommended values:

  • Display Name: clear payment label customers recognize, for example Card payment (GP WebPay).
  • Select button name: action-style text such as Pay now.
  • Instructions: one short sentence explaining redirect to secure payment page.

When subscriptions are enabled, additional required fields appear:

  • Subscription Display Name
  • Subscription Button Name
  • Subscription Instructions

Subscription example:

  • Subscription Display Name: Card payment - recurring
  • Subscription Button Name: Start subscription
  • Subscription Instructions: After confirmation, recurring card payment authorization will be completed on GP WebPay page.

Restrictions tab

Use restrictions to control when/where the method appears:

  • Visible From / Visible To: date-time visibility window.
  • Available in countries: country whitelist for showing this payment method.

If no countries are selected, admins should treat it as available broadly by default behavior.

Practical usage examples:

  • Launch in one market first: choose only sk.
  • Maintenance window: set Visible To for temporary disable without removing credentials.
  • Campaign method: use both date range and countries to control rollout.

Settings tab (credentials and technical setup)

Core required fields (when plugin is enabled):

  • Merchant number
  • Public key file path
  • Private key file path
  • Private key password
  • Default currency
  • Default language

Field meaning and examples:

  • Merchant number: GP WebPay merchant identifier provided by PSP contract.
  • Public key file path: merchant certificate/public key file used for response validation.
  • Private key file path: private key used for request signing.
  • Private key password: password matching private key file.
  • Default currency: currency sent to GP WebPay (EUR, CZK, HUF, USD in current plugin UI options).
  • Default language: gateway language (for example sk-SK, en-US, cs-CZ).

Example sandbox configuration:

  • Merchant number: 1234567890
  • Public key file path: /web/gpwebpay/gpe.signing_test.cer
  • Private key file path: /web/gpwebpay/gpwebpay-pvk.key
  • Private key password: ********
  • Default currency: EUR
  • Default language: en-US

Example live configuration:

  • Merchant number: production ID from GP WebPay
  • Public key file path: /web/gpwebpay/gpe.signing_live.cer
  • Private key file path: /web/gpwebpay/gpwebpay-live.key
  • Private key password: production key password
  • Default currency: contracted currency for live account
  • Default language: primary store language

Key path format

The plugin resolves key paths by prefixing project root (@root) to the value you save. Use project-root relative paths, for example:

  • /web/gpwebpay/public.pem
  • /web/gpwebpay/private.key

If a file path is wrong or unreadable, credential testing and payment preparation will fail.

File placement guidance

Place key files in a controlled directory under project root. Typical folder used by the plugin team is /web/gpwebpay/.

Checklist:

  1. Files exist on server in same environment as Craft.
  2. Stored path in settings starts with / and is relative to project root.
  3. PHP process has read permission.
  4. Password matches the private key.

Action buttons

The settings header includes two admin actions:

  • Test Credentials (gpwebpay/settings/test)
  • Check Payments (gpwebpay/settings/check-payments)

Test Credentials

Runs a real initialization flow:

  1. validates required settings
  2. validates key file existence
  3. initializes GP WebPay API signer
  4. creates a test payment request URL

Use this after every key/merchant change.

If test fails, review:

  • merchant number correctness
  • key file paths
  • private key password
  • currency mapping

Check Payments

Scans pending payment orders and triggers payment status checks through plugin service logic. Use this for operational recovery when callback timing is delayed or uncertain.

Recommended use:

  • after PSP outage
  • after temporary callback/network issue
  • before manually canceling pending payment orders

Sandbox test cards

When Enable Sandbox Mode is ON, the settings UI includes a Test Cards tab with predefined test card numbers. Use these cards only in sandbox mode to simulate successful and declined payment scenarios during QA.

Validation and save behavior

When plugin is enabled, required field validation is strict. If save succeeds:

  • Craft shows a success notice
  • payment methods cache storage is invalidated so checkout sees updated gateway configuration

If save fails, Craft keeps validation errors on the form.

Validation reminder:

  • merchantNumber, name, buttonName, defaultCurrency, privateKeyFilepath, privateKeyPassword, and publicKeyFilepath are required when enabled.
  • subscription label/button fields become required when Enable Subscriptions is ON.
  1. Save all required credentials in sandbox mode.
  2. Run Test Credentials until it passes.
  3. Place test orders and verify redirect + callback behavior.
  4. Configure restrictions (countries/time) if needed.
  5. Switch to production credentials.
  6. Disable sandbox mode.
  7. Monitor first live orders with this method.

Troubleshooting

Test Credentials fails immediately

Most common causes:

  • wrong key path
  • wrong private key password
  • incorrect merchant number

Action:

  1. Re-check all credential fields.
  2. Confirm files exist and are readable by web server user.
  3. Save again and repeat Test Credentials.

Payment method not visible in checkout

Check:

  1. Enable GP WebPay is ON.
  2. Country restriction includes current shipping/billing country.
  3. Visibility window is currently active.
  4. Payment method cache was refreshed (save settings again if needed).

Orders remain in pending_payment

Action:

  1. Open plugin settings and run Check Payments.
  2. Review order payment transaction details.
  3. Confirm callback route and gateway response behavior in logs.