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

# Get Invite With Event

> Get invite details along with associated event information

This endpoint retrieves both invitation details and information about the associated event in a single call. It's perfect for creating attendee-facing interfaces where you need to show both the invitation and event information.

**What it does:**

* Fetches an invitation and its associated event details in one request
* Can find the invitation using either a session ID or invite ID
* Returns comprehensive information about both the invitation and the event

**When to use it:**

* When building user-facing invitation portals
* For creating digital tickets that show event details
* When displaying "Your Invitations" screens in an app
* To get complete context about an invitation and its event

## Query Parameters

| Parameter    | Type   | Required | Description                   |
| ------------ | ------ | -------- | ----------------------------- |
| `session_id` | string | No       | The unique session identifier |
| `invite_id`  | string | No       | The unique invite identifier  |

You must provide either `session_id` or `invite_id`, but not necessarily both.

## Response

The API returns a response object containing the invite details and its associated event information:

```json theme={null}
{
  "invite": {
    "id": "invite-123",
    "first_name": "John",
    "last_name": "Doe",
    "email": "john.doe@example.com",
    "country_code": "1",
    "mobile_number": "5551234567",
    "authentication_method": "QR Code",
    "event_id": "event-456",
    "session_code": "ABC123",
    "session_id": "session-789",
    "image": "https://example.com/profile-photos/john-doe.jpg",
    "status": "accepted",
    "created_at": "2023-02-28T12:00:00Z",
    "updated_at": "2023-03-01T09:30:00Z",
    "last_seen": "2023-03-01T10:15:00Z"
  },
  "event": {
    "id": "event-456",
    "title": "Annual Tech Conference",
    "description": "Join us for the annual tech conference featuring speakers from top tech companies",
    "instructions": "Please arrive 30 minutes before the event starts for registration",
    "imageUrl": "https://example.com/event-image.jpg",
    "location": {
      "address": "123 Conference Center Dr",
      "city": "San Francisco",
      "state": "CA",
      "zipCode": "94105",
      "country": "USA"
    },
    "start_timestamp": 1677609600,
    "end_timestamp": 1677696000,
    "type": "dated"
  }
}
```

**Efficiency note:** This endpoint combines what would otherwise be two separate API calls (getting invite details and getting event details), making your application more efficient and providing a better user experience.


## OpenAPI

````yaml GET /invites-with-event
openapi: 3.1.0
info:
  title: Securegate.ai API
  version: 0.1.0
servers:
  - url: https://api.securegate.ai
    description: Production environment
security:
  - ApiKeyAuth: []
paths:
  /invites-with-event:
    get:
      summary: Get Invite With Event
      description: Get invite details along with associated event information
      operationId: get_invite_with_event_invites_with_event_get
      parameters:
        - name: session_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Session Id
        - name: invite_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Invite Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InviteWithEvent'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    InviteWithEvent:
      properties:
        invite:
          $ref: '#/components/schemas/Invite'
        event:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Event
      type: object
      required:
        - invite
      title: InviteWithEvent
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    Invite:
      properties:
        first_name:
          type: string
          title: First Name
        last_name:
          type: string
          title: Last Name
        email:
          type: string
          title: Email
        country_code:
          $ref: '#/components/schemas/CountryCodeSimple'
        mobile_number:
          type: string
          title: Mobile Number
        authentication_method:
          $ref: '#/components/schemas/AuthenticationMethod'
        id:
          type: string
          title: Id
        event_id:
          type: string
          title: Event Id
        session_code:
          type: string
          title: Session Code
        image:
          anyOf:
            - type: string
            - type: 'null'
          title: Image
        session_id:
          type: string
          title: Session Id
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        last_seen:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Seen
        onyxplus_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Onyxplus Id
        ticket_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Ticket Id
        status:
          $ref: '#/components/schemas/InviteStatus'
          default: pending
      type: object
      required:
        - first_name
        - last_name
        - email
        - country_code
        - mobile_number
        - authentication_method
        - id
        - event_id
        - session_code
        - session_id
        - created_at
        - updated_at
      title: Invite
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    CountryCodeSimple:
      type: string
      enum:
        - '1'
        - '44'
        - '1'
        - '61'
        - '91'
        - '345'
      title: CountryCodeSimple
    AuthenticationMethod:
      type: string
      enum:
        - QR Code
        - Biometric
        - Both
      title: AuthenticationMethod
    InviteStatus:
      type: string
      enum:
        - pending
        - sent
        - accepted
        - rejected
      title: InviteStatus
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key authentication. Add your API key as the value of the 'x-api-key'
        header.

````