Worldpay.TokenImport (Worldpay v1.0.0)

Copy Markdown View Source

Worldpay Token Import — migrate tokens from a previous provider.

Allows merchants switching to Worldpay to import existing card tokens, avoiding the need to re-collect card details from customers.

Token import is handled via a secure SFTP file transfer process with Worldpay's implementation team. This module provides helpers for building the import manifest.

Process

  1. Contact Worldpay IM to initiate token import
  2. Build an import manifest using build_manifest/2
  3. Encrypt the manifest (Worldpay provides PGP public key)
  4. Transfer to Worldpay SFTP
  5. Worldpay processes and returns a completion file

Supported source vaults

  • Stripe tokens
  • Braintree tokens
  • Adyen tokens
  • Chase Paymentech tokens
  • Other PCI-compliant token vaults

Summary

Functions

Build a token import manifest entry.

Build a complete token import manifest (JSON).

Parse a token import completion file.

Functions

build_entry(opts)

@spec build_entry(keyword()) :: %{required(String.t()) => term()}

Build a token import manifest entry.

build_manifest(entries, opts \\ [])

@spec build_manifest(
  [map()],
  keyword()
) :: String.t()

Build a complete token import manifest (JSON).

parse_completion(json)

@spec parse_completion(String.t()) :: {:ok, map()} | {:error, term()}

Parse a token import completion file.