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

# Update Mobile App

> Update an existing mobile app's configuration

## Request

<ParamField header="X-API-KEY" type="string" required>
  Your API key: `b2co_your_api_key`
</ParamField>

<ParamField path="id" type="string" required>
  The unique identifier of the mobile app to update
</ParamField>

<ParamField body="name" type="string">
  Display name for the mobile app (1-255 characters)
</ParamField>

### iOS App Parameters

<ParamField body="bundleId" type="string">
  iOS bundle identifier (e.g., com.yourcompany.yourapp)
</ParamField>

<ParamField body="appStoreFallback" type="string">
  App Store URL to redirect users without the app installed
</ParamField>

<ParamField body="appStoreId" type="string">
  App Store ID for the app (numeric string)
</ParamField>

<ParamField body="iosMinVersion" type="string">
  Minimum iOS version required (e.g., "14.0")
</ParamField>

### Android App Parameters

<ParamField body="packageName" type="string">
  Android package name (e.g., com.yourcompany.yourapp)
</ParamField>

<ParamField body="playStoreFallback" type="string">
  Play Store URL to redirect users without the app installed
</ParamField>

<ParamField body="androidMinVersion" type="string">
  Minimum Android API level required (e.g., "21")
</ParamField>

<Info>
  **Partial Updates**: You can update any subset of fields. Only provide the fields you want to change.
  The platform cannot be changed after creation.
</Info>

## Response

<ResponseField name="success" type="boolean">
  Indicates if the request was successful
</ResponseField>

<ResponseField name="data" type="object">
  The updated mobile app object
</ResponseField>

<ResponseField name="data.id" type="string">
  Unique identifier for the mobile app
</ResponseField>

<ResponseField name="data.name" type="string">
  Display name of the mobile app
</ResponseField>

<ResponseField name="data.platform" type="string">
  Platform type: `IOS` or `ANDROID`
</ResponseField>

<ResponseField name="data.bundleId" type="string">
  iOS bundle identifier (iOS apps only)
</ResponseField>

<ResponseField name="data.appStoreFallback" type="string">
  App Store fallback URL (iOS apps only)
</ResponseField>

<ResponseField name="data.appStoreId" type="string">
  App Store ID (iOS apps only)
</ResponseField>

<ResponseField name="data.iosMinVersion" type="string">
  Minimum iOS version required (iOS apps only)
</ResponseField>

<ResponseField name="data.packageName" type="string">
  Android package name (Android apps only)
</ResponseField>

<ResponseField name="data.playStoreFallback" type="string">
  Play Store fallback URL (Android apps only)
</ResponseField>

<ResponseField name="data.androidMinVersion" type="string">
  Minimum Android version required (Android apps only)
</ResponseField>

<ResponseField name="data.createdAt" type="string">
  ISO 8601 timestamp when the app was created
</ResponseField>

<ResponseField name="data.updatedAt" type="string">
  ISO 8601 timestamp when the app was last updated
</ResponseField>

<ResponseField name="timestamp" type="string">
  ISO 8601 timestamp of the response
</ResponseField>

<RequestExample>
  ```bash Update Name theme={null}
  curl -X PUT "https://api.bit2connect.com/1.0/mobile-apps/550e8400-e29b-41d4-a716-446655440000" \
    -H "X-API-KEY: b2co_your_api_key" \
    -H "Content-Type: application/json" \
    -d '{
      "name": "Updated App Name"
    }'
  ```

  ```bash Update iOS App theme={null}
  curl -X PUT "https://api.bit2connect.com/1.0/mobile-apps/550e8400-e29b-41d4-a716-446655440000" \
    -H "X-API-KEY: b2co_your_api_key" \
    -H "Content-Type: application/json" \
    -d '{
      "name": "My Updated iOS App",
      "appStoreFallback": "https://apps.apple.com/app/id987654321",
      "appStoreId": "987654321",
      "iosMinVersion": "15.0"
    }'
  ```

  ```javascript JavaScript theme={null}
  const appId = '550e8400-e29b-41d4-a716-446655440000';
  const response = await fetch(`https://api.bit2connect.com/1.0/mobile-apps/${appId}`, {
    method: 'PUT',
    headers: {
      'X-API-KEY': 'b2co_your_api_key',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      name: 'Updated App Name',
      appStoreFallback: 'https://apps.apple.com/app/id987654321'
    })
  });

  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  app_id = '550e8400-e29b-41d4-a716-446655440000'
  response = requests.put(
      f'https://api.bit2connect.com/1.0/mobile-apps/{app_id}',
      headers={
          'X-API-KEY': 'b2co_your_api_key',
          'Content-Type': 'application/json'
      },
      json={
          'name': 'Updated App Name',
          'appStoreFallback': 'https://apps.apple.com/app/id987654321'
      }
  )

  data = response.json()
  print(data)
  ```
</RequestExample>

<ResponseExample>
  ```json Success Response theme={null}
  {
    "success": true,
    "data": {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "name": "Updated App Name",
      "platform": "IOS",
      "bundleId": "com.mycompany.myapp",
      "appStoreFallback": "https://apps.apple.com/app/id987654321",
      "appStoreId": "987654321",
      "iosMinVersion": "15.0",
      "packageName": null,
      "playStoreFallback": null,
      "androidMinVersion": null,
      "createdAt": "2024-01-15T10:30:00Z",
      "updatedAt": "2024-01-15T12:00:00Z"
    },
    "timestamp": "2024-01-15T12:00:00Z"
  }
  ```
</ResponseExample>
