# Survey management APIs

Source: [https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html)

The following table lists the indoor APIs to manage the surveys.

| Method | Endpoint | Description | Success code | Error codes |
| --- | --- | --- | --- | --- |
| [POST](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html#post-venues-venueid-survey-publish) | `/venues/{venueId}/survey-publish` | Publish a survey | 202 Accepted | <ul class="ul" id="survey-management-apis__ul_bgr_kx4_4hc"><br>                                    <li class="li">400 Bad Request</li><br><br>                                    <li class="li">401 Unauthorized</li><br><br>                                    <li class="li">403 Forbidden</li><br><br>                                    <li class="li">404 Venue Not Found</li><br><br>                                    <li class="li">409 Conflict (survey state)</li><br><br>                                    <li class="li">500 Internal Server Error</li><br><br>                                </ul> |
| [POST](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html#post-venues-venueid-survey-unpublish) | `/venues/{venueId}/survey-unpublish` | Unpublish a survey | 202 Accepted | <ul class="ul" id="survey-management-apis__ul_u1r_qx4_4hc"><br>                                    <li class="li">401 Unauthorized</li><br><br>                                    <li class="li">403 Forbidden</li><br><br>                                    <li class="li">404 Venue Not Found</li><br><br>                                    <li class="li">409 Conflict (survey state)</li><br><br>                                    <li class="li">500 Internal Server Error</li><br><br>                                </ul> |
| [GET](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html#get-venues-venueid-survey-status) | `/venues/{venueId}/survey-status` | Get the survey status | 200 OK | <ul class="ul" id="survey-management-apis__ul_ldw_rx4_4hc"><br>                                    <li class="li">401 Unauthorized</li><br><br>                                    <li class="li">403 Forbidden</li><br><br>                                    <li class="li">404 Venue Not Found</li><br><br>                                    <li class="li">500 Internal Server Error</li><br><br>                                </ul> |

## POST /venues/{venueId}/survey-publish

Source: [https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html)

Publish a survey for a venue with specified sessions and configuration.

**Path parameters**

| Parameter | Type | Values | Description |
| --- | --- | --- | --- |
| `venueId` | Integer |  | The ID of the venue |

**Request headers**

    Content-Type: application/jsonCopy to clipboard

**Request body**

    {
      "sessions": [1001, 1002, 1003],
      "scanTypes": ["wifi", "ble"],
      "wifiBands": [2.4, 5.0],
      "expirationTimestamp": 1735689600
    }Copy to clipboard

**Request body parameters**

| Parameter | Type | Values | Description |
| --- | --- | --- | --- |
| `sessions` | Array of integers | Minimum: 1 session | List of survey session IDs to publish |
| `scanTypes` | Array of strings | Valid values: <ul class="ul" id="post-venues-venueid-survey-publish__ul_pbm_2y4_4hc"><br>                  <li class="li"><code class="ph codeph">wifi</code></li><br><br>                  <li class="li"><code class="ph codeph">wifiRtt</code></li><br><br>                  <li class="li"><code class="ph codeph">ble</code></li><br><br>                </ul><br><br>Shouldn't contain both `wifi` and<br>                  `wifiRtt` | Types of scans to perform |
| `wifiBands` | Array of floats | Valid values: <ul class="ul" id="post-venues-venueid-survey-publish__ul_mnv_cy4_4hc"><br>                                    <li class="li"><code class="ph codeph">2.4</code></li><br><br>                                    <li class="li"><code class="ph codeph">5.0</code></li><br><br>                                    <li class="li"><code class="ph codeph">6.0</code></li><br><br>                                </ul> | Wi-Fi bands to scan in GHz |
| `expirationTimestamp` | Integer (optional) | Must be a future date | Unix timestamp for survey expiration |

**Response**

- Success response: 202 Accepted

        {
          "message": "Survey publish request accepted."
        }Copy to clipboard
- Error responses:
    - 400 Bad Request

            {
              "message": "sessions: This field is required."
            }
            {
              "message": "sessions: This field may not be null."
            }
            {
              "message": "sessions: Ensure this field has at least 1 elements."
            }
            {
              "message": "sessions: 0: Ensure this value is greater than or equal to 1."
            }
            {
              "message": "sessions: Expected a list of items but got type "str"."
            }
            {
              "message": "scanTypes: This field is required."
            }
            {
              "message": "scanTypes: This field may not be null."
            }
            {
              "message": "scanTypes: 0: "invalid" is not a valid choice."
            }
            {
              "message": "scanTypes: Ensure this field has at least 1 elements."
            }
            {
              "message": "scanTypes: Expected a list of items but got type "str"."
            }
            {
              "message": "scanTypes: scanTypes cannot contain both 'wifi' and 'wifiRtt'."
            }
            {
              "message": "wifiBands: This field is required."
            }
            {
              "message": "wifiBands: This field may not be null."
            }
            {
              "message": "wifiBands: 0: "99.9" is not a valid choice."
            }
            {
              "message": "wifiBands: Ensure this field has at least 1 elements."
            }
            {
              "message": "wifiBands: Expected a list of items but got type "str"."
            }Copy to clipboard
    - 401 Unauthorized: Missing or invalid Skyhook-Auth-Key
              header

            {
              "message": "Missing Skyhook-Auth-Key."
            }
            {
              "message": "Invalid Skyhook-Auth-Key."
            }Copy to clipboard
    - 403 Forbidden: Valid API key but insufficient permissions for the
              requested resource

            {
              "message": "Access Denied."
            }Copy to clipboard
    - 404 Not Found

            {
              "message": "Venue with id <venueId> not found or not associated with this project."
            }
            {
              "message": "The requested resource was not found."
            }Copy to clipboard
    - 409 Conflict

            {
              "message": "Not possible to publish the Survey (current state: ACTIVING)."
            }Copy to clipboard
    - 500 Internal Server Error

            {
              "message": "An unexpected error occurred while publishing the survey."
            }Copy to clipboard

## POST /venues/{venueId}/survey-unpublish

Source: [https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html)

Unpublish an active survey for a venue.

**Path parameters**

| Parameter | Type | Values | Description |
| --- | --- | --- | --- |
| `venueId` | Integer |  | The ID of the venue |

**Request headers**

    Content-Type: application/jsonCopy to clipboard

**Response**

- Success response: 202 Accepted

        {
          "message": "Survey unpublish request accepted."
        }Copy to clipboard
- Error responses:
    - 401 Unauthorized: Missing or invalid Skyhook-Auth-Key
                            header

            {
              "message": "Missing Skyhook-Auth-Key."
            }
            {
              "message": "Invalid Skyhook-Auth-Key."
            }Copy to clipboard
    - 403 Forbidden: Valid API key but insufficient permissions for the
                            requested resource

            {
              "message": "Access Denied."
            }Copy to clipboard
    - 404 Not Found

            {
              "message": "Venue with id <venueId> not found or not associated with this project."
            }
            {
              "message": "The requested resource was not found."
            }Copy to clipboard
    - 409 Conflict

            {
              "message": "Not possible to unpublish the Survey (current state: INACTIVE)."
            }
            {
              "message": "Not possible to unpublish the Survey (current state: DEACTIVATING)."
            }Copy to clipboard
    - 500 Internal Server Error

            {
              "message": "An unexpected error occurred while unpublishing the survey."
            }Copy to clipboard

## GET /venues/{venueId}/survey-status

Source: [https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html](https://docs.qualcomm.com/doc/80-42204-2/topic/survey-management-apis.html)

Retrieves the current status of a survey including published sessions and
                statistics.

**Path parameters**

| Parameter | Type | Values | Description |
| --- | --- | --- | --- |
| `venueId` | Integer |  | The ID of the venue. |

**Request headers**

    Content-Type: application/jsonCopy to clipboard

**Response fields**

| Field | Field | Field | Type | Values | Description |
| --- | --- | --- | --- | --- | --- |
| `surveyState` | `surveyState` | `surveyState` | String | Valid values:<ul class="ul" id="get-venues-venueid-survey-status__ul_axz_51p_4hc"><br>                                    <li class="li">INACTIVE</li><br><br>                                    <li class="li">ACTIVATING</li><br><br>                                    <li class="li">ACTIVE </li><br><br>                                    <li class="li">DEACTIVATING</li><br><br>                                </ul> | Current state of the survey |
| `surveyLastError` | `surveyLastError` | `surveyLastError` | String (nullable) |  | Last error message if any |
| `surveyLastErrorTimestamp` | `surveyLastErrorTimestamp` | `surveyLastErrorTimestamp` | Integer (nullable) |  | Unix timestamp of last error |
| `surveyStats` | `surveyStats` | `surveyStats` | Object (optional) |  | Survey statistics (only present when state is ACTIVE) |
|  | `timestamp` | `timestamp` | Integer |  | Unix timestamp of statistics |
|  | `beacons` | `beacons` | Array |  | Beacon statistics per floor |
|  |  | `floorId` | Integer |  | Floor identifier |
|  |  | `numAPs` | Integer |  | Number of Wi-Fi access points |
|  |  | `numBles` | Integer |  | Number of BLE beacons |
| `sessions` | `sessions` | `sessions` | Array |  | List of all survey sessions for the venue |
|  |  | `sessionId` | Integer |  | Session identifier |
|  |  | `floorId` | Integer |  | Floor identifier |
|  |  | `gtName` | String (nullable) |  | Ground truth name |
|  |  | `configuration` | String |  | Configuration identifier |
|  |  | `generation` | Integer |  | Collection generation |
|  |  | `published` | Boolean |  | Whether session is published |
|  |  | `deviceManufacturer` | String |  | Device manufacturer |
|  |  | `deviceModel` | String |  | Device model |
|  |  | `deviceId` | String |  | Device identifier |
|  |  | `timestamp` | Integer |  | Unix timestamp of session creation |
|  |  | `stats` | Object |  | JSON object for internal tracking and diagnostics; structure may<br>                                vary by release |
|  |  |  |  |  |  |
|  |  |  |  |  |  |
|  |  |  |  |  |  |
|  |  |  |  |  |  |

**Response**

- Success response: 200 OK

        {
          "surveyState": "ACTIVE",
          "surveyLastError": null,
          "surveyLastErrorTimestamp": null,
          "surveyStats": {
            "timestamp": 1698765432,
            "beacons": [
              {
                "floorId": 456,
                "numAPs": 25,
                "numBles": 10
              },
              {
                "floorId": 457,
                "numAPs": 30,
                "numBles": 15
              }
            ]
          },
          "sessions": [
            {
              "sessionId": 1001,
              "floorId": 456,
              "gtName": "ground_truth_01",
              "configuration": "config_001",
              "generation": 1,
              "published": true,
              "deviceManufacturer": "Samsung",
              "deviceModel": "Galaxy S21",
              "deviceId": "1a2b3c4d5e6f",
              "timestamp": 1698765432,
              "stats": {
                "duration": 300,
                "distance": 150.5
              }
            },
            {
              "sessionId": 1002,
              "floorId": 457,
              "gtName": null,
              "configuration": "config_002",
              "generation": 1,
              "published": true,
              "deviceManufacturer": "Apple",
              "deviceModel": "iPhone 13",
              "deviceId": "a1b2c3d4e5f6",
              "timestamp": 1698765433,
              "stats": {}
            }
          ]
        }Copy to clipboard
- Error responses:
    - 401 Unauthorized: Missing or invalid Skyhook-Auth-Key
                            header

            {
              "message": "Missing Skyhook-Auth-Key."
            }
            {
              "message": "Invalid Skyhook-Auth-Key."
            }Copy to clipboard
    - 403 Forbidden: Valid API key but insufficient permissions for the
                            requested resource

            {
              "message": "Access Denied."
            }Copy to clipboard
    - 404 Not Found

            {
              "message": "Venue with id <venueId> not found or not associated with this project."
            }
            {
              "message": "The requested resource was not found."
            }Copy to clipboard
    - 500 Internal Server Error

            {
              "message": "An unexpected error occurred while retrieving the survey status."
            }Copy to clipboard

Last Published: May 19, 2026

[Previous Topic
Survey session management APIs](https://docs.qualcomm.com/bundle/publicresource/80-42204-2/topics/survey-session-management-api.md)