Available on the Enterprise plan. Contact sales to learn more.
gitpod-sdk, @gitpod/sdk, and github.com/gitpod-io/gitpod-sdk-go. Imports, environment variables, request types, responses, and error types change.
Use the examples shipped in the Python source distribution, TypeScript package, or public Go module mirror. Do not use examples from the former language-specific SDK repositories.
Review the breaking changes
Find SDK 0.x usage
Search the application before changing dependencies:Upgrade the package
Upgrade the package and commit the resulting lockfile or module changes:- Python
- TypeScript
- Go
Rename authentication variables
RenameGITPOD_API_KEY to ONA_API_KEY in deployment configuration, local environment files, and secret stores:
GITPOD_API_KEY after every workload uses an SDK version 1.x.
For an organization with a custom management-plane domain, set the API URL explicitly:
https://app.ona.com/api.
Replace client construction and environment workflows
Move environment lifecycle and environment operations to the high-level resource clients. These workflows replace manual environment-class selection, polling helpers, and command helpers used with SDK versions 0.x.- Python
- TypeScript
- Go
Replace Create an environment and run a command through the returned handle:The Python SDK version 1.x is synchronous. In an asynchronous application, call it through a worker thread instead of importing
Gitpod or AsyncGitpod with create_client_from_env:AsyncGitpod:create calls wait for the environment to run. stop waits for the environment to stop, and delete cleans it up. Remove 0.x polling utilities that duplicate this behavior.
Migrate direct API calls to Connect
Use generated protobuf messages and Connect clients for API methods that the high-level workflows do not cover. Request fields now follow the public protobuf schema instead of the parameter objects from versions 0.x.- Python
- TypeScript
- Go
Authenticated synchronous service clients are available through Generated responses are protobuf messages, not Pydantic models. Replace helpers such as
ona.services:to_dict() and to_json() with protobuf-aware serialization where needed.Update pagination, timeouts, and errors
Replace 0.x runtime helpers with their 1.x equivalents:- Pagination: High-level environment lists still fetch pages lazily. Iterate the Python generator, TypeScript async generator, or Go
iter.Seq2. For direct RPCs, sendPaginationRequest.tokenfrom the previousPaginationResponse.next_token. - Timeouts: Use
timeoutin Python, anAbortSignalordefaultTimeoutMsin TypeScript, andcontext.Contextdeadlines in Go. - Errors: Catch typed
SDKErrorsubclasses for high-level workflows. Direct calls use the language’s Connect error type. Replace checks for 0.x types such asAPIStatusError,APIConnectionError, andgitpod.Error. - Retries: Add retries at your application boundary only for operations that are safe to repeat. Do not assume the 0.x default of two retries still applies.
Test the migrated application
Before deploying:- Run the language type checker, compiler, and tests.
- Test authentication with
ONA_API_KEY. - Create, use, and delete a disposable environment.
- Test expected error branches, timeouts, and pagination.
- Test
ONA_BASE_URLif the organization uses a custom domain. - Remove 0.x-only imports, helpers, error types, and the old
GITPOD_API_KEYsetting.
Troubleshooting
An import for Gitpod, AsyncGitpod, or option no longer exists
An import for Gitpod, AsyncGitpod, or option no longer exists
The application still uses a 0.x import. Python code should import from
ona_sdk, TypeScript should use named exports such as createClientFromEnv, and Go workflow code should import the sdk package.Python code blocks the event loop after migration
Python code blocks the event loop after migration
The Python SDK version 1.x is synchronous. Run SDK calls in a worker thread with
asyncio.to_thread, or move the SDK work to a synchronous worker process.A direct API request has type errors after migration
A direct API request has type errors after migration
Build the request with the generated protobuf type for that RPC. In TypeScript, use
create(RequestSchema, fields). In Python and Go, instantiate the generated request message. Check the API reference because 0.x parameter names and helper types do not carry over.Requests fail after changing to ONA_API_KEY
Requests fail after changing to ONA_API_KEY
Confirm that the process receives
ONA_API_KEY, not only GITPOD_API_KEY. For custom domains, also confirm that ONA_BASE_URL uses the management-plane domain and ends in /api.