Hellgate API (2.0)

Getting started

This reference is key for your comprehensive understanding of Hellgate® and, as such, essential for the successful use of our payment orchestration products.

Hellgate® APIs make use of RESTful conventions when possible and where it makes sense. All calls use the standard HTTP verbs to express access semantics, like GET, POST, PATCH, and DELETE. Other related conventions for our API can be found in the section below.

Gated Features

Some of the features offered by Hellgate® are gated and require explicit activation. These features are clearly labeled with a Gated badge.

In order to get access you need to contact your account manager.

Beta Features

Hellgate® offers various features as part of our beta release track. These features are clearly labeled with a Beta badge in the documentation and interface.

By default, accounts do not have access to beta features unless explicitly subscribed to beta releases. If you would like to enable beta features, please contact your account manager for subscription options.

⚠️ Beta features are experimental and subject to change or removal at any time. They may also have limited support and stability.

JSON Conventions

  • Resources are addressable by a UUIDv4 id property.
  • Property names are always in snake_case.
  • Hellgate® does not support empty strings. To unset a string value, use an explicit null value instead.
  • Temporal data is encoded in ISO 8601 strings.

Authentication

Hellgate® supports API keys to authenticate requests.

The keys are passed in via the HTTP header x-api-key.

curl --header 'X-API-Key: <SECRET>' \
  --request POST 'https://api.hellgate.io/...'

The keys must be handled with care and kept secure. Never hardcode the API keys in your source code, but keep them solely on your backend systems.

API Use

API Versions

Hellgate® API will be updated regularly, to include new features and updates to existing ones. We package these changes into versions that can be addressed using a header field (x-hellgate-version).

If the there is no version specified in the header, the most recent version is being used.

curl --header 'x-hellgate-version: <SELECTED VERSION>' \
  --request POST 'https://api.hellgate.io/...'

Hellgate® sets the x-hellgate-version header on API responses, to tell the integrator which version is in use.

Idempotency

To prevent your system from handling requests twice and thus, for example, charging a customer twice, Hellgate® supports idempotency on requests to the API.

The behavior is controlled via the header field x-idempotency-Key.

curl --header 'x-idempotency-key: <key>' ...

Pagination

Endpoints that return lists of objects support cursor-based pagination requests. By default, Hellgate® returns up to 50 objects per API call. If the number of objects in a response from a support endpoint exceeds the default, then an integration can use pagination to request a specific set of the results and/or to limit the number of returned objects.

If an endpoint supports pagination, the response body follows this structure:

{
  "current_page": 1,
  "page_size": 50,
  "total_items": 200,
  "total_pages": 4,
  "data": [...]
}

The single pages can be requested with query parameters:

ParameterTypeDescription
limitintegerThe maximum amount of objects to be returned on a page.
pageintegerThe requested number of the page to return.

Request Errors

Hellgate® uses the standard errors to indicate the client errors on the gateway level.

The response payload for processing errors follows a standard format.

{
  "status": "the HTTP status code",
  "classifier": "the classifer of the error",
  "message": "interesting for humans..."
}

Business Errors

The processing errors refer to the primary functions of Hellgate® and not necessarily to the related business logic. For example, a failed authorization due to insufficient funds will result in a 200 response, as the payment layer could successfully process the request (even though the business result is negative).

Download OpenAPI description
Overview
Languages
Servers
Hellgate® Sandbox
https://sandbox.hellgate.io/
Hellgate® Production
https://api.hellgate.io/

Customer Initiated

Operations

Merchant Initiated

Operations

Payment Modifications

Operations

Payment Data

Operations

Refund Data

Operations

Customer Initiated

Hellgate® allows to process EMVCo 3-D Secure authentication requests as standalone request.

For example, these endpoints can be used to process payment authentication centrally and process the subsequent authorization requests conditionally on different payment processors.

The secion of customer initiated authentications consists of three use-cases:

Use-Case Description
One OffA standard situation in which a single payment amount shall undergo 3-D Secure authentication.
Initial RecurringAn authentication of the first payment in the sequence of recurring payments.
Initial InstallmentAn authentication of the first payment in the sequence of installment payments.
Operations

Merchant Initiated (3RI)

Hellgate® supports requestor-initiated EMVCo 3-D Secure authentication requests as standalone transactions.

All requests in this section must be linked to a prior customer-initiated authentication.

Operations

Authentication Data

Access the results of prior authentications for reference.

Operations

Credentials on File

Operations

Create Hellgate® Tokens

