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

# Create Order with Member

> Create a new order and send digital benefit cards to a member.



## OpenAPI

````yaml POST /organization/Sponsor/Order/CreateOrderWithMember
openapi: 3.0.3
info:
  title: iQpay Order API
  description: >-
    API for sponsors and organizations to create orders and send digital benefit
    cards to members.
  version: '2024.5'
  contact:
    name: iQpay Support
    url: https://iqpay.com
servers:
  - url: https://api-demo.bridgepo.com
    description: Demo Environment
security: []
paths:
  /organization/Sponsor/Order/CreateOrderWithMember:
    post:
      tags:
        - Orders
      summary: Create Order with Member
      description: >-
        Create a new order and send digital benefit cards to a member. If the
        program is configured to deliver cards via webhook, card delivery is
        handled by the sponsor — not iQpay.
      operationId: createOrderWithMember
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateOrderRequest'
      responses:
        '200':
          description: Order created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateOrderResponse'
        '201':
          description: Order for program already in place for this member.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateOrderResponse'
        '400':
          description: Bad request. See common errors below.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderErrorResponse'
              examples:
                loadLimitExceeded:
                  summary: Organization load limit exceeded
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Organization load limit is exceeded
                    status: 400
                    detail: >-
                      The organization has exceeded the load limit defined in
                      the system.
                    traceId: 00-abc123-def456-00
                missingExternalTxnId:
                  summary: Missing external transaction ID
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: >-
                      External transaction id is mandatory when program is
                      configured to send communication through webhook
                    status: 400
                    detail: external_transaction_id parameter is empty or null.
                    traceId: 00-abc123-def456-00
                mixedCardIssuers:
                  summary: Mixed card issuers
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Order can only have same card issuer products
                    status: 400
                    detail: Products in the order must be from the same card issuer.
                    traceId: 00-abc123-def456-00
                missingPhoneOrEmail:
                  summary: Missing phone or email
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: You must provide at least a mobile phone or email
                    status: 400
                    traceId: 00-abc123-def456-00
                programNotLaunched:
                  summary: Program not launched
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Program product not launched
                    status: 400
                    traceId: 00-abc123-def456-00
                missingParameters:
                  summary: Missing required parameters
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Missing Parameters
                    status: 400
                    traceId: 00-abc123-def456-00
                externalIdRequired:
                  summary: External ID required
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: External id required
                    status: 400
                    detail: The program has ExternalId defined as mandatory.
                    traceId: 00-abc123-def456-00
                productNotMapped:
                  summary: Product not mapped to program
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Specified product not mapped to the program
                    status: 400
                    traceId: 00-abc123-def456-00
                programNotActive:
                  summary: Program not active
                  value:
                    type: https://tools.ietf.org/html/rfc7231#section-6.5.1
                    title: Program is not active
                    status: 400
                    detail: The program code passed in request payload is deactivated.
                    traceId: 00-abc123-def456-00
        '401':
          description: Unauthorized. Token is missing or invalid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderErrorResponse'
        '403':
          description: Forbidden.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderErrorResponse'
        '404':
          description: >-
            Resource not found. Could not find the organization, program, or
            product specified in the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderErrorResponse'
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    CreateOrderRequest:
      type: object
      required:
        - productCode
        - programCode
        - email
        - firstName
        - lastName
        - phoneCountryCode
        - phone
        - optInNotification
        - optInForSMSOrEmail
      properties:
        productCode:
          type: string
          description: >-
            Product code provided by the iQpay team for the specific benefit
            card type. If there are multiple products, send a comma-separated
            list of product codes.
          example: PROD-001
        programCode:
          type: string
          description: >-
            Program code provided by the iQpay team identifying the sponsor's
            program.
          example: PROG-2024-FOOD
        email:
          type: string
          format: email
          maxLength: 80
          description: >-
            Member's email address. Used for card delivery if program is
            configured for email.
          example: member@example.com
        firstName:
          type: string
          maxLength: 50
          description: Member's first name.
          example: Jane
        lastName:
          type: string
          maxLength: 50
          description: Member's last name.
          example: Smith
        phoneCountryCode:
          type: string
          maxLength: 1
          description: Phone country code. Defaults to `1` (US) if not provided.
          default: '1'
          example: '1'
        phone:
          type: string
          maxLength: 10
          description: Member's mobile phone number. Used for SMS card delivery.
          example: '5551234567'
        externalId:
          type: string
          maxLength: 50
          description: >-
            Sponsor's external identifier for the member (e.g., employee code).
            Optional, but required if enabled in Program configuration.
          example: EXT-MBR-12345
        externalTransactionId:
          type: string
          maxLength: 50
          description: >-
            Sponsor's external transaction identifier for tracing. Optional, but
            **required** when the program is configured to send communication
            through webhook.
          example: TXN-2024-00001
        optInNotification:
          type: boolean
          description: >-
            Indicates whether the member has provided consent to receive future
            communications from the organization. Set to `true` when prior
            messaging consent has not been established, such as when collecting
            member information for the first time.
          example: true
        optInForSMSOrEmail:
          type: boolean
          description: >-
            Member opt-in to receive SMS/email for digital card delivery. Must
            be set to `true` for all members.
          example: true
        processingDate:
          type: string
          format: date-time
          nullable: true
          description: >-
            Optional scheduled processing date for the order. If not provided,
            the order is processed immediately. Used to schedule future card
            delivery.
          example: '2026-04-15T00:00:00Z'
    CreateOrderResponse:
      type: object
      properties:
        success:
          type: boolean
          description: Whether the order was created successfully.
          example: true
        statusText:
          type: string
          description: Status message from the server.
          example: Ok
        statusCode:
          type: integer
          nullable: true
          description: Status code, if applicable.
          example: null
        id:
          type: integer
          description: The created order ID.
          example: 12345
        dependantId:
          type: integer
          nullable: true
          description: Dependant order ID, if applicable.
          example: null
    OrderErrorResponse:
      type: object
      properties:
        type:
          type: string
          description: A URI reference identifying the error type.
          example: https://tools.ietf.org/html/rfc7231#section-6.5.1
        title:
          type: string
          description: A short human-readable summary of the error.
          example: One or more validation errors occurred.
        status:
          type: integer
          description: The HTTP status code.
          example: 400
        detail:
          type: string
          description: A detailed explanation of the error.
          example: The productCode field is required.
        traceId:
          type: string
          description: A unique trace identifier for debugging.
          example: 00-abc123def456-789ghi-00
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT token obtained from the `/identity/Auth/SignIn` endpoint.

````