Skip to content

Latest commit

Β 

History

History
9322 lines (6420 loc) Β· 119 KB

reference.md

File metadata and controls

9322 lines (6420 loc) Β· 119 KB

Reference

V1 Users

client.v1.users.list(...)

πŸ“ Description

List all users of tenant filtered by query and showInvalidUsers. Pagination is available based on query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.users.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

query: typing.Optional[str]

show_invalid_users: typing.Optional[bool] β€” Show Deactivated users

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.users.update_roles(...)

πŸ“ Description

This endpoint allows tenant administrators to update the roles of a user within their tenant.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.users.update_roles(email='email', roles=['roles'], )

βš™οΈ Parameters

email: str β€” Email of the user

roles: typing.Sequence[str] β€” Roles for the user

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.users.get(...)

πŸ“ Description

Get User associated with provided User id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.users.get(id='id', )

βš™οΈ Parameters

id: str β€” User Id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.users.invite_user(...)

πŸ“ Description

Invite a user to the tenant

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.users.invite_user(accept_invite_client_url='<control plane url>/invite-accept', email='email', )

βš™οΈ Parameters

accept_invite_client_url: str β€” Url to redirect when invite is accepted

email: str β€” Email of user

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.users.deactivate(...)

πŸ“ Description

Deactivate user associated with the provided email within the tenant.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.users.deactivate(email='email', )

βš™οΈ Parameters

email: str β€” Email of the user

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.users.activate(...)

πŸ“ Description

Activate user associated with the provided email within the tenant.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.users.activate(email='email', )

βš™οΈ Parameters

email: str β€” Email of the user

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Teams

client.v1.teams.list(...)

πŸ“ Description

Retrieve all teams associated with the authenticated user. If the user is a tenant admin, returns all teams for the tenant. Pagination is available based on query parameters

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.teams.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.teams.create_or_update(...)

πŸ“ Description

Creates a new team or updates an existing team. It ensures that the team name is unique, valid, and that the team has at least one member. The members of the team are added or updated based on the provided emails.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import TeamManifest
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.teams.create_or_update(manifest=TeamManifest(name='name', members=['members'], ), )

βš™οΈ Parameters

manifest: TeamManifest β€” Team manifest

dry_run: typing.Optional[bool] β€” Dry run

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.teams.get(...)

πŸ“ Description

Get Team associated with provided team id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.teams.get(id='id', )

βš™οΈ Parameters

id: str β€” Team Id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.teams.delete(...)

πŸ“ Description

Deletes the Team associated with the provided Id.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.teams.delete(id='id', )

βš™οΈ Parameters

id: str β€” Team Id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 PersonalAccessTokens

client.v1.personal_access_tokens.list(...)

πŸ“ Description

List Personal Access Tokens created by the user in the current tenant.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.personal_access_tokens.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.personal_access_tokens.create(...)

πŸ“ Description

Create Personal Access Token

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.personal_access_tokens.create(name='name', )

βš™οΈ Parameters

name: str β€” serviceaccount name

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.personal_access_tokens.delete(...)

πŸ“ Description

Delete Personal Access Token associated with the provided serviceAccountId

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.personal_access_tokens.delete(id='id', )

βš™οΈ Parameters

id: str β€” serviceaccount id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 VirtualAccounts

client.v1.virtual_accounts.list(...)

πŸ“ Description

List virtual accounts for the tenant.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.virtual_accounts.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.virtual_accounts.create_or_update(...)

πŸ“ Description

Creates a new virtual account or updates an existing one based on the provided manifest.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import VirtualAccountManifest
from truefoundry_sdk import Permissions
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.virtual_accounts.create_or_update(manifest=VirtualAccountManifest(name='name', permissions=[Permissions(resource_fqn='resource_fqn', resource_type='resource_type', role_id='role_id', )], ), )

βš™οΈ Parameters

manifest: VirtualAccountManifest β€” Virtual account manifest

dry_run: typing.Optional[bool] β€” Dry run

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.virtual_accounts.get(...)

πŸ“ Description

Get virtual account by id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.virtual_accounts.get(id='id', )

βš™οΈ Parameters