Hellgate® Tokens are powerful instrument to manage card holder data in a PCI/DSS compliant way.

Compliance as a Service

Achieve PCI / DSS compliance in almost no time using our certified managed compliance service.

No Acquirer Lock-In

Transparently use the cardholder data across all connected processors to implement a non lock-in acquiring setup.

Network Tokens

For every card which is tokenized on Hellgate®, network-tokens can be automatically provisioned. This allows for more secure transactions, better conversion, and ultimately lower processing cost.

Operations

Token Management

All cards stored with Hellgate® can be managed via the endpoints in this section.

The CVC2 security code is only kept in an ephemeral cache for a few minutes. The API allows to manage this resource with these endpoints:

  • check if the CVC2 is still availble
  • request a new session to renew the CVC2 with our SDK
  • consume the token after a successful authorization on an external processor
Operations

Compliance Service

Operations

Network Tokens

Hellgate® supports Network Tokens with major card schemes.

The lifecycle of network tokens is automatically managed. When activated a network token is automatically provisioned and maintained through its life-cycle.

The use of Network Tokens requires prior activation by your account manager.

Operations

Request payment-dataGated

Request

Request a payment-data bundle for a Hellgate® token.

The bundle can contain various elements including the TAVV cryptogram for a network token.

This call supports the all operating models of Hellgate® (single merchant and eco-systems).

For eco-systems you need to specify which merchant you want to request the crypotgram for.

Path
idstring(uuid)required

The ID of the Hellgate® token

Bodyapplication/json
amountinteger>= 0required

The amount given in minor units (e.g. use 700 for 7€). Some currencies do not support minor units (e.g. Japanese Yen). In this case send in the full value, .i.e. 100 for 100 JPY.

currency_codestringrequired

The three letter currency code. See: ISO-4217

merchant_idstring(uuid)

The ID of the merchant for whom the authentication is requested.

Only required when the account operates an ecoystem or platform. The value will default to the primary merchant of an account in other cases.

Example: "00000000-0000-0000-0000-000000000000"
referencestringrequired

A reference to the payment

Example: "1234567890"
curl -i -X POST \
  'https://sandbox.hellgate.io/tokens/{id}/payment-data' \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: YOUR_API_KEY_HERE' \
  -d '{
    "amount": 10000,
    "currency_code": "EUR",
    "reference": "1234567890"
  }'

Responses

Success response

Bodyapplication/json
idstring(uuid)required

The id of the requested payment data

amountinteger>= 0required

The amount given in minor units (e.g. use 700 for 7€). Some currencies do not support minor units (e.g. Japanese Yen). In this case send in the full value, .i.e. 100 for 100 JPY.

currency_codestringrequired

The three letter currency code. See: ISO-4217

created_atstring(date-time)

The date-time the payment-data was created (following ISO 8601)

encrypted_authentication_datastring

JWE encrypted JSON string containing authentication data.

Encrypted in a symmetric way with the shared encryption key using "alg"=A256GCMKW and "enc"="A256GCM". For decryption make sure the shared secret is hashed with a sha256 digest.

The decrypted JSON has the following format:

{
    network_token: {
      token: "token_value",
      expiry_year: 2023,
      expiry_month: 12
    },
    cryptogram: "cryptogram_value",
    eci: "eci_value"
}
  • The field network_token contains the value of the token, the year of expiry and the month of expiry of the token and is always included.
  • The field cryptogram contains the value of the cryptogram and is always included.
  • The field eci can instead have a value if there was an Electronic Commerce Indicator assigned, or it can be null if no information was provided.
failure_detailsArray of objects

The reasons why the processing failed. There are two categories of errors that can happen in this context (the source field indicates the category):

  1. Scheme errors: errors that are returned by the scheme.
  2. Configuration errors: errors that are caused by the configuration with respect to the scheme.
merchant_idstring(uuid)required

The ID of the merchant for whom the authentication is requested

referencestringrequired

Reference in calling system

successbooleanrequired

The result of the processing of the request. If true, the processing was successfully completed. In case it is false, the processing failed and the failure_details field contains more information about the failure.

token_idstring(uuid)required

The ID of the token on Hellgate

Response
application/json
{ "id": "00000000-0000-0000-0000-000000000000", "amount": 10000, "currency_code": "EUR", "created_at": "2023-10-01T00:00:00Z", "encrypted_authentication_data": "eyJhbGc...", "merchant_id": "00000000-0000-0000-0000-000000000000", "reference": "1234567890", "success": true, "token_id": "00000000-0000-0000-0000-000000000000" }

