Developer Docs

Developer Docs

  • Getting Started
  • SubscriptionJS
  • REST API
  • Webhooks
  • Code Samples
  • UseCases
  • Request a Demo

›Reference

SubscriptionJS

  • Overview
  • Initial Setup
  • Signup
  • Portal
  • Payments
  • Coupons
  • Synchronization
  • Going Live

Reference

    Methods

    • Payment
    • Signup
    • Portal
    • General
  • Types
  • Callbacks

Embeddable Elements

  • Available Elements
  • Payment Form IFrame

    • Introduction
    • Configuration
    • Appearance
    • Reference

SubscriptionJS Callbacks

  • success(successData)
  • error(errorData)

success(successData)

Most SubscriptionJS methods provide a success callback. Please refer to each method to see in which form successData will be provided.


error(errorData)

Most SubscriptionJS methods provide a callback to handle errors.

{
    "errorCode" : ["InvalidCardCvc"],
    "errorMessage" : "",
    "referenceId" : "",
    "referenceUrl" : "",
    "details" : ""
}

Please check the structure of the passed object before using it. Currently, the passed object might have a different structure under certain circumstances.

errorMessage is an error message for your internal use. It is NOT prepared for direct notification of the customer. referenceId Reserved for future use. referenceUrl Reserved for future use. details Reserved for future use. errorCode is an array that provides a hierarchy of error codes. At least one value is provided. This can be used to implement error specific behaviour of your page, e.g. inform the customer some credit card data was incorrect and let him correct it.

Possible values created by SubscriptionJS:

Aborted,
AcquirerServerError,
AmountLimitExceeeded,
AuthorizationRejected,
BearerExpired,
BearerRejected,
InvalidAccountHolder,
InvalidAccountNumber,
InvalidAmount,
InvalidBankCode,
InvalidBic,
InvalidCardType,
InvalidCardNumber,
InvalidCardCvc,
InvalidCardHolder,
InvalidConfiguration,
InvalidCountry,
InvalidCouponCode
InvalidCurrency,
InvalidData,
InvalidExpirationDate,
InvalidKey,
InvalidIban,
InvalidName, //Invalid customer name
InvalidPaymentData,
InvalidPaymentMethod,
InvalidTransaction,
InvalidVatId,
IteroServerError,
PspServerError,
RateLimit,
Timeout,
UnmappedError, //for PSP errors not mapped to a specific billwerk code
3DsProblem

Possible values returned by the server on failed payments:

AlreadyExecuted,
BearerInvalid,
BearerExpired,
Canceled,
LimitExceeded,
LoginError,
InsufficientBalance,
InternalError,
InvalidAmount,
InvalidBic,
InvalidCountry,
InvalidConfiguration,
InvalidCurrency,
InvalidData,
InvalidIBAN,
InvalidPreconditions,
InternalProviderError,
PermissionDenied,
PSPConnectionProblem,
PSPConnectionTimeout,
RateLimit,
Rejected,
UnmappedError //for PSP errors not mapped to a specific billwerk code
Last updated on 6/30/2020 by Thomas Tauber
← TypesAvailable Elements →
Docs
Getting StartedAPI Reference
Resource
Help CenterSupportBlogTutorials
Start with billwerk
Test for free
Request a Demo
Already started?
billwerk Sandboxbillwerk Production
billwerk GmbH
© Made with ❤ in Germany for Europe by billwerk GmbH | 2022
Imprint
|
Data Privacy Rules
|
Disclaimer