id: str β€” serviceaccount id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.virtual_accounts.delete(...)

πŸ“ Description

Delete a virtual account associated with the provided virtual account id.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.virtual_accounts.delete(id='id', )

βš™οΈ Parameters

id: str β€” serviceaccount id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Secrets

client.v1.secrets.list(...)

πŸ“ Description

List secrets associated with a user filtered with optional parameters passed in the body.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.secrets.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

secret_id: typing.Optional[str] β€” Secret Id of the secret.

secret_fqns: typing.Optional[typing.Sequence[str]] β€” Array of FQNs

secret_group_id: typing.Optional[str] β€” Secret Group Id of the secret gourp.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secrets.get(...)

πŸ“ Description

Get Secret associated with provided id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secrets.get(id='id', )

βš™οΈ Parameters

id: str β€” Secret Id of the secret.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secrets.delete(...)

πŸ“ Description

Deletes a secret and its versions along with its values.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secrets.delete(id='id', )

βš™οΈ Parameters

id: str β€” Secret Id of the secret.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 SecretGroups

client.v1.secret_groups.list(...)

πŸ“ Description

List the secret groups associated with a user along with the associated secrets for each group. Filtered with the options passed in the query fields.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.secret_groups.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

secret_group_id: typing.Optional[str] β€” Secret Group Id of secret group.

secret_group_fqn: typing.Optional[str] β€” Fqn of secret group.

secret_attributes: typing.Optional[str] β€” Attributes to return for secret object provided as comma separated values (secretAttributes=id,fqn)

secret_group_attributes: typing.Optional[str] β€” Attributes returned for secret group object provided as comma separated values (secretGroupAttributes=id,fqn)

search: typing.Optional[str] β€” Search query - filters by secret group names that contain the search string

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secret_groups.create(...)

πŸ“ Description

Creates a secret group with secrets in it. A secret version for each of the created secret is created with version number as 1. The returned secret group does not have any secrets in the associatedSecrets field. A separate API call should be made to fetch the associated secrets.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import SecretInput
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secret_groups.create(name='name', integration_id='integrationId', secrets=[SecretInput(key='key', value='value', )], )

βš™οΈ Parameters

name: str β€” Name of the secret group.

integration_id: str β€” Id of the provider integration.

secrets: typing.Sequence[SecretInput] β€” The secrets to be associated with the secret group

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secret_groups.get(...)

πŸ“ Description

Get Secret Group associated with provided secretGroup id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secret_groups.get(id='id', )

βš™οΈ Parameters

id: str β€” Secret Id of the secret group.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secret_groups.update(...)

πŸ“ Description

Updates the secrets in a secret group with new values. A new secret version is created for every secret that has a modified value. Returns the updated secret group. The returned secret group does not have any secrets in the associatedSecrets field. A separate API call should be made to fetch the associated secrets.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import UpdateSecretInput
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secret_groups.update(id='id', secrets=[UpdateSecretInput(key='key', value='value', )], )

βš™οΈ Parameters

id: str β€” Secret Id of the secret group.

secrets: typing.Sequence[UpdateSecretInput]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secret_groups.delete(...)

πŸ“ Description

Deletes the secret group, its associated secrets and secret versions of those secrets.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secret_groups.delete(id='id', )

βš™οΈ Parameters

id: str β€” Secret Id of the secret group.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.secret_groups.list_secrets(...)

πŸ“ Description

List Secrets associated with a Secret Group.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.secret_groups.list_secrets(id='id', )

βš™οΈ Parameters

id: str β€” Secret Id of the secret group.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Clusters

client.v1.clusters.list(...)

πŸ“ Description

Retrieves a list of all latest Clusters. Pagination is available based on query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.clusters.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.clusters.create_or_update(...)

πŸ“ Description

Create or Update cluster with provided manifest

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ClusterManifest
from truefoundry_sdk import ClusterManifestClusterType
from truefoundry_sdk import Collaborator
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.clusters.create_or_update(manifest=ClusterManifest(name='name', cluster_type=ClusterManifestClusterType.AWS_EKS, environment_names=['environment_names'], collaborators=[Collaborator(subject='subject', role_id='role_id', )], ), )

