-
Notifications
You must be signed in to change notification settings - Fork 227
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixed fetch config python code snippet
- Loading branch information
Showing
1 changed file
with
3 additions
and
3 deletions.
There are no files selected for viewing
6 changes: 3 additions & 3 deletions
6
agenta-web/src/code_snippets/endpoints/fetch_config/python.ts
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
export default function pythonCode(baseId: string, env_name: string): string { | ||
return ` | ||
# os.environ["AGENTA_API_KEY"] = "your_api_key" # Only when using cloud | ||
# os.environ["HOST"] = "https://cloud.agenta.ai" | ||
# os.environ["AGENTA_HOST"] = "https://cloud.agenta.ai" | ||
from agenta import Agenta | ||
ag = Agenta() | ||
ag.get_config(base_id="${baseId}", | ||
environment="${env_name}", | ||
cache_timeout=600) # timeout 300 per default | ||
environment="${env_name}", | ||
cache_timeout=600) # timeout 300 per default | ||
` | ||
} |