# Error Codes

This page lists common error codes returned by the MoreLogin API.

## Response Format

All API responses follow this standard format:


```json
{
  "code": 0,
  "msg": null,
  "data": {},
  "requestId": "unique-request-id"
}
```

| Field | Type | Description |
|  --- | --- | --- |
| `code` | integer | `0` = success, `>0` = error |
| `msg` | string | Error message (null when successful) |
| `data` | object | Response data |
| `requestId` | string | Unique request identifier for troubleshooting |


## Common Error Codes

### General Errors

| Code | Description | Solution |
|  --- | --- | --- |
| `0` | Success | — |
| `99001` | Invalid parameters | Check request body format and required fields |
| `99002` | Permission denied | Check your account permissions |
| `99003` | Request exception | Please make the necessary business adjustments based on the response |
| `99004` | Request body too large | Check your request body |
| `429` | Rate limit exceeded | Reduce request frequency and retry after delay |


### Browser Profile Errors (Local API)

| Code | Description | Solution |
|  --- | --- | --- |
| `100` | Profile is already running | Close the profile first with `/api/env/close` |
| `101` | Profile not found | Verify the `envId` or `uniqueId` |
| `102` | MoreLogin client not running | Start the MoreLogin desktop application |
| `103` | Encryption key required | Provide `encryptKey` for encrypted profiles |


### Cloud Phone Errors (Open API)

| Code | Description | Solution |
|  --- | --- | --- |
| `200` | Cloud phone is offline | Power on the cloud phone first |
| `201` | App installation failed | Check the `appVersionId` or `packageName` |
| `202` | File upload failed | Verify file URL and destination path |


## HTTP Status Codes

| Status | Description |
|  --- | --- |
| `200` | Request processed (check `code` field for business result) |
| `401` | Unauthorized — invalid or expired access token |
| `403` | Forbidden — insufficient permissions |
| `429` | Too Many Requests — rate limit exceeded |
| `500` | Internal Server Error — contact support |


> **Tip**: Always include the `requestId` from the response when contacting support for faster troubleshooting.