βš™οΈ Parameters

manifest: ClusterManifest β€” Cluster manifest

dry_run: typing.Optional[bool] β€” Dry run the cluster creation/update

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.clusters.get(...)

πŸ“ Description

Get cluster associated with provided id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.clusters.get(id='id', )

βš™οΈ Parameters

id: str β€” Cluster id of the cluster

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.clusters.delete(...)

πŸ“ Description

Delete cluster associated with provided cluster id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.clusters.delete(id='id', )

βš™οΈ Parameters

id: str β€” Cluster id of the cluster

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.clusters.get_addons(...)

πŸ“ Description

List addons for the provided cluster.Pagination is available based on query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.clusters.get_addons(id='id', limit=10, offset=0, )

βš™οΈ Parameters

id: str β€” Cluster id of the cluster

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.clusters.is_connected(...)

πŸ“ Description

Get the status of provided cluster

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.clusters.is_connected(id='id', )

βš™οΈ Parameters

id: str β€” Cluster id of the cluster

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Environments

client.v1.environments.list(...)

πŸ“ Description

List environments, if no environments are found, default environments are created and returned. Pagination is available based on query parameters

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.environments.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.environments.create_or_update(...)

πŸ“ Description

Creates a new Environment or updates an existing Environment.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import EnvironmentManifest
from truefoundry_sdk import EnvironmentColor
from truefoundry_sdk import EnvironmentOptimizeFor
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.environments.create_or_update(manifest=EnvironmentManifest(name='name', color=EnvironmentColor(), is_production=True, optimize_for=EnvironmentOptimizeFor.COST, ), )

βš™οΈ Parameters

manifest: EnvironmentManifest β€” Environment Manifest

dry_run: typing.Optional[bool] β€” Dry run

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.environments.get(...)

πŸ“ Description

Get Environment associated with the provided id.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.environments.get(id='id', )

βš™οΈ Parameters

id: str β€” Environment id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.environments.delete(...)

πŸ“ Description

Delete Environment associated with the provided id.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.environments.delete(id='id', )

βš™οΈ Parameters

id: str β€” Environment id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Applications

client.v1.applications.list(...)

πŸ“ Description

Retrieves a list of all latest applications. Supports filtering by application ID, name, type, and other parameters. Pagination is available based on query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.applications.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

application_id: typing.Optional[str] β€” Application id of the application

workspace_id: typing.Optional[str] β€” Workspace id of the application (comma separated for multiple)

application_name: typing.Optional[str] β€” Name of application

application_type: typing.Optional[str] β€” Type of application (comma separated for multiple). Allowed Values: async-service, service, job, spark-job, helm, notebook, codeserver, rstudio, ssh-server, volume, application, application-set, intercept, workflow

name_search_query: typing.Optional[str] β€” Search query for application name

environment_id: typing.Optional[str] β€” Filter by Environment ids of the application (comma separated for multiple)

cluster_id: typing.Optional[str] β€” Filter by Cluster ids of the application (comma separated for multiple)

application_set_id: typing.Optional[str] β€” Filter by Application Set id of the application

paused: typing.Optional[bool] β€” Filter by Application Paused status

device_type_filter: typing.Optional[ApplicationsListRequestDeviceTypeFilter] β€” Filter by device type of the application. Allowed values: cpu, nvidia_gpu, aws_inferentia, nvidia_mig_gpu, nvidia_timeslicing_gpu, gcp_tpu

last_deployed_by_subjects: typing.Optional[str] β€” Filter by last deployed by specific users

lifecycle_stage: typing.Optional[ApplicationsListRequestLifecycleStage] β€” Filter by application lifecycle state

is_recommendation_present: typing.Optional[bool] β€” Filter out applications with recommendations

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.create_or_update(...)

πŸ“ Description

Create a new Application Deployment based on the provided manifest.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.create_or_update(manifest={'key': 'value'
}, )

βš™οΈ Parameters

manifest: typing.Dict[str, typing.Optional[typing.Any]] β€” Manifest of application

dry_run: typing.Optional[bool] β€” Dry run

force_deploy: typing.Optional[bool] β€” Cancels any ongoing deployments

