Skip to content

Commit 3018b4c

Browse files
feat(api): update via SDK Studio
1 parent 4292abf commit 3018b4c

Some content is hidden

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

45 files changed

+3762
-82
lines changed

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 170
22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/digitalocean%2Fgradientai-015417b36365dfcb32166e67379c38de8bf5127c33dff646097a819a7b4dc588.yml
33
openapi_spec_hash: d7d811c13cc79f15d82fe680cf425859
4-
config_hash: debcb81a744e9f69195a635bb70d45eb
4+
config_hash: 9e90c31a8b4d524c6714fa969828ecc8

api.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -847,6 +847,68 @@ Methods:
847847
- <code title="get /v2/gen-ai/indexing_jobs/{indexing_job_uuid}/data_sources">client.knowledge_bases.indexing_jobs.<a href="./src/do_gradientai/resources/knowledge_bases/indexing_jobs.py">retrieve_data_sources</a>(indexing_job_uuid) -> <a href="./src/do_gradientai/types/knowledge_bases/indexing_job_retrieve_data_sources_response.py">IndexingJobRetrieveDataSourcesResponse</a></code>
848848
- <code title="put /v2/gen-ai/indexing_jobs/{uuid}/cancel">client.knowledge_bases.indexing_jobs.<a href="./src/do_gradientai/resources/knowledge_bases/indexing_jobs.py">update_cancel</a>(path_uuid, \*\*<a href="src/do_gradientai/types/knowledge_bases/indexing_job_update_cancel_params.py">params</a>) -> <a href="./src/do_gradientai/types/knowledge_bases/indexing_job_update_cancel_response.py">IndexingJobUpdateCancelResponse</a></code>
849849

