Overview
Theupdate()
and aupdate()
methods allow you to modify an existing prompt’s name or description. Use update()
for synchronous operations and aupdate()
for asynchronous operations.
Usage example
Parameters
Core Parameters
The unique identifier of the prompt to update (passed as first positional argument).
Dictionary containing the fields to update (passed as second positional argument).Supported Fields:
name
(string, optional): New name for the promptdescription
(string, optional): New description for the prompt
Returns
Returns a prompt object with the following attributes:id
(string): The prompt’s unique identifiername
(string): The prompt’s namedescription
(string): The prompt’s descriptioncontent
(string): The prompt’s contentvariables
(list): List of variables in the promptmetadata
(dict): Additional metadatacreated_at
(string): Creation timestampupdated_at
(string): Last update timestamp