workspace_id: typing.Optional[str] β€” workspace id of the workspace

application_id: typing.Optional[str] β€” Id of the application

name: typing.Optional[str] β€” Name of application

application_set_id: typing.Optional[str] β€” Application Set Id

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.get(...)

πŸ“ Description

Get Application associated with the provided application ID.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.get(id='id', )

βš™οΈ Parameters

id: str β€” Id of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.delete(...)

πŸ“ Description

Delete Application associated with the provided application ID.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.delete(id='id', )

βš™οΈ Parameters

id: str β€” Id of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.scale_to_zero(...)

πŸ“ Description

Pause a running application by scaling to 0 replicas

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.scale_to_zero(id='id', )

βš™οΈ Parameters

id: str β€” Id of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.scale_to_original(...)

πŸ“ Description

Resume a paused application by scaling back to the original number of replicas

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.scale_to_original(id='id', )

βš™οΈ Parameters

id: str β€” Id of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.applications.cancel_deployment(...)

πŸ“ Description

Cancel an ongoing deployment associated with the provided application ID and deployment ID.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.applications.cancel_deployment(id='id', deployment_id='deploymentId', )

βš™οΈ Parameters

id: str β€” Application id of the application

deployment_id: str β€” Deployment id of the deployment

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 ApplicationVersions

client.v1.application_versions.list(...)

πŸ“ Description

Fetch all deployments for a given application ID with optional filters such as deployment ID or version. Supports pagination.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.application_versions.list(id='id', limit=10, offset=0, version='1', deployment_id='deployment123', )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

id: str β€” Id of the application

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

version: typing.Optional[str] β€” Deployment version. Filter deployments by version.

deployment_id: typing.Optional[str] β€” Deployment ID. Filter deployments by a specific ID.

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.application_versions.get(...)

πŸ“ Description

Get Deployment associated with the provided application ID and deployment ID.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.application_versions.get(id='id', deployment_id='deploymentId', )

βš™οΈ Parameters

id: str β€” Application id of the application

deployment_id: str β€” Deployment id of the deployment

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Jobs

client.v1.jobs.list_runs(...)

πŸ“ Description

