coolipy.resources.tags
Tags resource clients (sync + async).
Classes
-
Expand source code
class AsyncTags(AsyncResourceBase): """Asynchronous client for Coolify tags.""" async def list(self) -> CoolipyAPIResponse[TagList]: """List all tags.""" return await self._get("/tags", response_model=list[Tag]) async def create(self, model: TagCreate) -> CoolipyAPIResponse[Tag]: """Create a tag.""" return await self._post("/tags", json=_dump(model), response_model=Tag) async def update(self, uuid: str, model: TagUpdate) -> CoolipyAPIResponse[Tag]: """Update a tag by UUID.""" return await self._patch(f"/tags/{uuid}", json=_dump(model), response_model=Tag) async def delete(self, uuid: str) -> CoolipyAPIResponse[MessageResponse]: """Delete a tag by UUID.""" return await self._delete(f"/tags/{uuid}", response_model=MessageResponse)Asynchronous client for Coolify tags.
Ancestors
- coolipy._base.AsyncResourceBase
Methods
-
Expand source code
async def create(self, model: TagCreate) -> CoolipyAPIResponse[Tag]: """Create a tag.""" return await self._post("/tags", json=_dump(model), response_model=Tag)Create a tag.
-
Expand source code
async def delete(self, uuid: str) -> CoolipyAPIResponse[MessageResponse]: """Delete a tag by UUID.""" return await self._delete(f"/tags/{uuid}", response_model=MessageResponse)Delete a tag by UUID.
-
Expand source code
async def list(self) -> CoolipyAPIResponse[TagList]: """List all tags.""" return await self._get("/tags", response_model=list[Tag])List all tags.
-
Expand source code
async def update(self, uuid: str, model: TagUpdate) -> CoolipyAPIResponse[Tag]: """Update a tag by UUID.""" return await self._patch(f"/tags/{uuid}", json=_dump(model), response_model=Tag)Update a tag by UUID.
-
Expand source code
class Tags(ResourceBase): """Synchronous client for Coolify tags.""" def list(self) -> CoolipyAPIResponse[TagList]: """List all tags.""" return self._get("/tags", response_model=list[Tag]) def create(self, model: TagCreate) -> CoolipyAPIResponse[Tag]: """Create a tag.""" return self._post("/tags", json=_dump(model), response_model=Tag) def update(self, uuid: str, model: TagUpdate) -> CoolipyAPIResponse[Tag]: """Update a tag by UUID.""" return self._patch(f"/tags/{uuid}", json=_dump(model), response_model=Tag) def delete(self, uuid: str) -> CoolipyAPIResponse[MessageResponse]: """Delete a tag by UUID.""" return self._delete(f"/tags/{uuid}", response_model=MessageResponse)Synchronous client for Coolify tags.
Ancestors
- coolipy._base.ResourceBase
Methods
-
Expand source code
def create(self, model: TagCreate) -> CoolipyAPIResponse[Tag]: """Create a tag.""" return self._post("/tags", json=_dump(model), response_model=Tag)Create a tag.
-
Expand source code
def delete(self, uuid: str) -> CoolipyAPIResponse[MessageResponse]: """Delete a tag by UUID.""" return self._delete(f"/tags/{uuid}", response_model=MessageResponse)Delete a tag by UUID.
-
Expand source code
def list(self) -> CoolipyAPIResponse[TagList]: """List all tags.""" return self._get("/tags", response_model=list[Tag])List all tags.
-
Expand source code
def update(self, uuid: str, model: TagUpdate) -> CoolipyAPIResponse[Tag]: """Update a tag by UUID.""" return self._patch(f"/tags/{uuid}", json=_dump(model), response_model=Tag)Update a tag by UUID.