Search

Are you looking for test card numbers?

Would you like to contact support?

Developer-resource icon

Migrate from origin key to client key

Learn about how and why to switch to using the client key.

If your Web Drop-in or Web Components integration uses the origin key, consider switching to the client key. The client key makes it easier for you to manage the origins for your Web Drop-in or Web Components integration.

With the client key, you have:

  • A single key for all your allowed origins in an environment.
  • Flexibility to add and remove origins without having to generate a new client key.
  • A human-readable prefix, test or live, so you can easily tell which environment a client key is linked to.

The client key also enables card type detection through Bank Identification Number (BIN) lookup, which is not available when using the origin key.

Availability and compatibility

The client key is available for Web Drop-in and Web Components version 3.10.1 and above. Previous versions require origin keys for client-side authentication.

The client key is backwards compatible with the origin key. Generating a client key does not invalidate a pre-existing origin key.

Switch to using the client key

You must be running Web Drop-in or Web Components version 3.10.1 or above.

  1. Log in to your test Customer Area.
  2. Go to Account > Users, and select the web service user for your Web Drop-in or Web Components integration, for example ws@Company.[YourCompanyAccount].
  3. Add your domains under Allowed origins. These are the domains from which you will be sending your client-side requests.
  4. Under Authentication, select Generate New Client Key. You can use your new client key immediately.
  1. Replace originKey in your Web Drop-in or Web Components configuration object with:

    const configuration = {
      ...
      clientKey: "YOUR_CLIENT_KEY",
      ...
    }

See also