List Job Runs for provided Job Id. Filter the data based on parameters passed in the query

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.jobs.list_runs(job_id='jobId', limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

job_id: str β€” Job id of the application

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

search_prefix: typing.Optional[str] β€” Prefix used to search for job runs by name or identifier

sort_by: typing.Optional[JobRunsSortBy] β€” Attribute to sort by

order: typing.Optional[JobRunsSortDirection] β€” Sorting order

triggered_by: typing.Optional[typing.Union[str, typing.Sequence[str]]] β€” Array of subject slugs

status: typing.Optional[typing.Union[JobRunStatus, typing.Sequence[JobRunStatus]]] β€” Status of the job run

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.jobs.get_run(...)

πŸ“ Description

Get Job Run for provided jobRunName and jobId

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.jobs.get_run(job_id='jobId', job_run_name='jobRunName', )

βš™οΈ Parameters

job_id: str β€” Application Id of JOB

job_run_name: str β€” Job run name of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.jobs.delete_run(...)

πŸ“ Description

Delete Job Run for provided jobRunName and jobId

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.jobs.delete_run(job_id='jobId', job_run_name='jobRunName', )

βš™οΈ Parameters

job_id: str β€” Application Id of JOB

job_run_name: str β€” Job run name of the application

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.jobs.trigger(...)

πŸ“ Description

Trigger Job for provided deploymentId or applicationId

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.jobs.trigger()

βš™οΈ Parameters

deployment_id: typing.Optional[str] β€” Deployment Id of the job

application_id: typing.Optional[str] β€” Application Id of the job

input: typing.Optional[TriggerJobRequestInput] β€” Job trigger input

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.jobs.terminate(...)

πŸ“ Description

Terminate Job for provided deploymentId and jobRunName

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.jobs.terminate(deployment_id='deploymentId', job_run_name='jobRunName', )

βš™οΈ Parameters

deployment_id: str β€” Deployment Id of the Deployment

job_run_name: str β€” Job Run name

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Workspaces

client.v1.workspaces.list(...)

πŸ“ Description

List workspaces associated with the user. Optional filters include clusterId, fqn, and workspace name. Pagination is available based on query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.workspaces.list(limit=10, offset=0, )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

limit: typing.Optional[int] β€” Number of items per page

offset: typing.Optional[int] β€” Number of items to skip

cluster_id: typing.Optional[str] β€” ClusterId of the Cluster

name: typing.Optional[str] β€” Workspace Name

fqn: typing.Optional[str] β€” Workspace FQN

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.workspaces.create_or_update(...)

πŸ“ Description

Creates a new workspace or updates an existing one based on the provided manifest.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import WorkspaceManifest
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.workspaces.create_or_update(manifest=WorkspaceManifest(cluster_fqn='cluster_fqn', name='name', ), )

βš™οΈ Parameters

manifest: WorkspaceManifest β€” Workspace manifest

dry_run: typing.Optional[bool] β€” Dry run the request

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.workspaces.get(...)

πŸ“ Description

Get workspace associated with provided workspace id

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.workspaces.get(id='id', )

βš™οΈ Parameters

id: str β€” Workspace id of the space

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.workspaces.delete(...)

πŸ“ Description

Deletes the workspace with the given workspace ID. - Removes the associated namespace from the cluster. - Deletes the corresponding authorization entry.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.workspaces.delete(id='id', )

βš™οΈ Parameters

id: str β€” Workspace id of the space

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Events

client.v1.events.get(...)

πŸ“ Description

Get Events for Pod, Job Run, Application. The events are sourced from Kubernetes as well as events captured by truefoundry. Optional query parameters include startTs, endTs for filtering.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.events.get()

βš™οΈ Parameters

start_ts: typing.Optional[str] β€” Start timestamp (ISO format) for querying events

end_ts: typing.Optional[str] β€” End timestamp (ISO format) for querying events

application_id: typing.Optional[str] β€” Application ID

application_fqn: typing.Optional[str] β€” Application FQN

pod_names: typing.Optional[typing.Union[str, typing.Sequence[str]]] β€” Name of the pods

job_run_name: typing.Optional[str] β€” Job run name

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Alerts

client.v1.alerts.list(...)

πŸ“ Description

Get alerts for a given application or cluster filtered by start and end timestamp

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.alerts.list()

βš™οΈ Parameters

start_ts: typing.Optional[str] β€” Start timestamp (ISO format) for querying events

end_ts: typing.Optional[str] β€” End timestamp (ISO format) for querying events

cluster_id: typing.Optional[str] β€” Cluster id

application_id: typing.Optional[str] β€” Application id

alert_status: typing.Optional[AlertStatus] β€” Alert status

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Logs

client.v1.logs.get(...)

πŸ“ Description

Fetch logs for various workload components, including Services, Jobs, Workflows, Job Runs, and Pods. Logs are filtered based on the provided query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.logs.get()

βš™οΈ Parameters

start_ts: typing.Optional[int] β€” Start timestamp for querying logs, in nanoseconds from the Unix epoch.

end_ts: typing.Optional[int] β€” End timestamp for querying logs, in nanoseconds from the Unix epoch.

limit: typing.Optional[int] β€” Max number of log lines to fetch

direction: typing.Optional[LogsSortingDirection] β€” Direction of sorting logs. Can be asc or desc

num_logs_to_ignore: typing.Optional[int] β€” Number of logs corresponding to the starting timestamp to be ignored.

application_id: typing.Optional[str] β€” Application ID

application_fqn: typing.Optional[str] β€” Application FQN

deployment_id: typing.Optional[str] β€” Deployment ID

job_run_name: typing.Optional[str] β€” Name of the Job Run for which to fetch logs.

pod_name: typing.Optional[str] β€” Name of Pod for which to fetch logs.

container_name: typing.Optional[str] β€” Name of the Container for which to fetch logs.

pod_names: typing.Optional[typing.Union[str, typing.Sequence[str]]] β€” List of pod names for which to fetch logs.

pod_names_regex: typing.Optional[str] β€” Regex pattern for pod names to fetch logs.

search_string: typing.Optional[str] β€” String that needs to be matched

search_type: typing.Optional[LogsSearchFilterType] β€” Query filter type, regex or substring

search_operator: typing.Optional[LogsSearchOperatorType] β€” Comparison operator for filter. equal or not_equal

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 MlRepos

client.v1.ml_repos.create_or_update(...)

πŸ“ Description

Creates or updates an MLRepo entity based on the provided manifest.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.ml_repos.create_or_update(manifest={'key': 'value'
}, )

βš™οΈ Parameters

manifest: typing.Dict[str, typing.Optional[typing.Any]] β€” MLRepo manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.ml_repos.get(...)

πŸ“ Description

Get a ml repo by id Args: id: Unique identifier of the ml repo to get user_info: Authenticated user information

Returns: GetMLRepoResponse: The ml repo

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.ml_repos.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.ml_repos.delete(...)

πŸ“ Description

Delete a ml repo Args: id: Unique identifier of the ml repo to delete user_info: Authenticated user information

Returns: EmptyResponse: Empty response indicating successful deletion

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.ml_repos.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.ml_repos.list(...)

πŸ“ Description

List ml repos Args: filters: Filters for the ml repos user_info: Authenticated user information

Returns: ListMLReposResponse: List of ml repos

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.ml_repos.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

name: typing.Optional[str]

limit: typing.Optional[int]

offset: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Artifacts

client.v1.artifacts.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifacts.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifacts.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifacts.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifacts.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.artifacts.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

run_id: typing.Optional[str]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifacts.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifacts.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Agents

client.v1.agents.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agents.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agents.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agents.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agents.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.agents.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agents.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agents.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Prompts

client.v1.prompts.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.prompts.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.prompts.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.prompts.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.prompts.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.prompts.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.prompts.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.prompts.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Tools

client.v1.tools.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tools.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tools.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tools.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tools.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.tools.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tools.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tools.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Models

client.v1.models.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.models.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.models.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.models.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.models.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.models.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

run_id: typing.Optional[str]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.models.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.models.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 ArtifactVersions

client.v1.artifact_versions.get(...)

πŸ“ Description

Get artifact version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.delete(...)

πŸ“ Description

Delete artifact versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.list(...)

πŸ“ Description

List artifact version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.artifact_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

artifact_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

run_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]]

