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

# Payment Request

> Payment Request



## OpenAPI

````yaml post /requests
openapi: 3.0.3
info:
  title: Fractal
  version: 1.0.0
  contact: {}
servers:
  - url: https://testapi.fractalpay.com/api/v1
    description: Sandbox
  - url: https://api.fractalpay.com/api/v1
    description: Production
security: []
tags:
  - name: Merchant Onboarding
  - name: Payment Collection Methods
  - name: Requests
  - name: Preauthorizations
  - name: Customers
  - name: Charging Customer
  - name: Transactions
paths:
  /requests:
    post:
      tags:
        - Payment Collection Methods
        - Requests
      summary: Payment Request
      description: >-
        Sends a payment request to a customer via SMS and/or email. Returns a
        pay link the customer uses to complete payment. Set preauth: true to
        issue a preauthorization instead of a charge — the customer authorizes
        the amount without being charged immediately. Fires a payment.success
        webhook on completed payment, or a preauth webhook on successful
        preauthorization.
      operationId: paymentRequest
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - order_id
                - amount
                - merchant_key
              properties:
                merchant_key:
                  type: string
                  description: The merchant's unique API key.
                  example: '{{merchant_key}}'
                amount:
                  type: string
                  description: Payment amount.
                  example: '10.00'
                order_id:
                  type: string
                  description: Your unique order reference. Max 100 characters.
                  example: '5467'
                phone_number:
                  type: string
                  description: >-
                    Customer phone number. If provided, an SMS with the pay link
                    is sent.
                  example: '7777771234'
                email:
                  type: string
                  description: >-
                    Customer email address. If provided, an email with the pay
                    link is sent.
                  example: customer@example.com
                name:
                  type: string
                  description: Customer name. Used in the email template.
                  example: Jane Smith
                preauth:
                  type: boolean
                  description: >-
                    Set to true to issue a preauthorization. The customer
                    authorizes the amount without being charged immediately.
                  example: true
                pass_fee:
                  type: boolean
                  description: Pass the processing fee to the customer.
                  example: true
                require_3ds:
                  type: boolean
                  description: Require 3D Secure authentication.
                  example: false
                allow_card:
                  type: boolean
                  description: >-
                    Allow card as a payment method. At least one of allow_card
                    or allow_ach must be true.
                  default: true
                  example: true
                allow_ach:
                  type: boolean
                  description: >-
                    Allow ACH as a payment method. At least one of allow_card or
                    allow_ach must be true.
                  default: true
                  example: true
                invoice_number:
                  type: string
                  description: Invoice reference. Alphanumeric, max 100 characters.
                  example: '345'
                sub_merchant_key:
                  type: string
                  description: Sub-merchant key, if applicable.
                  example: ''
                discount:
                  type: string
                  description: Discount amount.
                  example: '0.00'
                surcharge:
                  type: string
                  description: Surcharge amount.
                  example: '0.00'
                tax:
                  type: string
                  description: Tax amount.
                  example: '0.00'
                description:
                  type: string
                  description: Payment description.
            examples:
              Standard Payment Request:
                value:
                  merchant_key: '{{merchant_key}}'
                  amount: '10.00'
                  order_id: '5467'
                  phone_number: '7777771234'
                  email: customer@example.com
                  allow_card: true
                  allow_ach: true
              Preauth Payment Request:
                value:
                  merchant_key: '{{merchant_key}}'
                  amount: '10.00'
                  order_id: '5467'
                  phone_number: '7777771234'
                  email: customer@example.com
                  preauth: true
                  pass_fee: true
                  require_3ds: false
                  invoice_number: '345'
                  allow_card: true
                  allow_ach: true
      responses:
        '200':
          description: Payment request created successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                  data:
                    type: object
                    properties:
                      order_id:
                        type: string
                        description: The order_id you provided.
                        example: '5467'
                      link_id:
                        type: string
                        description: Short code identifying the pay link.
                        example: gsgqll4xfa7
                      pay_link:
                        type: string
                        description: >-
                          Full URL to send to the customer to complete payment
                          or preauthorization.
                        example: >-
                          https://testapi.fractalpay.com/authcheck-paymentlink/gsgqll4xfa7
              examples:
                Preauth Request:
                  value:
                    message: Authorization request has been sent
                    data:
                      order_id: '5467'
                      link_id: gsgqll4xfa7
                      pay_link: >-
                        https://testapi.fractalpay.com/authcheck-paymentlink/gsgqll4xfa7
                Standard Payment Request:
                  value:
                    message: Text request has been sent
                    data:
                      order_id: '5467'
                      link_id: gsgqll4xfa7
                      pay_link: >-
                        https://testapi.fractalpay.com/authcheck-paymentlink/gsgqll4xfa7
      security:
        - basicAuth: []
components:
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: |-
        Use your Fractal API credentials.

        Username = Client ID
        Password = Secret Key

        Sandbox credentials can be generated from the Test Portal.

````