langsmith.client.Client.list_prompts#
- Client.list_prompts(*, limit: int = 100, offset: int = 0, is_public: bool | None = None, is_archived: bool | None = False, sort_field: PromptSortField = PromptSortField.updated_at, sort_direction: Literal['desc', 'asc'] = 'desc', query: str | None = None) ListPromptsResponse[source]#
List prompts with pagination.
- Parameters:
limit (int) – The maximum number of prompts to return. Defaults to 100.
offset (int) – The number of prompts to skip. Defaults to 0.
is_public (Optional[bool]) – Filter prompts by if they are public.
is_archived (Optional[bool]) – Filter prompts by if they are archived.
sort_field (ls_schemas.PromptsSortField) – The field to sort by. Defaults to “updated_at”.
sort_direction (Literal["desc", "asc"]) – The order to sort by. Defaults to “desc”.
query (Optional[str]) – Filter prompts by a search query.
- Returns:
A response object containing the list of prompts.
- Return type:
ls_schemas.ListPromptsResponse