run_steps: typing.Optional[typing.Union[int, typing.Sequence[int]]]

include_internal_metadata: typing.Optional[bool]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.get_signed_urls(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import Operation
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.get_signed_urls(id='id', paths=['paths'], operation=Operation.READ, )

βš™οΈ Parameters

id: str

paths: typing.Sequence[str]

operation: Operation

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.create_multi_part_upload(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.create_multi_part_upload(id='id', path='path', num_parts=1, )

βš™οΈ Parameters

id: str

path: str

num_parts: int

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.stage(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.stage(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.list_files(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.artifact_versions.list_files(id='id', )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

id: str

path: typing.Optional[str]

limit: typing.Optional[int]

page_token: typing.Optional[str]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.artifact_versions.mark_stage_failure(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.artifact_versions.mark_stage_failure(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 ModelVersions

client.v1.model_versions.get(...)

πŸ“ Description

Get model version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.model_versions.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.model_versions.delete(...)

πŸ“ Description

Delete model versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.model_versions.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.model_versions.list(...)

πŸ“ Description

List model version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.model_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

model_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

run_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]]

run_steps: typing.Optional[typing.Union[int, typing.Sequence[int]]]

include_internal_metadata: typing.Optional[bool]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 PromptVersions

client.v1.prompt_versions.get(...)

πŸ“ Description

Get prompt version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.prompt_versions.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.prompt_versions.delete(...)

πŸ“ Description

Delete prompt versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.prompt_versions.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.prompt_versions.list(...)

πŸ“ Description

List prompt version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.prompt_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

prompt_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 ToolVersions

client.v1.tool_versions.get(...)

πŸ“ Description

Get tool version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tool_versions.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tool_versions.delete(...)

πŸ“ Description

Delete tool versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tool_versions.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tool_versions.list(...)

πŸ“ Description

List tool versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.tool_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

tool_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 AgentVersions

client.v1.agent_versions.resolve(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agent_versions.resolve(fqn='fqn', )

βš™οΈ Parameters

fqn: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agent_versions.get(...)

πŸ“ Description

Get agent version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agent_versions.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agent_versions.delete(...)

πŸ“ Description

Delete agent versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.agent_versions.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.agent_versions.list(...)

πŸ“ Description

List agent versions API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.agent_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

agent_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 DataDirectories

client.v1.data_directories.get(...)

πŸ“ Description

Get a data directory by its ID.

Args: id (str): The ID of the data directory to retrieve user_info: Current authenticated user info

Returns: DataDirectoryResponse: Response containing the retrieved data directory

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.delete(...)

πŸ“ Description

Delete a data directory and optionally its contents.

Args: id: Unique identifier of the data directory to delete delete_contents: If True, also deletes the data directory's contents user_info: Authenticated user information

Returns: EmptyResponse: Empty response indicating successful deletion

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.delete(id='id', )

βš™οΈ Parameters

id: str

delete_contents: typing.Optional[bool]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.list(...)

πŸ“ Description

List all data directories with optional filtering and pagination.

Args: filters: Query parameters for filtering and pagination - ml_repo_id: Filter data directories by ml repo ID - name: Optional filter data directories by name - limit: Optional maximum number of data directories to return - offset: Optional number of data directories to skip user_info: Authenticated user information

Returns: ListDataDirectoriesResponse: List of data directories and pagination info

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.data_directories.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[str]

name: typing.Optional[str]

limit: typing.Optional[int]

offset: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.list_files(...)

πŸ“ Description

List files in a dataset.

Args: request_dto: Request containing dataset ID, path, page token and limit user_info: Authenticated user information

Returns: ListFilesResponse: Response containing files and pagination info

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.data_directories.list_files(id='id', )
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

id: str

path: typing.Optional[str]

limit: typing.Optional[int]

page_token: typing.Optional[str]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.delete_files(...)

πŸ“ Description

Delete files from the dataset.

Args: request_dto: Request containing dataset ID and paths user_info: Authenticated user information

Returns: EmptyResponse: Empty response indicating successful deletion

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.delete_files(id='id', paths=['paths'], )

βš™οΈ Parameters

id: str

paths: typing.Sequence[str]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.get_signed_urls(...)

πŸ“ Description

Get signed URLs for a dataset.

Args: request_dto: Request containing dataset ID, paths and operation user_info: Authenticated user information

Returns: GetSignedURLsResponse: Response containing signed URLs

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import Operation
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.get_signed_urls(id='id', paths=['paths'], operation=Operation.READ, )

βš™οΈ Parameters

id: str

paths: typing.Sequence[str]

operation: Operation

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.data_directories.create_multipart_upload(...)

πŸ“ Description

Create a multipart upload for a dataset

Args: request_dto: Request containing dataset ID, path and number of parts user_info: Authenticated user information

Returns: MultiPartUploadResponse: Response containing multipart upload info

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.data_directories.create_multipart_upload(id='id', path='path', num_parts=1, )

βš™οΈ Parameters

id: str

path: str

num_parts: int

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 TracingProjects

client.v1.tracing_projects.list(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.tracing_projects.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

ml_repo_id: typing.Optional[int]

fqn: typing.Optional[str]

name: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tracing_projects.create_or_update(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ModelManifest
from truefoundry_sdk import TrueFoundryManagedSource
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tracing_projects.create_or_update(manifest=ModelManifest(name='name', metadata={'key': 'value'
}, ml_repo='ml_repo', source=TrueFoundryManagedSource(), ), )

βš™οΈ Parameters

manifest: Manifest

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tracing_projects.get(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tracing_projects.get(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.tracing_projects.delete(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.tracing_projects.delete(id='id', )

βš™οΈ Parameters

id: str

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Users

client.v1.internal.users.get_info()

πŸ“ Description

Get the user session details for the currently authenticated user

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.users.get_info()

βš™οΈ Parameters

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Clusters

client.v1.internal.clusters.get_autoprovisioning_state(...)

πŸ“ Description

Get the auto provisioning status for the provided cluster

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.clusters.get_autoprovisioning_state(id='id', )

βš™οΈ Parameters

id: str β€” Cluster id of the cluster

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Deployments

client.v1.internal.deployments.get_builds(...)

πŸ“ Description

This endpoint returns all build details associated with a specific deployment in a given application.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.deployments.get_builds(id='id', deployment_id='deploymentId', )

βš™οΈ Parameters

id: str β€” Application id of the application

deployment_id: str β€” Deployment id of the deployment

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.internal.deployments.get_code_upload_url(...)

πŸ“ Description

Generate presigned URL to upload code for given serviceName and workspaceFqn

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.deployments.get_code_upload_url(service_name='serviceName', workspace_fqn='workspaceFqn', )

βš™οΈ Parameters

service_name: str β€” ServiceName of the deployment

workspace_fqn: str β€” WorkSpaceFQN of the workspace

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.internal.deployments.get_suggested_endpoint(...)

πŸ“ Description

Generate deployment endpoint based on the provided query parameters.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk import ApplicationType
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.deployments.get_suggested_endpoint(application_type=ApplicationType.ASYNC_SERVICE, application_name='applicationName', workspace_id='workspaceId', )

βš™οΈ Parameters

application_type: ApplicationType β€” Application Type

application_name: str β€” Application name

workspace_id: str β€” Workspace id

base_domain: typing.Optional[str] β€” Base domain

port: typing.Optional[str] β€” Port

prefer_wildcard: typing.Optional[bool] β€” Prefer wildcard

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Applications

client.v1.internal.applications.get_pod_template_hash_to_deployment_version(...)

πŸ“ Description

This endpoint fetches the pod template hash to deployment version map for a specific application.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.applications.get_pod_template_hash_to_deployment_version(id='id', )

βš™οΈ Parameters

id: str β€” Id of the application

pod_template_hashes: typing.Optional[str] β€” Pod Template Hashes (comma separated for multiple)

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Vcs

client.v1.internal.vcs.get_repository_details(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.vcs.get_repository_details(repo_url='repoURL', )

βš™οΈ Parameters

repo_url: str β€” The URL of the repository

id: typing.Optional[str] β€” The integration id of the repository

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

client.v1.internal.vcs.get_authenticated_url(...)

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.vcs.get_authenticated_url(repo_url='repoURL', )

βš™οΈ Parameters

repo_url: str β€” Repository URL (e.g., https://github.com/user/repo, https://bitbucket.org/user/repo)

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal Metrics

client.v1.internal.metrics.get_charts(...)

πŸ“ Description

List charts for a given Application based on parameters passed in the query.

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
from truefoundry_sdk.v1.internal.metrics import MetricsGetChartsRequestFilterEntity
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
client.v1.internal.metrics.get_charts(workspace_id='workspaceId', application_id='applicationId', filter_entity=MetricsGetChartsRequestFilterEntity.APPLICATION, )

βš™οΈ Parameters

workspace_id: str

application_id: str

filter_entity: MetricsGetChartsRequestFilterEntity

start_ts: typing.Optional[str] β€” Start Timestamp

end_ts: typing.Optional[str] β€” End Timestamp

filter_query: typing.Optional[str] β€” Query params to filter metrics

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.

V1 Internal ArtifactVersions

client.v1.internal.artifact_versions.list(...)

πŸ“ Description

List artifact version API

πŸ”Œ Usage

from truefoundry_sdk import TrueFoundry
client = TrueFoundry(api_key="YOUR_API_KEY", base_url="https://yourhost.com/path/to/api", )
response = client.v1.internal.artifact_versions.list()
for item in response:
    yield item
# alternatively, you can paginate page-by-page
for page in response.iter_pages():
    yield page

βš™οΈ Parameters

artifact_id: typing.Optional[str]

fqn: typing.Optional[str]

offset: typing.Optional[int]

limit: typing.Optional[int]

run_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]]

run_steps: typing.Optional[typing.Union[int, typing.Sequence[int]]]

include_internal_metadata: typing.Optional[bool]

include_model_versions: typing.Optional[bool]

request_options: typing.Optional[RequestOptions] β€” Request-specific configuration.