Class PromptsClient
- Namespace
- Auth0.ManagementApi.Clients
- Assembly
- Auth0.ManagementApi.dll
Contains methods to access the /prompts endpoints.
public class PromptsClient : BaseClient, IPromptsClient
- Inheritance
-
PromptsClient
- Implements
- Inherited Members
Constructors
PromptsClient(IManagementConnection, Uri, IDictionary<string, string>)
Initializes a new instance on PromptsClient
public PromptsClient(IManagementConnection connection, Uri baseUri, IDictionary<string, string> defaultHeaders)
Parameters
connectionIManagementConnectionIManagementConnection used to make all API calls.
baseUriUriUri of the endpoint to use in making API calls.
defaultHeadersIDictionary<string, string>Dictionary containing default headers included with every request this client makes.
Methods
GetAsync(CancellationToken)
Get prompts settings
public Task<Prompt> GetAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenThe cancellation token to cancel operation.
Returns
Remarks
Get prompts settings
GetCustomTextForPromptAsync(string, string, CancellationToken)
Retrieve custom text for a specific prompt and language.
public Task<object> GetCustomTextForPromptAsync(string promptName, string language, CancellationToken cancellationToken)
Parameters
promptNamestringName of the prompt.
languagestringLanguage to update.
cancellationTokenCancellationToken
Returns
GetPartialsAsync(string, CancellationToken)
Get template partials for a prompt
public Task<object> GetPartialsAsync(string promptName, CancellationToken cancellationToken = default)
Parameters
promptNamestringName of the prompt.
cancellationTokenCancellationToken
Returns
SetCustomTextForPromptAsync(string, string, object, CancellationToken)
Set custom text for a specific prompt. Existing texts will be overwritten.
public Task SetCustomTextForPromptAsync(string promptName, string language, object customText, CancellationToken cancellationToken = default)
Parameters
promptNamestringName of the prompt.
languagestringLanguage to update.
customTextobjectAn object containing custom dictionaries for a group of screens.
cancellationTokenCancellationToken
Returns
SetPartialsAsync(string, object, CancellationToken)
Set template partials for a prompt
public Task SetPartialsAsync(string promptName, object partials, CancellationToken cancellationToken = default)
Parameters
promptNamestringName of the prompt.
partialsobjectAn object containing template partials for a group of screens.
cancellationTokenCancellationToken
Returns
UpdateAsync(PromptUpdateRequest, CancellationToken)
Update prompts settings.
public Task<Prompt> UpdateAsync(PromptUpdateRequest request, CancellationToken cancellationToken = default)
Parameters
requestPromptUpdateRequestSpecifies prompt setting values that are to be updated.
cancellationTokenCancellationTokenThe cancellation token to cancel operation.
Returns
Remarks
Update prompts settings.