examples: add basic_usage.py starter example#34
Draft
kjankov wants to merge 1 commit into
Draft
Conversation
Adds a minimal runnable example that shows how to create a client, start an agent run, and print the resulting run_id. The file lives in examples/ (manually-maintained, never overwritten by the generator). Co-Authored-By: Oz <oz-agent@warp.dev>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
examples/basic_usage.py— a minimal, runnable starter script that shows how to:OzAPIusingWARP_API_KEYfrom the environmentclient.agent.run()run_idThe file lives in
examples/(manually maintained; never overwritten by the Stainless generator) and follows the conventions documented inCONTRIBUTING.md.Screenshot
Testing
python3 -m ruff format examples/basic_usage.py— 1 file left unchangedpython3 -m ruff check examples/basic_usage.py— All checks passed!Conversation: http://localhost:8080/conversation/a5db1199-acfc-4416-a975-8dc5da001a40
Run: http://localhost:8082/runs/019edca3-58b6-71ad-a2dd-ff73b07c0a44
This PR was generated with Oz.