Update Auth
Stay organized with collections
Save and categorize content based on your preferences.
Version 4.0.26.10
Update API Session
API Session Workspace
You can use this endpoint to change the active workspace for the current API session.
Only one workspace can be active in a session. The active workspace can be changed
any number of times in a session.
The default workspace for API sessions is the "production" workspace.
All Looker APIs that use projects or lookml models (such as running queries) will
use the version of project and model files defined by this workspace for the lifetime of the
current API session or until the session workspace is changed again.
An API session has the same lifetime as the access_token used to authenticate API requests. Each successful
API login generates a new access_token and a new API session.
If your Looker API client application needs to work in a dev workspace across multiple
API sessions, be sure to select the dev workspace after each login.
Request
PATCH
/session
Expand HTTP Body definition...
Expand ApiSession definition...
can
lock
object
Operations the current user is able to perform on this object
workspace_id
string
The id of active workspace for this session
sudo_user_id
lock
string
The id of the actual user in the case when this session represents one user sudo'ing as another
Response
200: Auth
can
lock
object
Operations the current user is able to perform on this object
workspace_id
string
The id of active workspace for this session
sudo_user_id
lock
string
The id of the actual user in the case when this session represents one user sudo'ing as another
400: Bad Request
message
lock
string
Error details
documentation_url
lock
string
Documentation link
404: Not Found
message
lock
string
Error details
documentation_url
lock
string
Documentation link
422: Validation Error
message
lock
string
Error details
Expand ValidationErrorDetail definition...
field
lock
string
Field with error
code
lock
string
Error code
message
lock
string
Error info message
documentation_url
lock
string
Documentation link
documentation_url
lock
string
Documentation link
429: Too Many Requests
message
lock
string
Error details
documentation_url
lock
string
Documentation link
Examples
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 2026-07-13 UTC.
[null,null,["Last updated 2026-07-13 UTC."],[],[]]