Status
Stay organized with collections
Save and categorize content based on your preferences.
The /osc/commands/status
API returns the status for previous inProgress
commands. The status
API is useful for polling the progress of a previously issued command; for example, determining whether camera.takePicture
has completed.
Output
The output is also a command object (see Output
of /osc/commands/execute
)
Error
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-09 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-09 UTC."],[[["\u003cp\u003eThe \u003ccode\u003e/osc/commands/status\u003c/code\u003e API is used to check the status of previously executed commands, like \u003ccode\u003ecamera.takePicture\u003c/code\u003e, that were in progress.\u003c/p\u003e\n"],["\u003cp\u003eIt requires the \u003ccode\u003eid\u003c/code\u003e of the command, obtained from the \u003ccode\u003e/osc/commands/execute\u003c/code\u003e API, to retrieve the status.\u003c/p\u003e\n"],["\u003cp\u003eThe API response provides details like command name, state (e.g., "done"), and any results, such as a file URI.\u003c/p\u003e\n"],["\u003cp\u003ePotential errors include missing or invalid \u003ccode\u003eid\u003c/code\u003e parameters.\u003c/p\u003e\n"]]],["The `/osc/commands/status` API retrieves the status of prior `inProgress` commands, using a command ID from `/osc/commands/execute`. Input requires the `id` parameter; output mirrors the command object format of `/osc/commands/execute`. Errors include `missingParameter` (no ID), `invalidParameterName`, or `invalidParameterValue` (incorrect ID type/value). An example shows a POST request with ID \"90ABCD\" and a successful response indicating \"camera.takePicture\" is \"done\" with the file URI.\n"],null,["# Status\n\nThe `/osc/commands/status` API returns the status for previous `inProgress` commands. The `status` API is useful for polling the progress of a previously issued command; for example, determining whether `camera.takePicture` has completed.\n\nInput\n-----\n\n| Name | Type | Description |\n|------|--------|-------------------------------------------------------------------|\n| `id` | String | Command ID returned by a previous call to`/osc/commands/execute`. |\n\nOutput\n------\n\nThe output is also a command object (see [Output](/streetview/open-spherical-camera/guides/osc/commands/execute#output) of `/osc/commands/execute`)\n\nError\n-----\n\n| Error code | Description |\n|-------------------------|------------------------------------------------------------------------------------------------------------------------------|\n| `missingParameter` | The `id` is not specified. This parameter requires a command ID returned by a previous call to `/osc/commands/execute`. |\n| `invalidParameterName` | The input parameter is unrecognized. |\n| `invalidParameterValue` | The input parameter is recognized, but its value is invalid; for example, `id` value doesn't exist or its type is incorrect. |\n\n| Example ------- ||\n|--------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| **Request** | ```http POST /osc/commands/status HTTP/1.1 Host: [camera ip address]:[httpPort] Content-Type: application/json;charset=utf-8 Accept: application/json Content-Length: {CONTENT_LENGTH} X-XSRF-Protected: 1 { \"id\": \"90ABCD\" } ``` |\n| **Response** | ```http HTTP/1.1 200 OK Content-Type: application/json;charset=utf-8 Content-Length: {CONTENT_LENGTH} X-Content-Type-Options: nosniff { \"name\": \"camera.takePicture\", \"state\": \"done\", \"results\": { \"fileUri\": \"ABC.JPG\" } } ``` |"]]