Skip to main content

Send Email

Send booking confirmation and travel details via email to passengers. This endpoint handles automated email delivery of booking information, tickets, and travel documents.


Endpoint

  • URL: /api/v1/flight/sendemail
  • Method: POST
  • Auth Required: Yes (Bearer Token/X-API-KEY)
  • Content-Type: application/json

Authentication

This endpoint requires a valid JWT Bearer token in the Authorization header:

Authorization: Bearer <access_token>

Obtain tokens via /api/v1/sign-in (POST) with your credentials.


Request Structure

FieldTypeRequiredDescription
systemstringNoBooking system code (e.g., VN, VJ, 1A)
bookingCodestringNoBooking code (PNR)
emailstringNoRecipient email address
paymentDisplayTypestringNoPayment display type (S: Summary, D: Detail, F: No financial

) |

Example Request:

{
"system": "VN",
"bookingCode": "ABC123",
"email": "passenger@example.com"
}

Request Constraints & Business Rules

  • The booking must exist and be in a valid state.
  • Email address must be valid and properly formatted.
  • Email content is automatically generated based on booking details.
  • Some airlines may have restrictions on email frequency per booking.
  • Email templates are predefined and cannot be customized through this endpoint.
  • Booking status affects the type of email content sent (confirmed, pending, etc.).

Response Structure

FieldTypeNullableDescription
systemstringYesSystem name (e.g., VN, VJ, 1A)
statusbooleanNotrue if successful, false if failed
errorobjectYesError details (if any)
descriptionstringYesError description (if any)
trackingIdstringYesTracking ID for request logs
trackingTimestringYesTime for request tracking (ISO 8601 format)

Error Object

FieldTypeNullableDescription
idintegerNoError code ID
messagestringYesError message

Example Response:

{
"system": "VN",
"status": true,
"error": null,
"description": null,
"trackingId": "abc-123",
"trackingTime": "2024-06-01T12:00:00Z"
}

Error Codes

See Error Codes for details on possible error responses.


Security & Validation

  • All input is validated for type and required fields.
  • Only authenticated users can access this endpoint.
  • Email addresses are validated for proper format.
  • Booking codes are verified against existing bookings.
  • All email sending actions are logged and traceable.
  • Personal data handling complies with privacy regulations.

Validation Questions

  • What types of email templates are available for different booking statuses?
  • Are there limitations on how many emails can be sent per booking?
  • How are email delivery failures handled and reported?
  • Can custom email content or templates be specified?

For integration support, see Contact Support.