> ## Documentation Index
> Fetch the complete documentation index at: https://rain-sandbox-trial.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Simulate a 3DS challenge

> Triggers a 3DS authentication challenge against a card to test your 3DS Forwarding webhook integration. The endpoint generates a one-time password (OTP), sends a `challenge.requested` webhook to your configured endpoint, and returns the challenge credentials.

**Sandbox only.** This endpoint returns `404 Not Found` in production environments.



## OpenAPI

````yaml /openapi.json post /simulate/3ds-challenge
openapi: 3.0.3
info:
  title: Issuing API
  description: This is the specification for Rain's Issuing API.
  termsOfService: https://www.rain.xyz/legal/authorized-user-terms
  contact:
    email: support@rain.xyz
  version: 1.3.0
servers:
  - url: https://api-dev.rain.xyz/v1
    description: Sandbox server
  - url: https://api.rain.xyz/v1
    description: Production server
security: []
tags:
  - name: paymentRoutes
    description: >-
      **Endpoint Migration:** The `/v1/automations` endpoints have been renamed
      to `/v1/payment-routes`. The old `/v1/automations` paths remain available
      as deprecated aliases during migration. Update your integrations to use
      `/v1/payment-routes` as the deprecated endpoints will be removed in a
      future release.
  - name: simulate
    description: >-
      Transaction simulation endpoints for testing integration flows in
      non-production environments. These endpoints let you trigger transaction
      events programmatically to automate integration tests and verify webhook
      handling without depending on external systems or staging real deposits.
      **Sandbox only** — all simulation endpoints return `404 Not Found` in
      production.
  - name: raindrops
    description: >-
      Rewards and points management endpoints. Custom API keys need
      `raindrops:read`/`raindrops:write` for general rewards endpoints and
      `raindrops-travel:read`/`raindrops-travel:write` for travel redemption
      endpoints.
    x-group: rewards
paths:
  /simulate/3ds-challenge:
    post:
      tags:
        - simulate
      summary: Simulate a 3DS challenge
      description: >-
        Triggers a 3DS authentication challenge against a card to test your 3DS
        Forwarding webhook integration. The endpoint generates a one-time
        password (OTP), sends a `challenge.requested` webhook to your configured
        endpoint, and returns the challenge credentials.


        **Sandbox only.** This endpoint returns `404 Not Found` in production
        environments.
      operationId: simulate3dsChallenge
      requestBody:
        description: 3DS challenge simulation request
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Simulate3dsChallengeRequest'
        required: true
      responses:
        '200':
          description: Successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Simulate3dsChallengeResponse'
        '400':
          description: >-
            Invalid body (missing required fields, invalid deliveryMethod), or
            the card is not active
        '404':
          description: >-
            Endpoint not available in production, the card does not exist, or
            the card does not belong to your tenant
      security:
        - ApiKeyAuth: []
components:
  schemas:
    Simulate3dsChallengeRequest:
      type: object
      required:
        - cardId
        - amount
        - merchantName
        - deliveryMethod
      properties:
        cardId:
          type: string
          format: uuid
          description: >-
            The Rain card ID to simulate the challenge for. Must be an active
            card belonging to your tenant.
        amount:
          type: integer
          minimum: 1
          description: The transaction amount in cents.
        merchantName:
          type: string
          description: The merchant name to include in the challenge details.
        deliveryMethod:
          type: string
          enum:
            - SMS
            - EMAIL
            - WHATSAPP
          description: The OTP delivery method. PUSH is not supported for simulation.
    Simulate3dsChallengeResponse:
      type: object
      required:
        - challengeId
        - oneTimePassword
        - expiryTime
      properties:
        challengeId:
          type: string
          format: uuid
          description: Unique identifier for this challenge session.
        oneTimePassword:
          type: string
          description: The 6-digit OTP that your system should deliver to the cardholder.
        expiryTime:
          type: string
          format: date-time
          description: When the challenge expires (5 minutes from creation).
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      name: Api-Key
      in: header

````