> ## Documentation Index
> Fetch the complete documentation index at: https://docs.briq.tz/llms.txt
> Use this file to discover all available pages before exploring further.

# Resend OTP

> Invalidate the prior OTP and send a new one. When your X-API-Key is bound to a developer app, omit app_key from the body. Accepts callback_url and callback_secret to set the flake callback target for the new OTP window.



## OpenAPI

````yaml /openapi.json post /v1/otp/resend
openapi: 3.1.0
info:
  title: Briq API
  description: Karibu Briq API Documentation
  version: '0.8'
servers:
  - url: https://karibu.briq.tz
    description: Production
  - url: https://pre-release.karibu.briq.tz
    description: Pre-release
  - url: http://karibu.briq.tz
    description: LocalPass
security: []
paths:
  /v1/otp/resend:
    post:
      tags:
        - Karibu-OTP
      summary: Resend OTP
      description: >-
        Invalidate the prior OTP and send a new one. When your X-API-Key is
        bound to a developer app, omit app_key from the body. Accepts
        callback_url and callback_secret to set the flake callback target for
        the new OTP window.
      operationId: resend_otp_developer_app_v1_otp_resend_post
      parameters:
        - name: X-API-Key
          in: header
          required: true
          schema:
            type: string
            title: X-Api-Key
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OTPResendDeveloperAppSchema'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BaseResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    OTPResendDeveloperAppSchema:
      properties:
        phone_number:
          type: string
          title: Phone Number
          description: >-
            Recipient's phone number, E.164 digits-only (no '+', e.g.
            255712345678)
          examples:
            - '255712345678'
        app_key:
          anyOf:
            - type: string
            - type: 'null'
          title: App Key
          description: >-
            Optional. Omit when your X-API-Key is bound to a developer app.
            Legacy unbound keys may send this or use the X-App-ID header
            instead.
          examples:
            - devapp_123456
        sender_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Sender Id
          description: >-
            Sender ID shown to the recipient. **SMS only** — silently ignored on
            `call` and `whatsapp`. Defaults to the platform-configured
            `OTP_DEFAULT_SENDER_ID`.
          examples:
            - BRIQ OTP
        otp_length:
          type: integer
          title: Otp Length
          description: Length of OTP code
          default: 6
          examples:
            - 6
        minutes_to_expire:
          type: integer
          title: Minutes To Expire
          description: OTP expiry time in minutes
          default: 10
          examples:
            - 10
        delivery_method:
          type: string
          enum:
            - sms
            - call
            - whatsapp
          title: Delivery Method
          description: >-
            Delivery channel: `sms` (default), `call` (TTS), or `whatsapp` (uses
            platform-managed `briq_otp` template; sender resolution is
            automatic). Switching channels on resend is allowed — the previous
            active OTP is invalidated regardless of which channel issued it.
          default: sms
          examples:
            - sms
            - call
            - whatsapp
        message_template:
          anyOf:
            - type: string
            - type: 'null'
          title: Message Template
          description: >-
            Custom OTP message template. Must contain `{code}`; `{expiry}` is
            also substituted. **SMS only** — silently ignored on `call` and
            `whatsapp`. WhatsApp wording is fixed by the approved `briq_otp`
            Meta template.
          examples:
            - Your OTP is {code}
        callback_url:
          anyOf:
            - type: string
              format: uri
            - type: 'null'
          title: Callback Url
          description: >-
            Optional HTTPS URL for flake lifecycle webhooks for this resend.
            Replaces the callback target for this phone/app until the new OTP
            expires.
          examples:
            - https://api.example.com/briq/otp-events
        callback_secret:
          anyOf:
            - type: string
            - type: 'null'
          title: Callback Secret
          description: Optional shared secret for signing callbacks to callback_url.
      type: object
      required:
        - phone_number
      title: OTPResendDeveloperAppSchema
    BaseResponse:
      properties:
        success:
          type: boolean
          title: Success
        message:
          type: string
          title: Message
        data:
          anyOf:
            - type: object
            - type: 'null'
          title: Data
        status_code:
          type: integer
          title: Status Code
          default: 200
      type: object
      required:
        - success
        - message
      title: BaseResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````