Contents

POST [/instances/$INSTANCE]/private/otp-devices#

This is used to associate an OTP device with an instance.

Required permission: otp-devices-write

Request:

The request must be a OtpDeviceAddDetails.

Response:

204 No content:

The creation of the template is successful.

404 Not found:

The merchant instance is unknown or it is not in our data.

Details:

interface OtpDeviceAddDetails {

  // Device ID to use.
  otp_device_id: string;

  // Human-readable description for the device.
  otp_device_description: string;

  // A key encoded with RFC 3548 Base32.
  // IMPORTANT: This is not using the typical
  // Taler base32-crockford encoding.
  // Instead it uses the RFC 3548 encoding to
  // be compatible with the TOTP standard.
  otp_key: string;

  // Algorithm for computing the POS confirmation.
  // "NONE" or 0: No algorithm (no pos confirmation will be generated)
  // "TOTP_WITHOUT_PRICE" or 1: Without amounts (typical OTP device)
  // "TOTP_WITH_PRICE" or 2: With amounts (special-purpose OTP device)
  // The "string" variants are supported @since protocol **v7**.
  otp_algorithm: Integer | string;

  // Counter for counter-based OTP devices.
  otp_ctr?: Integer;
}