Get payment-dataGated

Request

List all payment-data bundles created for this Hellgate® Token.

Path
idstring(uuid)required

The ID of the Hellgate® token

Query
limitinteger[ 1 .. 500 ]

The desired amount of records per page. The parameter defaults to 50 if it is omitted and has a maximum of 500.

pageinteger>= 1

The desired number of the page to return.

sortstring

It allows sorting the result by created_at. e.g sort=created_at+asc or sort=created_at+desc

curl -i -X GET \
  'https://sandbox.hellgate.io/tokens/{id}/payment-data?limit=1&page=1&sort=string' \
  -H 'X-API-Key: YOUR_API_KEY_HERE'

Responses

Success response

Bodyapplication/json
dataArray of objects
paginationobject

The meta-data describing lists of data from the Hellgate® API. The pages are indexed from 1 up to the total_pages.

Example: {"current_page":1,"page_size":1,"total_items":1,"total_pages":1}
Response
application/json
{ "data": [ {} ], "pagination": { "current_page": 1, "page_size": 1, "total_items": 1, "total_pages": 1 } }

Forward payment-dataGated

Request

This endpoint enables platform merchants to leverage payment-data bundles in their acquirer integration. The request is forwarded to the configured destination URL of your merchant settings.

Hellgate requires certain HTTP headers for this feature. These headers are reserved and cannot be used by the caller:

  • x-api-key - required for request authentication

In order to use the same header keys for the third-party provider, Hellgate allows to define key-value pairs with are resolved and injected as HTTP headers before forwarding to the third-party provider. The following example illustrates the use:

curl --location 'https://sandbox.hellgate.io/payment-data/d76074b3-53a8-4288-abcc-27c1281596d9/forward' \
--header 'x-api-key: hlg-sbx-9876...'
--header 'x-own-header-name: x-api-key' \
--header 'x-own-header-value: 123456...' \
...

The caller defines a custom header x-own-header-name with the value x-api-key which was previously reserved by Hellgate. The key-value pairs are matched on the term x-own-header in the example above.

Path
idstring(uuid)required

The ID of the payment-data bundle

Body
object

The payload the caller wants to forward to the third party provider.

To securely handle and inject sensitive token data, predefined templates can be used. These templates help structure and standardize the data injection process while ensuring compliance with security and regulatory requirements.

PlaceholderDescription
{{ network_token }}The actual full account number of the stored card.
{{ cardholder_name }}The name of the cardholder.
{{ expiration_year }}Four digit year of the expiration date.
{{ expiration_month }}Two digit month of the expiration date.
{{ cryptogram }}The token authentication verification value TAVV.
{{ eci }}The ECI associated with the payment-data bundle.
{{ amount }}The authenticated amount given in minor units
{{ currency_code }}The currency code of the authenticated amount.

All injected data will be represented as a string in the payload. If a specific data type is required, such as a numeric representation of the expiration month, the data can be unwrapped and converted back to its original type as needed: {{ expiration_month | unwrap }}.

curl -i -X POST \
  'https://sandbox.hellgate.io/payment-data/{id}/forward' \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: YOUR_API_KEY_HERE' \
  -d '{
    "reference": "MAGIC DUST XYZ",
    "amount": {
      "value": "{{ amount }}",
      "currency": "{{ currency_code }}"
    },
    "paymentMethod": {
      "type": "networkToken",
      "expiryMonth": "{{ expiration_month }}",
      "expiryYear": "{{ expiration_year }}",
      "holderName": "{{ cardholder_name }}",
      "number": "{{ network_token }}"
    },
    "mpiData": {
      "tokenAuthenticationVerificatioNValue": "{{ cryptogram }}",
      "eci": "{{ eci }}"
    },
    "recurringProcessingModel": "CardOnFile",
    "shopperInteraction": "Ecommerce"
  }'

Responses

Success response

Body
object

The response from the third party provider.

Response
{}

Merchants

Hellgate® accounts support two operating models.

This is the default model for accounts.

  • It is not possible to add sub-merchants (via POST /merchants)
  • It is not possible to delete the primary merchant (via DELETE /merchants/{id})
Operations

Processor Backup

In case your precious payment-method data is currently locked into an acquirer processor, Hellgate® allows you to migrate the tokens automatically. Currently we support stripe.com, but more processors are on our list. Please ask you account manager for more information.

Detailed documentation on how to migrate your stripe payment methods can be found on the Hellgate® Developer Documentation.

Operations

Reconciliation

Operations