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

# Get Mobile Operator API

> Look up the mobile operator for a given phone number. Use the returned operator info to select the correct top-up product.

**Real URL:** `POST https://accounts.xoxoday.com/chef/v1/oauth/api`


| Data Type | Description                                        |
| --------- | -------------------------------------------------- |
| String    | Mobile number in E.164 format for operator lookup. |

## Response Schema

| Parameter          | Data Type | Description                                                              |
| ------------------ | --------- | ------------------------------------------------------------------------ |
| `status`           | String    | Indicates the result of the lookup request (e.g., `success`, `failure`). |
| `message`          | String    | Message describing the lookup result.                                    |
| `phone`            | String    | Mobile number in E.164 format that was validated.                        |
| `network_operator` | String    | Operator identified for the given mobile number.                         |
| `is_active`        | Boolean   | Indicates whether the mobile number is active.                           |
| `parentProductId`  | Integer   | Internal product ID mapped to the identified mobile operator.            |

> Note: You can use the same parentProductId in the Get Mobile Top-Up Catalogue API to fetch plans specific to the identified operator.


## OpenAPI

````yaml specs/rewards-mobile-top-up.yaml POST /getMobileOperator
openapi: 3.0.3
info:
  title: Xoxoday Rewards API – Mobile Top-Up
  version: '1.2'
  description: >
    Mobile Top-Up API endpoints for browsing the catalog, looking up operators,

    placing orders, and reporting.


    All operations dispatch to `POST /v1/oauth/api`. Virtual path suffixes are
    used

    for playground differentiation since OpenAPI does not allow multiple POST
    operations

    on the same path.


    **Host split:**

    - `getFilters`, `getBalance`, `paymentHistory` → `stagingstores.xoxoday.com`

    - `getMobileTopUpCatalog`, `getMobileOperator`, `placeOrder`,
    `getOrderDetails`, `getOrderHistory` → `accounts.xoxoday.com`


    **Get Balance** sends parameters as URL query string (not request body).
servers:
  - url: https://stagingstores.xoxoday.com/chef/v1/oauth/api
    description: Sandbox
  - url: https://accounts.xoxoday.com/chef/v1/oauth/api
    description: Production
  - url: https://canvas.xoxoday.com/chef/v1/oauth/api
    description: Testing
security:
  - BearerAuth: []
tags:
  - name: Catalog
  - name: Orders
  - name: Reporting
paths:
  /getMobileOperator:
    post:
      tags:
        - Catalog
      summary: Get Mobile Operator API
      description: >
        Look up the mobile operator for a given phone number. Use the returned
        operator info to select the correct top-up product.


        **Real URL:** `POST https://accounts.xoxoday.com/chef/v1/oauth/api`
      operationId: topupGetMobileOperator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - query
                - tag
                - variables
              properties:
                query:
                  type: string
                  enum:
                    - plumProAPI.mutation.lookupMobileNumber
                  default: plumProAPI.mutation.lookupMobileNumber
                tag:
                  type: string
                  enum:
                    - plumProAPI
                  default: plumProAPI
                variables:
                  type: object
                  required:
                    - data
                  properties:
                    data:
                      type: object
                      required:
                        - mobile_number
                      properties:
                        mobile_number:
                          type: string
                          description: Full phone number including country code.
                          example: '+12125551234'
            example:
              query: plumProAPI.mutation.lookupMobileNumber
              tag: plumProAPI
              variables:
                data:
                  mobile_number: '+12125551234'
      responses:
        '200':
          description: Mobile operator details returned.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      lookupMobileNumber:
                        type: object
                        properties:
                          status:
                            type: number
                          operator:
                            type: string
                            description: Detected mobile operator name.
                          countryCode:
                            type: string
                            description: ISO country code.
                          productId:
                            type: number
                            description: Matched product/operator ID.
              example:
                data:
                  lookupMobileNumber:
                    status: 1
                    operator: AT&T
                    countryCode: US
                    productId: 55132
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '502':
          $ref: '#/components/responses/BadGateway'
      servers:
        - url: https://stagingstores.xoxoday.com/chef/v1/oauth/api
          description: Sandbox
        - url: https://accounts.xoxoday.com/chef/v1/oauth/api
          description: Production
        - url: https://canvas.xoxoday.com/chef/v1/oauth/api
          description: Testing
components:
  responses:
    BadRequest:
      description: Invalid request body or parameters.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
              message:
                type: string
    Unauthorized:
      description: Missing or invalid access token.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Unauthorized
    BadGateway:
      description: Upstream service error.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: '`Authorization: Bearer <access_token>`'

````