MobileApp

Bulk User Upload Endpoint

Changed on

Function: bulk_user_upload_endpoint Type: API Endpoint (POST)

Purpose: This function uploads an Excel file containing bulk user data to blob storage and sends a message to the service bus to trigger bulk user creation processing.

URL: POST /api/bulk_user_upload

Parameters:

  • App_Code (str): Base64 encoded application code.
  • User_Code (str): Base64 encoded user code.
  • Customer_Key (str): Base64 encoded customer key.
  • excel_file (UploadFile): The Excel file containing user data to upload.

Returns:

  • A JSON response indicating the success or failure of the operation.
  • If successful, returns the uploaded file details and batch ID.
  • If the Customer_Key is invalid, it returns a failure message.

Expected Excel Format: The Excel file should contain columns for user data such as:

  • User Id, First Name, Last Name, Email, Mobile, user_group_code, etc.

Exceptions:

  • Handles exceptions during base64 decoding and database operations, returning an appropriate error message.
post/api/MobileApp/bulk_user_upload

Request

Headers

App-Codestring required
User-Codestring required
Customer-Keystring required

Request body multipart/form-data

excel_filestring binary required

Response

Successful Response

unknown required

Changes