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

# Start Push Live Activity

> Start a Live Activity session for targeted push devices.

Start a Live Activity session for matching push devices. iOS delivery uses
ActivityKit push-to-start tokens registered by the SDK. Android delivery uses
ongoing notifications with the same live activity payload shape.

```json theme={null}
{
  "app_id": "push_app_short_id",
  "activity_id": "order-123",
  "device_ids": ["push_device_id"],
  "title": "Delivery",
  "status": "Preparing order",
  "progress": 0.25,
  "launch_url": "myapp://orders/123",
  "buttons": [
    {
      "id": "track",
      "text": "Track",
      "launch_url": "myapp://orders/123/track"
    }
  ],
  "data": {
    "order_id": "123"
  }
}
```

Targeting supports the same identifiers as push notification sends: `tokens`,
`device_ids`, `contact_ids`, `external_ids`, `emails`, and `audiences`.


## OpenAPI

````yaml api-reference/openapi.json POST /push/live-activities
openapi: 3.0.1
info:
  title: Sendrealm API
  description: >-
    API for email, push, audience resources, domains, campaign drafts,
    templates, events, topics, and automations
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.sendrealm.com
security:
  - bearerAuth: []
paths:
  /push/live-activities:
    post:
      summary: Start a push Live Activity
      description: Start a Live Activity session for targeted push devices.
      requestBody:
        description: Live Activity start payload
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PushLiveActivityStart'
        required: true
      responses:
        '201':
          description: Live Activity start notification queued or sent
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PushLiveActivityResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '422':
          $ref: '#/components/responses/UnprocessableEntity'
components:
  schemas:
    PushLiveActivityStart:
      allOf:
        - $ref: '#/components/schemas/PushLiveActivityFields'
        - type: object
          required:
            - app_id
            - activity_id
          properties:
            app_id:
              type: string
              description: Push app short ID.
            activity_id:
              type: string
            tokens:
              type: array
              minItems: 1
              items:
                type: object
                required:
                  - token
                  - platform
                additionalProperties: false
                properties:
                  token:
                    type: string
                  platform:
                    type: string
                    enum:
                      - android
                      - ios
            device_ids:
              type: array
              minItems: 1
              items:
                type: string
            contact_ids:
              type: array
              minItems: 1
              items:
                type: string
                format: uuid
            external_ids:
              type: array
              minItems: 1
              items:
                type: string
            emails:
              type: array
              minItems: 1
              items:
                type: string
                format: email
            audiences:
              type: array
              minItems: 1
              items:
                type: string
                format: uuid
            excluded_audiences:
              type: array
              minItems: 1
              items:
                type: string
                format: uuid
            platforms:
              type: array
              minItems: 1
              uniqueItems: true
              items:
                type: string
                enum:
                  - android
                  - ios
          anyOf:
            - required:
                - tokens
            - required:
                - device_ids
            - required:
                - contact_ids
            - required:
                - external_ids
            - required:
                - emails
            - required:
                - audiences
    PushLiveActivityResponse:
      allOf:
        - $ref: '#/components/schemas/Envelope'
        - type: object
          required:
            - data
          properties:
            data:
              type: object
              required:
                - id
                - activity_id
                - event
                - total
                - sent
                - failed
              properties:
                id:
                  type: string
                  format: uuid
                activity_id:
                  type: string
                event:
                  type: string
                total:
                  type: integer
                sent:
                  type: integer
                failed:
                  type: integer
    PushLiveActivityFields:
      type: object
      properties:
        title:
          type: string
        subtitle:
          type: string
        body:
          type: string
        status:
          type: string
        progress:
          type: number
          minimum: 0
          maximum: 1
        eta:
          type: string
        image_url:
          type: string
          format: uri
        accent_color:
          type: string
        launch_url:
          type: string
          maxLength: 2048
        dismiss_at:
          type: string
          format: date-time
        buttons:
          type: array
          maxItems: 3
          items:
            $ref: '#/components/schemas/PushActionButton'
        data:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/JsonValue'
    Envelope:
      type: object
      required:
        - status
      properties:
        status:
          type: integer
          description: HTTP response status code
    Error:
      type: object
      required:
        - status
        - error
      properties:
        status:
          type: integer
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
            details:
              $ref: '#/components/schemas/JsonValue'
            issues:
              type: array
              items:
                $ref: '#/components/schemas/ValidationIssue'
    PushActionButton:
      type: object
      required:
        - id
      additionalProperties: false
      anyOf:
        - type: object
          required:
            - text
        - type: object
          required:
            - title
      properties:
        id:
          type: string
        text:
          type: string
        title:
          type: string
          description: Deprecated alias for text.
        icon:
          type: string
        launch_url:
          type: string
          maxLength: 2048
    JsonValue:
      oneOf:
        - type: string
          nullable: true
        - type: number
        - type: boolean
        - type: object
          additionalProperties:
            $ref: '#/components/schemas/JsonValue'
        - type: array
          items:
            $ref: '#/components/schemas/JsonValue'
    ValidationIssue:
      type: object
      required:
        - code
        - path
        - message
      properties:
        code:
          type: string
        path:
          type: string
          nullable: true
        message:
          type: string
  responses:
    BadRequest:
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Invalid or missing API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Conflict:
      description: Resource conflict
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    UnprocessableEntity:
      description: Request could not be processed
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````