Skip to content

Commit 1034c21

Browse files
feat(api): update via SDK Studio
1 parent 6ef6312 commit 1034c21

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+3377
-32
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 55
1+
configured_endpoints: 67
22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/digitalocean%2Fgradientai-e40feaac59c85aace6aa42d2749b20e0955dbbae58b06c3a650bc03adafcd7b5.yml
33
openapi_spec_hash: 825c1a4816938e9f594b7a8c06692667
4-
config_hash: ed552d382f42c2e579a4bb0a608e2055
4+
config_hash: e178baf496088c521dd245cbc46c932a

api.md

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,60 @@ Methods:
191191
- <code title="post /v2/gen-ai/agents/{parent_agent_uuid}/child_agents/{child_agent_uuid}">client.agents.child_agents.<a href="./src/do_gradientai/resources/agents/child_agents.py">add</a>(path_child_agent_uuid, \*, path_parent_agent_uuid, \*\*<a href="src/do_gradientai/types/agents/child_agent_add_params.py">params</a>) -> <a href="./src/do_gradientai/types/agents/child_agent_add_response.py">ChildAgentAddResponse</a></code>
192192
- <code title="get /v2/gen-ai/agents/{uuid}/child_agents">client.agents.child_agents.<a href="./src/do_gradientai/resources/agents/child_agents.py">view</a>(uuid) -> <a href="./src/do_gradientai/types/agents/child_agent_view_response.py">ChildAgentViewResponse</a></code>
193193

