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

# Create a new Rove Miles account

> Creates a new Rove Miles account for a user identified by phone number and external ID.



## OpenAPI

````yaml https://api.staging.rovemiles.com/functions/v1/openapi post /miles/account/create
openapi: 3.0.3
info:
  title: Rove Miles API
  version: 0.1.0
  description: Data Utils, Flights, Hotels & Miles endpoints.
servers:
  - url: https://api.staging.rovemiles.com/functions/v1
security:
  - bearerAuth: []
tags:
  - name: Data
    description: Operations related to reference data like airports and places
  - name: Flights
    description: Operations related to flight search and booking
  - name: Hotels
    description: Operations related to hotel search and booking
  - name: Miles
    description: Operations related to miles and points management
  - name: Deals
    description: Operations related to special offers and promotions for flights and hotels
paths:
  /miles/account/create:
    post:
      tags:
        - Miles
      summary: Create a new Rove Miles account
      description: >-
        Creates a new Rove Miles account for a user identified by phone number
        and external ID.
      operationId: createMilesAccount
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - phone_number
                - external_id
              properties:
                phone_number:
                  type: string
                  description: Phone number of the user
                  pattern: ^(\+1|1)[0-9]+$
                external_id:
                  type: string
                  description: External identifier for the user
            example:
              phone_number: '+12025550123'
              external_id: user_12345
      responses:
        '200':
          description: Successfully created account
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  account_id:
                    type: string
                    format: uuid
                    description: The UUID of the created account
        '400':
          description: Bad Request - Invalid input parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        message:
                          type: string
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalError'
components:
  responses:
    Unauthorized:
      description: Unauthorized - Invalid or missing token
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: 401
            message: Unauthorized - Invalid or missing token
    InternalError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: 500
            message: Internal Server Error
  schemas:
    Error:
      type: object
      properties:
        code:
          type: integer
        message:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        API key for authentication. Add your API key to the Authorization header
        with this format: 'Bearer your_api_key_here'

````