Skip to content

release: 2.0.0 #363

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
May 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,30 @@ jobs:
- name: Run lints
run: ./scripts/lint

upload:
if: github.repository == 'stainless-sdks/julep-python'
timeout-minutes: 10
name: upload
permissions:
contents: read
id-token: write
runs-on: depot-ubuntu-24.04
steps:
- uses: actions/checkout@v4

- name: Get GitHub OIDC Token
id: github-oidc
uses: actions/github-script@v6
with:
script: core.setOutput('github_token', await core.getIDToken());

- name: Upload tarball
env:
URL: https://pkg.stainless.com/s
AUTH: ${{ steps.github-oidc.outputs.github_token }}
SHA: ${{ github.sha }}
run: ./scripts/utils/upload-artifact.sh

test:
timeout-minutes: 10
name: test
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "1.78.3"
".": "2.0.0"
}
8 changes: 4 additions & 4 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 53
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/julep-ai-inc-dash%2Fjulep-14e6e11ab9b7ae3afeab9a4b72dd906f43dfe0a41c8fda86e612eaaae9a8d085.yml
openapi_spec_hash: 01b01a97793714f89a7c971a4cc0f17b
config_hash: 6596c6457cbea976768290d343dcfeea
configured_endpoints: 57
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/julep-ai-inc-dash%2Fjulep-3b58badc86faa95cdd3ca635911d7e31fc286635d11d7731caaf537c239be52b.yml
openapi_spec_hash: 9c451e0c93746d508c96eb94262c79ea
config_hash: 88b616a80e3611da8d5935ccda360a6a
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## 2.0.0 (2025-05-16)

