> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://one.miles-api.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://one.miles-api.com/_mcp/server.

# Ingest Enrollment Form

POST https://api.milescaira.com/v7/mf/enrolments/ingest/
Content-Type: application/json

Upsert a MilesForce enrollment-form snapshot (vendor-token gated).

Reference: https://one.miles-api.com/api-reference/account-users/account/ingest-enrollment-form-v-7-mf-enrolments-ingest-post

## Servers

- `https://api.milescaira.com` (Production, default)
- `https://miles-usp-backend-uat-2-154625965269.asia-south1.run.app` (UAT)
- `http://localhost:8080` (Local)

## Request

### Headers

- `X-Enrollment-Form-Vendor-Token` (string, optional, nullable)

### Body (application/json)

This endpoint expects an EnrollmentIngestIn.

- `mf_sso_user_id` (string, required)
- `id` (integer, optional, nullable)
- `status` (boolean, optional, nullable)
- `is_active` (boolean, optional, nullable)
- `created_by` (integer, optional, nullable)
- `updated_by` (integer, optional, nullable)
- `created_at` (datetime, optional, nullable)
- `updated_at` (datetime, optional, nullable)
- `uuid` (string, optional, nullable)
- `candidate_category` (integer, optional, nullable)
- `enrolment_type` (integer, optional, nullable)
- `accept_status` (integer, optional, nullable)
- `draft_type` (string, optional, nullable)
- `ef_status` (integer, optional, nullable)
- `payment_status` (string, optional, nullable)
- `program_mode_id` (integer, optional, nullable)
- `program_id` (integer, optional, nullable)
- `program_level_id` (integer, optional, nullable)
- `program_part_id` (integer, optional, nullable)
- `agreed_amount` (EnrollmentIngestInAgreedAmount, optional, nullable)
- `actual_amount` (EnrollmentIngestInActualAmount, optional, nullable)
- `agreed_date` (datetime, optional, nullable)
- `accepted_at` (datetime, optional, nullable)
- `date_of_enrolment` (datetime, optional, nullable)
- `is_discount` (boolean, optional, nullable)
- `reason_for_discount` (string, optional, nullable)
- `is_loan` (boolean, optional, nullable)
- `loan_id` (string, optional, nullable)
- `loan_tenur_id` (integer, optional, nullable)
- `loan_table_id` (integer, optional, nullable)
- `avanse_loan_table_id` (integer, optional, nullable)
- `propelld_loan_table_id` (integer, optional, nullable)
- `referalId` (integer, optional, nullable)
- `leadId` (integer, optional, nullable)
- `batchId` (integer, optional, nullable)
- `purchase_id` (integer, optional, nullable)
- `shippingAddressId` (integer, optional, nullable)
- `billingAddressId` (integer, optional, nullable)
- `enrolledById` (integer, optional, nullable)
- `srSpocId` (integer, optional, nullable)
- `company_id` (integer, optional, nullable)
- `university_id` (integer, optional, nullable)
- `is_same_address` (boolean, optional, nullable)
- `isDefaulter` (boolean, optional, nullable)
- `defaulter_date` (datetime, optional, nullable)
- `is_whatsapp` (boolean, optional, nullable)
- `lms_access` (boolean, optional, nullable)
- `lms_access_released` (boolean, optional, nullable)
- `date_of_lms_access_released` (datetime, optional, nullable)
- `enrollment_form_link` (string, optional, nullable)
- `is_book` (boolean, optional, nullable)
- `is_evaluation` (boolean, optional, nullable)
- `is_cr_connect` (boolean, optional, nullable)
- `is_combo_enrol` (boolean, optional, nullable)
- `can_edit` (boolean, optional, nullable)
- `comment` (string, optional, nullable)
- `ima_membership` (string, optional, nullable)
- `payload` (any, optional)

## Response

### 201

Successful Response

- `message` (string, required)
- `uuid` (string, required)
- `mf_sso_user_id` (string, required)
- `milesone_user_id` (string, required)
- `mf_id` (integer, optional, nullable)
- `mf_uuid` (string, optional, nullable)

## Errors

### 422 Unprocessable Entity Error

Validation Error

- `detail` (list of ValidationError, optional)

## Types

### EnrollmentIngestInAgreedAmount

### EnrollmentIngestInActualAmount

### ValidationError

- `loc` (list of ValidationErrorLocItems, required)
- `msg` (string, required)
- `type` (string, required)
- `input` (any, optional)
- `ctx` (ValidationErrorCtx, optional)

### ValidationErrorLocItems

### ValidationErrorCtx

## Examples

**Request**

```json
{
  "mf_sso_user_id": "string"
}
```

**Response**

```json
{
  "message": "string",
  "uuid": "string",
  "mf_sso_user_id": "string",
  "milesone_user_id": "string",
  "mf_id": 1,
  "mf_uuid": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.milescaira.com/v7/mf/enrolments/ingest/"

payload = { "mf_sso_user_id": "string" }
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.milescaira.com/v7/mf/enrolments/ingest/"

	payload := strings.NewReader("{\n  \"mf_sso_user_id\": \"string\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.milescaira.com/v7/mf/enrolments/ingest/")
  .header("Content-Type", "application/json")
  .body("{\n  \"mf_sso_user_id\": \"string\"\n}")
  .asString();
```