---
title: "Get 2FA message template"
method: GET
path: "/2fa/2/applications/{appId}/messages/{msgId}"
tags: ["platform", "2fa", "2fa-configuration", "manage-message-templates"]
---

# Get 2FA message template

`GET /2fa/2/applications/{appId}/messages/{msgId}`

## Request

- Base URL: `https://api.infobip.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.infobip.com/2fa/2/applications/{appId}/messages/{msgId}`
- Auth: one of:
  - HTTP basic
  - API key in header `Authorization`
  - API key in header `Authorization`
  - OAuth 2
    - Client credentials
    - Token URL: `https://api.infobip.com/auth/1/oauth2/token`

Get a single 2FA message template from an application to see its configuration details.

## Path parameters

- `appId` string, required
- `msgId` string, required

## Response `200`

successful response

- C3b21d2ffef2552e10577daa67c904ac80618665b001ef386a4faefc515e78f3Message
  - `applicationId` string: The ID of the application that represents your service (e.g. 2FA for login, 2FA for changing the password, etc.) for which the requested message has been created.
  - `emailTemplateId` integer: Email template ID that should reference a previously created Email template. This field is present only for [Email message templates](#channels/sms/create-2fa-email-message-template).
  - `from` string: The sender of the 2FA message, an email address with an optional sender name (e.g. `company@example.com` or `Jane Smith <jane.smith@somecompany.com>`). This field is present only for [Email message templates](#channels/sms/create-2fa-email-message-template).
  - `landingPageId` string: Opt out landing page ID that should reference a previously created landing page template. This field is present only for [Email message templates](#channels/sms/create-2fa-email-message-template).
  - `language` string: Language code which message is written in. This is used when sending text-to-speech messages. More about Text-to-speech functionality and supported TTS languages can be found [here](https://www.infobip.com/docs/voice-and-video/outbound-calls#text-to-speech-voice-over-broadcast). If not set, default language is `English [en]`. If voice is not set, then default voice for that specific language is used. In the case of English language, the voice is `[Joanna]`.
  - `messageId` string: The ID of the message template (message body with the PIN placeholder) that is sent to the recipient.
  - `messageText` string: Text of a message that will be sent. Message text must contain `pinPlaceholder`.
  - `pinLength` integer: PIN code length.
  - `pinPlaceholder` string: The PIN code placeholder that will be replaced with a generated PIN code.
  - `pinType` 'NUMERIC' | 'ALPHA' | 'HEX' | 'ALPHANUMERIC'
  - `regional` C3b21d2ffef2552e10577daa67c904ac80618665b001ef386a4faefc515e78f3RegionalOptions
    - `indiaDlt` C3b21d2ffef2552e10577daa67c904ac80618665b001ef386a4faefc515e78f3IndiaDltOptions
      - `contentTemplateId` string: Registered DLT content template ID which matches message you are sending.
      - `principalEntityId` string: Your assigned DLT principal entity ID.
      - `teleMarketerId` string: Your assigned Telemarketer ID (required for Aggregators).
  - `repeatDTMF` string: In case PIN message is sent by Voice, DTMF code will enable replaying the message.
  - `senderId` string: The sender of the 2FA message (Example: CompanyName).
  - `speechRate` number, double: In case PIN message is sent by Voice, the speed of speech can be set for the message. Supported range is from `0.5` to `2`.
  - `voiceName` string: Defines the voice that will be used for the chosen language (example: Joanna). For each supported language, we may offer different voices (learn more [here](https://www.infobip.com/docs/voice-and-video/reference#text-to-speech-languages)). You can use this [method](https://www.infobip.com/docs/api/channels/voice/voice-message/get-voices) to retrieve all voices for the given language. If not defined, it will default to the standard voice for the selected language (if available). If the standard voice is not available, the request will fail. To avoid that, you can choose one of the neural voices (charges will apply).

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `500`: Internal Server Error
- `4XX`: Error responses
- `5XX`: Error responses

---

[API](https://skmtc.dev/infobip/apis/infobip-openapi-specification.md) - [All operations](https://skmtc.dev/infobip/apis/infobip-openapi-specification/llms.txt) - [OpenAPI document](https://skmtc.dev/infobip/apis/infobip-openapi-specification/revisions/9dcbbaf902de?raw)