Full Changelog: [v1.78.3...v2.0.0](https://github.com/julep-ai/python-sdk/compare/v1.78.3...v2.0.0)

### Features

* **api:** api update ([053aa7e](https://github.com/julep-ai/python-sdk/commit/053aa7ed8c6447bf3e7c41a0fb8d0f537d11c8e1))
* **api:** manual updates ([75655dd](https://github.com/julep-ai/python-sdk/commit/75655dd686306d77228d7293f32c489f11ca2fc7))


### Chores

* **ci:** fix installation instructions ([26c34e0](https://github.com/julep-ai/python-sdk/commit/26c34e0967193c6ee101d7027ffd17b677d5df81))
* **ci:** upload sdks to package manager ([1bcf32d](https://github.com/julep-ai/python-sdk/commit/1bcf32d2ebbdbc85cd733a07760b3e3239e917fd))
* update SDK settings ([f573d02](https://github.com/julep-ai/python-sdk/commit/f573d020c8c057a55e4099e489ff8e0a4117e4d6))

## 1.78.3 (2025-05-10)

Full Changelog: [v1.78.2...v1.78.3](https://github.com/julep-ai/python-sdk/compare/v1.78.2...v1.78.3)
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,11 @@ tool = client.agents.tools.create(
"files": {},
"follow_redirects": True,
"headers": {"foo": "string"},
"include_response_content": True,
"json": {},
"params": "string",
"schema": {},
"secrets": {"foo": {"name": "name"}},
"timeout": 0,
},
)
Expand Down
15 changes: 15 additions & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -201,3 +201,18 @@ Methods:

- <code title="get /executions/{execution_id}/transitions">client.executions.transitions.<a href="./src/julep/resources/executions/transitions.py">list</a>(execution_id, \*\*<a href="src/julep/types/executions/transition_list_params.py">params</a>) -> <a href="./src/julep/types/transition.py">SyncOffsetPagination[Transition]</a></code>
- <code title="get /executions/{execution_id}/transitions.stream">client.executions.transitions.<a href="./src/julep/resources/executions/transitions.py">stream</a>(execution_id, \*\*<a href="src/julep/types/executions/transition_stream_params.py">params</a>) -> <a href="./src/julep/types/executions/transition_stream_response.py">object</a></code>

# Secrets

Types:

```python
from julep.types import Secret, SecretListResponse
```

Methods:

- <code title="post /secrets">client.secrets.<a href="./src/julep/resources/secrets.py">create</a>(\*\*<a href="src/julep/types/secret_create_params.py">params</a>) -> <a href="./src/julep/types/secret.py">Secret</a></code>
- <code title="put /secrets/{secret_id}">client.secrets.<a href="./src/julep/resources/secrets.py">update</a>(secret_id, \*\*<a href="src/julep/types/secret_update_params.py">params</a>) -> <a href="./src/julep/types/secret.py">Secret</a></code>
- <code title="get /secrets">client.secrets.<a href="./src/julep/resources/secrets.py">list</a>(\*\*<a href="src/julep/types/secret_list_params.py">params</a>) -> <a href="./src/julep/types/secret_list_response.py">SecretListResponse</a></code>
- <code title="delete /secrets/{secret_id}">client.secrets.<a href="./src/julep/resources/secrets.py">delete</a>(secret_id) -> <a href="./src/julep/types/shared/resource_deleted.py">ResourceDeleted</a></code>
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "julep"
version = "1.78.3"
version = "2.0.0"
description = "The official Python library for the julep API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
25 changes: 25 additions & 0 deletions scripts/utils/upload-artifact.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/usr/bin/env bash
set -exuo pipefail

RESPONSE=$(curl -X POST "$URL" \
-H "Authorization: Bearer $AUTH" \
-H "Content-Type: application/json")

SIGNED_URL=$(echo "$RESPONSE" | jq -r '.url')

if [[ "$SIGNED_URL" == "null" ]]; then
echo -e "\033[31mFailed to get signed URL.\033[0m"
exit 1
fi

UPLOAD_RESPONSE=$(tar -cz . | curl -v -X PUT \
-H "Content-Type: application/gzip" \
--data-binary @- "$SIGNED_URL" 2>&1)

if echo "$UPLOAD_RESPONSE" | grep -q "HTTP/[0-9.]* 200"; then
echo -e "\033[32mUploaded build to Stainless storage.\033[0m"
echo -e "\033[32mInstallation: pip install 'https://pkg.stainless.com/s/julep-python/$SHA'\033[0m"
else
echo -e "\033[31mFailed to upload artifact.\033[0m"
exit 1
fi
39 changes: 38 additions & 1 deletion src/julep/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,12 @@
)

if TYPE_CHECKING:
from .resources import docs, jobs, files, tasks, users, agents, sessions, executions
from .resources import docs, jobs, files, tasks, users, agents, secrets, sessions, executions
from .resources.docs import DocsResource, AsyncDocsResource
from .resources.jobs import JobsResource, AsyncJobsResource
from .resources.files import FilesResource, AsyncFilesResource
from .resources.tasks import TasksResource, AsyncTasksResource
from .resources.secrets import SecretsResource, AsyncSecretsResource
from .resources.sessions import SessionsResource, AsyncSessionsResource
from .resources.users.users import UsersResource, AsyncUsersResource
from .resources.agents.agents import AgentsResource, AsyncAgentsResource
Expand Down Expand Up @@ -188,6 +189,12 @@ def executions(self) -> ExecutionsResource:

return ExecutionsResource(self)

@cached_property
def secrets(self) -> SecretsResource:
from .resources.secrets import SecretsResource

return SecretsResource(self)

@cached_property
def with_raw_response(self) -> JulepWithRawResponse:
return JulepWithRawResponse(self)
Expand Down Expand Up @@ -430,6 +437,12 @@ def executions(self) -> AsyncExecutionsResource:

return AsyncExecutionsResource(self)

@cached_property
def secrets(self) -> AsyncSecretsResource:
from .resources.secrets import AsyncSecretsResource

return AsyncSecretsResource(self)

@cached_property
def with_raw_response(self) -> AsyncJulepWithRawResponse:
return AsyncJulepWithRawResponse(self)
Expand Down Expand Up @@ -599,6 +612,12 @@ def executions(self) -> executions.ExecutionsResourceWithRawResponse:

return ExecutionsResourceWithRawResponse(self._client.executions)

@cached_property
def secrets(self) -> secrets.SecretsResourceWithRawResponse:
from .resources.secrets import SecretsResourceWithRawResponse

return SecretsResourceWithRawResponse(self._client.secrets)


class AsyncJulepWithRawResponse:
_client: AsyncJulep
Expand Down Expand Up @@ -654,6 +673,12 @@ def executions(self) -> executions.AsyncExecutionsResourceWithRawResponse:

return AsyncExecutionsResourceWithRawResponse(self._client.executions)

@cached_property
def secrets(self) -> secrets.AsyncSecretsResourceWithRawResponse:
from .resources.secrets import AsyncSecretsResourceWithRawResponse

return AsyncSecretsResourceWithRawResponse(self._client.secrets)


class JulepWithStreamedResponse:
_client: Julep
Expand Down Expand Up @@ -709,6 +734,12 @@ def executions(self) -> executions.ExecutionsResourceWithStreamingResponse:

return ExecutionsResourceWithStreamingResponse(self._client.executions)

@cached_property
def secrets(self) -> secrets.SecretsResourceWithStreamingResponse:
from .resources.secrets import SecretsResourceWithStreamingResponse

return SecretsResourceWithStreamingResponse(self._client.secrets)


class AsyncJulepWithStreamedResponse:
_client: AsyncJulep
Expand Down Expand Up @@ -764,6 +795,12 @@ def executions(self) -> executions.AsyncExecutionsResourceWithStreamingResponse:

return AsyncExecutionsResourceWithStreamingResponse(self._client.executions)

@cached_property
def secrets(self) -> secrets.AsyncSecretsResourceWithStreamingResponse:
from .resources.secrets import AsyncSecretsResourceWithStreamingResponse

return AsyncSecretsResourceWithStreamingResponse(self._client.secrets)


Client = Julep

Expand Down
2 changes: 1 addition & 1 deletion src/julep/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "julep"
__version__ = "1.78.3" # x-release-please-version
__version__ = "2.0.0" # x-release-please-version
14 changes: 14 additions & 0 deletions src/julep/resources/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,14 @@
AgentsResourceWithStreamingResponse,
AsyncAgentsResourceWithStreamingResponse,
)
from .secrets import (
SecretsResource,
AsyncSecretsResource,
SecretsResourceWithRawResponse,
AsyncSecretsResourceWithRawResponse,
SecretsResourceWithStreamingResponse,
AsyncSecretsResourceWithStreamingResponse,
)
from .sessions import (
SessionsResource,
AsyncSessionsResource,
Expand Down Expand Up @@ -114,4 +122,10 @@
"AsyncExecutionsResourceWithRawResponse",
"ExecutionsResourceWithStreamingResponse",
"AsyncExecutionsResourceWithStreamingResponse",
"SecretsResource",
"AsyncSecretsResource",
"SecretsResourceWithRawResponse",
"AsyncSecretsResourceWithRawResponse",
"SecretsResourceWithStreamingResponse",
"AsyncSecretsResourceWithStreamingResponse",
]
16 changes: 16 additions & 0 deletions src/julep/resources/agents/agents.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ def create(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -118,6 +119,7 @@ def create(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_create_params.AgentCreateParams,
),
Expand All @@ -139,6 +141,7 @@ def update(
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
name: Optional[str] | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -172,6 +175,7 @@ def update(
"metadata": metadata,
"model": model,
"name": name,
"project": project,
},
agent_update_params.AgentUpdateParams,
),
Expand Down Expand Up @@ -275,6 +279,7 @@ def create_or_update(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -308,6 +313,7 @@ def create_or_update(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_create_or_update_params.AgentCreateOrUpdateParams,
),
Expand Down Expand Up @@ -362,6 +368,7 @@ def reset(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -395,6 +402,7 @@ def reset(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_reset_params.AgentResetParams,
),
Expand Down Expand Up @@ -444,6 +452,7 @@ async def create(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -475,6 +484,7 @@ async def create(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_create_params.AgentCreateParams,
),
Expand All @@ -496,6 +506,7 @@ async def update(
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
name: Optional[str] | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -529,6 +540,7 @@ async def update(
"metadata": metadata,
"model": model,
"name": name,
"project": project,
},
agent_update_params.AgentUpdateParams,
),
Expand Down Expand Up @@ -632,6 +644,7 @@ async def create_or_update(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -665,6 +678,7 @@ async def create_or_update(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_create_or_update_params.AgentCreateOrUpdateParams,
),
Expand Down Expand Up @@ -719,6 +733,7 @@ async def reset(
instructions: Union[str, List[str]] | NotGiven = NOT_GIVEN,
metadata: Optional[object] | NotGiven = NOT_GIVEN,
model: str | NotGiven = NOT_GIVEN,
project: Optional[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand Down Expand Up @@ -752,6 +767,7 @@ async def reset(
"instructions": instructions,
"metadata": metadata,
"model": model,
"project": project,
},
agent_reset_params.AgentResetParams,
),
Expand Down
Loading