194+
# Providers
195+
196+
## Anthropic
197+
198+
### Keys
199+
200+
Types:
201+
202+
```python
203+
from do_gradientai.types.providers.anthropic import (
204+
KeyCreateResponse,
205+
KeyRetrieveResponse,
206+
KeyUpdateResponse,
207+
KeyListResponse,
208+
KeyDeleteResponse,
209+
KeyListAgentsResponse,
210+
)
211+
```
212+
213+
Methods:
214+
215+
- <code title="post /v2/gen-ai/anthropic/keys">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">create</a>(\*\*<a href="src/do_gradientai/types/providers/anthropic/key_create_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/anthropic/key_create_response.py">KeyCreateResponse</a></code>
216+
- <code title="get /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">retrieve</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/providers/anthropic/key_retrieve_response.py">KeyRetrieveResponse</a></code>
217+
- <code title="put /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">update</a>(path_api_key_uuid, \*\*<a href="src/do_gradientai/types/providers/anthropic/key_update_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/anthropic/key_update_response.py">KeyUpdateResponse</a></code>
218+
- <code title="get /v2/gen-ai/anthropic/keys">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">list</a>(\*\*<a href="src/do_gradientai/types/providers/anthropic/key_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/anthropic/key_list_response.py">KeyListResponse</a></code>
219+
- <code title="delete /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">delete</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/providers/anthropic/key_delete_response.py">KeyDeleteResponse</a></code>
220+
- <code title="get /v2/gen-ai/anthropic/keys/{uuid}/agents">client.providers.anthropic.keys.<a href="./src/do_gradientai/resources/providers/anthropic/keys.py">list_agents</a>(uuid, \*\*<a href="src/do_gradientai/types/providers/anthropic/key_list_agents_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/anthropic/key_list_agents_response.py">KeyListAgentsResponse</a></code>
221+
222+
## OpenAI
223+
224+
### Keys
225+
226+
Types:
227+
228+
```python
229+
from do_gradientai.types.providers.openai import (
230+
KeyCreateResponse,
231+
KeyRetrieveResponse,
232+
KeyUpdateResponse,
233+
KeyListResponse,
234+
KeyDeleteResponse,
235+
KeyRetrieveAgentsResponse,
236+
)
237+
```
238+
239+
Methods:
240+
241+
- <code title="post /v2/gen-ai/openai/keys">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">create</a>(\*\*<a href="src/do_gradientai/types/providers/openai/key_create_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/openai/key_create_response.py">KeyCreateResponse</a></code>
242+
- <code title="get /v2/gen-ai/openai/keys/{api_key_uuid}">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">retrieve</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/providers/openai/key_retrieve_response.py">KeyRetrieveResponse</a></code>
243+
- <code title="put /v2/gen-ai/openai/keys/{api_key_uuid}">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">update</a>(path_api_key_uuid, \*\*<a href="src/do_gradientai/types/providers/openai/key_update_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/openai/key_update_response.py">KeyUpdateResponse</a></code>
244+
- <code title="get /v2/gen-ai/openai/keys">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">list</a>(\*\*<a href="src/do_gradientai/types/providers/openai/key_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/openai/key_list_response.py">KeyListResponse</a></code>
245+
- <code title="delete /v2/gen-ai/openai/keys/{api_key_uuid}">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">delete</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/providers/openai/key_delete_response.py">KeyDeleteResponse</a></code>
246+
- <code title="get /v2/gen-ai/openai/keys/{uuid}/agents">client.providers.openai.keys.<a href="./src/do_gradientai/resources/providers/openai/keys.py">retrieve_agents</a>(uuid, \*\*<a href="src/do_gradientai/types/providers/openai/key_retrieve_agents_params.py">params</a>) -> <a href="./src/do_gradientai/types/providers/openai/key_retrieve_agents_response.py">KeyRetrieveAgentsResponse</a></code>
247+
194248
# Regions
195249

196250
Types:
@@ -321,4 +375,4 @@ from do_gradientai.types import APIAgreement, APIModel, APIModelVersion, ModelLi
321375

322376
Methods:
323377

324-
- <code title="get /v2/gen-ai/models">client.models.<a href="./src/do_gradientai/resources/models/models.py">list</a>(\*\*<a href="src/do_gradientai/types/model_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/model_list_response.py">ModelListResponse</a></code>
378+
- <code title="get /v2/gen-ai/models">client.models.<a href="./src/do_gradientai/resources/models.py">list</a>(\*\*<a href="src/do_gradientai/types/model_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/model_list_response.py">ModelListResponse</a></code>

src/do_gradientai/_client.py

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,14 @@
3131
)
3232

3333
if TYPE_CHECKING:
34-
from .resources import chat, agents, models, regions, inference, indexing_jobs, knowledge_bases
34+
from .resources import chat, agents, models, regions, inference, providers, indexing_jobs, knowledge_bases
35+
from .resources.models import ModelsResource, AsyncModelsResource
3536
from .resources.regions import RegionsResource, AsyncRegionsResource
3637
from .resources.chat.chat import ChatResource, AsyncChatResource
3738
from .resources.agents.agents import AgentsResource, AsyncAgentsResource
3839
from .resources.indexing_jobs import IndexingJobsResource, AsyncIndexingJobsResource
39-
from .resources.models.models import ModelsResource, AsyncModelsResource
4040
from .resources.inference.inference import InferenceResource, AsyncInferenceResource
41+
from .resources.providers.providers import ProvidersResource, AsyncProvidersResource
4142
from .resources.knowledge_bases.knowledge_bases import KnowledgeBasesResource, AsyncKnowledgeBasesResource
4243

4344
__all__ = [
@@ -114,6 +115,12 @@ def agents(self) -> AgentsResource:
114115

115116
return AgentsResource(self)
116117

118+
@cached_property
119+
def providers(self) -> ProvidersResource:
120+
from .resources.providers import ProvidersResource
121+
122+
return ProvidersResource(self)
123+
117124
@cached_property
118125
def regions(self) -> RegionsResource:
119126
from .resources.regions import RegionsResource
@@ -327,6 +334,12 @@ def agents(self) -> AsyncAgentsResource:
327334

328335
return AsyncAgentsResource(self)
329336

337+
@cached_property
338+
def providers(self) -> AsyncProvidersResource:
339+
from .resources.providers import AsyncProvidersResource
340+
341+
return AsyncProvidersResource(self)
342+
330343
@cached_property
331344
def regions(self) -> AsyncRegionsResource:
332345
from .resources.regions import AsyncRegionsResource
@@ -490,6 +503,12 @@ def agents(self) -> agents.AgentsResourceWithRawResponse:
490503

491504
return AgentsResourceWithRawResponse(self._client.agents)
492505

506+
@cached_property
507+
def providers(self) -> providers.ProvidersResourceWithRawResponse:
508+
from .resources.providers import ProvidersResourceWithRawResponse
509+
510+
return ProvidersResourceWithRawResponse(self._client.providers)
511+
493512
@cached_property
494513
def regions(self) -> regions.RegionsResourceWithRawResponse:
495514
from .resources.regions import RegionsResourceWithRawResponse
@@ -539,6 +558,12 @@ def agents(self) -> agents.AsyncAgentsResourceWithRawResponse:
539558

540559
return AsyncAgentsResourceWithRawResponse(self._client.agents)
541560

561+
@cached_property
562+
def providers(self) -> providers.AsyncProvidersResourceWithRawResponse:
563+
from .resources.providers import AsyncProvidersResourceWithRawResponse
564+
565+
return AsyncProvidersResourceWithRawResponse(self._client.providers)
566+
542567
@cached_property
543568
def regions(self) -> regions.AsyncRegionsResourceWithRawResponse:
544569
from .resources.regions import AsyncRegionsResourceWithRawResponse
@@ -588,6 +613,12 @@ def agents(self) -> agents.AgentsResourceWithStreamingResponse:
588613

589614
return AgentsResourceWithStreamingResponse(self._client.agents)
590615

616+
@cached_property
617+
def providers(self) -> providers.ProvidersResourceWithStreamingResponse:
618+
from .resources.providers import ProvidersResourceWithStreamingResponse
619+
620+
return ProvidersResourceWithStreamingResponse(self._client.providers)
621+
591622
@cached_property
592623
def regions(self) -> regions.RegionsResourceWithStreamingResponse:
593624
from .resources.regions import RegionsResourceWithStreamingResponse
@@ -637,6 +668,12 @@ def agents(self) -> agents.AsyncAgentsResourceWithStreamingResponse:
637668

638669
return AsyncAgentsResourceWithStreamingResponse(self._client.agents)
639670

671+
@cached_property
672+
def providers(self) -> providers.AsyncProvidersResourceWithStreamingResponse:
673+
from .resources.providers import AsyncProvidersResourceWithStreamingResponse
674+
675+
return AsyncProvidersResourceWithStreamingResponse(self._client.providers)
676+
640677
@cached_property
641678
def regions(self) -> regions.AsyncRegionsResourceWithStreamingResponse:
642679
from .resources.regions import AsyncRegionsResourceWithStreamingResponse

src/do_gradientai/resources/__init__.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,14 @@
4040
InferenceResourceWithStreamingResponse,
4141
AsyncInferenceResourceWithStreamingResponse,
4242
)
43+
from .providers import (
44+
ProvidersResource,
45+
AsyncProvidersResource,
46+
ProvidersResourceWithRawResponse,
47+
AsyncProvidersResourceWithRawResponse,
48+
ProvidersResourceWithStreamingResponse,
49+
AsyncProvidersResourceWithStreamingResponse,
50+
)
4351
from .indexing_jobs import (
4452
IndexingJobsResource,
4553
AsyncIndexingJobsResource,
@@ -64,6 +72,12 @@
6472
"AsyncAgentsResourceWithRawResponse",
6573
"AgentsResourceWithStreamingResponse",
6674
"AsyncAgentsResourceWithStreamingResponse",
75+
"ProvidersResource",
76+
"AsyncProvidersResource",
77+
"ProvidersResourceWithRawResponse",
78+
"AsyncProvidersResourceWithRawResponse",
79+
"ProvidersResourceWithStreamingResponse",
80+
"AsyncProvidersResourceWithStreamingResponse",
6781
"RegionsResource",
6882
"AsyncRegionsResource",
6983
"RegionsResourceWithRawResponse",

src/do_gradientai/resources/models/models.py renamed to src/do_gradientai/resources/models.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@
77

88
import httpx
99

10-
from ...types import model_list_params
11-
from ..._types import NOT_GIVEN, Body, Query, Headers, NotGiven
12-
from ..._utils import maybe_transform, async_maybe_transform
13-
from ..._compat import cached_property
14-
from ..._resource import SyncAPIResource, AsyncAPIResource
15-
from ..._response import (
10+
from ..types import model_list_params
11+
from .._types import NOT_GIVEN, Body, Query, Headers, NotGiven
12+
from .._utils import maybe_transform, async_maybe_transform
13+
from .._compat import cached_property
14+
from .._resource import SyncAPIResource, AsyncAPIResource
15+
from .._response import (
1616
to_raw_response_wrapper,
1717
to_streamed_response_wrapper,
1818
async_to_raw_response_wrapper,
1919
async_to_streamed_response_wrapper,
2020
)
21-
from ..._base_client import make_request_options
22-
from ...types.model_list_response import ModelListResponse
21+
from .._base_client import make_request_options
22+
from ..types.model_list_response import ModelListResponse
2323

2424
__all__ = ["ModelsResource", "AsyncModelsResource"]
2525

src/do_gradientai/resources/models/__init__.py

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from .openai import (
4+
OpenAIResource,
5+
AsyncOpenAIResource,
6+
OpenAIResourceWithRawResponse,
7+
AsyncOpenAIResourceWithRawResponse,
8+
OpenAIResourceWithStreamingResponse,
9+
AsyncOpenAIResourceWithStreamingResponse,
10+
)
11+
from .anthropic import (
12+
AnthropicResource,
13+
AsyncAnthropicResource,
14+
AnthropicResourceWithRawResponse,
15+
AsyncAnthropicResourceWithRawResponse,
16+
AnthropicResourceWithStreamingResponse,
17+
AsyncAnthropicResourceWithStreamingResponse,
18+
)
19+
from .providers import (
20+
ProvidersResource,
21+
AsyncProvidersResource,
22+
ProvidersResourceWithRawResponse,
23+
AsyncProvidersResourceWithRawResponse,
24+
ProvidersResourceWithStreamingResponse,
25+
AsyncProvidersResourceWithStreamingResponse,
26+
)
27+
28+
__all__ = [
29+
"AnthropicResource",
30+
"AsyncAnthropicResource",
31+
"AnthropicResourceWithRawResponse",
32+
"AsyncAnthropicResourceWithRawResponse",
33+
"AnthropicResourceWithStreamingResponse",
34+
"AsyncAnthropicResourceWithStreamingResponse",
35+
"OpenAIResource",
36+
"AsyncOpenAIResource",
37+
"OpenAIResourceWithRawResponse",
38+
"AsyncOpenAIResourceWithRawResponse",
39+
"OpenAIResourceWithStreamingResponse",
40+
"AsyncOpenAIResourceWithStreamingResponse",
41+
"ProvidersResource",
42+
"AsyncProvidersResource",
43+
"ProvidersResourceWithRawResponse",
44+
"AsyncProvidersResourceWithRawResponse",
45+
"ProvidersResourceWithStreamingResponse",
46+
"AsyncProvidersResourceWithStreamingResponse",
47+
]
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from .keys import (
4+
KeysResource,
5+
AsyncKeysResource,
6+
KeysResourceWithRawResponse,
7+
AsyncKeysResourceWithRawResponse,
8+
KeysResourceWithStreamingResponse,
9+
AsyncKeysResourceWithStreamingResponse,
10+
)
11+
from .anthropic import (
12+
AnthropicResource,
13+
AsyncAnthropicResource,
14+
AnthropicResourceWithRawResponse,
15+
AsyncAnthropicResourceWithRawResponse,
16+
AnthropicResourceWithStreamingResponse,
17+
AsyncAnthropicResourceWithStreamingResponse,
18+
)
19+
20+
__all__ = [
21+
"KeysResource",
22+
"AsyncKeysResource",
23+
"KeysResourceWithRawResponse",
24+
"AsyncKeysResourceWithRawResponse",
25+
"KeysResourceWithStreamingResponse",
26+
"AsyncKeysResourceWithStreamingResponse",
27+
"AnthropicResource",
28+
"AsyncAnthropicResource",
29+
"AnthropicResourceWithRawResponse",
30+
"AsyncAnthropicResourceWithRawResponse",
31+
"AnthropicResourceWithStreamingResponse",
32+
"AsyncAnthropicResourceWithStreamingResponse",
33+
]

0 commit comments

Comments
 (0)