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

# Send offer

> Sends a pending offer to the customer. The offer must be in "pending" status.



## OpenAPI

````yaml https://api.sibipro.com/offers/openapi.json post /{id}/send
openapi: 3.0.0
info:
  title: Offers API
  version: 1.0.0
  description: RESTful API for managing offers
servers:
  - url: https://api.sibipro.com/prod/offers
    description: API endpoint
security: []
paths:
  /{id}/send:
    post:
      summary: Send offer
      description: >-
        Sends a pending offer to the customer. The offer must be in "pending"
        status.
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
          description: The ID of the offer to send
      responses:
        '200':
          description: Offer sent successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SendOfferResponse'
        '400':
          description: Bad request - Offer is not in a sendable state
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                offerNotPending:
                  value:
                    code: OFFER_NOT_PENDING
                    message: Offer cannot be sent because it is not in "pending" status
                offerSendingError:
                  value:
                    code: OFFER_SENDING_ERROR
                    message: Error sending offer to customer
        '401':
          description: Unauthorized - Missing or invalid authentication
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                unauthorized:
                  value:
                    code: UNAUTHORIZED
                    message: Missing authentication token
        '403':
          description: Forbidden - Caller can view this offer but is not allowed to send it
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                permissionDenied:
                  value:
                    code: FORBIDDEN
                    message: User does not have permission to send this offer
        '404':
          description: Not found - Offer does not exist or caller is not allowed to view it
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                notFound:
                  value:
                    code: OFFER_NOT_FOUND
                    message: Offer not found
        '409':
          description: Upsells are still generating; retry once generation completes
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                upsellsGenerating:
                  value:
                    code: UPSELLS_GENERATING
                    message: >-
                      Upsell generation for this offer is still in progress.
                      Please retry shortly.
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                serverError:
                  value:
                    code: INTERNAL_SERVER_ERROR
                    message: An unexpected error occurred
components:
  schemas:
    SendOfferResponse:
      type: object
      properties:
        success:
          type: boolean
          description: Whether the offer was sent successfully
          example: true
        sentAt:
          type: string
          format: date-time
          description: Timestamp when the offer was sent
          example: '2024-01-20T12:00:00Z'
      required:
        - success
        - sentAt
    ErrorResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code indicating the type of error
        message:
          type: string
          description: Human-readable error message explaining what went wrong
          example: The request contains invalid parameters
        details:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
              error:
                type: string
            required:
              - field
              - error
          description: Detailed validation errors when applicable
          example:
            - field: customer.email
              error: Invalid email
            - field: address.postalCode
              error: Invalid
      required:
        - code
        - message

````