850+
# Models
851+
852+
Types:
853+
854+
```python
855+
from do_gradientai.types import APIAgreement, APIModel, APIModelVersion, ModelListResponse
856+
```
857+
858+
Methods:
859+
860+
- <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>
861+
862+
## Providers
863+
864+
### Anthropic
865+
866+
Types:
867+
868+
```python
869+
from do_gradientai.types.models.providers import (
870+
AnthropicCreateResponse,
871+
AnthropicRetrieveResponse,
872+
AnthropicUpdateResponse,
873+
AnthropicListResponse,
874+
AnthropicDeleteResponse,
875+
AnthropicListAgentsResponse,
876+
)
877+
```
878+
879+
Methods:
880+
881+
- <code title="post /v2/gen-ai/anthropic/keys">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">create</a>(\*\*<a href="src/do_gradientai/types/models/providers/anthropic_create_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/anthropic_create_response.py">AnthropicCreateResponse</a></code>
882+
- <code title="get /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">retrieve</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/models/providers/anthropic_retrieve_response.py">AnthropicRetrieveResponse</a></code>
883+
- <code title="put /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">update</a>(path_api_key_uuid, \*\*<a href="src/do_gradientai/types/models/providers/anthropic_update_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/anthropic_update_response.py">AnthropicUpdateResponse</a></code>
884+
- <code title="get /v2/gen-ai/anthropic/keys">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">list</a>(\*\*<a href="src/do_gradientai/types/models/providers/anthropic_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/anthropic_list_response.py">AnthropicListResponse</a></code>
885+
- <code title="delete /v2/gen-ai/anthropic/keys/{api_key_uuid}">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">delete</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/models/providers/anthropic_delete_response.py">AnthropicDeleteResponse</a></code>
886+
- <code title="get /v2/gen-ai/anthropic/keys/{uuid}/agents">client.models.providers.anthropic.<a href="./src/do_gradientai/resources/models/providers/anthropic.py">list_agents</a>(uuid, \*\*<a href="src/do_gradientai/types/models/providers/anthropic_list_agents_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/anthropic_list_agents_response.py">AnthropicListAgentsResponse</a></code>
887+
888+
### OpenAI
889+
890+
Types:
891+
892+
```python
893+
from do_gradientai.types.models.providers import (
894+
OpenAICreateResponse,
895+
OpenAIRetrieveResponse,
896+
OpenAIUpdateResponse,
897+
OpenAIListResponse,
898+
OpenAIDeleteResponse,
899+
OpenAIRetrieveAgentsResponse,
900+
)
901+
```
902+
903+
Methods:
904+
905+
- <code title="post /v2/gen-ai/openai/keys">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">create</a>(\*\*<a href="src/do_gradientai/types/models/providers/openai_create_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/openai_create_response.py">OpenAICreateResponse</a></code>
906+
- <code title="get /v2/gen-ai/openai/keys/{api_key_uuid}">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">retrieve</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/models/providers/openai_retrieve_response.py">OpenAIRetrieveResponse</a></code>
907+
- <code title="put /v2/gen-ai/openai/keys/{api_key_uuid}">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">update</a>(path_api_key_uuid, \*\*<a href="src/do_gradientai/types/models/providers/openai_update_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/openai_update_response.py">OpenAIUpdateResponse</a></code>
908+
- <code title="get /v2/gen-ai/openai/keys">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">list</a>(\*\*<a href="src/do_gradientai/types/models/providers/openai_list_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/openai_list_response.py">OpenAIListResponse</a></code>
909+
- <code title="delete /v2/gen-ai/openai/keys/{api_key_uuid}">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">delete</a>(api_key_uuid) -> <a href="./src/do_gradientai/types/models/providers/openai_delete_response.py">OpenAIDeleteResponse</a></code>
910+
- <code title="get /v2/gen-ai/openai/keys/{uuid}/agents">client.models.providers.openai.<a href="./src/do_gradientai/resources/models/providers/openai.py">retrieve_agents</a>(uuid, \*\*<a href="src/do_gradientai/types/models/providers/openai_retrieve_agents_params.py">params</a>) -> <a href="./src/do_gradientai/types/models/providers/openai_retrieve_agents_response.py">OpenAIRetrieveAgentsResponse</a></code>
911+
850912
# Regions
851913

852914
Types:

src/do_gradientai/_client.py

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
)
3333

3434
if TYPE_CHECKING:
35-
from .resources import chat, agents, regions, databases, inference, gpu_droplets, knowledge_bases
35+
from .resources import chat, agents, models, regions, databases, inference, gpu_droplets, knowledge_bases
3636
from .resources.regions import RegionsResource, AsyncRegionsResource
3737
from .resources.chat.chat import ChatResource, AsyncChatResource
3838
from .resources.gpu_droplets import (
@@ -48,6 +48,7 @@
4848
load_balancers,
4949
)
5050
from .resources.agents.agents import AgentsResource, AsyncAgentsResource
51+
from .resources.models.models import ModelsResource, AsyncModelsResource
5152
from .resources.databases.databases import DatabasesResource, AsyncDatabasesResource
5253
from .resources.inference.inference import InferenceResource, AsyncInferenceResource
5354
from .resources.gpu_droplets.snapshots import (
@@ -211,6 +212,12 @@ def knowledge_bases(self) -> KnowledgeBasesResource:
211212

212213
return KnowledgeBasesResource(self)
213214

215+
@cached_property
216+
def models(self) -> ModelsResource:
217+
from .resources.models import ModelsResource
218+
219+
return ModelsResource(self)
220+
214221
@cached_property
215222
def regions(self) -> RegionsResource:
216223
from .resources.regions import RegionsResource
@@ -521,6 +528,12 @@ def knowledge_bases(self) -> AsyncKnowledgeBasesResource:
521528

522529
return AsyncKnowledgeBasesResource(self)
523530

531+
@cached_property
532+
def models(self) -> AsyncModelsResource:
533+
from .resources.models import AsyncModelsResource
534+
535+
return AsyncModelsResource(self)
536+
524537
@cached_property
525538
def regions(self) -> AsyncRegionsResource:
526539
from .resources.regions import AsyncRegionsResource
@@ -703,6 +716,12 @@ def knowledge_bases(self) -> knowledge_bases.KnowledgeBasesResourceWithRawRespon
703716

704717
return KnowledgeBasesResourceWithRawResponse(self._client.knowledge_bases)
705718

719+
@cached_property
720+
def models(self) -> models.ModelsResourceWithRawResponse:
721+
from .resources.models import ModelsResourceWithRawResponse
722+
723+
return ModelsResourceWithRawResponse(self._client.models)
724+
706725
@cached_property
707726
def regions(self) -> regions.RegionsResourceWithRawResponse:
708727
from .resources.regions import RegionsResourceWithRawResponse
@@ -751,6 +770,12 @@ def knowledge_bases(self) -> knowledge_bases.AsyncKnowledgeBasesResourceWithRawR
751770

752771
return AsyncKnowledgeBasesResourceWithRawResponse(self._client.knowledge_bases)
753772

773+
@cached_property
774+
def models(self) -> models.AsyncModelsResourceWithRawResponse:
775+
from .resources.models import AsyncModelsResourceWithRawResponse
776+
777+
return AsyncModelsResourceWithRawResponse(self._client.models)
778+
754779
@cached_property
755780
def regions(self) -> regions.AsyncRegionsResourceWithRawResponse:
756781
from .resources.regions import AsyncRegionsResourceWithRawResponse
@@ -799,6 +824,12 @@ def knowledge_bases(self) -> knowledge_bases.KnowledgeBasesResourceWithStreaming
799824

800825
return KnowledgeBasesResourceWithStreamingResponse(self._client.knowledge_bases)
801826

827+
@cached_property
828+
def models(self) -> models.ModelsResourceWithStreamingResponse:
829+
from .resources.models import ModelsResourceWithStreamingResponse
830+
831+
return ModelsResourceWithStreamingResponse(self._client.models)
832+
802833
@cached_property
803834
def regions(self) -> regions.RegionsResourceWithStreamingResponse:
804835
from .resources.regions import RegionsResourceWithStreamingResponse
@@ -847,6 +878,12 @@ def knowledge_bases(self) -> knowledge_bases.AsyncKnowledgeBasesResourceWithStre
847878

848879
return AsyncKnowledgeBasesResourceWithStreamingResponse(self._client.knowledge_bases)
849880

881+
@cached_property
882+
def models(self) -> models.AsyncModelsResourceWithStreamingResponse:
883+
from .resources.models import AsyncModelsResourceWithStreamingResponse
884+
885+
return AsyncModelsResourceWithStreamingResponse(self._client.models)
886+
850887
@cached_property
851888
def regions(self) -> regions.AsyncRegionsResourceWithStreamingResponse:
852889
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
@@ -16,6 +16,14 @@
1616
AgentsResourceWithStreamingResponse,
1717
AsyncAgentsResourceWithStreamingResponse,
1818
)
19+
from .models import (
20+
ModelsResource,
21+
AsyncModelsResource,
22+
ModelsResourceWithRawResponse,
23+
AsyncModelsResourceWithRawResponse,
24+
ModelsResourceWithStreamingResponse,
25+
AsyncModelsResourceWithStreamingResponse,
26+
)
1927
from .regions import (
2028
RegionsResource,
2129
AsyncRegionsResource,
@@ -88,6 +96,12 @@
8896
"AsyncKnowledgeBasesResourceWithRawResponse",
8997
"KnowledgeBasesResourceWithStreamingResponse",
9098
"AsyncKnowledgeBasesResourceWithStreamingResponse",
99+
"ModelsResource",
100+
"AsyncModelsResource",
101+
"ModelsResourceWithRawResponse",
102+
"AsyncModelsResourceWithRawResponse",
103+
"ModelsResourceWithStreamingResponse",
104+
"AsyncModelsResourceWithStreamingResponse",
91105
"RegionsResource",
92106
"AsyncRegionsResource",
93107
"RegionsResourceWithRawResponse",
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 .models import (
4+
ModelsResource,
5+
AsyncModelsResource,
6+
ModelsResourceWithRawResponse,
7+
AsyncModelsResourceWithRawResponse,
8+
ModelsResourceWithStreamingResponse,
9+
AsyncModelsResourceWithStreamingResponse,
10+
)
11+
from .providers import (
12+
ProvidersResource,
13+
AsyncProvidersResource,
14+
ProvidersResourceWithRawResponse,
15+
AsyncProvidersResourceWithRawResponse,
16+
ProvidersResourceWithStreamingResponse,
17+
AsyncProvidersResourceWithStreamingResponse,
18+
)
19+
20+
__all__ = [
21+
"ProvidersResource",
22+
"AsyncProvidersResource",
23+
"ProvidersResourceWithRawResponse",
24+
"AsyncProvidersResourceWithRawResponse",
25+
"ProvidersResourceWithStreamingResponse",
26+
"AsyncProvidersResourceWithStreamingResponse",
27+
"ModelsResource",
28+
"AsyncModelsResource",
29+
"ModelsResourceWithRawResponse",
30+
"AsyncModelsResourceWithRawResponse",
31+
"ModelsResourceWithStreamingResponse",
32+
"AsyncModelsResourceWithStreamingResponse",
33+
]

0 commit comments

Comments
 (0)