• Namespace
  • Class

Namespaces

  • Klarna
    • Exceptions
    • Rest
      • Checkout
      • CustomerToken
      • HostedPaymentPage
      • InstantShopping
      • MerchantCardService
      • OrderManagement
      • Payments
      • Settlements
      • Transport
        • Exception

Exceptions

  • ConnectorException

Class ConnectorException

ConnectorException is used to represent a API error response.

Exception implements Throwable
Extended by RuntimeException
Extended by Klarna\Rest\Transport\Exception\ConnectorException
Namespace: Klarna\Rest\Transport\Exception
Located at Klarna/Rest/Transport/Exception/ConnectorException.php

Methods summary

public
# __construct( array $data, $code = 0 )

Constructs a connector exception instance.

Constructs a connector exception instance.

Parameters

$data
Error data
$code

Overrides

Exception::__construct
public string
# getErrorCode( )

Gets the API error code for this exception.

Gets the API error code for this exception.

Returns

string
public array
# getMessages( )

Gets the API error messages for this exception.

Gets the API error messages for this exception.

Returns

array
public string
# getCorrelationId( )

Gets the API correlation ID for this exception.

Gets the API correlation ID for this exception.

Returns

string
public string
# getServiceVersion( )

Gets the API Service version for this exception.

Gets the API Service version for this exception.

Returns

string
public null
# getResponse( )

Deprecated

Function is not longer used. Will always return null Gets the HTTP response for this API error.


Returns

null

Methods inherited from Exception

__toString(), __wakeup(), getCode(), getFile(), getLine(), getMessage(), getPrevious(), getTrace(), getTraceAsString()

Magic methods summary

Properties summary

protected string $errorCode

API response error code.

API response error code.

#
protected string[] $messages

API response error messages.

API response error messages.

#
protected string $correlationId

API response error correlation ID.

API response error correlation ID.

#

Properties inherited from Exception

$code, $file, $line, $message

API documentation generated by ApiGen