client.projects
client.projects — the projects operations.
On AsyncKindgi every method is the same, awaited.
client.projects.get_default()
Section titled “client.projects.get_default()”get_default(*, timeout: float | None = None) -> ProjectFetch the tenant's Default project. GET /v1/projects/default
Returns the row where Project.isDefault = true (exactly one per tenant), to a caller who can read it, as GET /v1/projects/{projectId} checks. Returns 404 project-not-found when no Default has been provisioned.
client.projects.list()
Section titled “client.projects.list()”list( *, limit: int | None = None, cursor: str | None = None, org_id: str | UUID | None = None, name_contains: str | None = None, timeout: float | None = None,) -> ProjectCollectionPageList projects in the caller's tenant. GET /v1/projects
Cursor-paginated. Optional ?orgId= narrows to a specific org (projects may have no org; absent = all); ?nameContains= substring-matches on Project.name.
client.projects.create()
Section titled “client.projects.create()”create( body: ProjectSpec | Mapping[str, Any] | None = None, /, *, idempotency_key: str | None = None, timeout: float | None = None, **fields: Any,) -> CreateResourceResultCreate a project. POST /v1/projects
A project's slug is unique within its org, and a project without an org's among the tenant's projects without one: two orgs may each have a project with the same slug. A taken slug answers 409 slug-conflict; a second Default, 409 project-default-already-exists.
client.projects.get()
Section titled “client.projects.get()”get(project_id: str | UUID, /, *, timeout: float | None = None) -> ProjectFetch a project by id. GET /v1/projects/{projectId}
client.projects.update()
Section titled “client.projects.update()”update( project_id: str | UUID, body: ProjectPatch | Mapping[str, Any] | None = None, /, *, idempotency_key: str | None = None, timeout: float | None = None, **fields: Any,) -> NonePartially update a project. PATCH /v1/projects/{projectId}
A new slug, or a move to another org (orgId, or null for none), answers 409 slug-conflict when the slug is taken where the project ends up.
client.projects.delete()
Section titled “client.projects.delete()”delete( project_id: str | UUID, /, *, idempotency_key: str | None = None, timeout: float | None = None,) -> NoneDelete a project (idempotent). DELETE /v1/projects/{projectId}